.github: Update GH actions & specify Python version as dependency (#537)

* Update actions

* Use fpm instead of stdeb

* Specify python3 as a dependency

Let's hope we can soon auto-update this version number
This commit is contained in:
Mathis Dröge 2023-01-25 10:23:27 +01:00 committed by GitHub
parent ae05b4c1e5
commit 362287543b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -16,9 +16,9 @@ jobs:
max-parallel: 3 max-parallel: 3
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v3
- uses: actions/setup-python@v2 - uses: actions/setup-python@v4
with: with:
python-version: '3.9' python-version: '3.9'
@ -48,7 +48,7 @@ jobs:
env: env:
PYTHONOPTIMIZE: 1 PYTHONOPTIMIZE: 1
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v3
with: with:
name: ${{ runner.os }}-package name: ${{ runner.os }}-package
path: legendary/dist/* path: legendary/dist/*
@ -57,26 +57,23 @@ jobs:
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v3
- name: Dependencies - name: Dependencies
run: sudo apt install run: |
python3-all sudo apt install ruby
python3-stdeb sudo gem install fpm
dh-python
python3-requests
python3-setuptools
python3-wheel
- name: Webview Dependencies
run: sudo apt install
python3-webview
python3-gi
python3-gi-cairo
gir1.2-gtk-3.0
- name: Build - name: Build
run: python3 setup.py --command-packages=stdeb.command bdist_deb run: fpm
--input-type python
--output-type deb
--python-package-name-prefix python3
--deb-suggests python3-webview
--maintainer "Rodney <rodney@rodney.io>"
--category python
--depends "python3 >= 3.9"
setup.py
- name: Os version - name: Os version
id: os_version id: os_version
@ -84,7 +81,7 @@ jobs:
source /etc/os-release source /etc/os-release
echo ::set-output name=version::$NAME-$VERSION_ID echo ::set-output name=version::$NAME-$VERSION_ID
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v3
with: with:
name: ${{ steps.os_version.outputs.version }}-deb-package name: ${{ steps.os_version.outputs.version }}-deb-package
path: deb_dist/*.deb path: ./*.deb