Skip to content

Commit

Permalink
use subdir to be consistent with existing package key
Browse files Browse the repository at this point in the history
  • Loading branch information
simonbyrne committed Jan 1, 2024
1 parent 9415286 commit 0329c2d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/register.jl
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ function update_versions_file(pkg::Project,
version_info["git-tag-name"] = tag_name
end
if subdir != ""
version_info["git-tree-path"] = subdir
version_info["subdir"] = subdir
end
versions_data[string(pkg.version)] = version_info

Expand All @@ -364,7 +364,7 @@ function update_versions_file(pkg::Project,
return 3
elseif x == "git-tag-name"
return 4
elseif x == "git-tree-path"
elseif x == "subdir"
return 5
elseif x == "yanked"
return 100
Expand Down
4 changes: 2 additions & 2 deletions test/regedit.jl
Original file line number Diff line number Diff line change
Expand Up @@ -304,10 +304,10 @@ end
@test data isa Dict
@test collect(keys(data)) == ["1.0.0"]
@test data["1.0.0"] isa Dict
@test sort!(collect(keys(data["1.0.0"]))) == ["git-commit-sha1", "git-tree-path", "git-tree-sha1"]
@test sort!(collect(keys(data["1.0.0"]))) == ["git-commit-sha1", "git-tree-sha1", "subdir"]
@test data["1.0.0"]["git-tree-sha1"] == tree_hash
@test data["1.0.0"]["git-commit-sha1"] == commit_hash
@test data["1.0.0"]["git-tree-path"] == subdir
@test data["1.0.0"]["subdir"] == subdir

check_versions!(pkg, data, status)
# This version was just registered, should be a complaint now.
Expand Down

0 comments on commit 0329c2d

Please sign in to comment.