lib/core/extract.rb in radon-0.1.1 vs lib/core/extract.rb in radon-0.1.2
- old
+ new
@@ -21,10 +21,14 @@
def extract_ruby(target)
extract_zip(Radon::Environments.getTargetOf('ruby (beta)'), target)
find_and_replace_all(target, '{{NAME}}', projectify(target).split('-').collect(&:capitalize).join)
end
+def extract_c(target)
+ extract_zip(Radon::Environments.getTargetOf('c'), target)
+end
+
# Extracts some zip data to the passed destination
def extract_zip(file, destination)
puts "Creating project under #{File.expand_path(destination)}" unless $quiet
create(destination)
FileUtils.mkdir_p(destination)
@@ -39,6 +43,6 @@
create(fpath)
end
zip_file.extract(f, fpath) unless File.exist?(fpath)
end
end
-end
\ No newline at end of file
+end