Compare commits
2 Commits
8bf3fdae1c
...
76c0b03e49
Author | SHA1 | Date |
---|---|---|
mat ess | 76c0b03e49 | |
mat ess | 07c88e6486 |
|
@ -54,7 +54,6 @@ in
|
||||||
"bbedit"
|
"bbedit"
|
||||||
# "discord"
|
# "discord"
|
||||||
# "element"
|
# "element"
|
||||||
"ferdium"
|
|
||||||
"firefox"
|
"firefox"
|
||||||
"jitsi-meet"
|
"jitsi-meet"
|
||||||
"knockknock"
|
"knockknock"
|
||||||
|
@ -63,10 +62,13 @@ in
|
||||||
"logi-options-plus"
|
"logi-options-plus"
|
||||||
"lulu"
|
"lulu"
|
||||||
"macsvg"
|
"macsvg"
|
||||||
|
"messenger"
|
||||||
"miniforge"
|
"miniforge"
|
||||||
"mullvadvpn"
|
"mullvadvpn"
|
||||||
# "obsidian"
|
# "obsidian"
|
||||||
|
"qflipper"
|
||||||
"rectangle"
|
"rectangle"
|
||||||
|
"remarkable"
|
||||||
"secretive"
|
"secretive"
|
||||||
"shortcat"
|
"shortcat"
|
||||||
"signal"
|
"signal"
|
||||||
|
|
|
@ -1,4 +1,7 @@
|
||||||
{
|
let
|
||||||
|
mkTemplates = builtins.mapAttrs (name: attrs: attrs // { path = ./. + "/${name}"; });
|
||||||
|
in
|
||||||
|
mkTemplates {
|
||||||
rust = {
|
rust = {
|
||||||
description = "A rust flake template based on flake.parts";
|
description = "A rust flake template based on flake.parts";
|
||||||
welcomeText = ''
|
welcomeText = ''
|
||||||
|
@ -6,6 +9,5 @@
|
||||||
|
|
||||||
run `direnv allow` and `cargo init` to start a new project
|
run `direnv allow` and `cargo init` to start a new project
|
||||||
'';
|
'';
|
||||||
path = ./templates/rust;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,8 +10,8 @@
|
||||||
pre-commit.inputs.nixpkgs.follows = "nixpkgs";
|
pre-commit.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, flake-parts, crane, pre-commit, ... }:
|
outputs = inputs@{ self, flake-parts, crane, pre-commit, ... }:
|
||||||
flake-parts.lib.mkFlake { inherit self; } {
|
flake-parts.lib.mkFlake { inherit inputs; } {
|
||||||
imports = [ pre-commit.flakeModule ];
|
imports = [ pre-commit.flakeModule ];
|
||||||
systems = [
|
systems = [
|
||||||
"aarch64-darwin"
|
"aarch64-darwin"
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
crane-lib = crane.lib.${system};
|
crane-lib = crane.lib.${system};
|
||||||
package = crane-lib.buildPackage {
|
package = crane-lib.buildPackage {
|
||||||
src = crane-lib.cleanCargoSource ./.;
|
src = crane-lib.cleanCargoSource ./.;
|
||||||
nativeBuildInputs = [ pkgs.libiconv ];
|
nativeBuildInputs = pkgs.lib.optionals pkgs.stdenv.isDarwin [ pkgs.libiconv ];
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
@ -43,15 +43,19 @@
|
||||||
inputsFrom = builtins.attrValues self.checks;
|
inputsFrom = builtins.attrValues self.checks;
|
||||||
|
|
||||||
RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}";
|
RUST_SRC_PATH = "${pkgs.rust.packages.stable.rustPlatform.rustLibSrc}";
|
||||||
nativeBuildInputs = with pkgs; [
|
nativeBuildInputs = builtins.attrValues {
|
||||||
cargo
|
inherit (pkgs)
|
||||||
rustc
|
cargo
|
||||||
];
|
rustc
|
||||||
buildInputs = with pkgs; [
|
;
|
||||||
rust-analyzer
|
};
|
||||||
rustfmt
|
buildInputs = builtins.attrValues {
|
||||||
clippy
|
inherit (pkgs)
|
||||||
];
|
rust-analyzer
|
||||||
|
rustfmt
|
||||||
|
clippy
|
||||||
|
;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue