1
我想爲Wordpress安裝設置git,並且正在嘗試編寫一個.gitignore文件,它將排除一切但是我的子主題文件夾。這是我到目前爲止:試圖設置一個.gitignore文件的Wordpress安裝
# Ignore everything in the root except the "wp-content" directory.
/*
!.gitignore
!wp-content/
# Ignore everything in the "wp-content" directory, except the "plugins"
# and "themes" directories.
wp-content/*
!wp-content/plugins/
!wp-content/themes/
# Ignore everything in the "plugins" directory, except the plugins you
# specify (see the commented-out examples for hints on how to do this.)
wp-content/plugins/*
# !wp-content/plugins/my-single-file-plugin.php
# !wp-content/plugins/my-directory-plugin/
# Ignore everything in the "themes" directory, except the themes you
# specify (see the commented-out example for a hint on how to do this.)
wp-content/themes/*
!wp-content/themes/my-theme/
這只是顯示子主題文件夾本身,而不是內容。我覺得根據我目前看到的文檔(https://gist.github.com/jdbartlett/444295),這是不對的。有什麼建議麼?
可能是一個愚蠢的問題 - 但你是否將你的主題文件夾添加到代表? –
是的,它已被添加。 – user3093381