Skip to content

Commit

Permalink
Add replaced_by to Schema
Browse files Browse the repository at this point in the history
  • Loading branch information
politas committed Nov 3, 2017
1 parent 714ccb9 commit f6bb8d1
Show file tree
Hide file tree
Showing 11 changed files with 970 additions and 948 deletions.
19 changes: 19 additions & 0 deletions CKAN.schema
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,25 @@
"items" : { "type" : "string" },
"uniqueItems" : true
},
"replaced_by" : {
"description" : "Optional pointer to mod that should be selected instead and treated as an update to this mod",
"type" : "object",
"properties" : {
"name" : {
"description" : "Identifier of the mod",
"$ref" : "#/definitions/identifier"
},
"version" : {
"description" : "Optional version",
"$ref" : "#/definitions/version"
},
"min_version" : {
"description" : "Optional minimum version",
"$ref" : "#/definitions/version"
}
},
"required" : [ "name" ]
},
"resources" : {
"description" : "Additional resources",
"type" : "object",
Expand Down
13 changes: 8 additions & 5 deletions Spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -481,11 +481,14 @@ A list of mods which *conflict* with this mod. The current mod

##### replaced-by

(**v1.22**) This is a way to mark a specific mod identifier as being
obsoleted and tell the client what it has been *replaced by*. It contains a
list of mods that should be selected for installation if this mod is
selected for updating, while this mod is uninstalled. If this mod identifier
is brought back to life, an epoch change should be applied.
(**v1.24**) This is a way to mark a specific mod identifier as being
obsoleted and tell the client what it has been *replaced by*. It contains a
single mod that should be selected for installation if this mod is
selected for updating, while this mod is uninstalled. If this mod identifier
is brought back to life, an epoch change should be applied. A *replaced_by*
relationship should be added to the final release of the mod being replaced.
The listed mod should include a "provides" relationship either to this mod,
or one of this mod's listed "provides".

#### resources

Expand Down
8 changes: 4 additions & 4 deletions Tests/Core/KSP.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ public void Setup()
public void TearDown()
{
if (ksp != null)
{
// Manually dispose of RegistryManager
// For some reason the KSP instance doesn't do this itself causing test failures because the registry
{
// Manually dispose of RegistryManager
// For some reason the KSP instance doesn't do this itself causing test failures because the registry
// lock file is still in use. So just dispose of it ourselves.
CKAN.RegistryManager.Instance(ksp).Dispose();
ksp.Dispose();
}
}

Directory.Delete(ksp_dir, true);
}
Expand Down
Loading

0 comments on commit f6bb8d1

Please sign in to comment.