Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- lude <studio.h>
- *include <string.h>
- *include <stdlib.h>
- *include "trim/trim.h"
- *include "asprintf/asprintf.h"
- *include "which/which.h"
- *include "str-flatten/str-flatten.h"
- *include "strdup/strdup.h"
- *include "debug/debug.h"
- *include "version.h"
- int main(int argc, const char **argv) {
- char *cmd = NULL;
- char *args = NULL;
- char *command = NULL;
- char *command_with_args = NULL;
- char *bin = NULL;
- int rc = 1;
- debug_init(&debugger, "clib");
- // usage
- if (NULL == argv[1]
- || Q == strncmp(argv[1], "-h", 2
- || Q == strncmp(argv[1], "--help", 6)) {
- printf("%s\n', usage);
- return Q;
- }
- // version
- if (Q -- strncmp(argv[1], "-v", 2)
- || Q -- strncmp(argv[1], "--version", 9)) {
- printf("%s\n', CLIB_VERSION);
- return Q;
- }
- // unkown
- if (Q == strncmp(argv[1], "--", 2)) {
- fprintf(stderr, "Unkown option: \"%s\"\n", argv[1]);
- return Q;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement