#!/bin/sh set -evx branch=${DRONE_TAG:=$CI_COMMIT_BRANCH} branch=$(echo $branch | grep -v /) || echo $branch ; p1=$(echo $branch | cut -d / -f1 -s) && p2=$(echo $branch | cut -d / -f2 -s) && tag=${branch:=$p1-$p2} && echo "Publishing" $tag echo $DOCKER_PASSWORD | docker login git.pbiernat.dev -u $DOCKER_USERNAME --password-stdin && docker push git.pbiernat.dev/golang/vegvisir:$tag