{"modulePath":"github.com/slackapi/slack-cli","version":"v0.0.0-20261126003108-35cb557150de","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package runtime\n\n## Constants\n\n```go\nconst DefaultRuntimeName = \"deno\"\n```\nDefaultRuntimeName is the runtime used when none are specified or detected\n\n## Functions\n\n```go\nfunc ActivatePythonVenvIfPresent(fs afero.Fs, os types.Os, projectDir string) (bool, error)\n```\nActivatePythonVenvIfPresent activates a Python virtual environment if one exists in the given project directory. This sets VIRTUAL\\_ENV, prepends the venv bin directory to PATH, and unsets PYTHONHOME on the current process so that child processes (hook scripts) inherit the activated venv.\n\n## Types\n\n```go\ntype Runtime interface {\n\tIgnoreDirectories() []string\n\tInstallProjectDependencies(context.Context, string, hooks.HookExecutor, iostreams.IOStreamer, afero.Fs, types.Os) (string, error)\n\tName() string\n\tVersion() string\n\tSetVersion(string)\n\tHooksJSONTemplate() []byte\n\tPreparePackage(context.Context, hooks.SDKCLIConfig, hooks.HookExecutor, types.PreparePackageOpts) error\n}\n```\nRuntime interface generalizes the required functionality for any runtime language. Example runtimes: Node.js, Deno, Python, Java, etc.\n\n```go\nfunc New(runtimeName string) (Runtime, error)\n```\nNew creates a new runtime using runtimeName to choose the runtime\n\nruntimeName uses the hosted version pattern, e.g. deno1.1, deno1.x\n\n```go\nfunc NewDetectProject(ctx context.Context, fs afero.Fs, dirPath string, sdkConfig hooks.SDKCLIConfig) (Runtime, error)\n```\nNewDetectProject returns a new Runtime based on the project type of dirPath\n\n","path":"github.com/slackapi/slack-cli/internal/runtime","name":"runtime","synopsis":"","isRedistributable":true}
