tbroadley / github-spellcheck-cli

Check a GitHub repository for spelling mistakes and automatically create a pull request :pen:
MIT License
135 stars 14 forks source link

Does it work with ubuntu? (no files seems to be considered) #90

Open andife opened 4 years ago

andife commented 4 years ago

Hello,

I tried to use the package in two different ways and I was not able to get some files processed. a) Is my filter wrong? b) Does it work with linux?

1)

(base) andi@pc1:~/work/github-spellcheck-cli$ node index.js -e "ipynb, txt, md, rst, py" -r bokeh/bokeh
You don't have push access to bokeh/bokeh.
Forking bokeh/bokeh or retrieving your existing fork...
Fork of bokeh/bokeh now exists at andife/bokeh.
Making sure the directory for andife/bokeh doesn't already exist...
Creating a directory...
Cloning andife/bokeh into the directory...
Fetching the latest on the branch 'main' from the parent repository...

Merging the latest from the parent repository into 'main'...
Getting the last commit from the branch 'main'...
Resetting local repository...
Getting a list of files in the working tree...
Filtering the list to only include files with extensions 'ipynb, txt, md, rst, py'...
Spell-checking the remaining files...
[========================================] 100% | ETA: 0s | 0/0
No corrections added.
Deleting andife/bokeh...
Exiting...

=> I seems that no files are considered?

(base) andi@pc1:~/work/github-spellcheck-cli$ github-spellcheck --no-pr -e "rst, ipynb" -t XXX -r bokeh/bokeh
[@octokit/rest] `const Octokit = require("@octokit/rest")` is deprecated. Use `const { Octokit } = require("@octokit/rest")` instead
You don't have push access to bokeh/bokeh.
Forking bokeh/bokeh or retrieving your existing fork...
[@octokit/rest] `const Octokit = require("@octokit/rest")` is deprecated. Use `const { Octokit } = require("@octokit/rest")` instead
Fork of bokeh/bokeh now exists at andife/bokeh.
Making sure the directory for andife/bokeh doesn't already exist...
Creating a directory...
Cloning andife/bokeh into the directory...
Fetching the latest on the branch 'main' from the parent repository...
Merging the latest from the parent repository into 'main'...
Getting the last commit from the branch 'main'...
Resetting local repository...
Getting a list of files in the working tree...
Filtering the list to only include files with extensions 'rst, ipynb'...
Spell-checking the remaining files...
[========================================] 100% | ETA: 0s | 0/0
No corrections added.
Deleting andife/bokeh...
[@octokit/rest] `const Octokit = require("@octokit/rest")` is deprecated. Use `const { Octokit } = require("@octokit/rest")` instead
Exiting...

=> It seems that no files are considered?

Is there a way to get a verbose output?

Thank you

Andreas

tbroadley commented 4 years ago

Hey, thanks for filing an issue! First, -e doesn't take a comma-separated list of extensions, but a space-separated list (e.g. -e ipynb txt md rst py).

However there is a bug here. I've noticed it too in the past. I think it's related to https://github.com/atom/node-spellchecker/issues/54. It looks like someone put up a PR to fix this but it hasn't been accepted: https://github.com/atom/node-spellchecker/pull/69 I might look into forking node-spellchecker and publishing a version that contains that fix.

In the meantime, based on https://github.com/atom/spell-check/issues/129, one workaround is to add LANG=en_US.UTF-8 before node index.js or github-spellcheck in the command you're running.

And no, currently there's no way to get verbose output from this tool.