Files
nixpkgs/pkgs/vibetyper/default.nix
T
2026-11-14 20:52:12 +01:00

51 lines
1.8 KiB
Nix

# last-modified: Fri, 24 Jul 2026 10:50:57 GMT
{
appimageTools,
fetchurl,
lib,
makeWrapper,
}: let
pname = "vibetyper";
version = "1.6.5";
# Upstream publishes to an unversioned URL — ./update.sh watches Last-Modified
# and refreshes the sha256 when the binary changes. Bump `version` manually.
src = fetchurl {
url = "https://cdn.vibetyper.com/releases/linux/VibeTyper.AppImage";
sha256 = "sha256-Z0Jn3rLNfbb/8EnRWO+9xyIjCsyHmU3mBAOpw0ifUbI=";
};
appimageContents = appimageTools.extract {inherit pname version src;};
in
appimageTools.wrapType2 {
inherit pname version src;
nativeBuildInputs = [makeWrapper];
# The AppImage bundles libgcrypt.so.20 but not its dependency
# libgpg-error.so.0, which the FHS env does not provide.
extraPkgs = pkgs: [pkgs.libgpg-error];
extraInstallCommands = ''
# Upstream 1.6.0 renamed the desktop file to "Vibe Typer.desktop"
# (Exec=vibe-typer); install it under the old lowercase name and point
# Exec at the wrapper binary.
install -m 444 -D "${appimageContents}/usr/share/applications/Vibe Typer.desktop" \
$out/share/applications/vibe-typer.desktop
substituteInPlace $out/share/applications/vibe-typer.desktop \
--replace 'Exec=vibe-typer' 'Exec=${pname}'
install -m 444 -D "${appimageContents}/Vibe Typer.png" \
$out/share/icons/hicolor/256x256/apps/vibe-typer.png
wrapProgram $out/bin/${pname} \
--set VIBE_DISABLE_HYPRLAND_INDICATOR_NO_BLUR 1
'';
passthru.updateScript = ./update.sh;
meta = {
description = "VibeTyper - AI-powered typing assistant";
homepage = "https://vibetyper.com";
license = lib.licenses.unfree;
platforms = lib.platforms.linux;
mainProgram = "vibetyper";
};
}