Skip to content

Loading…

Impossible to reinitialize workspace #28

Closed
trivoallan opened this Issue · 6 comments

3 participants

@trivoallan

Using Ubuntu 10.04 and code from develop branch (4de01f2)

$ git flow init -f
flags:WARN getopt: option invalide -- 'f'
 -- 'init'
flags:FATAL unable to parse provided options with getopt.
@ghost

This is a known issue with shFlags on Ubuntu's getopt. Will have to see whether the shFlags project can pick this up, or whether we could provide a patch for the shFlags repo ourselves.

A workaround for now is to run the following commands:

git config --unset gitflow.branch.master
git config --unset gitflow.branch.develop
git config --unset gitflow.prefix.feature
git config --unset gitflow.prefix.release
git config --unset gitflow.prefix.hotfix
git config --unset gitflow.prefix.support
git config --unset gitflow.prefix.versiontag

Then call git flow init without the -f option.

@trivoallan

Ok. Thanks for the workaround. is there a place where i can vote for resolution of the upstream bug ?

@ghost

I've only recently tested gitflow on Ubuntu, so it's fairly fresh. Haven't had the time to figure out how to translate this exactly to a bug report on shFlags. Help is appreciated with this one.

@nvie
Owner

Decided not to invest in shFlags. Will do a complete reimplementation of gitflow in Python soon (http://github.com/nvie/gitflow/issues#issue/33), which won't suffer from the command line platform difficulties.

@nvie
Owner

Fixed in e1ec57d and confirmed on Ubuntu!

@vdelau

Can confirm this fixed on Debian as well. (was broken in 0.4-dev)

@gmallard gmallard pushed a commit that referenced this issue
@nvie Tell getopt to parse POSIX compatible.
By setting the environmental variable POSIXLY_CORRECT, getopt behaves
strictly POSIX-compatible.  This fixes the incorrect getopt parsing
style that breaks git-flow in several flavours of Linux.

Many thanks to Thiana for figuring this one out.

This should fix issues #28 and #29.
e1ec57d
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.