refactor: renaem record shell.sh.tmpl to just .sh since no longer a template

This commit is contained in:
2026-03-19 18:58:18 +00:00
parent ec1d7ec23a
commit 5ebca22225
2 changed files with 5 additions and 7 deletions
+4 -4
View File
@@ -12,8 +12,8 @@ import (
const recordShellName = "shell.sh" const recordShellName = "shell.sh"
//go:embed record_shell.sh.tmpl //go:embed record_shell.sh
var recordShellTemplateFS embed.FS var recordShellFS embed.FS
func recordShellPath(testDir string) string { func recordShellPath(testDir string) string {
return filepath.Join(testDir, recordShellName) return filepath.Join(testDir, recordShellName)
@@ -63,9 +63,9 @@ func resolveRecordShell(testDir string) (string, error) {
} }
func buildRecordShellScript() string { func buildRecordShellScript() string {
body, err := recordShellTemplateFS.ReadFile("record_shell.sh.tmpl") body, err := recordShellFS.ReadFile("record_shell.sh")
if err != nil { if err != nil {
panic(fmt.Sprintf("read record shell template: %v", err)) panic(fmt.Sprintf("read record shell: %v", err))
} }
return string(body) return string(body)
@@ -1,11 +1,9 @@
#!/bin/sh #!/bin/sh
set -eu set -eu
# Host directory mounted as the sandboxed HOME. # hoisted vars to fail fast if any missing
host_home=${MIRO_HOST_HOME:?} host_home=${MIRO_HOST_HOME:?}
# Host temp directory mounted read-write inside the sandbox.
host_tmp=${MIRO_HOST_TMP:?} host_tmp=${MIRO_HOST_TMP:?}
# PATH value forwarded into the sandbox so required tools stay available.
path_env=${MIRO_PATH_ENV:?} path_env=${MIRO_PATH_ENV:?}
visible_home=${MIRO_VISIBLE_HOME:?} visible_home=${MIRO_VISIBLE_HOME:?}