From 09c0b4b7829f642eb0efbd4a1292ac2fd941ef36 Mon Sep 17 00:00:00 2001 From: Hraban Luyat Date: Thu, 18 Apr 2024 02:38:58 -0400 Subject: [PATCH] docs: more explanation in the readme --- README.org | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/README.org b/README.org index 94a0014..572fe23 100644 --- a/README.org +++ b/README.org @@ -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.