pathspec error when trying to commit

I am new to git and heroku. I am trying to commit new changes to index.php by:

git add . && git commit -am "test" && git push 

and my output is

  • Why was there an Atlassian icon in my shell when I pushed a commit?
  • Removing Git history as a result of adding wrong remote repo
  • git refuses password, only when logged in as root
  • Where does git rebase make changes
  • Best fit for including or ignoring vQmod files in versioning
  • plugin from github not successfully installing
  • error pathspec '"\226am"' did not match any file<s> known to git.
    

    I’m sure I am just typing a command error, but don’t know what it is.

  • Cloning specific branch
  • Jenkins hangs at git fetch
  • Git init initializes on different directory instead of the current
  • How can I reset my branch to a commit I created while in detached-HEAD mode?
  • Issue with cloning repo from gitlab (fatal: The remote end hung up unexpectedly)
  • Why git AuthorDate is different from CommitDate?
  • One Solution collect form web for “pathspec error when trying to commit”

    I think your minus sign is not the standard, but maybe a UTF-8 hyphen or the like. As a result, -am is being interpreted as a file name instead of an option. Edit the command line, remove what looks like the minus sign and type in a real one.

    Git Baby is a git and github fan, let's start git clone.