MCPcopy Index your code
hub / github.com/nikivdev/go / openInTablePlus

Function openInTablePlus

cli/flow/main.go:1867–1882  ·  view source on GitHub ↗
(ctx *snap.Context, databasePath string)

Source from the content-addressed store, hash-verified

1865}
1866
1867func openInTablePlus(ctx *snap.Context, databasePath string) error {
1868 tablePlusApp := "/Applications/TablePlus.app"
1869 if _, err := os.Stat(tablePlusApp); err != nil {
1870 return fmt.Errorf("TablePlus.app not found at %s: %w", tablePlusApp, err)
1871 }
1872
1873 cmd := exec.Command("open", "-a", tablePlusApp, databasePath)
1874 cmd.Stdout = ctx.Stdout()
1875 cmd.Stderr = ctx.Stderr()
1876 cmd.Stdin = ctx.Stdin()
1877 if err := cmd.Run(); err != nil {
1878 return fmt.Errorf("open TablePlus: %w", err)
1879 }
1880
1881 return nil
1882}
1883
1884func runListWindowsOfApp(ctx *snap.Context) error {
1885 if ctx.NArgs() != 0 {

Callers 1

runOpenSqliteFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected