L
L
LIAL2015-05-20 09:49:56
git
LIAL, 2015-05-20 09:49:56

Is there such a possibility in Git - to create an archive with changed files?

Good afternoon, tell me who knows: is there in git (maybe there are some other means for this) the ability to create a separate file or folder (such as a patch) with changed files (or indicating a commit) and saving the paths?
The goal is this: I am developing on a local area where there is a git repo, then I need to upload the changes to the server (there is no repository) via FTP. File-by-file pouring is not very convenient, especially if there are a lot of files. I would like to get a file or directory - in which there are only those files that are changed or from the specified commit, but with the preservation of all paths - to specify this folder, specify to overwrite files and it would be safely uploaded to the server.
PS: you don't need to offer to put the repo on the server

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Z
Zakharov Alexander, 2015-05-20
@LIAL

This option with TortoiseGit will not work for you:
I see that all the saved files are scattered in their paths.
I found something, just for linux console:
from experiments on the document: stackoverflow.com/questions/4541300/export-only-mo...
my example:
determine the SHA of the commit from which the files are needed and do:
git diff- tree -r --no-commit-id --name-only --diff-filter=ACMRT fd720ceac0b856995afc02921de1615197e9eb0d | xargs tar -rf mytarfile.tar
b435ca8c28394a0cad95c5b66f1a12ac.png

D
dmitry, 2015-05-20
@dmitriylanets

maybe the phing + rsync deployment option or the deployment service is suitable for you deployment service is suitable for you to solve this problem?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question