Login
Username:

Password:

Remember me



Lost Password?

Register now!
Sections
Who's Online
62 user(s) are online (58 user(s) are browsing Forums)

Members: 0
Guests: 62

more...
Support us!
Recent OS4 Files
OS4Depot.net





Delete command quirks
Quite a regular
Joined:
2007/2/27 10:47
From Gravity well
Posts: 644
So there's an undocumented feature of the "4.1" delete command (version 53.2). Suppose you have a directory soft_demonstration , that has one file in it. If you give delete the path of this file (relative or absolute) and any number of names that are not found, there will be a message about each:

7.RAM Disk:> echo ... > soft_demonstration/unimportant_file
7.RAM Disk
:> delete RAM:soft_demonstration/unimportant_file peekaboo_number_two peekaboo_numero_uno
RAM
:soft_demonstration/unimportant_file  Deleted
peekaboo_number_two  Not Deleted
object not found
peekaboo_numero_uno  Not Deleted
object not found


That's expected, right? But if something like this occurs, the silence is surprising:

7.RAM Disk:> echo ... > soft_demonstration/unimportant_file
7.RAM Disk
:> delete soft_demonstration there_is_not_anything_here_at all
soft_demonstration
/unimportant_file  Deleted
soft_demonstration  Deleted


So in other words, if you use the "all" modifier, the output resembles the delete of old (version 37.8). That one only notifies if there was nothing to delete. AmigaOS 4.0 equivalent is different, it mentions not found things by name unless you have "all" in. Then the message is a generic "object not found".

The above example could be flat, referencing just a file without any directory, "all" is the deciding thing.


Edited by Rigo on 2019/6/16 15:20:05
   Report Go to top

Re: delete thread
Quite a regular
Joined:
2006/12/2 0:35
From Sydney
Posts: 683
What do you find strange? Do you think there is something wrong?

_________________
cheers
tony
   Report Go to top

Re: delete thread
Quite a regular
Joined:
2007/2/27 10:47
From Gravity well
Posts: 644
No, I'm just showing off the quirks and features of the system.

   Report Go to top

Re: delete thread
Home away from home
Joined:
2006/12/4 23:15
Posts: 2106
Dunno if it's just me but the title of this thread suggest you want it deleted rather than it being about Delete Perhaps change it to "DELETE command quirks" or something

AS to the supression of file not found errors perhaps it to make it work betterwith something like

DELETE all foo foo/bar

once foo was dleted foo/bar would give an error if not supressed and whilst that might not be an issue in command line usage it could trip up some auto created script.


_________________
Blender For OS4.x : Blues : Walker Broad
   Report Go to top

Re: delete thread
Supreme Council
Joined:
2006/11/16 19:25
From Sweden
Posts: 3145
@broadblues

Yeah, I was close to deleting it by mistake 3-4 times already ;)

_________________
Vacca foeda. Sum, ergo edo

Mr Bobo Cornwater
   Report Go to top





[Advanced Search]


Powered by XOOPS 2.0 © 2001-2016 The XOOPS Project