# File lib/piston/commands/switch.rb, line 7
      def run
        new_root, dir = args.shift, args.shift
        raise Piston::CommandError, "Expected two arguments only to switch.  Unrecognized arguments: #{args.inspect}" unless args.empty?
        raise Piston::CommandError, "Expected a new vendor repository URL." if new_root.nil?
        raise Piston::CommandError, "Expected a directory to update." if dir.nil?
        switch(dir, new_root)
      end