Module: Octokit::Client::SourceImport
- Included in:
- Octokit::Client
- Defined in:
- lib/octokit/client/source_import.rb
Overview
Methods for the Source Import API
Instance Method Summary collapse
-
#cancel_source_import(repo, options = {}) ⇒ Boolean
Stop an import for a repository.
-
#map_source_import_commit_author(author_url, values, options = {}) ⇒ Sawyer::Resource
Update an author’s identity for the import.
-
#source_import_commit_authors(repo, options = {}) ⇒ Array<Sawyer::Resource>
List source import commit authors.
-
#source_import_progress(repo, options = {}) ⇒ Sawyer::Resource
View the progress of an import.
-
#start_source_import(repo, vcs, vcs_url, options = {}) ⇒ Sawyer::Resource
Start a source import to a GitHub repository using GitHub Importer.
Instance Method Details
#cancel_source_import(repo, options = {}) ⇒ Boolean
Stop an import for a repository.
87 88 89 90 |
# File 'lib/octokit/client/source_import.rb', line 87 def cancel_source_import(repo, = {}) = ensure_api_media_type(:source_imports, ) boolean_from_response :delete, "#{Repository.path repo}/import", end |
#map_source_import_commit_author(author_url, values, options = {}) ⇒ Sawyer::Resource
Update an author’s identity for the import.
74 75 76 77 |
# File 'lib/octokit/client/source_import.rb', line 74 def (, values, = {}) = ensure_api_media_type(:source_imports, .merge(values)) patch , end |
#source_import_commit_authors(repo, options = {}) ⇒ Array<Sawyer::Resource>
List source import commit authors
54 55 56 57 |
# File 'lib/octokit/client/source_import.rb', line 54 def (repo, = {}) = ensure_api_media_type(:source_imports, ) get "#{Repository.path repo}/import/authors", end |
#source_import_progress(repo, options = {}) ⇒ Sawyer::Resource
View the progress of an import.
39 40 41 42 |
# File 'lib/octokit/client/source_import.rb', line 39 def source_import_progress(repo, = {}) = ensure_api_media_type(:source_imports, ) get "#{Repository.path repo}/import", end |
#start_source_import(repo, vcs, vcs_url, options = {}) ⇒ Sawyer::Resource
Start a source import to a GitHub repository using GitHub Importer.
26 27 28 29 |
# File 'lib/octokit/client/source_import.rb', line 26 def start_source_import(repo, vcs, vcs_url, = {}) = ensure_api_media_type(:source_imports, .merge(:vcs => vcs, :vcs_url => vcs_url)) put "#{Repository.path repo}/import", end |