8000 Add Destructive Command Guard workflow by wheeljackz · Pull Request #70 · zainfathoni/zainf · GitHub
[go: up one dir, main page]

Skip to content

Add Destructive Command Guard workflow - #70

Closed
wheeljackz wants to merge 3 commits into
mainfrom
wheeljack/setup-destructive-command-guard
Closed

wheeljackz wants to merge 3 commits into
mainfrom
wheeljack/setup-destructive-command-guard

Conversation

@wheeljackz
@wheeljackz wheeljackz commented Apr 27, 2026 •
Copy link
Copy Markdown
Collaborator

Summary

  • Add a conservative Destructive Command Guard workflow for repository-wide scan coverage.
  • Pin DCG to v0.4.5 and install the Linux binary directly because the published composite action tag/installer currently does not resolve successfully on GitHub Actions.
  • Keep permissions read-only and fail only on error-severity findings.

Validation

  • YAML parsed with Ruby YAML loader.
  • git diff --check passed.
  • GitHub Actions DCG job is now running from the direct binary installer.

Current check result

  • DCG check passes on the PR branch.

@vercel
vercel Bot commented Apr 27, 2026 •
Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
zainf Ready Ready Preview, Comment Apr 27, 2026 5:29am

Copy link
Copy Markdown
Owner

Closing as abandoned. This was the only green DCG attempt (direct binary install), but it never landed and main still has no .github/. Re-open from a fresh branch if we still want the scanner.

zainfathoni added a commit that referenced this pull request Sep 11, 2026
## Summary
- Add a conservative Destructive Command Guard workflow for
repository-wide scan coverage.
- Pin DCG to **v0.14.3** and install the Linux musl binary directly,
with SHA-256 verification of the release archive.
- Keep permissions read-only and fail only on error-severity findings.

## Why not the composite action
Previous attempts failed in this repository's GitHub Actions:
- #69 used `Dicklesworthstone/destructive_command_guard/action@v0`
- #71 used `action@v0.4.5`

The only green implementation was #70's direct-binary install, but it
was closed without merging. This PR follows that approach, updated for
the current release:

- Linux x86_64 artifacts are now `x86_64-unknown-linux-musl` (not
`x86_64-unknown-linux-gnu`)
- The archive SHA-256 is pinned in the workflow so a swapped GitHub
Release cannot run

## Validation
- Local `dcg scan --paths . --fail-on error` on the source tree
(excluding `node_modules`) reported **0 findings**.
- The workflow file itself extracts 9 commands and reports **0
findings**.
- GitHub Actions DCG jobs from this PR are the remaining check.

## Policy (first rollout)
- Triggers: `push` and `pull_request`
- `permissions: contents: read`
- `dcg scan --paths . --fail-on error --format pretty`
- No PR comments

Co-authored-by: Amp <amp@ampcode.com>

This branch was successfully deployed

1 active deployment
Preview — 2ccb31ec Deployed Apr 27, 2026 by vercel[bot]
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.

2 participants

0