Verify
AnthropicOfficialPublished by Anthropic
- Skill
- Review and audit
- Software development
- Apache-2.0
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured approach to testing and validating administrative scripts used for managing Microsoft 365 add-ins. It focuses on creating isolated, sandboxed environments to safely execute destructive operations, ensuring that scripts perform as expected without impacting real user data or system configurations. The methodology covers both macOS shell scripts and Windows PowerShell scripts, emphasizing the importance of cross-platform verification and integrity checks.
What it does
- Provides procedures for linting and syntax checking of shell and PowerShell scripts.
- Guides the creation of a sandboxed environment using a fake HOME directory to test destructive script operations.
- Offers a snapshot-diffing technique to verify that add-in management operations do not inadvertently affect user data.
- Includes specific validation steps for PowerShell scripts to ensure compatibility with Windows PowerShell 5.1.
- Highlights common pitfalls such as character encoding issues and argument parsing errors in scripts.
When to use it
- When modifying or updating administrative scripts for the claude-for-msft-365-install tool.
- Before committing changes to ensure scripts are linted and syntax-correct.
- When testing destructive operations like clearing add-in caches to ensure they only target intended files.
- When verifying that script changes do not cause regressions in data integrity or cross-platform compatibility.
Advantages
- Enables safe testing of destructive scripts without risking real system data.
- Provides a clear methodology for verifying that chat history and other user data remain untouched.
- Addresses critical cross-platform differences between macOS and Windows environments.
- Includes robust checks for common script failures like encoding issues and argument parsing bugs.
Usage examples
- “How do I verify my changes to the clear-addin-cache script without deleting real data?”
- The agent will guide you through setting up a sandboxed directory structure that mimics the Microsoft Office file layout, allowing you to run the script against a fake HOME path.
- “How can I ensure my PowerShell script changes are valid for Windows?”
- The agent will provide a PowerShell snippet to perform a tokenization parse check, ensuring the script is compatible with Windows PowerShell 5.1 and free of encoding errors.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/anthropics/verify/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip verify.zip -d .agents/skills
Documentation by Anthropic
Verifying claude-for-msft-365-install
This plugin is admin CLI tooling, not an app. There is nothing to build and
no server to boot. The surface is the terminal: scripts/*.sh on macOS,
scripts/*.ps1 on Windows.
Lint gate
python3 scripts/check.py # from the REPO ROOT, not the plugin dir
bash -n claude-for-msft-365-install/scripts/<script>.shcheck.py lints every manifest and self-installs the pre-commit hook that
patch-bumps .claude-plugin/plugin.json. Run it before committing.
Drive the scripts against a fake $HOME
Every macOS script resolves Office paths from $HOME, so overriding it gives a
throwaway sandbox — you can exercise the destructive --apply paths without
touching real Office data.
S=<scratchpad>/sandbox
for app in Excel Word Powerpoint; do
mkdir -p "$S/Library/Containers/com.microsoft.$app/Data/Documents/wef"
done
printf '<x/>' > "$S/Library/Containers/com.microsoft.Excel/Data/Documents/wef/aaaaaaaa-1111-1111-1111-111111111111.manifest-a.xml"
HOME=$S ./scripts/clear-addin-cache.sh # list
HOME=$S ./scripts/clear-addin-cache.sh --id <GUID> # dry-run
HOME=$S ./scripts/clear-addin-cache.sh --id <GUID> --apply # destructiveSeed at least two IDs across two apps, with mixed upper/lowercase. Both properties have caught real bugs: cross-app blast radius, and a case-sensitive glob that reported "already clear" and sent admins to a folder-wide wipe.
Prove storage is retained
The load-bearing claim of this plugin is that clearing a manifest never touches
the user's chat history. Verify it by snapshot-diffing both trees around the
operation, against the real $HOME:
snap() {
for app in Excel Word Powerpoint; do
find "$HOME/Library/Containers/com.microsoft.$app/Data/Library/WebKit/WebsiteData" \
-type f -exec stat -f '%N %z %m' {} \; 2>/dev/null
find "$HOME/Library/Containers/com.microsoft.$app/Data/Documents/wef" \
-type f -exec stat -f 'WEF %N %z' {} \; 2>/dev/null
done | sort
}
snap > before.txt; <run the script>; snap > after.txt; diff before.txt after.txtManifests live in Data/Documents/wef; storage lives in
Data/Library/WebKit/WebsiteData. Different subtrees — the diff should show
only the manifest you removed. Restore any planted files and re-diff to
confirm you left the machine as you found it.
Gotchas
The Bash tool runs zsh. Scripts are
#!/usr/bin/env bash; test bash-only behaviour (shopt, glob semantics) insidebash <<'EOF' … EOF, not inline.PRAGMA integrity_checkandSELECT count(*)fail on exported IndexedDB files withno such collation sequence: IDBKEY. That is WebKit's custom collation, not corruption — it fails on the source file too. Verify completeness withSELECT sum(length(value)) FROM Records;on both sides.Never claim the
.ps1scripts work without running them on Windows. macOS has no PowerShell, so a.ps1change verified only here is unverified. Run it on a real Windows host against Windows PowerShell 5.1, and always include a parse check before the behavioural ones:$e = $null [System.Management.Automation.PSParser]::Tokenize( (Get-Content -Raw .\clear-addin-cache.ps1), [ref]$e) | Out-Null if ($e.Count) { $e | ForEach-Object { $_.Message } } else { 'parse ok' }A file can be perfectly fine on macOS and fail to parse outright on Windows (see the ASCII note below), so parsing is the first thing to establish.
.ps1files must be pure ASCII (enforced byscripts/check.py). Windows PowerShell 5.1 reads a BOM-less.ps1as ANSI, so an em dash decodes to mojibake containing", which terminates a string and breaks the parse.clear-addin-cache.ps1shipped broken this way and no macOS check caught it.Probe the arg parser.
--flagas the final argument makesshift 2fail underset -eand exits 1 with no output; each flag needs a[ $# -ge 2 ]guard.
Files
- ATTRIBUTION.mdAdded by AutoGineer906 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md4.1 KiB
SKILL.md
Verifying claude-for-msft-365-install
This plugin is admin CLI tooling, not an app. There is nothing to build and
no server to boot. The surface is the terminal: scripts/*.sh on macOS,
scripts/*.ps1 on Windows.
Lint gate
python3 scripts/check.py # from the REPO ROOT, not the plugin dir
bash -n claude-for-msft-365-install/scripts/<script>.shcheck.py lints every manifest and self-installs the pre-commit hook that
patch-bumps .claude-plugin/plugin.json. Run it before committing.
Drive the scripts against a fake $HOME
Every macOS script resolves Office paths from $HOME, so overriding it gives a
throwaway sandbox — you can exercise the destructive --apply paths without
touching real Office data.
S=<scratchpad>/sandbox
for app in Excel Word Powerpoint; do
mkdir -p "$S/Library/Containers/com.microsoft.$app/Data/Documents/wef"
done
printf '<x/>' > "$S/Library/Containers/com.microsoft.Excel/Data/Documents/wef/aaaaaaaa-1111-1111-1111-111111111111.manifest-a.xml"
HOME=$S ./scripts/clear-addin-cache.sh # list
HOME=$S ./scripts/clear-addin-cache.sh --id <GUID> # dry-run
HOME=$S ./scripts/clear-addin-cache.sh --id <GUID> --apply # destructiveSeed at least two IDs across two apps, with mixed upper/lowercase. Both properties have caught real bugs: cross-app blast radius, and a case-sensitive glob that reported "already clear" and sent admins to a folder-wide wipe.
Prove storage is retained
The load-bearing claim of this plugin is that clearing a manifest never touches
the user's chat history. Verify it by snapshot-diffing both trees around the
operation, against the real $HOME:
snap() {
for app in Excel Word Powerpoint; do
find "$HOME/Library/Containers/com.microsoft.$app/Data/Library/WebKit/WebsiteData" \
-type f -exec stat -f '%N %z %m' {} \; 2>/dev/null
find "$HOME/Library/Containers/com.microsoft.$app/Data/Documents/wef" \
-type f -exec stat -f 'WEF %N %z' {} \; 2>/dev/null
done | sort
}
snap > before.txt; <run the script>; snap > after.txt; diff before.txt after.txtManifests live in Data/Documents/wef; storage lives in
Data/Library/WebKit/WebsiteData. Different subtrees — the diff should show
only the manifest you removed. Restore any planted files and re-diff to
confirm you left the machine as you found it.
Gotchas
The Bash tool runs zsh. Scripts are
#!/usr/bin/env bash; test bash-only behaviour (shopt, glob semantics) insidebash <<'EOF' … EOF, not inline.PRAGMA integrity_checkandSELECT count(*)fail on exported IndexedDB files withno such collation sequence: IDBKEY. That is WebKit's custom collation, not corruption — it fails on the source file too. Verify completeness withSELECT sum(length(value)) FROM Records;on both sides.Never claim the
.ps1scripts work without running them on Windows. macOS has no PowerShell, so a.ps1change verified only here is unverified. Run it on a real Windows host against Windows PowerShell 5.1, and always include a parse check before the behavioural ones:$e = $null [System.Management.Automation.PSParser]::Tokenize( (Get-Content -Raw .\clear-addin-cache.ps1), [ref]$e) | Out-Null if ($e.Count) { $e | ForEach-Object { $_.Message } } else { 'parse ok' }A file can be perfectly fine on macOS and fail to parse outright on Windows (see the ASCII note below), so parsing is the first thing to establish.
.ps1files must be pure ASCII (enforced byscripts/check.py). Windows PowerShell 5.1 reads a BOM-less.ps1as ANSI, so an em dash decodes to mojibake containing", which terminates a string and breaks the parse.clear-addin-cache.ps1shipped broken this way and no macOS check caught it.Probe the arg parser.
--flagas the final argument makesshift 2fail underset -eand exits 1 with no output; each flag needs a[ $# -ge 2 ]guard.
Requirements and compatibility
Written for: Claude Code, Claude apps
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Names Claude Code tools, Needs Python
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Anthropic
- Publisher
- Anthropic (Official)
- Source
- anthropics/financial-services · claude-for-msft-365-install/.claude/skills/verify · commit 6056506
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Anthropic or Anthropic.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download verify.zip