Class: Veye::Github::Delete
- Inherits:
-
BaseExecutor
- Object
- BaseExecutor
- Veye::Github::Delete
- Defined in:
- lib/veye/github/delete.rb
Overview
Delete class include methods to cleanup projects imported from Github
Class Method Summary collapse
Methods inherited from BaseExecutor
catch_request_error, filter_dependencies, get_formatter, show_bulk_dependencies, show_dependencies, show_message, show_results, valid_response?
Methods included from FormatHelpers
#format_exists?, #formats_attached?, #supported_format?
Class Method Details
.delete_repo(api_key, repo_name, options) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/veye/github/delete.rb', line 7 def self.delete_repo(api_key, repo_name, ) response = Veye::API::Github.delete_repo( api_key, repo_name, [:branch] ) show_result(response) end |
.show_result(response) ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/veye/github/delete.rb', line 14 def self.show_result(response) if response.success printf "Deleted\n".color(:green) else printf("Cant delete - %s\n%s\n", response..color(:red), response.data['error']) end end |