Hi Ross,

     Thank you very much for guiding me to use sanitize tag. I searched the 
forum and found this post extremely helpful 
http://gmod.827538.n3.nabble.com/preserving-newlines-in-input-parameters-td4022647.html.
 The problem got solved at least for now. One more question: is there anything 
like predefined set for all special characters, something like string.letters, 
string.digits ? Otherwise I have to define each of them in the add and remove 
list.

Best regards!
Jun

From: Ross [mailto:ross.laza...@gmail.com]
Sent: 26 October 2013 03:07
To: Jun Fan
Cc: galaxy-dev@lists.bx.psu.edu
Subject: Re: [galaxy-dev] pass regular expression

Hi, Jun.
The inbuilt parameter sanitizer can be controlled - see 
http://wiki.galaxyproject.org/Admin/Tools/ToolConfigSyntax#A.3Csanitizer.3E_tag_set
The <valid> sub-tag allows precise control and you can specify eg 
string.printable if you want ANY printable character in your parameter

Here's an example from the Tool Factory:

 <param name="tool_name" type="text" value="My dynamic script"   label="New 
tool ID and title for outputs" size="60"
         help="This will become the toolshed repository name so please choose 
thoughtfully to avoid namespace clashes with$
        <sanitizer invalid_char="">
            <valid initial="string.letters,string.digits"/>
        </sanitizer>
    </param>

I hope this helps?
On Sat, Oct 26, 2013 at 11:43 AM, Jun Fan 
<j....@qmul.ac.uk<mailto:j....@qmul.ac.uk>> wrote:
Hi all,

     I am trying to develop a tool which allows the user to use regular 
expression to only keep the lines matching the given pattern in the output. 
There are many special characters, e.g. \ in \d. In the perl script the wrapper 
invokes, the regular expression is printed as Xd+ for the regular expression 
\d+. My question is how to pass these special characters including \, (, ), ^ 
etc. correctly into the perl script.

Best regards!
Jun

___________________________________________________________
Please keep all replies on the list by using "reply all"
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:
  http://lists.bx.psu.edu/

To search Galaxy mailing lists use the unified search at:
  http://galaxyproject.org/search/mailinglists/

___________________________________________________________
Please keep all replies on the list by using "reply all"
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:
  http://lists.bx.psu.edu/

To search Galaxy mailing lists use the unified search at:
  http://galaxyproject.org/search/mailinglists/

Reply via email to