Jump to content

Dealing with greater-than (>) in bash script output

Recommended Posts

I use Toodledo for my task management, largely because of its ability to parse nearly all task attributes via text-based macros in the subject line of a task emailed in, like so:

Task title *folder * !! >startdate #enddate @context %tags

(The sitting-alone * is to star the task; the exclamation points are to set importance.)


I'm trying to use a bash script in a workflow so that I can open a mailto: link with the address and subject coded with the query I paste in (this format: mailto:addressee@domain.com?subject=word%20word).


It's working great, except that it seems as though the script chokes in some way on the ">" in front of the startdate.


In other words, a query of 

Task title *folder * !! >startdate #enddate @context %tags

results in an email addressed to the proper sender, but with the subject reading only "Task title *folder * !! ", and leaving off the rest.


If I remove the ">", everything works fine.


Is there a way to in some way escape the ">" when executing the script?






A backslash will escape it, but I had backslashes being escaped in the script component of the workflow. Turned that off, added the backslash, and it's good to go.

Edited by someguy
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...