diff --git a/.lane/memory/apps/app/src/app.tsx/01M4YT6XB7NQ89E6F4P375REE7-all-projects-and-project-vie.md b/.lane/memory/apps/app/src/app.tsx/01M4YT6XB7NQ89E6F4P375REE7-all-projects-and-project-vie.md index bc3a23f7..d84bcf82 100644 --- a/.lane/memory/apps/app/src/app.tsx/01M4YT6XB7NQ89E6F4P375REE7-all-projects-and-project-vie.md +++ b/.lane/memory/apps/app/src/app.tsx/01M4YT6XB7NQ89E6F4P375REE7-all-projects-and-project-vie.md @@ -4,9 +4,9 @@ anchor: function App created: 2026-10-15T03:38:04Z norm: '1' sig: 063d0f00fea02511 -body_hash: 83384f8adacc5fe0 -raw_hash: 8ef778bdb202cc6b -vouched: 2026-10-22T21:26:46Z +body_hash: b43eff10846d0cd3 +raw_hash: c90b02e06b07e972 +vouched: 2026-10-22T22:08:11Z lines: 235-824 --- diff --git a/.lane/memory/apps/app/src/app.tsx/01M5JMVG9G87F31FGVV571Y6BJ-the-project-list-is-built-on.md b/.lane/memory/apps/app/src/app.tsx/01M5JMVG9G87F31FGVV571Y6BJ-the-project-list-is-built-on.md index 624fa5e4..84a56e07 100644 --- a/.lane/memory/apps/app/src/app.tsx/01M5JMVG9G87F31FGVV571Y6BJ-the-project-list-is-built-on.md +++ b/.lane/memory/apps/app/src/app.tsx/01M5JMVG9G87F31FGVV571Y6BJ-the-project-list-is-built-on.md @@ -4,9 +4,9 @@ anchor: function App created: 2026-10-22T20:29:16Z norm: '1' sig: 063d0f00fea02511 -body_hash: 83384f8adacc5fe0 -raw_hash: 8ef778bdb202cc6b -vouched: 2026-10-22T21:26:46Z +body_hash: b43eff10846d0cd3 +raw_hash: c90b02e06b07e972 +vouched: 2026-10-22T22:08:11Z lines: 330-1237 --- diff --git a/.lane/memory/apps/app/src/dashboard.tsx/01M5AYX7CX6GW2PYNTV3BS5F91-with-no-usable-model-on-this.md b/.lane/memory/apps/app/src/dashboard.tsx/01M5AYX7CX6GW2PYNTV3BS5F91-with-no-usable-model-on-this.md index 319c8f41..a03f5a0b 100644 --- a/.lane/memory/apps/app/src/dashboard.tsx/01M5AYX7CX6GW2PYNTV3BS5F91-with-no-usable-model-on-this.md +++ b/.lane/memory/apps/app/src/dashboard.tsx/01M5AYX7CX6GW2PYNTV3BS5F91-with-no-usable-model-on-this.md @@ -4,9 +4,9 @@ anchor: function Dashboard created: 2026-10-19T20:51:03Z norm: '1' sig: 4bfb45497157c0e0 -body_hash: 7bc89e0d12e7b984 -raw_hash: cc8a4b9d6c396b11 -vouched: 2026-10-22T20:44:27Z +body_hash: e77359bc3330d503 +raw_hash: 7884a688975d2f4c +vouched: 2026-10-22T22:08:11Z lines: 256-606 --- diff --git a/.lane/memory/apps/app/src/open-project.tsx/01M5JNQ72H3WS44JG82D60Q37M-a-folder-without-a-commit-is.md b/.lane/memory/apps/app/src/open-project.tsx/01M5JNQ72H3WS44JG82D60Q37M-a-folder-without-a-commit-is.md index ef9e2203..83cf4438 100644 --- a/.lane/memory/apps/app/src/open-project.tsx/01M5JNQ72H3WS44JG82D60Q37M-a-folder-without-a-commit-is.md +++ b/.lane/memory/apps/app/src/open-project.tsx/01M5JNQ72H3WS44JG82D60Q37M-a-folder-without-a-commit-is.md @@ -3,9 +3,10 @@ id: 01M5JNQ72H3WS44JG82D60Q37M anchor: function InitGit created: 2026-10-22T20:44:24Z norm: '1' -sig: e05f5c81094473f3 -body_hash: faffdcfc736d2780 -raw_hash: e2bf3f4586e0df5c +sig: bbe6f480fcc6cbd1 +body_hash: 0fc448d2189f968d +raw_hash: 517902d11c496496 +vouched: 2026-10-22T22:08:11Z lines: 52-111 --- diff --git a/.lane/memory/apps/app/src/projects.ts/01M4YQHHKT4G697PSH2EAWHFCK-a-peer-answers-project-repo.md b/.lane/memory/apps/app/src/projects.ts/01M4YQHHKT4G697PSH2EAWHFCK-a-peer-answers-project-repo.md index 8f6b299c..a1e0e945 100644 --- a/.lane/memory/apps/app/src/projects.ts/01M4YQHHKT4G697PSH2EAWHFCK-a-peer-answers-project-repo.md +++ b/.lane/memory/apps/app/src/projects.ts/01M4YQHHKT4G697PSH2EAWHFCK-a-peer-answers-project-repo.md @@ -4,9 +4,9 @@ anchor: function projects created: 2026-10-15T02:51:27Z norm: '1' sig: a2ec110fa31d81ee -body_hash: b6503a52b484f8c1 -raw_hash: 512eae2c23a06106 -vouched: 2026-10-22T14:33:26Z +body_hash: 61e3738b3ac3c6ad +raw_hash: edf6c307fa9849bb +vouched: 2026-10-22T22:08:11Z lines: 42-91 --- diff --git a/apps/app/src/app.tsx b/apps/app/src/app.tsx index c7e8aadd..b814c311 100644 --- a/apps/app/src/app.tsx +++ b/apps/app/src/app.tsx @@ -689,14 +689,16 @@ export function App() { } } - async function init(path: string) { + async function init(path: string, empty?: boolean) { try { await host.request({ op: "project-init", path }); - toast.success("Initialized Git", { + toast.success(empty ? "Made the first commit" : "Initialized Git", { description: "Committed the folder's files as Initial commit. Channels can start here now.", }); } catch (error) { - toast.error("Could not initialize Git", { description: (error as Error).message }); + toast.error(empty ? "Could not make the first commit" : "Could not initialize Git", { + description: (error as Error).message, + }); } } @@ -1068,7 +1070,7 @@ export function App() { local={local} connected={connected} onSetup={!local && current.repo ? () => startSetup(current) : undefined} - onInit={() => init(current.path)} + onInit={() => init(current.path, current.empty)} onProject={chooseProject} onRemove={removeRepo} onOpen={() => void choose()} @@ -1128,10 +1130,11 @@ export function App() {
init(current.path)} + onInit={() => init(current.path, current.empty)} />
)} diff --git a/apps/app/src/dashboard.tsx b/apps/app/src/dashboard.tsx index 19d21ff6..5ababd68 100644 --- a/apps/app/src/dashboard.tsx +++ b/apps/app/src/dashboard.tsx @@ -441,6 +441,7 @@ export function Dashboard( -

Initialize a Git repository to get started

+

+ {empty + ? "Make the first commit to get started" + : "Initialize a Git repository to get started"} +

{ignored ? (

- Channels work in lanes, which are Git worktrees. {name} already has a{" "} - .gitignore, so Ace won't commit under its rules. Run git init - {" "} - and commit its files yourself, then channels can start here. + {lanes} {name} already has a{" "} + .gitignore, so Ace won't commit under its rules. {empty ? "Commit" : ( + <> + Run git init and commit + + )} its files yourself, then channels can start here.

) : ( <>

- Channels work in lanes, which are Git worktrees. Ace will run git init in - {" "} - {name}, add a .gitignore that leaves out secrets such as{" "} + {lanes} Ace will {empty ? "add" : ( + <> + run git init in {name}, add + + )} a .gitignore that leaves out secrets such as{" "} .env, dependencies, and build output, and commit the rest.

)} diff --git a/apps/app/src/projects.ts b/apps/app/src/projects.ts index b686368d..7702620e 100644 --- a/apps/app/src/projects.ts +++ b/apps/app/src/projects.ts @@ -89,6 +89,7 @@ export function projects(opened: Project[], channels: Listing[], host: string): }; if (repo) created.repo = repo; if (opened?.git === false) created.git = false; + if (opened?.empty) created.empty = true; if (opened?.ignored) created.ignored = true; return void values.set(id, created); } diff --git a/apps/host/src/projects.ts b/apps/host/src/projects.ts index 86ce51aa..027e591b 100644 --- a/apps/host/src/projects.ts +++ b/apps/host/src/projects.ts @@ -98,6 +98,7 @@ async function project(path: string): Promise { if (repo) value.repo = repo; if (!commit) { value.git = false; + if (existsSync(join(root, ".git"))) value.empty = true; if (existsSync(join(root, ".gitignore"))) value.ignored = true; } return value; diff --git a/apps/host/src/protocol.ts b/apps/host/src/protocol.ts index 9739d4b3..a3865893 100644 --- a/apps/host/src/protocol.ts +++ b/apps/host/src/protocol.ts @@ -269,6 +269,8 @@ export type Project = { repo?: string; /** False until the folder is a Git repository with a commit, which lanes start from. */ git?: false; + /** The folder is already a Git repository and needs only its first commit. */ + empty?: true; /** The folder without a commit already has a `.gitignore`, so Ace leaves initializing it to its owner. */ ignored?: true; };