-
Notifications
You must be signed in to change notification settings - Fork 189
/
Copy pathfilepad_tasks.html
204 lines (191 loc) · 8.78 KB
/
filepad_tasks.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
<!DOCTYPE html>
<html lang="en" data-content_root="./">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Using the built-in FilePad Tasks — FireWorks 2.0.4 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=03e43079" />
<link rel="stylesheet" type="text/css" href="_static/nature.css?v=b0beeceb" />
<script src="_static/documentation_options.js?v=adc66a14"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Using the dataflow Firetasks" href="dataflow_tasks.html" />
<link rel="prev" title="Using the PyTask" href="pytask.html" />
<link href='https://fonts.googleapis.com/css?family=Lato:400,700' rel='stylesheet' type='text/css'>
</head><body>
<div class="related" role="navigation" aria-label="Related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="dataflow_tasks.html" title="Using the dataflow Firetasks"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="pytask.html" title="Using the PyTask"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">FireWorks 2.0.4 documentation</a> »</li>
<li class="nav-item nav-item-this"><a href="">Using the built-in FilePad Tasks</a></li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<section id="using-the-built-in-filepad-tasks">
<h1>Using the built-in FilePad Tasks<a class="headerlink" href="#using-the-built-in-filepad-tasks" title="Link to this heading">¶</a></h1>
<p>FireWorks comes with several built-in tasks for performing file I/O (writing, moving, and deleting files).</p>
<section id="addfilestask">
<h2>AddFilesTask<a class="headerlink" href="#addfilestask" title="Link to this heading">¶</a></h2>
<p>The <em>AddFilesTask</em> enables one to insert one or more files into MongoDb/GridFS using FilePad(see the documentation for FilePad <a class="reference internal" href="filepad_tutorial.html"><span class="doc">FilePad tutorial</span></a>.)</p>
<section id="required-parameters">
<h3>Required parameters<a class="headerlink" href="#required-parameters" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>paths ([str]): list of paths to files to be added</p></li>
</ul>
</section>
<section id="optional-parameters">
<h3>Optional parameters<a class="headerlink" href="#optional-parameters" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>identifiers ([str]): list of identifiers, one for each file in the paths list.</p></li>
<li><p>filepad_file (str): path to the filepad db config file</p></li>
<li><p>compress (bool): whether or not to compress the file before inserting to gridfs</p></li>
<li><p>metadata (dict): metadata to store along with the file, stored in ‘metadata’ key</p></li>
</ul>
</section>
</section>
<section id="getfilestask">
<h2>GetFilesTask<a class="headerlink" href="#getfilestask" title="Link to this heading">¶</a></h2>
<p>The <em>GetFilesTask</em> enables one to fetch one or more files into MongoDb/GridFS using FilePad and write
them to the given destination directory.</p>
<section id="id1">
<h3>Required parameters<a class="headerlink" href="#id1" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>identifiers ([str]): list of identifiers, one for each file in the paths list.</p></li>
</ul>
</section>
<section id="id2">
<h3>Optional parameters<a class="headerlink" href="#id2" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>filepad_file (str): path to the filepad db config file.</p></li>
<li><p>dest_dir (str): destination directory, default is the current working directory.</p></li>
<li><p>new_file_names ([str]): if provided, the retrieved files will be renamed.</p></li>
</ul>
</section>
</section>
<section id="deletefilestask">
<h2>DeleteFilesTask<a class="headerlink" href="#deletefilestask" title="Link to this heading">¶</a></h2>
<p>The <em>DeleteFilesTask</em> lets you delete one or more files from the filepad.</p>
<section id="id3">
<h3>Required parameters<a class="headerlink" href="#id3" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>identifiers: ([str]) file identifiers to delete</p></li>
</ul>
</section>
<section id="id4">
<h3>Optional parameters<a class="headerlink" href="#id4" title="Link to this heading">¶</a></h3>
<ul class="simple">
<li><p>filepad_file (str): path to the filepad db config file</p></li>
</ul>
</section>
</section>
</section>
<div class="clearer"></div>
</div>
</div>
</div>
<div class="sphinxsidebar" role="navigation" aria-label="Main">
<div class="sphinxsidebarwrapper">
<div>
<h3><a href="index.html">Table of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">Using the built-in FilePad Tasks</a><ul>
<li><a class="reference internal" href="#addfilestask">AddFilesTask</a><ul>
<li><a class="reference internal" href="#required-parameters">Required parameters</a></li>
<li><a class="reference internal" href="#optional-parameters">Optional parameters</a></li>
</ul>
</li>
<li><a class="reference internal" href="#getfilestask">GetFilesTask</a><ul>
<li><a class="reference internal" href="#id1">Required parameters</a></li>
<li><a class="reference internal" href="#id2">Optional parameters</a></li>
</ul>
</li>
<li><a class="reference internal" href="#deletefilestask">DeleteFilesTask</a><ul>
<li><a class="reference internal" href="#id3">Required parameters</a></li>
<li><a class="reference internal" href="#id4">Optional parameters</a></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div>
<h4>Previous topic</h4>
<p class="topless"><a href="pytask.html"
title="previous chapter">Using the PyTask</a></p>
</div>
<div>
<h4>Next topic</h4>
<p class="topless"><a href="dataflow_tasks.html"
title="next chapter">Using the dataflow Firetasks</a></p>
</div>
<div role="note" aria-label="source link">
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="_sources/filepad_tasks.rst.txt"
rel="nofollow">Show Source</a></li>
</ul>
</div>
<search id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
<input type="submit" value="Go" />
</form>
</div>
</search>
<script>document.getElementById('searchbox').style.display = "block"</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related" role="navigation" aria-label="Related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="genindex.html" title="General Index"
>index</a></li>
<li class="right" >
<a href="py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="dataflow_tasks.html" title="Using the dataflow Firetasks"
>next</a> |</li>
<li class="right" >
<a href="pytask.html" title="Using the PyTask"
>previous</a> |</li>
<li class="nav-item nav-item-0"><a href="index.html">FireWorks 2.0.4 documentation</a> »</li>
<li class="nav-item nav-item-this"><a href="">Using the built-in FilePad Tasks</a></li>
</ul>
</div>
<div class="footer" role="contentinfo">
© Copyright 2013, Anubhav Jain.
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 8.1.3.
</div>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-53488807-1', 'auto');
ga('send', 'pageview');
</script>
</body>
</html>