mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 14:49:14 +00:00
tree-wide: format with nixfmt
Another saturday another useless formatter change. It's my dotfiles, after all alejandra doesn't handle c-style inline comments well.
This commit is contained in:
parent
ec704b5272
commit
ebf8468807
116 changed files with 1895 additions and 1689 deletions
|
|
@ -2,36 +2,37 @@
|
|||
lib,
|
||||
rustPlatform,
|
||||
fetchFromGitHub,
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
rev = "c9d4b164ff5dc2567bb0de3876460e51da62ba94";
|
||||
in
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
pname = "typst-bot";
|
||||
version = lib.substring 0 8 rev;
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
pname = "typst-bot";
|
||||
version = lib.substring 0 8 rev;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "mattfbacon";
|
||||
repo = "typst-bot";
|
||||
inherit rev;
|
||||
hash = "sha256-tB+zrE5p7zOloOgoP2fmFsajd4IBf94ET1v/0W3aNcM=";
|
||||
src = fetchFromGitHub {
|
||||
owner = "mattfbacon";
|
||||
repo = "typst-bot";
|
||||
inherit rev;
|
||||
hash = "sha256-tB+zrE5p7zOloOgoP2fmFsajd4IBf94ET1v/0W3aNcM=";
|
||||
};
|
||||
|
||||
preBuild = ''
|
||||
# Don't use the upstream way of embedding the git rev
|
||||
echo 'fn main() { println!("cargo:rustc-env=BUILD_SHA=${rev}"); }' > crates/bot/build.rs
|
||||
|
||||
# Patch the command calling the worker by name.
|
||||
substituteInPlace crates/bot/src/worker.rs --replace-fail \
|
||||
'"./worker"' \
|
||||
'"${placeholder "out"}/bin/worker"'
|
||||
'';
|
||||
|
||||
cargoBuildFlags = [ "--workspace" ];
|
||||
|
||||
cargoLock = {
|
||||
lockFile = "${finalAttrs.src}/Cargo.lock";
|
||||
outputHashes = {
|
||||
"poise-0.6.1" = "sha256-iXyp9sR/vzPsexGPdRjfuKyFcGqvDdqiBAXnuw/HFo8=";
|
||||
};
|
||||
|
||||
preBuild = ''
|
||||
# Don't use the upstream way of embedding the git rev
|
||||
echo 'fn main() { println!("cargo:rustc-env=BUILD_SHA=${rev}"); }' > crates/bot/build.rs
|
||||
|
||||
# Patch the command calling the worker by name.
|
||||
substituteInPlace crates/bot/src/worker.rs --replace-fail \
|
||||
'"./worker"' \
|
||||
'"${placeholder "out"}/bin/worker"'
|
||||
'';
|
||||
|
||||
cargoBuildFlags = ["--workspace"];
|
||||
|
||||
cargoLock = {
|
||||
lockFile = "${finalAttrs.src}/Cargo.lock";
|
||||
outputHashes = {
|
||||
"poise-0.6.1" = "sha256-iXyp9sR/vzPsexGPdRjfuKyFcGqvDdqiBAXnuw/HFo8=";
|
||||
};
|
||||
};
|
||||
})
|
||||
};
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue