Skip to content

Commit 7aa67e5

Browse files
authored
Add embeddedcli.Path() accessor for the resolved CLI path (#1677)
1 parent 481ccac commit 7aa67e5

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

go/embeddedcli/installer.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,11 @@ type Config = embeddedcli.Config
1515
func Setup(cfg Config) {
1616
embeddedcli.Setup(cfg)
1717
}
18+
19+
// Path returns the absolute path to the embedded Copilot CLI, installing it on
20+
// first call if necessary. It returns an empty string when no embedded CLI was
21+
// configured via Setup (e.g. a build compiled without the embedded runtime).
22+
// The result is computed once and cached for the life of the process.
23+
func Path() string {
24+
return embeddedcli.Path()
25+
}

0 commit comments

Comments
 (0)