Skip to content

Commit 2f5669b

Browse files
authored
Merge pull request #670 from psafont/private/paus/yangtze-bow
Add release capabilities to the yangtze branch
2 parents 1649dfe + 4b5e534 commit 2f5669b

File tree

4 files changed

+44
-1
lines changed

4 files changed

+44
-1
lines changed

.github/workflows/lcm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
run: sudo apt-get update
1818

1919
- name: Checkout
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121

2222
- name: Check whether there are unlicensed packages
2323
run: tools/license-check.sh

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Create release from tag
2+
3+
on:
4+
push:
5+
tags:
6+
- '6.*'
7+
8+
jobs:
9+
release:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
with:
14+
fetch-depth: 0
15+
16+
- name: Install opam
17+
run: sudo apt-get install -y opam
18+
19+
- name: Collect licenses
20+
run: ./tools/print-licenses.sh > licenses.txt
21+
22+
- name: Archive upstream libraries
23+
run: make archive
24+
25+
- name: Create release ${{ github.ref_name }}
26+
run: |
27+
gh release create ${{ github.ref_name }} --repo ${{ github.repository }} --generate-notes \
28+
licenses.txt xs-opam-repo-${{ github.ref_name }}.tar.gz
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
cache
2+
cache.log
23
xs-opam-repo-*/
34
xs-opam-repo-*

tools/print-licenses.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#! /bin/bash
2+
# emit licenses for toolstack packages, needs to be run at the root of the
3+
# project
4+
5+
set -e
6+
7+
for file in packages/{upstream,xs}/*/opam;
8+
do
9+
name=$(basename ${file%%.*})
10+
license=$(grep 'license: ' $file | awk -F ': ' '{print $2}')
11+
echo $name: $license
12+
done

0 commit comments

Comments
 (0)