Skip to content

Commit 7c66f92

Browse files
committed
ci: add semantic-release
1 parent cd96fdc commit 7c66f92

31 files changed

+4757
-0
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules/

.releaserc.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
verifyConditions:
2+
- '@semantic-release/github'
3+
prepare:
4+
- path: '@semantic-release/exec'
5+
shell: pwsh
6+
cmd: |
7+
Update-ModuleManifest -ErrorAction Stop -Path ./PSSourcegraph/PSSourcegraph.psd1 -ModuleVersion '${nextRelease.version}' -ReleaseNotes @'
8+
${nextRelease.notes}
9+
'@.Trim()
10+
publish:
11+
- path: '@semantic-release/exec'
12+
shell: pwsh
13+
cmd: |
14+
& {
15+
$ErrorActionPreference = 'Stop'
16+
Publish-Module -Path ./PSSourcegraph -NuGetApiKey $env:NUGET_API_KEY
17+
ConvertTo-Json @{
18+
name = 'PowerShell Gallery'
19+
url = 'https://www.powershellgallery.com/packages/PSSourcegraph'
20+
}
21+
}
22+
- path: '@semantic-release/github'

.travis.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,19 @@ script:
1818
- pwsh -c 'Import-Module ./PSSourcegraph.psd1'
1919

2020
if: tag IS blank
21+
22+
jobs:
23+
include:
24+
- stage: test
25+
- stage: release
26+
cache:
27+
yarn: true
28+
install:
29+
- yarn --frozen-lockfile
30+
script:
31+
- yarn semantic-release
32+
33+
stages:
34+
- test
35+
- name: release
36+
if: branch = master AND type = push AND fork = false
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)