Eric J Ostrander's

ClearCase / ClearQuest / Git/Stash "how to" pages.


Git Errors


NOTE: There may be more causes for the errors than the ones listed. The listed cause is just the one that caused it when I made the record. In addition, the solutions may not be the only solution, but the one that was used at the time.

Errors




fatal: pathspec 'file.txt' did not match any files
Updated: 07/21/14
Version: 1.9.4

This error occurred when attempting to add a file to source control from the CLI.
The file did not exist in the current folder. To add a file to source (track), it must already exist.

Back to the INDEX.



fatal: unable to stat 'filename': Filename too long
Updated: 08/06/14
Version: 1.9.4

This error occurred when attempting to add a directory tree of folders/files from the CLI.
The path was 275 characters long and the filename itself was 91 characters long.
I got around the error with:
	git config --global core.longpaths true
Back to the INDEX.


fatal: No such remote 'origin'
Updated: 08/06/14
Version: 1.9.4

This error occurred when attempting to set a remote repository as the origin. The command used was:
	git remote set-url origin URL
That command assumes that "origin" has already been defined and you are just updating the URL for it. Since in this case "origin" was not already defined, the command should be, which defines "origin" and sets the URL at the same time.
	git remote add origin URL
Back to the INDEX.


ejostrander@cox.net
Return to the home page .

This page last modified: 08/27/2020