Date command lformat substitution operators, me totally out
Posted: Thu Feb 06, 2014 11:17 pm
lformat and possible bugs.
My system is Peg2/1gb/Radeon9250. This is made with normal amiga shell.
I used DATE command lformat substitution operators from http://www.titan.co.nz/amigaak/AA020844e2D.htm
Pretty amazing site... loads of useful information.
I renamed file qwe with next command set: rename qwe qwe.`date lformat %operator`
Im finetuning my backup logs, so find these.
Most operators works fine, some not.
%a works
%A works
%b works
%B works
%c fails,
3.RAM Disk:> rename qwe qwe.`date lformat %c`
RENAME: Destination "2014" is not a directory.
If I try to point comman to directory, result is similar.
%d works
%D fails,
3.RAM Disk:> rename qwe qwe.`date lformat %D`
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%e fails,
3.RAM Disk:> rename qwe qwe.`date lformat %e`
RENAME: Destination "6" is not a directory.
%h works
%H works
%I works
%j works
%m works
%n works
%p works
%q works
%Q works
%r fails
3.RAM Disk:> rename qwe qwe.`date lformat %r`
RENAME: Destination "PM" is not a directory.
%R fails,
3.RAM Disk:> rename qwe qwe.`date lformat %R`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:49" because
RENAME: device (or volume) is not mounted
%S works
%t works
%T fails,
3.RAM Disk:> rename qwe qwe.`date lformat %T`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:51:22" because
RENAME: device (or volume) is not mounted
%U works
%w works, counts as monday is first day of week, documentation says that should start from sunday
%W, counts as sunday is first day of week, my documentation says that should start from monday
Either doc is wrong or output is wrong?
%x fails,
3.RAM Disk:> rename qwe qwe.`date lformat %x`
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%X fails,
3.RAM Disk:> rename qwe qwe.`date lformat %X`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:54:28" because
RENAME: device (or volume) is not mounted
%y works
%Y works
There seems to be three different misbehaving.
1st
Operator %c
RENAME: Destination "2014" is not a directory.
Operator %e
RENAME: Destination "6" is not a directory.
Operator %r
RENAME: Destination "PM" is not a directory.
%c - same as "%a %b %d %H:%M:%S %Y"
%e - day number with leading spaces
%r - same as "%I:%M:%S %p"
2nd
Operator %D
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
Operator %x
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%D - same as "%m/%d/%y"
%x - same as "%m/%d/%y"
3rd
Operator %R
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:49" because
RENAME: device (or volume) is not mounted
Operator %T
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:51:22" because
RENAME: device (or volume) is not mounted
Operator %X
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:54:28" because
RENAME: device (or volume) is not mounted
%R - same as "%H:%M"
%T - same as "%H:%M:%S"
%X - same as "%H:%M:%S"
Could someone from betatesting team test and confirm ?
Thanks.
My system is Peg2/1gb/Radeon9250. This is made with normal amiga shell.
I used DATE command lformat substitution operators from http://www.titan.co.nz/amigaak/AA020844e2D.htm
Pretty amazing site... loads of useful information.
I renamed file qwe with next command set: rename qwe qwe.`date lformat %operator`
Im finetuning my backup logs, so find these.
Most operators works fine, some not.
%a works
%A works
%b works
%B works
%c fails,
3.RAM Disk:> rename qwe qwe.`date lformat %c`
RENAME: Destination "2014" is not a directory.
If I try to point comman to directory, result is similar.
%d works
%D fails,
3.RAM Disk:> rename qwe qwe.`date lformat %D`
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%e fails,
3.RAM Disk:> rename qwe qwe.`date lformat %e`
RENAME: Destination "6" is not a directory.
%h works
%H works
%I works
%j works
%m works
%n works
%p works
%q works
%Q works
%r fails
3.RAM Disk:> rename qwe qwe.`date lformat %r`
RENAME: Destination "PM" is not a directory.
%R fails,
3.RAM Disk:> rename qwe qwe.`date lformat %R`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:49" because
RENAME: device (or volume) is not mounted
%S works
%t works
%T fails,
3.RAM Disk:> rename qwe qwe.`date lformat %T`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:51:22" because
RENAME: device (or volume) is not mounted
%U works
%w works, counts as monday is first day of week, documentation says that should start from sunday
%W, counts as sunday is first day of week, my documentation says that should start from monday
Either doc is wrong or output is wrong?
%x fails,
3.RAM Disk:> rename qwe qwe.`date lformat %x`
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%X fails,
3.RAM Disk:> rename qwe qwe.`date lformat %X`
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:54:28" because
RENAME: device (or volume) is not mounted
%y works
%Y works
There seems to be three different misbehaving.
1st
Operator %c
RENAME: Destination "2014" is not a directory.
Operator %e
RENAME: Destination "6" is not a directory.
Operator %r
RENAME: Destination "PM" is not a directory.
%c - same as "%a %b %d %H:%M:%S %Y"
%e - day number with leading spaces
%r - same as "%I:%M:%S %p"
2nd
Operator %D
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
Operator %x
RENAME: Can't rename "qwe" as "qwe.02/06/14" because
RENAME: object not found
%D - same as "%m/%d/%y"
%x - same as "%m/%d/%y"
3rd
Operator %R
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:49" because
RENAME: device (or volume) is not mounted
Operator %T
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:51:22" because
RENAME: device (or volume) is not mounted
Operator %X
Amigados requester, Please insert volume qwe.23 in any drive Proess: 954 "rename"
RENAME: Can't rename "qwe" as "qwe.23:54:28" because
RENAME: device (or volume) is not mounted
%R - same as "%H:%M"
%T - same as "%H:%M:%S"
%X - same as "%H:%M:%S"
Could someone from betatesting team test and confirm ?
Thanks.