diff --git a/Octokit.Reactive/Clients/IObservableRepositoryContentsClient.cs b/Octokit.Reactive/Clients/IObservableRepositoryContentsClient.cs index 45d07226..1ab8ab7b 100644 --- a/Octokit.Reactive/Clients/IObservableRepositoryContentsClient.cs +++ b/Octokit.Reactive/Clients/IObservableRepositoryContentsClient.cs @@ -23,20 +23,7 @@ namespace Octokit.Reactive /// The name of the repository /// IObservable GetReadmeHtml(string owner, string name); - - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// - [Obsolete("Use GetArchive to download the archive instead")] - IObservable GetArchiveLink(string owner, string name); - + /// /// Get an archive of a given repository's contents /// @@ -46,20 +33,6 @@ namespace Octokit.Reactive /// A promise, containing the binary contents of the archive IObservable GetArchive(string owner, string name); - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// - [Obsolete("Use GetArchive to download the archive instead")] - IObservable GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat); - /// /// Get an archive of a given repository's contents, in a specific format /// @@ -70,21 +43,6 @@ namespace Octokit.Reactive /// A promise, containing the binary contents of the archive IObservable GetArchive(string owner, string name, ArchiveFormat archiveFormat); - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// A valid Git reference. - /// - [Obsolete("Use GetArchive to download the archive instead")] - IObservable GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat, string reference); - /// /// Get an archive of a given repository's contents, using a specific format and reference /// diff --git a/Octokit.Reactive/Clients/ObservableRepositoryContentsClient.cs b/Octokit.Reactive/Clients/ObservableRepositoryContentsClient.cs index 6d05f60b..456ce31b 100644 --- a/Octokit.Reactive/Clients/ObservableRepositoryContentsClient.cs +++ b/Octokit.Reactive/Clients/ObservableRepositoryContentsClient.cs @@ -48,23 +48,6 @@ namespace Octokit.Reactive return _client.Repository.Content.GetReadmeHtml(owner, name).ToObservable(); } - - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// - [Obsolete("Use GetArchive to download the archive instead")] - public IObservable GetArchiveLink(string owner, string name) - { - return GetArchiveLink(owner, name, ArchiveFormat.Tarball, string.Empty); - } - /// /// Get an archive of a given repository's contents /// @@ -77,23 +60,6 @@ namespace Octokit.Reactive return GetArchive(owner, name, ArchiveFormat.Tarball); } - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// - [Obsolete("Use GetArchive to download the archive instead")] - public IObservable GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat) - { - return GetArchiveLink(owner, name, archiveFormat, string.Empty); - } - /// /// Get an archive of a given repository's contents, in a specific format /// @@ -107,27 +73,6 @@ namespace Octokit.Reactive return GetArchive(owner, name, archiveFormat, string.Empty); } - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// A valid Git reference. - /// - [Obsolete("Use GetArchive to download the archive instead")] - public IObservable GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat, string reference) - { - Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); - Ensure.ArgumentNotNullOrEmptyString(name, "name"); - - return _client.Repository.Content.GetArchiveLink(owner, name, archiveFormat, reference).ToObservable(); - } - /// /// Get an archive of a given repository's contents, using a specific format and reference /// diff --git a/Octokit/Clients/IRepositoryContentsClient.cs b/Octokit/Clients/IRepositoryContentsClient.cs index daf12728..272f3c06 100644 --- a/Octokit/Clients/IRepositoryContentsClient.cs +++ b/Octokit/Clients/IRepositoryContentsClient.cs @@ -91,19 +91,6 @@ namespace Octokit /// Task GetReadmeHtml(string owner, string name); - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// - [Obsolete("Use GetArchive to download the archive instead")] - Task GetArchiveLink(string owner, string name); - /// /// Get an archive of a given repository's contents /// @@ -113,20 +100,6 @@ namespace Octokit /// The binary contents of the archive Task GetArchive(string owner, string name); - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// - [Obsolete("Use GetArchive to download the archive instead")] - Task GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat); - /// /// Get an archive of a given repository's contents, in a specific format /// @@ -137,21 +110,6 @@ namespace Octokit /// The binary contents of the archive Task GetArchive(string owner, string name, ArchiveFormat archiveFormat); - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// A valid Git reference. - /// - [Obsolete("Use GetArchive to download the archive instead")] - Task GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat, string reference); - /// /// Get an archive of a given repository's contents, using a specific format and reference /// diff --git a/Octokit/Clients/RepositoryContentsClient.cs b/Octokit/Clients/RepositoryContentsClient.cs index fbd1d850..16c47e35 100644 --- a/Octokit/Clients/RepositoryContentsClient.cs +++ b/Octokit/Clients/RepositoryContentsClient.cs @@ -148,22 +148,6 @@ namespace Octokit return ApiConnection.GetHtml(ApiUrls.RepositoryReadme(owner, name), null); } - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// - [Obsolete("Octokit's HTTP library now follows redirects by default - this API will be removed in a future release")] - public Task GetArchiveLink(string owner, string name) - { - return GetArchiveLink(owner, name, ArchiveFormat.Tarball, string.Empty); - } - /// /// Get an archive of a given repository's contents /// @@ -176,23 +160,6 @@ namespace Octokit return GetArchive(owner, name, ArchiveFormat.Tarball, string.Empty); } - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// - [Obsolete("Octokit's HTTP library now follows redirects by default - this API will be removed in a future release")] - public Task GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat) - { - return GetArchiveLink(owner, name, archiveFormat, string.Empty); - } - /// /// Get an archive of a given repository's contents, in a specific format /// @@ -206,27 +173,6 @@ namespace Octokit return GetArchive(owner, name, archiveFormat, string.Empty); } - /// - /// This method will return a 302 to a URL to download a tarball or zipball archive for a repository. - /// Please make sure your HTTP framework is configured to follow redirects or you will need to use the - /// Location header to make a second GET request. - /// Note: For private repositories, these links are temporary and expire quickly. - /// - /// https://developer.github.com/v3/repos/contents/#get-archive-link - /// The owner of the repository - /// The name of the repository - /// The format of the archive. Can be either tarball or zipball - /// A valid Git reference. - /// - [Obsolete("Octokit's HTTP library now follows redirects by default - this API will be removed in a future release")] - public Task GetArchiveLink(string owner, string name, ArchiveFormat archiveFormat, string reference) - { - Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); - Ensure.ArgumentNotNullOrEmptyString(name, "name"); - - return ApiConnection.GetRedirect(ApiUrls.RepositoryArchiveLink(owner, name, archiveFormat, reference)); - } - /// /// Get an archive of a given repository's contents, using a specific format and reference ///