Skip to content

Instantly share code, notes, and snippets.

@neenaoffline
Created September 21, 2010 09:21
Show Gist options
  • Save neenaoffline/589444 to your computer and use it in GitHub Desktop.
Save neenaoffline/589444 to your computer and use it in GitHub Desktop.
diff --git a/clydelib/aur.lua b/clydelib/aur.lua
index 3b33529..81b98d9 100644
--- a/clydelib/aur.lua
+++ b/clydelib/aur.lua
@@ -15,6 +15,7 @@ function download(host, file, user)
lfs.mkdir("/tmp/clyde-"..user.."/"..foldername)
local f, err = io.open("/tmp/clyde-"..user.."/"..foldername.. "/" ..filename, "w")
local received = 0
+ http.PROXY = os.getenv('http_proxy');
local r, c, h = http.request {
method = "HEAD",
url = "http://" ..host..file
@@ -74,6 +75,7 @@ function getgzip(geturl)
["Accept-Encoding"] = "gzip";
}
+ http.PROXY = os.getenv('http_proxy');
local r, e = http.request {
url = geturl;
sink = ltn12.sink.table(sinktbl);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment