Class: VPL::Command::Update::CMake
- Inherits:
-
VPL::Command::Update
- Object
- CLAide::Command
- VPL::Command
- VPL::Command::Update
- VPL::Command::Update::CMake
- Defined in:
- lib/vcpkg_pipeline/command/update/cmake.rb
Overview
VPL::Command::Update::CMake
Instance Attribute Summary
Attributes inherited from VPL::Command
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(argv) ⇒ CMake
constructor
A new instance of CMake.
- #run ⇒ Object
Methods inherited from VPL::Command
ensure_not_root_or_allowed!, git_version, options_extension, options_extension_hash, run, verify_minimum_git_version!, verify_xcode_license_approved!
Constructor Details
#initialize(argv) ⇒ CMake
Returns a new instance of CMake.
26 27 28 29 30 31 |
# File 'lib/vcpkg_pipeline/command/update/cmake.rb', line 26 def initialize(argv) @path = argv.shift_argument || Dir.pwd @new_version = argv.option('version', '').split(',').first super end |
Class Method Details
.options ⇒ Object
20 21 22 23 24 |
# File 'lib/vcpkg_pipeline/command/update/cmake.rb', line 20 def self. [ ['--version=x.x.x', '新版本号。(默认使用patch+1)'] ].concat(super) end |
Instance Method Details
#run ⇒ Object
33 34 35 36 37 |
# File 'lib/vcpkg_pipeline/command/update/cmake.rb', line 33 def run updater = Updater.new(@path) updater.update_cmake(@new_version) end |