typos
typos copied to clipboard
Automatically fix all the typos in typos workflow
I hope is there any way in which I can automatically fix all the errors pointed out by the typos workflow run.
I've seen other Actions that fix PRs or master, so this is inline with them. Personally, I've not quite understood them though
- If you squash merge or have a single-commit, then the workflow can just squash. Otherwise, you wouldn't want it to squash and it adds noise to your history
- I guess the user has to always do a force-push (and not even with lease) and have the spell checker run again if they make an update to a PR?
In the mean time, a workaround is to have everyone use the pre-commit
@epage, Can you provide me with a sample format that can skip files during typos
workflow run ?
Something like this
if I want to skip filename.json and Foldername during the typos
workflow run?
with:
files: ./filename.json
./FolderName/
isolated : true
Please start a Discussion or an Issue for a support question so we can keep the conversation on issues more focused.
Sorry, @epage for closing this issue! and asking so many doubts 😅.
Thank you for such a nice tool! Would be great to have ability to fix while using GitHub actions. If you add a flag to configuration so it pass write
it solve the issue :).
How hard is it?
What do you think about compile to wasm
so typo
can be used from node.js
?
If you add a flag to configuration so it pass write it solve the issue :).
Could you clarify what you mean?
What do you think about compile to wasm so typo can be used from node.js?
I'd be willing to take a contribution along those lines. I've not messed with wasm workflows or node.js integration yet and don't have the time at the moment,
Could you clarify what you mean?
Right now when I want to fix typos in source code I have two variants using cli
:
- read the message and do it myself;
- use a flag
--write-changes
and lettypos
fix it;
typos --write-changes
I want to have autofix for Github Actions, so when it find fixes, it make changes and does the commit stuff. Something like https://github.com/EndBug/add-and-commit/ but for typos
.
Could you please tell me what exit code 2
mean?

I'm trying to setup github actions to autofix typos using cli
version.
Sorry for the delay. exit code 1 is a processing error while exit code 2 means a typo was found. We also use a couple more exit codes for various cases.
I want to have autofix for Github Actions, so when it find fixes, it make changes and does the commit stuff. Something like https://github.com/EndBug/add-and-commit/ but for
typos
.
I've implemented auto-fix in my reuseable workflow. You can check the code at:
https://github.com/kdeldycke/workflows/blob/b3ca0119417ab717b6af9271e06448c583024618/.github/workflows/docs.yaml#L23-L51