generator-xh icon indicating copy to clipboard operation
generator-xh copied to clipboard

WP folders are not ignored when dist is not ignored

Open arekf opened this issue 9 years ago • 1 comments

When dist folder is not addded to .gitignore, WordPress ignored folders are also not being added, see: https://github.com/xhtmlized/generator-xh/blob/master/app/templates/gitignore#L36

Is there any reason for that?

arekf avatar Dec 16 '15 10:12 arekf

Is this because of syntax error? Instead:

bower_components<% if (ignoreDist) { %>
dist<% if (isWP) { %>
wp/wp-content/themes/**/img
wp/wp-content/themes/**/fonts
wp/wp-content/themes/**/js
wp/wp-content/themes/**/css
wp/wp-content/themes/**/media
wp/wp-content/uploads<% } %><% } %>

should be:

bower_components<% if (ignoreDist) { %>
/dist<% } %><% if (isWP) { %>
wp/wp-content/themes/**/img
wp/wp-content/themes/**/fonts
wp/wp-content/themes/**/js
wp/wp-content/themes/**/css
wp/wp-content/themes/**/media
wp/wp-content/uploads<% } %>

Note "/dist" instead "dist" because of problems this definition introduces to some plugins (i.e. Yoast SEO) which uses such folder name.

See pull request: #219

piotr-bajer avatar May 31 '16 20:05 piotr-bajer