Skip to content

Commit

Permalink
add log about moved secret
Browse files Browse the repository at this point in the history
  • Loading branch information
emicklei_kramphub committed Apr 4, 2018
1 parent e2e78d1 commit 207a4b7
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
7 changes: 5 additions & 2 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
### 1.4.0
### v1.4.1
- more logging when moving secrets from one to another profile

### v1.4.0
- add filter for list operation (thanks Tom Geurtsen)

### 1.3.5
### v1.3.5
- default generate character set is made URL encoding free
- after generate password copy it to clipboard
- do not log secrets if a command fails
Expand Down
2 changes: 1 addition & 1 deletion cmd_delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func commandDelete(kmsService *cloudkms.Service, storageService *cloudstore.Clie
if err := deleteSecret(storageService, target, key); err != nil {
fmt.Printf("failed to delete [%s] from [%s] because [%v]\n", key, target.Label, err)
} else {
fmt.Printf("successfully deleted [%s] from [%s]\n", key, target.Label)
fmt.Printf("Successfully deleted [%s] from [%s]\n", key, target.Label)
}
} else {
log.Fatalln("delete aborted")
Expand Down
2 changes: 2 additions & 0 deletions cmd_move.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package main

import (
"fmt"
"log"

cloudstore "cloud.google.com/go/storage"
Expand All @@ -24,6 +25,7 @@ func commandMove(
}
// store value for key to target
commandPutPasteGenerate(kmsService, storageService, target, "put", targetKey, sourceValue, true)
fmt.Printf("Successfully copied [%s] to [%s]\n", sourceKey, target.Label)
// delete key from source
commandDelete(kmsService, storageService, source, sourceKey)
}
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"google.golang.org/api/cloudkms/v1"
)

var version = "v1.4.0"
var version = "v1.4.1"

const (
doPrompt = true
Expand Down

0 comments on commit 207a4b7

Please sign in to comment.