Forum: CFEngine Help Subject: Re: How to remove a string from an slist based off of a class. Author: msvob...@linkedin.com Link to topic: https://cfengine.com/forum/read.php?3,23646,24104#msg-24104
+1 The negative lookahead using grep is counter intuitive. I think we need three new functions. 1. Remove a string from a slist 2. Remove a slist from a slist 3. Remove an element from an array. Right now, to deal with arrays and slists, I have to use classes to "append." I suppose that approach works, but, we should also be able to remove using a function. Slists and arrays are the basic data structures in Cfengine, and their use / manipulation should be straightforward. I've submitted a feature request for this here: https://cfengine.com/bugtracker/view.php?id=877 Thanks Mike On 11/29/11 11:37 AM, "Ted Zlatanov" wrote: On Mon, 31 Oct 2011 10:09:37 -0500 Ted Zlatanov wrote: TZ> On Fri, 30 Sep 2011 19:00:28 +0200 (CEST) neilhwatson wrote: n> No, use a negative regular expression. Match things that are not 'Two'. TZ> There are regular expressions that can't be practically inverted, and TZ> even simple ones look awkward. Could grep() support a "-v" flag? Any news on this? Is it of interest to anyone else? Ted _______________________________________________ _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine