mirror of
https://github.com/helmfile/helmfile.git
synced 2026-10-22 03:02:07 +02:00
added option for --no-hooks for helm diff and apply (#279)
* added option for --no-hooks for helm diff and apply Signed-off-by: Arpan Adhikari <kcarpan5@gmail.com> * test case for --no-hooks Signed-off-by: Arpan Adhikari <kcarpan5@gmail.com> * fix test fails Signed-off-by: Arpan Adhikari <kcarpan5@gmail.com> * Resolve conflict with main Signed-off-by: Arpan Adhikari <kcarpan5@gmail.com> * fixup! Resolve conflict with main Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * Add no-hooks case for diff test Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> * fixup! Add no-hooks case for diff test Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> Signed-off-by: Arpan Adhikari <kcarpan5@gmail.com> Signed-off-by: Yusuke Kuoka <ykuoka@gmail.com> Co-authored-by: Arpan Adhikari <arpan@thephotostudio.com.au> Co-authored-by: Yusuke Kuoka <ykuoka@gmail.com>
This commit is contained in:
co-authored by
Arpan Adhikari
Yusuke Kuoka
parent
b8cf0f156e
commit
e1ca846772
@@ -32,6 +32,7 @@ type diffConfig struct {
|
||||
suppress []string
|
||||
suppressSecrets bool
|
||||
showSecrets bool
|
||||
noHooks bool
|
||||
suppressDiff bool
|
||||
noColor bool
|
||||
context int
|
||||
@@ -95,6 +96,10 @@ func (a diffConfig) ShowSecrets() bool {
|
||||
return a.showSecrets
|
||||
}
|
||||
|
||||
func (a diffConfig) NoHooks() bool {
|
||||
return a.noHooks
|
||||
}
|
||||
|
||||
func (a diffConfig) SuppressDiff() bool {
|
||||
return a.suppressDiff
|
||||
}
|
||||
@@ -143,6 +148,7 @@ func TestDiff(t *testing.T) {
|
||||
type flags struct {
|
||||
skipNeeds bool
|
||||
includeNeeds bool
|
||||
noHooks bool
|
||||
}
|
||||
|
||||
testcases := []struct {
|
||||
@@ -1377,6 +1383,7 @@ changing working directory back to "/path/to"
|
||||
detailedExitcode: tc.detailedExitcode,
|
||||
skipNeeds: tc.flags.skipNeeds,
|
||||
includeNeeds: tc.flags.includeNeeds,
|
||||
noHooks: tc.flags.noHooks,
|
||||
})
|
||||
|
||||
var diffErrStr string
|
||||
|
||||
Reference in New Issue
Block a user