Re-write argument parsing, implement skeleton of copy functionality

This commit is contained in:
2024-03-01 21:09:56 -05:00
parent 0afcdbb29b
commit 51313eb307
5 changed files with 145 additions and 32 deletions
+21
View File
@@ -0,0 +1,21 @@
package offline
import (
"fmt"
"os"
)
func CopyField(targetLocation string, field rune) {
if isFile, _ := TargetIsFile(targetLocation, true); isFile {
//decryptedEntry := DecryptGPG(targetLocation)
// TODO implement clipboard support (maybe use third-party library?)
fmt.Println("In the future, this will copy " + string(field))
} else {
fmt.Println(AnsiError + "Failed to read \"" + targetLocation + "\" - it is a directory" + AnsiReset)
}
os.Exit(0)
}
func clipClear() {
}