mirror of
https://github.com/lindbergh-loader/lindbergh-loader.git
synced 2026-09-27 09:23:07 +03:00
Check the changelog.
This commit is contained in:
@@ -1,73 +0,0 @@
|
||||
name: Build and Release Lindbergh
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build-and-release:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
# Checkout the repository
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Set up Docker Buildx
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
# Build the Docker image
|
||||
- name: Build Docker image
|
||||
run: |
|
||||
docker build --target lindbergh-build -t lindbergh-loader .
|
||||
|
||||
# Extract build artifacts
|
||||
- name: Extract build artifacts
|
||||
run: |
|
||||
docker create --name lindbergh-builder lindbergh-loader
|
||||
docker cp lindbergh-builder:/output ./build
|
||||
docker rm lindbergh-builder
|
||||
|
||||
# Compress the build directory
|
||||
- name: Compress build directory
|
||||
run: tar -czvf build.tar.gz -C ./build .
|
||||
|
||||
# Archive the build directory as an artifact for debugging
|
||||
- name: Archive build directory
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: build-output
|
||||
path: ./build
|
||||
|
||||
# Create a GitHub release and capture the upload URL (only on push events)
|
||||
- name: Create Release
|
||||
if: github.event_name == 'push'
|
||||
id: create_release
|
||||
uses: actions/create-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: v${{ github.run_number }}
|
||||
release_name: "Build v${{ github.run_number }}"
|
||||
draft: false
|
||||
prerelease: false
|
||||
|
||||
# Upload the compressed build artifact to the release (only on push events)
|
||||
- name: Upload Release Asset
|
||||
if: github.event_name == 'push'
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||
asset_path: ./build.tar.gz
|
||||
asset_name: build.tar.gz
|
||||
asset_content_type: application/gzip
|
||||
@@ -0,0 +1,44 @@
|
||||
name: 📦 Linux Flatpak
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
linux-flatpak-build:
|
||||
name: "Build"
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: ghcr.io/flathub-infra/flatpak-github-actions:kde-6.8
|
||||
options: --privileged
|
||||
timeout-minutes: 60
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
set-safe-directory: ${{ env.GITHUB_WORKSPACE }}
|
||||
|
||||
# Work around container ownership issue
|
||||
- name: Set Safe Directory
|
||||
shell: bash
|
||||
run: git config --global --add safe.directory "*"
|
||||
|
||||
- name: Build Flatpak
|
||||
uses: flathub-infra/flatpak-github-actions/flatpak-builder@master
|
||||
with:
|
||||
bundle: lindbergh-loader.flatpak
|
||||
upload-artifact: false
|
||||
manifest-path: scripts/flatpak/com.github.lindberghloader.yml
|
||||
build-bundle: true
|
||||
verbose: true
|
||||
branch: stable
|
||||
cache: true
|
||||
restore-cache: true
|
||||
cache-key: flatpak-${{ hashFiles('scripts/flatpak/*.yaml') }}
|
||||
|
||||
- name: Upload Flatpak
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: "linux-flatpak"
|
||||
path: "lindbergh-loader.flatpak"
|
||||
@@ -0,0 +1,45 @@
|
||||
name: Build and Release Lindbergh
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build-and-release:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
# Checkout the repository
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Set up Docker Buildx
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
# Build the Docker image
|
||||
- name: Build Docker image
|
||||
run: |
|
||||
docker build --target lindbergh-build -t lindbergh-loader .
|
||||
|
||||
# Extract build artifacts
|
||||
- name: Extract build artifacts
|
||||
run: |
|
||||
docker create --name lindbergh-builder lindbergh-loader
|
||||
docker cp lindbergh-builder:/output ./build
|
||||
docker rm lindbergh-builder
|
||||
|
||||
# Compress the build directory
|
||||
- name: Compress build directory
|
||||
run: tar -czvf build.tar.gz -C ./build .
|
||||
|
||||
# Archive the build directory as an artifact for debugging
|
||||
- name: Archive build directory
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: linux-build
|
||||
path: build.tar.gz
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
name: Automated Builds
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
- '.github/ISSUE_TEMPLATE/*'
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths-ignore:
|
||||
- '**.md'
|
||||
- '.github/ISSUE_TEMPLATE/*'
|
||||
|
||||
jobs:
|
||||
linux-build:
|
||||
name: 💻 Linux
|
||||
uses: "./.github/workflows/linux-build.yml"
|
||||
linux-flatpak:
|
||||
name: 📦 Linux Flatpak
|
||||
uses: "./.github/workflows/flatpak-build.yml"
|
||||
|
||||
create-release:
|
||||
name: 📤 Create Release
|
||||
needs: [linux-build, linux-flatpak]
|
||||
runs-on: ubuntu-22.04
|
||||
if: github.ref == 'refs/heads/main'
|
||||
steps:
|
||||
- name: Download Artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: ./artifacts/
|
||||
|
||||
- name: Display Downloaded Artifacts
|
||||
run: find ./artifacts/
|
||||
|
||||
- name: Create Preview Release
|
||||
if: github.ref == 'refs/heads/main'
|
||||
uses: "marvinpinto/action-automatic-releases@latest"
|
||||
with:
|
||||
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
automatic_release_tag: v${{ github.run_number }}
|
||||
prerelease: false
|
||||
title: "Build v${{ github.run_number }}"
|
||||
files: |
|
||||
./artifacts/linux-flatpak/lindbergh-loader.flatpak
|
||||
./artifacts/linux-build/build.tar.gz
|
||||
Reference in New Issue
Block a user