Merge branch 'remove-repo'

This commit is contained in:
Chris Wanstrath 2026-03-01 09:46:53 -08:00
commit 310994b77c

View File

@ -1,6 +1,6 @@
import { Hype } from '@because/hype'
import { define, stylesToCSS } from '@because/forge'
import { baseStyles, ToolScript, theme } from '@because/toes/tools'
import { baseStyles, ToolScript, theme, on } from '@because/toes/tools'
import { mkdirSync } from 'fs'
import { mkdir, readdir, readlink, rm, stat } from 'fs/promises'
import { join, resolve } from 'path'
@ -536,6 +536,11 @@ function RepoListPage({ baseUrl, repos }: RepoListPageProps) {
mkdirSync(REPOS_DIR, { recursive: true })
on('app:delete', async ({ app: name }) => {
const bare = repoPath(name)
if (await dirExists(bare)) await rm(bare, { recursive: true, force: true })
})
app.get('/ok', c => c.text('ok'))
app.get('/styles.css', c =>