1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-11-15 16:56:08 -05:00
v2fly/azure-pipelines.yml
Loyalsoldier dcf368bd93
Refine Azure Pipelines & Bazel: remove unnecessary steps (#246)
* Bazel: remove GPG sign
* Azure Pipelines: remove unnecessary steps
2020-10-02 16:09:33 +08:00

63 lines
1.7 KiB
YAML

trigger:
batch: true
branches:
include:
- master
- dev*
- refs/tags/*
pool:
vmImage: 'ubuntu-latest'
variables:
- group: GithubToken
- name: GOPATH
value: '$(system.defaultWorkingDirectory)/gopath'
- name: BAZEL_VER
value: '3.5.0'
steps:
- checkout: self
- task: GoTool@0
inputs:
version: '1.15.2'
- script: |
go version
mkdir -p $GOPATH/src/v2ray.com
ln -s $(pwd) $GOPATH/src/v2ray.com/core
ls -lah $GOPATH/src/v2ray.com/core
cd $GOPATH/src/v2ray.com/core || exit 1
go mod download
workingDirectory: '$(system.defaultWorkingDirectory)'
displayName: 'Fetch sources'
- script: |
cd ./src/v2ray.com/core || exit 1
bazel build --action_env=GOPATH=$GOPATH --action_env=PATH=$PATH --action_env=SPWD=$PWD --action_env=GOCACHE=$(go env GOCACHE) --spawn_strategy local //release:all
workingDirectory: '$(GOPATH)'
displayName: 'Build Binaries'
- script: |
cd ./src/v2ray.com/core || exit 1
echo $RELEASE_TAG
./release/bleedingrelease.sh
workingDirectory: '$(GOPATH)'
displayName: 'Generate Bleeding Edge Release'
env:
GITHUB_TOKEN: $(GITHUB_TOKEN)
PRERELEASE: true
RELEASE_TAG: unstable-$(Build.SourceVersion)
RELEASE_SHA: $(Build.SourceVersion)
TRIGGER_REASON: $(Build.SourceBranch)
GITHUB_REPO_OWNER: v2fly
GITHUB_REPO_NAME: v2ray-core
- script: |
cd ./src/v2ray.com/core || exit 1
echo $RELEASE_TAG
./release/tagrelease.sh
workingDirectory: '$(GOPATH)'
displayName: 'Generate Tag Release'
env:
GITHUB_TOKEN: $(GITHUB_TOKEN)
PRERELEASE: true
RELEASE_TAG: unstable-$(Build.SourceVersion)
TRIGGER_REASON: $(Build.SourceBranch)