Created
July 17, 2014 15:08
-
-
Save iagopiimenta/77baa975ac3c36fca990 to your computer and use it in GitHub Desktop.
How add or change a file but is ignored by git
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git init | |
touch test.php | |
git add test.php | |
git commit -m "initial commit" | |
# any command or script to add or change a file but is ignored by git | |
# example: add debug.php and alter file -> echo -n "testing..." >> test.php | |
any-command-to-edit-or-create-patch-files | |
ls | |
-> test.php debug.php | |
# Now git status to ignore the added and changed files. | |
git status | |
-> nothing to commit (working directory clean) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment