Skip to content

Commit 14a1016

Browse files
authored
chore: update semantic-release to handle 'main' branch (#10)
* chore: update semantic-release to handle 'main' branch * chore: switch to Azure DevOps for CI
1 parent 14d0e09 commit 14a1016

File tree

5 files changed

+5529
-950
lines changed

5 files changed

+5529
-950
lines changed

.releaserc

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
branches:
2+
- '+([0-9])?(.{+([0-9]),x}).x'
3+
- 'main'
4+
- 'next'
5+
- 'next-major'
6+
- name: 'beta'
7+
prerelease: true
8+
- name: 'alpha'
9+
prerelease: true

.travis.yml

-16
This file was deleted.

azure-pipelines.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
jobs:
2+
- job: Linux
3+
4+
pool:
5+
vmImage: 'Ubuntu 16.04'
6+
7+
steps:
8+
- task: NodeTool@0
9+
inputs:
10+
versionSpec: '10.x'
11+
displayName: 'Install Node.js'
12+
13+
- script: npm ci
14+
displayName: 'Install dependencies'
15+
16+
- script: npm pack
17+
displayName: 'Prepare installable tarball'
18+
condition: succeededOrFailed()
19+
20+
- task: PublishBuildArtifacts@1
21+
displayName: 'Save npm-tarball.tgz'
22+
condition: and(succeededOrFailed(), ne(variables['system.pullrequest.isfork'], true))
23+
inputs:
24+
artifactName: 'npm-tarball.tgz'
25+
PathtoPublish: '$(System.DefaultWorkingDirectory)/git-http-mock-server-0.0.0-development.tgz'
26+
27+
- script: npm run semantic-release
28+
displayName: 'Publish to npm'
29+
condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/main'))
30+
env:
31+
GH_TOKEN: $(GITHUB_TOKEN)
32+
NPM_TOKEN: $(Npm.Token)

0 commit comments

Comments
 (0)