Compare commits

..

1 Commits

Author SHA1 Message Date
Jan-Bulthuis
c2a73f4de7 feat: release 0.2.0 2026-07-19 21:17:12 +02:00
2 changed files with 24 additions and 22 deletions

22
flake.lock generated
View File

@ -20,9 +20,7 @@
},
"helix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
],
"nixpkgs": "nixpkgs",
"rust-overlay": "rust-overlay"
},
"locked": {
@ -40,6 +38,22 @@
}
},
"nixpkgs": {
"locked": {
"lastModified": 1775036866,
"narHash": "sha256-ZojAnPuCdy657PbTq5V0Y+AHKhZAIwSIT2cb8UgAz/U=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "6201e203d09599479a3b3450ed24fa81537ebc4e",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1784120854,
"narHash": "sha256-KesHgItiZPgGX740axSiQLcIQ8D24MDqNpkKYWIek8k=",
@ -59,7 +73,7 @@
"inputs": {
"flake-utils": "flake-utils",
"helix": "helix",
"nixpkgs": "nixpkgs"
"nixpkgs": "nixpkgs_2"
}
},
"rust-overlay": {

View File

@ -3,7 +3,6 @@
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
helix.url = "github:helix-editor/helix";
helix.inputs.nixpkgs.follows = "nixpkgs";
};
outputs =
@ -28,27 +27,23 @@
in
pkgs.stdenv.mkDerivation {
name = "syntax";
nativeBuildInputs = [ pkgs.patchelf ];
phases = [
"buildPhase"
"installPhase"
];
buildPhase = ''
mkdir -p build
cp -r ${helix}/runtime/queries/* ./build/
chmod u+w ./build -R
cp -r ${helix}/runtime/queries/* ./
chmod u+w ./* -R
for so in ${grammars}/*.so; do
name=$(basename "$so" .so)
if [ -d "./build/$name" ]; then
cp "$so" "./build/$name/$name.so"
chmod u+w "./build/$name/$name.so"
patchelf --shrink-rpath "./build/$name/$name.so"
if [ -d "./$name" ]; then
cp "$so" "./$name/$name.so"
fi
done
'';
installPhase = ''
mkdir -p $out
cp -r ./build/* $out/
cp -r ./* $out/
'';
};
packages.themes = pkgs.stdenv.mkDerivation {
@ -62,14 +57,7 @@
packages.karnaugh = pkgs.rustPlatform.buildRustPackage (final: {
pname = "karnaugh";
version = "0.2.0";
src = pkgs.lib.fileset.toSource {
root = ./.;
fileset = pkgs.lib.fileset.unions [
./Cargo.toml
./Cargo.lock
./src
];
};
src = self;
cargoLock.lockFile = ./Cargo.lock;
});
packages.container = pkgs.dockerTools.buildImage {