Documentation
¶
Index ¶
- Constants
- Variables
- func AppExists(app types.App, auth types.SlackAuth) error
- func GetProcessName() string
- func IsFlagChanged(cmd *cobra.Command, flag string) bool
- func IsSlackHostedProject(ctx context.Context, clients *shared.ClientFactory) error
- func IsValidProjectDirectory(clients *shared.ClientFactory) error
Constants ¶
const DeployedAppNotInstalledMsg = "App is not installed or deployed"
const LocalAppNotInstalledMsg = "Local app is not installed"
const ( // OrgGrantWorkspaceFlag is used in the `run`, `deploy` and `install` commands // to specify an org workspace to add a grant for when installing OrgGrantWorkspaceFlag = "org-workspace-grant" )
Flag values
Variables ¶
var OrgGrantWorkspaceDescription = func() string { return fmt.Sprintf("grant access to a specific org workspace ID\n %s", style.Secondary("(or 'all' for all workspaces in the org)")) }
OrgGrantWorkspaceDescription is the description for for --org-workspace-grant flag in the run, deploy and install commands This value is a function so that formatting is applied for the help page (when style is enabled).
Functions ¶
func AppExists ¶
appExists returns an error if an app has not yet been created (i.e it doesn't have an App ID)
Note: An app can have an App ID and NOT yet be installed to the workspace because an app's ID is created before it is installed. However historically we have not highlighted the distinction for end users. Therefore the slackerror message text mentions install. In future, if it becomes possible for an enduser to separately manage app creation (manifest.create) and installation (apps.devInstall), this ought to be revisited.
func GetProcessName ¶
func GetProcessName() string
Get the executable process name. This is typically the binary's name. Example: `slack`
func IsFlagChanged ¶
IsFlagChanged checks if a certain flag has been set in the command
func IsSlackHostedProject ¶
func IsSlackHostedProject(ctx context.Context, clients *shared.ClientFactory) error
IsSlackHostedProject determines if the manifest represents a ROSI application
func IsValidProjectDirectory ¶
func IsValidProjectDirectory(clients *shared.ClientFactory) error
IsValidProjectDirectory verifies that a command is run in a valid project directory and returns nil, otherwise returns an error
Types ¶
This section is empty.