Sha256: 04579c2cb352662e6e3e0e030f9dd81b7c2f375fcce33f91ee426f65a621a678
Contents?: true
Size: 471 Bytes
Versions: 6
Compression:
Stored size: 471 Bytes
Contents
# frozen_string_literal: true require 'travis/cli' module Travis module CLI class Raw < ApiCommand description 'makes an (authenticated) API call and prints out the result' skip :authenticate on('--[no-]json', 'display as json') def run(resource) reply = session.get_raw(resource) json? ? say(reply.to_json) : pp(reply) rescue Travis::Client::NotFound error 'resource not found' end end end end
Version data entries
6 entries across 6 versions & 1 rubygems