Files
oh-my-pi/types/assets/index.d.ts
T
roboomp 77265de55e fix(bash): re-exported env vars referenced by snapshotted shell functions
generateSnapshotScript captured the user's shell functions via declare -f /
typeset -f and dropped everything except PATH on the export floor. mise
activate installs a mise() function whose body expands $__MISE_EXE; the
replay shell then ran `command "" "$@"` and died with
`command: command not found:` (exit 127). The same shape breaks asdf
shims, direnv-style helpers, and any other activation idiom that pairs a
shell function with a sidecar env var.

The snapshot script now scans captured function bodies for $VAR /
${VAR…} references and re-emits `export NAME='value'` for each name
that is currently set and not on a shell-internal denylist (PATH, HOME,
BASH_*, LC_*, …). getShellConfigFile also honours env.HOME so callers
(and tests) can target a sandboxed home — os.homedir() is cached by Bun
and ignores later process.env.HOME mutations.

Fixes #3470
2026-06-25 15:10:59 +00:00

67 lines
1.4 KiB
TypeScript

declare module "*.md" {
const content: string;
export default content;
}
declare module "*.txt" {
const content: string;
export default content;
}
declare module "*.py" {
const content: string;
export default content;
}
declare module "*.rb" {
const content: string;
export default content;
}
declare module "*.jl" {
const content: string;
export default content;
}
declare module "*.lark" {
const content: string;
export default content;
}
declare module "*.sh" {
const content: string;
export default content;
}
declare module "*.bdf" {
const content: string;
export default content;
}
// Session-export template assets imported as text (coding-agent src/export/html).
// No `*.html` declaration: bun-types claims that pattern as HTMLBundle, so the
// text import casts at the use site instead.
declare module "*.css" {
const content: string;
export default content;
}
declare module "*/template.js" {
const content: string;
export default content;
}
declare module "*.generated.js" {
const content: string;
export default content;
}
// turndown-plugin-gfm has no published types
declare module "turndown-plugin-gfm" {
import type TurndownService from "turndown";
export const gfm: TurndownService.Plugin;
export const tables: TurndownService.Plugin;
export const strikethrough: TurndownService.Plugin;
export const taskListItems: TurndownService.Plugin;
}