git-resource icon indicating copy to clipboard operation
git-resource copied to clipboard

Checkout non-detatched mode

Open Jarlotee opened this issue 6 years ago • 3 comments

It looks like currently git always checks out master in detached mode.

But I need to reference what branch has been selected for some automation scripts

Is there parameter to toggle the detached behavior?

Jarlotee avatar Jun 19 '18 22:06 Jarlotee

Hello,

We do experience the same issue, which is annoying for scripts that needs to know which branch has been selected like with

git rev-parse --abbrev-ref HEAD

M0nsieurChat avatar Nov 28 '18 13:11 M0nsieurChat

is this under consideration? This has been open for a half a year now and did not get any feedback :(

Finkregh avatar Jan 28 '19 11:01 Finkregh

Seems like an easy feature to PR. The resource could write to .git/branch just like it writes to .git/ref already.

vito avatar Jan 28 '19 19:01 vito