wow
Some checks failed
CI / check (push) Failing after 2s
CI / list-packages (push) Failing after 2s

This commit is contained in:
암냥 2026-05-26 09:24:30 +09:00
commit c293ad4c67
2 changed files with 41 additions and 26 deletions

View file

@ -7,7 +7,11 @@
outputs = { self, nixpkgs }: outputs = { self, nixpkgs }:
let let
system = "x86_64-linux"; system = [
"x86_64-linux"
"aarch64-darwin"
"x86_64-darwin"
];
# Overlay 정의 # Overlay 정의
overlay = final: prev: { overlay = final: prev: {

View file

@ -1,50 +1,61 @@
{ pkgs, lib, fetchTarball }: { pkgs, lib, fetchurl }:
let let
inherit (pkgs) stdenv; inherit (pkgs) stdenv;
sysAttrs = if stdenv.hostPlatform.isDarwin then sysAttrs =
if stdenv.hostPlatform.isAarch64 then { if stdenv.hostPlatform.isDarwin then
url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-arm64-dmg"; if stdenv.hostPlatform.isAarch64 then {
sha256 = "sha256-K+U6JtVNz1PRzL/0SIEK7RXwQu6LL3p+248Ywbn+mDc="; url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-arm64-dmg";
} else { sha256 = "sha256-K+U6JtVNz1PRzL/0SIEK7RXwQu6LL3p+248Ywbn+mDc=";
url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-x64-dmg"; } else {
sha256 = "sha256-ex0ESS9APZxgc7b96Q7EQbckUXE51LmTqDfsnN07W3I="; url = "https://code.visualstudio.com/sha/download?build=insider&os=darwin-x64-dmg";
} sha256 = "sha256-ex0ESS9APZxgc7b96Q7EQbckUXE51LmTqDfsnN07W3I=";
else { }
url = "https://code.visualstudio.com/sha/download?build=insider&os=linux-x64"; else {
sha256 = "sha256-kE99FyilwwFv3zTCkufGwD3s1WwoJ2krg10l3Xy5PRE="; url = "https://code.visualstudio.com/sha/download?build=insider&os=linux-x64";
}; sha256 = "sha256-kE99FyilwwFv3zTCkufGwD3s1WwoJ2krg10l3Xy5PRE=";
};
src = fetchTarball { src = fetchurl {
inherit (sysAttrs) url sha256; inherit (sysAttrs) url sha256;
}; };
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;
buildInputs = (oldAttrs.buildInputs or []) buildInputs =
++ stdenv.lib.optionals stdenv.hostPlatform.isLinux [ pkgs.krb5 pkgs.libsoup_3 pkgs.webkitgtk_4_1 ]; (oldAttrs.buildInputs or [])
++ lib.optionals stdenv.hostPlatform.isLinux [
pkgs.krb5
pkgs.libsoup_3
pkgs.webkitgtk_4_1
];
prePatch = stdenv.lib.optionalString stdenv.hostPlatform.isLinux '' prePatch = lib.optionalString stdenv.hostPlatform.isLinux ''
${oldAttrs.prePatch or ""} ${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
''; '';
preFixup = if stdenv.hostPlatform.isDarwin then '' preFixup =
${oldAttrs.preFixup or ""} if stdenv.hostPlatform.isDarwin then ''
'' else '' ${oldAttrs.preFixup or ""}
${oldAttrs.preFixup or ""} '' else ''
rm -rf resources/app/node_modules/@github/copilot-linuxmusl-x64 ${oldAttrs.preFixup or ""}
'';
rm -rf resources/app/node_modules/@github/copilot-linuxmusl-x64
'';
meta = (oldAttrs.meta or {}) // { meta = (oldAttrs.meta or {}) // {
mainProgram = if stdenv.hostPlatform.isDarwin then "code-insiders" else "code-insiders"; mainProgram = "code-insiders";
}; };
}) })