Cannot ignore class ans wsdl files in SourceTree

I have bunch of .class and .wsdl files which simple are not ignored by SourceTree - ignore command in the drop down menu is not active

gitignore.png

My .gitignore file looks like

#
# Default excludes
#

# Binaries
*.7z
*.dmg
*.gz
*.iso
*.jar
*.rar
*.tar
*.zip
*.war
*.ear
*.sar
*.class

# Maven 
target/

# IntelliJ project files 
*.iml
*.iws
*.ipr
.idea/

# Unknown
**/jaxws/*
**/wsdl/*

Any clue what is going on?

1 comment

It looks like the icon is yellow. That means the file has already been committed, which is why you can't ignore it. Untracked files have a purple icon with a question mark.

 

This might help: https://stackoverflow.com/questions/7527982/applying-gitignore-to-committed-files

OK, so I have done 

git ls-files -ci --exclude-standard

related files were on the list so I have did

git ls-files -ci --exclude-standard -z | xargs -0 git rm --cached

and those "yellow" icon files were moved to Staged Files window instead removing them to be tracked.

Any clue on that?

Comment

Log in or Sign up to comment
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Brian Ganninger
Published Jan 23, 2018 in Sourcetree

Tip from the team: workflow and keyboard shortcuts

Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...

649 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you