1
0
Fork 0
mirror of https://github.com/ryanccn/flake.git synced 2025-12-06 08:10:43 +01:00

fix(rust): adopt sccache again

This commit is contained in:
Ryan Cao 2024-02-14 15:26:06 +08:00
parent bb39b10e1f
commit 426718a435
Signed by: ryanccn
SSH key fingerprint: SHA256:NtP/BlVhoQq4xU6BEcZeT8nIPvHntkJ3lIc2yB+F09E
3 changed files with 41 additions and 42 deletions

54
flake.lock generated
View file

@ -7,11 +7,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1705399930, "lastModified": 1707355110,
"narHash": "sha256-JZG+pAe78RYnp9dYegalSwUTZqbNcSRmJjPnDZRl+JI=", "narHash": "sha256-S3mesqNxuY4kEHrTaqX5zVs8u31/YcpZ52GGl7sq7PE=",
"owner": "ryanccn", "owner": "ryanccn",
"repo": "am", "repo": "am",
"rev": "a68d35ca256622db496e1e5d8165c6dfd08d2469", "rev": "75deb936a48ad74c647d3890893a601d91f1f04d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -22,11 +22,11 @@
}, },
"catppuccin": { "catppuccin": {
"locked": { "locked": {
"lastModified": 1705010618, "lastModified": 1707140582,
"narHash": "sha256-7mFUoNL0Ty/akEcXtAKueZbYbeDy0IOAS02w7ufgslU=", "narHash": "sha256-Wzq2W08mSfJ/M1yRQWGwvuEEwQn3+xDx82/9FrouDzw=",
"owner": "Stonks3141", "owner": "Stonks3141",
"repo": "ctp-nix", "repo": "ctp-nix",
"rev": "310ab70d9e690b641005ceafc6582305195c8711", "rev": "948fe713ea548764a0a3f122975b8d79c44b7054",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -78,11 +78,11 @@
"rust-analyzer-src": "rust-analyzer-src" "rust-analyzer-src": "rust-analyzer-src"
}, },
"locked": { "locked": {
"lastModified": 1706595721, "lastModified": 1706941198,
"narHash": "sha256-nf5/lPawM20WO1gHAlsUwDEJ4v+InC3BYYV1EBsBJZk=", "narHash": "sha256-t6/qloMYdknVJ9a3QzjylQIZnQfgefJ5kMim50B7dwA=",
"owner": "nix-community", "owner": "nix-community",
"repo": "fenix", "repo": "fenix",
"rev": "46a368edf5f1cc16573157797e5acead834d5b2c", "rev": "28dbd8b43ea328ee708f7da538c63e03d5ed93c8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -160,11 +160,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1706473109, "lastModified": 1707467182,
"narHash": "sha256-iyuAvpKTsq2u23Cr07RcV5XlfKExrG8gRpF75hf1uVc=", "narHash": "sha256-/Bw/xgCXfj4nXDd8Xq+r1kaorfsYkkomMf5w5MpsDyA=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "d634c3abafa454551f2083b054cd95c3f287be61", "rev": "5b9156fa9a8b8beba917b8f9adbfd27bf63e16af",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -220,11 +220,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1706581965, "lastModified": 1706833576,
"narHash": "sha256-1H7dRdK9LJ7+2X1XQtbwXr+QMqtVVo/ZF0/LIvkjdK8=", "narHash": "sha256-w7BL0EWRts+nD1lbLECIuz6fRzmmV+z8oWwoY7womR0=",
"owner": "LnL7", "owner": "LnL7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "91b9daf672c957ef95a05491a75f62e6a01d5aaf", "rev": "bdbae6ecff8fcc322bf6b9053c0b984912378af7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -235,11 +235,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1706487304, "lastModified": 1707451808,
"narHash": "sha256-LE8lVX28MV2jWJsidW13D2qrHU/RUUONendL2Q/WlJg=", "narHash": "sha256-UwDBUNHNRsYKFJzyTMVMTF5qS4xeJlWoeyJf+6vvamU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "90f456026d284c22b3e3497be980b2e47d0b28ac", "rev": "442d407992384ed9c0e6d352de75b69079904e4e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -256,11 +256,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1706444613, "lastModified": 1707057654,
"narHash": "sha256-DeLsDDC+AyKeQ7YPk1nUyVMXTELm7np55sri0DYy4xE=", "narHash": "sha256-WrpyT5h+eoCu7cspf9KGaM0FgLmnBm8tOHIWbj8sYpo=",
"owner": "ryanccn", "owner": "ryanccn",
"repo": "nrr", "repo": "nrr",
"rev": "8d846528c5e71702fedb2c675d7a18ff3330da23", "rev": "73d2e8e419498cca910a41a32ce933b1fb0d043c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -291,11 +291,11 @@
"ohmyzsh": { "ohmyzsh": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1706646978, "lastModified": 1707403294,
"narHash": "sha256-5vbO9OsIMfnTDL7tUOV8EUcQ512jQpxaVmoF10hAKyU=", "narHash": "sha256-7S6UZCcUgBguoVaDWG4xGGQI2ePIVjz2L8aketzYbOw=",
"owner": "ohmyzsh", "owner": "ohmyzsh",
"repo": "ohmyzsh", "repo": "ohmyzsh",
"rev": "e195c7cb438224e8bcea20bdbc2e4b8a6bb3949b", "rev": "fff073b55defed72a0a1aac4e853b165f208735b",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -328,11 +328,11 @@
"rust-analyzer-src": { "rust-analyzer-src": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1706540258, "lastModified": 1706875368,
"narHash": "sha256-6RTztJE21l0hfWHp0qMWBurWnoFmUxYEDCvaGTnQYcA=", "narHash": "sha256-KOBXxNurIU2lEmO6lR2A5El32X9x8ITt25McxKZ/Ew0=",
"owner": "rust-lang", "owner": "rust-lang",
"repo": "rust-analyzer", "repo": "rust-analyzer",
"rev": "d13951f25c4cb880bff09a3c02a796ecc51f69ac", "rev": "8f6a72871ec87ed53cfe43a09fb284168a284e7e",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -1,15 +1,27 @@
{ {
pkgs, pkgs,
config, lib,
... ...
}: let }: let
toml = pkgs.formats.toml {}; toml = pkgs.formats.toml {};
in { in {
home.file.".cargo/config.toml".source = toml.generate "config.toml" { home.file.".cargo/config.toml".source = toml.generate "config.toml" {
build.target-dir = "${config.home.homeDirectory}/.cargo/target"; build.rustc-wrapper = "${lib.getExe' pkgs.sccache "sccache"}";
}; };
home.packages = with pkgs; [ home.packages = with pkgs; [
(fenix.combine (
with fenix;
with stable; [
cargo
rustc
rustfmt
clippy
rust-src
targets.wasm32-unknown-unknown.stable.rust-std
]
))
cargo-bloat cargo-bloat
cargo-cache cargo-cache
cargo-deny cargo-deny

View file

@ -15,19 +15,6 @@
nix-melt nix-melt
# fh # fh
(fenix.combine (
with fenix;
with stable; [
cargo
rustc
rustfmt
clippy
rust-src
rust-docs
targets.wasm32-unknown-unknown.stable.rust-std
]
))
fnm fnm
deno deno
bun bun