Browse Source

Three rdist log file name improvements on one single line:

1) replace +%e by +%d, unescaped blanks don't work at all in file names
2) replace +%b by +%m to make log files sort better by month
3) replace the home-grown +%Y.%m.%d by the standard +%F (= +%Y-%m-%d)
from Tim van der Molen <tbvdm at xs4all dot nl>, thanks!
ok okan@
OPENBSD_4_6
schwarze 15 years ago
parent
commit
45b8893465
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      src/etc/daily

+ 2
- 3
src/etc/daily View File

@ -1,5 +1,5 @@
#
# $OpenBSD: daily,v 1.65 2009/05/25 21:31:24 schwarze Exp $
# $OpenBSD: daily,v 1.66 2009/05/26 22:59:15 schwarze Exp $
# From: @(#)daily 8.2 (Berkeley) 1/25/94
#
# For local additions, create the file /etc/daily.local.
@ -175,8 +175,7 @@ next_part "Checking filesystems:"
next_part "Running rdist:"
if [ -f /etc/Distfile ]; then
if [ -d /var/log/rdist ]; then
logf=`date +%Y.%b.%e`
rdist -f /etc/Distfile 2>&1 | tee /var/log/rdist/$logf
rdist -f /etc/Distfile 2>&1 | tee /var/log/rdist/`date +%F`
else
rdist -f /etc/Distfile
fi


Loading…
Cancel
Save