mirror of
https://github.com/thegeeklab/drone-github-comment.git
synced 2024-11-25 20:20:38 +00:00
fix versioning
This commit is contained in:
parent
8c6fd000e3
commit
c515a891a3
@ -83,10 +83,9 @@ local PipelineBuildBinaries = {
|
|||||||
name: 'build',
|
name: 'build',
|
||||||
image: 'techknowlogick/xgo:go-1.14.x',
|
image: 'techknowlogick/xgo:go-1.14.x',
|
||||||
commands: [
|
commands: [
|
||||||
'[ -z "${DRONE_TAG}" ] && BUILD_VERSION=${DRONE_COMMIT_SHA:0:8} || BUILD_VERSION=${DRONE_TAG##v}',
|
'[ -z "$${DRONE_TAG}" ] && BUILD_VERSION=$${DRONE_COMMIT_SHA:0:8} || BUILD_VERSION=$${DRONE_TAG##v}',
|
||||||
'mkdir -p release/',
|
'mkdir -p release/',
|
||||||
"cd cmd/drone-github-comment && xgo -ldflags \"-s -w -X main.Version=$BUILD_VERSION\" -tags netgo -targets 'linux/amd64,linux/arm-6,linux/arm64' -out drone-github-comment .",
|
"cd cmd/drone-github-comment && xgo -ldflags \"-s -w -X main.Version=$$BUILD_VERSION\" -tags netgo -targets 'linux/amd64,linux/arm-6,linux/arm64' -out drone-github-comment .",
|
||||||
'ls -la /build/',
|
|
||||||
'mv /build/* /drone/src/release/',
|
'mv /build/* /drone/src/release/',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
@ -113,6 +112,24 @@ local PipelineBuildBinaries = {
|
|||||||
'cd release/ && sha256sum * > sha256sum.txt',
|
'cd release/ && sha256sum * > sha256sum.txt',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'publish',
|
||||||
|
image: 'plugins/github-release',
|
||||||
|
settings: {
|
||||||
|
overwrite: true,
|
||||||
|
api_key: {
|
||||||
|
from_secret: 'github_token',
|
||||||
|
},
|
||||||
|
files: ['release/*'],
|
||||||
|
title: '${DRONE_TAG}',
|
||||||
|
note: 'CHANGELOG.md',
|
||||||
|
},
|
||||||
|
when: {
|
||||||
|
ref: [
|
||||||
|
'refs/tags/**',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
},
|
||||||
],
|
],
|
||||||
depends_on: [
|
depends_on: [
|
||||||
'test',
|
'test',
|
||||||
@ -241,7 +258,7 @@ local PipelineNotifications = {
|
|||||||
from_secret: 'docker_username',
|
from_secret: 'docker_username',
|
||||||
},
|
},
|
||||||
PUSHRM_FILE: 'README.md',
|
PUSHRM_FILE: 'README.md',
|
||||||
PUSHRM_SHORT: 'Drone CI - Plugin to add comments to GitHub Issues/PRs',
|
PUSHRM_SHORT: 'GitHub Comment - Drone plugin to add comments to GitHub Issues/PRs',
|
||||||
PUSHRM_TARGET: 'thegeeklab/${DRONE_REPO_NAME}',
|
PUSHRM_TARGET: 'thegeeklab/${DRONE_REPO_NAME}',
|
||||||
},
|
},
|
||||||
when: {
|
when: {
|
||||||
|
23
.drone.yml
23
.drone.yml
@ -61,10 +61,9 @@ steps:
|
|||||||
- name: build
|
- name: build
|
||||||
image: techknowlogick/xgo:go-1.14.x
|
image: techknowlogick/xgo:go-1.14.x
|
||||||
commands:
|
commands:
|
||||||
- "[ -z \"${DRONE_TAG}\" ] && BUILD_VERSION=${DRONE_COMMIT_SHA:0:8} || BUILD_VERSION=${DRONE_TAG##v}"
|
- "[ -z \"$${DRONE_TAG}\" ] && BUILD_VERSION=$${DRONE_COMMIT_SHA:0:8} || BUILD_VERSION=$${DRONE_TAG##v}"
|
||||||
- mkdir -p release/
|
- mkdir -p release/
|
||||||
- cd cmd/drone-github-comment && xgo -ldflags "-s -w -X main.Version=$BUILD_VERSION" -tags netgo -targets 'linux/amd64,linux/arm-6,linux/arm64' -out drone-github-comment .
|
- cd cmd/drone-github-comment && xgo -ldflags "-s -w -X main.Version=$$BUILD_VERSION" -tags netgo -targets 'linux/amd64,linux/arm-6,linux/arm64' -out drone-github-comment .
|
||||||
- ls -la /build/
|
|
||||||
- mv /build/* /drone/src/release/
|
- mv /build/* /drone/src/release/
|
||||||
|
|
||||||
- name: executable
|
- name: executable
|
||||||
@ -84,6 +83,20 @@ steps:
|
|||||||
commands:
|
commands:
|
||||||
- cd release/ && sha256sum * > sha256sum.txt
|
- cd release/ && sha256sum * > sha256sum.txt
|
||||||
|
|
||||||
|
- name: publish
|
||||||
|
image: plugins/github-release
|
||||||
|
settings:
|
||||||
|
api_key:
|
||||||
|
from_secret: github_token
|
||||||
|
files:
|
||||||
|
- release/*
|
||||||
|
note: CHANGELOG.md
|
||||||
|
overwrite: true
|
||||||
|
title: ${DRONE_TAG}
|
||||||
|
when:
|
||||||
|
ref:
|
||||||
|
- refs/tags/**
|
||||||
|
|
||||||
trigger:
|
trigger:
|
||||||
ref:
|
ref:
|
||||||
- refs/heads/master
|
- refs/heads/master
|
||||||
@ -366,7 +379,7 @@ steps:
|
|||||||
DOCKER_USER:
|
DOCKER_USER:
|
||||||
from_secret: docker_username
|
from_secret: docker_username
|
||||||
PUSHRM_FILE: README.md
|
PUSHRM_FILE: README.md
|
||||||
PUSHRM_SHORT: Drone CI - Plugin to add comments to GitHub Issues/PRs
|
PUSHRM_SHORT: GitHub Comment - Drone plugin to add comments to GitHub Issues/PRs
|
||||||
PUSHRM_TARGET: thegeeklab/${DRONE_REPO_NAME}
|
PUSHRM_TARGET: thegeeklab/${DRONE_REPO_NAME}
|
||||||
when:
|
when:
|
||||||
status:
|
status:
|
||||||
@ -416,6 +429,6 @@ depends_on:
|
|||||||
|
|
||||||
---
|
---
|
||||||
kind: signature
|
kind: signature
|
||||||
hmac: 14cc8682d5c27ee5548f9596f5778b82f331b5c2d5e2a816b874ae7682524335
|
hmac: 0d83e319e617c570b761092c701b6b7a12607fcde2fcff0e007f536c8e11c6c0
|
||||||
|
|
||||||
...
|
...
|
||||||
|
55
.github/settings.yml
vendored
Normal file
55
.github/settings.yml
vendored
Normal file
@ -0,0 +1,55 @@
|
|||||||
|
repository:
|
||||||
|
name: drone-github-comment
|
||||||
|
description: GitHub Comment - Dron plugin to add comments to GitHub Issues/PRs
|
||||||
|
topics: drone, drone-plugin
|
||||||
|
|
||||||
|
private: false
|
||||||
|
has_issues: true
|
||||||
|
has_wiki: false
|
||||||
|
has_downloads: true
|
||||||
|
|
||||||
|
default_branch: master
|
||||||
|
|
||||||
|
allow_squash_merge: true
|
||||||
|
allow_merge_commit: true
|
||||||
|
allow_rebase_merge: true
|
||||||
|
|
||||||
|
labels:
|
||||||
|
- name: bug
|
||||||
|
color: d73a4a
|
||||||
|
description: Something isn't working
|
||||||
|
- name: documentation
|
||||||
|
color: 0075ca
|
||||||
|
description: Improvements or additions to documentation
|
||||||
|
- name: duplicate
|
||||||
|
color: cfd3d7
|
||||||
|
description: This issue or pull request already exists
|
||||||
|
- name: enhancement
|
||||||
|
color: a2eeef
|
||||||
|
description: New feature or request
|
||||||
|
- name: good first issue
|
||||||
|
color: 7057ff
|
||||||
|
description: Good for newcomers
|
||||||
|
- name: help wanted
|
||||||
|
color: 008672
|
||||||
|
description: Extra attention is needed
|
||||||
|
- name: invalid
|
||||||
|
color: e4e669
|
||||||
|
description: This doesn't seem right
|
||||||
|
- name: question
|
||||||
|
color: d876e3
|
||||||
|
description: Further information is requested
|
||||||
|
- name: wontfix
|
||||||
|
color: ffffff
|
||||||
|
description: This will not be worked on
|
||||||
|
|
||||||
|
branches:
|
||||||
|
- name: master
|
||||||
|
protection:
|
||||||
|
required_pull_request_reviews: null
|
||||||
|
required_status_checks:
|
||||||
|
strict: true
|
||||||
|
contexts:
|
||||||
|
- continuous-integration/drone/pr
|
||||||
|
enforce_admins: null
|
||||||
|
restrictions: null
|
@ -1,12 +1,12 @@
|
|||||||
# drone-github-comment
|
# drone-github-comment
|
||||||
|
|
||||||
Drone CI - Plugin to add comments to GitHub Issues/PRs
|
GitHub Comment - Drone plugin to add comments to GitHub Issues/PRs
|
||||||
|
|
||||||
[![Build Status](https://img.shields.io/drone/build/thegeeklab/drone-github-comment?logo=drone)](https://cloud.drone.io/thegeeklab/drone-github-comment)
|
[![Build Status](https://img.shields.io/drone/build/thegeeklab/drone-github-comment?logo=drone)](https://cloud.drone.io/thegeeklab/drone-github-comment)
|
||||||
[![Docker Hub](https://img.shields.io/badge/dockerhub-latest-blue.svg?logo=docker&logoColor=white)](https://hub.docker.com/r/thegeeklab/drone-github-comment)
|
[![Docker Hub](https://img.shields.io/badge/dockerhub-latest-blue.svg?logo=docker&logoColor=white)](https://hub.docker.com/r/thegeeklab/drone-github-comment)
|
||||||
[![Quay.io](https://img.shields.io/badge/quay-latest-blue.svg?logo=docker&logoColor=white)](https://quay.io/repository/thegeeklab/drone-github-comment)
|
[![Quay.io](https://img.shields.io/badge/quay-latest-blue.svg?logo=docker&logoColor=white)](https://quay.io/repository/thegeeklab/drone-github-comment)
|
||||||
[![Source: GitHub](https://img.shields.io/badge/source-github-blue.svg?logo=github&logoColor=white)](https://github.com/thegeeklab/drone-github-comment)
|
[![Source: GitHub](https://img.shields.io/badge/source-github-blue.svg?logo=github&logoColor=white)](https://github.com/thegeeklab/drone-github-comment)
|
||||||
[![License: MIT](https://img.shields.io/github/license/thegeeklab/drone-github-comment)]([LICENSE](https://github.com/thegeeklab/drone-github-comment/blob/master/LICENSE))
|
[![License: MIT](https://img.shields.io/github/license/thegeeklab/drone-github-comment)](<[LICENSE](https://github.com/thegeeklab/drone-github-comment/blob/master/LICENSE)>)
|
||||||
|
|
||||||
Drone plugin to add comments to GitHub Issues/PR's.
|
Drone plugin to add comments to GitHub Issues/PR's.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user