Module: Kar::DSL
- Defined in:
- lib/kar/dsl.rb
Overview
DSLs you can use in your Rakefiles
Instance Method Summary collapse
-
#cargo(target) ⇒ Object
Declare a cargo task which builds extension in Rust by Cargo.
- #download(args) ⇒ Object
- #files(file_list) ⇒ Object
Instance Method Details
#cargo(target) ⇒ Object
Declare a cargo task which builds extension in Rust by Cargo.
Also defines a cargo:check task which check sources and manifests. It’s useful to add them to the dependency of build task and prevent building invalid gem package.
Uses Gem::Ext::CargoBuilder internally unlike RbSys::ExtensionTask in order to build in the same way as ‘gem install` command, even though the output might be less usefull. When `RbSys::Extension` uses the same way, this function may be deprecated.
70 71 72 |
# File 'lib/kar/dsl.rb', line 70 def cargo(target) CargoTask.new target end |
#download(args) ⇒ Object
49 50 51 |
# File 'lib/kar/dsl.rb', line 49 def download(args) URITask.new args end |
#files(file_list) ⇒ Object
26 27 28 29 30 |
# File 'lib/kar/dsl.rb', line 26 def files(file_list) file_list.each do |file_name| file file_name end end |