From 2b64a22fdde1ad164ea9e3dae3777ec20900153e Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Tue, 2 Aug 2016 19:22:01 +0300 Subject: [PATCH] Make tag-with-version alias --- project_template/mk-tag-alias | 5 +++++ project_template/tag.vim | 9 +++++++++ 2 files changed, 14 insertions(+) create mode 100755 project_template/mk-tag-alias create mode 100644 project_template/tag.vim diff --git a/project_template/mk-tag-alias b/project_template/mk-tag-alias new file mode 100755 index 0000000..658fdbc --- /dev/null +++ b/project_template/mk-tag-alias @@ -0,0 +1,5 @@ +#!/bin/sh + +exec git config --local alias.tag-with-version \ + "!GIT_EDITOR='vim -c \"source tag.vim\"' \ + exec git tag -s \`python setup.py --version\`" diff --git a/project_template/tag.vim b/project_template/tag.vim new file mode 100644 index 0000000..27d311b --- /dev/null +++ b/project_template/tag.vim @@ -0,0 +1,9 @@ +set fileencoding=utf-8 +edit ChangeLog +normal 1G3yy +buffer 1 +normal 1GPf ;Da: +. +normal JJjdd +s/\.$// +update -- 2.39.5