Compare commits
No commits in common. "main" and "update/flake-lock-2026-05-25" have entirely different histories.
main
...
update/fla
5 changed files with 48 additions and 280 deletions
|
|
@ -4,6 +4,7 @@ on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
check:
|
check:
|
||||||
|
|
|
||||||
|
|
@ -1,81 +0,0 @@
|
||||||
name: Pull Request
|
|
||||||
|
|
||||||
on:
|
|
||||||
pull_request:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
check:
|
|
||||||
runs-on: x86_64
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Check flake
|
|
||||||
run: |
|
|
||||||
source /etc/bashrc
|
|
||||||
nix flake check
|
|
||||||
|
|
||||||
list-packages:
|
|
||||||
runs-on: x86_64
|
|
||||||
outputs:
|
|
||||||
packages: ${{ steps.set-matrix.outputs.packages }}
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
- id: set-matrix
|
|
||||||
run: |
|
|
||||||
source /etc/bashrc
|
|
||||||
ALL_PACKAGES=$(nix flake show --json | nix run nixpkgs#jq -- -r '.packages."x86_64-linux" | keys[]')
|
|
||||||
|
|
||||||
if [ "${{ github.event_name }}" == "pull_request" ]; then
|
|
||||||
echo "Detecting changed packages for PR..."
|
|
||||||
BASE_REF="${{ github.base_ref }}"
|
|
||||||
# Ensure the base branch is available for diffing
|
|
||||||
git fetch origin "$BASE_REF" --depth=1
|
|
||||||
CHANGED_FILES=$(git diff --name-only "origin/$BASE_REF"...HEAD)
|
|
||||||
|
|
||||||
if echo "$CHANGED_FILES" | grep -qE 'flake.nix|flake.lock'; then
|
|
||||||
echo "Flake files changed, building all packages."
|
|
||||||
SELECTED_PACKAGES=$(echo "$ALL_PACKAGES" | nix run nixpkgs#jq -- -R . | nix run nixpkgs#jq -- -s -c .)
|
|
||||||
else
|
|
||||||
# Extract package names from pkgs/<name>/
|
|
||||||
CHANGED_PKGS=$(echo "$CHANGED_FILES" | grep '^pkgs/' | cut -d'/' -f2 | sort -u || true)
|
|
||||||
|
|
||||||
FINAL_PKGS=()
|
|
||||||
for pkg in $CHANGED_PKGS; do
|
|
||||||
if echo "$ALL_PACKAGES" | grep -q "^$pkg$"; then
|
|
||||||
FINAL_PKGS+=("$pkg")
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
if [ ${#FINAL_PKGS[@]} -eq 0 ]; then
|
|
||||||
SELECTED_PACKAGES="[]"
|
|
||||||
else
|
|
||||||
SELECTED_PACKAGES=$(printf '%s\n' "${FINAL_PKGS[@]}" | nix run nixpkgs#jq -- -R . | nix run nixpkgs#jq -- -s -c .)
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
echo "Push event, listing all packages."
|
|
||||||
SELECTED_PACKAGES=$(echo "$ALL_PACKAGES" | nix run nixpkgs#jq -- -R . | nix run nixpkgs#jq -- -s -c .)
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "packages=$SELECTED_PACKAGES" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
build:
|
|
||||||
needs: [check, list-packages]
|
|
||||||
runs-on: x86_64
|
|
||||||
if: ${{ fromJson(needs.list-packages.outputs.packages)[0] != null }}
|
|
||||||
strategy:
|
|
||||||
fail-fast: false
|
|
||||||
matrix:
|
|
||||||
package: ${{ fromJson(needs.list-packages.outputs.packages) }}
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Checkout code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Build package
|
|
||||||
run: |
|
|
||||||
source /etc/bashrc
|
|
||||||
nix build .#${{ matrix.package }}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -7,17 +7,15 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update:
|
update:
|
||||||
runs-on: ubuntu-latest
|
runs-on: x86_64
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Check for new vscode-insiders release
|
- name: Check for new vscode-insiders release
|
||||||
id: check
|
id: check
|
||||||
shell: bash
|
|
||||||
run: |
|
run: |
|
||||||
source /etc/bashrc || true
|
source /etc/bashrc
|
||||||
|
|
||||||
CURRENT_VERSION=$(grep 'version = ' pkgs/vscode-insiders/default.nix | head -1 | grep -oP '"[^"]+"' | tr -d '"')
|
CURRENT_VERSION=$(grep 'version = ' pkgs/vscode-insiders/default.nix | head -1 | grep -oP '"[^"]+"' | tr -d '"')
|
||||||
echo "Current version: $CURRENT_VERSION"
|
echo "Current version: $CURRENT_VERSION"
|
||||||
|
|
@ -27,109 +25,45 @@ jobs:
|
||||||
|
|
||||||
if [ "$CURRENT_VERSION" = "$LATEST_VERSION" ]; then
|
if [ "$CURRENT_VERSION" = "$LATEST_VERSION" ]; then
|
||||||
echo "Already up to date."
|
echo "Already up to date."
|
||||||
echo "updated=false" >> "$GITHUB_OUTPUT"
|
echo "updated=false" >> $GITHUB_OUTPUT
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "New version found: $LATEST_VERSION"
|
echo "New version found: $LATEST_VERSION"
|
||||||
|
echo "latest_version=$LATEST_VERSION" >> $GITHUB_OUTPUT
|
||||||
echo "latest_version=$LATEST_VERSION" >> "$GITHUB_OUTPUT"
|
echo "updated=true" >> $GITHUB_OUTPUT
|
||||||
echo "updated=true" >> "$GITHUB_OUTPUT"
|
|
||||||
|
|
||||||
- name: Update version and sha256
|
- name: Update version and sha256
|
||||||
if: steps.check.outputs.updated == 'true'
|
if: steps.check.outputs.updated == 'true'
|
||||||
id: update
|
id: update
|
||||||
shell: bash
|
|
||||||
run: |
|
run: |
|
||||||
source /etc/bashrc || true
|
source /etc/bashrc
|
||||||
|
|
||||||
LATEST="${{ steps.check.outputs.latest_version }}"
|
LATEST="${{ steps.check.outputs.latest_version }}"
|
||||||
|
URL="https://code.visualstudio.com/sha/download?build=insider&os=linux-x64"
|
||||||
|
|
||||||
fetch_sri() {
|
echo "Fetching new sha256 for VSCode Insiders..."
|
||||||
local url="$1"
|
NEW_SHA256=$(nix-prefetch-url --type sha256 "$URL" 2>/dev/null | tail -1)
|
||||||
|
NEW_SHA256_SRI=$(nix hash convert --hash-algo sha256 --to sri "$NEW_SHA256")
|
||||||
|
echo "New sha256 (SRI): $NEW_SHA256_SRI"
|
||||||
|
|
||||||
HASH=$(nix-prefetch-url --type sha256 "$url" 2>/dev/null | tail -1)
|
sed -i "s|version = \".*\";|version = \"${LATEST}\";|" pkgs/vscode-insiders/default.nix
|
||||||
nix hash convert --hash-algo sha256 --to sri "$HASH"
|
sed -i "s|sha256 = \"sha256-.*\";|sha256 = \"${NEW_SHA256_SRI}\";|" pkgs/vscode-insiders/default.nix
|
||||||
}
|
|
||||||
|
|
||||||
echo "Fetching hashes..."
|
echo "new_sha256=$NEW_SHA256_SRI" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
LINUX_SHA=$(fetch_sri "https://code.visualstudio.com/sha/download?build=insider&os=linux-x64")
|
|
||||||
DARWIN_ARM_SHA=$(fetch_sri "https://code.visualstudio.com/sha/download?build=insider&os=darwin-arm64")
|
|
||||||
DARWIN_X64_SHA=$(fetch_sri "https://code.visualstudio.com/sha/download?build=insider&os=darwin")
|
|
||||||
|
|
||||||
echo "Linux SHA: $LINUX_SHA"
|
|
||||||
echo "Darwin ARM SHA: $DARWIN_ARM_SHA"
|
|
||||||
echo "Darwin x64 SHA: $DARWIN_X64_SHA"
|
|
||||||
|
|
||||||
export LATEST
|
|
||||||
export LINUX_SHA
|
|
||||||
export DARWIN_ARM_SHA
|
|
||||||
export DARWIN_X64_SHA
|
|
||||||
|
|
||||||
python <<'PY'
|
|
||||||
import os
|
|
||||||
import re
|
|
||||||
from pathlib import Path
|
|
||||||
|
|
||||||
path = Path("pkgs/vscode-insiders/default.nix")
|
|
||||||
text = path.read_text()
|
|
||||||
|
|
||||||
text = re.sub(
|
|
||||||
r'version = ".*?";',
|
|
||||||
f'version = "{os.environ["LATEST"]}";',
|
|
||||||
text,
|
|
||||||
count=1
|
|
||||||
)
|
|
||||||
|
|
||||||
text = re.sub(
|
|
||||||
r'(os=darwin-arm64";\s+sha256 = ").*?(";\s+)',
|
|
||||||
rf'\g<1>{os.environ["DARWIN_ARM_SHA"]}\2',
|
|
||||||
text,
|
|
||||||
count=1,
|
|
||||||
flags=re.S
|
|
||||||
)
|
|
||||||
|
|
||||||
text = re.sub(
|
|
||||||
r'(os=darwin";\s+sha256 = ").*?(";\s+)',
|
|
||||||
rf'\g<1>{os.environ["DARWIN_X64_SHA"]}\2',
|
|
||||||
text,
|
|
||||||
count=1,
|
|
||||||
flags=re.S
|
|
||||||
)
|
|
||||||
|
|
||||||
text = re.sub(
|
|
||||||
r'(os=linux-x64";\s+sha256 = ").*?(";\s+)',
|
|
||||||
rf'\g<1>{os.environ["LINUX_SHA"]}\2',
|
|
||||||
text,
|
|
||||||
count=1,
|
|
||||||
flags=re.S
|
|
||||||
)
|
|
||||||
|
|
||||||
path.write_text(text)
|
|
||||||
PY
|
|
||||||
|
|
||||||
echo "linux_sha=$LINUX_SHA" >> "$GITHUB_OUTPUT"
|
|
||||||
echo "darwin_arm_sha=$DARWIN_ARM_SHA" >> "$GITHUB_OUTPUT"
|
|
||||||
echo "darwin_x64_sha=$DARWIN_X64_SHA" >> "$GITHUB_OUTPUT"
|
|
||||||
|
|
||||||
- name: Verify build
|
- name: Verify build
|
||||||
if: steps.check.outputs.updated == 'true'
|
if: steps.check.outputs.updated == 'true'
|
||||||
shell: bash
|
|
||||||
run: |
|
run: |
|
||||||
source /etc/bashrc || true
|
source /etc/bashrc
|
||||||
|
NIXPKGS_ALLOW_UNFREE=1 nix build .#vscode-insiders
|
||||||
export NIXPKGS_ALLOW_UNFREE=1
|
|
||||||
|
|
||||||
nix build .#vscode-insiders
|
|
||||||
|
|
||||||
- name: Create Pull Request
|
- name: Create Pull Request
|
||||||
if: steps.check.outputs.updated == 'true'
|
if: steps.check.outputs.updated == 'true'
|
||||||
env:
|
env:
|
||||||
API_FORGEJO_TOKEN: ${{ secrets.API_FORGEJO_TOKEN }}
|
API_FORGEJO_TOKEN: ${{ secrets.API_FORGEJO_TOKEN }}
|
||||||
shell: bash
|
|
||||||
run: |
|
run: |
|
||||||
source /etc/bashrc || true
|
source /etc/bashrc
|
||||||
|
|
||||||
LATEST="${{ steps.check.outputs.latest_version }}"
|
LATEST="${{ steps.check.outputs.latest_version }}"
|
||||||
BRANCH="update/vscode-insiders-${LATEST}"
|
BRANCH="update/vscode-insiders-${LATEST}"
|
||||||
|
|
@ -138,20 +72,16 @@ jobs:
|
||||||
git config user.email "akiyama@mizuki.guru"
|
git config user.email "akiyama@mizuki.guru"
|
||||||
|
|
||||||
git checkout -b "$BRANCH"
|
git checkout -b "$BRANCH"
|
||||||
|
|
||||||
git add pkgs/vscode-insiders/default.nix
|
git add pkgs/vscode-insiders/default.nix
|
||||||
|
|
||||||
git commit -m "pkgs/vscode-insiders: update to ${LATEST}"
|
git commit -m "pkgs/vscode-insiders: update to ${LATEST}"
|
||||||
|
|
||||||
REPO_URL=$(git remote get-url origin | sed 's|https://||')
|
REPO_URL=$(git remote get-url origin | sed 's|https://||')
|
||||||
|
|
||||||
git push "https://oauth2:${API_FORGEJO_TOKEN}@${REPO_URL}" "$BRANCH"
|
git push "https://oauth2:${API_FORGEJO_TOKEN}@${REPO_URL}" "$BRANCH"
|
||||||
|
|
||||||
FORGEJO_HOST=$(echo "$REPO_URL" | cut -d'/' -f1)
|
FORGEJO_HOST=$(echo "$REPO_URL" | cut -d'/' -f1)
|
||||||
REPO_PATH=$(echo "$REPO_URL" | cut -d'/' -f2-)
|
REPO_PATH=$(echo "$REPO_URL" | cut -d'/' -f2-)
|
||||||
|
|
||||||
curl -fsSL \
|
curl -fsSL -X POST \
|
||||||
-X POST \
|
|
||||||
-H "Authorization: token ${API_FORGEJO_TOKEN}" \
|
-H "Authorization: token ${API_FORGEJO_TOKEN}" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
"https://${FORGEJO_HOST}/api/v1/repos/${REPO_PATH}/pulls" \
|
"https://${FORGEJO_HOST}/api/v1/repos/${REPO_PATH}/pulls" \
|
||||||
|
|
@ -159,4 +89,5 @@ jobs:
|
||||||
\"title\": \"pkgs/vscode-insiders: update to ${LATEST}\",
|
\"title\": \"pkgs/vscode-insiders: update to ${LATEST}\",
|
||||||
\"head\": \"${BRANCH}\",
|
\"head\": \"${BRANCH}\",
|
||||||
\"base\": \"main\",
|
\"base\": \"main\",
|
||||||
\"body\": \"Automated update of VSCode Insiders to version \`${LATEST}\`.\n\nLinux SHA:\n\`${{ steps.update.outputs.linux_sha }}\`\n\nDarwin ARM SHA:\n\`${{ steps.update.outputs.darwin_arm_sha }}\`\n\nDarwin x64 SHA:\n\`${{ steps.update.outputs.darwin_x64_sha }}\`\"}"
|
\"body\": \"Automated update of VSCode Insiders to version \`${LATEST}\`.\n\nNew SRI Hash: \`${{ steps.update.outputs.new_sha256 }}\`\"
|
||||||
|
}"
|
||||||
44
flake.nix
44
flake.nix
|
|
@ -7,12 +7,9 @@
|
||||||
|
|
||||||
outputs = { self, nixpkgs }:
|
outputs = { self, nixpkgs }:
|
||||||
let
|
let
|
||||||
supportedSystems = [
|
system = "x86_64-linux";
|
||||||
"x86_64-linux"
|
|
||||||
"aarch64-darwin"
|
# Overlay 정의
|
||||||
"x86_64-darwin"
|
|
||||||
];
|
|
||||||
|
|
||||||
overlay = final: prev: {
|
overlay = final: prev: {
|
||||||
waterfox-bin = final.callPackage ./pkgs/waterfox-bin/default.nix { };
|
waterfox-bin = final.callPackage ./pkgs/waterfox-bin/default.nix { };
|
||||||
xcursor-mizuki = final.callPackage ./pkgs/xcursor-mizuki/default.nix { };
|
xcursor-mizuki = final.callPackage ./pkgs/xcursor-mizuki/default.nix { };
|
||||||
|
|
@ -21,31 +18,22 @@
|
||||||
vscode-insiders = final.callPackage ./pkgs/vscode-insiders/default.nix { };
|
vscode-insiders = final.callPackage ./pkgs/vscode-insiders/default.nix { };
|
||||||
};
|
};
|
||||||
|
|
||||||
forAllSystems = f: nixpkgs.lib.genAttrs supportedSystems (system: f (
|
pkgs = import nixpkgs {
|
||||||
import nixpkgs {
|
inherit system;
|
||||||
inherit system;
|
overlays = [ overlay ];
|
||||||
overlays = [ overlay ];
|
config.allowUnfree = true;
|
||||||
config.allowUnfree = true;
|
};
|
||||||
}
|
|
||||||
));
|
|
||||||
in {
|
in {
|
||||||
overlays.default = overlay;
|
overlays.default = overlay;
|
||||||
|
|
||||||
packages = forAllSystems (pkgs:
|
packages.${system} = {
|
||||||
let
|
inherit (pkgs)
|
||||||
allPkgs = {
|
waterfox-bin
|
||||||
inherit (pkgs)
|
xcursor-mizuki
|
||||||
waterfox-bin
|
pjsk-cursor
|
||||||
xcursor-mizuki
|
helium
|
||||||
pjsk-cursor
|
vscode-insiders;
|
||||||
helium
|
};
|
||||||
vscode-insiders;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
nixpkgs.lib.filterAttrs (name: pkg:
|
|
||||||
nixpkgs.lib.elem pkgs.stdenv.hostPlatform.system (pkg.meta.platforms or [ "x86_64-linux" ])
|
|
||||||
) allPkgs
|
|
||||||
);
|
|
||||||
|
|
||||||
nixConfig = {
|
nixConfig = {
|
||||||
extra-substituters = [
|
extra-substituters = [
|
||||||
|
|
|
||||||
|
|
@ -1,100 +1,29 @@
|
||||||
{ pkgs, lib, fetchurl }:
|
{ pkgs }:
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (pkgs) stdenv;
|
src = fetchTarball {
|
||||||
|
url = "https://code.visualstudio.com/sha/download?build=insider&os=linux-x64";
|
||||||
sysAttrs =
|
sha256 = "04brczgkvpkqrg018wss9z5hk56n4d58r1bd7zq83wsycma9mq2b";
|
||||||
if stdenv.hostPlatform.isDarwin then
|
|
||||||
if stdenv.hostPlatform.isAarch64 then {
|
|
||||||
url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-arm64-dmg";
|
|
||||||
sha256 = "sha256-K+U6JtVNz1PRzL/0SIEK7RXwQu6LL3p+248Ywbn+mDc=";
|
|
||||||
name = "vscode-insiders-darwin-arm64.dmg";
|
|
||||||
} else {
|
|
||||||
url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-x64-dmg";
|
|
||||||
sha256 = "sha256-ex0ESS9APZxgc7b96Q7EQbckUXE51LmTqDfsnN07W3I=";
|
|
||||||
name = "vscode-insiders-darwin-x64.dmg";
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
url = "https://code.visualstudio.com/sha/download?build=insider&os=linux-x64";
|
|
||||||
sha256 = "sha256-kE99FyilwwFv3zTCkufGwD3s1WwoJ2krg10l3Xy5PRE=";
|
|
||||||
name = "vscode-insiders-linux-x64.tar.gz";
|
|
||||||
};
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
inherit (sysAttrs) url sha256 name;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
in
|
in
|
||||||
|
|
||||||
(pkgs.vscode.override {
|
(pkgs.vscode.override {
|
||||||
isInsiders = true;
|
isInsiders = true;
|
||||||
}).overrideAttrs (oldAttrs: {
|
}).overrideAttrs (oldAttrs: {
|
||||||
pname = "vscode-insiders";
|
pname = "vscode-insiders";
|
||||||
version = "1.122.0-insider";
|
version = "1.122.0-insider";
|
||||||
|
isInsiders = true;
|
||||||
inherit src;
|
inherit src;
|
||||||
|
|
||||||
sourceRoot = lib.optionalString stdenv.hostPlatform.isDarwin ".";
|
buildInputs = (oldAttrs.buildInputs or []) ++ [ pkgs.krb5 pkgs.libsoup_3 pkgs.webkitgtk_4_1 ];
|
||||||
|
|
||||||
postUnpack = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
||||||
export sourceRoot="$(ls -d *.app)"
|
|
||||||
chmod -R +w "$sourceRoot"
|
|
||||||
'';
|
|
||||||
|
|
||||||
nativeBuildInputs = (oldAttrs.nativeBuildInputs or [])
|
prePatch = ''
|
||||||
++ lib.optionals stdenv.hostPlatform.isDarwin [ pkgs.undmg pkgs.darwin.xattr ];
|
|
||||||
|
|
||||||
buildInputs =
|
|
||||||
(oldAttrs.buildInputs or [])
|
|
||||||
++ lib.optionals stdenv.hostPlatform.isLinux [
|
|
||||||
pkgs.krb5
|
|
||||||
pkgs.libsoup_3
|
|
||||||
pkgs.webkitgtk_4_1
|
|
||||||
];
|
|
||||||
|
|
||||||
prePatch = if stdenv.hostPlatform.isDarwin then ''
|
|
||||||
${oldAttrs.prePatch or ""}
|
${oldAttrs.prePatch or ""}
|
||||||
|
|
||||||
mkdir -p Contents/Resources/app/node_modules/@vscode/ripgrep/bin
|
|
||||||
touch Contents/Resources/app/node_modules/@vscode/ripgrep/bin/rg
|
|
||||||
'' else if stdenv.hostPlatform.isLinux then ''
|
|
||||||
${oldAttrs.prePatch or ""}
|
|
||||||
|
|
||||||
mkdir -p resources/app/node_modules/@vscode/ripgrep/bin
|
mkdir -p resources/app/node_modules/@vscode/ripgrep/bin
|
||||||
touch resources/app/node_modules/@vscode/ripgrep/bin/rg
|
touch resources/app/node_modules/@vscode/ripgrep/bin/rg
|
||||||
'' else "";
|
|
||||||
|
|
||||||
installPhase = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
||||||
mkdir -p $out/Applications
|
|
||||||
cp -r . $out/Applications/Visual\ Studio\ Code\ -\ Insiders.app
|
|
||||||
|
|
||||||
# Create a wrapper script in bin/ to launch the app
|
|
||||||
mkdir -p $out/bin
|
|
||||||
cat > $out/bin/code-insiders << 'EOF'
|
|
||||||
#!/bin/sh
|
|
||||||
exec "$out/Applications/Visual Studio Code - Insiders.app/Contents/MacOS/Electron" "$@"
|
|
||||||
EOF
|
|
||||||
chmod +x $out/bin/code-insiders
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
preFixup =
|
|
||||||
if stdenv.hostPlatform.isDarwin then ''
|
|
||||||
${oldAttrs.preFixup or ""}
|
|
||||||
|
|
||||||
# Fix executable permissions in the app bundle
|
|
||||||
chmod +x "Contents/MacOS/Electron"
|
|
||||||
find Contents -type f -perm +111 -exec chmod +x {} \;
|
|
||||||
|
|
||||||
# Make the app executable for Gatekeeper/notarization checks
|
|
||||||
xattr -d com.apple.quarantine . 2>/dev/null || true
|
|
||||||
'' else ''
|
|
||||||
${oldAttrs.preFixup or ""}
|
|
||||||
|
|
||||||
rm -rf resources/app/node_modules/@github/copilot-linuxmusl-x64
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = (oldAttrs.meta or {}) // {
|
meta = (oldAttrs.meta or {}) // {
|
||||||
mainProgram = "code-insiders";
|
mainProgram = "code-insiders";
|
||||||
|
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue