Files
setup-script/.gitea/workflows/build.yml
aggarwalakshun 2950f93b38
Some checks failed
Build on Multiple Distributions / build-on-arch (push) Has been cancelled
Build on Multiple Distributions / build-on-debian (push) Has been cancelled
Build on Multiple Distributions / build-on-fedora (push) Has been cancelled
change url
2025-02-11 18:04:48 +05:30

138 lines
3.6 KiB
YAML

name: Build on Multiple Distributions
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-on-arch:
runs-on: ubuntu-latest
container:
image: archlinux:latest
steps:
- name: Install basic dependencies
run: |
pacman -Syu --noconfirm
pacman -S --noconfirm git nodejs npm
- name: Checkout code
run: |
git clone https://gitea.akshun-lab.cc/aggarwalakshun/setup-script.git .
git checkout $GITEA_SHA
- name: Install dependencies
run: |
pacman -S --noconfirm python python-pip binutils
- name: Check for changes
run: |
if ! git diff --name-only $GITEA_BEFORE_SHA $GITEA_SHA; then
echo "No changes detected. Skipping build."
exit 0
fi
- name: Prepare Python environment
run: |
mv /lib/python3*/EXTERNALLY-MANAGED .
pip install --upgrade pip
pip install pyinstaller inquirerpy distro
- name: Build with PyInstaller
run: |
pyinstaller --onefile --add-data "bash/:bash/" --add-data "prompts/:prompts/" --add-data "config/:config/" setup.py
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: arch-setup
path: dist/setup
build-on-debian:
runs-on: ubuntu-latest
container:
image: debian:stable
steps:
- name: Install basic dependencies
run: |
apt update && apt upgrade -y
apt install -y git nodejs npm
- name: Checkout code
run: |
git clone https://gitea.akshun-lab.cc/aggarwalakshun/setup-script.git .
git checkout $GITEA_SHA
- name: Install dependencies
run: |
apt install -y python3 python3-pip binutils
- name: Check for changes
run: |
if ! git diff --name-only $GITEA_BEFORE_SHA $GITEA_SHA; then
echo "No changes detected. Skipping build."
exit 0
fi
- name: Prepare Python environment
run: |
mv /lib/python*/EXTERNALLY-MANAGED .
pip install pyinstaller inquirerpy distro
- name: Build with PyInstaller
run: |
pyinstaller --onefile --add-data "bash/:bash/" --add-data "prompts/:prompts/" --add-data "config/:config/" setup.py
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: debian-setup
path: dist/setup
build-on-fedora:
runs-on: ubuntu-latest
container:
image: fedora:latest
steps:
- name: Install basic dependencies
run: |
dnf up -y
dnf install -y git nodejs npm
- name: Checkout code
run: |
git clone https://gitea.akshun-lab.cc/aggarwalakshun/setup-script.git .
git checkout $GITEA_SHA
- name: Install dependencies
run: |
dnf install -y python python-pip binutils
- name: Check for changes
run: |
if ! git diff --name-only $GITEA_BEFORE_SHA $GITEA_SHA; then
echo "No changes detected. Skipping build."
exit 0
fi
- name: Install Python dependencies
run: |
pip install inquirerpy distro pyinstaller
- name: Build with PyInstaller
run: |
pyinstaller --onefile --add-data "bash/:bash/" --add-data "prompts/:prompts/" --add-data "config/:config/" setup.py
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: fedora-setup
path: dist/setup