るりまサーチ

最速Rubyリファレンスマニュアル検索!
348件ヒット [101-200件を表示] (0.138秒)

別のキーワード

  1. openssl t61string
  2. asn1 t61string
  3. t61string new
  4. matrix t
  5. fiddle type_size_t

ライブラリ

クラス

モジュール

キーワード

検索結果

<< < 1 2 3 4 > >>

Rake::PackageTask#need_tar_gz=(flag) (9113.0)

gzip した tar ファイル (tar.gz) を作成するかどうかを設定します。

...した tar ファイル (tar.gz) を作成するかどうかを設定します。

@param flag 真または偽を指定します。

//emlist[][ruby]{
# Rakefile での記載例とする
require 'rake/packagetask'

Rake::PackageTask.new("sample", "1.0.0") do |package_task|
package_task.need_tar_gz...
...# => false
package_task.need_tar_gz = true
package_task.need_tar_gz # => true
end
//}...

Pathname#delete -> Integer (6213.0)

self が指すディレクトリあるいはファイルを削除します。

...self が指すディレクトリあるいはファイルを削除します。

//emlist[例][ruby]{
require "pathname"

pathname = Pathname("/path/to/sample")
pathname.exist? # => true
pathname.unlink # => 1
pathname.exist? # => false
//}...

Object#respond_to_missing?(symbol, include_private) -> bool (6167.0)

自身が symbol で表されるメソッドに対し BasicObject#method_missing で反応するつもりならば真を返します。

...るメソッドに対し
BasicObject#method_missing で反応するつもりならば真を返します。

Object#respond_to? はメソッドが定義されていない場合、
デフォルトでこのメソッドを呼びだし問合せます。

BasicObject#method_missing を override した場...
...rivate private method も含めたい場合に true が渡されます

//emlist[例][ruby]{
class Sample
def method_missing(name, *args)
if name =~ /^to_*/
[name, *args] # => [:to_sample, "sample args1", "sample args2"]
return
else
super
end
end

def respond_to_m...
...issing?(sym, include_private)
(sym =~ /^to_*/) ? true : super
end
end

s = Sample.new
s.to_sample("sample args1", "sample args2")
s.respond_to?(:to_sample) # => true
s.respond_to?(:sample) # => false
//}

@see Object#respond_to?, BasicObject#method_missing...

Pathname#split -> Array (6119.0)

File.split(self.to_s) と同じです。

...File.split(self.to_s) と同じです。

//emlist[例][ruby]{
require "pathname"

pathname = Pathname("/path/to/sample")
pathname.split # => [#<Pathname:/path/to>, #<Pathname:sample>]
//}

@see File.split...

Rake::PackageTask#package_dir_path -> String (6119.0)

パッケージに含むファイルを配置するディレクトリを返します。

...パッケージに含むファイルを配置するディレクトリを返します。

//emlist[][ruby]{
# Rakefile での記載例とする
require 'rake/packagetask'

Rake::PackageTask.new("sample", "1.0.0") do |package_task|
package_task.package_dir_path # => "pkg/sample-1.0.0"
end
//}...

絞り込み条件を変える

Rake::TaskManager#intern(task_class, task_name) -> Rake::Task (6119.0)

タスクを検索します。

...am task_class タスクのクラスを指定します。

@param task_name タスクの名前を指定します。

//emlist[][ruby]{
# Rakefile での記載例とする

t
ask default: :test_rake_app

t
ask :test_rake_app do |task|
t
ask.application.intern(Rake::Task, "test_rake_app") # => <Rake::Ta...
...sk test_rake_app => []>
t
ask.application.intern(Rake::Task, "sample_task") # => <Rake::Task sample_task => []>
end
//}...

Rake::FileList#egrep(pattern) {|filename, count, line| ... } (3167.0)

与えられたパターンをファイルリストから grep のように検索します。

...pattern 正規表現を指定します。

//emlist[][ruby]{
# Rakefile での記載例とする

IO.write("sample1", "line1\nline2\nline3\n")
IO.write("sample2", "line1\nline2\nline3\nline4\n")

t
ask default: :test_rake_app
t
ask :test_rake_app do

file_list = FileList.new('sample*')
file_list.e...
...ist.egrep(/.*/) do |filename, count, line|
"filename = #{filename}, count = #{count}, line = #{line}"
end
end

# => "filename = sample1, count = 1, line = line1\n"
# => "filename = sample1, count = 2, line = line2\n"
# => "filename = sample1, count = 3, line = line3\n"
# => "filename = sample2...
..., count = 1, line = line1\n"
# => "filename = sample2, count = 2, line = line2\n"
# => "filename = sample2, count = 3, line = line3\n"
# => "filename = sample2, count = 4, line = line4\n"
//}...

Rake::Application#add_loader(ext, loader) (3125.0)

与えられた拡張子で終わるファイル名のファイルをロードするためのローダーを 自身に追加します。

...aram ext 拡張子を指定します。

@param loader ローダーを指定します。

//emlist[例][ruby]{
require "rake/loaders/makefile"

# Rakefile での記載例とする

t
ask default: :test
t
ask :test

makefile =<<-EOS
<< <<-'SAMPLE_MF'
# Comments
a: a1 a2 a3 a4
EOS
IO.write("sample.mf",...
...makefile)
Rake.application.add_loader("mf", Rake::MakefileLoader.new)
Rake.application.add_import("sample.mf")
Rake::Task.task_defined?("a") # => false
Rake.application.load_imports
Rake::Task.task_defined?("a") # => true
//}...

Rake::PackageTask#name -> String (3119.0)

バージョン情報を含まないパッケージの名前を返します。

...バージョン情報を含まないパッケージの名前を返します。

//emlist[][ruby]{
# Rakefile での記載例とする
require 'rake/packagetask'

Rake::PackageTask.new("sample", "1.0.0") do |package_task|
package_task.name # => "sample"
end
//}...
<< < 1 2 3 4 > >>