nomad icon indicating copy to clipboard operation
nomad copied to clipboard

Bug Report | `git add` subcommand does not work on new Git branches

Open JosephLai241 opened this issue 1 year ago • 0 comments

Describe The Bug

Running nd git add when adding (staging) files on a new branch will not work.

Expected Behavior

This subcommand should successfully stage a file by modifying the Git index.

Actual Behavior

nomad throws an error stating it is unable to stage files and does not modify the Git index.

Steps To Reproduce

  • git checkout a new branch.
  • Create a throwaway file and run nd git add <FILE_OR_DIRECTORY_IDENTIFIER>.
    • An error should be raised here stating nomad is unable to stage the file.

Traceback/Output

"Unable to stage files": Error { code: -9, klass: 4, message: "reference 'refs/heads/master' not found" }

Additional Context

According to the error that was returned, I may need to revisit how the Git refs are pulled from a repository.

JosephLai241 avatar Aug 24 '22 16:08 JosephLai241