diff --git a/.github/actions/build-linux-arm/action.yml b/.github/actions/build-linux-arm/action.yml index 6741548a..c37dcf36 100644 --- a/.github/actions/build-linux-arm/action.yml +++ b/.github/actions/build-linux-arm/action.yml @@ -73,6 +73,11 @@ runs: copy_artifact_path: target copy_artifact_dest: target commands: | + # Install Python distutils in the ARM container + sudo apt-get update + sudo apt-get install -y python3-pip python3-setuptools python3-dev + pip3 install setuptools --break-system-packages || pip3 install setuptools + cd target # TODO upgrade node to 20.11.0 to match NODE_VERSION wget https://nodejs.org/dist/v18.16.0/node-v18.16.0-linux-${{ inputs.matrix-name }}.tar.xz diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 29fd960f..51968093 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -84,7 +84,7 @@ jobs: matrix-os: windows-latest matrix-name: win upload-artifact: false - + # ARM Linux: build-linux-armv7l: @@ -97,6 +97,28 @@ jobs: - name: Checkout code uses: actions/checkout@v4 + - name: Set up QEMU and binfmt + run: | + # Install qemu-user-static + sudo apt-get update + sudo apt-get install -y qemu-user-static binfmt-support python3-setuptools + + # Install distutils for node-gyp + sudo apt-get install -y python3-distutils || sudo apt-get install -y python3-dev python-is-python3 + + + # Download and install binfmt configurations + wget https://github.com/qemu/qemu/raw/master/scripts/qemu-binfmt-conf.sh + chmod +x qemu-binfmt-conf.sh + sudo ./qemu-binfmt-conf.sh --qemu-path /usr/bin --qemu-suffix -static --debian + + # Import the binfmt configurations + sudo update-binfmts --import qemu-arm + sudo update-binfmts --import qemu-aarch64 + + # Verify they exist + ls -la /proc/sys/fs/binfmt_misc/qemu-arm* || true + - name: Build ARMv7l uses: ./.github/actions/build-linux-arm env: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d1b9f1c8..68190dc1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -84,6 +84,27 @@ jobs: - name: Checkout code uses: actions/checkout@v4 + - name: Set up QEMU and binfmt + run: | + # Install qemu-user-static + sudo apt-get update + sudo apt-get install -y qemu-user-static binfmt-support python3-setuptools + + # Install distutils for node-gyp + sudo apt-get install -y python3-distutils || sudo apt-get install -y python3-dev python-is-python3 + + # Download and install binfmt configurations + wget https://github.com/qemu/qemu/raw/master/scripts/qemu-binfmt-conf.sh + chmod +x qemu-binfmt-conf.sh + sudo ./qemu-binfmt-conf.sh --qemu-path /usr/bin --qemu-suffix -static --debian + + # Import the binfmt configurations + sudo update-binfmts --import qemu-arm + sudo update-binfmts --import qemu-aarch64 + + # Verify they exist + ls -la /proc/sys/fs/binfmt_misc/qemu-arm* || true + - name: Build ARMv7l uses: ./.github/actions/build-linux-arm env: @@ -134,7 +155,7 @@ jobs: - name: List downloaded artifacts run: ls -R ./artifacts - + - name: Ensure non-empty artifacts run: | echo "Checking for zero-byte files in artifacts/..." diff --git a/app/menus/menu.ts b/app/menus/menu.ts index 9162803f..d3200c2f 100644 --- a/app/menus/menu.ts +++ b/app/menus/menu.ts @@ -65,7 +65,10 @@ export const createMenu = ( Created by Guillermo Rauch Copyright © 2022 Vercel, Inc. - `.split('\n').map(z => z.trim()).join('\n'), + ` + .split('\n') + .map((z) => z.trim()) + .join('\n'), buttons: [], icon: icon as any }); diff --git a/app/ui/window.ts b/app/ui/window.ts index b41dd10b..e65fe317 100644 --- a/app/ui/window.ts +++ b/app/ui/window.ts @@ -27,7 +27,7 @@ import toElectronBackgroundColor from '../utils/to-electron-background-color'; import contextMenuTemplate from './contextmenu'; -if(process.platform === 'darwin') { +if (process.platform === 'darwin') { electronDragClick(); } diff --git a/lib/components/style-sheet.tsx b/lib/components/style-sheet.tsx index e8011fba..bf1faefb 100644 --- a/lib/components/style-sheet.tsx +++ b/lib/components/style-sheet.tsx @@ -1,7 +1,8 @@ import React, {forwardRef} from 'react'; +import {useDevicePixelRatio} from 'use-device-pixel-ratio'; + import type {StyleSheetProps} from '../../typings/hyper'; -import { useDevicePixelRatio } from 'use-device-pixel-ratio'; const StyleSheet = forwardRef((props, ref) => { const {borderColor} = props;