diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-14 19:12:45 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-14 19:12:45 +0200 |
commit | e10944f8c9b774ad4e8c618bea7962d31756b4ad (patch) | |
tree | 618bdd3cdaf2f1843db914f0b4bc21486bd024b5 /src/options.def.h | |
parent | 5ebebb3688a0e88fadc6a10219572cbcf3a8603a (diff) | |
download | fastd-e10944f8c9b774ad4e8c618bea7962d31756b4ad.tar fastd-e10944f8c9b774ad4e8c618bea7962d31756b4ad.zip |
Allow disabling redundant command line options
Diffstat (limited to 'src/options.def.h')
-rw-r--r-- | src/options.def.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/options.def.h b/src/options.def.h index 73ce1c5..159a328 100644 --- a/src/options.def.h +++ b/src/options.def.h @@ -3,19 +3,28 @@ OPTION(version, "--version" OR "-v", "Shows the fastd version"); OPTION(option_daemon, "--daemon" OR "-d", "Runs fastd in the background"); OPTION_ARG(option_pid_file, "--pid-file", "<filename>", "Writes fastd's PID to the specified file"); SEPARATOR; + OPTION_ARG(option_config, "--config" OR "-c", "<filename>", "Loads a config file"); OPTION_ARG(option_config_peer, "--config-peer", "<filename>", "Loads a config file for a single peer"); OPTION_ARG(option_config_peer_dir, "--config-peer-dir", "<dir>", "Loads all files from a directory as peer configs"); SEPARATOR; + +#ifdef WITH_CMDLINE_USER OPTION_ARG(option_user, "--user", "<user>", "Sets the user to run fastd as"); OPTION_ARG(option_group, "--group", "<group>", "Sets the group to run fastd as"); SEPARATOR; +#endif + +#ifdef WITH_CMDLINE_LOGGING OPTION_ARG(option_log_level, "--log-level", "error|warn|info|verbose|debug", "Sets the stderr log level; default is info, if no alternative log destination is configured"); OPTION_ARG(option_syslog_level, "--syslog-level", "error|warn|info|verbose|debug", "Sets the log level for syslog output; default is not to use syslog"); OPTION_ARG(option_syslog_ident, "--syslog-ident", "<ident>", "Sets the syslog identification; default is 'fastd'"); OPTION(option_hide_ip_addresses, "--hide-ip-addresses", "Hides IP addresses in log output"); OPTION(option_hide_mac_addresses, "--hide-mac-addresses", "Hides MAC addresses in log output"); SEPARATOR; +#endif + +#ifdef WITH_CMDLINE_OPERATION OPTION_ARG(option_mode, "--mode" OR "-m", "tap|tun", "Sets the mode of the interface"); OPTION_ARG(option_interface, "--interface" OR "-i", "<name>", "Sets the name of the TUN/TAP interface to use"); OPTION_ARG(option_mtu, "--mtu" OR "-M", "<mtu>", "Sets the MTU; must be at least 576"); @@ -24,6 +33,9 @@ OPTION_ARG(option_protocol, "--protocol" OR "-p", "<protocol>", "Sets the protoc OPTION_ARG(option_method, "--method", "<method>", "Sets the encryption method"); OPTION(option_forward, "--forward", "Enables forwarding of packets between peers; read the documentation before use!"); SEPARATOR; +#endif + +#ifdef WITH_CMDLINE_COMMANDS OPTION_ARG(option_on_pre_up, "--on-pre-up", "<command>", "Sets a shell command to execute before interface creation"); OPTION_ARG(option_on_up, "--on-up", "<command>", "Sets a shell command to execute after interface creation"); OPTION_ARG(option_on_down, "--on-down", "<command>", "Sets a shell command to execute before interface destruction"); @@ -32,6 +44,8 @@ OPTION_ARG(option_on_establish, "--on-establish", "<command>", "Sets a shell com OPTION_ARG(option_on_disestablish, "--on-disestablish", "<command>", "Sets a shell command to execute when a connection is lost"); OPTION_ARG(option_on_verify, "--on-verify", "<command>", "Sets a shell command to execute to check a connection attempt by an unknown peer"); SEPARATOR; +#endif + OPTION(option_generate_key, "--generate-key", "Generates a new keypair"); OPTION(option_show_key, "--show-key", "Shows the public key corresponding to the configured secret"); OPTION(option_machine_readable, "--machine-readable", "Suppresses output of explaining text in the --show-key and --generate-key commands"); |