pin vscode rustanalyzer

This commit is contained in:
Cyryl Płotnicki 2023-01-31 21:38:23 +00:00
parent f386acd94d
commit 95310bbcee
3 changed files with 198 additions and 183 deletions

View file

@ -366,6 +366,22 @@
"type": "github"
}
},
"nixpkgs-rust-analyzer": {
"locked": {
"lastModified": 1675198550,
"narHash": "sha256-LWUqaWNDvHvfsruLk27u8uMo0lT4w7Gzl/zFOIr27HE=",
"owner": "cyplo",
"repo": "nixpkgs",
"rev": "85b5540187b50ef99a14a39a5437fd0abb9f3e4b",
"type": "github"
},
"original": {
"owner": "cyplo",
"ref": "85b5540187b50ef99a14a39a5437fd0abb9f3e4b",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-stable": {
"locked": {
"lastModified": 1674407282,
@ -410,6 +426,7 @@
"nixos-hardware": "nixos-hardware",
"nixpkgs-master": "nixpkgs-master",
"nixpkgs-nixos-unstable": "nixpkgs-nixos-unstable",
"nixpkgs-rust-analyzer": "nixpkgs-rust-analyzer",
"nixpkgs-stable": "nixpkgs-stable",
"nur": "nur",
"sops": "sops"

View file

@ -1,21 +1,10 @@
{
description = "NixOS configuration with flakes";
outputs = {
self,
flake-utils,
flake-compat,
home-manager,
nixpkgs-nixos-unstable,
nixpkgs-master,
nixpkgs-stable,
darwin,
nixos-hardware,
nur,
sops,
nil,
helix,
alejandra,
} @ inputs: let
outputs = { self, flake-utils, flake-compat, home-manager
, nixpkgs-nixos-unstable, nixpkgs-master, nixpkgs-stable, darwin
, nixos-hardware, nur, sops, nil, helix, alejandra, nixpkgs-rust-analyzer
}@inputs:
let
mkServer = pkgs: system: hostname:
pkgs.lib.nixosSystem {
inherit system;
@ -24,13 +13,13 @@
(import ./nixos/server-common.nix)
sops.nixosModules.sops
];
specialArgs = {inherit inputs system;};
specialArgs = { inherit inputs system; };
};
mkRaspi = pkgs: hostname:
pkgs.lib.nixosSystem {
system = "aarch64-linux";
modules = [(./. + "/nixos/boxes/${hostname}")];
specialArgs = {inherit inputs;};
modules = [ (./. + "/nixos/boxes/${hostname}") ];
specialArgs = { inherit inputs; };
};
mkKiosk = pkgs: system: hostname:
pkgs.lib.nixosSystem {
@ -45,7 +34,8 @@
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.cyryl = {
imports = [./nixos/home-manager ./nixos/home-manager/linux.nix];
imports =
[ ./nixos/home-manager ./nixos/home-manager/linux.nix ];
_module.args.inputs = inputs;
_module.args.system = system;
};
@ -55,11 +45,11 @@
inherit inputs system;
nixpkgs-nixos-stable-and-unfree = import nixpkgs-stable {
inherit system;
config = {allowUnfree = true;};
config = { allowUnfree = true; };
};
nixpkgs-nixos-unstable-and-unfree = import nixpkgs-nixos-unstable {
inherit system;
config = {allowUnfree = true;};
config = { allowUnfree = true; };
};
};
};
@ -77,7 +67,8 @@
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.cyryl = {
imports = [./nixos/home-manager ./nixos/home-manager/linux.nix];
imports =
[ ./nixos/home-manager ./nixos/home-manager/linux.nix ];
_module.args.inputs = inputs;
_module.args.system = system;
};
@ -87,18 +78,17 @@
inherit inputs system;
nixpkgs-nixos-stable-and-unfree = import nixpkgs-stable {
inherit system;
config = {allowUnfree = true;};
config = { allowUnfree = true; };
};
nixpkgs-nixos-unstable-and-unfree = import nixpkgs-nixos-unstable {
inherit system;
config = {allowUnfree = true;};
config = { allowUnfree = true; };
};
};
};
mkShell = packageSet: system: let
pkgs = packageSet.legacyPackages.${system};
in
pkgs.mkShell {
mkShell = packageSet: system:
let pkgs = packageSet.legacyPackages.${system};
in pkgs.mkShell {
packages = with pkgs; [
cacert
git
@ -125,7 +115,7 @@
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.cyryl = {
imports = [./nixos/home-manager];
imports = [ ./nixos/home-manager ];
_module.args.inputs = inputs;
_module.args.system = system;
};
@ -145,12 +135,12 @@
bootstrap = nixpkgs-stable.lib.nixosSystem rec {
system = "x86_64-linux";
modules = [(./. + "/nixos/boxes/bootstrap") sops.nixosModules.sops];
modules = [ (./. + "/nixos/boxes/bootstrap") sops.nixosModules.sops ];
specialArgs = {
inherit inputs system;
nixpkgs-nixos-unstable-and-unfree = import nixpkgs-nixos-unstable {
inherit system;
config = {allowUnfree = true;};
config = { allowUnfree = true; };
};
};
};
@ -163,7 +153,8 @@
(import
"${inputs.nixpkgs-nixos-unstable}/nixos/modules/installer/sd-card/sd-image-aarch64-installer.nix")
{
environment.systemPackages = with nixpkgs-nixos-unstable.legacyPackages."aarch64-linux"; [
environment.systemPackages =
with nixpkgs-nixos-unstable.legacyPackages."aarch64-linux"; [
neovim
htop
btop
@ -195,7 +186,7 @@
console.earlySetup = true;
}
];
specialArgs = {inherit inputs;};
specialArgs = { inherit inputs; };
};
};
};
@ -221,6 +212,13 @@
ref = "nixos-22.11";
};
nixpkgs-rust-analyzer = {
type = "github";
owner = "cyplo";
repo = "nixpkgs";
ref = "85b5540187b50ef99a14a39a5437fd0abb9f3e4b";
};
nixos-hardware = {
type = "github";
owner = "NixOS";

View file

@ -1,11 +1,11 @@
{ config, pkgs, ... }: {
{ config, pkgs, inputs, ... }: {
home.packages = with pkgs;
[
(vscode-with-extensions.override {
vscodeExtensions = with vscode-extensions;
[
ms-python.python
rust-lang.rust-analyzer
inputs.nixpkgs-rust-analyzer.legacyPackages.x86_64-linux.vscode-extensions.rust-lang.rust-analyzer
(vscode-utils.buildVscodeExtension {
vscodeExtUniqueId = "vadimcn.vscode-lldb";
name = "vadimcn.vscode-lldb-1.6.10";