test-cross-platform
Skill486 starsChanged 15 days agoApache-2.0View on GitHub
Synchronize repository changes to remote test fleet (Linux, macOS, Windows) and execute the full test suite across all platforms concurrently.
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 4 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Run the full test suite across the remote cross-platform fleet (Linux on nazmul-mobile.local, macOS, and Windows) to verify compatibility, …
- Very specific: line 13
After modifying cross-platform code, platform-specific #[cfg(...)] gates, or PTY logic.
- Distinctive: line 14
Before merging pull requests or finalizing release milestones.
- Very specific: line 15
When the user runs /test-cross-platform or asks to test across platforms/fleet.
- Very specific: line 31
If you are in ~/github/roc, $FOLDER_NAME is roc.
- Very specific: line 74
Ensure the target folder exists on each remote fleet machine, then synchronize the current worktree (always excluding .git and target/ so …
- Distinctive: line 94
All sync operations can run in parallel.
- Very specific: line 98
Run the full test suite across all three platforms concurrently using non-blocking background tasks (run_command with async tasks, or …
- Very specific: line 119
When testing specific subsystems (like core::pty) during active refactoring rather than the entire workspace:
- Distinctive: line 127
Wait for all three runs to conclude (via reactive task completion messages).
- Distinctive: line 137
If any test fails, extract the failure diagnostics and failing test names for triage.
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Cross-Platform Fleet Testing
Run the full test suite across the remote cross-platform fleet (Linux on nazmul-mobile.local, macOS, and Windows)
to verify compatibility, platform gates, and asynchronous I/O behavior.
When to Use
- After modifying cross-platform code, platform-specific
#[cfg(...)]gates, or PTY logic. - Before merging pull requests or finalizing release milestones.
- When the user runs
/test-cross-platformor asks to test across platforms/fleet.
Worktree & Folder Detection
The skill dynamically detects whether you are in the primary repository or a git worktree:
# Fish syntax:
set -l REPO_ROOT (git rev-parse --show-toplevel)
set -l FOLDER_NAME (basename "$REPO_ROOT")
# Bash syntax:
REPO_ROOT=$(git rev-parse --show-toplevel)
FOLDER_NAME=$(basename "$REPO_ROOT")If you are in ~/github/roc, $FOLDER_NAME is roc. If you are in a worktree such as ~/github/roc-fix-shift-home-lockup, $FOLDER_NAME is roc-fix-shift-home-lockup. Remote fleet machines mirror this folder under their respective repository parent paths.
Worktree Portability & Relative Paths (worktree.useRelativePaths)
Linked git worktrees store administrative pointer files:
- Inside the worktree:
.git(file containinggitdir: <path_to_main_repo>/.git/worktrees/<name>) - Inside the main repo:
.git/worktrees/<name>/gitdir(file containing<path_to_worktree>/.git)
By default, Git writes absolute paths (/home/nazmul/... on Linux vs /Users/nazmul/... on macOS). If worktrees or their .git files are mirrored across systems with different home directory roots, Git will fail on the remote host with:
fatal: not a git repository: (null)which causes any tests or tools that invoke git (such as cargo-rustdoc-fmt validation tests in build-infra) to fail.
To prevent this:
- Always enable relative worktree paths globally:
Or explicitly passgit config --global worktree.useRelativePaths true--relativewhen creating a worktree:git worktree add --relative ../<worktree_folder> <branch> - To repair existing worktrees with absolute path mismatches:
Git will detect the absolute path mismatch and convert all linked worktrees to relative paths in place.cd ~/github/roc git config worktree.useRelativePaths true git worktree repair
Fleet Overview
| Platform | Host Address | Shell | Repository Path | Test Runner |
| Linux | nazmul-mobile.local | fish | ~/github/<folder_name> | ./check.fish --test |
| macOS | nazmul-mac.local | fish | ~/github/<folder_name> | ./check.fish --test |
| Windows | nazmul-win.local | nu (Nushell) | github/<folder_name> | cargo test |
Workflow
Step 1: Fleet Synchronization
Ensure the target folder exists on each remote fleet machine, then synchronize the current worktree (always excluding .git and target/ so git worktree files and platform binaries are not overwritten):
- Linux (
nazmul-mobile.local):ssh nazmul-mobile.local "mkdir -p ~/github/$FOLDER_NAME" rsync -av --delete --exclude='.git' --exclude='target' "$REPO_ROOT/" nazmul-mobile.local:"github/$FOLDER_NAME/" - macOS (
nazmul-mac.local):ssh nazmul-mac.local "mkdir -p ~/github/$FOLDER_NAME" rsync -av --delete --exclude='.git' --exclude='target' "$REPO_ROOT/" nazmul-mac.local:"github/$FOLDER_NAME/" - Windows (
nazmul-win.local):ssh nazmul-win.local "powershell -NoProfile -Command 'New-Item -ItemType Directory -Force -Path github/$FOLDER_NAME'" tar -cz -C "$REPO_ROOT" --exclude=.git --exclude=target . | ssh nazmul-win.local "tar -xz -C github/$FOLDER_NAME"
All sync operations can run in parallel.
Step 2: Concurrent Test Execution
Run the full test suite across all three platforms concurrently using non-blocking background tasks (run_command with async tasks, or delegated via invoke_subagent with TypeName: "self", Model: "inherit") so the active conversation remains responsive:
- Linux (
nazmul-mobile.local):
(Alternatively:ssh nazmul-mobile.local "cd ~/github/$FOLDER_NAME && ./check.fish --test"ssh nazmul-mobile.local "cd ~/github/$FOLDER_NAME && cargo test") - macOS (
nazmul-mac.local):
(Alternatively:ssh nazmul-mac.local "cd ~/github/$FOLDER_NAME && ./check.fish --test"ssh nazmul-mac.local "cd ~/github/$FOLDER_NAME && cargo test") - Windows (
nazmul-win.local):ssh nazmul-win.local "cd github/$FOLDER_NAME; cargo test"
Step 3: Targeted Subsystem Testing (Optional)
When testing specific subsystems (like core::pty) during active refactoring rather than the entire workspace:
- Linux:
ssh nazmul-mobile.local "cd ~/github/$FOLDER_NAME && cargo test -p r3bl_tui core::pty" - macOS:
ssh nazmul-mac.local "cd ~/github/$FOLDER_NAME && cargo test -p r3bl_tui core::pty" - Windows:
ssh nazmul-win.local "cd github/$FOLDER_NAME; cargo test -p r3bl_tui core::pty"
Step 4: Result Aggregation & Reporting
- Wait for all three runs to conclude (via reactive task completion messages).
- Extract summary lines (
test result: ok. <X> passed; <Y> failed; ...). - Present results in a markdown summary table:
| Platform | Host / Machine | Result | Tests Passed | Tests Failed | Duration |
| Linux | nazmul-mobile.local | PASSED | 53 | 0 | 0.01s |
| macOS | nazmul-mac.local | PASSED | 53 | 0 | 0.02s |
| Windows | nazmul-win.local | PASSED | 55 | 0 | 0.46s |
- If any test fails, extract the failure diagnostics and failing test names for triage.
- Emit attention beep signal:
fish -c "beep"
In this repository30 other files it gives its agents.
- .agents/AGENTS.mdAGENTS.md
- AGENTS.mdAGENTS.md
- build-infra/AGENTS.mdAGENTS.md
- rust-analyzer-mcp-server/AGENTS.mdAGENTS.md
- task/AGENTS.mdAGENTS.md
- llms.txtllms.txt
- analyze-log-filesSkill
- analyze-performanceSkill
- audit-taskSkill
- batch-refactor-with-sub-agentsSkill
- check-bounds-safetySkill
- check-code-qualitySkill
- check-test-coverageSkill
- code-reviewSkill
- concurrency-safetySkill
- create-commit-messageSkill
- create-prSkill
- design-philosophySkill
- fast-string-allocationsSkill
- fix-issueSkill
- merge-prSkill
- organize-modulesSkill
- organize-testsSkill
- release-crateSkill
- remove-crate-prefixSkill
- review-prSkill
- run-clippySkill
- safe-renamingSkill
- write-documentationSkill
- write-structured-tracingSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

