Giter Site home page Giter Site logo

bin's Introduction

bin

common scripts, templates and helpers for building and develpment

Lost art of the makefile

12 factor app is the philosophy

Semantic versioning support

semver which is based on this tool provides utility to manipulate semantic version strings from bash scripts.

syntax : semver bump (major|minor|patch|pre-release) <version>

Note: Version must be properly formatted as a semantic version string

Examples:

command output
./semver bump pre-release 10.0.0-RC.1 10.0.0-RC.2
./semver bump patch 10.0.0 10.0.1
./semver bump minor 10.0.0 10.1.0
./semver bump major 10.0.0 11.0.0

Note: ./semver bump pre-release will work only if the version has pre release part, eg 10.0.0-RC.2

build_functions.sh helpers

command output Note
incrementVersion patch 10.0.0 10.0.1 Helper method to increment version. It calls semver bump with given arguments
updateVersionProps 10.0.0-RC.1 updates the version.properties with given version string it expects version.properties in current directory

Example

source ./build_functions.sh
incrementVersion patch 10.0.0 #Will output 10.0.1
updateVersionProps 10.0.11 #Will update version.properties with version=10.0.11

Make file helpers

Make target Note
make version prints the version which will be released.
make update-version updates version.properties with new version
make git-tag Tags the current version and pushes to github
make release it depends on following targets update-version build/docker-build build/docker-deploy git-tag

so it will update the version, build docker image, push image to dockerhub and then create a git tag

Makefile.deploy-common-targets must have been included in the main make file of the target project eg. include /PATH-TO/Makefile.deploy-common-targets

Refs

links for using make and docker

versioning example

docker makefiles

bin's People

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

bin's Issues

automate release process for jars and docker

Story
As a dev and ci I want to have the same automated versioning mechanism and tagging on releases without needing gradle. As a dev I want to be able to do this versioning and tagging for docker images and in python project such as OCI.

The goal of this issue is to bascially duplicate the functionality that is in the shipyak gradle plugin that is based on shipkit. The bash script should follow https://semver.org
The bash script should follow same rules as the gradle-plugin we are using now that is based on shipkit

implement bash script for version update for automate release process for jars and docker

Right now when we deploy rcm to the client the war is created, versioned and released in repo.9ci.com , we tag it github and we can always either recreate it form the tag or just download from the repo.

With new implementation with docker we need similar automatic way of versioning our docker production releases.

take a look at the https://github.com/mvanholsteijn/docker-makefile example, we can do something similar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.