Add Utilities/setup-dev.sh for one-command contributor setup#726
Merged
kateinoigakukun merged 1 commit intoswiftwasm:mainfrom Apr 26, 2026
Merged
Conversation
Wraps the manual steps already documented in CONTRIBUTING.md:
- Verifies required tools (swiftly, swift, jq, npm, make, curl).
- If a .swift-version file is present, installs the pinned toolchain via
swiftly.
- Resolves and installs a matching Wasm SDK from swift-sdk-index
(idempotent — skipped if already installed).
- Runs `make bootstrap` to install JS deps.
- Prints SWIFT_SDK_ID for use with `make unittest`.
The script runs under bash via shebang; the export instructions it prints
work unchanged in zsh and bash. The repo does not track .swift-version;
contributors who want it ignored locally can add it to .git/info/exclude.
The original manual instructions are kept in CONTRIBUTING.md as a fallback.
kateinoigakukun
approved these changes
Apr 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
Utilities/setup-dev.sh, a wrapper around the manual setup steps already documented inCONTRIBUTING.md. Re-running it is idempotent.The script:
swiftly,swift,jq,npm,make,curl) and prints actionable hints if any are missing..swift-versionfile is present at the repo root, installs that toolchain viaswiftly.make bootstrap.SWIFT_SDK_IDfor use withmake unittest.The script runs under bash via the shebang; the printed
exportinstructions work unchanged in both bash and zsh.CONTRIBUTING.mdnow opens with a "Quick start" section pointing at the script, and keeps the original manual instructions as a "Manual setup" fallback for anyone who wants to follow each step by hand.Notes
.swift-version; contributors who want it ignored locally can add it to.git/info/exclude.Utilities/format.swiftdoes not apply.swift sdk remove, and invocation from a different working directory.Test plan
swiftly, run./Utilities/setup-dev.shand confirm it installs the Wasm SDK, runsmake bootstrap, and prints a usableSWIFT_SDK_ID.make unittest SWIFT_SDK_ID=<printed-id>runs the Wasm test suite.