2023-07-17 03:23:26 +02:00
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
2023-08-04 00:44:15 +02:00
|
|
|
"fmt"
|
2023-07-17 05:02:29 +02:00
|
|
|
"os"
|
|
|
|
"strings"
|
2023-08-04 00:44:15 +02:00
|
|
|
"time"
|
2023-07-17 05:02:29 +02:00
|
|
|
|
|
|
|
"github.com/quexten/goldwarden/browserbiometrics"
|
2023-07-17 03:23:26 +02:00
|
|
|
"github.com/quexten/goldwarden/cmd"
|
|
|
|
)
|
|
|
|
|
|
|
|
func main() {
|
2023-07-17 05:02:29 +02:00
|
|
|
if len(os.Args) > 1 && strings.Contains(os.Args[1], "com.8bit.bitwarden.json") {
|
|
|
|
browserbiometrics.Main()
|
|
|
|
return
|
|
|
|
}
|
|
|
|
|
2023-08-04 00:44:15 +02:00
|
|
|
if !cmd.IsPolkitSetup() {
|
|
|
|
fmt.Println("Polkit is not setup. Run 'goldwarden setup polkit' to set it up.")
|
|
|
|
time.Sleep(3 * time.Second)
|
|
|
|
}
|
|
|
|
|
2023-07-17 03:23:26 +02:00
|
|
|
cmd.Execute()
|
|
|
|
}
|