From 5cad5f4a647765ff34e2aa3a867aabc1322703dd Mon Sep 17 00:00:00 2001 From: swaggboi Date: Sat, 15 Mar 2025 00:43:34 +0000 Subject: [PATCH] Change .profile EDITOR back since that's set in .kshrc; do EDITOR check in .kshrc; new TODOs --- README.md | 5 +++++ my_home/.kshrc | 21 ++++++++++++++------- my_home/.profile | 2 +- 3 files changed, 20 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index de441d4..cc57394 100644 --- a/README.md +++ b/README.md @@ -4,3 +4,8 @@ Dotfiles. For NetBSD. The `my_home` represents `$HOME` to keep directory structure for things that don't use `$HOME/.config`. + +## TODO + +- Login shell check to do fortune output (breaks `rsync`) +- Make `mg` stop leaving those damn tilde files diff --git a/my_home/.kshrc b/my_home/.kshrc index bc6dfea..119abdc 100644 --- a/my_home/.kshrc +++ b/my_home/.kshrc @@ -1,8 +1,10 @@ -if [ -x /usr/games/fortune ]; then - echo - /usr/games/fortune - echo -fi +# .kshrc 3/14/2025 + +# Need to do the 'login shell' test before running this +#if [ -x /usr/games/fortune ]; then +# /usr/games/fortune +# echo +#fi # user specific aliases alias l='ls -lhF' @@ -18,7 +20,12 @@ alias n='cat -n' # exports export PS1='$USER:/${PWD#/}:!$ ' -export EDITOR='mg' export PATH="$HOME/bin:$PATH" export HISTFILE="$HOME/.sh_history" -export PKG_PATH="http://ftp.netbsd.org/pub/pkgsrc/packages/NetBSD/amd64/10.1/All/" +export PKG_PATH="http://cdn.netbsd.org/pub/pkgsrc/packages/NetBSD/amd64/10.1/All/" + +if command -v emacs > /dev/null 2>&1; then + export EDITOR='emacs -nw' +elif command -v mg > /dev/null 2>&1; then + export EDITOR='mg' +fi diff --git a/my_home/.profile b/my_home/.profile index 0fd6ccd..e07ccca 100644 --- a/my_home/.profile +++ b/my_home/.profile @@ -13,7 +13,7 @@ # software will run ed and other software will fail. Can be set to # emacs or nano or whatever other editor you may prefer, but of course # those editors must be installed before you can use them. -export EDITOR=mg +export EDITOR=vi # vi settings: set show-match auto-indent always-redraw shift-width=4 #export EXINIT="se sm ai redraw sw=4"