summaryrefslogtreecommitdiff
path: root/lib/irb/lc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/irb/lc')
-rw-r--r--lib/irb/lc/error.rb29
-rw-r--r--lib/irb/lc/help-message100
-rw-r--r--lib/irb/lc/ja/encoding_aliases.rb11
-rw-r--r--lib/irb/lc/ja/error.rb31
-rw-r--r--lib/irb/lc/ja/help-message25
5 files changed, 71 insertions, 125 deletions
diff --git a/lib/irb/lc/error.rb b/lib/irb/lc/error.rb
index 798994e92c..ee0f047822 100644
--- a/lib/irb/lc/error.rb
+++ b/lib/irb/lc/error.rb
@@ -1,27 +1,17 @@
-# frozen_string_literal: false
+# frozen_string_literal: true
#
# irb/lc/error.rb -
-# $Release Version: 0.9.6$
-# $Revision$
# by Keiju ISHITSUKA(keiju@ruby-lang.org)
#
-# --
-#
-#
-#
-# :stopdoc:
module IRB
+ # :stopdoc:
+
class UnrecognizedSwitch < StandardError
def initialize(val)
super("Unrecognized switch: #{val}")
end
end
- class NotImplementedError < StandardError
- def initialize(val)
- super("Need to define `#{val}'")
- end
- end
class CantReturnToNormalMode < StandardError
def initialize
super("Can't return to normal mode.")
@@ -47,11 +37,6 @@ module IRB
super("No such job(#{val}).")
end
end
- class CantShiftToMultiIrbMode < StandardError
- def initialize
- super("Can't shift to multi irb mode.")
- end
- end
class CantChangeBinding < StandardError
def initialize(val)
super("Can't change binding to (#{val}).")
@@ -62,10 +47,6 @@ module IRB
super("Undefined prompt mode(#{val}).")
end
end
- class IllegalRCGenerator < StandardError
- def initialize
- super("Define illegal RC_NAME_GENERATOR.")
- end
- end
+
+ # :startdoc:
end
-# :startdoc:
diff --git a/lib/irb/lc/help-message b/lib/irb/lc/help-message
index 939dc38975..37347306e8 100644
--- a/lib/irb/lc/help-message
+++ b/lib/irb/lc/help-message
@@ -1,61 +1,55 @@
-# -*- coding: utf-8 -*-
-#
-# irb/lc/help-message.rb -
-# $Release Version: 0.9.6$
-# $Revision$
-# by Keiju ISHITSUKA(keiju@ruby-lang.org)
-#
-# --
-#
-#
-#
Usage: irb.rb [options] [programfile] [arguments]
- -f Suppress read of ~/.irbrc
- -d Set $DEBUG to true (same as `ruby -d')
- -r load-module Same as `ruby -r'
- -I path Specify $LOAD_PATH directory
- -U Same as `ruby -U`
- -E enc Same as `ruby -E`
- -w Same as `ruby -w`
- -W[level=2] Same as `ruby -W`
+ -f Don't initialize from configuration file.
+ -d Set $DEBUG and $VERBOSE to true (same as 'ruby -d').
+ -r load-module Require load-module (same as 'ruby -r').
+ -I path Specify $LOAD_PATH directory (same as 'ruby -I').
+ -U Set external and internal encodings to UTF-8.
+ -E ex[:in] Set default external (ex) and internal (in) encodings
+ (same as 'ruby -E').
+ -w Suppress warnings (same as 'ruby -w').
+ -W[level=2] Set warning level: 0=silence, 1=medium, 2=verbose
+ (same as 'ruby -W').
--context-mode n Set n[0-4] to method to create Binding Object,
- when new workspace was created
- --extra-doc-dir Add an extra doc dir for the doc dialog
- --echo Show result (default)
- --noecho Don't show result
+ when new workspace was created.
+ --extra-doc-dir Add an extra doc dir for the doc dialog.
+ --echo Show result (default).
+ --noecho Don't show result.
--echo-on-assignment
- Show result on assignment
+ Show result on assignment.
--noecho-on-assignment
- Don't show result on assignment
+ Don't show result on assignment.
--truncate-echo-on-assignment
- Show truncated result on assignment (default)
- --inspect Use `inspect' for output
- --noinspect Don't use inspect for output
- --multiline Use multiline editor module
- --nomultiline Don't use multiline editor module
- --singleline Use singleline editor module
- --nosingleline Don't use singleline editor module
- --colorize Use colorization
- --nocolorize Don't use colorization
- --autocomplete Use autocompletion
- --noautocomplete Don't use autocompletion
- --prompt prompt-mode/--prompt-mode prompt-mode
- Switch prompt mode. Pre-defined prompt modes are
- `default', `simple', `xmp' and `inf-ruby'
+ Show truncated result on assignment (default).
+ --inspect Use 'inspect' for output.
+ --noinspect Don't use 'inspect' for output.
+ --no-pager Don't use pager.
+ --multiline Use multiline editor module (default).
+ --nomultiline Don't use multiline editor module.
+ --singleline Use single line editor module.
+ --nosingleline Don't use single line editor module (default).
+ --colorize Use color-highlighting (default).
+ --nocolorize Don't use color-highlighting.
+ --autocomplete Use auto-completion (default).
+ --noautocomplete Don't use auto-completion.
+ --regexp-completor
+ Use regexp based completion (default).
+ --type-completor Use type based completion.
+ --prompt prompt-mode, --prompt-mode prompt-mode
+ Set prompt mode. Pre-defined prompt modes are:
+ 'default', 'classic', 'simple', 'inf-ruby', 'xmp', 'null'.
--inf-ruby-mode Use prompt appropriate for inf-ruby-mode on emacs.
Suppresses --multiline and --singleline.
- --sample-book-mode/--simple-prompt
- Simple prompt mode
- --noprompt No prompt mode
+ --sample-book-mode, --simple-prompt
+ Set prompt mode to 'simple'.
+ --noprompt Don't output prompt.
+ --script Script mode (default, treat first argument as script)
+ --noscript No script mode (leave arguments in argv)
--single-irb Share self with sub-irb.
- --tracer Display trace for each execution of commands.
- --back-trace-limit n
- Display backtrace top n and tail n. The default
- value is 16.
- --verbose Show details
- --noverbose Don't show details
- -v, --version Print the version of irb
- -h, --help Print help
- -- Separate options of irb from the list of command-line args
-
-# vim:fileencoding=utf-8
+ --tracer Show stack trace for each command.
+ --back-trace-limit n[=16]
+ Display backtrace top n and bottom n.
+ --verbose Show details.
+ --noverbose Don't show details.
+ -v, --version Print the version of irb.
+ -h, --help Print help.
+ -- Separate options of irb from the list of command-line args.
diff --git a/lib/irb/lc/ja/encoding_aliases.rb b/lib/irb/lc/ja/encoding_aliases.rb
deleted file mode 100644
index c534bf0fef..0000000000
--- a/lib/irb/lc/ja/encoding_aliases.rb
+++ /dev/null
@@ -1,11 +0,0 @@
-# frozen_string_literal: false
-# :stopdoc:
-module IRB
- class Locale
- @@legacy_encoding_alias_map = {
- 'ujis' => Encoding::EUC_JP,
- 'euc' => Encoding::EUC_JP
- }.freeze
- end
-end
-# :startdoc:
diff --git a/lib/irb/lc/ja/error.rb b/lib/irb/lc/ja/error.rb
index 31ebb3b5f0..9e2e5b8870 100644
--- a/lib/irb/lc/ja/error.rb
+++ b/lib/irb/lc/ja/error.rb
@@ -1,27 +1,17 @@
-# -*- coding: utf-8 -*-
-# frozen_string_literal: false
+# frozen_string_literal: true
+#
# irb/lc/ja/error.rb -
-# $Release Version: 0.9.6$
-# $Revision$
# by Keiju ISHITSUKA(keiju@ruby-lang.org)
#
-# --
-#
-#
-#
-# :stopdoc:
module IRB
+ # :stopdoc:
+
class UnrecognizedSwitch < StandardError
def initialize(val)
super("スイッチ(#{val})が分りません")
end
end
- class NotImplementedError < StandardError
- def initialize(val)
- super("`#{val}'の定義が必要です")
- end
- end
class CantReturnToNormalMode < StandardError
def initialize
super("Normalモードに戻れません.")
@@ -47,11 +37,6 @@ module IRB
super("そのようなジョブ(#{val})はありません.")
end
end
- class CantShiftToMultiIrbMode < StandardError
- def initialize
- super("multi-irb modeに移れません.")
- end
- end
class CantChangeBinding < StandardError
def initialize(val)
super("バインディング(#{val})に変更できません.")
@@ -62,11 +47,7 @@ module IRB
super("プロンプトモード(#{val})は定義されていません.")
end
end
- class IllegalRCGenerator < StandardError
- def initialize
- super("RC_NAME_GENERATORが正しく定義されていません.")
- end
- end
+
+ # :startdoc:
end
-# :startdoc:
# vim:fileencoding=utf-8
diff --git a/lib/irb/lc/ja/help-message b/lib/irb/lc/ja/help-message
index 238535afb7..99f4449b3b 100644
--- a/lib/irb/lc/ja/help-message
+++ b/lib/irb/lc/ja/help-message
@@ -1,13 +1,3 @@
-# -*- coding: utf-8 -*-
-# irb/lc/ja/help-message.rb -
-# $Release Version: 0.9.6$
-# $Revision$
-# by Keiju ISHITSUKA(keiju@ruby-lang.org)
-#
-# --
-#
-#
-#
Usage: irb.rb [options] [programfile] [arguments]
-f ~/.irbrc を読み込まない.
-d $DEBUG をtrueにする(ruby -d と同じ)
@@ -19,10 +9,18 @@ Usage: irb.rb [options] [programfile] [arguments]
-W[level=2] ruby -W と同じ.
--context-mode n 新しいワークスペースを作成した時に関連する Binding
オブジェクトの作成方法を 0 から 3 のいずれかに設定する.
+ --extra-doc-dir 指定したディレクトリのドキュメントを追加で読み込む.
--echo 実行結果を表示する(デフォルト).
--noecho 実行結果を表示しない.
+ --echo-on-assignment
+ 代入結果を表示する.
+ --noecho-on-assignment
+ 代入結果を表示しない.
+ --truncate-echo-on-assignment
+ truncateされた代入結果を表示する(デフォルト).
--inspect 結果出力にinspectを用いる.
--noinspect 結果出力にinspectを用いない.
+ --no-pager ページャを使用しない.
--multiline マルチラインエディタを利用する.
--nomultiline マルチラインエディタを利用しない.
--singleline シングルラインエディタを利用する.
@@ -31,6 +29,9 @@ Usage: irb.rb [options] [programfile] [arguments]
--nocolorize 色付けを利用しない.
--autocomplete オートコンプリートを利用する.
--noautocomplete オートコンプリートを利用しない.
+ --regexp-completor
+ 補完に正規表現を利用する.
+ --type-completor 補完に型情報を利用する.
--prompt prompt-mode/--prompt-mode prompt-mode
プロンプトモードを切替えます. 現在定義されているプ
ロンプトモードは, default, simple, xmp, inf-rubyが
@@ -41,6 +42,8 @@ Usage: irb.rb [options] [programfile] [arguments]
--sample-book-mode/--simple-prompt
非常にシンプルなプロンプトを用いるモードです.
--noprompt プロンプト表示を行なわない.
+ --script スクリプトモード(最初の引数をスクリプトファイルとして扱う、デフォルト)
+ --noscript 引数をargvとして扱う.
--single-irb irb 中で self を実行して得られるオブジェクトをサ
ブ irb と共有する.
--tracer コマンド実行時にトレースを行なう.
@@ -53,5 +56,3 @@ Usage: irb.rb [options] [programfile] [arguments]
-v, --version irbのバージョンを表示する.
-h, --help irb のヘルプを表示する.
-- 以降のコマンドライン引数をオプションとして扱わない.
-
-# vim:fileencoding=utf-8