Skip to content

Commit

Permalink
feat: hook support bat and powershell in windows (TencentBlueKing#3379)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlkaidChan committed Aug 23, 2024
1 parent d99bd82 commit e0c6f87
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions bcs-services/bcs-bscp/pkg/dal/table/hook.go
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,12 @@ const (

// Python is the type for python hook
Python ScriptType = "python"

// Bat is the type for bat hook
Bat ScriptType = "bat"

// PowerShell is the type for powershell hook
PowerShell ScriptType = "powershell"
)

// ScriptType is the type of hook script
Expand All @@ -163,6 +169,8 @@ func (s ScriptType) Validate() error {
switch s {
case Shell:
case Python:
case Bat:
case PowerShell:
default:
return fmt.Errorf("unsupported hook type: %s", s)
}
Expand Down

0 comments on commit e0c6f87

Please sign in to comment.