Skip to content

Commit

Permalink
Update to LocalRegistry.jl v0.4 and above
Browse files Browse the repository at this point in the history
  • Loading branch information
ffevotte committed Jul 18, 2023
1 parent bc08ea1 commit ab0dd8f
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "RegistryCLI"
uuid = "41fcc7e7-1908-4925-8240-7eafabf08a75"
authors = ["François Févotte <[email protected]>"]
version = "0.1.0"
version = "0.1.1"
license = "MIT"

[deps]
Expand All @@ -12,6 +12,6 @@ Mustache = "ffc61752-8dc7-55ee-8c37-f3e9cdd09e70"

[compat]
ArgParse = "1.1"
LocalRegistry = "0.3"
LocalRegistry = "0.4, 0.5"
Mustache = "1.0"
julia = "1"
2 changes: 1 addition & 1 deletion src/RegistryCLI.jl
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function add(args)
end

verbose && @info "Registering new version in the registry"
LocalRegistry.register(path, pwd())
LocalRegistry.register(path, registry = pwd())
end

return 0
Expand Down
14 changes: 11 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using RegistryCLI: main
using LibGit2
using RegistryCLI.LibGit2
using Test

function grep(str, file)
Expand All @@ -23,14 +23,22 @@ end
reg_path = joinpath(tmpdir, "registry_local") # Path to local clone

# Create git repo for the public Registry
LibGit2.init(#=path=# reg_url,
#=bare=# true)
repo = LibGit2.init(#=path=# reg_url,
#=bare=# true)
ENV["GIT_AUTHOR_NAME"] = "Test User"
ENV["GIT_AUTHOR_EMAIL"] = "[email protected]"
ENV["GIT_COMMITTER_NAME"] = "Test User"
ENV["GIT_COMMITTER_EMAIL"] = "[email protected]"

# Initialize public Registry
main("create", "--help")
main("-v", "create", reg_url, reg_path,
"--description", "Test registry")

cd(reg_path) do
run(`git push --set-upstream origin master`)
end

@test isfile(joinpath(reg_path, "Registry.toml"))
@test count_commits(reg_path) == 1

Expand Down

2 comments on commit ab0dd8f

@ffevotte
Copy link
Member Author

Choose a reason for hiding this comment

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

@JuliaRegistrator register

Release notes:

Updated to LocalRegistry.jl v0.4 & v0.5

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

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

Registration pull request created: JuliaRegistries/General/87698

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.1 -m "<description of version>" ab0dd8f3c1ee045de5ea444bf47ec80fcbf31e31
git push origin v0.1.1

Please sign in to comment.