xref: /freebsd/share/skel/dot.shrc (revision d0b2dbfa0ecf2bbc9709efc5e20baf8e4b44bbbf)
1386e8837SWolfram Schneider#
2386e8837SWolfram Schneider# .shrc - bourne shell startup file
3386e8837SWolfram Schneider#
4386e8837SWolfram Schneider# This file will be used if the shell is invoked for interactive use and
5386e8837SWolfram Schneider# the environment variable ENV is set to this file.
6386e8837SWolfram Schneider#
7386e8837SWolfram Schneider# see also sh(1), environ(7).
8386e8837SWolfram Schneider#
9386e8837SWolfram Schneider
10386e8837SWolfram Schneider
11386e8837SWolfram Schneider# file permissions: rwxr-xr-x
12386e8837SWolfram Schneider#
13386e8837SWolfram Schneider# umask	022
14386e8837SWolfram Schneider
15824c5192SJilles Tjoelker# Uncomment this to enable the builtin vi(1) command line editor in sh(1),
16824c5192SJilles Tjoelker# e.g. ESC to go into visual mode.
17698f822dSJuli Mallett# set -o vi
18386e8837SWolfram Schneider
19386e8837SWolfram Schneider
20386e8837SWolfram Schneider# some useful aliases
21386e8837SWolfram Schneideralias h='fc -l'
22386e8837SWolfram Schneideralias j=jobs
231a1620dcSEitan Adleralias m="$PAGER"
24386e8837SWolfram Schneideralias ll='ls -laFo'
25386e8837SWolfram Schneideralias l='ls -l'
26386e8837SWolfram Schneideralias g='egrep -i'
27386e8837SWolfram Schneider
28386e8837SWolfram Schneider# # be paranoid
29386e8837SWolfram Schneider# alias cp='cp -ip'
30386e8837SWolfram Schneider# alias mv='mv -i'
31386e8837SWolfram Schneider# alias rm='rm -i'
32386e8837SWolfram Schneider
335fe97373SBaptiste Daroussin# # csh like history on arrow up and down
345fe97373SBaptiste Daroussinbind ^[[A ed-search-prev-history
355fe97373SBaptiste Daroussinbind ^[[B ed-search-next-history
365fe97373SBaptiste Daroussin
375fe97373SBaptiste Daroussin# # ctrl+arrow allow to jump from words to words
385fe97373SBaptiste Daroussinbind "\\e[1;5C" em-next-word
395fe97373SBaptiste Daroussinbind "\\e[1;5D" ed-prev-word
405fe97373SBaptiste Daroussinalias history='fc -l'
41386e8837SWolfram Schneider
42*f3aad18dSBaptiste Daroussin# Fix home/del for mobaxterm
43*f3aad18dSBaptiste Daroussinbind ^[[5~ ed-move-to-beg
44*f3aad18dSBaptiste Daroussinbind ^[[6~ ed-move-to-end
45*f3aad18dSBaptiste Daroussin
46488174baSEdward Tomasz Napierala# set prompt: ``username@hostname:directory $ ''
47d81ca439SEdward Tomasz NapieralaPS1="\u@\h:\w \\$ "
48386e8837SWolfram Schneider
49386e8837SWolfram Schneider# search path for cd(1)
504ae95455SJilles Tjoelker# CDPATH=:$HOME
51