Skip to content

Commit 1c6ea13

Browse files
committed
wip: ci/publish actions
1 parent c843dc1 commit 1c6ea13

File tree

2 files changed

+94
-0
lines changed

2 files changed

+94
-0
lines changed

.github/workflows/publish.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,48 @@ jobs:
3636
run: |
3737
cargo login ${{ secrets.CARGO_TOKEN }}
3838
cargo publish --manifest-path pyroscope_cli/Cargo.toml
39+
publish-pprofrs:
40+
name: Backend: pprofrs
41+
runs-on: ubuntu-latest
42+
if: "startsWith(github.event.release.tag_name, 'pprofrs-')"
43+
steps:
44+
- uses: actions/checkout@v1
45+
- uses: actions-rs/toolchain@v1
46+
with:
47+
toolchain: stable
48+
override: true
49+
- name: publish pprofrs crate
50+
continue-on-error: true
51+
run: |
52+
cargo login ${{ secrets.CARGO_TOKEN }}
53+
cargo publish --manifest-path pyroscope_backends/pyroscope_pprofrs/Cargo.toml
54+
publish-pyroscope:
55+
name: Backend: rbspy
56+
runs-on: ubuntu-latest
57+
if: "startsWith(github.event.release.tag_name, 'rbspy-')"
58+
steps:
59+
- uses: actions/checkout@v1
60+
- uses: actions-rs/toolchain@v1
61+
with:
62+
toolchain: stable
63+
override: true
64+
- name: publish rbspy crate
65+
continue-on-error: true
66+
run: |
67+
cargo login ${{ secrets.CARGO_TOKEN }}
68+
cargo publish --manifest-path pyroscope_backends/pyroscope_rbspy/Cargo.toml
69+
publish-pyroscope:
70+
name: Backend: pyspy
71+
runs-on: ubuntu-latest
72+
if: "startsWith(github.event.release.tag_name, 'pyspy-')"
73+
steps:
74+
- uses: actions/checkout@v1
75+
- uses: actions-rs/toolchain@v1
76+
with:
77+
toolchain: stable
78+
override: true
79+
- name: publish pyspy crate
80+
continue-on-error: true
81+
run: |
82+
cargo login ${{ secrets.CARGO_TOKEN }}
83+
cargo publish --manifest-path pyroscope_backends/pyroscope_pyspy/Cargo.toml

.github/workflows/release.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,16 @@ jobs:
6262
- name: Checkout repository
6363
uses: actions/checkout@v2
6464

65+
- name: Install packages (Ubuntu)
66+
if: matrix.os == 'ubuntu-18.04'
67+
run: |
68+
ci/ubuntu-install-packages
69+
70+
- name: Install packages (macOS)
71+
if: matrix.os == 'macos-latest'
72+
run: |
73+
ci/macos-install-packages
74+
6575
- name: Install Rust
6676
uses: actions-rs/toolchain@v1
6777
with:
@@ -109,3 +119,42 @@ jobs:
109119
asset_path: "pyroscope_cli/target/${{ matrix.target }}/release/pyroscope-cli"
110120
asset_name: "pyroscope-cli"
111121
asset_content_type: application/octet-stream
122+
pprofrs-release:
123+
name: pyroscope-main
124+
runs-on: ubuntu-latest
125+
if: "startsWith(github.ref, 'refs/tags/pprofrs-')"
126+
continue-on-error: true
127+
steps:
128+
- uses: "marvinpinto/[email protected]"
129+
with:
130+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
131+
automatic_release_tag: "${{ github.ref_name }}"
132+
title: "Backend: ${{ github.ref_name }}"
133+
draft: true
134+
prerelease: false
135+
rbspy-release:
136+
name: pyroscope-main
137+
runs-on: ubuntu-latest
138+
if: "startsWith(github.ref, 'refs/tags/rbspy-')"
139+
continue-on-error: true
140+
steps:
141+
- uses: "marvinpinto/[email protected]"
142+
with:
143+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
144+
automatic_release_tag: "${{ github.ref_name }}"
145+
title: "Backend: ${{ github.ref_name }}"
146+
draft: true
147+
prerelease: false
148+
pyspy-release:
149+
name: pyroscope-main
150+
runs-on: ubuntu-latest
151+
if: "startsWith(github.ref, 'refs/tags/pyspy-')"
152+
continue-on-error: true
153+
steps:
154+
- uses: "marvinpinto/[email protected]"
155+
with:
156+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
157+
automatic_release_tag: "${{ github.ref_name }}"
158+
title: "Backend: ${{ github.ref_name }}"
159+
draft: true
160+
prerelease: false

0 commit comments

Comments
 (0)