Skip to content

v0.5.0: see what it changes, and undo it

Choose a tag to compare

@batrapulkit batrapulkit released this 03 Oct 19:40
· 410 commits to main since this release

Before anyone approves a risky command, they now see what it will change, measured on the developer's machine. And an approved delete can be undone.

  • What it changes. The approval (dashboard, phone, Slack) shows the cost, not a guess:

    • git push --force: the commits it would remove from the remote (as of your last fetch)
    • git reset --hard, checkout, restore: the uncommitted changes it would throw away
    • git clean -f: the untracked files it would delete
    • rm -r, Remove-Item, rmdir /s: how many files, and how much data

    It's information for the approver; it never changes the decision.

  • Undo. Right before an approved delete, git reset --hard, checkout/restore or git clean runs, Squidbrake keeps a copy. squidbrake undo lists them and squidbrake undo ID puts one back, leaving alone anything that changed since (--force overwrites). Build outputs like node_modules aren't copied, and very large deletes are skipped (the agent is told). Backups stay on the machine and are removed after 14 days.

  • Fixed: the evidence pack made with squidbrake evidence showed "0 rules".

Upgrade: pipx upgrade squidbrake

Install this version (0.5.0)

Windows (PowerShell):

$env:SQUIDBRAKE_VERSION="0.5.0"; irm https://pilots.squidbrake.com/install.ps1 | iex

macOS / Linux:

curl -fsSL https://pilots.squidbrake.com/install.sh | SQUIDBRAKE_VERSION=0.5.0 sh

With pip: pip install squidbrake==0.5.0. Docker: docker pull ghcr.io/batrapulkit/squidbrake:0.5.0

Running the line again without SQUIDBRAKE_VERSION goes back to the newest. Every version:
https://github.com/batrapulkit/squidbrake/releases