Class: AppCommand::ScriptsPomFixer

Inherits:
Convoy::ActionCommand::Base
  • Object
show all
Defined in:
lib/routes/scripts_pom_fixer.rb

Instance Method Summary collapse

Instance Method Details

#executeObject



5
6
7
8
9
10
11
12
13
# File 'lib/routes/scripts_pom_fixer.rb', line 5

def execute

    @opts = command_options
    @args = arguments
    @git = App::Git.new
    opts_validate
    opts_routing

end

#fix_pomsObject



25
26
27
28
29
30
31
32
33
# File 'lib/routes/scripts_pom_fixer.rb', line 25

def fix_poms

    current_branch_code_repo = @git.current_branch_for_repo(App::Config.param(App::Config::WORKSTATION_PATH_TO_BP_CODE))

    files_to_change = App::Pom::get_files_to_change

    App::Pom::unsnapshot_files(files_to_change,  (@opts[:forMaster] ? App::Git::MASTER : current_branch_code_repo))

end

#opts_routingObject



19
20
21
22
23
# File 'lib/routes/scripts_pom_fixer.rb', line 19

def opts_routing

    fix_poms

end

#opts_validateObject



15
16
17
# File 'lib/routes/scripts_pom_fixer.rb', line 15

def opts_validate

end