247件ヒット
[1-100件を表示]
(0.017秒)
別のキーワード
クラス
モジュール
- FileUtils (91)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (12) - FileUtils (12)
- Marshal フォーマット (12)
-
NEWS for Ruby 2
. 0 . 0 (12) -
cp
_ lr (7) -
cp
_ r (12) - rm (12)
-
rm
_ r (12) -
rm
_ rf (12) - rmtree (12)
-
ruby 1
. 6 feature (12) -
ruby 1
. 8 . 3 feature (12) -
ruby 1
. 8 . 4 feature (12) -
ruby 1
. 9 feature (12) -
rubygems
/ commands / cert _ command (12) -
rubygems
/ commands / sources _ command (12) -
rubygems
/ commands / uninstall _ command (12) -
rubygems
/ security (12) -
set
_ params (12)
検索結果
先頭5件
-
FileUtils
. # remove(list , options = {}) -> () (18215.0) -
list で指定された対象を消去します。
...指定可能です。
二つ以上指定する場合は配列で指定します。
@param options :force, :noop, :verbose が指定できます。
c:FileUtils#options
//emlist[][ruby]{
require 'fileutils'
FileUtils.rm('junk.txt')
FileUtils.rm(Dir.glob('*~'))
FileUtils.rm... -
FileUtils
. options -> Array (18113.0) -
オプション名の配列を返します。
...オプション名の配列を返します。
//emlist[][ruby]{
require 'fileutils'
FileUtils.options
# => ["verbose", "mode", "noop", "parents", "force", "preserve", "dereference_root", "remove_destination", "secure", "mtime", "nocreate"]
//}......オプション名の配列を返します。
//emlist[][ruby]{
require 'fileutils'
FileUtils.options
# => ["noop", "verbose", "force", "mode", "parents", "owner", "group", "preserve", "dereference_root", "remove_destination", "secure", "mtime", "nocreate"]
//}... -
FileUtils
. # rm(list , options = {}) -> () (3115.0) -
list で指定された対象を消去します。
...指定可能です。
二つ以上指定する場合は配列で指定します。
@param options :force, :noop, :verbose が指定できます。
c:FileUtils#options
//emlist[][ruby]{
require 'fileutils'
FileUtils.rm('junk.txt')
FileUtils.rm(Dir.glob('*~'))
FileUtils.rm... -
FileUtils
. # rm _ rf(list , options = {}) -> () (126.0) -
ファイルまたはディレクトリ list を再帰的に消去します。
...ram options :noop, :verbose, :secure が指定できます。
c:FileUtils#options
=== 注意
このメソッドにはローカル脆弱性が存在します。
この脆弱性を回避するには :secure オプションを使用してください。
詳しくは FileUtils.#remove_e......ntry_secure の項を参照してください。
@see FileUtils.#rm, FileUtils.#rm_r, FileUtils.#remove_entry_secure... -
FileUtils
. # rmtree(list , options = {}) -> () (126.0) -
ファイルまたはディレクトリ list を再帰的に消去します。
...ram options :noop, :verbose, :secure が指定できます。
c:FileUtils#options
=== 注意
このメソッドにはローカル脆弱性が存在します。
この脆弱性を回避するには :secure オプションを使用してください。
詳しくは FileUtils.#remove_e......ntry_secure の項を参照してください。
@see FileUtils.#rm, FileUtils.#rm_r, FileUtils.#remove_entry_secure... -
FileUtils
. # rm _ r(list , options = {}) -> () (125.0) -
ファイルまたはディレクトリ list を再帰的に消去します。
...定可能です。
二つ以上指定する場合は配列で指定します。
@param options :force, :noop, :verbose, :secure が指定できます。
c:FileUtils#options
=== 注意
このメソッドにはローカル脆弱性が存在します。
この脆弱性を......ョンを使用してください。
詳しくは FileUtils.#remove_entry_secure の項を参照してください。
//emlist[][ruby]{
require 'fileutils'
FileUtils.rm_r(Dir.glob('/tmp/*'))
FileUtils.rm_r(Dir.glob('/tmp/*'), secure: true)
//}
@see FileUtils.#rm, FileUtils.#remove_entry_secure... -
FileUtils
. # cp _ lr(src , dest , noop: nil , verbose: nil , dereference _ root: true , remove _ destination: false) (119.0) -
src へのハードリンク dest を作成します。 src がディレクトリの場合、再帰的にリンクします。 dest がディレクトリの場合、src へのハードリンク dest/src を作成します。
...。
@param dest リンク作成先のファイルかディレクトリです。
@param options :noop, :verbose, :dereference_root, :remove_destination が指定できます。
c:FileUtils#options
@raise ArgumentError dest が src に含まれる場合に発生します。
@raise Er... -
FileUtils
. # cp _ r(src , dest , options = {}) -> () (119.0) -
src を dest にコピーします。src がディレクトリであったら再帰的に コピーします。その際 dest がディレクトリなら dest/src にコピーします。
...。
@param dest コピー先のファイルかディレクトリです。
@param options :preserve, :noop, :verbose, :dereference_root, :remove_destination が指定できます。
c:FileUtils#options
//emlist[][ruby]{
# installing ruby library "mylib" under the site_ruby
require '... -
Marshal フォーマット (30.0)
-
Marshal フォーマット フォーマットバージョン 4.8 を元に記述しています。
...ータ構造になります。
//emlist{
| '/' | 長さ(Fixnum形式) | ソース文字列 | オプション |
//}
オプションは、Regexp#optionsの結果 + 漢字コードのフラグ値です。
ruby 1.9 以降では隠しインスタンス変数として String と同様に
encoding が......instance_eval { @bar } # => 1
File.open('testfile', 'wb') do |f|
Marshal.dump(Bar, f)
end
# 別プログラム相当にするため remove_const
Object.send :remove_const, :Bar
module Bar
end
p bar = Marshal.load(File.binread('testfile'))
p bar.instance_eval { @bar }
# => nil
//}
//emlist[例......az
end
end
p Baz.baz
# => 1
File.open('testfile', 'wb') do |f|
Marshal.dump(Baz, f)
end
# 別プログラム相当にするため remove_const
Object.send :remove_const, :Baz
module Baz
def self.baz
@@baz
end
end
p baz = Marshal.load(File.binread('testfile'))
# => Baz
baz.baz
# => unin...