Created
June 22, 2014 13:24
-
-
Save Hexodus/dbb28212c71066768a8f to your computer and use it in GitHub Desktop.
This shows how to tar the current directory except the unwanted subdirectory files.
This file contains 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
tar cvpzf backup.tgz --exclude='dir_to_exculde/*' * | |
tar cvpzf backup.tgz --exclude='dir_to_exculde/*' | |
--exclude='dir_to_exculde' * | |
//The last asteric means that the current dir is used. Keep in mind that files with a dot aren't included. | |
//The secound example excludes also the directory from being included otherwise it would be included as empty one... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment