Skip to content

Instantly share code, notes, and snippets.

@astrotars
Created December 4, 2012 18:33
Show Gist options
  • Save astrotars/4207260 to your computer and use it in GitHub Desktop.
Save astrotars/4207260 to your computer and use it in GitHub Desktop.
Allows for empty directory in GIT repository.
# Ignore everything in this directory
*
# Except this file
!.gitignore
@astrotars
Copy link
Author

Place a .gitignore file with the contents above into your empty directory (e.g. /uploads or /tmp). Make sure that your directory has the necessary permissions before committing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment