reBourne
reBourne

Reputation: 127

Save output into variable

i have tried for like 30 minutes. Whats wrong with this code ? :( Input :

var = `cat marktplatz.html | grep -m 1 "post" | grep -o -E '\b(jobs/.*htm)' `

Output :

var: command not found

Upvotes: 4

Views: 1702

Answers (1)

Fred Foo
Fred Foo

Reputation: 363487

var = BLABLA

should be

var=BLABLA

The first form is interpreted as running the command var with = as the first argument.

Upvotes: 5

Related Questions