detox  1.4.5
About: Detox is a utility designed to clean up filenames, especially those created on other operating systems.
  Fossies Dox: detox-1.4.5.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

parse_options.c File Reference
#include "config.h"
#include <sys/stat.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <errno.h>
#include <libgen.h>
#include "detox.h"
#include "parse_options.h"
Include dependency graph for parse_options.c:

Go to the source code of this file.

Macros

#define INLINE_DETOX_BIN   "inline-detox"
 

Enumerations

enum  { LONG_OPTION_DRY_RUN = 1 , LONG_OPTION_INLINE , LONG_OPTION_REMOVE_TRAILING , LONG_OPTION_SPECIAL }
 

Functions

struct detox_optionsinitialize_main_options (void)
 
struct detox_optionsparse_options_getopt (int argc, char **argv)
 

Variables

static int long_option = 0
 
char usage_message []
 
char help_message []
 
char usage_message_inline []
 
char help_message_inline []
 

Macro Definition Documentation

◆ INLINE_DETOX_BIN

#define INLINE_DETOX_BIN   "inline-detox"

Definition at line 35 of file parse_options.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

This file is part of the Detox package.

Copyright (c) Doug Harple detox.nosp@m..dha.nosp@m.rple@.nosp@m.gmai.nosp@m.l.com

For the full copyright and license information, please view the LICENSE file that was distributed with this source code.

Enumerator
LONG_OPTION_DRY_RUN 
LONG_OPTION_INLINE 
LONG_OPTION_REMOVE_TRAILING 
LONG_OPTION_SPECIAL 

Definition at line 28 of file parse_options.c.

Function Documentation

◆ initialize_main_options()

struct detox_options* initialize_main_options ( void  )

Definition at line 125 of file parse_options.c.

References malloc(), and detox_options::sequence_name.

Referenced by parse_options_getopt().

◆ parse_options_getopt()

Variable Documentation

◆ help_message

char help_message[]
Initial value:
= {
" -f configfile choose which config file to use\n"
" -h this message\n"
" -L list available sequences and exit\n"
" with -v ... dump sequence contents\n"
" -n do a dry run (don't actually do anything)\n"
" -r be recursive (descend into subdirectories)\n"
" -s sequence choose which sequence to detox with\n"
" -v be verbose\n"
" -V show the current version\n"
}

Definition at line 71 of file parse_options.c.

Referenced by parse_options_getopt().

◆ help_message_inline

char help_message_inline[]
Initial value:
= {
" -f configfile choose which config file to use\n"
" -h this message\n"
" -L list available sequences and exit\n"
" with -v ... dump sequence contents\n"
" -s sequence choose which sequence to detox with\n"
" -v be verbose\n"
" -V show the current version\n"
}

Definition at line 105 of file parse_options.c.

Referenced by parse_options_getopt().

◆ long_option

int long_option = 0
static

Definition at line 38 of file parse_options.c.

Referenced by parse_options_getopt().

◆ usage_message

char usage_message[]
Initial value:
= {
"usage: detox [-hLnrvV] [-f configfile] [-s sequence]"
" file [file ...]\n"
}

This file is part of the Detox package.

Copyright (c) Doug Harple detox.nosp@m..dha.nosp@m.rple@.nosp@m.gmai.nosp@m.l.com

For the full copyright and license information, please view the LICENSE file that was distributed with this source code.

Definition at line 62 of file parse_options.c.

Referenced by parse_options_getopt().

◆ usage_message_inline

char usage_message_inline[]
Initial value:
= {
"usage: inline-detox [-hLvV] [-f configfile] [-s sequence] [file]\n"
}

Definition at line 101 of file parse_options.c.

Referenced by parse_options_getopt().