in reply to Re: chosse selected files and delete rest
in thread chosse selected files and delete rest

...or, for your pattern match match based solution, why not utilize the fact that unlink takes a list viz (also untested:-):
unlink grep { -f $_ && ! /$pattern/ } glob "$Directory/*";

A user level that continues to overstate my experience :-))