[TxMt] Help with simple command

Oliver Taylor ollieman at gmail.com
Wed May 10 03:25:00 UTC 2006


> This should do what you need:
>
> npp=38
> res=$(echo `wc -l`)
> pretty () { rev <<<$1|perl -pe 's/(\d{3})(?=.)/$1,/g'|rev; }
> total=$(pretty $(cut <<<$res -d\  -f1))
> php -r "echo ceil($TM_LINE_NUMBER/$npp).'/'.ceil($total/$npp);"

I get the following error:

> Warning: Wrong parameter count for ceil() in Command line code on line 1 58/


More information about the textmate mailing list