-
-
Save albertski/c1deff6bca016243eac2f6a747db75de to your computer and use it in GitHub Desktop.
A command line utility to open a url with a bunch of different screen widths (and organize the windows).
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
display_usage() { | |
echo "This script should be run with one argument." | |
echo "Example: rwulr http://www.siteurl.com" | |
} | |
if [ $# -le 0 ] | |
then | |
display_usage | |
exit 1 | |
fi | |
if [[ ( $@ == "--help") || $@ == "-h" ]] | |
then | |
display_usage | |
exit 0 | |
fi | |
open -n -g -a "Google Chrome" --args --new-window --profile-directory=Profile\ 1 --app="data:text/html,<html><body><script>window.moveTo(0,0);window.resizeTo(320,1395);window.location='$1';</script></body></html>" | |
open -n -g -a "Google Chrome" --args --new-window --profile-directory=Profile\ 1 --app="data:text/html,<html><body><script>window.moveTo(330,0);window.resizeTo(480,1395);window.location='$1';</script></body></html>" | |
open -n -g -a "Google Chrome" --args --new-window --profile-directory=Profile\ 1 --app="data:text/html,<html><body><script>window.moveTo(815,0);window.resizeTo(640,1395);window.location='$1';</script></body></html>" | |
open -n -g -a "Google Chrome" --args --new-window --profile-directory=Profile\ 1 --app="data:text/html,<html><body><script>window.moveTo(1460,0);window.resizeTo(800,1395);window.location='$1';</script></body></html>" | |
open -n -g -a "Google Chrome" --args --new-window --profile-directory=Profile\ 1 --app="data:text/html,<html><body><script>window.moveTo(2265,0);window.resizeTo(1024,1395);window.location='$1';</script></body></html>" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment