ci: update preview-publish.ps1

pull/5110/head
mehmet-erim 5 years ago
parent f818db3425
commit 04108a6969

@ -1,10 +0,0 @@
const fse = require('fs-extra');
const commonProps = fse.readFileSync('../common.props').toString();
const versionTag = '<Version>';
const versionEndTag = '</Version>';
const first = commonProps.indexOf(versionTag) + versionTag.length;
const last = commonProps.indexOf(versionEndTag);
console.log(commonProps.substring(first, last));

@ -8,8 +8,8 @@ param(
npm install
$NextVersion = $(node get-version.js)
$rootFolder = (Get-Item -Path "./" -Verbose).FullName
$NextVersion = $(node publish-utils.js --nextVersion)
$RootFolder = (Get-Item -Path "./" -Verbose).FullName
if(-Not $Version) {
$Version = $NextVersion;
@ -34,7 +34,7 @@ foreach ($command in $commands) {
Invoke-Expression $command
if($LASTEXITCODE -ne '0' -And $command -notlike '*cd *'){
Write-Host ("Process failed! " + $command)
Set-Location $rootFolder
Set-Location $RootFolder
exit $LASTEXITCODE
}
}
Loading…
Cancel
Save