Add modrinth v0.9.3

This commit is contained in:
Joseph Hanson 2025-02-28 16:57:17 -06:00
parent af474361ef
commit 60fa032842
Signed by: jahanson
SSH key fingerprint: SHA256:vy6dKBECV522aPAwklFM3ReKAVB086rT3oWwiuiFG7o
4 changed files with 11455 additions and 0 deletions

View file

@ -1,6 +1,7 @@
{
config,
pkgs,
myPkgs,
inputs,
...
}: let
@ -16,6 +17,7 @@ in {
fastfetch
gtk3
dconf-editor
myPkgs.modrinth-app-unwrapped
];
hardware.graphics = {

View file

@ -12,6 +12,7 @@ with lib; rec {
# Create custom package set
mkMyPkgs = pkgs: {
borgmatic = pkgs.callPackage ../../nixos/packages/borgmatic {};
modrinth-app-unwrapped = pkgs.callPackage ../../nixos/packages/modrinth {};
};
# main service builder

11333
nixos/packages/modrinth/Cargo.lock generated Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,119 @@
{
lib,
rustPlatform,
fetchFromGitHub,
pkg-config,
wrapGAppsHook,
atk,
bzip2,
cairo,
dbus,
gdk-pixbuf,
glib,
gtk3,
libsoup_3,
openssl,
pango,
rust-jemalloc-sys,
sqlite,
webkitgtk,
xz,
zstd,
stdenv,
darwin,
wayland,
webkitgtk_4_1,
cacert,
cargo-tauri,
desktop-file-utils,
nodejs,
pnpm_9,
}: let
pnpm = pnpm_9;
in
rustPlatform.buildRustPackage rec {
pname = "modrinth-app";
version = "0.9.3";
src = fetchFromGitHub {
owner = "modrinth";
repo = "code";
rev = "v${version}";
hash = "sha256-h+zj4Hm7v8SU6Zy0rIWbOknXVdSDf8b1d4q6M12J5Lc=";
};
cargoLock = {
lockFile = ./Cargo.lock;
outputHashes = {
"wry-0.47.2" = "sha256-zb/BX2UU3Hw87H0m+l3wl6YnCroC+93xMMr+SGl532w=";
};
};
pnpmDeps = pnpm.fetchDeps {
inherit pname version src;
hash = "sha256-nFuPFgwJw38XVxhW0QXmU31o+hqJKGJysnPg2YSg2D0=";
};
nativeBuildInputs = [
pkg-config
wrapGAppsHook
cacert # Required for turbo
cargo-tauri.hook
desktop-file-utils
nodejs
pkg-config
pnpm.configHook
];
buildInputs =
[
atk
bzip2
cairo
dbus
gdk-pixbuf
glib
gtk3
libsoup_3
openssl
pango
rust-jemalloc-sys
sqlite
webkitgtk
xz
zstd
]
++ lib.optionals stdenv.isDarwin [
darwin.apple_sdk.frameworks.AppKit
darwin.apple_sdk.frameworks.CoreFoundation
darwin.apple_sdk.frameworks.CoreGraphics
darwin.apple_sdk.frameworks.CoreServices
darwin.apple_sdk.frameworks.Foundation
darwin.apple_sdk.frameworks.IOKit
darwin.apple_sdk.frameworks.Security
darwin.apple_sdk.frameworks.SystemConfiguration
]
++ lib.optionals stdenv.isLinux [
wayland
webkitgtk_4_1
];
# Tests fail on other, unrelated packages in the monorepo
cargoTestFlags = [
"--package"
"theseus_gui"
];
env = {
OPENSSL_NO_VENDOR = true;
ZSTD_SYS_USE_PKG_CONFIG = true;
};
meta = {
description = "The Modrinth monorepo containing all code which powers Modrinth";
homepage = "https://github.com/modrinth/code";
license = lib.licenses.unfree; # FIXME: nix-init did not find a license
maintainers = with lib.maintainers; [];
mainProgram = "modrinth-app";
};
}