0

I am using Bitbucket as the version controller for my WordPress theme.

I need to ignore some files in the root directory (style.css, style.css.map, gulpfile.js). But that was not worked as I tried in the below .gitignore file.

Please anyone can help me to identify what was the issue with that?

This is my WordPress theme folder structure:

node-modules
index.php
header.php
footer.php
sidebar.php
gulfile.js
package.json
package-lock.json
style.css
style.css.map

This is my .gitignore file

# Node artifact files
node_modules/
dist/

# Log files
*.log

# Theme style
style.css

# Theme style
style.css.map

# Gulpfile js
gulpfile.js
Kelum
  • 1
  • 2
  • 2
    Just adding stuff into .gitignore changes nothing if the files are already tracked. Might have to consider to delete the files (with `git rm --cached`) so that they are ignored _moving forward_ (but kept in the working tree, not really deleted). – eftshift0 Nov 30 '20 at 16:32
  • @isherwood Yes, That worked. Thank you.. – Kelum Nov 30 '20 at 17:18
  • @eftshift0 Thanks for replying. Got an idea from your answer also. – Kelum Nov 30 '20 at 17:19

0 Answers0