Skip to content

Commit

Permalink
fix #3464
Browse files Browse the repository at this point in the history
  • Loading branch information
JeffBezanson committed Jun 20, 2013
1 parent 293be7b commit 5b7df8e
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions base/git.jl
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ end
function read_config_blob(blob::String)
tmp, io = mktemp()
try
write(io, readall(`git cat-file blob $blob`))
write(io, readall(`cat-file blob $blob`))
finally
close(io)
end
Expand All @@ -137,10 +137,10 @@ function write_config(file::String, cfg::Dict)
val = cfg[key]
if isa(val,Array)
for x in val
run(`git config -f $tmp --add $key $x`)
run(`config -f $tmp --add $key $x`)
end
else
run(`git config -f $tmp $key $val`)
run(`config -f $tmp $key $val`)
end
end
if isfile(tmp)
Expand Down Expand Up @@ -197,12 +197,12 @@ const GITHUB_REGEX = r"^(?:git@|git://|https://(?:[\w\.\+\-]+@)?)github.com[:/](
# setup a repo's push URL intelligently

function autoconfig_pushurl()
url = readchomp(`git config remote.origin.url`)
url = readchomp(`config remote.origin.url`)
m = match(GITHUB_REGEX,url)
if m != nothing
pushurl = "git@github.com:$(m.captures[1])"
if pushurl != url
run(`git config remote.origin.pushurl $pushurl`)
run(`config remote.origin.pushurl $pushurl`)
end
end
end
Expand Down

1 comment on commit 5b7df8e

@StefanKarpinski
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops. Thanks for fixing that.

Please sign in to comment.