Mercurial > repo
changeset 10391:31fc0eb7ea45
<oerjan> sled bin/url//s,http,https,g
author | HackBot |
---|---|
date | Sat, 11 Mar 2017 01:24:33 +0000 |
parents | d09500035782 |
children | 355a1c8028dc |
files | bin/url |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/bin/url Fri Mar 10 23:57:24 2017 +0000 +++ b/bin/url Sat Mar 11 01:24:33 2017 +0000 @@ -1,14 +1,14 @@ #!/usr/bin/env python import sys, os.path, re, urllib if len(sys.argv) <= 1: - print "http://hackego.esolangs.org/fshg/" + print "https://hackego.esolangs.org/fshg/" else: f = os.path.abspath(sys.argv[1]) f = re.sub(r"^/+hackenv/", "", f) if re.match(r"/|\.hg(?:/|$)",f): sys.exit("File is outside web-viewable filesystem repository.") elif re.match(r"tmp(?:/|$)",f): - print ("http://hackego.esolangs.org/" + urllib.quote(f)) + print ("https://hackego.esolangs.org/" + urllib.quote(f)) else: - print ("http://hackego.esolangs.org/fshg/index.cgi/file/tip/" + + print ("https://hackego.esolangs.org/fshg/index.cgi/file/tip/" + urllib.quote(f))