This commit is contained in:
Kyle Spearrin 2019-03-12 23:51:03 -04:00
parent e33e4f7044
commit 51215577a2
1 changed files with 10 additions and 6 deletions

View File

@ -20,9 +20,9 @@ init:
install:
- ps: |
$PACKAGE_VERSION = (Get-Content -Raw -Path .\src\package.json | ConvertFrom-Json).version
$PROD_DEPLOY = $false
$PROD_DEPLOY = "false"
if($env:APPVEYOR_REPO_TAG -eq "true" -and $env:APPVEYOR_RE_BUILD -eq "True") {
$PROD_DEPLOY = $true
$PROD_DEPLOY = "true"
echo "This is a production deployment."
}
if($isWindows) {
@ -30,11 +30,10 @@ install:
cloc --include-lang TypeScript,JavaScript,HTML,Sass,CSS --vcs git
}
- sh: |
echo "prod deploy: ${PROD_DEPLOY}"
if [ "${SNAP_TOKEN}" != "" ]
then
echo "login to snap"
echo "$SNAP_TOKEN" | snapcraft login --with -
snapcraft whoami
fi
before_build:
@ -62,7 +61,7 @@ build_script:
after_build:
- ps: |
if($PROD_DEPLOY) {
if($PROD_DEPLOY -eq "true") {
if($isLinux) {
echo "Deploy Linux..."
}
@ -70,6 +69,11 @@ after_build:
echo "Deploy Windows..."
}
}
- sh: |
if [ "${SNAP_TOKEN}" != "" ]
then
snapcraft logout
fi
for:
-