forked from Ether1Project/Ethoprotocol
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f709408
commit 7328c35
Showing
1 changed file
with
61 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,70 @@ | ||
# Golang CircleCI 2.0 configuration file | ||
# | ||
# Check https://circleci.com/docs/2.0/language-go/ for more details | ||
# | ||
# Credit Fractalyse (CuBe) | ||
# | ||
version: 2.1 | ||
jobs: | ||
build: | ||
|
||
docker: | ||
- image: circleci/golang:1.14 | ||
|
||
working_directory: /go/src/github.com/{{ORG_NAME}}/{{REPO_NAME}} | ||
- image: circleci/golang:1.16.9 | ||
steps: | ||
- checkout | ||
- run: | ||
name: "Compile" | ||
command: | ||
make geth | ||
prerelease: | ||
docker: | ||
- image: circleci/golang:1.16.9 | ||
steps: | ||
- checkout | ||
- run: | ||
name: "Compile" | ||
command: make geth | ||
- run: | ||
name: "Make tar PreRelease and publish" | ||
command: | | ||
cd build/bin | ||
VERSION=$(./geth version | grep "^Version:" | cut -d' ' -f2 | cut -d'-' -f1) | ||
echo $VERSION | ||
tar -cvjf etho-linux-V${VERSION}-test.tar.gz geth && rm geth | ||
go get github.com/tcnksm/ghr | ||
ghr -t "${GITHUB_TOKEN}" -u "${CIRCLE_PROJECT_USERNAME}" -r "${CIRCLE_PROJECT_REPONAME}" -c "${CIRCLE_SHA1}" -delete -n "${CIRCLE_BRANCH}" -b "***FOR TESTING PURPOSE ONLY***" --prerelease "V${VERSION}-test" ./ | ||
release: | ||
docker: | ||
- image: circleci/golang:1.16.9 | ||
steps: | ||
- checkout | ||
# specify any bash command here prefixed with `run: ` | ||
- run: make geth && cd build/bin && sudo apt-get install zip && zip ether-1-linux-1.3.2.zip geth | ||
- store_artifacts: | ||
path: build/bin/ | ||
- run: | ||
name: "Make tar Release and publish" | ||
command: | | ||
make geth | ||
cd build/bin | ||
VERSION=$(./geth version | grep "^Version:" | cut -d' ' -f2 | cut -d'-' -f1) | ||
echo $VERSION | ||
tar -cvjf etho-linux-V${VERSION}.tar.gz geth && rm geth | ||
go get github.com/tcnksm/ghr | ||
ghr -t "${GITHUB_TOKEN}" -u "${CIRCLE_PROJECT_USERNAME}" -r "${CIRCLE_PROJECT_REPONAME}" -c "${CIRCLE_SHA1}" -delete "V${VERSION}" ./ | ||
workflows: | ||
version: 2.1 | ||
main: | ||
jobs: | ||
- build: | ||
filters: | ||
branches: | ||
ignore: | ||
- HyperCube-testnet | ||
- master | ||
- fix-circleci-builds | ||
- prerelease: | ||
filters: | ||
branches: | ||
only: | ||
- HyperCube-testnet | ||
- release: | ||
filters: | ||
branches: | ||
only: | ||
- master |