Retrieve a single file from a repository
In git version 1.7.9.5 this seems to work to export a single file from a remote git archive –remote=ssh://host/pathto/repo.git HEAD README.md This will cat the contents of the file README.md.
In git version 1.7.9.5 this seems to work to export a single file from a remote git archive –remote=ssh://host/pathto/repo.git HEAD README.md This will cat the contents of the file README.md.
Please note that this answer does download a complete copy of the data from a repository. The git remote add -f command will clone the whole repository. From the man page of git-remote: With -f option, git fetch <name> is run immediately after the remote information is set up. Try this: mkdir myrepo cd myrepo … Read more