Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

julia error when using Pkg.add

Tags:

github

julia

I just install julia in ubuntu and found some problems when I added a package.

julia> Pkg.Add("Gadfly")
ERROR: UndefVarError: Add not defined

I also tried to update julia but an error popped up:

julia> Pkg.update()
INFO: Initializing package repository /home/jing/.julia/v0.5
INFO: Cloning METADATA from git://github.com/JuliaLang/METADATA.jl
fatal: unable to connect to github.com:
github.com[0: 192.30.252.131]: errno=Connection timed out

ERROR: failed process: Process(git clone -q -b metadata-v2 git://github.com/JuliaLang/METADATA.jl METADATA, ProcessExited(128)) [128]
in run at ./process.jl:531
in anonymous at pkg/dir.jl:52
in cd at ./file.jl:22
in init at pkg/dir.jl:50
in cd at pkg/dir.jl:28
in update at ./pkg.jl:45

Could anyone please help me fix this problem? Thanks!!

like image 680
jeanne Avatar asked Jul 03 '26 08:07

jeanne


1 Answers

The key message here is

fatal: unable to connect to github.com:
github.com[0: 192.30.252.131]: errno=Connection timed out

It seems you didn't have an internet connection when this was run. Make sure you have internet and that you can access github on the machine this is running on.

like image 103
Shelvacu Avatar answered Jul 06 '26 11:07

Shelvacu



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!