Skip to content

mantas6/dots

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2,290 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dots

dotfiles

Setup

Clone the repo and link

git clone https://github.com/mantas6/dots.git "$HOME/.dots"
cd "$HOME/.dots"
./bin/dot/stw

If stow fails, remove conflicting files (preferably to trash) and run again. Pay close attention to the output to make sure that the links that it creates make sense.

Create NixOS ISO

nix run nixpkgs#nixos-generators -- --format iso --flake #iso

Install NixOS

Normal setup:

nix run nixpkgs#nixos-anywhere -- \
    --flake ".#__host__" \
    --generate-hardware-config nixos-generate-config nix/hosts/__host__/hardware.nix \
    --target-host "root@__host__"

Encrypted setup:

nix run nixpkgs#nixos-anywhere -- \
    --flake ".#__host__" \
    --disk-encryption-keys /tmp/secret.key <(pass "hosts/__host__") \
    --generate-hardware-config nixos-generate-config nix/hosts/"__host__"/hardware.nix \
    --target-host "root@__host__"

Deploy NixOS on the network

nixos-rebuild --flake .#__host__ --target-host root@__host__ switch

Rescue

Upgrade out-dated dotfiles

Run when need to migrate old version of dotfiles structure

cd "$HOME/.dots"
./bin/dot/stw -D
git pull
./bin/dot/stw

Reinstall bootloader for NixOS

sudo nixos-rebuild --install-bootloader switch --flake .

MacOS

Setup

To initialize new environment run:

git clone https://github.com/mantas6/dots.git "$HOME/.dots"
cd "$HOME/.dots"
./bin/mac/rebuild-macos-env brew

Restart the shell and run stow:

cd "$HOME/.dots"
./bin/dot/stw

Run the script again to continue setup:

rebuild-macos-env init

Brew

Update all packages:

brew bundle upgrade --global

Update Brewfile after setup modifications:

brew bundle dump --global --force

Clean up removed packages:

brew bundle cleanup --global

Misc

Stress testing

Run stress test on the CPU:

nix run nixpkgs#stress-ng -- -c0

Monitor temperatures:

nix run nixpkgs#s-tui

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Contributors 3

  •  
  •  
  •