From 2cbef0310e18ad90cc6f05e8463b2a4f874ba4a8 Mon Sep 17 00:00:00 2001 From: Danny Ben Shitrit Date: Mon, 27 Sep 2021 14:07:32 +0000 Subject: [PATCH] remove ExecHandler leftovers --- CHANGELOG.md | 6 ++++++ Runfile | 6 +++--- lib/runfile/dsl.rb | 45 ------------------------------------------ lib/runfile/version.rb | 2 +- 4 files changed, 10 insertions(+), 49 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 12373d7..e588c87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ Change Log Untagged - Latest ---------------------------------------- +- Remove Colsole and Exec modules + + +v0.11.2 - 2020-11-06 +---------------------------------------- + - Add 'env_var' DSL command to specify environment variables used by the Runfile diff --git a/Runfile b/Runfile index 7312abb..805cd6b 100644 --- a/Runfile +++ b/Runfile @@ -33,12 +33,12 @@ end help "Run YARD server" action :yard do - run "yard server -p3000 -B0.0.0.0 -r" + system "yard server -p3000 -B0.0.0.0 -r" end help "Generate changelog and append old changelog" action :changelog do - run "git changelog --save" + system "git changelog --save" # append older changelog (prior to switching to git-changelog) - run "cat .changelog.old.md >> CHANGELOG.md" + system "cat .changelog.old.md >> CHANGELOG.md" end diff --git a/lib/runfile/dsl.rb b/lib/runfile/dsl.rb index 97f905d..bf4dfb8 100644 --- a/lib/runfile/dsl.rb +++ b/lib/runfile/dsl.rb @@ -83,51 +83,6 @@ def execute(command_string) Runner.instance.cross_call command_string end - # Run a command, wait until it is done and continue - # run 'rails server' - def run(cmd) - ExecHandler.instance.run cmd - end - - # Run a command, wait until it is done, then exit - # run! 'rails server' - def run!(cmd) - ExecHandler.instance.run! cmd - end - - # Run a command in the background, optionally log to a log file and save - # the process ID in a pid file - # run_bg 'rails server', pid: 'rails', log: 'tmp/log.log' - def run_bg(cmd, pid: nil, log: '/dev/null') - ExecHandler.instance.run_bg cmd, pid: pid, log: log - end - - # Stop a command started with 'run_bg'. Provide the name of he pid file you - # used in 'run_bg' - # stop_bg 'rails' - def stop_bg(pid) - ExecHandler.instance.stop_bg pid - end - - # Set a block to be called before each run. The block should return - # the command to run, since this is intended to let the block modify - # the command if it needs to. - # before_run do |command| - # puts "BEFORE #{command}" - # command - # end - def before_run(&block) - ExecHandler.instance.before_run(&block) - end - - # Set a block to be called after each run - # before_run do |command| - # puts "AFTER #{command}" - # end - def after_run(&block) - ExecHandler.instance.after_run(&block) - end - # Also allow to use 'endcommand' instead of 'command' to end # a command namespace definition alias_method :endcommand, :command diff --git a/lib/runfile/version.rb b/lib/runfile/version.rb index f9a469a..91c81be 100644 --- a/lib/runfile/version.rb +++ b/lib/runfile/version.rb @@ -1,3 +1,3 @@ module Runfile - VERSION = "0.11.2" + VERSION = "0.12.0-rc1" end \ No newline at end of file