diff --git a/flake.lock b/flake.lock index f3fb695..28aaf48 100644 --- a/flake.lock +++ b/flake.lock @@ -50,11 +50,11 @@ ] }, "locked": { - "lastModified": 1768597968, - "narHash": "sha256-WdkoFB2QyMkZOmsi/08394clBRyEtNseH+jYGUs9eDU=", + "lastModified": 1771534639, + "narHash": "sha256-I6OHmwXmDdAbWObZ8poKUUXinENW0lh1EtOy9As/+PE=", "owner": "cachix", "repo": "devenv", - "rev": "92ad9c70fad164e8f4a3656dec91717a5c42cd98", + "rev": "5f81ecdb9424823142affe92e9d1a52c778324c0", "type": "github" }, "original": { @@ -102,11 +102,11 @@ ] }, "locked": { - "lastModified": 1768135262, - "narHash": "sha256-PVvu7OqHBGWN16zSi6tEmPwwHQ4rLPU9Plvs8/1TUBY=", + "lastModified": 1769996383, + "narHash": "sha256-AnYjnFWgS49RlqX7LrC4uA+sCCDBj0Ry/WOJ5XWAsa0=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "80daad04eddbbf5a4d883996a73f3f542fa437ac", + "rev": "57928607ea566b5db3ad13af0e57e921e6b12381", "type": "github" }, "original": { @@ -139,11 +139,11 @@ ] }, "locked": { - "lastModified": 1767281941, - "narHash": "sha256-6MkqajPICgugsuZ92OMoQcgSHnD6sJHwk8AxvMcIgTE=", + "lastModified": 1770726378, + "narHash": "sha256-kck+vIbGOaM/dHea7aTBxdFYpeUl/jHOy5W3eyRvVx8=", "owner": "cachix", "repo": "git-hooks.nix", - "rev": "f0927703b7b1c8d97511c4116eb9b4ec6645a0fa", + "rev": "5eaaedde414f6eb1aea8b8525c466dc37bba95ae", "type": "github" }, "original": { @@ -199,11 +199,11 @@ ] }, "locked": { - "lastModified": 1768491252, - "narHash": "sha256-ZlIPlKCYXwQJsw9WYVeyCapF5Y8JZL2Hctf22+IbHqo=", + "lastModified": 1771532737, + "narHash": "sha256-H26FQmOyvIGnedfAioparJQD8Oe+/byD6OpUpnI/hkE=", "owner": "cachix", "repo": "nix", - "rev": "9f0da1cd90b271569752a4c83f3ff700b8fcbe12", + "rev": "7eb6c427c7a86fdc3ebf9e6cbf2a84e80e8974fd", "type": "github" }, "original": { @@ -242,11 +242,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1768569498, - "narHash": "sha256-bB6Nt99Cj8Nu5nIUq0GLmpiErIT5KFshMQJGMZwgqUo=", + "lastModified": 1771207753, + "narHash": "sha256-b9uG8yN50DRQ6A7JdZBfzq718ryYrlmGgqkRm9OOwCE=", "owner": "nixos", "repo": "nixpkgs", - "rev": "be5afa0fcb31f0a96bf9ecba05a516c66fcd8114", + "rev": "d1c15b7d5806069da59e819999d70e1cec0760bf", "type": "github" }, "original": { @@ -294,11 +294,11 @@ ] }, "locked": { - "lastModified": 1768158989, - "narHash": "sha256-67vyT1+xClLldnumAzCTBvU0jLZ1YBcf4vANRWP3+Ak=", + "lastModified": 1770228511, + "narHash": "sha256-wQ6NJSuFqAEmIg2VMnLdCnUc0b7vslUohqqGGD+Fyxk=", "owner": "numtide", "repo": "treefmt-nix", - "rev": "e96d59dff5c0d7fddb9d113ba108f03c3ef99eca", + "rev": "337a4fe074be1042a35086f15481d763b8ddc0e7", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 246c925..fe50d50 100755 --- a/flake.nix +++ b/flake.nix @@ -56,7 +56,6 @@ with flake-parts-lib; let defaultFlakeModule = importApply ./modules/flake/default.nix { inherit withSystem; }; - treefmtFlakeModule = importApply ./modules/flake/treefmt.nix { inherit withSystem; }; in { imports = [ @@ -65,7 +64,6 @@ flake-parts.flakeModules.easyOverlay git-hooks.flakeModule treefmt-nix.flakeModule - treefmtFlakeModule ]; flake = { @@ -147,8 +145,6 @@ fleet = pkgs.callPackage ./pkgs/fleet { }; bootloose = pkgs.callPackage ./pkgs/bootloose { }; longhornctl = pkgs.callPackage ./pkgs/longhornctl { }; - prettier-plugin-astro = pkgs.callPackage ./pkgs/prettier-plugin-astro { }; - prettier-plugin-tailwindcss = pkgs.callPackage ./pkgs/prettier-plugin-tailwindcss { }; }; }; diff --git a/modules/flake/treefmt.nix b/modules/flake/treefmt.nix deleted file mode 100644 index e8355fb..0000000 --- a/modules/flake/treefmt.nix +++ /dev/null @@ -1,46 +0,0 @@ -{ withSystem, ... }: -_: - -{ - perSystem = - { system, ... }: - { - devenv.modules = [ - { - treefmt.config.programs.prettier = withSystem system ( - { config, pkgs, ... }: - { - includes = [ - "*.astro" - "*.cjs" - "*.css" - "*.html" - "*.js" - "*.jsx" - "*.mdx" - "*.mjs" - "*.mts" - "*.scss" - "*.ts" - "*.tsx" - "*.vue" - ]; - package = pkgs.prettier.override { - plugins = [ - config.packages.prettier-plugin-astro - config.packages.prettier-plugin-tailwindcss - ]; - }; - settings.overrides = [ - { - files = "*.astro"; - options.parser = "astro"; - } - ]; - } - ); - - } - ]; - }; -} diff --git a/pkgs/prettier-plugin-astro/default.nix b/pkgs/prettier-plugin-astro/default.nix deleted file mode 100644 index e7f8788..0000000 --- a/pkgs/prettier-plugin-astro/default.nix +++ /dev/null @@ -1,59 +0,0 @@ -{ - fetchFromGitHub, - fetchPnpmDeps, - lib, - nodejs, - pnpm_9, - pnpmConfigHook, - stdenv, -}: - -stdenv.mkDerivation (finalAttrs: { - pname = "prettier-plugin-astro"; - version = "0.14.1"; - - src = fetchFromGitHub { - owner = "withastro"; - repo = "prettier-plugin-astro"; - rev = "v${finalAttrs.version}"; - hash = "sha256-XGPz4D2UKOonet0tX3up5mCxw3/69XYPScxb9l7nzpE="; - }; - - nativeBuildInputs = [ - nodejs - pnpmConfigHook - pnpm_9 - ]; - - pnpmDeps = fetchPnpmDeps { - inherit (finalAttrs) pname version src; - fetcherVersion = 3; - hash = finalAttrs.pnpmDepsHash; - pnpm = pnpm_9; - }; - - pnpmDepsHash = "sha256-vs7KOsX+jmnY2+RKJlhSWDVyTUxAO2af3lyao9AYFr8="; - - buildPhase = '' - runHook preBuild - pnpm build - runHook postBuild - ''; - - installPhase = '' - runHook preInstall - mkdir -p $out/lib/node_modules/prettier-plugin-astro/dist - cp -r dist/* $out/lib/node_modules/prettier-plugin-astro/dist - cp -r node_modules $out/lib/node_modules/prettier-plugin-astro/node_modules - cp package.json $out/lib/node_modules/prettier-plugin-astro/package.json - cp README.md $out/lib/node_modules/prettier-plugin-astro/README.md - runHook postInstall - ''; - - meta = with lib; { - description = "Prettier plugin for Astro"; - homepage = "https://github.com/withastro/prettier-plugin-astro"; - license = licenses.mit; - maintainers = with maintainers; [ shikanime ]; - }; -}) diff --git a/pkgs/prettier-plugin-tailwindcss/default.nix b/pkgs/prettier-plugin-tailwindcss/default.nix deleted file mode 100644 index 4244f20..0000000 --- a/pkgs/prettier-plugin-tailwindcss/default.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ - lib, - buildNpmPackage, - fetchFromGitHub, - prettier, -}: - -buildNpmPackage rec { - pname = "prettier-plugin-tailwindcss"; - version = "0.7.2"; - - src = fetchFromGitHub { - owner = "tailwindlabs"; - repo = "prettier-plugin-tailwindcss"; - rev = "v${version}"; - hash = "sha256-/zRz0mP2P8xX8n0UQmzWt0eYNYA5S4RrD0lRzQYt03M="; - }; - - npmDepsHash = "sha256-J2TTD4rsEG2CYtGWfksbGdTD/yFOX/WeVwaUdlyjuPQ="; - - postInstall = '' - mkdir -p $out/lib/node_modules/prettier-plugin-tailwindcss/node_modules - ln -s ${prettier}/lib/node_modules/prettier $out/lib/node_modules/prettier-plugin-tailwindcss/node_modules/prettier - ''; - - meta = with lib; { - description = "Prettier plugin for Tailwind CSS"; - homepage = "https://github.com/tailwindlabs/prettier-plugin-tailwindcss"; - license = licenses.mit; - maintainers = with maintainers; [ shikanime ]; - }; -}