Skip to content
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

make: split out clippy and format targets #528

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bradjc
Copy link
Contributor

@bradjc bradjc commented Jan 11, 2024

Running the tests take a while and sometimes it is helpful to just be able to run clippy quickly.

Running the tests take a while and sometimes it is helpful to just be
able to run clippy quickly.
@@ -33,6 +33,8 @@ usage:
@echo "Run 'make flash-<board> EXAMPLE=<>' to flash EXAMPLE to a tockloader-supported board."
@echo "Run 'make qemu-example EXAMPLE=<>' to run EXAMPLE in QEMU"
@echo "Run 'make test' to test any local changes you have made"
@echo "Run 'make format' to format any local changes you have made"
Copy link
Collaborator

Choose a reason for hiding this comment

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

This isn't accurate -- make format checks formatting, but does not change formatting.

I don't want make test to make edits, so we either need to just update the documentation, or have separate actions for "format the code" and "check formatting".


.PHONY: format
format:
LIBTOCK_PLATFORM=nrf52 cargo fmt --all -- --check
Copy link
Collaborator

Choose a reason for hiding this comment

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

The clippy and format actions need to depend on toolchain. In retrospect, test should explicitly depend on toolchain -- it currently transitively depends on it through examples.

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.

None yet

3 participants