Compare commits

..

5 Commits

Author SHA1 Message Date
Chris Wanstrath
a545c3e056 hide scrollbars 2025-09-26 12:29:58 -07:00
Chris Wanstrath
7e5de30ee9 git sha 2025-09-26 12:28:02 -07:00
Chris Wanstrath
6492d5b3d5 need you 2025-09-26 12:26:23 -07:00
Chris Wanstrath
282fb79f36 uptime command 2025-09-26 12:26:19 -07:00
Chris Wanstrath
9f5b003bb7 env command 2025-09-26 12:26:14 -07:00
4 changed files with 43 additions and 1 deletions

15
app/nose/bin/env.ts Normal file
View File

@ -0,0 +1,15 @@
import { NOSE_STARTED, NOSE_SYS, NOSE_DIR, GIT_SHA } from "@/config"
export default function () {
return [
`NODE_ENV=${process.env.NODE_ENV || "(none)"}`,
`BUN_HOT=${process.env.BUN_HOT || "(none)"}`,
`PORT=${process.env.PORT || "(none)"}`,
`USER=${process.env.USER || "(none)"}`,
`PWD=${process.env.PWD || "(none)"}`,
`NOSE_STARTED=${NOSE_STARTED}`,
`NOSE_SYS=${NOSE_SYS}`,
`NOSE_DIR=${NOSE_DIR}`,
`GIT_SHA=${GIT_SHA.slice(0, 8)}`,
].join("\n")
}

10
app/nose/bin/uptime.ts Normal file
View File

@ -0,0 +1,10 @@
import { NOSE_STARTED } from "@/config"
export default function () {
const ms = Date.now() - NOSE_STARTED
const sec = Math.floor(ms / 1000)
const min = Math.floor(sec / 60)
const hrs = Math.floor(min / 60)
return `${hrs}h ${min % 60}m ${sec % 60}s`
}

View File

@ -1,4 +1,5 @@
import { resolve, join } from "node:path"
import { $ } from "bun"
export const NOSE_ICON = ` ͡° ͜ʖ ͡°`
@ -8,3 +9,6 @@ export const NOSE_SYS_BIN = join(NOSE_SYS, "bin")
export const NOSE_DIR = resolve("..")
export const NOSE_BIN = join(NOSE_DIR, "bin")
export const NOSE_WWW = join(NOSE_DIR, "www")
export const NOSE_STARTED = Date.now()
export const GIT_SHA = (await $`git rev-parse HEAD`.text()).trim()

View File

@ -108,6 +108,14 @@
/* The scrollback shows your previous inputs and outputs. */
#scrollback {
overflow: auto;
/* Firefox */
scrollbar-width: none;
/* IE/Edge */
-ms-overflow-style: none;
overflow-y: auto;
margin: 0;
padding: 0;
@ -115,6 +123,11 @@
font-size: var(--cli-font-size);
}
#scrollback::-webkit-scrollbar {
/* Chrome, Safari, Opera */
display: none;
}
[data-mode="cinema"] #scrollback {
max-height: 505px;
}