fix: retarget updater to @mosaic/mosaic (#384)
This commit was merged in pull request #384.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@mosaic/cli",
|
||||
"version": "0.0.16",
|
||||
"version": "0.0.17",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://git.mosaicstack.dev/mosaic/mosaic-stack.git",
|
||||
|
||||
@@ -314,7 +314,8 @@ program
|
||||
.description('Check for and install Mosaic CLI updates')
|
||||
.option('--check', 'Check only, do not install')
|
||||
.action(async (opts: { check?: boolean }) => {
|
||||
const { checkForUpdate, formatUpdateNotice } = await import('@mosaic/mosaic');
|
||||
const { checkForUpdate, formatUpdateNotice, getInstallCommand } =
|
||||
await import('@mosaic/mosaic');
|
||||
const { execSync } = await import('node:child_process');
|
||||
|
||||
console.log('Checking for updates…');
|
||||
@@ -344,7 +345,7 @@ program
|
||||
try {
|
||||
// Relies on @mosaic:registry in ~/.npmrc — do NOT pass --registry
|
||||
// globally or non-@mosaic deps will 404 against the Gitea registry.
|
||||
execSync('npm install -g @mosaic/cli@latest', {
|
||||
execSync(getInstallCommand(result), {
|
||||
stdio: 'inherit',
|
||||
timeout: 60_000,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user