Skip to content

Instantly share code, notes, and snippets.

@creativecoder
Created June 22, 2016 20:49
Show Gist options
  • Save creativecoder/fad608748374d9772e71a37d841cfa31 to your computer and use it in GitHub Desktop.
Save creativecoder/fad608748374d9772e71a37d841cfa31 to your computer and use it in GitHub Desktop.
WordPress .gitignore
# WPEngine Deploy - wp-content folder #
###########################################

# Ignore all files in the app directory
app/*
# But not the directory, itself
!app/
# And not the wp-content directory
!**/wp-content/
# Or it's contents
!**/wp-content/*
# Or any of its subdirectories
!**/wp-content/**/*

# Always-ignore extensions #
############################
*.bak
*.diff
*.err
*.orig
*.log
*.rej
*.swo
*.swp
*.zip
*.vi
*~
*.un~
*.sass-cache

# OS generated files #
######################
*~
.svn
.cvs
.DS_Store*
._*
.Spotlight-V100
.Trashes
Icon?
ehthumbs.db
Thumbs.db
.cache
.project
.settings
.tmproj
*.esproj
nbproject
*.sublime*
.awspublish*

# Folders to ignore #
#####################
.hg
.svn
.CVS
.idea
node_modules
.rvmrc
.vagrant
vendor

# Wordpress files #
###################
.env
**/wp-content/uploads/
**/wp-content/blogs.dir/
**/wp-content/upgrade/
**/wp-content/backup-db/
**/wp-content/object-cache.php
**/wp-content/advanced-cache.php
**/wp-content/wp-cache-config.php
**/wp-content/cache/
**/wp-content/backups/
sitemap.xml
sitemap.xml.gz

# Exceptions #
##############
# Include vendor library in plugins folder, since we aren't using `composer install` from within these directories
!**/plugins/*/vendor/

# WPEngine large/disallowed file types
# a CDN should be used for these
*.hqx
*.bin
*.exe
*.dll
*.deb
*.dmg
*.iso
*.img
*.msi
*.msp
*.msm
*.mid
*.midi
*.kar
*.mp3
*.ogg
*.m4a
*.ra
*.3gpp
*.3gp
*.mp4
*.mpeg
*.mpg
*.mov
*.webm
*.flv
*.m4v
*.mng
*.asx
*.asf
*.wmv
*.avi
*.7z
*.bz2
*.jar
*.rar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment