Skip to content

Commit fa7ecfb

Browse files
committed
Rename project from devsetup to setup
- Update all references: repo name, clone path, state directory, URLs, banners - Add migration to move existing state and clone directories - Rename GitHub repo from trusted/devsetup to trusted/setup
1 parent 64de54b commit fa7ecfb

12 files changed

Lines changed: 104 additions & 55 deletions

AGENTS.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# AGENTS.md
22

3-
Guidance for AI coding agents working on the Trusted Dev Setup repository.
3+
Guidance for AI coding agents working on the Trusted Setup repository.
44

55
## Overview
66

@@ -9,7 +9,7 @@ This repo contains a bash bootstrap script that prepares developer machines with
99
## Architecture
1010

1111
- `setup.sh` — Main entry point. Bash only. Detects OS, installs tools idempotently, then runs pending migrations.
12-
- `lib/migrate.sh` — Migration runner. Sourced by `setup.sh`. Tracks state in `~/.local/state/trusted/devsetup/migrations/`.
12+
- `lib/migrate.sh` — Migration runner. Sourced by `setup.sh`. Tracks state in `~/.local/state/trusted/setup/migrations/`.
1313
- `migrations/*.sh` — Run-once bash scripts for environment transitions. Named by Unix timestamp.
1414

1515
## Key rules
@@ -85,7 +85,7 @@ It does **NOT** install:
8585

8686
## Commands
8787

88-
- `shellcheck -x setup.sh doctor.sh lib/*.sh ci/mock-op` — Lint bash scripts
88+
- `shellcheck -x setup.sh doctor.sh lib/*.sh migrations/*.sh ci/mock-op` — Lint bash scripts
8989
- `bash -n setup.sh` — Check for syntax errors without executing
9090
- `bash doctor.sh` — Run post-setup diagnostic checks
9191
- `date +%s` — Generate a migration timestamp

ARCHITECTURE.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Trusted Dev Setup - Architecture
1+
# Trusted Setup - Architecture
22

33
## Problem
44

@@ -8,7 +8,7 @@ This is a chicken-and-egg problem: you need the repo cloned to run `bin/setup`,
88

99
## Solution
1010

11-
A centralized `trusted/devsetup` repository containing a bash bootstrap script (`setup.sh`) that prepares any developer machine with the baseline system tools required to clone and run any Trusted project's `bin/setup`.
11+
A centralized `trusted/setup` repository containing a bash bootstrap script (`setup.sh`) that prepares any developer machine with the baseline system tools required to clone and run any Trusted project's `bin/setup`.
1212

1313
The script is invocable via `curl | bash` on a fresh machine (no prerequisites beyond bash and curl, which are present on all target platforms).
1414

@@ -72,7 +72,7 @@ Migrations handle one-time transitions that are not naturally idempotent: removi
7272
Inspired by [Omarchy's migration system](https://github.com/basecamp/omarchy/blob/dev/bin/omarchy-migrate).
7373

7474
- Migration scripts live in `migrations/` and are named `<timestamp>_<description>.sh`: e.g. `1740000000_remove_deprecated_tool.sh`
75-
- State is tracked in `~/.local/state/trusted/devsetup/migrations/` as empty marker files (one per completed migration)
75+
- State is tracked in `~/.local/state/trusted/setup/migrations/` as empty marker files (one per completed migration)
7676
- On each run of `setup.sh`, the migration runner:
7777
1. Scans `migrations/*.sh` sorted numerically
7878
2. Skips any migration whose marker file already exists
@@ -101,10 +101,10 @@ This removes the marker file for the given migration and re-executes it.
101101

102102
## State directory
103103

104-
All local state is stored under `~/.local/state/trusted/devsetup/` (follows XDG Base Directory conventions):
104+
All local state is stored under `~/.local/state/trusted/setup/` (follows XDG Base Directory conventions):
105105

106106
```
107-
~/.local/state/trusted/devsetup/
107+
~/.local/state/trusted/setup/
108108
└── migrations/
109109
├── 1740000000.sh # marker: migration completed
110110
├── 1740100000.sh
@@ -122,7 +122,7 @@ Options:
122122
123123
Examples:
124124
# First-time setup (or re-run to update)
125-
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/devsetup/main/setup.sh)"
125+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/setup/main/setup.sh)"
126126
127127
# Re-run a specific migration
128128
./setup.sh --rerun 1740000000
@@ -132,7 +132,7 @@ Examples:
132132

133133
```bash
134134
# 1. One-time system bootstrap
135-
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/devsetup/main/setup.sh)"
135+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/setup/main/setup.sh)"
136136

137137
# 2. Clone any Trusted project
138138
gh repo clone trusted/<project>
@@ -144,7 +144,7 @@ cd <project> && bin/setup
144144
## Repository structure
145145

146146
```
147-
devsetup/
147+
setup/
148148
├── setup.sh # Main bootstrap script (bash, entry point)
149149
├── doctor.sh # Read-only diagnostic script (verifies setup.sh outcomes)
150150
├── lib/

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Trusted Dev Setup
1+
# Trusted Setup
22

33
Bootstraps a developer machine with the baseline tools required to work on Trusted projects.
44

@@ -26,7 +26,7 @@ Bootstraps a developer machine with the baseline tools required to work on Trust
2626
## Quick start
2727

2828
```bash
29-
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/devsetup/main/setup.sh)"
29+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/setup/main/setup.sh)"
3030
```
3131

3232
Then clone and set up any project:
@@ -40,16 +40,16 @@ cd <project> && bin/setup
4040

4141
The script is idempotent. Run it again at any time to ensure your tools are up to date and apply new migrations.
4242

43-
Locally from the cloned repo at `~/Work/devsetup`:
43+
Locally from the cloned repo at `~/Work/setup`:
4444

4545
```bash
46-
bash ~/Work/devsetup/setup.sh
46+
bash ~/Work/setup/setup.sh
4747
```
4848

4949
Via curl (fetches latest from GitHub):
5050

5151
```bash
52-
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/devsetup/main/setup.sh)"
52+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/trusted/setup/main/setup.sh)"
5353
```
5454

5555

@@ -58,7 +58,7 @@ Via curl (fetches latest from GitHub):
5858
Run `doctor.sh` at any time to check that all expected tools are installed and no migrations are pending. It never changes anything — only reports:
5959

6060
```bash
61-
bash ~/Work/devsetup/doctor.sh
61+
bash ~/Work/setup/doctor.sh
6262
```
6363

6464
## Migrations
@@ -68,7 +68,7 @@ One-time environment changes are tracked as migration scripts in `migrations/`.
6868
To re-run a specific migration:
6969

7070
```bash
71-
bash ~/Work/devsetup/setup.sh --rerun <timestamp>
71+
bash ~/Work/setup/setup.sh --rerun <timestamp>
7272
```
7373

7474
## How it works

doctor.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
#
3-
# Trusted Dev Setup — Doctor
3+
# Trusted Setup — Doctor
44
#
55
# Read-only diagnostic script that verifies all tools and configuration
66
# installed by setup.sh are present and working. Never modifies anything.
@@ -69,7 +69,7 @@ check_cmd() {
6969
# ---------------------------------------------------------------------------
7070

7171
echo ""
72-
echo "= Trusted Dev Setup Doctor ="
72+
echo "= Trusted Setup Doctor ="
7373
echo ""
7474
echo " Platform: $OS"
7575
echo ""

lib/common.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
#
3-
# Shared helpers for Trusted Dev Setup.
3+
# Shared helpers for Trusted Setup.
44
# Sourced by setup.sh — do not execute directly.
55

66
# ---------------------------------------------------------------------------

lib/migrate.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
#!/bin/bash
22
#
3-
# Migration runner for Trusted Dev Setup.
3+
# Migration runner for Trusted Setup.
44
# Sourced by setup.sh — do not execute directly.
55
#
66
# Inspired by Omarchy's migration system:
77
# https://github.com/basecamp/omarchy/blob/dev/bin/omarchy-migrate
88

9-
MIGRATION_STATE_DIR="$HOME/.local/state/trusted/devsetup/migrations"
9+
MIGRATION_STATE_DIR="$HOME/.local/state/trusted/setup/migrations"
1010

1111
run_migrations() {
1212
local script_dir="$1"

lib/migrate_doctor.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
fmt_header "Migrations"
99

10-
MIGRATION_STATE_DIR="$HOME/.local/state/trusted/devsetup/migrations"
10+
MIGRATION_STATE_DIR="$HOME/.local/state/trusted/setup/migrations"
1111

1212
if [ -d "$MIGRATION_STATE_DIR" ]; then
1313
check_pass "Migration state directory exists"

lib/registries_setup.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,8 @@ YARNRC_FILE="$HOME/.yarnrc.yml"
8686

8787
# Build the npmScopes block. We overwrite the file each time to ensure
8888
# credentials stay current. Any pre-existing content that is NOT managed
89-
# by devsetup will be lost — this is intentional; ~/.yarnrc.yml is owned
90-
# by devsetup for scope configuration.
89+
# by setup will be lost — this is intentional; ~/.yarnrc.yml is owned
90+
# by setup for scope configuration.
9191
cat > "$YARNRC_FILE" <<EOF
9292
npmScopes:
9393
trusted:

lib/repos_doctor.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,16 @@ else
1212
check_fail "$HOME/Work directory does not exist"
1313
fi
1414

15-
if [ -d "$HOME/Work/devsetup/.git" ]; then
16-
check_pass "devsetup is cloned to $HOME/Work/devsetup"
15+
if [ -d "$HOME/Work/setup/.git" ]; then
16+
check_pass "setup is cloned to $HOME/Work/setup"
1717
else
18-
check_warn "devsetup not found at $HOME/Work/devsetup (ok if running from another location)"
18+
check_warn "setup not found at $HOME/Work/setup (ok if running from another location)"
1919
fi
2020

21-
if [ -f "$HOME/Work/devsetup/setup.sh" ]; then
22-
check_pass "$HOME/Work/devsetup contains setup.sh"
21+
if [ -f "$HOME/Work/setup/setup.sh" ]; then
22+
check_pass "$HOME/Work/setup contains setup.sh"
2323
else
24-
check_warn "setup.sh not found in $HOME/Work/devsetup"
24+
check_warn "setup.sh not found in $HOME/Work/setup"
2525
fi
2626

2727
if [ -d "$HOME/Work/docs/.git" ]; then

lib/repos_setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@ clone_to_work() {
2424
fi
2525
}
2626

27-
clone_to_work "trusted/devsetup" "devsetup"
27+
clone_to_work "trusted/setup" "setup"
2828
clone_to_work "trusted/docs" "docs"

0 commit comments

Comments
 (0)