Skip to content

Instantly share code, notes, and snippets.

@frnkst
Created November 21, 2024 21:57
Show Gist options
  • Save frnkst/c6ba9529c287b387fb0c6a3516995ab1 to your computer and use it in GitHub Desktop.
Save frnkst/c6ba9529c287b387fb0c6a3516995ab1 to your computer and use it in GitHub Desktop.
function FindProxyForURL(url, host) {
// Bypass proxy for local addresses
if (shExpMatch(host, "*.local")) {
return "DIRECT";
}
// Use proxy for all other requests
return "PROXY proxy.example.com:8080";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment