Sorry, i typo'd

ifconfig | perl6 -e 'lines.grep(/flags/).map(*.words[0]).sort[1].chop'


On 08/05/2017 05:41 AM, ToddAndMargo wrote:
> On 08/04/2017 08:14 PM, Timo Paulssen wrote:
>> ifconfig | perl6 -e 'lines.grep("flags").map(*.words[0]).sort[1].chop'
>>
>> this should do the trick. i'm not sure if 2,2p is meant to "output just
>> the second result" and if it's okay to just unconditionally remove the
>> last character.
>>
>> hth
>>    - Timo
>>
>
>
> 2,2p means to print only the second line
>
> $ ifconfig | /usr/bin/perl6 -e
> 'lines.grep("flags").map(*.words[0]).sort[1].chop'
>
> Use of Nil in string context
>   in block <unit> at -e line 1
>
> :'(
>
>
>

Reply via email to