initial commit

This commit is contained in:
Alex Xu committed 2026-09-22 17:45:07 -07:00
1 parent bed9382aab
commit fed16a3f16
2 files changed
+62 -24

No files matched your search

+55 -24
View File
@@ -22,47 +22,78 @@ on:
- '.dockerignore' - '.dockerignore'
jobs: jobs:
build: build-appimage:
runs-on: ubuntu-22.04 name: Build AppImage (${{ matrix.arch }})
runs-on: ${{ matrix.runs-on }}
strategy:
matrix:
include:
- runs-on: ubuntu-latest
arch: x86_64
- runs-on: ubuntu-24.04-arm
arch: aarch64
container: ghcr.io/pkgforge-dev/archlinux:latest
steps: steps:
- uses: actions/checkout@v7 - uses: actions/checkout@v7
- name: Prepare container
uses: pkgforge-dev/anylinux-setup-action@v2
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v7 uses: actions/setup-python@v7
with: with:
python-version: 3.11 python-version: 3.11
cache: 'pip' cache: 'pip'
- name: Install python dependencies - name: Install python dependencies
run: | run: |
sudo apt-get update sudo apt-get update
sudo apt-get install -y libpng-dev libjpeg-dev p7zip-full p7zip-rar python3-pip squashfs-tools libfuse2 libxcb-cursor0 sudo apt-get install -y libpng-dev libjpeg-dev p7zip-full p7zip-rar python3-pip squashfs-tools libxcb-cursor0
python -m pip install --upgrade pip certifi pyinstaller --no-binary pyinstaller python -m pip install --upgrade pip
python -m pip install -r requirements.txt python -m pip install -r requirements.txt
- name: build binary
- name: Install kcc
run: | run: |
python setup.py build_binary python -m pip install --break-system-packages .
chmod +x dist/kcc_linux*
# issue with this action, disabled and commented out - name: Determine version
# see https://github.com/AppImageCrafters/build-appimage/issues/5 id: version
# see https://appimage-builder.readthedocs.io/en/latest/intro/install.html#install-appimagetool run: |
# - name: Build AppImage if [[ "${{ github.event_name }}" == "release" ]]; then
# uses: AppImageCrafters/build-appimage-action@master echo "version=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT"
# env: else
# UPDATE_INFO: gh-releases-zsync|ciromattia|kcc|latest|*x86_64.AppImage.zsync echo "version=dev-${GITHUB_SHA::7}" >> "$GITHUB_OUTPUT"
# with: fi
# recipe: AppImageBuilder.yml
- name: Build AppImage - name: Build AppImage
env:
ARCH: ${{ matrix.arch }}
ICON: ${{ github.workspace }}/icons/comic2ebook.png
DESKTOP: ${{ github.workspace }}/packaging/appimage/kcc.desktop
DEPLOY_PYTHON: 1
OUTPATH: ${{ github.workspace }}/dist
OUTNAME: kcc-${{ steps.version.outputs.version }}-${{ matrix.arch }}.AppImage
run: | run: |
wget -O appimage-builder-x86_64.AppImage https://github.com/AppImageCrafters/appimage-builder/releases/download/v1.1.0/appimage-builder-1.1.0-x86_64.AppImage mkdir -p dist
chmod +x appimage-builder-x86_64.AppImage quick-sharun "$(which cli-chess)"
sudo mv appimage-builder-x86_64.AppImage /usr/local/bin/appimage-builder quick-sharun --make-appimage
appimage-builder --recipe AppImageBuilder.yml --skip-test
- name: Test AppImage
run: |
quick-sharun --simple-test ./dist/*.AppImage
env: env:
UPDATE_INFO: gh-releases-zsync|ciromattia|kcc|latest|*x86_64.AppImage.zsync UPDATE_INFO: gh-releases-zsync|ciromattia|kcc|latest|*x86_64.AppImage.zsync
- name: upload artifact - name: upload artifact
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
name: AppImage name: kcc-${{ steps.version.outputs.version }}-${{ matrix.arch }}
path: './*.AppImage*' path: |
dist/*.AppImage
dist/*.AppImage.zsync
- name: Release - name: Release
uses: softprops/action-gh-release@v3 uses: softprops/action-gh-release@v3
if: startsWith(github.ref, 'refs/tags/') if: startsWith(github.ref, 'refs/tags/')
@@ -70,5 +101,5 @@ jobs:
prerelease: true prerelease: true
generate_release_notes: false generate_release_notes: false
files: | files: |
LICENSE.txt dist/*.AppImage
*.AppImage* dist/*.AppImage.zsync
+7
View File
@@ -0,0 +1,7 @@
[Desktop Entry]
Name=kcc
Comment=Optimize comics/manga for eink
Exec=kcc
Icon=comic2ebook
Type=Application
Terminal=false