Last active
June 6, 2017 03:50
-
-
Save zQueal/eebe993527f6b8884cbc9b7d044cfdad to your computer and use it in GitHub Desktop.
A little fish shell function to help build shadowsocks sessions in screen
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
function sshadowsocks --description 'create shadowsocks instance for user' | |
set -x USERNAME $argv[1] | |
set -x PASSWORD (go-shadowsocks2 -keygen 16) | |
set -x PORT $argv[2] | |
screen -dmS (echo $USERNAME"_"$PORT) go-shadowsocks2 -s ss://AEAD_AES_128_GCM:(echo $PASSWORD)@:(echo $PORT) -verbose | |
echo "Password: "$PASSWORD | |
echo "Cipher: AEAD_AES_128_GCM" | |
echo "Port: "$PORT | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment