Skip to content

Commit

Permalink
Fix BRAVE_PROFILE usage, unique uuid in plist
Browse files Browse the repository at this point in the history
  • Loading branch information
arbal committed Feb 6, 2021
1 parent c26f631 commit 156e1fa
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 16 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ ch {query}

1. Open workflow `Brave History` in Alfred Workflows tab.
2. Open Workflow Configuration dialog by upper right side button.
3. Set `CHROME_PROFILE` variable with your Brave profile directory name or path such as `Profile 1`.
3. Set `BRAVE_PROFILE` variable with your Brave profile directory name or path such as `Profile 1`.

## License

Expand Down
16 changes: 8 additions & 8 deletions _workflow/info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
<plist version="1.0">
<dict>
<key>bundleid</key>
<string>com.github.pasela.alfred-brave-history</string>
<string>com.github.arbal.alfred-brave-history</string>
<key>category</key>
<string>Internet</string>
<key>connections</key>
<dict>
<key>50B0CD10-4D52-4898-9C05-DD3A34A829C3</key>
<key>80B0CD10-4D52-4898-9C05-DD3A34A829C3</key>
<array>
<dict>
<key>destinationuid</key>
Expand All @@ -33,7 +33,7 @@
</array>
</dict>
<key>createdby</key>
<string>pasela</string>
<string>pasela and arbal</string>
<key>description</key>
<string>Search Brave history</string>
<key>disabled</key>
Expand Down Expand Up @@ -85,7 +85,7 @@
<key>type</key>
<string>alfred.workflow.input.scriptfilter</string>
<key>uid</key>
<string>50B0CD10-4D52-4898-9C05-DD3A34A829C3</string>
<string>80B0CD10-4D52-4898-9C05-DD3A34A829C3</string>
<key>version</key>
<integer>2</integer>
</dict>
Expand Down Expand Up @@ -135,7 +135,7 @@ Search Brave history and open/copy URLs.
You can specify the profile and result limits.
`CHROME_PROFILE` variable is the profile directory name (or path) such as `Default`, `Profile 1`, and so on.
`BRAVE_PROFILE` variable is the profile directory name (or path) such as `Default`, `Profile 1`, and so on.
`LIMIT` variable is the result limit counts.</string>
<key>uidata</key>
Expand All @@ -147,7 +147,7 @@ You can specify the profile and result limits.
<key>ypos</key>
<integer>50</integer>
</dict>
<key>50B0CD10-4D52-4898-9C05-DD3A34A829C3</key>
<key>80B0CD10-4D52-4898-9C05-DD3A34A829C3</key>
<dict>
<key>note</key>
<string>Alfred 3 now supports JSON as the Script Filter output. This is the recommended output.</string>
Expand All @@ -165,8 +165,8 @@ You can specify the profile and result limits.
</dict>
</dict>
<key>version</key>
<string>1.0</string>
<string>2.0</string>
<key>webaddress</key>
<string>https://github.com/pasela/alfred-brave-history</string>
<string>https://github.com/arbal/alfred-brave-history</string>
</dict>
</plist>
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/pasela/alfred-brave-history
module github.com/arbal/alfred-brave-history

go 1.13

Expand Down
4 changes: 2 additions & 2 deletions history/history.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"strings"
"time"

"github.com/arbal/alfred-brave-history/profile"
"github.com/arbal/alfred-brave-history/utils"
_ "github.com/mattn/go-sqlite3"
"github.com/pasela/alfred-brave-history/profile"
"github.com/pasela/alfred-brave-history/utils"
"golang.org/x/text/unicode/norm"
)

Expand Down
2 changes: 1 addition & 1 deletion profile/profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"path/filepath"
"strings"

"github.com/pasela/alfred-brave-history/utils"
"github.com/arbal/alfred-brave-history/utils"
)

const (
Expand Down
4 changes: 2 additions & 2 deletions query.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"os"
"path/filepath"

"github.com/pasela/alfred-brave-history/history"
"github.com/pasela/alfred-brave-history/utils"
"github.com/arbal/alfred-brave-history/history"
"github.com/arbal/alfred-brave-history/utils"
)

func queryHistory(profile, url, title string, limit int) ([]history.Entry, error) {
Expand Down
3 changes: 2 additions & 1 deletion standalone.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@ package main
import (
"flag"
"fmt"
"os"
"strings"
)

func run() error {
var limit int
profile := "Default"
profile := os.Getenv("BRAVE_PROFILE")
flag.StringVar(&profile, "profile", profile, "Brave profile directory")
flag.IntVar(&limit, "limit", 0, "Limit n results")
flag.Parse()
Expand Down

0 comments on commit 156e1fa

Please sign in to comment.