1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00
jellyfin-web/.ci/azure-pipelines.yml

93 lines
2 KiB
YAML
Raw Normal View History

trigger:
batch: true
branches:
include:
- master
- release-*
tags:
include:
- '*'
2020-03-15 21:53:28 +01:00
pr:
branches:
include:
- '*'
jobs:
2020-03-16 23:30:14 +09:00
- job: build
displayName: 'Build'
pool:
vmImage: 'ubuntu-latest'
2020-03-16 23:30:14 +09:00
strategy:
matrix:
2020-03-16 23:49:56 +09:00
Development:
BuildConfiguration: development
Bundle:
BuildConfiguration: bundle
Standalone:
BuildConfiguration: standalone
maxParallel: 3
2020-03-16 23:30:14 +09:00
steps:
- task: NodeTool@0
displayName: 'Install Node'
inputs:
versionSpec: '10.x'
- script: 'yarn install'
displayName: 'Install Dependencies'
2020-03-17 00:17:46 +09:00
- task: Cache@2
displayName: 'Cache Dependencies'
inputs:
key: 'yarn | yarn.lock'
2020-03-17 00:37:21 +09:00
path: '$(Pipeline.Workspace)/node_modules'
2020-03-17 00:17:46 +09:00
- script: 'yarn build'
displayName: 'Build Development'
condition: eq(variables['BuildConfiguration'], 'development')
2020-02-28 15:15:22 +01:00
- script: 'yarn build'
2020-03-16 23:49:56 +09:00
displayName: 'Build Bundle'
condition: eq(variables['BuildConfiguration'], 'bundle')
- script: 'yarn build --standalone'
displayName: 'Build Standalone'
condition: eq(variables['BuildConfiguration'], 'standalone')
2020-02-28 15:15:22 +01:00
- script: 'test -d dist'
displayName: 'Check Build'
2020-03-16 23:49:56 +09:00
- script: 'mv dist jellyfin-web'
displayName: 'Rename Directory'
condition: succeeded()
- task: PublishPipelineArtifact@1
displayName: 'Publish Release'
condition: succeeded()
inputs:
2020-03-16 23:49:56 +09:00
targetPath: '$(Build.SourcesDirectory)/jellyfin-web'
artifactName: 'jellyfin-web-$(BuildConfiguration)'
- job: lint
displayName: 'Lint'
pool:
vmImage: 'ubuntu-latest'
steps:
- task: NodeTool@0
displayName: 'Install Node'
inputs:
versionSpec: '10.x'
- script: 'yarn install'
displayName: 'Install Dependencies'
- script: 'yarn run lint'
displayName: 'Run ESLint'
2020-01-19 16:05:35 +01:00
2020-03-16 23:30:14 +09:00
- script: 'yarn run stylelint'
displayName: 'Run Stylelint'