mirror of
https://github.com/tuxdotrs/tshell.git
synced 2026-09-19 10:39:04 +05:30
style: format code
This commit is contained in:
11
flake.nix
11
flake.nix
@@ -15,14 +15,12 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs = {
|
||||||
{
|
|
||||||
self,
|
self,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
quickshell,
|
quickshell,
|
||||||
treefmt-nix,
|
treefmt-nix,
|
||||||
}:
|
}: let
|
||||||
let
|
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
|
||||||
@@ -37,13 +35,12 @@
|
|||||||
projectRootFile = "flake.nix";
|
projectRootFile = "flake.nix";
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
nixfmt.enable = true;
|
alejandra.enable = true;
|
||||||
qmlformat.enable = true;
|
qmlformat.enable = true;
|
||||||
clang-format.enable = true;
|
clang-format.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
in
|
in rec {
|
||||||
rec {
|
|
||||||
formatter.${system} = treefmtEval.config.build.wrapper;
|
formatter.${system} = treefmtEval.config.build.wrapper;
|
||||||
|
|
||||||
packages.${system} = {
|
packages.${system} = {
|
||||||
|
|||||||
18
package.nix
18
package.nix
@@ -10,34 +10,32 @@
|
|||||||
cava,
|
cava,
|
||||||
wallust,
|
wallust,
|
||||||
nerd-fonts,
|
nerd-fonts,
|
||||||
extraRuntimeDeps ? [ ],
|
extraRuntimeDeps ? [],
|
||||||
}:
|
}: let
|
||||||
let
|
|
||||||
version = "0.1.0";
|
version = "0.1.0";
|
||||||
|
|
||||||
runtimeDeps = [
|
runtimeDeps =
|
||||||
|
[
|
||||||
cava
|
cava
|
||||||
wallust
|
wallust
|
||||||
]
|
]
|
||||||
++ extraRuntimeDeps;
|
++ extraRuntimeDeps;
|
||||||
|
|
||||||
fontconfig = makeFontsConf {
|
fontconfig = makeFontsConf {
|
||||||
fontDirectories = [ nerd-fonts.fira-code ];
|
fontDirectories = [nerd-fonts.fira-code];
|
||||||
};
|
};
|
||||||
|
|
||||||
# Unlike lib.fileset, this keeps untracked files (the flake only sees
|
# Unlike lib.fileset, this keeps untracked files (the flake only sees
|
||||||
# git-tracked paths) while dropping build artifacts.
|
# git-tracked paths) while dropping build artifacts.
|
||||||
src = lib.cleanSourceWith {
|
src = lib.cleanSourceWith {
|
||||||
src = lib.cleanSource ./.;
|
src = lib.cleanSource ./.;
|
||||||
filter =
|
filter = path: _: let
|
||||||
path: _:
|
|
||||||
let
|
|
||||||
name = baseNameOf path;
|
name = baseNameOf path;
|
||||||
in
|
in
|
||||||
!(name == "dist" || name == "result" || name == "result-bin" || lib.hasPrefix "build" name);
|
!(name == "dist" || name == "result" || name == "result-bin" || lib.hasPrefix "build" name);
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
inherit version src;
|
inherit version src;
|
||||||
pname = "tshell";
|
pname = "tshell";
|
||||||
|
|
||||||
@@ -79,4 +77,4 @@ stdenv.mkDerivation {
|
|||||||
mainProgram = "tshell";
|
mainProgram = "tshell";
|
||||||
platforms = lib.platforms.linux;
|
platforms = lib.platforms.linux;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user