Skip to content

Support file paths in CLI positional argument #16

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

Merged
merged 3 commits into from
Aug 21, 2024

Conversation

2bndy5
Copy link
Collaborator

@2bndy5 2bndy5 commented Aug 21, 2024

resolves #8

Copy link

codecov bot commented Aug 21, 2024

Codecov Report

Attention: Patch coverage is 97.72727% with 5 lines in your changes missing coverage. Please review.

Project coverage is 88.25%. Comparing base (c7ae257) to head (b2321aa).
Report is 1 commits behind head on main.

Files Patch % Lines
cpp-linter-lib/src/cli/structs.rs 98.11% 2 Missing ⚠️
cpp-linter-lib/src/run.rs 93.75% 2 Missing ⚠️
cpp-linter-lib/src/rest_api/github_api.rs 87.50% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #16      +/-   ##
==========================================
+ Coverage   87.22%   88.25%   +1.02%     
==========================================
  Files          11       12       +1     
  Lines        2169     2230      +61     
==========================================
+ Hits         1892     1968      +76     
+ Misses        277      262      -15     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines +123 to +125
if env::var("PRE_COMMIT").is_ok_and(|v| v == "1") {
return (checks_failed > 1) as i32;
}
Copy link
Collaborator Author

@2bndy5 2bndy5 Aug 21, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have to test this externally. pre-commit does not support installing hooks from a monorepo (via git source). Furthermore, their rust language support uses a very outdated paradigm for building binary executables from rust code. (see pre-commit/pre-commit#3278)

To test this, I need to start publishing python builds to test-pypi.org, and install the hook from there. So, pre-commit support is on the back burner again...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reminder

We can install with pip from GitHub source using:

pip install git+https://github.com/cpp-linter/cpp_linter_rs.git#subdirectory=cpp-linter-py

@2bndy5 2bndy5 changed the title Allow files position args Support file paths in CLI position argument Aug 21, 2024
@2bndy5 2bndy5 changed the title Support file paths in CLI position argument Support file paths in CLI positional argument Aug 21, 2024
@2bndy5 2bndy5 merged commit 9dde123 into main Aug 21, 2024
60 checks passed
@2bndy5 2bndy5 deleted the allow-files-position-args branch August 21, 2024 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

accept a list of positional CLI args
1 participant