Added rust

This commit is contained in:
Nickiel12 2022-10-10 16:50:15 -07:00
parent e115a557c6
commit 3f0c292332
3 changed files with 35 additions and 2 deletions

View file

@ -35,9 +35,10 @@
home-manager.users.${user} = {
imports = [
./home.nix
./modules/zsh.nix
./modules/git.nix
./modules/urxvt.nix
./modules/vim.nix
./modules/zsh.nix
];
};
}

View file

@ -3,6 +3,13 @@
let
user = "nixolas";
editor = "vim";
moz_overlay = import (builtins.fetchTarball https://github.com/mozilla/nixpkgs-mozilla/archive/master.tar.gz);
nixpkgs = import <nixpkgs> {
overlays = [ moz_overlay ];
};
ruststable = (nixpkgs.latest.rustChannels.stable.rust.override {
extensions = [ "rust-src" "rust-analysis" ];}
);
in
{
@ -32,7 +39,12 @@ in
powerline
nodejs # required for coc-nvim
# Gui application
cargo
rustc
rustfmt
# Gui application
firefox
libsForQt5.kate
];

20
rust-shell-template.nix Normal file
View file

@ -0,0 +1,20 @@
{ pkgs ? import <nixpkgs> {}}:
let
rust_overlay = import (builtins.fetchTarball "https://github.com/oxalica/rust-overlay/archive/master.tar.gz");
pkgs = import <nixpkgs> { overlays = [ rust_overlay ]; };
ruststable = (pkgs.latest.rustChannels.stable.default.override {
extensions = [
"rust-src"
"rustfmt"
"clippy"
];
});
in
pkgs.mkShell {
buildInputs = with pkgs; [
ruststable
];
RUST_BACKTRACE = 1;
}