Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pkg not defined - Julia 1.0 #28574

Closed
JackHo327 opened this issue Aug 10, 2018 · 7 comments
Closed

Pkg not defined - Julia 1.0 #28574

JackHo327 opened this issue Aug 10, 2018 · 7 comments

Comments

@JackHo327
Copy link

Hi Team,

I am a new Julia user.

I just installed the Julia 1.0 on my mac, but I found out that it looks like I could not use the Pkg directly?

julia> Pkg
ERROR: UndefVarError: Pkg not defined

julia> Pkg.add("IJupyter")
ERROR: UndefVarError: Pkg not defined
Stacktrace:
 [1] top-level scope at none:0
@pkofod
Copy link
Contributor

pkofod commented Aug 10, 2018

You need to using Pkg first. Note,that usage questions should be directed towards discourse.julialang.org, and also be warned that not all packages are up to date yet, but people are working hard to make it happen. Lastly, welcome to Julia!

@affans
Copy link
Contributor

affans commented Aug 10, 2018

See related issue #28553
I've already submitted a PR with better documentation as suggested.

@JackHo327
Copy link
Author

@affans Oh, I see. That's make sense. I watched the youtube video -- starts at 4:17 -- she just directly use the Pkg.add("IJulia") -- right now, I guess that's the feature of version 0.6.0?

@affans
Copy link
Contributor

affans commented Aug 10, 2018

It works in both 0.6 and 0.7/1.0 however in 0.7/1.0 it now requires a specific import Pkg to use the functionality of the new, overhauled system.

You can also enter the package manager from the repl using ] (and existing out of it using backspace). When it pkg> prompt, you can use add [pkgname] and st to add and look at package status.

@JackHo327
Copy link
Author

@affans Great. Thank you very much.

@rajacsp
Copy link

rajacsp commented Oct 3, 2018

Hi Team,

I am a new Julia user.

I just installed the Julia 1.0 on my mac, but I found out that it looks like I could not use the Pkg directly?

julia> Pkg
ERROR: UndefVarError: Pkg not defined

julia> Pkg.add("IJupyter")
ERROR: UndefVarError: Pkg not defined
Stacktrace:
 [1] top-level scope at none:0

Try this if you face the issue still,
Julia>using Pkg

more:
https://snag.gy/xhZd19.jpg

@sainikhileshreddy
Copy link

I just set up my Julia and IJulia. Setups I followed.

julia> using Pkg
julia> Pkg.add("IJulia")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants