Thanks to visit codestin.com
Credit goes to github.com

Skip to content

git-changes fails for now repositories #74

@Brickster

Description

@Brickster
$ git state
# status (master)

    Empty repository

$ git changes
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Traceback (most recent call last):
  File "/Users/marcus/Development/python/git-commands/bin/git-changes", line 192, in <module>
    main()
  File "/Users/marcus/Development/python/git-commands/bin/git-changes", line 181, in main
    committish = changes.get_association()
  File "/Users/marcus/Development/python/git-commands/bin/commands/changes.py", line 74, in get_association
    branch = branch if branch else git.current_branch()
  File "/Users/marcus/Development/python/git-commands/bin/commands/utils/git.py", line 94, in current_branch
    return check_output(('git', 'rev-parse', '--abbrev-ref', 'HEAD')).strip()
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 573, in check_output
    raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '('git', 'rev-parse', '--abbrev-ref', 'HEAD')' returned non-zero exit status 128

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions