mirror of
https://github.com/cmderdev/cmder.git
synced 2024-11-10 09:49:12 +08:00
create save to directory if it doesn't exist
This commit is contained in:
parent
2189fe9483
commit
28e42104ac
@ -1,6 +1,6 @@
|
|||||||
<#
|
<#
|
||||||
.Synopsis
|
.Synopsis
|
||||||
Pack cmder
|
Pack Cmder
|
||||||
.DESCRIPTION
|
.DESCRIPTION
|
||||||
Use this script to pack cmder into release archives
|
Use this script to pack cmder into release archives
|
||||||
|
|
||||||
@ -36,7 +36,6 @@ Param(
|
|||||||
)
|
)
|
||||||
|
|
||||||
$cmderRoot = Resolve-Path $cmderRoot
|
$cmderRoot = Resolve-Path $cmderRoot
|
||||||
$saveTo = Resolve-Path $saveTo
|
|
||||||
|
|
||||||
. "$PSScriptRoot\utils.ps1"
|
. "$PSScriptRoot\utils.ps1"
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
@ -51,6 +50,12 @@ $targets = @{
|
|||||||
Delete-Existing "..\Version*"
|
Delete-Existing "..\Version*"
|
||||||
Delete-Existing "..\build\*"
|
Delete-Existing "..\build\*"
|
||||||
|
|
||||||
|
If(-not (Test-Path -PathType container $saveTo)) {
|
||||||
|
New-Item -ItemType Directory -Path $saveTo
|
||||||
|
}
|
||||||
|
|
||||||
|
$saveTo = Resolve-Path $saveTo
|
||||||
|
|
||||||
$version = Get-VersionStr
|
$version = Get-VersionStr
|
||||||
(New-Item -ItemType file "$cmderRoot\Version $version") | Out-Null
|
(New-Item -ItemType file "$cmderRoot\Version $version") | Out-Null
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user