From 2fe1ccf386c9bc64848854bf4287638344149fa9 Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Thu, 21 Nov 2019 17:37:01 -0500 Subject: Use .profile, .shrc, .history --- home/.profile | 20 ++++++++++++++++++++ home/.shrc | 31 +++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) create mode 100644 home/.profile create mode 100644 home/.shrc (limited to 'home') diff --git a/home/.profile b/home/.profile new file mode 100644 index 00000000..c2e14ba0 --- /dev/null +++ b/home/.profile @@ -0,0 +1,20 @@ +_PATH=$PATH +for prefix in '' /usr/local /usr/pkg /usr /opt/pkg ~/.local; do + PATH=${PATH}${PATH:+:}${prefix}/sbin:${prefix}/bin +done +PATH=$PATH:/usr/games + +export PAGER=less +export LESS=FRX +export EDITOR=nvim +export MANPAGER="nvim -c 'set ft=man' -" +export MANSECT=2:3:1:8:6:5:7:4:9 +export CLICOLOR=1 +export GPG_TTY=$(tty) +export NETHACKOPTIONS='pickup_types:$!?+/=, color, DECgraphics' + +type nvim >/dev/null || EDITOR=vim +[ -e /usr/share/mk/sys.mk ] || export CFLAGS=-O +cd + +export ENV=~/.shrc diff --git a/home/.shrc b/home/.shrc new file mode 100644 index 00000000..e815a748 --- /dev/null +++ b/home/.shrc @@ -0,0 +1,31 @@ +set -o noclobber -o nounset -o vi + +HISTFILE=~/.history +CDPATH=:~ + +alias vim=$EDITOR +alias ls='ls -p' +alias ll='ls -hl' +alias bc='bc -l' +alias gs='git status --short --branch || ls' gd='git diff' +alias gsh='git show' gl='git log --graph --pretty=log' +alias gco='git checkout' gb='git branch' gm='git merge' gst='git stash' +alias ga='git add' gmv='git mv' grm='git rm' +alias gc='git commit' gca='gc --amend' gt='git tag' +alias gp='git push' gu='git pull' gf='git fetch' +alias gr='git rebase' gra='gr --abort' grc='gr --continue' grs='gr --skip' +alias rand='openssl rand -base64 33' +alias private='eval "$(gpg -d ~/.private)"' +if [ "$(uname)" = 'Linux' ]; then + alias ls='ls --color=auto' grep='grep --color' +fi + +PS0=$'\n' +PS1='\$ ' +RPS1="\? ${SSH_CLIENT:+\h:}\w" + +if [ "${TERM%-*}" = 'xterm' ]; then + tsl=$'\e]0;' + fsl=$'\e\\' + PS0="${tsl}${SSH_CLIENT:+\h:}\W${fsl}${PS0}" +fi -- cgit 1.4.1 8cee783c6002f94b2fa9432470738&showmsg=1&follow=1'>root/LICENSE (unfollow)
Commit message (Collapse)Author
2020-05-02Pass explicit host to git-credentialJune McEnroe
2020-05-02Fix git-fetch-email argument parsingJune McEnroe
Shell script is hard.
2020-05-02Remove git am from imbox.1 exampleJune McEnroe
It should have --patch-format=mboxrd but it's clumsy and git-fetch-email --apply should be used for that anyway.
2020-05-02Rewrite git-fetch-email with git rev-parse --parseoptJune McEnroe
Adds long options, -u/--user, -a/--apply to automatically pipe to git-am.
2020-05-02Update email addressesJune McEnroe
2020-05-01Update compat.h for split read/write streamsJune McEnroe
2020-05-01Simplify imbox code and remove text/plain restrictionJune McEnroe
2020-05-01Update IMAP parserJune McEnroe
2020-04-08Remove unused includesJune McEnroe
2020-04-08Add compat.h dependency to MakefileJune McEnroe
2020-04-08Use a real IMAP parserJune McEnroe
2020-04-07Simplify mboxrd output 1.0p2June McEnroe
2020-04-06Don't bother generating real From linesJune McEnroe
This is the From line that public-inbox uses, and is probably better since it indicates mboxrd format.
2020-03-03Don't use $ inside $(()) 1.0p1June McEnroe
2020-03-03Use getoptsJune McEnroe
2020-01-28Call fopencookie with a+June McEnroe
Otherwise interleaved reads and writes can interfere with each other, since you're supposed to have intervening fseeks.
2019-12-24Exit git-fetch-email on getopt failure 1.0June McEnroe
2019-12-23Export References headerJune McEnroe
2019-12-23Add (GNU/)Linux compatibilityJune McEnroe
Implements a dumb version of readpassphrase that calls getpass and implements funopen in terms of fopencookie.
2019-12-23Handle folded From headersJune McEnroe
2019-12-23Restrict search to plain-text messagesJune McEnroe
2019-12-23Properly support using drill rather than digJune McEnroe
Silly drill doesn't have +short, so emulate it by waiting for the ANSWER SECTION and skipping the leading fields.
2019-12-22Document dig requirement in imbox(1)June McEnroe
2019-12-22Add CAVEAT about expecting plain-textJune McEnroe
2019-12-22Quote user, pass and mailboxJune McEnroe
2019-12-22Use sequence numbers rather than UIDsJune McEnroe
We aren't doing any expunging or anything across different sessions, so it's safe to just use sequence numbers.
2019-12-22Use EXAMINE rather than SELECTJune McEnroe
This is a read-only operation.
2019-12-22Export To and CC headersJune McEnroe
2019-12-22Add missing includeJune McEnroe
2019-12-22Export In-Reply-To headersJune McEnroe
2019-12-21Add git-fetch-email to READMEJune McEnroe
2019-12-21Clarify purpose in READMEJune McEnroe
2019-12-21Add READMEJune McEnroe
2019-12-21Add copyright header to git-fetch-emailJune McEnroe
2019-12-21Add git-fetch-email to SEE ALSO of imboxJune McEnroe
2019-12-21Add git-fetch-email wrapperJune McEnroe
2019-12-21Determine host by SRV lookupJune McEnroe
2019-12-21Clean up remaining codeJune McEnroe
2019-12-21Clean up mboxrd codeJune McEnroe
2019-12-21Convert CRLF to LFJune McEnroe
2019-12-21Implement -CFSTJune McEnroe
2019-12-21Rewrite aspirational manualJune McEnroe
2019-12-21Null-terminate read literalsJune McEnroe