unused-code / unused

A tool to identify potentially unused code.
https://unused.codes
MIT License
283 stars 11 forks source link

Ignore is not working #36

Closed amadeu01 closed 2 years ago

amadeu01 commented 3 years ago

Attempt to use --ignore path_folder not working

➜ unused --version
unused-rs 0.1.0
joshuaclayton commented 3 years ago

@amadeu01 can you follow the upgrade instructions and report back if this is still an issue?

amadeu01 commented 3 years ago

I'll try!

joshuaclayton commented 3 years ago

@amadeu01 any luck?

joshuaclayton commented 2 years ago

@amadeu01 I'm closing this due to inactivity; if you have a chance to give this another try, please let me know how it goes!

amadeu01 commented 2 years ago

@joshuaclayton I tried to run again

unused --only-filetypes=rb,json,js,jsx --ignore='sorbet/**/**'
unused --only-filetypes=rb,json,js,jsx --ignore='sorbet/**/*'
unused --only-filetypes=rb,json,js,jsx --ignore='sorbet/**'
unused --only-filetypes=rb,json,js,jsx --ignore='sorbet/*'
unused --only-filetypes=rb,json,js,jsx --ignore='sorbet'

All of them give the following result.

yieldall
   Reason: Only one occurrence exists
   Defined in: (1)
   * /Users/amadeucavalcante/.asdf/installs/ruby/2.6.6/lib/ruby/gems/2.6.0/gems/yard-0.9.20/lib/yard/templates/template.rb
   Found in: (1)
   * sorbet/rbi/gems/yard@0.9.20.rbi
amadeu01 commented 2 years ago

@joshuaclayton do you have any clue why it is not ignoring some paths? I'm doing something wrong, it does not understand wildcard?