mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-23 14:15:13 +00:00
hotfix(pkg): fix edge versioning
This commit is contained in:
parent
056704f17c
commit
2f1e0045cc
@ -27,8 +27,8 @@ async function main() {
|
|||||||
// Step 1: Apply suffixes
|
// Step 1: Apply suffixes
|
||||||
for (const pkg of workspacePackages) {
|
for (const pkg of workspacePackages) {
|
||||||
if (pkg.options.suffix && pkg.options.suffix.length) {
|
if (pkg.options.suffix && pkg.options.suffix.length) {
|
||||||
pkg.suffixAndVersion()
|
await pkg.suffixAndVersion()
|
||||||
pkg.writePackage()
|
await pkg.writePackage()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { resolve } from 'path'
|
import { resolve } from 'path'
|
||||||
import consola from 'consola'
|
import consola from 'consola'
|
||||||
import { spawn } from 'cross-spawn'
|
import spawn from 'cross-spawn'
|
||||||
import { existsSync, readJSONSync, writeFile, copy, remove } from 'fs-extra'
|
import { existsSync, readJSONSync, writeFile, copy, remove } from 'fs-extra'
|
||||||
import _ from 'lodash'
|
import _ from 'lodash'
|
||||||
import { rollup, watch } from 'rollup'
|
import { rollup, watch } from 'rollup'
|
||||||
@ -307,8 +307,8 @@ export default class Package {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async exec(command, args, silent = false) {
|
exec(command, args, silent = false) {
|
||||||
const r = await spawn(command, args.split(' '), { cwd: this.options.rootDir }, { env: process.env })
|
const r = spawn.sync(command, args.split(' '), { cwd: this.options.rootDir }, { env: process.env })
|
||||||
|
|
||||||
if (!silent) {
|
if (!silent) {
|
||||||
const fullCommand = command + ' ' + args
|
const fullCommand = command + ' ' + args
|
||||||
@ -333,13 +333,13 @@ export default class Package {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async gitShortCommit() {
|
gitShortCommit() {
|
||||||
const { stdout } = await this.exec('git', 'rev-parse --short HEAD', true)
|
const { stdout } = this.exec('git', 'rev-parse --short HEAD', true)
|
||||||
return stdout
|
return stdout
|
||||||
}
|
}
|
||||||
|
|
||||||
async gitBranch() {
|
gitBranch() {
|
||||||
const { stdout } = await this.exec('git', 'rev-parse --abbrev-ref HEAD', true)
|
const { stdout } = this.exec('git', 'rev-parse --abbrev-ref HEAD', true)
|
||||||
return stdout
|
return stdout
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user