From 334f75fd2a167731b74f08a40dad00db77b71802 Mon Sep 17 00:00:00 2001 From: Umair Idris Date: Tue, 27 Oct 2020 16:27:43 -0400 Subject: [PATCH 1/4] Delete build.sh (#88) This has been replaced by Github Actions. --- build.sh | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100755 build.sh diff --git a/build.sh b/build.sh deleted file mode 100755 index b8dcdf8..0000000 --- a/build.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -# Usage: ./build.sh -o /tmp/cdap_provider -v v1.0.0 - -set -e - -OUTPUT_DIR="." -VERSION="" - -while getopts 'o:v:' c -do - case $c in - o) OUTPUT_DIR=${OPTARG} ;; - v) VERSION=${OPTARG} ;; - *) - echo "Invalid flag ${OPTARG}" - exit 1 - ;; - esac -done - -if [[ -z ${VERSION} ]]; then - echo "-v must be set" - exit 1 -fi - -SUPPORTED_OS=("linux" "darwin" "windows") -ARCH="amd64" - -for OS in "${SUPPORTED_OS[@]}" -do - output_name="terraform-provider-cdap_${VERSION}_${OS}-${ARCH}" - echo "Building ${output_name}" - env GOOS="${OS}" GOARCH="${ARCH}" go build -o "${OUTPUT_DIR}/${output_name}" -done From 7537b0c018b08c3e6078a398bb17a1d32e2da509 Mon Sep 17 00:00:00 2001 From: Umair Idris Date: Tue, 27 Oct 2020 16:42:43 -0400 Subject: [PATCH 2/4] Add releasing instructions (#87) #85 --- README.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/README.md b/README.md index 3f6a802..3a39d51 100644 --- a/README.md +++ b/README.md @@ -22,3 +22,28 @@ GCP Data Fusion specific helpers and modules can be found in the corresponding ## Contributing See [CONTRIBUTING.md](./CONTRIBUTING.md) + +## Releasing + +Automated releases are handled by Github Actions. + +1. Choose a version. It should match the regex `^v[0-9]+\.[0-9]+\.[0-9]+$`. + That is, a leading "v", followed by three period-separated numbers. + + ```bash + version="v0.1.0" + ``` + +1. Create the Git tag. + + For binaries: + + ```bash + git tag -a "${version}" -m "${version}" + ``` + +1. Push the tag: + + ```bash + git push origin --tags + ``` From c12d116d07f3349d65c30cb657788817b7beb10a Mon Sep 17 00:00:00 2001 From: Umair Idris Date: Tue, 27 Oct 2020 16:42:55 -0400 Subject: [PATCH 3/4] update install instructions (#89) --- docs/index.md | 15 +++++++++++++-- tools/generate_docs/templates/index.md.tmpl | 15 +++++++++++++-- 2 files changed, 26 insertions(+), 4 deletions(-) diff --git a/docs/index.md b/docs/index.md index 80ec7ae..d18f83b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,6 +1,17 @@ -The CDAP provider is used to configure your -[CDAP](https://docs.cdap.io/cdap/current/en/index.html) infrastructure. +Add the following block to your Terraform configs +(updating the version to the desired release): + +```hcl +terraform { + required_providers { + cdap = { + source = "GoogleCloudPlatform/cdap" + version = "~> 0.7.0" + } + } +} +``` ## Installation diff --git a/tools/generate_docs/templates/index.md.tmpl b/tools/generate_docs/templates/index.md.tmpl index 41d9f7b..d49f479 100644 --- a/tools/generate_docs/templates/index.md.tmpl +++ b/tools/generate_docs/templates/index.md.tmpl @@ -1,7 +1,18 @@ {{template "header" -}} -The CDAP provider is used to configure your -[CDAP](https://docs.cdap.io/cdap/current/en/index.html) infrastructure. +Add the following block to your Terraform configs +(updating the version to the desired release): + +```hcl +terraform { + required_providers { + cdap = { + source = "GoogleCloudPlatform/cdap" + version = "~> 0.7.0" + } + } +} +``` ## Installation From 739a20c0463e869cc3f51dc65e0d1c69772ae7fe Mon Sep 17 00:00:00 2001 From: Umair Idris Date: Tue, 27 Oct 2020 17:12:15 -0400 Subject: [PATCH 4/4] add dev instructions (#90) --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 3a39d51..08d71af 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,11 @@ GCP Data Fusion specific helpers and modules can be found in the corresponding See [CONTRIBUTING.md](./CONTRIBUTING.md) +## Development + +To build a local version of the provider, run `go build -o ${test_dir}` +where `test_dir` is the path to a directory hosting test Terraform configs. + ## Releasing Automated releases are handled by Github Actions.