Skip to content

Commit

Permalink
docs: more explanation in the readme
Browse files Browse the repository at this point in the history
  • Loading branch information
hraban committed Apr 18, 2024
1 parent 8edd9db commit 09c0b4b
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.org
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,24 @@ jobs:
- name: "nocommit checker"
uses: nobssoftware/nocommit@v1
#+end_src

** NOCOMMIT

Use this for code you don’t even wish to commit. Anything you never want to see on CI, e.g. temporary credentials, local dev setup, etc.

You can add a git =pre-commit= hook to help you catch any accidental commits, see the [[pre-commit]] file.

Example:

#+begin_src c
static int
mul(int x, int y)
{
printf("debug: mul(%d, %d) called", x, y) // NOCOMMIT
return x * y;
}
#+end_src

** NOMERGE

Same as NOCOMMIT, but it won’t trip up that =pre-commit= hook. Use this for changes you want to push to CI, but not merge to master. This is useful for debugging CI or for testing something on deployed infra.

0 comments on commit 09c0b4b

Please sign in to comment.