2022-08-02 01:50:50 -05:00
|
|
|
{ pkgs, config, lib, ... }:
|
2022-04-29 10:58:31 -05:00
|
|
|
|
2022-08-02 01:50:50 -05:00
|
|
|
{
|
2022-04-29 10:58:31 -05:00
|
|
|
programs.xonsh = {
|
|
|
|
|
enable = true;
|
|
|
|
|
|
|
|
|
|
sessionVariables = {
|
|
|
|
|
CLICOLOR = 1;
|
|
|
|
|
EDITOR = "${pkgs.vim}/bin/vim";
|
|
|
|
|
# vte_new_tab_cwd causes new Terminal tabs to open in the
|
|
|
|
|
# same CWD as the current tab
|
|
|
|
|
LESS_TERMCAP_mb = "\\033[01;31m"; # begin blinking
|
|
|
|
|
LESS_TERMCAP_md = "\\033[01;31m"; # begin bold
|
|
|
|
|
LESS_TERMCAP_me = "\\033[0m"; # end mode
|
|
|
|
|
LESS_TERMCAP_so = "\\033[01;44;36m"; # begin standout-mode (bottom of screen)
|
|
|
|
|
LESS_TERMCAP_se = "\\033[0m"; # end standout-mode
|
|
|
|
|
LESS_TERMCAP_us = "\\033[00;36m"; # begin underline
|
|
|
|
|
LESS_TERMCAP_ue = "\\033[0m"; # end underline
|
2024-06-12 10:45:43 -05:00
|
|
|
LIBMYSQL_ENABLE_CLEARTEXT_PLUGIN = "1";
|
|
|
|
|
LSCOLORS = "ExGxBxDxCxEgEdxbxgxcxd";
|
|
|
|
|
MAVEN_OPTS = " -Dmaven.wagon.http.ssl.insecure=true";
|
|
|
|
|
OS_CLOUD = "default";
|
|
|
|
|
PROMPT = "{vte_new_tab_cwd}{env_name}{BOLD_GREEN}{user}@{hostname}{BOLD_BLUE} {short_cwd}{branch_color}{curr_branch: {}}{RESET} {BOLD_BLUE}{prompt_end}{RESET} ";
|
|
|
|
|
SWORD_PATH = "${config.home.homeDirectory}/.sword/";
|
|
|
|
|
TIMEFORMAT = "%3Uu %3Ss %3lR %P%%";
|
|
|
|
|
# Tells vox where to find virtualenvs
|
|
|
|
|
VIRTUALENV_HOME = "${config.home.homeDirectory}/venv/";
|
2022-11-07 13:52:53 -06:00
|
|
|
|
2024-01-23 14:46:59 -06:00
|
|
|
COMPASS_SKIP_ORIGIN_CHECK = "True";
|
|
|
|
|
|
2022-11-07 13:52:53 -06:00
|
|
|
GOPATH = "${config.home.homeDirectory}/src/go";
|
|
|
|
|
GOBIN = "${config.home.homeDirectory}/src/bin";
|
2022-04-29 10:58:31 -05:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
aliases = {
|
|
|
|
|
ac = "vox activate";
|
2022-11-10 08:22:42 -06:00
|
|
|
|
2024-01-22 12:15:46 -06:00
|
|
|
cavg = "compass workspace exec bazel run src/go/compass.com/tools/circleci_results_cache/avg_duration/cmd/avg_duration:avg_duration";
|
2023-12-06 12:53:14 -06:00
|
|
|
cbazel = "compass workspace exec bazel";
|
2022-09-27 11:04:50 -05:00
|
|
|
cblack = "compass workspace run src/python3/uc/tools:run_black --";
|
2022-11-01 14:50:38 -05:00
|
|
|
cbuild = "compass workspace build";
|
2023-11-27 16:28:09 -06:00
|
|
|
cci = "compass workspace run src/python3/uc/tools:circleci-checks";
|
2023-12-06 12:53:14 -06:00
|
|
|
ccover = "compass workspace cover --extra-cmd-args=\"--test_output=errors\"";
|
|
|
|
|
cexec = "compass workspace exec";
|
2023-08-07 16:16:20 -05:00
|
|
|
cgh = "$GH_CONFIG_DIR=\"${config.home.homeDirectory}/.config/gh/compass\" gh";
|
2023-12-06 12:53:14 -06:00
|
|
|
cpip = "compass workspace run src/python3/uc/tools:run_pip_compile";
|
2022-09-27 11:04:50 -05:00
|
|
|
crun = "compass workspace run";
|
2023-08-18 13:16:23 -05:00
|
|
|
ctest = "compass workspace test --extra-cmd-args=\"--test_output=errors\"";
|
2023-11-27 16:28:09 -06:00
|
|
|
cylint = "compass workspace run src/python3/uc/tools:run_yaml_lint";
|
2023-10-26 08:53:58 -05:00
|
|
|
gazelle = "compass workspace exec bazel run :gazelle";
|
2022-11-10 08:22:42 -06:00
|
|
|
|
2023-12-11 12:25:35 -06:00
|
|
|
cleanup = "sudo nix-collect-garbage --delete-older-than 30d && nix store optimise";
|
2022-04-29 10:58:31 -05:00
|
|
|
d = "vox deactivate";
|
2022-09-27 11:04:50 -05:00
|
|
|
dirflake = "nix flake new -t github:nix-community/nix-direnv";
|
2023-08-07 16:16:20 -05:00
|
|
|
gh-personal = "$GH_CONFIG_DIR=\"${config.home.homeDirectory}/.config/gh/personal\" gh";
|
2024-07-22 17:46:02 -05:00
|
|
|
gl-nging = "sudo nixos-container run gitlab -- systemctl restart nginx";
|
2023-06-28 22:50:29 -05:00
|
|
|
ls = "ls --color";
|
|
|
|
|
ll = "ls -l --color";
|
2022-04-29 10:58:31 -05:00
|
|
|
molcol = "molecule -c ../../tests/molecule.yml";
|
2022-11-10 08:22:42 -06:00
|
|
|
nixup = "nix flake lock --update-input";
|
2022-04-29 10:58:31 -05:00
|
|
|
pa = "cd ~/src/packaging";
|
2024-01-17 12:34:10 -06:00
|
|
|
tf = "terraform";
|
2022-06-12 00:50:26 -05:00
|
|
|
tsup = "sudo tailscale up";
|
|
|
|
|
tspub = "sudo tailscale up --exit-node=linode";
|
2022-06-13 16:14:41 +00:00
|
|
|
tshome = "sudo tailscale up --exit-node=2maccabees";
|
2022-06-12 00:56:46 -05:00
|
|
|
tsclear = "sudo tailscale up --exit-node=''";
|
2022-09-27 11:04:50 -05:00
|
|
|
vdown = "vagrant destroy";
|
|
|
|
|
vhalt = "vagrant halt";
|
|
|
|
|
vos = "vagrant up --provision --provider openstack";
|
|
|
|
|
vprov = "vagrant provision";
|
|
|
|
|
vup = "vagrant up --provision --provider libvirt";
|
|
|
|
|
vssh = "vagrant ssh";
|
2022-04-29 10:58:31 -05:00
|
|
|
};
|
|
|
|
|
|
2022-11-10 10:54:22 -06:00
|
|
|
configHeader = builtins.readFile ./xonsh_header.xsh;
|
2024-01-16 23:02:05 -06:00
|
|
|
configFooter = (builtins.readFile ./xonsh_footer.xsh) + (builtins.concatStringsSep "\n" [
|
|
|
|
|
"with open('${pkgs.stdenv.cc}/nix-support/dynamic-linker', 'r') as fp:"
|
|
|
|
|
" $NIX_LD = fp.read().strip()"
|
|
|
|
|
]);
|
2022-04-29 10:58:31 -05:00
|
|
|
};
|
|
|
|
|
}
|