2019-03-12 17:31:30 +01:00
|
|
|
image:
|
2019-03-12 19:53:00 +01:00
|
|
|
- Visual Studio 2017
|
2019-03-12 17:31:30 +01:00
|
|
|
- Ubuntu1804
|
|
|
|
|
|
|
|
branches:
|
|
|
|
except:
|
|
|
|
- l10n_master
|
|
|
|
|
|
|
|
stack: node 10
|
|
|
|
|
2019-03-12 19:39:09 +01:00
|
|
|
init:
|
|
|
|
- sh: sudo apt-get update
|
|
|
|
- sh: sudo apt-get -y install pkg-config libxss-dev libsecret-1-dev rpm
|
|
|
|
- ps: |
|
|
|
|
if($isWindows) {
|
|
|
|
Install-Product node 10
|
|
|
|
}
|
|
|
|
|
2019-03-12 17:31:30 +01:00
|
|
|
install:
|
2019-03-12 17:52:59 +01:00
|
|
|
- ps: |
|
2019-03-13 03:10:40 +01:00
|
|
|
$packageVersion = (Get-Content -Raw -Path .\src\package.json | ConvertFrom-Json).version
|
|
|
|
$prodDeploy = $false
|
|
|
|
if($env:APPVEYOR_REPO_TAG -eq "true" -and $env:APPVEYOR_RE_BUILD -eq "True") {
|
|
|
|
$prodDeploy = $true
|
|
|
|
echo "This is a production deployment."
|
2019-03-12 20:32:16 +01:00
|
|
|
}
|
2019-03-12 17:52:59 +01:00
|
|
|
if($isWindows) {
|
|
|
|
choco install cloc --no-progress
|
|
|
|
cloc --include-lang TypeScript,JavaScript,HTML,Sass,CSS --vcs git
|
|
|
|
}
|
2019-03-12 17:31:30 +01:00
|
|
|
|
|
|
|
before_build:
|
|
|
|
- node --version
|
|
|
|
- npm --version
|
|
|
|
|
|
|
|
build_script:
|
|
|
|
- npm install
|
|
|
|
- ps: |
|
2019-03-12 17:52:59 +01:00
|
|
|
if($isLinux) {
|
2019-03-12 18:46:06 +01:00
|
|
|
npm run dist:lin
|
2019-03-13 03:10:40 +01:00
|
|
|
Push-AppveyorArtifact ./dist/Bitwarden-${packageVersion}-x86_64.AppImage
|
|
|
|
Push-AppveyorArtifact ./dist/bitwarden_${packageVersion}_amd64.snap
|
|
|
|
Push-AppveyorArtifact ./dist/Bitwarden-${packageVersion}-amd64.deb
|
|
|
|
Push-AppveyorArtifact ./dist/Bitwarden-${packageVersion}-x64.freebsd
|
|
|
|
Push-AppveyorArtifact ./dist/Bitwarden-${packageVersion}-x86_64.rpm
|
2019-03-12 17:52:59 +01:00
|
|
|
}
|
|
|
|
else {
|
2019-03-12 18:46:06 +01:00
|
|
|
npm run dist:win:ci
|
2019-03-13 03:10:40 +01:00
|
|
|
Push-AppveyorArtifact .\dist\Bitwarden-Portable-${packageVersion}.exe
|
|
|
|
Push-AppveyorArtifact .\dist\nsis-web\Bitwarden-Installer-${packageVersion}.exe
|
|
|
|
Push-AppveyorArtifact .\dist\Bitwarden-${packageVersion}-x64.appx
|
|
|
|
Push-AppveyorArtifact .\dist\Bitwarden-${packageVersion}-ia32.appx
|
2019-03-12 17:52:59 +01:00
|
|
|
}
|
2019-03-12 19:02:17 +01:00
|
|
|
|
2019-03-12 20:32:16 +01:00
|
|
|
after_build:
|
|
|
|
- ps: |
|
2019-03-13 03:10:40 +01:00
|
|
|
if($prodDeploy) {
|
2019-03-12 21:37:36 +01:00
|
|
|
if($isLinux) {
|
|
|
|
echo "Deploy Linux..."
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
echo "Deploy Windows..."
|
|
|
|
}
|
2019-03-12 20:32:16 +01:00
|
|
|
}
|
|
|
|
|
2019-03-12 19:28:32 +01:00
|
|
|
for:
|
2019-03-12 19:53:00 +01:00
|
|
|
-
|
|
|
|
matrix:
|
2019-03-12 19:28:32 +01:00
|
|
|
only:
|
|
|
|
- image: Visual Studio 2017
|
|
|
|
cache:
|
2019-03-13 03:22:10 +01:00
|
|
|
- '%LOCALAPPDATA%\electron -> appveyor.yml'
|
|
|
|
- '%LOCALAPPDATA%\electron-builder -> appveyor.yml'
|
2019-03-12 19:28:32 +01:00
|
|
|
|
2019-03-12 19:53:00 +01:00
|
|
|
-
|
|
|
|
matrix:
|
2019-03-12 19:28:32 +01:00
|
|
|
only:
|
|
|
|
- image: Ubuntu1804
|
|
|
|
cache:
|
|
|
|
- '/home/appveyor/.cache/electron -> appveyor.yml'
|
|
|
|
- '/home/appveyor/.cache/electron-builder -> appveyor.yml'
|