diff --git a/lib/importmap/commands.rb b/lib/importmap/commands.rb index e5d9b9d..0a6fbec 100644 --- a/lib/importmap/commands.rb +++ b/lib/importmap/commands.rb @@ -46,10 +46,10 @@ def unpin(*packages) end end - desc "pristine [*PACKAGES]", "Redownload all pinned packages" + desc "pristine", "Redownload all pinned packages" option :env, type: :string, aliases: :e, default: "production" option :from, type: :string, aliases: :f, default: "jspm" - def pristine(*packages) + def pristine packages = npm.packages_with_versions.map do |p, v| v.blank? ? p : [p, v].join("@") end