This is the San Francisco Compute command line tool.
Install the command line tool by running:
curl -fsSL https://sfcompute.com/cli/install | bashThen, you can run the cli:
sf --version # 0.1.0- Install Node.js (v22 or later) - used as the runtime
- Install Bun - used as the package manager
- Install dependencies:
bun install - Auth your CLI with
bun run prod login
- Make code changes
- Test changes with
bun run devto test against local APIbun run prodto test against production API- These are aliases to the user facing
sfcommand. So if you wanted to runsf loginlocally against the local API, runbun run dev login
Releases are managed through GitHub Actions. To create a new release:
- Ensure your changes are merged into the
mainbranch - Go to the Actions tab in the repository
- Click on the "Release" workflow
- Click "Run workflow"
- Select the version bump type:
patch: for backwards-compatible changes (0.0.x)minor: for breaking changes (0.x.0)major: for major breaking changes (x.0.0)prerelease: for pre-release versions (0.0.0-pre.timestamp)
- Click "Run workflow" to start the release process
- Creates a new GitHub release with compiled binaries
- Updates package.json with the new version
- Users on older versions will be notified to update
- Patch updates trigger automatic updates for users
- Tagged as pre-release in GitHub
- Include timestamp in version (e.g.,
0.6.4-pre.1709347826543) - Important: Users on stable versions:
- Will not see update notifications for pre-releases
- Cannot upgrade to pre-releases
- Will only see and receive stable version updates
- Pre-release users:
- Can update to newer pre-releases
- Can update to stable releases
- Will see update notifications normally
The workflow will:
- Run quality checks:
- Linting with
biome ci - Type checking with
tsc --noEmit - Run all tests with
vitest
- Linting with
- Bump the version in package.json
- Create a new GitHub release with compiled binaries
- Push the version bump commit back to main
Note: The release workflow will only run on the main branch and will fail if
any of the quality checks fail.