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

Makefile: add make help command that describes goals #8411

Merged
merged 1 commit into from
Jan 22, 2024

Conversation

guggero
Copy link
Collaborator

@guggero guggero commented Jan 22, 2024

This commit adds a description to each make goal that is printed when make help is run.
Idea borrowed from btcsuite/btcd#2107.

Generated output:

$ make help
 Listing commands:
  android                Build mobile RPC stubs and project template for Android
  apple                  Build mobile RPC stubs and project template for iOS and macOS
  build                  Build lnd and lncli binaries, place them in project directory
  build-itest            Build integration test binaries, place them in itest directory
  build-itest-race       Build integration test binaries in race detector mode, place them in itest directory
  check                  Run unit and integration tests
  clean-mobile           Remove all generated mobile files
  clean                  Remove all generated files
  docker-release         Same as release but within a docker container to support reproducible builds on BSD/MacOS platforms
  flakehunter-parallel   Run the integration tests continuously until one fails, running up to ITEST_PARALLELISM test tranches in parallel (default 4)
  flakehunter            Run the integration tests continuously until one fails
  flake-unit             Run the unit tests continuously until one fails
  fmt-check              Make sure source code is formatted and imports are correct
  fmt                    Format source code and fix imports
  fuzz                   Run the fuzzing tests
  help                   List all available make targets with their descriptions
  install                Build and install lnd and lncli binaries, place them in $GOPATH/bin
  ios                    Build mobile RPC stubs and project template for iOS
  itest                  Build and run integration tests
  itest-clean            Kill all running itest processes
  itest-only             Only run integration tests without re-building binaries
  itest-parallel         Build and run integration tests in parallel mode, running up to ITEST_PARALLELISM test tranches in parallel (default 4)
  itest-race             Build and run integration tests in race detector mode
  lint                   Run static code analysis
  list                   List all available make targets
  macos                  Build mobile RPC stubs and project template for macOS
  mobile                 Build mobile RPC stubs and project templates for iOS and Android
  mobile-rpc             Compile mobile RPC stubs from the protobuf definitions
  release                Build the full set of reproducible release binaries for all supported platforms
  release-install        Build and install lnd and lncli release binaries, place them in $GOPATH/bin
  rpc-check              Make sure protobuf definitions are up to date
  rpc                    Compile protobuf definitions and generate REST proxy stubs
  rpc-format             Format protobuf definition files
  rpc-js-compile         Compile protobuf definitions and generate JSON/WASM stubs
  sample-conf-check      Make sure default values in the sample-lnd.conf file are set correctly
  sqlc-check             Make sure sql models and queries are up to date
  sqlc                   Generate sql models and queries in Go
  tidy-module-check      Make sure all modules are up to date
  tidy-module            Run `go mod` tidy for all modules
  unit-bench             Run benchmark tests
  unit-cover             Run unit tests in coverage mode
  unit-debug             Run unit tests with debug log output enabled
  unit-module            Run unit tests of all submodules
  unit-race              Run unit tests in race detector mode
  unit                   Run unit tests
  vendor                 Create a vendor directory with all dependencies

This commit adds a description to each make goal that is printed when
`make help` is run.
Idea borrowed from btcsuite/btcd#2107.
@guggero guggero added documentation Documentation changes that do not affect code behaviour docs inline documentation documentation within the code no-itest no-changelog labels Jan 22, 2024
Copy link
Contributor

coderabbitai bot commented Jan 22, 2024

Important

Auto Review Skipped

Auto reviews are limited to the following labels: llm-review. Please add one of these labels to enable auto reviews.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository.

To trigger a single review, invoke the @coderabbitai review command.

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share

Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit-tests for this file.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit tests for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository from git and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

Copy link
Collaborator

@ellemouton ellemouton left a comment

Choose a reason for hiding this comment

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

tACK, LGTM! Very nice 🔍

@guggero guggero merged commit e1259cd into lightningnetwork:master Jan 22, 2024
18 of 19 checks passed
@guggero guggero deleted the make-help branch January 22, 2024 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs documentation Documentation changes that do not affect code behaviour inline documentation documentation within the code no-changelog no-itest
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants