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

gh not defined #24

Closed
sairus7 opened this issue Feb 28, 2024 · 1 comment
Closed

gh not defined #24

sairus7 opened this issue Feb 28, 2024 · 1 comment

Comments

@sairus7
Copy link

sairus7 commented Feb 28, 2024

I've tried code from example, and it gives me the following error:

julia> using ArtifactUtils

julia> tempdir = mktempdir();

julia> write(joinpath(tempdir, "file"), "hello");

julia> artifact_id = artifact_from_directory(tempdir)
SHA1("5481654e3cae0a52752a1ef6eca29ba9c94eda34")

julia> gist = upload_to_gist(artifact_id)
ERROR: UndefVarError: `gh` not defined
Stacktrace:
  [1] with_new_gist(f::ArtifactUtils.var"#11#12"{String}; private::Bool)
    @ ArtifactUtils C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\gistutils.jl:24
  [2] with_new_gist
    @ C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\gistutils.jl:23 [inlined]
  [3] gist_from_file(filepath::String; private::Bool)
    @ ArtifactUtils C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\gistutils.jl:10
  [4] gist_from_file
    @ C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\gistutils.jl:6 [inlined]
  [5] upload_to_gist(artifact_id::Base.SHA1, tarball::String; private::Bool, archive_options::@Kwargs{})
    @ ArtifactUtils C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\ArtifactUtils.jl:172
  [6] upload_to_gist
    @ C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\ArtifactUtils.jl:163 [inlined]
  [7] #32
    @ C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\ArtifactUtils.jl:205 [inlined]
  [8] mktempdir(fn::ArtifactUtils.var"#32#33"{@Kwargs{}, Base.SHA1, String}, parent::String; prefix::String)
    @ Base.Filesystem .\file.jl:766
  [9] mktempdir (repeats 2 times)
    @ .\file.jl:762 [inlined]
 [10] #upload_to_gist#31
    @ C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\ArtifactUtils.jl:204 [inlined]
 [11] upload_to_gist(artifact_id::Base.SHA1)
    @ ArtifactUtils C:\Users\gvg\.julia\packages\ArtifactUtils\OB0c7\src\ArtifactUtils.jl:183
 [12] top-level scope
    @ REPL[15]:1

Then I installed gh, authorized with it, so it works with my private repos. But it doesn't help.
I have Windows 10, Julia 1.10.1.

@giordano
Copy link
Member

This isn't a problem in this package. Downgrade gh_cli_jll to v2.35: JuliaPackaging/Yggdrasil#7765 (comment).

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

2 participants