You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nheko/.ci/azure-build.yml

82 lines
3.3 KiB

steps:
- bash: mkdir -p ${ARTIFACT_STAGING_DIRECTORY}
env:
ARTIFACT_STAGING_DIRECTORY: $(Build.ArtifactStagingDirectory))
name: createStaging
- bash: |
export CXX=${CXX_COMPILER}
export CC=${C_COMPILER}
# Use TRAVIS_TAG if defined, or the short commit SHA otherwise
export VERSION=${TRAVIS_TAG:-$(git rev-parse --short HEAD)}
./.ci/install.sh
export PATH=/usr/local/bin:${PATH}
./.ci/script.sh
sed -i -e "s/VERSION_NAME_VALUE/${VERSION}/g" ./.ci/bintray-release.json || true
cp ./.ci/bintray-release.json .
env:
ARTIFACT_STAGING_DIRECTORY: $(Build.ArtifactStagingDirectory))
name: build
displayName: build
# - task: CopyFiles@2
# inputs:
# sourceFolder: $(Build.Repository.LocalPath) # Optional
# contents: |
# '**/nheko*.dmg'
# '**/nheko*.AppImage'
# targetFolder: $(Build.ArtifactStagingDirectory)
# #cleanTargetFolder: false # Optional
# overWrite: true # Optional
# flattenFolders: true # Optional
# Create a variable for build success
- bash: |
echo ${ARTIFACT_STAGING_DIRECTORY}
ls ${ARTIFACT_STAGING_DIRECTORY}
env:
ARTIFACT_STAGING_DIRECTORY: $(Build.ArtifactStagingDirectory))
- pwsh: if( (Get-ChildItem $ENV:ARTIFACT_STAGING_DIRECTORY | Measure-Object).Count -eq 0) { echo '##vso[task.setvariable variable=buildSuccess]false' } else { echo '##vso[task.setvariable variable=buildSuccess]true' }
env:
ARTIFACT_STAGING_DIRECTORY: $(Build.ArtifactStagingDirectory))
name: buildCheck
- task: GitHubRelease@0
condition: eq(variables['buildSuccess'], 'true')
continueOnError: true
name: GitHubRelease
inputs:
gitHubConnection: nheko-reborn-pipeline
repositoryName: '$(Build.Repository.Name)'
action: 'create' # Options: create, edit, delete
target: '$(Build.SourceVersion)' # Required when action == Create || Action == Edit
tagSource: 'manual' # Required when action == Create# Options: auto, manual
tag: $(Build.BuildNumber) # Required when action == Edit || Action == Delete || TagSource == Manual
#title: # Optional
#releaseNotesSource: 'file' # Optional. Options: file, input
#releaseNotesFile: CHANGELOG.md # Optional
#releaseNotes: # Optional
#assets: '$(Build.ArtifactStagingDirectory)/*' # Optional
assetUploadMode: 'delete' # Optional. Options: delete, replace
#isDraft: false # Optional
isPreRelease: true # Optional
addChangeLog: true # Optional
# If the release already exists, edit it instead.
- task: GitHubRelease@0
condition: eq(variables['buildSuccess'], 'true')
continueOnError: true
inputs:
gitHubConnection: nheko-reborn-pipeline
repositoryName: '$(Build.Repository.Name)'
action: 'edit' # Options: create, edit, delete
target: '$(Build.SourceVersion)' # Required when action == Create || Action == Edit
tagSource: 'manual' # Required when action == Create# Options: auto, manual
tag: $(Build.BuildNumber) # Required when action == Edit || Action == Delete || TagSource == Manual
#title: # Optional
#releaseNotesSource: 'file' # Optional. Options: file, input
#releaseNotesFile: CHANGELOG.md # Optional
#releaseNotes: # Optional
#assets: '$(Build.ArtifactStagingDirectory)/*' # Optional
assetUploadMode: 'delete' # Optional. Options: delete, replace
#isDraft: false # Optional
isPreRelease: true # Optional
addChangeLog: true # Optional