Class: Makit::Cli::NugetCacheCommand

Inherits:
Clamp::Command
  • Object
show all
Defined in:
lib/makit/cli/utility_commands.rb

Overview

Manage NuGet package cache

Instance Method Summary collapse

Instance Method Details

#executeObject



39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# File 'lib/makit/cli/utility_commands.rb', line 39

def execute
  unless nuget_available?
    puts "Error: NuGet CLI is not available. Please install .NET SDK or NuGet CLI tools."
    exit 1
  end

  if list?
    list_cache_locations
  elsif verify?
    verify_cache_integrity
  elsif clear?
    clear_nuget_caches
  else
    show_cache_status
  end
end