dpkg 1.22.7-3-g89f48
Loading...
Searching...
No Matches
Data Structures | Functions
command.h File Reference

(8389e7010)

#include <dpkg/macros.h>
#include <stdarg.h>
#include <stdbool.h>
Include dependency graph for command.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  command
 Describe a command to execute. More...
 

Functions

void command_init (struct command *cmd, const char *filename, const char *name)
 Initialize a command structure.
 
void command_destroy (struct command *cmd)
 Destroy a command structure.
 
void command_add_arg (struct command *cmd, const char *arg)
 Append an argument to the command's argv.
 
void command_add_argl (struct command *cmd, const char **argv)
 Append an argument array to the command's argv.
 
void command_add_argv (struct command *cmd, va_list args)
 Append a va_list of argument to the command's argv.
 
void command_add_args (struct command *cmd,...) DPKG_ATTR_SENTINEL
 Append a variable list of argument to the command's argv.
 
void command_exec (struct command *cmd) DPKG_ATTR_NORET
 Execute the command specified.
 
void command_shell (const char *cmd, const char *name) DPKG_ATTR_NORET
 Execute a shell with a possible command.
 
bool command_in_path (const char *cmd)
 Check whether a command can be found in PATH.