]> begriffs open source - freertos/blob - .github/workflows/auto-release.yml
RP2040: Fix compiler warning and comment (#509)
[freertos] / .github / workflows / auto-release.yml
1 name: Kernel-Auto-Release
2
3 on:
4   workflow_dispatch:
5     inputs:
6       commit_id:
7         description: 'Commit ID'
8         required: true
9         default: 'HEAD'
10       version_number:
11         description: 'Version Number (Ex. 10.4.0)'
12         required: true
13         default: '10.4.0'             
14
15 jobs:
16   release-packager:
17     name: Release Packager
18     runs-on: ubuntu-latest
19     steps:
20       # Install python 3
21       - name: Tool Setup
22         uses: actions/setup-python@v2
23         with:
24           python-version: 3.7.10
25           architecture:   x64
26         env:
27           GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
28
29       # Currently FreeRTOS/.github/scripts houses the release script. Download it for upcoming usage
30       - name: Checkout FreeRTOS Release Tools
31         uses: actions/checkout@v2
32         with:
33           repository: FreeRTOS/FreeRTOS
34           path: tools
35       
36       # Simpler git auth if we use checkout action and forward the repo to release script 
37       - name: Checkout FreeRTOS Kernel
38         uses: actions/checkout@v2
39         with: 
40           path: local_kernel
41           fetch-depth: 0
42
43       - name: Release
44         run: |
45           # Configure repo for push
46           git config --global user.name ${{ github.actor }}
47           git config --global user.email ${{ github.actor }}@users.noreply.github.com
48           
49           # Install deps and run
50           pip install -r ./tools/.github/scripts/release-requirements.txt
51           ./tools/.github/scripts/release.py FreeRTOS --kernel-repo-path=local_kernel --kernel-commit=${{ github.event.inputs.commit_id }} --new-kernel-version=${{ github.event.inputs.version_number }}
52           exit $?
53         env:
54             GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}