-
Notifications
You must be signed in to change notification settings - Fork 432
Add basic CLAUDE.md file
#4352
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
base: main
Are you sure you want to change the base?
Add basic CLAUDE.md file
#4352
Conversation
|
👋 Thanks for assigning @joostjager as a reviewer! |
|
@joostjager @TheBlueMatt Anything else that you deem worthy to add? |
cd6ac32 to
ecf8c05
Compare
TheBlueMatt
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing comes to mind, we can definitely iterate on it.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4352 +/- ##
=======================================
Coverage 86.08% 86.09%
=======================================
Files 156 156
Lines 102428 102428
Branches 102428 102428
=======================================
+ Hits 88179 88181 +2
+ Misses 11754 11753 -1
+ Partials 2495 2494 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
||
| ## Development Rules | ||
|
|
||
| - Always ensure tests pass before committing. To this end, you should run the test suite via `./ci/ci-tests.sh`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this is always practical when working on draft branches?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably it is possible to specify it in a way that we can ask claude to run the CI checks? But do not assume to run it always?
On mine I have
### When to run CI checks
- When explicitly asked (e.g., "run CI", "check CI", "verify commits")
- Before creating a PR (if requested)
- After fixing CI-related issues
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this is always practical when working on draft branches?
Hmm, but ensuring tests pass before committing is kinda important, no? And in my experience it will allow Claude to catch a lot of bugs? Any suggestion for a good replacement, maybe cargo test, which should be considerably faster, even if it doesn't catch everything?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps it can be:
Always run tests before committing, unless the commit message contains "WIP" or "draft" (case-insensitive).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps it can be:
Always run tests before committing, unless the commit message contains "WIP" or "draft" (case-insensitive).
That seems tailored to your specific workflow. Maybe you want to put that in your .claude.local.md override instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can try to override the testing behavior.
It isn't my workflow to prepend the commit titles, but I could adopt that as the workflow potentially.
Let's go with what you have and see how it works out, and adapt if necessary
CLAUDE.md
Outdated
| - Always ensure tests pass before committing. To this end, you should run the test suite via `./ci/ci-tests.sh`. | ||
| - Run `cargo +1.75.0 fmt --all` after every code change | ||
| - Never add new dependencies unless explicitly requested | ||
| - Please always disclose the use of any AI tools in commit messages and PR descriptions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specify how this should be disclosed, maybe a standard sentence to add for consistency?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should consistently require it disclose itself as HAL 9000 😂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specify how this should be disclosed, maybe a standard sentence to add for consistency?
I don't know - do you have a specific example in mind? Otherwise above instructions worked pretty well for me so far.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe just put what it produced for you in here? Or just specifiy that it should use co-authored-by
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe just put what it produced for you in here? Or just specifiy that it should use co-authored-by
Done:
diff --git a/CLAUDE.md b/CLAUDE.md
index 51bbe1d90..611322c12 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -14,4 +14,4 @@ See [README.md](README.md) for the workspace layout and [ARCH.md](ARCH.md) for s
- Run `cargo +1.75.0 fmt --all` after every code change
- Never add new dependencies unless explicitly requested
-- Please always disclose the use of any AI tools in commit messages and PR descriptions
+- Please always disclose the use of any AI tools in commit messages and PR descriptions using a `Co-Authored-By:` line.
- When adding new `.rs` files, please ensure to always add the licensing header as found, e.g., in `lightning/src/lib.rs` and other files.ecf8c05 to
d987453
Compare
We add a basic `CLAUDE.md` file pointing it to some workspace specifics (in particular running `cargo fmt` on 1.75.0 MSRV, and using `./ci/ci-tests.sh` to run tests). Signed-off-by: Elias Rohrer <dev@tnull.de>
d987453 to
8b1386c
Compare
We add a basic
CLAUDE.mdfile pointing it to some workspace specifics (in particular runningcargo fmton 1.75.0 MSRV, and using./ci/ci-tests.shto run tests).