From 987a83afbbe6661b28a2ba030fec3b8c056a21b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A0=D0=B0=D1=81=D1=85=D0=BE=D0=B4=D0=BD=D1=8B=D0=B5=20?= =?UTF-8?q?=D0=BC=D0=B0=D1=82=D0=B5=D1=80=D0=B8=D0=B0=D0=BB=D1=8B?= <78630225+aucub@users.noreply.github.com> Date: Sat, 28 Sep 2024 20:34:17 +0000 Subject: [PATCH 1/2] maintainers: add aucub --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 5431ce9a489d7..89380c2d19bbb 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -2041,6 +2041,12 @@ github = "auchter"; githubId = 1190483; }; + aucub = { + name = "aucub"; + email = "dr56ekgbb@mozmail.com"; + github = "aucub"; + githubId = 78630225; + }; augustebaum = { email = "auguste.apple@gmail.com"; github = "augustebaum"; From 7552231e3555535ed8b7643d405063d4e14b652c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D1=80=D0=B0=D1=81=D1=85=D0=BE=D0=B4=D0=BD=D1=8B=D0=B9=20?= =?UTF-8?q?=D0=BC=D0=B0=D1=82=D0=B5=D1=80=D0=B8=D0=B0=D0=BB?= <78630225+aucub@users.noreply.github.com> Date: Tue, 1 Oct 2024 14:25:27 +0000 Subject: [PATCH 2/2] waveterm: init at 0.8.7 --- pkgs/by-name/wa/waveterm/package.nix | 191 +++++++++++++++++++++++++++ 1 file changed, 191 insertions(+) create mode 100644 pkgs/by-name/wa/waveterm/package.nix diff --git a/pkgs/by-name/wa/waveterm/package.nix b/pkgs/by-name/wa/waveterm/package.nix new file mode 100644 index 0000000000000..450614b5cc253 --- /dev/null +++ b/pkgs/by-name/wa/waveterm/package.nix @@ -0,0 +1,191 @@ +{ + lib, + stdenv, + fetchurl, + makeDesktopItem, + copyDesktopItems, + unzip, + autoPatchelfHook, + atk, + at-spi2-atk, + cups, + libdrm, + gtk3, + pango, + cairo, + libX11, + libXcomposite, + libXdamage, + libXext, + libXfixes, + libXrandr, + mesa, + expat, + libxcb, + alsa-lib, + nss, + nspr, + vips, + wrapGAppsHook3, + udev, + libGL, +}: + +let + inherit (stdenv.hostPlatform) system; + throwSystem = throw "Unsupported system: ${system}"; + + pname = "waveterm"; + version = "0.8.7"; + + suffix = + { + x86_64-linux = "waveterm-linux-x64-${version}.zip"; + aarch64-linux = "waveterm-linux-arm64-${version}.zip"; + x86_64-darwin = "Wave-darwin-universal-${version}.zip "; + aarch64-darwin = "Wave-darwin-arm64-${version}.zip"; + } + .${system} or throwSystem; + + src = fetchurl { + url = "https://github.com/wavetermdev/waveterm/releases/download/v${version}/${suffix}"; + hash = + { + x86_64-linux = "sha256-pWBKZid8sumi/EP3DA5KcLnZsHsuKYK6E6NHXdWKh8s="; + aarch64-linux = "sha256-2paRX+OGPSEktV4S+V43ZE9UgltLYZ+Nyba5/miBQkA="; + x86_64-darwin = "sha256-tsqw597gQIMnQ/OPZhrWwaRliF94KyS+ryajttDLqBA="; + aarch64-darwin = "sha256-PD38UBSNKuv836P/py/CtrLOlddHa0+w7R20YVY4Ybc="; + } + .${system} or throwSystem; + }; + + desktopItems = [ + (makeDesktopItem { + name = "waveterm"; + exec = "waveterm --no-sandbox %U"; + icon = fetchurl { + url = "https://raw.githubusercontent.com/wavetermdev/waveterm/refs/tags/v${version}/build/appicon.png"; + hash = "sha256-qob27/64C9XPBtXghxg5/g0qRaiOUOpuFYL1n7/aEB0="; + }; + startupWMClass = "Wave"; + comment = "Open-Source AI-Native Terminal Built for Seamless Workflows"; + desktopName = "Wave"; + genericName = "Terminal Emulator"; + categories = [ + "Development" + "Utility" + "TerminalEmulator" + ]; + keywords = [ + "developer" + "terminal" + "emulator" + ]; + }) + ]; + + unpackPhase = '' + runHook preUnpack + unzip ${src} -d ./ + runHook postUnpack + ''; + + meta = { + description = "Open-source, cross-platform terminal for seamless workflows"; + homepage = "https://www.waveterm.dev"; + mainProgram = "waveterm"; + sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; + license = lib.licenses.asl20; + platforms = [ + "aarch64-linux" + "aarch64-darwin" + "x86_64-linux" + "x86_64-darwin" + ]; + maintainers = with lib.maintainers; [ aucub ]; + }; + + linux = stdenv.mkDerivation { + inherit + pname + version + src + desktopItems + unpackPhase + ; + + nativeBuildInputs = [ + unzip + copyDesktopItems + autoPatchelfHook + wrapGAppsHook3 + ]; + + buildInputs = [ + atk + at-spi2-atk + cups + libdrm + gtk3 + pango + cairo + libX11 + libXcomposite + libXdamage + libXext + libXfixes + libXrandr + mesa + expat + libxcb + alsa-lib + nss + nspr + vips + ]; + + runtimeDependencies = map lib.getLib [ + udev + ]; + + installPhase = '' + runHook preInstall + mkdir -p $out/waveterm $out/bin + cp -r ./* $out/waveterm/ + runHook postInstall + ''; + + preFixup = '' + makeWrapper $out/waveterm/waveterm $out/bin/waveterm \ + --prefix LD_LIBRARY_PATH : "${ + lib.makeLibraryPath [ + libGL + ] + }" + ''; + }; + + darwin = stdenv.mkDerivation { + inherit + pname + version + src + unpackPhase + meta + ; + + nativeBuildInputs = [ + unzip + ]; + + sourceRoot = "Wave.app"; + + installPhase = '' + runHook preInstall + mkdir -p $out/Applications/Wave.app + cp -R . $out/Applications/Wave.app + runHook postInstall + ''; + }; +in +if stdenv.hostPlatform.isDarwin then darwin else linux