Skip to content

Commit

Permalink
Add "Open in Chrome Canary" extension.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcgrtz committed Mar 31, 2017
1 parent 8b65bd4 commit 718cce6
Show file tree
Hide file tree
Showing 6 changed files with 65 additions and 2 deletions.
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2014–2016 Marc Görtz <https://marcgoertz.de/>
Copyright (c) 2014–2017 Marc Görtz <https://marcgoertz.de/>

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,14 @@ extensions I use on a regular basis.
fancy Jira icon in PopClip and… abracadabra, there you go!
Additionally the URL is put into your clipboard.

* **Open in Chrome Canary**<br>
This is almost the same extension as
[Open in Chrome](http://pilotmoon.com/popclip/extensions//page/OpenInChrome),
but it opens the current URL in Chrome Canary.

## License

Copyright (c) 2014–2016 Marc Görtz <https://marcgoertz.de/>
Copyright (c) 2014–2017 Marc Görtz <https://marcgoertz.de/>

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
Expand Down
Binary file added open-in-canary.popclipextz
Binary file not shown.
46 changes: 46 additions & 0 deletions src/open-in-canary/Config.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Actions</key>
<array>
<dict>
<key>Image File</key>
<string>chrome.png</string>
<key>Requirements</key>
<array>
<string>httpurls</string>
</array>
<key>Shell Script File</key>
<string>open-in-canary.sh</string>
<key>Title</key>
<string>Open in Chrome Canary</string>
</dict>
</array>
<key>Apps</key>
<array>
<dict>
<key>Check Installed</key>
<true/>
<key>Bundle Identifier</key>
<string>com.google.Chrome.Canary</string>
<key>Link</key>
<string>https://www.google.com/chrome/browser/canary.html</string>
<key>Name</key>
<string>Google Chrome Canary</string>
</dict>
</array>
<key>Blocked Apps</key>
<array>
<string>com.google.Chrome.Canary</string>
</array>
<key>Extension Description</key>
<string>Open the link in Google Chrome Canary.</string>
<key>Extension Identifier</key>
<string>de.marcgoertz.popclip.extension.open-in-canary</string>
<key>Extension Name</key>
<string>Open in Chrome Canary</string>
<key>Version</key>
<integer>1</integer>
</dict>
</plist>
Binary file added src/open-in-canary/chrome.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions src/open-in-canary/open-in-canary.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
COUNT=0
for THIS_URL in $POPCLIP_URLS
do
let COUNT=COUNT+1
if [[ -n "$THIS_URL" ]]; then #if non-empty
echo "Opening [$THIS_URL]"
open -b com.google.Chrome.Canary "$THIS_URL"
fi
if [[ $COUNT -ge 10 ]]; then #limit to 10 so as not to go crazy
break
fi
done

0 comments on commit 718cce6

Please sign in to comment.