aboutsummaryrefslogtreecommitdiff
path: root/libexec/rc
diff options
context:
space:
mode:
authorXin LI <delphij@FreeBSD.org>2023-05-23 04:23:57 +0000
committerXin LI <delphij@FreeBSD.org>2023-05-23 05:05:35 +0000
commit634a770a5e16b424c096b74ac33a145e766dd7af (patch)
treee748149574fbf6e9b1b192fff61d455bb9b77149 /libexec/rc
parent5a9c724847f9b4e3831aa2c16276cc2ae20a99cc (diff)
Diffstat (limited to 'libexec/rc')
-rwxr-xr-xlibexec/rc/rc.d/motd3
1 files changed, 2 insertions, 1 deletions
diff --git a/libexec/rc/rc.d/motd b/libexec/rc/rc.d/motd
index d9dd60a0f59a..e27cf273741d 100755
--- a/libexec/rc/rc.d/motd
+++ b/libexec/rc/rc.d/motd
@@ -45,7 +45,8 @@ motd_start()
fi
T=`mktemp -t motd`
- uname -v | sed -e 's,^\([^#]*\) #\(.* [1-2][0-9][0-9][0-9]\).*/\([^\]*\) $,\1 (\3) #\2,' > ${T}
+ uname -v | sed -e 's,^\([^#]*\) #\(.* [1-2][0-9][0-9][0-9]\).*/\([^\]*\)$,\1 (\3) #\2,' \
+ -e 's,^\([^ ]*\) \([^ ]*\) \([^ ]*\) \([^ ]*\)$,\1 \2 (\4) \3,' > ${T}
cat "${TEMPLATE}" >> ${T}
install -C -o root -g wheel -m "${PERMS}" "$T" "${TARGET}"