MCPcopy Create free account
hub / github.com/codehamr/codehamr / mustCwd

Function mustCwd

cmd/codehamr/main.go:204–210  ·  view source on GitHub ↗

mustCwd returns the working directory or exits 1, called only where there's nothing sensible to recover to.

()

Source from the content-addressed store, hash-verified

202func reexecEnv() []string {
203 os.Setenv("CODEHAMR_NO_UPDATE_CHECK", "1")
204 return os.Environ()
205}
206
207// mustCwd returns the working directory or exits 1, called only where
208// there's nothing sensible to recover to.
209func mustCwd() string {
210 cwd, err := os.Getwd()
211 if err != nil {
212 log.Fatalf("codehamr: %v", err)
213 }

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected