From 62fcd12a0a1ea557334dec1fa0cfdce69d003bd8 Mon Sep 17 00:00:00 2001 From: Kumar Damani Date: Fri, 24 Jul 2026 00:28:12 -0400 Subject: flake shell for typst --- .envrc | 1 + flake.lock | 43 +++++++++++++++++++++++++++++++++++++++++++ flake.nix | 27 +++++++++++++++++++++++++++ 3 files changed, 71 insertions(+) create mode 100644 .envrc create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/.envrc b/.envrc new file mode 100644 index 0000000..3550a30 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use flake diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..686bd4a --- /dev/null +++ b/flake.lock @@ -0,0 +1,43 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1784497964, + "narHash": "sha256-vlHUuqAcbcH2RKmHbPiuQzbv1pnzzavXnI62RD0bqCU=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "241313f4e8e508cb9b13278c2b0fa25b9ca27163", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs", + "systems": "systems" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..057056a --- /dev/null +++ b/flake.nix @@ -0,0 +1,27 @@ +{ + description = "A basic Typst project."; + + inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + inputs.systems.url = "github:nix-systems/default"; + + outputs = { systems, nixpkgs, ... }: + let + eachSystem = nixpkgs.lib.genAttrs (import systems); + in + { + devShells = eachSystem (system: + let + pkgs = nixpkgs.legacyPackages.${system}; + in + { + default = pkgs.mkShell { + packages = with pkgs; [ + typst + ]; + shellHook = '' + echo "Welcome to the shell!" + ''; + }; + }); + }; +} -- cgit v1.2.3