annotate sed.xml @ 0:8ae62a63e93d draft default tip

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
author bgruening
date Wed, 09 Nov 2016 14:50:45 -0500
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
1 <tool id="sed_stream_editor" name="Manipulation" version="0.0.1">
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
2 <description>utility that parses and transforms text using regular expressions (sed)</description>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
3 <command>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
4 <![CDATA[
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
5 sed -r '$pattern'
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
6 $input > $outfile
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
7 ]]>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
8 </command>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
9 <inputs>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
10 <param format="txt, tabular" name="input" type="data" label="Replace lines from"/>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
11 <param name="pattern" type="text" value="" label="the pattern" help="here you can enter your sed expression (No syntax check or sanitising!)" />
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
12 </inputs>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
13 <outputs>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
14 <data format="input" name="outfile" metadata_source="input"/>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
15 </outputs>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
16 <options sanitize="False"/>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
17 <requirements>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
18 <requirement type="binary">sed</requirement>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
19 </requirements>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
20 <tests>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
21
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
22 </tests>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
23 <help>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
24 <![CDATA[
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
25
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
26 .. class:: warningmark
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
27
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
28 Use with caution! Its a plain wrapper around **sed** and the input is not sanitized.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
29
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
30
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
31 -----
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
32
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
33 **What it does**
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
34
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
35 Changes every line of a text file according to a given regular expression.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
36
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
37 -----
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
38
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
39 **Syntax**
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
40
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
41 Use the **sed**-syntax -> **s/find-pattern/replace-pattern/**
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
42
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
43 **Example**
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
44
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
45 - **s/x/-/** Replace all **x** with **-**.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
46
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
47 - **s/_.*//** Splits a string after **_** and replaces the rest with nothing.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
48 - **s/[^_]*_*//** Splits a string after **_** and replaces the first part with nothing.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
49
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
50 - **s/\\s.*//** Splits a string after whitespaces and replaces the rest with nothing.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
51 - **s/\\S*\\s*//** Splits a string after whitespaces and replaces the first part with nothing.
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
52
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
53
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
54 ]]>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
55 </help>
8ae62a63e93d planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sed commit cfb00484086246d51865572f004e3140b8bf4852
bgruening
parents:
diff changeset
56 </tool>