Skip to content

Commit d057f24

Browse files
✨Added a way to open browser window (raycast#773)
* ✨Added a way to open browser window * 📋 Title-Cased Package Name
1 parent d0f8005 commit d057f24

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/bin/bash
2+
3+
# Required parameters:
4+
# @raycast.schemaVersion 1
5+
# @raycast.title New Browser Window
6+
# @raycast.mode compact
7+
8+
# Optional parameters:
9+
# @raycast.icon 🌐
10+
# @raycast.packageName Browser Utils
11+
12+
# Documentation:
13+
# @raycast.description Open new window in default browser
14+
# @raycast.author Levi Nelson
15+
# @raycast.authorURL https://github.com/LeviticusNelson
16+
17+
# https://stackoverflow.com/a/66026925/13949806
18+
defaultBrowser=$(plutil -p ~/Library/Preferences/com.apple.LaunchServices/com.apple.launchservices.secure.plist | grep 'https' -b3 |awk 'NR==3 {split($4, arr, "\""); print arr[2]}')
19+
open --new -b "$defaultBrowser"

0 commit comments

Comments
 (0)