# update all flake inputs
nix flake update
# update only specific flake inputs
nix flake update [input]
nix flake init -t "path:$HOME/dotfiles/assets/devenvs#[language]"
# rebuilds nixos and home-manager
./assets/scripts/rebuild
# ,+ü in neovim for sha autofill
{pkgs, ...}: let
PKG-git = pkgs.PKG.overrideAttrs (prev: {
version = "git";
src = pkgs.fetchFromGitHub {
owner = "PKG";
repo = "PKG";
rev = "";
sha256 = pkgs.lib.fakeSha256;
};
});
in {
programs = {
PKG = {
enable = true;
package = PKG-git;
};
};
}
or overlay:
nixpkgs = {
overlays = [
(final: prev: {
PKG = prev.PKG.overrideAttrs (oldAttrs: rec {
pname = "PKG";
version = "0-unstable-$DATE";
src = prev.fetchFromGitHub {
owner = "PKG";
repo = "PKG";
rev = "";
sha256 = "";
};
});
})
];
};
disabledModules = ["/path/to/module.nix"];
imports = [
./my-own-module.nix # local import
"${inputs.pkgs}/path/to/module.nix" # other input e.g. nixpkgs import
];
git submodule init && git submodule update
source: here
derivation.nix
{ stdenv }:
stdenv.mkDerivation rec {
name = "program-${version}";
version = "1.0";
src = ./.;
nativeBuildInputs = [ ];
buildInputs = [ ];
buildPhase = ''
gcc program.c -o myprogram
'';
installPhase = ''
mkdir -p $out/bin
cp myprogram $out/bin
'';
}
default.nix
{ pkgs ? import <nixpkgs> {} }:
pkgs.callPackage ./derivation.nix {}
then run:
nix-build
journalctl -xeu nixos-update.service
$DOTFILES_PATH
is required to be set- private zsh functions etc. in $HOME/.config/zsh/.priv.zsh
- stylus catppuccin themes: catppuccin
- asahi widevine useragent:
Mozilla/5.0 (X11; CrOS aarch64 15236.80.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.5414.125 Safari/537.36