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
Git submodules as wordlist? #128
Comments
hi @zfauser do you have a public repository which demonstrating this? My experience with submodules is limited and not full fond memories. |
Hey, unfortunately I do not and it's not possible for me to make one of the existing repos public, sorry. What we are essentially doing though is writing code documentation which involves many things that are not recognized in the dictionary (I.e. 'const') and instead of everyone individually discovering each of these I figured having one document we all collaborated on would make sense. Do you know if this would be possible or maybe just a different way of doing it? |
Hi @zfauser I have been thinking about this problem and think I have foundation a solution. It does require some code changes. More information will follow... |
Hi @zfauser Okay, here goes: Using the name: Spellcheck Action
on: push
jobs:
build:
name: Spellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: rojopolis/spellcheck-github-actions@0.29.0
name: Spellcheck
with:
config_path: config/spellcheck.yml # put path to configuration file here So you can place it in a directory, which you handle as a git submodule. The above is the file controlling your workflow/action located in: REF: documentation Inside the configuration of the, you can set the path of the custom dictionary / wordlist. This is the file pointed to in the above configuration. matrix:
- name: Markdown
aspell:
lang: en
dictionary:
wordlists:
- config/wordlist.txt
encoding: utf-8
pipeline:
- pyspelling.filters.markdown:
- pyspelling.filters.html:
comments: false
ignores:
- code
- pre
sources:
- '**/*.md'
default_encoding: utf-8 REF: documentation So you can place the wordlist in a directory, which you handle as a git submodule. Please let me know if this is unclear or does not work. I do not work with git submodules, so I do not have a working example, all of the above is just deducted from the documentation and is untested in git submodule context. I will make some updates to the documentation to emphasize the flexibility taken advantage of to meet your request. |
I am might have run into an issue with the above approach, I will need to do some more testing... |
Sorry about that, I am tired. I forgot to tell my local test to point to the moved configuration. I have a shell wrapper on the Docker image, which I call like so: $ INPUT_CONFIG_PATH=".github/spellcheck.yml" spellchecker.sh Forgot to set the environment variable, which is how the action configuration on GitHub communicates with the entry point in the Docker image. |
Btw: you can see an example configuration here. I believe you just have to isolate your configuration file(s) in a module you control as a git submodule and make the adjustments, then it should work. |
How would you use a git submodule as a wordlist, when I try to use it currently It always just returns that the wordlist could not be found.
The text was updated successfully, but these errors were encountered: