sudo nano ~/.bash_profile
export GLINTT_BROWSER_PROTOCOL ="PATH_TO_CHROME_PORTABLE"
Open Script Editor
Copy the following script.
on open location this_URL
do shell script "open -a $GLINTT_BROWSER_PROTOCOL --args \"" & findAndReplaceInText(this_URL, "glintt://", "") & "\""
end open location
on findAndReplaceInText(theText, theSearchString, theReplacementString)
set AppleScript's text item delimiters to theSearchString
set theTextItems to every text item of theText
set AppleScript's text item delimiters to theReplacementString
set theText to theTextItems as string
set AppleScript's text item delimiters to ""
return theText
end findAndReplaceInText
Export script as Application (File > Export… ) into Applications folder.
Open generated application using “Show Package Contents”.
Navigate into Contents folder. Edit Info.plist and add the following XML to the end of the document.
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>SysPref Handler</string>
<key>CFBundleURLSchemes</key>
<array>
<string>glintt</string>
</array>
</dict>
</array>
sudo nano ~/.bashrc
export GLINTT_BROWSER_PROTOCOL ="PATH_TO_CHROME_PORTABLE"
fullUrl=$1
url=${fullUrl#glintt://}
$GLINTT_BROWSER_PROTOCOL $url
sudo chmod a+x /usr/local/bin/glinttbrowserprotocol
[Desktop Entry]
Name=Proto name
Exec=/usr/local/bin/glinttbrowserprotocol %u
Type=Application
Terminal=false
MimeType=x-scheme-handler/glintt;
sudo update-desktop-database
setx GLINTT_BROWSER_PROTOCOL "PATH_TO_CHROME_PORTABLE"
set GLINTTADDRESS=%1
set GLINTTADDRESS=%GLINTTADDRESS:~10%
start %GLINTT_BROWSER_PROTOCOL% "%glinttaddress%"
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\glintt]
@="URL: glintt"
"URL Protocol"=""
[HKEY_CLASSES_ROOT\glintt\shell]
[HKEY_CLASSES_ROOT\glintt\shell\open]
[HKEY_CLASSES_ROOT\glintt\shell\open\command]
@="\"PATH_TO_BAT_PROTOCOL\" \"%1\""