Skip to content

Commit

Permalink
Auto badge (#346)
Browse files Browse the repository at this point in the history
* Update badges

* Update badges
  • Loading branch information
osterman committed Mar 20, 2020
1 parent c406306 commit 8c3eb28
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@

[![Cloud Posse][logo]](https://cpco.io/homepage)

# Packages [![Codefresh Build Status](https://g.codefresh.io/api/badges/pipeline/cloudposse/cloudposse%2Fpackages%2Fapk?type=cf-1)](https://g.codefresh.io/public/accounts/cloudposse/pipelines/5baae099b35f251ecadf1fa0) [![Latest Release](https://img.shields.io/github/release/cloudposse/packages.svg)](https://github.com/cloudposse/packages/releases/latest) [![Slack Community](https://slack.cloudposse.com/badge.svg)](https://slack.cloudposse.com)
# Packages [![Codefresh Build Status](https://g.codefresh.io/api/badges/pipeline/cloudposse/cloudposse%2Fpackages%2Fapk?branch=master&key=eyJhbGciOiJIUzI1NiJ9.NWEwMTJmNWM3Yjg3YTQwMDAxYTlkMjU0.UwxTSXZGXq3wPQjj3O1k71kQsGuWGlzgkp9V2-llce8&type=cf-1)](https://g.codefresh.io/pipelines/apk/builds?repoOwner=cloudposse&repoName=packages&serviceName=cloudposse%2Fpackages&filter=trigger:build~Build;branch:master;pipeline:5baae099b35f251ecadf1fa0~apk) [![Auto Update Status](https://github.com/cloudposse/packages/workflows/auto-update/badge.svg)](https://github.com/cloudposse/packages/actions?query=workflow%3Aauto-update) [![Latest Release](https://img.shields.io/github/release/cloudposse/packages.svg)](https://github.com/cloudposse/packages/releases/latest) [![Slack Community](https://slack.cloudposse.com/badge.svg)](https://slack.cloudposse.com)


Cloud Posse distribution of awesome apps.
Expand Down
7 changes: 5 additions & 2 deletions README.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,11 @@ github_repo: cloudposse/packages
# Badges to display
badges:
- name: "Codefresh Build Status"
image: "https://g.codefresh.io/api/badges/pipeline/cloudposse/cloudposse%2Fpackages%2Fapk?type=cf-1"
url: "https://g.codefresh.io/public/accounts/cloudposse/pipelines/5baae099b35f251ecadf1fa0"
image: "https://g.codefresh.io/api/badges/pipeline/cloudposse/cloudposse%2Fpackages%2Fapk?branch=master&key=eyJhbGciOiJIUzI1NiJ9.NWEwMTJmNWM3Yjg3YTQwMDAxYTlkMjU0.UwxTSXZGXq3wPQjj3O1k71kQsGuWGlzgkp9V2-llce8&type=cf-1"
url: "https://g.codefresh.io/pipelines/apk/builds?repoOwner=cloudposse&repoName=packages&serviceName=cloudposse%2Fpackages&filter=trigger:build~Build;branch:master;pipeline:5baae099b35f251ecadf1fa0~apk"
- name: "Auto Update Status"
image: "https://github.com/cloudposse/packages/workflows/auto-update/badge.svg"
url: "https://github.com/cloudposse/packages/actions?query=workflow%3Aauto-update"
- name: "Latest Release"
image: "https://img.shields.io/github/release/cloudposse/packages.svg"
url: "https://github.com/cloudposse/packages/releases/latest"
Expand Down
2 changes: 1 addition & 1 deletion tasks/Makefile.package
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ auto-update:
# Update the VERSION file only if it would change, to avoid triggering unnecessary builds
CURRENT_VERSION: API=releases/latest
CURRENT_VERSION: QUERY=.tag_name
CURRENT_VERSION:
CURRENT_VERSION::
@local_version=$$(cat VERSION || echo 0); \
current_version=$$(env PATH='$(PATH)' github-repo-metadata $(VENDOR) $(PACKAGE_REPO_NAME) '$(API)' '$(QUERY)' | sed 's/^v//'); \
if [ $$? -ne 0 ]; then \
Expand Down
2 changes: 1 addition & 1 deletion vendor/sentinel/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export PACKAGE_NAME ?= sentinel
export DOWNLOAD_URL ?= https://releases.hashicorp.com/$(PACKAGE_NAME)/$(PACKAGE_VERSION)/$(PACKAGE_NAME)_$(PACKAGE_VERSION)_$(OS)_$(ARCH).zip
export APK_BUILD_TEMPLATE ?= APKBUILD.github-binary

CURRENT_VERSION:
CURRENT_VERSION::
@local_version=$$(cat VERSION || echo 0); \
current_version=$$(curl -s "https://releases.hashicorp.com/$(PACKAGE_NAME)/" | sed -nE 's/.*\<a\shref=\"\/sentinel\/(\d+\.\d+\.\d+)\/.*/\1/pi' | head -n 1); \
if [ $$? -ne 0 ]; then \
Expand Down

0 comments on commit 8c3eb28

Please sign in to comment.