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

fix: install zpm 0.9+ in current namespace #465

Merged
merged 1 commit into from
Apr 25, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/%ZPM/PackageManager.cls
Original file line number Diff line number Diff line change
Expand Up @@ -1543,10 +1543,6 @@ ClassMethod Install(ByRef pCommandInfo) [ Internal ]
}
If (tModuleName = "") {
Quit $$$OK
}
If (tModuleName = "zpm") {
New $Namespace
Set $Namespace="%SYS"
}
If tRegistry = "" {
Set tServer = ##class(%ZPM.PackageManager.Client.RemoteServerDefinition).DeploymentServerOpen(1,,.tSC)
Expand Down Expand Up @@ -1601,6 +1597,11 @@ ClassMethod Install(ByRef pCommandInfo) [ Internal ]
$$$ThrowStatus($$$ERROR($$$GeneralError, "Deployed package '" _ tModuleName _ "' " _ tResult.VersionString _ " not supported on this platform " _ platformVersion _ "."))
}
}
If (tModuleName = "zpm") && (tResult.VersionString < 0.9) {
// Pre-%IPM, install zpm in %SYS.
New $Namespace
Set $Namespace="%SYS"
}
$$$ThrowOnError(##class(%ZPM.PackageManager.Developer.Utils).LoadQualifiedReference(tResult, .tParams))
}
} Else {
Expand Down Expand Up @@ -2534,4 +2535,3 @@ ClassMethod DisplayModules(ByRef pList, pNumbered As %Boolean = 0, pWithNamespac
}

}

Loading