cctools
batch_wrapper.h
Go to the documentation of this file.
1/*
2Copyright (C) 2024 The University of Notre Dame
3This software is distributed under the GNU General Public License.
4See the file COPYING for details.
5*/
6
7#ifndef BATCH_WRAPPER_H
8#define BATCH_WRAPPER_H
9
10#include "batch_job.h"
11
34struct batch_wrapper *batch_wrapper_create(void);
35
41void batch_wrapper_delete(struct batch_wrapper *w);
42
50void batch_wrapper_pre(struct batch_wrapper *w, const char *cmd);
51
59void batch_wrapper_argv(struct batch_wrapper *w, char *const argv[]);
60
67void batch_wrapper_args(struct batch_wrapper *w, char *const args[]);
68
74void batch_wrapper_cmd(struct batch_wrapper *w, const char *cmd);
75
76
84void batch_wrapper_post(struct batch_wrapper *w, const char *cmd);
85
93void batch_wrapper_prefix(struct batch_wrapper *w, const char *prefix);
94
102char *batch_wrapper_write(struct batch_wrapper *w, struct batch_job *t);
103
112char *batch_wrapper_expand(struct batch_job *t, struct jx *spec);
113
114#endif
115/* vim: set noexpandtab tabstop=8: */
Represents a single batch job.
void batch_wrapper_argv(struct batch_wrapper *w, char *const argv[])
Specify a command line to execute in the wrapper.
void batch_wrapper_pre(struct batch_wrapper *w, const char *cmd)
Add a shell command to the batch wrapper.
char * batch_wrapper_expand(struct batch_job *t, struct jx *spec)
Generate one or more wrapper scripts from a JX command spec.
struct batch_wrapper * batch_wrapper_create(void)
Create a builder for a batch wrapper.
void batch_wrapper_post(struct batch_wrapper *w, const char *cmd)
Specify cleanup commands.
void batch_wrapper_delete(struct batch_wrapper *w)
Free a batch_wrapper.
void batch_wrapper_args(struct batch_wrapper *w, char *const args[])
Specify a command line to execute with shell interpretation.
void batch_wrapper_cmd(struct batch_wrapper *w, const char *cmd)
Specify a shell command to execute.
char * batch_wrapper_write(struct batch_wrapper *w, struct batch_job *t)
Write out the batch_wrapper as a shell script.
void batch_wrapper_prefix(struct batch_wrapper *w, const char *prefix)
Set the name prefix to use for the wrapper script.
Internal description of a single batch job submitted to a queue.
Definition batch_job.h:27
JX value representing any expression type.
Definition jx.h:117