Skip to content

fix(shell): declare the dialect for the sourced contract.config.sh - #240

Open
hyperpolymath wants to merge 1 commit into
mainfrom
fix/shellcheck-shell-directive
Open

fix(shell): declare the dialect for the sourced contract.config.sh#240
hyperpolymath wants to merge 1 commit into
mainfrom
fix/shellcheck-shell-directive

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

shellcheck SC2148 (target shell is unknown) on contract.config.sh.

Deliberately a directive, not a shebang. The file is sourced by tools/check-contract.sh and never executed as its own process, so a shebang would claim an execution model it does not have. # shellcheck shell=bash states the dialect without making that false claim.

Placed on line 2, immediately after the SPDX header, so the estate rule that SPDX must be line 1 still holds — shellcheck directives are honoured anywhere before the first command.

Found by an estate-wide sweep of 5,111 scripts across 375 repos: 85 files lack a shell declaration. Only first-party files were changed — HOL's ATP scripts and the ReScript compiler's own test fixtures were excluded as vendored upstream code, where a shebang would create permanent divergence for a lint warning.

shellcheck SC2148 ('target shell is unknown') on contract.config.sh.

Deliberately a directive, not a shebang. The file is SOURCED by
tools/check-contract.sh and never executed as its own process, so a shebang
would claim an execution model it does not have. '# shellcheck shell=bash'
states the dialect without making that false claim.

Placed on line 2, immediately after the SPDX header, so the estate rule that
SPDX must be line 1 still holds — shellcheck directives are honoured anywhere
before the first command.

Found by an estate-wide sweep of 5,111 scripts across 375 repos: 85 files lack
a shell declaration. Only first-party files were changed; HOL's ATP scripts and
the ReScript compiler's own test fixtures were excluded as vendored upstream
code, where a shebang would create permanent divergence for a lint warning.
@coderabbitai

coderabbitai Bot commented Aug 26, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 658ac256-9de6-482e-ae85-8b9d278f4e3e

📥 Commits

Reviewing files that changed from the base of the PR and between a82cb67 and e76b4d5.

📒 Files selected for processing (1)
  • contract.config.sh

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (3)
  • GitHub Check: Codacy Static Code Analysis
  • GitHub Check: scan / Hypatia Neurosymbolic Analysis
  • GitHub Check: Cargo audit (RustSec advisories)
⚠️ CI failures not shown inline (8)

GitHub Actions: E2E Validation / 0_Cargo build + test (typed-wasm-verify).txt: fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run cargo build --workspace --locked
 �[36;1mcargo build --workspace --locked�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 error: failed to parse lock file at: /home/runner/work/typed-wasm/typed-wasm/Cargo.lock
 Caused by:
   package `wasmparser` is specified twice in the lockfile
 ##[error]Process completed with exit code 101.

GitHub Actions: E2E Validation / Cargo build + test (typed-wasm-verify): fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run cargo build --workspace --locked
 �[36;1mcargo build --workspace --locked�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 error: failed to parse lock file at: /home/runner/work/typed-wasm/typed-wasm/Cargo.lock
 Caused by:
   package `wasmparser` is specified twice in the lockfile
 ##[error]Process completed with exit code 101.

GitHub Actions: E2E Validation / 1_Build + E2E (Idris2 + Zig).txt: fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run E2E_BUILD=1 bash tests/e2e.sh
 �[36;1mE2E_BUILD=1 bash tests/e2e.sh�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 �[0;36m=== 1. Spec documents ===�[0m
   �[0;32mPASS�[0m  Level spec document exists and is non-trivial (32177 bytes)
   �[0;31mFAIL�[0m  Missing: LEVEL-STATUS.md
   �[0;32mPASS�[0m  Grammar spec exists (32596 bytes)
 �[0;36m=== 2. Example .twasm files (levels 1-6) ===�[0m
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/01-single-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/02-multi-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/03-ownership-linearity.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/04-ecs-game.twasm
   �[0;32mPASS�[0m  examples/ contains 6 .twasm files (>= 4)
 �[0;36m=== 3. Idris2 ABI files (L1-L10) ===�[0m
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Region.idr (23565 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/TypedAccess.idr (10290 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Pointer.idr (9325 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Levels.idr (14774 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Effects.idr (14156 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Lifetime.idr (11447 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Linear.idr (12956 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Proofs.idr (65715 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/MultiModule.idr (25185 bytes)
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Tropical.idr
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Epistemic.idr
 �[0;36m=== 4. Zig FFI implementation ===�[0m
   �[0;32mPASS�[0m  Zig FFI file exists: ffi/zig/build.zig (5235...

GitHub Actions: E2E Validation / Build + E2E (Idris2 + Zig): fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run E2E_BUILD=1 bash tests/e2e.sh
 �[36;1mE2E_BUILD=1 bash tests/e2e.sh�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 �[0;36m=== 1. Spec documents ===�[0m
   �[0;32mPASS�[0m  Level spec document exists and is non-trivial (32177 bytes)
   �[0;31mFAIL�[0m  Missing: LEVEL-STATUS.md
   �[0;32mPASS�[0m  Grammar spec exists (32596 bytes)
 �[0;36m=== 2. Example .twasm files (levels 1-6) ===�[0m
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/01-single-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/02-multi-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/03-ownership-linearity.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/04-ecs-game.twasm
   �[0;32mPASS�[0m  examples/ contains 6 .twasm files (>= 4)
 �[0;36m=== 3. Idris2 ABI files (L1-L10) ===�[0m
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Region.idr (23565 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/TypedAccess.idr (10290 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Pointer.idr (9325 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Levels.idr (14774 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Effects.idr (14156 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Lifetime.idr (11447 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Linear.idr (12956 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Proofs.idr (65715 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/MultiModule.idr (25185 bytes)
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Tropical.idr
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Epistemic.idr
 �[0;36m=== 4. Zig FFI implementation ===�[0m
   �[0;32mPASS�[0m  Zig FFI file exists: ffi/zig/build.zig (5235...

GitHub Actions: E2E Validation / 2_Smoke test (Node.js AffineScript parser).txt: fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run node tests/aspect/claim-envelope.mjs
 �[36;1mnode tests/aspect/claim-envelope.mjs�[0m
 �[36;1mnode tests/aspect/security-envelope.mjs�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 === 1. ipkg membership matches doc claims ===
   OK    typed-wasm.ipkg lists 23 modules
   OK    Tropical (L11) is in typed-wasm.ipkg
   OK    Epistemic (L12) is in typed-wasm.ipkg
   OK    ROADMAP.adoc L11/L12 claims do not contradict the ipkg
   SKIP  LEVEL-STATUS.md not found — cannot cross-check L11/L12 claim
   OK    README.adoc L11/L12 claims do not contradict the ipkg
 === 2. unsound-pattern badge truthfulness ===
   OK    all 24 .idr files: 0 non-comment occurrences of banned patterns
   OK    README badge claims believe_me=0 (matches reality)
 === 3. Rust crate constants match README spec ===
   OK    OwnershipKind::Unrestricted = 0 (matches README spec)
   OK    OwnershipKind::Linear = 1 (matches README spec)
   OK    OwnershipKind::SharedBorrow = 2 (matches README spec)
   OK    OwnershipKind::ExclBorrow = 3 (matches README spec)
   OK    OWNERSHIP_SECTION_NAME = "typedwasm.ownership" (matches doc claims)
 === 4. CI + Justfile path references are real ===
   OK    Justfile -> tests/parser/ParserTests.mjs (build output; source exists)
   OK    Justfile -> tests/contracts/airborne-step-state-contract.mjs
   OK    Justfile -> tests/e2e/e2e-driver.mjs
   OK    Justfile -> tests/levels/L1.mjs
   OK    Justfile -> tests/levels/L2.mjs
   OK    Justfile -> tests/levels/L3.mjs
   OK    Justfile -> tests/levels/L4.mjs
   OK    Justfile -> tests/levels/L5.mjs
   OK    Justfile -> tests/levels/L6.mjs
   OK    Justfile -> tests/levels/L7.mjs
   OK    Justfile -> tests/levels/L8.mjs
   OK    Justfile -> tests/levels/L9.mjs
   OK    Justfile -> tests/levels/L10.mjs
   OK    Justfile -> tests/smoke/e2e-smoke.mjs
   OK    Justfile -> tests/aspect/claim-envelope.mjs
   OK    Justfile -> tests/aspect/security-envelope.mjs
   OK    Justfile -> tests/property/property_test.mjs
   O...

GitHub Actions: E2E Validation / Smoke test (Node.js AffineScript parser): fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run node tests/aspect/claim-envelope.mjs
 �[36;1mnode tests/aspect/claim-envelope.mjs�[0m
 �[36;1mnode tests/aspect/security-envelope.mjs�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 === 1. ipkg membership matches doc claims ===
   OK    typed-wasm.ipkg lists 23 modules
   OK    Tropical (L11) is in typed-wasm.ipkg
   OK    Epistemic (L12) is in typed-wasm.ipkg
   OK    ROADMAP.adoc L11/L12 claims do not contradict the ipkg
   SKIP  LEVEL-STATUS.md not found — cannot cross-check L11/L12 claim
   OK    README.adoc L11/L12 claims do not contradict the ipkg
 === 2. unsound-pattern badge truthfulness ===
   OK    all 24 .idr files: 0 non-comment occurrences of banned patterns
   OK    README badge claims believe_me=0 (matches reality)
 === 3. Rust crate constants match README spec ===
   OK    OwnershipKind::Unrestricted = 0 (matches README spec)
   OK    OwnershipKind::Linear = 1 (matches README spec)
   OK    OwnershipKind::SharedBorrow = 2 (matches README spec)
   OK    OwnershipKind::ExclBorrow = 3 (matches README spec)
   OK    OWNERSHIP_SECTION_NAME = "typedwasm.ownership" (matches doc claims)
 === 4. CI + Justfile path references are real ===
   OK    Justfile -> tests/parser/ParserTests.mjs (build output; source exists)
   OK    Justfile -> tests/contracts/airborne-step-state-contract.mjs
   OK    Justfile -> tests/e2e/e2e-driver.mjs
   OK    Justfile -> tests/levels/L1.mjs
   OK    Justfile -> tests/levels/L2.mjs
   OK    Justfile -> tests/levels/L3.mjs
   OK    Justfile -> tests/levels/L4.mjs
   OK    Justfile -> tests/levels/L5.mjs
   OK    Justfile -> tests/levels/L6.mjs
   OK    Justfile -> tests/levels/L7.mjs
   OK    Justfile -> tests/levels/L8.mjs
   OK    Justfile -> tests/levels/L9.mjs
   OK    Justfile -> tests/levels/L10.mjs
   OK    Justfile -> tests/smoke/e2e-smoke.mjs
   OK    Justfile -> tests/aspect/claim-envelope.mjs
   OK    Justfile -> tests/aspect/security-envelope.mjs
   OK    Justfile -> tests/property/property_test.mjs
   O...

GitHub Actions: E2E Validation / 3_Structural E2E (no-build).txt: fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run E2E_BUILD=0 bash tests/e2e.sh
 �[36;1mE2E_BUILD=0 bash tests/e2e.sh�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 �[0;36m=== 1. Spec documents ===�[0m
   �[0;32mPASS�[0m  Level spec document exists and is non-trivial (32177 bytes)
   �[0;31mFAIL�[0m  Missing: LEVEL-STATUS.md
   �[0;32mPASS�[0m  Grammar spec exists (32596 bytes)
 �[0;36m=== 2. Example .twasm files (levels 1-6) ===�[0m
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/01-single-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/02-multi-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/03-ownership-linearity.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/04-ecs-game.twasm
   �[0;32mPASS�[0m  examples/ contains 6 .twasm files (>= 4)
 �[0;36m=== 3. Idris2 ABI files (L1-L10) ===�[0m
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Region.idr (23565 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/TypedAccess.idr (10290 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Pointer.idr (9325 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Levels.idr (14774 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Effects.idr (14156 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Lifetime.idr (11447 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Linear.idr (12956 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Proofs.idr (65715 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/MultiModule.idr (25185 bytes)
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Tropical.idr
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Epistemic.idr
 �[0;36m=== 4. Zig FFI implementation ===�[0m
   �[0;32mPASS�[0m  Zig FFI file exists: ffi/zig/build.zig (5235...

GitHub Actions: E2E Validation / Structural E2E (no-build): fix(shell): declare the dialect for the sourced contract.config.sh

Conclusion: failure

View job details

##[group]Run E2E_BUILD=0 bash tests/e2e.sh
 �[36;1mE2E_BUILD=0 bash tests/e2e.sh�[0m
 shell: /usr/bin/bash -e {0}
 ##[endgroup]
 �[0;36m=== 1. Spec documents ===�[0m
   �[0;32mPASS�[0m  Level spec document exists and is non-trivial (32177 bytes)
   �[0;31mFAIL�[0m  Missing: LEVEL-STATUS.md
   �[0;32mPASS�[0m  Grammar spec exists (32596 bytes)
 �[0;36m=== 2. Example .twasm files (levels 1-6) ===�[0m
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/01-single-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/02-multi-module.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/03-ownership-linearity.twasm
   �[0;32mPASS�[0m  Example file exists and is non-empty: examples/04-ecs-game.twasm
   �[0;32mPASS�[0m  examples/ contains 6 .twasm files (>= 4)
 �[0;36m=== 3. Idris2 ABI files (L1-L10) ===�[0m
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Region.idr (23565 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/TypedAccess.idr (10290 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Pointer.idr (9325 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Levels.idr (14774 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Effects.idr (14156 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Lifetime.idr (11447 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Linear.idr (12956 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/Proofs.idr (65715 bytes)
   �[0;32mPASS�[0m  Idris2 ABI file exists: src/abi/TypedWasm/ABI/MultiModule.idr (25185 bytes)
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Tropical.idr
   �[0;32mPASS�[0m  Draft Idris2 file exists (L11/L12): src/abi/TypedWasm/ABI/Epistemic.idr
 �[0;36m=== 4. Zig FFI implementation ===�[0m
   �[0;32mPASS�[0m  Zig FFI file exists: ffi/zig/build.zig (5235...
🔇 Additional comments (1)
contract.config.sh (1)

2-2: LGTM!


📝 Walkthrough

Summary by CodeRabbit

  • Chores
    • Improved script compatibility and static analysis by explicitly identifying the Bash shell dialect.

Walkthrough

contract.config.sh now declares Bash as its shell dialect for ShellCheck.

Changes

ShellCheck configuration

Layer / File(s) Summary
Declare Bash dialect
contract.config.sh
Adds a ShellCheck directive that identifies the script as Bash.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk: ⚪ Minimal · up to e76b4

This localized change only declares the shell dialect for linting and does not alter runtime behavior; no actionable merge-blocking risk remains beyond normal checks and review.

Poem

A rabbit checks the Bash-bound line
ShellCheck reads the dialect sign
One small directive joins the code
The script now bears its proper mode
Carrots compile in neat array

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description clearly explains the change, its rationale, placement, and scope. It does not provide the required RSR checklist status or a Testing section, so the template requirements are incomplet… Add the required template sections. Mark each applicable RSR Quality Checklist item, and document the commands or checks used to test the change. Add Screenshots or terminal output if applicable.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely identifies the Bash dialect declaration added to the sourced contract.config.sh file.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description clearly explains the change, its rationale, placement, and scope. It does not provide the required RSR checklist status or a Testing section, so the template requirements are incomplete.

Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files.

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@sonarqubecloud

Copy link
Copy Markdown

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

AI Reviewer: first review requested successfully. AI can make mistakes. Always validate suggestions.

Run reviewer

TIP This summary will be updated as you push new changes.

@codacy-production codacy-production Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull Request Overview

This PR addresses the ShellCheck warning SC2148 in contract.config.sh by adding a shell directive. By using # shellcheck shell=bash instead of a shebang, the script is correctly identified as a sourced file rather than an executable. The directive is placed appropriately after the SPDX license header to comply with project standards. Codacy analysis confirms the PR is up to standards with no new quality or complexity issues.

Test suggestions

  • Verify that ShellCheck no longer reports SC2148 for contract.config.sh.
  • Ensure the script remains valid for sourcing by tools/check-contract.sh.
Prompt proposal for missing tests
Consider implementing these tests if applicable:
1. Verify that ShellCheck no longer reports SC2148 for contract.config.sh.
2. Ensure the script remains valid for sourcing by tools/check-contract.sh.

TIP Improve review quality by adding custom instructions
TIP How was this review? Give us feedback

@gitar-bot

gitar-bot Bot commented Aug 26, 2026

Copy link
Copy Markdown

Important

You are using the Gitar free plan. Upgrade to unlock code review, CI analysis, auto-apply, custom automations, and more.

Gitar

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.

1 participant