From 2c0c8cefa4d3a0fb53798695af518e0d21c4a3aa Mon Sep 17 00:00:00 2001 From: Max Horstmann Date: Fri, 13 Nov 2020 10:01:22 -0500 Subject: [PATCH] Go version: run build checks & tests (#317) --- .github/workflows/build.yml | 29 +++++++++++++++++++++++++++++ README.md | 3 ++- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..73e1a63 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,29 @@ +name: build + +on: + pull_request: + branches: [ master ] + push: + branches: [ master ] + +jobs: + + build: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: ^1.15 + - name: Build binaries + working-directory: cmd/blackbox + run: go build + - name: Run unit tests + run: go test ./... + - name: Run integration tests + working-directory: integrationTest + run: umask 0027 ; rm -rf /tmp/bbhome-* && go test -long -nocleanup diff --git a/README.md b/README.md index 3aaa5f2..2a63755 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ -BlackBox [![CircleCI](https://circleci.com/gh/StackExchange/blackbox.svg?style=shield)](https://circleci.com/gh/StackExchange/workflows/blackbox) +BlackBox [![CircleCI](https://circleci.com/gh/StackExchange/blackbox.svg?style=shield)](https://circleci.com/gh/StackExchange/workflows/blackbox) [![Build Status](https://github.com/StackExchange/blackbox/workflows/build/badge.svg)](https://github.com/StackExchange/blackbox/actions?query=workflow%3Abuild+branch%3Amaster) + ======== Safely store secrets in a VCS repo (i.e. Git, Mercurial, Subversion or Perforce). These commands make it easy for you to Gnu Privacy Guard (GPG) encrypt specific files in a repo so they are "encrypted at rest" in your repository. However, the scripts make it easy to decrypt them when you need to view or edit them, and decrypt them for use in production. Originally written for Puppet, BlackBox now works with any Git or Mercurial repository.