repositorypackage
0.0.0-20151016085225-b1ca99b875b0
Repository: https://github.com/emssconsulting/executor.git
Documentation: pkg.go.dev
# Packages
No description provided by the author
# README
Executor

Go based task runner for cross platform script execution
Executor is designed to simplify the task of running user configurable scripts across a wide range of platforms. This use case is common when writing a test runner or automated deployment tool like Depro.
Features
- Simple API allows you to quickly get started and minimize boilerplate
- Pluggable Shells allow you to pick and chose the shell plugins you wish to use, or even create your own.
- Powerful Configuration of each task's arguments and environment, as well as the environment of your executor instance - allowing you to quickly build hierarchical environments.
Usage
package main
import (
"os"
executor "github.com/EMSSConsulting/Executor"
)
func main() {
exec := executor.NewExecutor("powershell")
exec.Environment["RUNNER"] = "Executor"
task := executor.NewTask([]string{
"Write-Host 'Hello World!'",
}, nil, nil)
err := exec.Run(task)
if err != nil {
os.Exit(1)
}
}