From 6adf0def4c2a3fad5b2afd84cc6f7dbbf9ef4774 Mon Sep 17 00:00:00 2001 From: lifangmoler Date: Tue, 5 Mar 2019 10:10:10 -0800 Subject: [PATCH] add doc --- README.md | 12 ++++++++++++ detect_gsc_test.go => detect_gcs_test.go | 0 go.sum | 1 + 3 files changed, 13 insertions(+) rename detect_gsc_test.go => detect_gcs_test.go (100%) diff --git a/README.md b/README.md index d9f8f67fd..85884fad4 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,7 @@ can be augmented at runtime by implementing the `Getter` interface. * Mercurial * HTTP * Amazon S3 + * Google GCP In addition to the above protocols, go-getter has what are called "detectors." These take a URL and attempt to automatically choose the best protocol for @@ -334,3 +335,14 @@ Some examples for these addressing schemes: - bucket.s3-eu-west-1.amazonaws.com/foo/bar - "s3::http://127.0.0.1:9000/test-bucket/hello.txt?aws_access_key_id=KEYID&aws_access_key_secret=SECRETKEY®ion=us-east-2" +### GCS (`gcs`) + +#### GCS Authentication + +In order to access to GCS, authentication credentials should be provided. More information can be found [here](https://cloud.google.com/docs/authentication/getting-started) + +#### GCS Bucket Examples + +- gcs::https://www.googleapis.com/storage/v1/bucket +- gcs::https://www.googleapis.com/storage/v1/bucket/foo.zip +- www.googleapis.com/storage/v1/bucket/foo diff --git a/detect_gsc_test.go b/detect_gcs_test.go similarity index 100% rename from detect_gsc_test.go rename to detect_gcs_test.go diff --git a/go.sum b/go.sum index 45220848b..0fc508823 100644 --- a/go.sum +++ b/go.sum @@ -54,6 +54,7 @@ github.com/hashicorp/go-cleanhttp v0.5.0 h1:wvCrVc9TjDls6+YGAF2hAifE1E5U1+b4tH6K github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= github.com/hashicorp/go-safetemp v1.0.0/go.mod h1:oaerMy3BhqiTbVye6QuFhFtIceqFoDHxNAB65b+Rj1I= +github.com/hashicorp/go-version v1.1.0 h1:bPIoEKD27tNdebFGGxxYwcL4nepeY4j1QP23PFRGzg0= github.com/hashicorp/go-version v1.1.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/jellevandenhooff/dkim v0.0.0-20150330215556-f50fe3d243e1/go.mod h1:E0B/fFc00Y+Rasa88328GlI/XbtyysCtTHZS8h7IrBU= github.com/jmespath/go-jmespath v0.0.0-20160202185014-0b12d6b521d8 h1:12VvqtR6Aowv3l/EQUlocDHW2Cp4G9WJVH7uyH8QFJE=