Compare commits
3 次程式碼提交
25403ef67d
...
61be8db799
作者 | SHA1 | 提交日期 |
---|---|---|
|
61be8db799 | |
|
1e58494989 | |
|
7d4a067aad |
|
@ -0,0 +1 @@
|
||||||
|
/result*
|
|
@ -13,4 +13,8 @@ in {
|
||||||
dependencies = [ "FILESYSTEMS" ];
|
dependencies = [ "FILESYSTEMS" ];
|
||||||
before = [ "nix-daemon" ];
|
before = [ "nix-daemon" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
freebsd.truss
|
||||||
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,6 +27,8 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
|
strace
|
||||||
|
|
||||||
# language servers
|
# language servers
|
||||||
nil
|
nil
|
||||||
rust-analyzer
|
rust-analyzer
|
||||||
|
|
|
@ -34,6 +34,7 @@
|
||||||
btop
|
btop
|
||||||
file
|
file
|
||||||
patchelf
|
patchelf
|
||||||
|
gdb
|
||||||
|
|
||||||
(python3.withPackages (p: with p; [
|
(python3.withPackages (p: with p; [
|
||||||
virtualenvwrapper
|
virtualenvwrapper
|
||||||
|
@ -57,12 +58,6 @@
|
||||||
'' + builtins.readFile ./dotfiles/zsh-prompt.sh;
|
'' + builtins.readFile ./dotfiles/zsh-prompt.sh;
|
||||||
shellInit = builtins.readFile ./dotfiles/zsh-init.sh;
|
shellInit = builtins.readFile ./dotfiles/zsh-init.sh;
|
||||||
shellAliases = {
|
shellAliases = {
|
||||||
nixos-edit = "(cd ~/nixos-config && vim configuration.nix)";
|
|
||||||
nixos-apply = "sudo nixos-rebuild switch --flake ~/nixos-config#$HOST";
|
|
||||||
ls = "ls --group-directories-first --color=auto";
|
|
||||||
ll = "ls -lh";
|
|
||||||
lh = "ll -ab";
|
|
||||||
l = "ls -ab";
|
|
||||||
grep = "grep --color=auto";
|
grep = "grep --color=auto";
|
||||||
egrep = "egrep --color=auto";
|
egrep = "egrep --color=auto";
|
||||||
objdump = "objdump -M intel";
|
objdump = "objdump -M intel";
|
||||||
|
|
|
@ -68,6 +68,24 @@ fi
|
||||||
|
|
||||||
# standard functions
|
# standard functions
|
||||||
|
|
||||||
|
function nixos-edit() {
|
||||||
|
(cd ~/nixos-config && vim configuration.nix)
|
||||||
|
}
|
||||||
|
|
||||||
|
function nixos-apply() {
|
||||||
|
sudo nixos-rebuild switch --flake ~/nixos-config#$HOST "$@"
|
||||||
|
}
|
||||||
|
|
||||||
|
lsflags=()
|
||||||
|
if ls --group-directories-first &>/dev/null; then
|
||||||
|
lsflags+=("--group-directories-first")
|
||||||
|
fi
|
||||||
|
|
||||||
|
alias ls="ls ${lsflags[@]} --color=auto";
|
||||||
|
alias ll="ls -lh";
|
||||||
|
alias lh="ll -ab";
|
||||||
|
alias l="ls -ab";
|
||||||
|
|
||||||
# https://stackoverflow.com/questions/6250698/how-to-decode-url-encoded-string-in-shell
|
# https://stackoverflow.com/questions/6250698/how-to-decode-url-encoded-string-in-shell
|
||||||
function urldecode() {
|
function urldecode() {
|
||||||
python3 -c "import sys; from urllib.parse import unquote; print(unquote(sys.stdin.read()));"
|
python3 -c "import sys; from urllib.parse import unquote; print(unquote(sys.stdin.read()));"
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
forBuildSystem = platform: let
|
forBuildSystem = platform: let
|
||||||
toBuildSystem = config: config.extendModules { modules = [ { nixpkgs.buildPlatform = platform; } ]; };
|
toBuildSystem = config: config.extendModules { modules = [ { nixpkgs.buildPlatform = platform; } ]; };
|
||||||
toToplevel = extended: {
|
toToplevel = extended: {
|
||||||
|
inherit (extended) config;
|
||||||
system = extended.config.system.build.toplevel;
|
system = extended.config.system.build.toplevel;
|
||||||
};
|
};
|
||||||
toSystem = name: config: toToplevel (toBuildSystem config);
|
toSystem = name: config: toToplevel (toBuildSystem config);
|
||||||
|
|
Loading…
Reference in New Issue