satisfactorymodmanager: init at 3.0.3 (#348137)

This commit is contained in:
Toma
2025-04-15 11:26:05 -04:00
committed by GitHub
parent 8885cfd290
commit 6b2a649d49
3 changed files with 9839 additions and 0 deletions
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,19 @@
diff --git a/frontend/postcss.config.cjs b/frontend/postcss.config.cjs
index b315cbc..06e5627 100644
--- a/frontend/postcss.config.cjs
+++ b/frontend/postcss.config.cjs
@@ -1,4 +1,3 @@
-const importUrl = require('postcss-import-url');
const postcssPresetEnv = require('postcss-preset-env');
const tailwindCSS = require('tailwindcss');
const tailwindCSSNesting = require('tailwindcss/nesting');
@@ -12,9 +11,6 @@ module.exports = {
},
}),
- importUrl({
- modernBrowser: true,
- }),
tailwindCSSNesting(),
tailwindCSS(),
],
@@ -0,0 +1,93 @@
{
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
nodejs,
pnpm_8,
wails,
wrapGAppsHook3,
glib-networking,
}:
buildGoModule rec {
pname = "satisfactorymodmanager";
version = "3.0.3";
src = fetchFromGitHub {
owner = "satisfactorymodding";
repo = "SatisfactoryModManager";
tag = "v${version}";
hash = "sha256-ndvrgSRblm7pVwnGvxpwtGVMEGp+mqpC4kE87lmt36M=";
};
patches = [
# disable postcss-import-url
./dont-vendor-remote-fonts.patch
# populates the lib/generated directory
./add-generated-files.patch
];
postPatch = ''
# don't generate i18n and graphql code
substituteInPlace frontend/package.json \
--replace-fail '"postinstall":' '"_postinstall":'
'';
nativeBuildInputs = [
nodejs
pnpm_8.configHook
wails
wrapGAppsHook3
];
buildInputs = [
glib-networking
];
# we use env because buildGoModule doesn't forward all normal attrs
# this is pretty hacky
env = {
pnpmDeps = pnpm_8.fetchDeps {
inherit pname version src;
sourceRoot = "${src.name}/frontend";
hash = "sha256-OP+3zsNlvqLFwvm2cnBd2bj2Kc3EghQZE3hpotoqqrQ=";
};
pnpmRoot = "frontend";
};
# running this caches some additional dependencies for the FOD
overrideModAttrs = {
preBuild = ''
wails build
'';
};
proxyVendor = true;
vendorHash = "sha256-3nsJPuwL2Zw/yuHvd8rMSpj9DBBpYUaR19z9TSV/7jg=";
buildPhase = ''
runHook preBuild
wails build
runHook postBuild
'';
installPhase = ''
runHook preInstall
install -Dm755 build/bin/SatisfactoryModManager -t "$out/bin"
runHook postInstall
'';
meta = {
broken = stdenv.hostPlatform.isDarwin;
description = "Mod manager and modloader for Satisfactory";
homepage = "https://github.com/satisfactorymodding/SatisfactoryModManager";
license = lib.licenses.gpl3Only;
mainProgram = "SatisfactoryModManager";
maintainers = with lib.maintainers; [ tomasajt ];
platforms = lib.platforms.linux ++ lib.platforms.darwin;
};
}