the line !wp-content/ in .gitignore should tell git to ignore everything except wp-content folder, but when i do git status it shows that files outside wp-content are not ignored and then complains that there files are untracked...
current git directory files (ls -a):
. index.php wp-blog-header.php wp-cron.php wp-mail.php
.. license.txt wp-comments-post.php wp-includes wp-settings.php
.git readme.html wp-config.php wp-links-opml.php wp-signup.php
.gitignore wp-activate.php wp-config-sample.php wp-load.php wp-trackback.php
.htaccess wp-admin wp-content wp-login.php xmlrpc.php
.gitignore content:
# ignore everything in the root except the "wp-content" directory.
!wp-content/
# ignore everything in the "wp-content" directory, except:
# "mu-plugins", "plugins", "themes" directory
wp-content/*
!wp-content/mu-plugins/
!wp-content/plugins/
!wp-content/themes/
# ignore these plugins
wp-content/plugins/hello.php
# ignore specific themes
wp-content/themes/twenty*/
wp-content/themes/auskim/img/
# ignore node dependency directories
node_modules/
# ignore log files and databases
*.log
*.sql
*.sqlite
what git status shows:
On branch master
Untracked files:
(use "git add <file>..." to include in what will be committed)
.htaccess
index.php
license.txt
readme.html
wp-activate.php
wp-admin/
wp-blog-header.php
wp-comments-post.php
wp-config-sample.php
wp-config.php
wp-cron.php
wp-includes/
wp-links-opml.php
wp-load.php
wp-login.php
wp-mail.php
wp-settings.php
wp-signup.php
wp-trackback.php
xmlrpc.php
nothing added to commit but untracked files present (use "git add" to track)