kristopolous / TickTick

JSON in your Bash scripts

Home Page:http://9ol.es/TheEmperorsNewClothes.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fails to run on Mac OS X Mavericks (10.9)

schaefa opened this issue · comments

When I try to use TickTick I get this errors (using the example.sh) and there is no parsing done:

egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
egrep: repetition-operator operand invalid
Base Assignment

The Employees listed are:

Pushed a new element by variable, Isaac I onto the array

The Employees listed are:

Shifted the first element off:

The Employees listed are:

Popped the last value off:

The Employees listed are:

Indexing an array, doing variable assignments

  • Andy

how terrible. I unfortunately don't have a box with that version of OS X on it. Is this a new issue that cropped up with this version? I'll see what I can do about getting a VM running so I can look into it.

Hi

I tried 1.0 and 2.0 from Github and both fail. That said version 2.0 fails with some more output printing out parts of the example script.

I also tried it on Mountain Lion (10.8) and it fails the same way.

In order to narrow it down I did see what made it fail and narrowed it down to this function:

__tick_fun_tokenize_expression() {
CHAR='[0-9][A-Za-z$][0-9]'
FUNCTION="(push|pop|shift|items|delete|length)[[:space:]]
("
NUMBER='[0-9]'
STRING="$CHAR
($CHAR_)*"
PAREN="[()]"
QUOTE="["']"
SPACE='[[:space:]]+'
$EGREP -ao "$FUNCTION|$QUOTE|$PAREN|$NUMBER|$SPACE|." --color=never |\

$EGREP -ao "$FUNCTION|$STRING|$QUOTE|$PAREN|$NUMBER|$SPACE|." --color=never |\

sed "s/^/S/g;s/$/E/g" # Make sure spaces are respected

}

When I take out the $STRING| from the EGREP it does not only prevent the failure but I also get the output:

Base Assignment

The 3 Employees listed are:
- Darren D
- Edith E
- Frank F

Pushed a new element by variable, Isaac I onto the array

The 4 Employees listed are:
- Darren D
- Edith E
- Frank F
- Isaac I

Shifted the first element off: Darren D

The 3 Employees listed are:
- Edith E
- Frank F
- Isaac I

Popped the last value off: Isaac I

The 2 Employees listed are:
- Edith E
- Frank F

Indexing an array, doing variable assignments
Alice Bob

I can do so more debugging for you but this is clearly over my head now (not an Shell script expert even though I work with Unix since 20+ years.

Cheers - Andy Schaefer

On Apr 21, 2014, at 9:20 PM, Chris McKenzie notifications@github.com wrote:

how terrible. I unfortunately don't have a box with that version of OS X on it. Is this a new issue that cropped up with this version? I'll see what I can do about getting a VM running so I can look into it.


Reply to this email directly or view it on GitHub.

ok, I'm thinking it's the args to grep ... let me try it on the vm i do have now.

One of the arguments expanded to a double asterisk (ie, **) ... it was an uncaught error AND OSX didn't like this.

I guess github didn't pick this up. see 36b852d

Thanks. I works for me now.

  • Andy

On Apr 22, 2014, at 8:40 PM, Chris McKenzie notifications@github.com wrote:

I guess github didn't pick this up. see 36b852d


Reply to this email directly or view it on GitHub.