Skip to content
Browse files

Updated CDE Generator

UpdatedCan be run with: rake cde
  • Loading branch information...
1 parent 594e745 commit f0b1d6d76fb0b508267442f6a943398edfbfab3e @bw-z bw-z committed May 16, 2012
Showing with 25 additions and 3 deletions.
  1. +25 −3 Rakefile
View
28 Rakefile
@@ -165,10 +165,32 @@ task :cde do
sh "make";
Dir.chdir "..";
puts "\nCreating CDE Package...\n";
- sh "./CDE/cde ruby beef";
- sleep (1);
+ sh "bundle install"
+ Rake::Task['cde_beef_start'].invoke
+ Rake::Task['beef_stop'].invoke
puts "\nCleaning Up...\n";
- sh "rm -r CDE";
+ sleep (2);
+ sh "rm -rf CDE";
puts "\nCDE Package Created...\n";
end
+################################
+# CDE/BeEF environment set up
+
+@beef_process_id = nil;
+
+task :cde_beef_start => 'beef' do
+ printf "Starting CDE BeEF (wait 10 seconds)..."
+ @beef_process_id = IO.popen("./CDE/cde ruby beef -x 2> /dev/null", "w+")
+ delays = [2, 2, 1, 1, 1, 0.5, 0.5 , 0.5, 0.3, 0.2, 0.1, 0.1, 0.1, 0.05, 0.05]
+ delays.each do |i| # delay for 10 seconds
+ printf '.'
+ sleep (i)
+ end
+ puts '.'
+end
+
+
+################################
+
+

0 comments on commit f0b1d6d

Please sign in to comment.
Something went wrong with that request. Please try again.