From 29a37ca8207c8c143b84da061e7d78b33135765d Mon Sep 17 00:00:00 2001 From: rawley Date: Mon, 27 Jul 2026 08:24:15 -0600 Subject: [PATCH] initial commit --- desktop/.kshrc | 53 ++++++++++++++++++++++++++++++++++++++++++++++++ desktop/.profile | 28 +++++++++++++++++++++++++ server/.kshrc | 53 ++++++++++++++++++++++++++++++++++++++++++++++++ server/.profile | 28 +++++++++++++++++++++++++ 4 files changed, 162 insertions(+) create mode 100644 desktop/.kshrc create mode 100644 desktop/.profile create mode 100644 server/.kshrc create mode 100644 server/.profile diff --git a/desktop/.kshrc b/desktop/.kshrc new file mode 100644 index 0000000..691833b --- /dev/null +++ b/desktop/.kshrc @@ -0,0 +1,53 @@ +# ~/.kshrc +# +# KornShell configuration for NetBSD +# +export EDITOR=emacs -nw +export VISUAL=emacs +export PAGER=less +export MANPAGER=less +export LANG=en_CA.UTF-8 +export LC_CTYPE=en_CA.UTF-8 +export ENV="$HOME/.kshrc" + +PATH="$HOME/bin:/usr/pkg/bin:/usr/pkg/sbin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin" +export PATH + +HISTFILE="$HOME/.ksh_history" +HISTSIZE=500 +SAVEHIST=500 + +set -o emacs +set -o noclobber +set -o notify + +mkcd() { + mkdir -p "$1" && cd "$1" +} + +extract() { + case "$1" in + *.tar.gz|*.tgz) tar xzf "$1" ;; + *.tar.bz2) tar xjf "$1" ;; + *.tar.xz) tar xJf "$1" ;; + *.zip) unzip "$1" ;; + *) echo "Don't know how to extract $1" ;; + esac +} + +export kE="`echo x | tr x '\033'`" +export kGreen="${kE}[1;32m" +export kBlue="${kE}[1;34m" +export kEnd="${kE}[0m" + +case "$TERM" in + xterm*|rxvt*|screen*|tmux*) + export PS1='${kGreen}[${USER}${kEnd}@${kBlue}$(hostname -s)${kGreen}]${kEnd} $ ' + ;; +esac + +if [ -t 1 ]; then + printf "NetBSD %s (%s)\n" "$(uname -r)" "$(uname -m)" +fi + +export ENV="$HOME/.kshrc" diff --git a/desktop/.profile b/desktop/.profile new file mode 100644 index 0000000..9ae8762 --- /dev/null +++ b/desktop/.profile @@ -0,0 +1,28 @@ +# $NetBSD: dot.profile,v 1.12 2024/09/23 12:12:36 uwe Exp $ +# +# This is the default .profile file. +# Users are expected to edit it to meet their own needs. +# +# The commands in this file are executed when an sh user first +# logs in. +# +# See sh(1) for details. + +# Many modern terminal emulators don't provide a way to disable +# alternate screen switching (like xterm's titeInhibit). less(1) has +# its own option (-X) for that that you can use to alleviate the pain, +# as PAGER is the most common scenario for hitting this. Add other +# flags according to taste. +#export LESS='-i -M -X' + +# Set your default printer, if desired. +#export PRINTER=change-this-to-a-printer + +# Set the search path for programs. +PATH=$HOME/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R7/bin:/usr/pkg/bin +PATH=${PATH}:/usr/pkg/sbin:/usr/games:/usr/local/bin:/usr/local/sbin +export PATH + +# Configure the shell to load .shrc at startup time. +# This will happen for every shell started, not just login shells. +export ENV=$HOME/.kshrc diff --git a/server/.kshrc b/server/.kshrc new file mode 100644 index 0000000..2485329 --- /dev/null +++ b/server/.kshrc @@ -0,0 +1,53 @@ +# ~/.kshrc +# +# KornShell configuration for NetBSD +# +export EDITOR=vi +export VISUAL=vi +export PAGER=less +export MANPAGER=less +export LANG=en_CA.UTF-8 +export LC_CTYPE=en_CA.UTF-8 +export ENV="$HOME/.kshrc" + +PATH="$HOME/bin:/usr/pkg/bin:/usr/pkg/sbin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin" +export PATH + +HISTFILE="$HOME/.ksh_history" +HISTSIZE=500 +SAVEHIST=500 + +set -o vi +set -o noclobber +set -o notify + +mkcd() { + mkdir -p "$1" && cd "$1" +} + +extract() { + case "$1" in + *.tar.gz|*.tgz) tar xzf "$1" ;; + *.tar.bz2) tar xjf "$1" ;; + *.tar.xz) tar xJf "$1" ;; + *.zip) unzip "$1" ;; + *) echo "Don't know how to extract $1" ;; + esac +} + +export kE="`echo x | tr x '\033'`" +export kGreen="${kE}[1;32m" +export kBlue="${kE}[1;34m" +export kEnd="${kE}[0m" + +case "$TERM" in + xterm*|rxvt*|screen*|tmux*) + export PS1='${kGreen}[${USER}${kEnd}@${kBlue}$(hostname -s)${kGreen}]${kEnd} $ ' + ;; +esac + +if [ -t 1 ]; then + printf "NetBSD %s (%s)\n" "$(uname -r)" "$(uname -m)" +fi + +export ENV="$HOME/.kshrc" diff --git a/server/.profile b/server/.profile new file mode 100644 index 0000000..9ae8762 --- /dev/null +++ b/server/.profile @@ -0,0 +1,28 @@ +# $NetBSD: dot.profile,v 1.12 2024/09/23 12:12:36 uwe Exp $ +# +# This is the default .profile file. +# Users are expected to edit it to meet their own needs. +# +# The commands in this file are executed when an sh user first +# logs in. +# +# See sh(1) for details. + +# Many modern terminal emulators don't provide a way to disable +# alternate screen switching (like xterm's titeInhibit). less(1) has +# its own option (-X) for that that you can use to alleviate the pain, +# as PAGER is the most common scenario for hitting this. Add other +# flags according to taste. +#export LESS='-i -M -X' + +# Set your default printer, if desired. +#export PRINTER=change-this-to-a-printer + +# Set the search path for programs. +PATH=$HOME/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11R7/bin:/usr/pkg/bin +PATH=${PATH}:/usr/pkg/sbin:/usr/games:/usr/local/bin:/usr/local/sbin +export PATH + +# Configure the shell to load .shrc at startup time. +# This will happen for every shell started, not just login shells. +export ENV=$HOME/.kshrc