Fix home-manager config on ubuntu

This commit is contained in:
Cyryl Płotnicki 2021-11-24 10:33:12 +00:00
parent abdcb8f007
commit afb108abf9
3 changed files with 41 additions and 6 deletions

View file

@ -193,6 +193,42 @@ specialArgs = { inherit inputs; };
}; };
``` ```
## Ubuntu
```
sudo apt install git vim curl
curl -L https://nixos.org/nix/install | sh
```
make sure
```
if [ -e /home/cyryl/.nix-profile/etc/profile.d/nix.sh ]; then . /home/cyryl/.nix-profile/etc/profile.d/nix.sh; fi # added by Nix installer
export NIX_PATH=$HOME/.nix-defexpr/channels${NIX_PATH:+:}$NIX_PATH
``` is in `~/.profile`
```
reboot
```
```
nix-shell '<home-manager>' -A install
```
```
mkdir dev
cd dev
git clone https://git.sr.ht/~cyplo/dotfiles
cd dotfiles
```
```
ln -vfs /home/cyryl/dev/dotfiles/nixos/home-other-os.nix /home/cyryl/.config/nixpkgs/home.nix
home-manager switch
```
## guix ## guix
I'm just starting to play with guix, these are just loose notes: I'm just starting to play with guix, these are just loose notes:

View file

@ -1,7 +1,4 @@
{ config, pkgs, inputs, ... }: { config, pkgs, ... }:
let
unstable = inputs.nixpkgs-nixos-unstable.legacyPackages.${pkgs.system};
in
{ {
home.file.".vimrc".source = ../../../.vimrc.nixos; home.file.".vimrc".source = ../../../.vimrc.nixos;
home.packages = with pkgs; [ home.packages = with pkgs; [
@ -15,7 +12,6 @@ in
withNodeJs = true; withNodeJs = true;
withPython3 = true; withPython3 = true;
withRuby = true; withRuby = true;
package = unstable.neovim-unwrapped;
plugins = with pkgs.vimPlugins; [ plugins = with pkgs.vimPlugins; [
ack-vim ack-vim

View file

@ -5,6 +5,10 @@ let
dotfiles = "/home/cyryl/dev/dotfiles"; dotfiles = "/home/cyryl/dev/dotfiles";
in in
{ {
home.username = "cyryl";
home.homeDirectory = "/home/cyryl";
home.stateVersion = "21.11";
nixpkgs.config = { nixpkgs.config = {
allowUnfree = true; allowUnfree = true;
packageOverrides = pkgs: { packageOverrides = pkgs: {
@ -24,7 +28,6 @@ in
imports = [ imports = [
./git/home.nix ./git/home.nix
./home-manager/programs/tmux.nix ./home-manager/programs/tmux.nix
./home-manager/programs/zsh.nix
./home-manager/links.nix ./home-manager/links.nix
./home-manager/programs/vim.nix ./home-manager/programs/vim.nix
]; ];