From d3160bc18f118745db19958efe1c5135d9847d21 Mon Sep 17 00:00:00 2001 From: goloop Date: Mon, 14 Dec 2020 18:12:50 +0200 Subject: [PATCH] Update --- .module | 2 +- Makefile | 13 +++++++++++++ README.md | 2 +- 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/.module b/.module index a7f351d..84f2574 100644 --- a/.module +++ b/.module @@ -1,3 +1,3 @@ REPOSITORY_NAME=github.com/goloop MODULE_NAME=opt -VERSION=0.0.1 +VERSION=0.1.3 diff --git a/Makefile b/Makefile index e1f5a76..2c30b47 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,10 @@ Commands: Requires `godocdown`, install as: go get github.com/robertkrimen/godocdown/godocdown + git.commit + Update readme, create commit and update tag from the .module file. + + Usage as: make git.commit am="Commit message" endef # Constants. @@ -73,3 +77,12 @@ ifeq (, $(shell which godocdown)) endif @godocdown -plain=true -template=.godocdown.md ./ | \ sed -e 's/\.VERSION/${VERSION}/g' > README.md +git.commit: readme +ifeq ($(am),) + @echo "You must provide a message to commit as: make commit am='Commit message'" +else + @git add . && git commit -am "${am}" && \ + git tag v${VERSION} && \ + git push -u origin --all && \ + git push -u origin --tag +endif diff --git a/README.md b/README.md index 6afdba5..8a3206c 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ [![Go Report Card](https://goreportcard.com/badge/github.com/goloop/opt)](https://goreportcard.com/report/github.com/goloop/opt) [![License](https://img.shields.io/badge/license-BSD-blue)](https://github.com/goloop/opt/blob/master/LICENSE) [![License](https://img.shields.io/badge/godoc-YES-green)](https://godoc.org/github.com/goloop/opt) -*Version: 0.0.1* +*Version: 0.1.3* # opt