611件ヒット
[1-100件を表示]
(0.078秒)
別のキーワード
ライブラリ
- ビルトイン (143)
- mkmf (11)
- pty (44)
- rake (11)
- shell (78)
-
shell
/ command-processor (66) -
shell
/ filter (84) -
shell
/ system-command (102)
クラス
- Shell (78)
-
Shell
:: CommandProcessor (66) -
Shell
:: Filter (84) -
Shell
:: SystemCommand (96)
キーワード
- < (6)
- > (6)
- >> (6)
- Rubyで使われる記号の意味(正規表現の複雑な記号は除く) (11)
- SystemCommand (6)
- Win32ネイティブ版Rubyの互換性問題 (11)
- ` (11)
- active? (6)
-
alias
_ command (6) - cat (18)
-
def
_ system _ command (12) - each (6)
- echo (18)
- exec (44)
-
find
_ system _ command (18) - flush (6)
- getpty (22)
- glob (18)
- input= (6)
-
install
_ system _ commands (12) - kill (6)
- name (6)
- new (6)
- notify (12)
- out (18)
- rdoc (11)
-
ruby 1
. 8 . 4 feature (11) -
ruby 1
. 9 feature (11) - sh (11)
-
shell
/ system-command (6) - spawn (66)
- start (6)
-
start
_ export (6) -
start
_ import (6) -
super
_ each (6) - tee (18)
- terminate (6)
-
to
_ a (6) -
to
_ s (6) - transact (18)
- tsort (11)
-
unalias
_ command (6) -
undef
_ system _ command (12) - wait? (6)
- xsystem (11)
- | (6)
検索結果
先頭5件
-
Shell
:: SystemCommand # command -> String (24101.0) -
@todo
@todo
コマンド名を返します。 -
Shell
:: CommandProcessor # system(command , *opts) -> Shell :: SystemCommand (21454.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
# system(command , *opts) -> Shell :: SystemCommand (18454.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
:: Filter # system(command , *opts) -> Shell :: SystemCommand (18454.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... -
Kernel
. # system(command , options={}) -> bool | nil (18262.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...の解釈
この形式では command が shell のメタ文字
//emlist{
* ? {} [] <> () ~ & | \ $ ; ' ` " \n
//}
を含む場合、shell 経由で実行されます。
そうでなければインタプリタから直接実行されます。
@param command command コマンドを文字列で指......][ruby]{
system("echo *") # => true
# fileA fileB fileC ...
//}
//emlist[exceptionオプションを指定][ruby]{
system("sad", exception: true) # => Errno::ENOENT (No such file or directory - sad)
system('ruby -e "exit(false)"', exception: true) # => RuntimeError (Command failed......with exit 1: ruby -e "exit(false)")
system('ruby -e "exit(true)"', exception: true) # => true
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(env , command , options={}) -> bool | nil (18262.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...の解釈
この形式では command が shell のメタ文字
//emlist{
* ? {} [] <> () ~ & | \ $ ; ' ` " \n
//}
を含む場合、shell 経由で実行されます。
そうでなければインタプリタから直接実行されます。
@param command command コマンドを文字列で指......][ruby]{
system("echo *") # => true
# fileA fileB fileC ...
//}
//emlist[exceptionオプションを指定][ruby]{
system("sad", exception: true) # => Errno::ENOENT (No such file or directory - sad)
system('ruby -e "exit(false)"', exception: true) # => RuntimeError (Command failed......with exit 1: ruby -e "exit(false)")
system('ruby -e "exit(true)"', exception: true) # => true
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(command , options={}) -> bool | nil (18238.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...の解釈
この形式では command が shell のメタ文字
//emlist{
* ? {} [] <> () ~ & | \ $ ; ' ` " \n
//}
を含む場合、shell 経由で実行されます。
そうでなければインタプリタから直接実行されます。
@param command command コマンドを文字列で指......定します。
@param env 更新する環境変数を表す Hash
@param options オプションパラメータ Hash
//emlist[シェル経由でコマンドを実行][ruby]{
system("echo *") # => true
# fileA fileB fileC ...
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(env , command , options={}) -> bool | nil (18238.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...の解釈
この形式では command が shell のメタ文字
//emlist{
* ? {} [] <> () ~ & | \ $ ; ' ` " \n
//}
を含む場合、shell 経由で実行されます。
そうでなければインタプリタから直接実行されます。
@param command command コマンドを文字列で指......定します。
@param env 更新する環境変数を表す Hash
@param options オプションパラメータ Hash
//emlist[シェル経由でコマンドを実行][ruby]{
system("echo *") # => true
# fileA fileB fileC ...
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(env , program , *args , options={}) -> bool | nil (18127.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...se RuntimeError exception: true が指定されていて、コマンドの終了ステータスが 0 以外のときに発生します。
//emlist[インタプリタから直接コマンドを実行][ruby]{
system("echo", "*") # => true
# *
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(program , *args , options={}) -> bool | nil (18127.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...se RuntimeError exception: true が指定されていて、コマンドの終了ステータスが 0 以外のときに発生します。
//emlist[インタプリタから直接コマンドを実行][ruby]{
system("echo", "*") # => true
# *
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(env , program , *args , options={}) -> bool | nil (18123.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...s オプションパラメータ Hash
@raise ArgumentError 第一引数が配列かつ要素数が 2 でない場合に発生します。
//emlist[インタプリタから直接コマンドを実行][ruby]{
system("echo", "*") # => true
# *
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Kernel
. # system(program , *args , options={}) -> bool | nil (18123.0) -
引数を外部コマンドとして実行して、成功した時に真を返します。
...s オプションパラメータ Hash
@raise ArgumentError 第一引数が配列かつ要素数が 2 でない場合に発生します。
//emlist[インタプリタから直接コマンドを実行][ruby]{
system("echo", "*") # => true
# *
//}
@see Kernel.#`,Kernel.#spawn,Kernel.#exec,system(3)... -
Shell
:: CommandProcessor . def _ system _ command(command , path = command) -> () (15422.0) -
@todo
...@todo
与えられたコマンドをメソッドとして定義します。
@param command 定義したいコマンドを指定します。
@param path command のパスを指定します。省略すると環境変数 PATH から command を探します。... -
Shell
:: CommandProcessor . undef _ system _ command(command) -> self (15309.0) -
与えられたコマンドを削除します。
...与えられたコマンドを削除します。
@param command 削除したいコマンド名を指定します。... -
Shell
:: CommandProcessor # find _ system _ command(command) (15303.0) -
@todo
@todo -
Shell
:: CommandProcessor . install _ system _ commands(prefix = "sys _ ") -> () (15201.0) -
全てのシステムコマンドをメソッドとして定義します。
全てのシステムコマンドをメソッドとして定義します。
既に定義されているコマンドを再定義することはありません。
デフォルトでは全てのコマンドに "sys_" というプレフィクスが付きます。
また、メソッド名として使用できない文字は全て "_" に置換してメソッドを定義します。
このメソッドの実行中に発生した例外は単に無視されます。
@param prefix プレフィクスを指定します。 -
Shell
. def _ system _ command(command , path = command) -> nil (12468.0) -
Shell のメソッドとして command を登録します.
...ell のメソッドとして command を登録します.
OS上のコマンドを実行するにはまず, Shellのメソッドとして定義します.
注) コマンドを定義しなくとも直接実行できる Shell#system コマンドもあります.
@param command Shell のメソッドと......文字列で指定します。
@param path command のパスを指定します。
指定しない場合はcommand と同じになります。
例)
require 'shell'
Shell.def_system_command "ls"
# ls を定義
Shell.def_system_command "sys_sort", "sort"
# sortコマンドをsy... -
Shell
. undef _ system _ command(command) -> Shell :: CommandProcessor (12449.0) -
commandを削除します.
...
commandを削除します.
@param command 削除するコマンドの文字列を指定します。
動作例:
require 'shell'
Shell.def_system_command("ls")
# ls を定義
Shell.undef_system_command("ls")
# ls を 削除
sh = Shell.new
begin
sh.transact {
ls("-l").each...