るりまサーチ

最速Rubyリファレンスマニュアル検索!
510件ヒット [1-100件を表示] (0.118秒)
トップページ > クエリ:Proc[x] > クエリ:command[x] > クエリ:shell/command-processor[x]

別のキーワード

  1. shell/builtin-command new
  2. shell/builtin-command each
  3. rubygems/command command
  4. irb/extend-command def_extend_command
  5. irb/extend-command install_extend_commands

検索結果

<< 1 2 3 ... > >>

shell/command-processor (50000.0)

Shell で使用可能なコマンドの大半を定義するライブラリです。

Shell で使用可能なコマンドの大半を定義するライブラリです。

Shell::CommandProcessor.def_system_command(command, path = command) -> () (20321.0)

@todo

...@todo

与えられたコマンドをメソッドとして定義します。

@param command 定義したいコマンドを指定します。

@param path command のパスを指定します。省略すると環境変数 PATH から command を探します。...

Shell::CommandProcessor.alias_command(alias, command, *opts) -> self (20210.0)

@todo

...@todo

@param alias エイリアスの名前を指定します。

@param command コマンド名を指定します。

@param opts コマンドに与えるオプションを指定します。

@raise SyntaxError コマンドのエイリアス作成に失敗した時に発生します。...

Shell::CommandProcessor.alias_command(alias, command, *opts) { ... } -> self (20210.0)

@todo

...@todo

@param alias エイリアスの名前を指定します。

@param command コマンド名を指定します。

@param opts コマンドに与えるオプションを指定します。

@raise SyntaxError コマンドのエイリアス作成に失敗した時に発生します。...

Shell::CommandProcessor.undef_system_command(command) -> self (20208.0)

与えられたコマンドを削除します。

...与えられたコマンドを削除します。

@param command 削除したいコマンド名を指定します。...

絞り込み条件を変える

Shell::CommandProcessor#find_system_command(command) (20202.0)

@todo

@todo

Shell::CommandProcessor.def_builtin_commands(delegation_class, commands_specs) -> () (20200.0)

@todo

...@todo

@param delegation_class 処理を委譲したいクラスかモジュールを指定します。

@param commands_specs コマンドの仕様を文字列の配列で指定します。
[[コマンド名, [引数1, 引数2, ...]], ...]...

Shell::CommandProcessor.add_delegate_command_to_shell(id) (20101.0)

@todo

@todo

Shell 自体を初期化する時に呼び出されるメソッドです。
ユーザが使用することはありません。

@param id メソッド名を指定します。

Shell::CommandProcessor.unalias_command(alias) -> self (20101.0)

エイリアスを削除します。

エイリアスを削除します。

@param alias 削除したいエイリアスを指定します。

Shell::CommandProcessor.install_builtin_commands -> () (20100.0)

ビルトインコマンドを定義します。

ビルトインコマンドを定義します。

絞り込み条件を変える

Shell::CommandProcessor.install_system_commands(prefix = "sys_") -> () (20100.0)

全てのシステムコマンドをメソッドとして定義します。

全てのシステムコマンドをメソッドとして定義します。

既に定義されているコマンドを再定義することはありません。
デフォルトでは全てのコマンドに "sys_" というプレフィクスが付きます。
また、メソッド名として使用できない文字は全て "_" に置換してメソッドを定義します。
このメソッドの実行中に発生した例外は単に無視されます。

@param prefix プレフィクスを指定します。

Shell::CommandProcessor (20000.0)

Shell::CommandProcessor#system(command, *opts) -> Shell::SystemCommand (14235.0)

command を実行する.

...
command
を実行する.

@param command 実行するコマンドのパスを文字列で指定します。

@param opts command のオプションを文字列で指定します。複数可。

使用例:

require 'shell'
Shell.verbose = false
sh = Shell.new

print sh.system("ls", "-l")
S...
...hell.def_system_command("head")
sh.system("ls", "-l") | sh.head("-n 3") > STDOUT...

Shell::CommandProcessor#[](command, file1, file2 = nil) -> bool | Time | Integer | nil (14108.0)

Kernel.#test や FileTest のメソッドに処理を委譲します。

...Kernel.#test や FileTest のメソッドに処理を委譲します。

@param command 数値、またはサイズが 1 の文字列の場合は Kernel.#test に処理委譲します。
2 文字以上の文字列の場合は FileTest のメソッドとして実行します。

@para...

Shell::CommandProcessor#test(command, file1, file2 = nil) -> bool | Time | Integer | nil (14108.0)

Kernel.#test や FileTest のメソッドに処理を委譲します。

...Kernel.#test や FileTest のメソッドに処理を委譲します。

@param command 数値、またはサイズが 1 の文字列の場合は Kernel.#test に処理委譲します。
2 文字以上の文字列の場合は FileTest のメソッドとして実行します。

@para...

絞り込み条件を変える

Shell::CommandProcessor.alias_map -> Hash (14016.0)

Shell::CommandProcessor.alias_command で定義したエイリアスの一覧を返します。

...Shell::CommandProcessor.alias_command で定義したエイリアスの一覧を返します。...

Shell::CommandProcessor#cat(*files) -> Shell::Filter (14006.0)

実行すると, それらを内容とする Filter オブジェクトを返します.

...param files シェルコマンド cat に与えるファイル名を文字列で指定します。

動作例
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact {
glob("*.txt").to_a.each { |file|
file.chomp!
cat(file).each { |l|
echo(l) | tee(...
<< 1 2 3 ... > >>