Answer the question
In order to leave comments, you need to log in
How to copy only the files changed in the current commit?
Access to the server is only via FTP. Often you need to upload changes of 20-30 files that are located in different folders.
Is it possible to somehow get a copy of all the changed/added files (it is clear that this will not work with deleted files) in a specific commit of files (respectively, from those sorted into folders) with one command (or better through the GUI)?
Answer the question
In order to leave comments, you need to log in
git diff --name-only HEAD^..HEAD
will show the contents of the last commit.
using it, you can already simply get the desired archive.
git diff --name-only HEAD^..HEAD | zip changes.zip [email protected]
will create a changes.zip archive with files changed by the last commit.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question