summaryrefslogtreecommitdiff
path: root/dev-vcs/git-imerge
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-vcs/git-imerge
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-vcs/git-imerge')
-rw-r--r--dev-vcs/git-imerge/Manifest4
-rw-r--r--dev-vcs/git-imerge/files/git-imerge.bashcomplete267
-rw-r--r--dev-vcs/git-imerge/git-imerge-1.0.0.ebuild45
-rw-r--r--dev-vcs/git-imerge/metadata.xml8
4 files changed, 324 insertions, 0 deletions
diff --git a/dev-vcs/git-imerge/Manifest b/dev-vcs/git-imerge/Manifest
new file mode 100644
index 000000000000..15ade50fdb08
--- /dev/null
+++ b/dev-vcs/git-imerge/Manifest
@@ -0,0 +1,4 @@
+AUX git-imerge.bashcomplete 4714 BLAKE2B 5e994a45e4d243611078a8f9d08019d24ce9ab80d4f59502e47bca94baadf122e8ae9a6218b58c4268a783cc5d7e03bee7bf26d8a39d853a9bd3ac3edb189133 SHA512 a1399072ca9a775acc4ceebbb2c13c1608687df68f01b407e1b3ff8f9ce01e748025ac02d88bf210af609206ffd0f6e578495b3c2a66bdddf9793210714c1b42
+DIST git-imerge-1.0.0.tar.gz 58736 BLAKE2B 16665436d10d07058eeadab5d53a2325d68174f6fcf1748948d0fc4fbe11ab4fca87853bb557e167b0f485351aedd72889fcedaa70f09439d7e66b75a61d318b SHA512 919b80f157d635e3a3eb2b05cfaf8f6a7034fe6f43529c829fef0152007bce3bf5b296cc00f6db0c0a711bfb9e118c4adb0f5a2641ff841c973ff12610473e9b
+EBUILD git-imerge-1.0.0.ebuild 1071 BLAKE2B aeb219159159150dc184a8f11d701d6a5c9f1ce1c7ed07dacd1d40cffd358df986817f179ec1b898272d6f5de001a8ffad30ad4fd7050786afb7e8a5fb3001fa SHA512 58ad713ad457416256406264bbced5fca2264c43bd479f8ab2d9da0fe7ed0c3b42e3b6b8b62d8334f1a942f63d93a65a3714a03c5bbd576f1824863d005476e8
+MISC metadata.xml 250 BLAKE2B f77aee69210d3e363a8b53c018b9e998e521b273b6e10451a467bcefd917fa2f6c3443000b603ab6355bfbd091b4b366f869ca5e8e695f9846634683309aef48 SHA512 c5b2424b4f6fdfbe8267055899a39cd14d992aaea9fc8dc6d007ee495e97a2d4125a9abad94c17a4c646521759fa998a3468dae0ac4d8b12c09926fc24e7403f
diff --git a/dev-vcs/git-imerge/files/git-imerge.bashcomplete b/dev-vcs/git-imerge/files/git-imerge.bashcomplete
new file mode 100644
index 000000000000..0fe8e04f64de
--- /dev/null
+++ b/dev-vcs/git-imerge/files/git-imerge.bashcomplete
@@ -0,0 +1,267 @@
+__git_imerge_branches () {
+ git for-each-ref --format='%(refname)' refs/heads/ refs/remotes/ 2>/dev/null |
+ sed -e 's!^refs/heads/!!' -e 's!^refs/remotes/!!'
+}
+
+__git_imerge_names () {
+ git for-each-ref --format='%(refname)' refs/imerge/ 2>/dev/null |
+ sed -e 's/^refs\/imerge\/\(.*\)\/.*/\1/' -e '/manual/d' -e '/auto/d'
+}
+
+__git_imerge_goals="\
+merge
+rebase
+rebase-with-history
+full
+"
+
+__git_imerge_commands="\
+start
+merge
+rebase
+continue
+finish
+diagram
+list
+init
+record
+autofill
+simplify
+remove
+reparent
+"
+
+__git_imerge_start_options="\
+--help
+--manual
+--name
+--branch
+--goal
+--first-parent
+"
+
+__git_imerge_init_options=$__git_imerge_start_options
+
+__git_imerge_continue_options="\
+--help
+--name
+--edit
+--no-edit
+"
+
+__git_imerge_finish_options="\
+--help
+--name
+--goal
+--branch
+--force
+"
+
+__git_imerge_simplify_options=$__git_imerge_finish_options
+
+__git_imerge_merge_options="\
+--help
+--name
+--goal
+--branch
+--manual
+"
+
+__git_imerge_list_options="\
+--help
+"
+
+__git_imerge_reparent_options=$__git_imerge_list_options
+
+__git_imerge_record_options="\
+--help
+--name
+--edit
+--no-edit
+"
+
+__git_imerge_autofill_options="\
+--help
+--name
+"
+
+__git_imerge_diagram_options="\
+--help
+--name
+--commits
+--frontier
+--html
+--color
+--no-color
+"
+
+__git_imerge_remove_options=$__git_imerge_autofill_options
+
+__git_imerge_rebase_options=$__git_imerge_merge_options
+
+__git-imerge_start_completion() {
+ case "$1_$cur" in
+ --help_|--branch_|_--branch=|--name_|_--name=)
+ return
+ ;;
+ --goal_*|*_--goal=*)
+ __gitcomp "$__git_imerge_goals" "" "${cur##--goal=}"
+ return
+ ;;
+ *-|*_-*?)
+ __gitcomp "$__git_imerge_start_options"
+ return
+ ;;
+ esac
+ __gitcomp "$(__git_imerge_branches)"
+}
+
+__git-imerge_init_completion() {
+ __git-imerge_start_completion $1
+}
+
+__git-imerge_continue_completion() {
+ case "$1_$cur" in
+ --help_)
+ return
+ ;;
+ --name_*|*_--name=*)
+ __gitcomp "$(__git_imerge_names)" "" "${cur##--name=}"
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_continue_options"
+}
+
+__git-imerge_finish_completion() {
+ case "$1_$cur" in
+ --help_)
+ return
+ ;;
+ --goal_*|*_--goal=*)
+ __gitcomp "$__git_imerge_goals" "" "${cur##--goal=}"
+ return
+ ;;
+ --branch_*|*_--branch=*)
+ __gitcomp "$(__git_imerge_branches)" "" "${cur##--branch=}"
+ return
+ ;;
+ --name_*|*_--name=*)
+ __gitcomp "$(__git_imerge_names)" "" "${cur##--name=}"
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_finish_options"
+}
+
+__git-imerge_simplify_completion() {
+ __git-imerge_finish_completion $1
+}
+
+__git-imerge_merge_completion() {
+ case "$1_$cur" in
+ --help_|--branch_|_--branch=|--name_|_--name=)
+ return
+ ;;
+ --goal_*|*_--goal=*)
+ __gitcomp "$__git_imerge_goals" "" "${cur##--goal=}"
+ return
+ ;;
+ *-|*_-*?)
+ __gitcomp "$__git_imerge_merge_options"
+ return
+ ;;
+ esac
+ __gitcomp "$(__git_imerge_branches)"
+}
+
+__git-imerge_rebase_completion() {
+ __git-imerge_merge_completion $1
+}
+
+__git-imerge_list_completion() {
+ case "$1" in
+ --help)
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_list_options"
+}
+
+__git-imerge_reparent_completion() {
+ __git-imerge_list_completion $1
+}
+
+__git-imerge_record_completion() {
+ case "$1_$cur" in
+ --help_)
+ return
+ ;;
+ --name_*|*_--name=*)
+ __gitcomp "$(__git_imerge_names)" "" "${cur##--name=}"
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_record_options"
+}
+
+__git-imerge_autofill_completion() {
+ case "$1_$cur" in
+ --help_)
+ return
+ ;;
+ --name_*|*_--name=*)
+ __gitcomp "$(__git_imerge_names)" "" "${cur##--name=}"
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_autofill_options"
+}
+
+__git-imerge_remove_completion() {
+ __git-imerge_autofill_completion $1
+}
+
+__git-imerge_diagram_completion() {
+ case "$1_$cur" in
+ --help_|--html_|_--html=)
+ return
+ ;;
+ --name_*|*_--name=*)
+ __gitcomp "$(__git_imerge_names)" "" "${cur##--name=}"
+ return
+ ;;
+ esac
+ __gitcomp "$__git_imerge_diagram_options"
+}
+
+_git_imerge () {
+ # Disable default filename completion. Note that "compopt" is only
+ # available in Bash 4 and newer, so we check for existence before
+ # trying to use it.
+ type compopt >/dev/null 2>&1 && compopt +o default +o bashdefault
+
+ local i command cur_opt
+ for ((i=0; i <= ${cword}; i++)); do
+ if [ -n "$command" ] && [ "${words[i]}" != "$cur" ]; then
+ cur_opt="${words[i]}"
+ fi
+ if [ -z "$command" ] && \
+ [ "$i" -lt "${cword}" ] && \
+ [[ "${words[i-1]}" == *"imerge"* ]]
+ then
+ command="${words[i]}"
+ fi
+ done
+
+ if test -z "$command"; then
+ __gitcomp "$__git_imerge_commands"
+ return
+ fi
+
+ if [ -z `type -t __git-imerge_"$command"_completion "$cur_opt"` ]; then
+ return
+ fi
+
+ __git-imerge_"$command"_completion "$cur_opt"
+}
diff --git a/dev-vcs/git-imerge/git-imerge-1.0.0.ebuild b/dev-vcs/git-imerge/git-imerge-1.0.0.ebuild
new file mode 100644
index 000000000000..249da409f76c
--- /dev/null
+++ b/dev-vcs/git-imerge/git-imerge-1.0.0.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
+
+inherit bash-completion-r1 python-r1
+
+DESCRIPTION="Incremental merge for git"
+HOMEPAGE="https://github.com/mhagger/git-imerge"
+SRC_URI="${HOMEPAGE}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RDEPEND="${PYTHON_DEPS}
+ dev-vcs/git"
+DEPEND="dev-python/docutils"
+
+src_compile() {
+ for doc in *.rst; do
+ rst2html.py "${doc}" > "${T}/${doc/.rst/.html}" \
+ || die "failed to convert ${doc} to ${T}/${doc/.rst/.html}"
+ done
+
+ rst2s5.py \
+ --theme=small-white \
+ --current-slide \
+ doc/presentations/GitMerge-2013/talk.rst \
+ "${T}/talk.html" \
+ || die 'failed to convert talk.rst to ${T}/talk.html'
+}
+
+src_install() {
+ python_foreach_impl python_doscript "${PN}"
+ newbashcomp "${FILESDIR}/git-imerge.bashcomplete" git-imerge
+ dodoc *.rst "${T}"/*.html
+
+ # Don't forget the CSS for the presentation.
+ dodoc -r "${T}/ui"
+}
diff --git a/dev-vcs/git-imerge/metadata.xml b/dev-vcs/git-imerge/metadata.xml
new file mode 100644
index 000000000000..33aa1137112c
--- /dev/null
+++ b/dev-vcs/git-imerge/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <!-- maintainer-needed -->
+ <upstream>
+ <remote-id type="github">mhagger/git-imerge</remote-id>
+ </upstream>
+</pkgmetadata>