ruby options

Option Description
-a Used with -n or -p to split each line. Check -n and -p options.
-c Checks syntax only, without executing program.
-C dir Changes directory before executing (equivalent to -X).
-d Enables debug mode (equivalent to -debug).
-F pat Specifies pat as the default separator pattern ($;) used by split.
-e prog Specifies prog as the program from the command line. Specify multiple -e options for multiline programs.
-h Displays an overview of command-line options.
-i [ ext] Overwrites the file contents with program output. The original file is saved with the extension ext. If ext isn't specified, the original file is deleted.
-I dir Adds dir as the directory for loading libraries.
-K [ kcode] Specifies the multibyte character set code (e or E for EUC (extended Unix code); s or S for SJIS (Shift-JIS); u or U for UTF-8; and a, A, n, or N for ASCII).
-l Enables automatic line-end processing. Chops a newline from input lines and appends a newline to output lines.
-n Places code within an input loop (as in while gets; ... end).
-0[ octal] Sets default record separator ($/) as an octal. Defaults to \0 if octal not specified.
-p Places code within an input loop. Writes $_ for each iteration.
-r lib Uses require to load lib as a library before executing.
-s Interprets any arguments between the program name and filename arguments fitting the pattern -xxx as a switch and defines the corresponding variable.
-T [level] Sets the level for tainting checks (1 if level not specified).
-v Displays version and enables verbose mode
-w Enables verbose mode. If programfile not specified, reads from STDIN.
-x [dir] Strips text before #!ruby line. Changes directory to dir before executing if dir is specified.
-X dir Changes directory before executing (equivalent to -C).
-y Enables parser debug mode.
--copyright Displays copyright notice.
--debug Enables debug mode (equivalent to -d).
--help Displays an overview of command-line options (equivalent to -h).
--version Displays version.
--verbose Enables verbose mode (equivalent to -v). Sets $VERBOSE to true
--yydebug Enables parser debug mode (equivalent to -y).

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值