You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.rst
+45-70Lines changed: 45 additions & 70 deletions
Original file line number
Diff line number
Diff line change
@@ -1,28 +1,3 @@
1
-
# Template for pytask plugins
2
-
3
-
This template has been generated by comparing the R and Stata plugins. It is thus based on the assumption that anything which is common between those two plugins is likely to be the same in the new plugin as well.
4
-
5
-
Usage:
6
-
- Download the source code
7
-
- Rename the folder `src/pytask_xxxxx` to `src/pytask_[your plugin's identifier]`
- **S**: ZZZZZ, **R**: [The command to start your program, e.g. RScript] *(if not common across platforms or more complicated, see the Stata plugin for more involved handling)*
- **S**: xxxxx, **R** on a case-by-case basis. This will often be your plugin's identifier, but can also be the extension of scripts in your language (e.g., `r`, `do`, `jl`) or other things.
16
-
17
-
- Try out
18
-
- Likely the first necessary adjustments will be to the code in collect.py
19
-
- For sure, later adjustments will be necessary for
20
-
- the code snippets in the tests and README.rst
21
-
- the author name and e-mail in `setup.cfg`
22
-
- Please let us know any things you think are worth noting!
23
-
24
-
------
25
-
26
1
pytask-julia
27
2
============
28
3
@@ -71,106 +46,106 @@ pytask-julia is available on `PyPI <https://pypi.org/project/pytask-julia>`_ and
71
46
72
47
$ conda install -c conda-forge pytask-julia
73
48
74
-
You also need to have YYYYY installed and ``ZZZZZ`` on your command line. Test it by
49
+
You also need to have Julia installed and ``julia`` on your command line. Test it by
75
50
typing the following on the command line
76
51
77
52
.. code-block:: console
78
53
79
-
$ ZZZZZ --help
54
+
$ julia -h
80
55
81
-
If an error is shown instead of a help page, you can install YYYYY ....
56
+
If an error is shown instead of a help page, you can install Julia ....
82
57
83
58
84
59
Usage
85
60
-----
86
61
87
62
Similarly to normal task functions which execute Python code, you define tasks to
88
-
execute scripts written in YYYYY with Python functions. The difference is that the
63
+
execute scripts written in Julia with Python functions. The difference is that the
89
64
function body does not contain any logic, but the decorator tells pytask how to handle
90
65
the task.
91
66
92
-
Here is an example where you want to run ``script.xxxxx``.
67
+
Here is an example where you want to run ``script.julia``.
93
68
94
69
.. code-block:: python
95
70
96
71
import pytask
97
72
98
73
99
-
@pytask.mark.xxxxx
100
-
@pytask.mark.depends_on("script.xxxxxx")
74
+
@pytask.mark.julia
75
+
@pytask.mark.depends_on("script.jl")
101
76
@pytask.mark.produces("out.csv")
102
-
deftask_run_xxxxx_script():
77
+
deftask_run_jl_script():
103
78
pass
104
79
105
-
Note that, you need to apply the ``@pytask.mark.xxxxx`` marker so that pytask-xxxxx handles the
80
+
Note that, you need to apply the ``@pytask.mark.julia`` marker so that pytask-julia handles the
106
81
task.
107
82
108
-
If you are wondering why the function body is empty, know that pytask-xxxxx replaces the
83
+
If you are wondering why the function body is empty, know that pytask-julia replaces the
109
84
body with a predefined internal function. See the section on implementation details for
110
85
more information.
111
86
112
87
113
88
Multiple dependencies and products
114
89
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
115
90
116
-
What happens if a task has more dependencies? Using a list, the YYYYY script which should be
91
+
What happens if a task has more dependencies? Using a list, the Julia script which should be
117
92
executed must be found in the first position of the list.
0 commit comments