source: packages/utils/mksh/patches/100-dot_mkshrc @ 31186

Last change on this file since 31186 was 31186, checked in by florian, 5 years ago

[package] mksh: update to 40d

Signed-off-by: Thorsten Glaser <tg@…>

File size: 1.2 KB
Line 
1$Id$
2
3        • Part of the FreeWRT patches:
4          – no hostname(1)
5          – ls(1) has no -o option
6        • OpenWrt and FreeWRT-1.0 fix:
7          – since this is not ~/.mkshrc make sure subshells find it
8
9--- a/dot.mkshrc        Sat Nov 26 18:15:38 2011
10+++ b/dot.mkshrc        Sun Dec 11 21:31:27 2011
11@@ -21,7 +21,7 @@
12 #-
13 # ${ENV:-~/.mkshrc}: mksh initialisation file for interactive shells
14 
15-: ${EDITOR:=/bin/ed} ${TERM:=vt100} ${HOSTNAME:=$(ulimit -c 0;hostname -s 2>&-)}
16+: ${EDITOR:=/bin/ed} ${TERM:=vt100} ${HOSTNAME:=$(</proc/sys/kernel/hostname)}
17 [[ $HOSTNAME = @(localhost|*([  ])) ]] && HOSTNAME=$(ulimit -c 0;hostname 2>&-)
18 : ${HOSTNAME:=nil}; if (( USER_ID )); then PS1='$'; else PS1='#'; fi
19 function precmd {
20@@ -40,7 +40,7 @@ unalias ls
21 alias l='ls -F'
22 alias la='l -a'
23 alias ll='l -l'
24-alias lo='l -alo'
25+alias lo='l -al'
26 whence -p rot13 >&- || alias rot13='tr \
27     abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ \
28     nopqrstuvwxyzabcdefghijklmNOPQRSTUVWXYZABCDEFGHIJKLM'
29@@ -365,5 +365,9 @@ alias cls='print -n \\033c'
30 #export LANG=C LC_CTYPE=$p LC_MEASUREMENT=$p LC_MESSAGES=$p LC_PAPER=$p
31 
32 unset p
33+
34+# we need this in OpenWrt for subshells that are not login shells
35+: ${ENV=/etc/mkshrc}
36+[[ -z $ENV ]] || export ENV
37 
38 : place customisations above this line
Note: See TracBrowser for help on using the repository browser.