Comments (5)
FYI right now I do codespell.py ... | tee /dev/tty | wc -l | xargs test 0 -eq
to get it to print the result and give a meaningful error code.
from codespell.
yeah... we should return an error code. Anyone up to send a patch for this?
from codespell.
Sure :)
from codespell.
Sorry for commenting on an old issue: I would be interested in two examples, showing:
- How to call codespell from python (script or notebook) and
- How to ceck the return code from that script.
If you happen to have such an example it would be greatly appreciated, otherwise I would try how far I can get myself.
EDIT: This file was a good starting point for me:
https://github.com/codespell-project/codespell/blob/master/codespell_lib/tests/test_basic.py
from codespell.
All of the tests do this. Everything is routed through codespell_lib.main
. Historically it has been designed as a command-line utility rather than with user-accessible Python functions in mind, so if you want to use Python functions with reasonable args
/ kwargs
and so forth then it will probably require refactoring.
from codespell.
Related Issues (20)
- question: how to print filename of the file being processed?
- Support namespaced dictionary packages HOT 1
- "Goverment" not regonized in all relevant lines HOT 2
- support ignore for blocks of code HOT 1
- Codespell Not Ignoring Words Properly when Provided in Original Case HOT 1
- release a new version ? HOT 15
- Unable to add inline comments for markdown documents HOT 7
- Splitting multiple 'skip' paths onto indented config file lines behaves differently than when on a single line HOT 4
- Are inline ignores restricted to hash-style comments? HOT 1
- Is it possible to combine a custom dictionary with a builtin dictionary? HOT 1
- pre-commit to remove `Used config files:` noisy output HOT 1
- Python API support HOT 7
- Better control over decoding problems reporting HOT 2
- Codespell inline ignores don't appear to work in Markdown files HOT 3
- assertIn false positivies HOT 9
- Better project description HOT 3
- Tests fail if not 'codespell' installed HOT 5
- I need to ignore "image/png" the contents of the ipynb(python) file / .pre-commit-config.yaml HOT 3
- false positive: unparseable HOT 6
- Unable to Ignore Files Completely Using .codespell.toml Configuration HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from codespell.