Class: BundlerSkills::Command
- Inherits:
-
Bundler::Plugin::API
- Object
- Bundler::Plugin::API
- BundlerSkills::Command
- Defined in:
- lib/bundler_skills/command.rb
Overview
‘bundle skills [sync|list|clean] [–dry-run]`
The manual entry point. Unlike the hook, it ignores the production/CI disabling guard — running it is an explicit user action. It reuses the same Synchronizer logic the hook uses.
Defined Under Namespace
Classes: OverrideDryRun
Instance Method Summary collapse
Instance Method Details
#exec(_command_name, args) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/bundler_skills/command.rb', line 12 def exec(_command_name, args) dry_run = args.delete("--dry-run") ? true : false subcommand = args.shift || "sync" case subcommand when "sync" then run_sync(dry_run) when "list" then run_list when "clean" then run_clean(dry_run) when "help", "-h", "--help" then print_help else Bundler.ui.error("[bundler-skills] unknown subcommand: #{subcommand}") print_help end end |