Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't understand -i #40

Closed
yegor256 opened this issue Aug 4, 2023 · 3 comments
Closed

Doesn't understand -i #40

yegor256 opened this issue Aug 4, 2023 · 3 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@yegor256
Copy link
Owner

yegor256 commented Aug 4, 2023

$ bibcop -i --fix a.bib
Cannot open file: -i
@yegor256 yegor256 added bug Something isn't working help wanted Extra attention is needed labels Aug 4, 2023
@oylenshpeegul
Copy link

It looks like bibcop.pl accepts anything that doesn't start with two dashes as a file name

https://github.com/yegor256/bibcop/blob/master/bibcop.pl#L834

Perhaps change it to one dash?

my ($file) = grep { not($_ =~ /^-.*$/) } @ARGV;

@yegor256
Copy link
Owner Author

yegor256 commented Aug 9, 2023

@oylenshpeegul indeed, the fix is simple, but we should also write a unit test for it. If you can make a pull request, I will appreciate!

oylenshpeegul pushed a commit to oylenshpeegul/bibcop that referenced this issue Aug 9, 2023
@yegor256
Copy link
Owner Author

yegor256 commented Aug 9, 2023

fixed

@yegor256 yegor256 closed this as completed Aug 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants