Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in DevOps and Agile by (29.3k points)

How can my client apply patch created by git diff without git installed? I have tried to use patch command but it always asks file name to patch.

1 Answer

0 votes
by (50.2k points)

git diff > patchfile

and

patch -p1 < patchfile

These are the two commands that help you to apply git diff patch without installing git.

The latest versions of patch command in version 2.7, support most features of the "diff --git" format, which includes renames and copies, permission changes, and symlink diffs.

So if you are using the latest version above 2.7 then you need to use the patch command and there is no need for the git.and able to apply its diff as a patch.

Related questions

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...