From 7b68e189572b3e5236471b327fb50ae98a4a6c9e Mon Sep 17 00:00:00 2001 From: Oleksandr Bezdieniezhnykh Date: Sun, 12 Apr 2026 05:18:39 +0300 Subject: [PATCH] Update coding rules and CI configuration - Added a new guideline to never suppress errors silently in coding rules. - Introduced specifications for command files, including markdown format and kebab-case filenames. - Updated Git workflow to require explicit user permission before pushing or merging changes. - Adjusted Woodpecker CI configuration to trigger on push events. Made-with: Cursor --- .cursor/rules/coderule.mdc | 1 + .cursor/rules/cursor-meta.mdc | 4 ++++ .cursor/rules/git-workflow.mdc | 1 + .woodpecker/build-arm.yml | 1 + 4 files changed, 7 insertions(+) diff --git a/.cursor/rules/coderule.mdc b/.cursor/rules/coderule.mdc index 4044db0..a208ac5 100644 --- a/.cursor/rules/coderule.mdc +++ b/.cursor/rules/coderule.mdc @@ -9,6 +9,7 @@ alwaysApply: true - Logic specific to a platform, variant, or environment belongs in the class that owns that variant, not in the general coordinator. Passing a dependency through is preferable to leaking variant-specific concepts into shared code. - Only use static methods for pure, self-contained computations (constants, simple math, stateless lookups). If a static method involves resource access, side effects, OS interaction, or logic that varies across subclasses or environments — use an instance method or factory class instead. Before implementing a non-trivial static method, ask the user. - Generate concise code +- Never suppress errors silently — no `2>/dev/null`, empty `catch` blocks, bare `except: pass`, or discarded error returns. These hide the information you need most when something breaks. If an error is truly safe to ignore, log it or comment why. - Do not put comments in the code, except in tests: every test must use the Arrange / Act / Assert pattern with language-appropriate comment syntax (`# Arrange` for Python, `// Arrange` for C#/Rust/JS/TS). Omit any section that is not needed (e.g. if there is no setup, skip Arrange; if act and assert are the same line, keep only Assert) - Do not put logs unless it is an exception, or was asked specifically - Do not put code annotations unless it was asked specifically diff --git a/.cursor/rules/cursor-meta.mdc b/.cursor/rules/cursor-meta.mdc index 8cc663a..5f607ab 100644 --- a/.cursor/rules/cursor-meta.mdc +++ b/.cursor/rules/cursor-meta.mdc @@ -14,6 +14,10 @@ globs: [".cursor/**"] - Body under 500 lines; use `references/` directory for overflow content - Templates live under their skill's `templates/` directory +## Command Files (.cursor/commands/) +- Plain markdown, no frontmatter +- Kebab-case filenames + ## Agent Files (.cursor/agents/) - Must have `name` and `description` in frontmatter diff --git a/.cursor/rules/git-workflow.mdc b/.cursor/rules/git-workflow.mdc index b400f89..873a8df 100644 --- a/.cursor/rules/git-workflow.mdc +++ b/.cursor/rules/git-workflow.mdc @@ -7,3 +7,4 @@ alwaysApply: true - Work on the `dev` branch - Commit message format: `[TRACKER-ID-1] [TRACKER-ID-2] Summary of changes` - Commit message total length must not exceed 30 characters +- Do NOT push or merge unless the user explicitly asks you to. Always ask first if there is a need. diff --git a/.woodpecker/build-arm.yml b/.woodpecker/build-arm.yml index 471b5f7..fb170b8 100644 --- a/.woodpecker/build-arm.yml +++ b/.woodpecker/build-arm.yml @@ -1,4 +1,5 @@ when: + event: push branch: [dev, stage, main] labels: