Class: DevFlow::Ur
Instance Attribute Summary
Attributes inherited from App
#command, #config, #git, #logger, #members, #roadmap, #waiting
Instance Method Summary collapse
Methods inherited from App
#all_member_names, #ask_rebase, #debug, #display_close_waiting, #display_tasks, #error, #hello, #hr, #hrb, #hrbh, #hrh, #i_am_leader?, #i_am_moderator?, #i_am_supervisor?, #i_have_power?, #in_release?, #in_trunk?, #info, #initialize, #leader_name, #load_roadmap, #new_version, #switch_to!, #sync?, #task, #tasks_for_close, #upload_progress!, #user_name, #warn
Constructor Details
This class inherits a constructor from DevFlow::App
Instance Method Details
#process! ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/dev_flow/commands/ur.rb', line 4 def process! error "Not on the develop trunk" unless @git.current_branch == 'develop' error "Only leader/moderator and supervisor can edit ROADMAP" unless i_have_power? #p @git.modified_files error "No change detected on #{@config[:roadmap]}" unless @git.modified_files.include? File.(@config[:roadmap]) `git add ROADMAP` msg = ARGV[1] || 'update roadmap' `git commit -am '#{msg}'` if sync? info "Push your change to the remote server" `git push #{@config["git_remote"]} develop` else warn "Offline update for ROADMAP." end end |