- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for DefaultCmds (0.15 sec)
-
src/cmd/go/internal/script/scripttest/scripttest.go
"errors" "io" "strings" "testing" ) // DefaultCmds returns a set of broadly useful script commands. // // This set includes all of the commands in script.DefaultCmds, // as well as a "skip" command that halts the script and causes the // testing.TB passed to Run to be skipped. func DefaultCmds() map[string]script.Cmd { cmds := script.DefaultCmds() cmds["skip"] = Skip() return cmds }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Sep 11 20:12:18 UTC 2023 - 3.7K bytes - Viewed (0) -
src/cmd/go/scriptcmds_test.go
"cmd/go/internal/work" "errors" "fmt" "os" "os/exec" "strings" "sync" "time" ) func scriptCommands(interrupt os.Signal, waitDelay time.Duration) map[string]script.Cmd { cmds := scripttest.DefaultCmds() // Customize the "exec" interrupt signal and grace period. var cancel func(cmd *exec.Cmd) error if interrupt != nil { cancel = func(cmd *exec.Cmd) error { return cmd.Process.Signal(interrupt) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 18:33:17 UTC 2024 - 3.3K bytes - Viewed (0) -
src/cmd/go/internal/vcweb/script.go
func newScriptEngine() *script.Engine { conds := script.DefaultConds() interrupt := func(cmd *exec.Cmd) error { return cmd.Process.Signal(os.Interrupt) } gracePeriod := 30 * time.Second // arbitrary cmds := script.DefaultCmds() cmds["at"] = scriptAt() cmds["bzr"] = script.Program("bzr", interrupt, gracePeriod) cmds["fossil"] = script.Program("fossil", interrupt, gracePeriod) cmds["git"] = script.Program("git", interrupt, gracePeriod)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Nov 08 19:37:03 UTC 2022 - 9K bytes - Viewed (0) -
src/cmd/go/internal/script/cmds.go
"os" "os/exec" "path/filepath" "regexp" "runtime" "strconv" "strings" "sync" "time" ) // DefaultCmds returns a set of broadly useful script commands. // // Run the 'help' command within a script engine to view a list of the available // commands. func DefaultCmds() map[string]Cmd { return map[string]Cmd{ "cat": Cat(), "cd": Cd(), "chmod": Chmod(), "cmp": Cmp(),
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 26 19:58:28 UTC 2024 - 28.5K bytes - Viewed (0) -
src/cmd/go/internal/script/engine.go
// section when starting a new section. Quiet bool } // NewEngine returns an Engine configured with a basic set of commands and conditions. func NewEngine() *Engine { return &Engine{ Cmds: DefaultCmds(), Conds: DefaultConds(), } } // A Cmd is a command that is available to a script. type Cmd interface { // Run begins running the command. //
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 27 01:16:19 UTC 2023 - 22.2K bytes - Viewed (0)