terminal user interface to jujutsu. Focused on speed and clarity
9
fork

Configure Feed

Select the types of activity you want to include in your feed.

flake experiment

+94 -30
+24
flake.lock
··· 1 + { 2 + "nodes": { 3 + "nixpkgs": { 4 + "locked": { 5 + "lastModified": 1713537308, 6 + "narHash": "sha256-XtTSSIB2DA6tOv+l0FhvfDMiyCmhoRbNB+0SeInZkbk=", 7 + "path": "/nix/store/v4pcs3nzx54m5bmxd39win0rgl2d2hbx-source", 8 + "rev": "5c24cf2f0a12ad855f444c30b2421d044120c66f", 9 + "type": "path" 10 + }, 11 + "original": { 12 + "id": "nixpkgs-unstable", 13 + "type": "indirect" 14 + } 15 + }, 16 + "root": { 17 + "inputs": { 18 + "nixpkgs": "nixpkgs" 19 + } 20 + } 21 + }, 22 + "root": "root", 23 + "version": 7 24 + }
+70 -30
flake.nix
··· 1 1 { 2 - description = "Ocaml project using `ocaml-flake` and `flake-parts`"; 2 + description = "Example JavaScript development environment for Zero to Nix"; 3 3 4 + # Flake inputs 4 5 inputs = { 5 - nixpkgs.url = "nixpkgs-unstable"; 6 - ocaml-flake.url = "github:9glenda/ocaml-flake"; 6 + 7 + # nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; 8 + nixpkgs.url = "nixpkgs-unstable"; # also valid: "nixpkgs" 9 + 10 + # roc={ 11 + # url="github:roc-lang/roc"; 12 + # inputs.nixpkgs.follows="nixpkgs"; 13 + 14 + # }; 15 + 7 16 }; 8 - 9 - outputs = inputs @ { 10 - flake-parts, 11 - ocaml-flake, 12 - ... 13 - }: 14 - flake-parts.lib.mkFlake {inherit inputs;} { 15 - imports = [ 16 - ocaml-flake.flakeModule 17 + # Flake outputs 18 + outputs = { self, nixpkgs, ... }@inputs: 19 + let 20 + # Systems supported 21 + allSystems = [ 22 + "x86_64-linux" # 64-bit Intel/AMD Linux 17 23 ]; 18 - systems = ["x86_64-linux" "aarch64-linux" "aarch64-darwin" "x86_64-darwin"]; 19 - perSystem = _: { 20 - ocaml = { 21 - duneProjects = { 22 - default = { 23 - name = "jj_tui"; 24 - src = ./.; 25 - }; 26 - eio-process = { 27 - name = "eio-process"; 28 - src = ./forks/.; 29 - }; 30 - notty = { 31 - name = "notty"; 32 - src = ./forks/.; 33 - }; 24 + 25 + # Helper to provide system-specific attributes 26 + forAllSystems = f: 27 + nixpkgs.lib.genAttrs allSystems (system: 28 + f { 29 + pkgs = import nixpkgs { inherit system; }; 30 + 31 + }); 32 + in { 33 + # Development environment output 34 + devShells = forAllSystems ({ pkgs }: { 35 + default = 36 + 37 + pkgs.mkShell { 38 + packages = with pkgs; [ 39 + 40 + opam 41 + git 42 + gnumake 43 + m4 44 + bubblewrap 45 + bash 46 + coreutils 47 + ((pkgs.openssl.override { static = true; })) 48 + pkgs.pkg-config 49 + pkgsMusl.gmp 50 + stdenv.cc.cc.lib 51 + jujutsu 52 + glibc.static 53 + musl.dev 54 + musl 55 + pkgsMusl.gcc 56 + pkgs.dune_3 57 + pkgsMusl.ocaml 58 + ]; 59 + shellHook = 60 + 61 + let 62 + libPath = pkgs.lib.makeLibraryPath [ 63 + pkgs.pkgsMusl.stdenv.cc.cc.lib 64 + pkgs.pkgsMusl.gmp 65 + pkgs.pkgsMusl.musl 66 + ]; 67 + in '' 68 + export CC=${pkgs.pkgsMusl.musl.stdenv.cc} 69 + # # yolo 70 + # export CFLAGS="$CFLAGS -I${pkgs.pkgsMusl.stdenv.cc.cc.lib}/include -I${pkgs.pkgsMusl.gmp}/include" 71 + # export LIBS="$LIBS -L${pkgs.pkgsMusl.stdenv.cc.cc.lib}/lib -L${pkgs.pkgsMusl.gmp}/lib" 72 + ''; 34 73 }; 35 - }; 36 - }; 74 + 75 + }); 76 + 37 77 }; 38 78 }