Skip to content

Instantly share code, notes, and snippets.

@kathampy
Created January 4, 2018 08:41
Show Gist options
  • Save kathampy/0b9f74ab5efaffa473e9c802411d3dbd to your computer and use it in GitHub Desktop.
Save kathampy/0b9f74ab5efaffa473e9c802411d3dbd to your computer and use it in GitHub Desktop.
Runs an instance of pacproxy in the background which terminates with the current shell.
# Runs an instance of pacproxy in the background which terminates with the current shell.
# Requires pacproxy (https://github.com/williambailey/pacproxy/releases).
# Must be sourced in the current shell with the command ". ./pacproxy.sh".
pacproxy -c http://proxy/proxy.pac -l 127.0.0.1:3128 -v & trap 'pkill -P $$' SIGINT SIGTERM EXIT && export HTTP_PROXY=http://127.0.0.1:3128 && export HTTPS_PROXY=$HTTP_PROXY
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment