Robin Green [Sat, 9 Mar 2013 13:04:06 +0000 (9 13:04 +0000)]
Bumped version to 0.9; last minute doc changes
Signed-off-by: Robin Green <greenrd@greenrd.org>
Robin Green [Sat, 9 Mar 2013 11:51:28 +0000 (9 11:51 +0000)]
Documentation cleanup
Robin Green [Sat, 9 Mar 2013 07:11:24 +0000 (9 07:11 +0000)]
INSTALL: Added installation instructions
Heiko Hund [Thu, 12 Nov 2009 10:15:08 +0000 (12 10:15 +0000)]
--strip option for tg export
This introduces the '--strip[=N]' option for 'tg export --quilt' to enable
export of a flat quilt series, even if the tg branch names are structured
hierarchically.
It may be useful if you - like me - structure your topgit branches like
"t/<NN>/<NAME>" to keep the overview in git, but don't want the exported
quilt series to be spread across subdirectories.
In contrast to '--flatten' this option removes the first 'N' or all
subdirectories from the topgit branch name, while keeping compatible with
the existing options. The remaining ones can still be flattened. Patch
names can still get numbered.
Signed-off-by: Heiko Hund <hhund@astaro.com>
Signed-off-by: Robin Green <greenrd@greenrd.org>
Robin Green [Sat, 9 Mar 2013 00:06:44 +0000 (9 00:06 +0000)]
README: Fix obsolete references to git push
Signed-off-by: Robin Green <greenrd@greenrd.org>
Robin Green [Fri, 8 Mar 2013 23:07:49 +0000 (8 23:07 +0000)]
Merge branch 'master' of git://github.com/arvidjaar/topgit
Robin Green [Thu, 7 Mar 2013 21:28:11 +0000 (7 21:28 +0000)]
Make tg help work in any directory
Signed-off-by: Robin Green <greenrd@greenrd.org>
Andrey Borzenkov [Sat, 19 Mar 2011 16:53:11 +0000 (19 19:53 +0300)]
tg-update: check for detached state of current branch
Check that current branch is not detached if called "-a" so we
can return to it.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Sat, 19 Mar 2011 16:53:11 +0000 (19 19:53 +0300)]
tg-update: correctly return error for missing deps
Adding -a introduced following regression: no error was returned
after missing deps to allow continuing with next branch. This means
missing dependencies during recursion were ignored (althouth warning
was output). Always abort with error unless called with "-a";
recursive never does it.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Sat, 19 Mar 2011 16:53:10 +0000 (19 19:53 +0300)]
tg-update: allow skipping branch if recursion fails
This allows user to skip failed recursive update and continue
with current state. It makes it possible to continue after
missing depenndency (which was the silent default before).
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Sat, 19 Mar 2011 16:53:10 +0000 (19 19:53 +0300)]
tg: fix recursing with missing dependencies
In the following dependency chain:
t/1 => t/2 => t/3
with missing initial t/1 no error is was returned when attempting
to update t/3, because t/2 was assumed to be external origin that
does not need update.
Extend recurse_deps() API to inform driver about missing dependency
by setting $_dep_missing before calling.
Use it in branch_needs_update() to indicate missing deps by emitting
additional '!' and forcing tg-update.sh to recurse into parent and
fail due to missing dep. All other drivers were extended to check
for $_dep_missing and silently return (that is what happened anyway).
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Sat, 19 Mar 2011 07:53:59 +0000 (19 10:53 +0300)]
tg-update: document variables
Andrey Borzenkov [Fri, 18 Mar 2011 22:51:03 +0000 (19 01:51 +0300)]
README: really update documentation
Andrey Borzenkov [Fri, 18 Mar 2011 22:40:32 +0000 (19 01:40 +0300)]
tg-delete: simplistic check for dependency on deleted branch
Andrey Borzenkov [Fri, 18 Mar 2011 21:27:51 +0000 (19 00:27 +0300)]
tg-update: strip refs/top-bases/ from PATTERNs just in case
Andrey Borzenkov [Fri, 18 Mar 2011 21:26:05 +0000 (19 00:26 +0300)]
tg-update: clarify that there could be multiple PATTERNs
Andrey Borzenkov [Fri, 18 Mar 2011 17:47:28 +0000 (18 20:47 +0300)]
Merge branch 'x' into github
Andrey Borzenkov [Fri, 18 Mar 2011 17:46:27 +0000 (18 20:46 +0300)]
tg-update: add -a support for all branches
Allow branch filtering by pattern (same as git-for-each-ref(1))
Return to original branch after all branches were processed. In case
of error stays on last branch being processed.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Fri, 18 Mar 2011 17:27:49 +0000 (18 20:27 +0300)]
tg-export.sh: support tag objects as parent
Currently tg-export fails with
Collapsing u/quota-pull
fatal:
2770ca86dec8b9cc36bf50127e5aff7f29557e3c is not a valid 'commit' object
Check for and resolve tag objects for parent.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Fri, 18 Mar 2011 17:24:29 +0000 (18 20:24 +0300)]
tg.sh: check for removed branch in branch_annihilated
Check that branch was not deleted by external means; prevents
errors from further git commands due to non-existing refs.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Andrey Borzenkov [Fri, 18 Mar 2011 17:24:29 +0000 (18 20:24 +0300)]
tg-create: let format.signoff control adding of Signed-off-by
GIT manual stresses that adding of Signed-off-by should be explicit
user decision. Some projects do ask for no Signed-off-by lines. So
make sure it is added by tg-create.sh only when explicity requested
by user.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Uwe Kleine-König [Sun, 26 Dec 2010 12:20:26 +0000 (26 13:20 +0100)]
Merge commit 'index-wt~2' of git://repo.or.cz/topgit/bertw
Bert Wesarg [Fri, 8 Oct 2010 07:32:36 +0000 (8 09:32 +0200)]
tg-prev/tg-next: commands to explore dependencies
Two new commands to explore the dependencies of TopGit branches:
a) tg prev [-i | -w] [NAME]
outputs the dependencies of NAME
b) tg next [-i | -w] [NAME]
outputs branches which depends on NAME
Obviously, quilt next was the inspiration.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Sat, 9 Oct 2010 20:52:19 +0000 (9 22:52 +0200)]
tg-mail: accept -i/-w
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Thu, 7 Oct 2010 21:05:08 +0000 (7 23:05 +0200)]
tg-summary: accept -i/-w
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Tue, 26 Oct 2010 21:15:55 +0000 (26 23:15 +0200)]
list_deps: accept -i/-w
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Mon, 8 Nov 2010 07:25:33 +0000 (8 08:25 +0100)]
tg-patch: use pretty_tree and diff-tree to generate the patch
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Thu, 7 Oct 2010 19:54:22 +0000 (7 21:54 +0200)]
branch_empty: use pretty_tree and therefore respect -i/-w
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Mon, 8 Nov 2010 07:26:28 +0000 (8 08:26 +0100)]
tg-files: simplify arg checking and add sanity check for -i/-w
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Mon, 8 Nov 2010 07:25:10 +0000 (8 08:25 +0100)]
tg-export: use pretty_tree -b for base
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Bert Wesarg [Wed, 20 Oct 2010 20:17:47 +0000 (20 22:17 +0200)]
cat_file: take -i/-w parameters
This changes the way how cat_file selects the source of the file. It
accepts an optional parameter which is either -i or -w and will react on this
instead of the branch name. tg-patch is updated accordingly and can now
accepts the current branch name as argument with -i or -w given.
cat_file was also broken for the worktree case when we are not in the top level.
Also, tg-patch allowed to be on the top-base branch, but -i and -w doesn't
make sense there too.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Wed, 20 Oct 2010 20:17:46 +0000 (20 22:17 +0200)]
provide a global temporary directory
The standard procedure 'tmp=mktemp; trap "rm $tmp" 0' was broken with the
introduction of the pager. Which overwrites the trap itself to close and
remove the pager fifo.
Now tg provides a temp playground and all other temp files should be created
inside this directory and only this directory will be removed with the exit
trap. setup_pager still overwrites the trap, but keeps the rm command from
the global temp directory. To simplify this the new function get_temp() is
provided.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 2 Nov 2010 20:54:21 +0000 (2 21:54 +0100)]
README: clearify note describing short-comings of tg log
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 18:27:47 +0000 (4 20:27 +0200)]
tg-files: list files changed by the topic branch
this could also be a --name-only option to tg-patch. But I like the
similarity to 'quilt files'.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 21:22:17 +0000 (4 23:22 +0200)]
hooks/pre-commit: check for deps repetitions
A dep should only be listed once in .topdeps, force this.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 21:18:50 +0000 (4 23:18 +0200)]
hooks/pre-commit: check .topdeps for valid branches
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 21:07:27 +0000 (4 23:07 +0200)]
hooks/pre-commit: check for cycles in dependencies
We need only to consider newly added dependencies. For each of these deps we
need to check if there is a path from this dep to the current HEAD.
We use recursive_dep() for this task. Even if recursive_dep() uses a DFS
traversal it will not run into an endless loop if there would be a cycle,
because recursive_dep() takes .topdeps only from committed trees. And we
require that the committed dependency graph has no cycles.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 18:54:57 +0000 (4 20:54 +0200)]
hooks/pre-commit: check .top* files in the to-be-commited tree
We currently check fo these files only in the working tree. But we should check
what would be commited. We use write-tree to be able to utilize ls-tree and
check the result.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 18:47:01 +0000 (4 20:47 +0200)]
tg.sh: simplify cat_file
Use shell parameter expansion to strip the leading (w): and (i)
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Mon, 4 Oct 2010 19:06:29 +0000 (4 21:06 +0200)]
README: move note about shortcomings of using --first-parent from tg base to tg log
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Sun, 3 Oct 2010 21:25:57 +0000 (3 23:25 +0200)]
tg-log: short cut to git log
A short cut to show the history of a named topgit branch. Additional options
to git log can be given after a '--'.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Sun, 3 Oct 2010 21:25:56 +0000 (3 23:25 +0200)]
put die() messages to stderr
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Sun, 3 Oct 2010 21:25:53 +0000 (3 23:25 +0200)]
tg-remote: use default remote if none is given
This is useful if the remote has new topics and you need to populate the local
top-bases.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Sun, 3 Oct 2010 21:25:52 +0000 (3 23:25 +0200)]
Let tg-update take a branch parameter
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Olaf Dabrunz [Mon, 6 Sep 2010 00:02:54 +0000 (6 02:02 +0200)]
Add pointer about the problems regarding tg depend rm to README
Signed-off-by: Olaf Dabrunz <odabrunz@gmx.net>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Sun, 3 Oct 2010 21:41:45 +0000 (3 23:41 +0200)]
Indicate the current branch in "tg summary --graphviz"
Give the current branch a yellow background in the output of
"tg summary --graphviz".
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Sun, 3 Oct 2010 21:37:52 +0000 (3 23:37 +0200)]
Implement "tg summary --deps" as a shell function.
This avoids running "$tg summary --deps" from all commands that need
that information internally.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Mon, 6 Sep 2010 05:12:16 +0000 (6 07:12 +0200)]
Do basic error checking in "tg depend add"
Check for the following errors:
- Working on a non-TopGit branch.
- Adding a branch as a dependency of itself.
- Adding a dependency that introduces a loop.
- Adding a dependency that already exists.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Mon, 6 Sep 2010 05:12:16 +0000 (6 07:12 +0200)]
Refactor tg summary
Break out the normal processing performed when no options are given to
a shell function.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 24 Aug 2010 18:56:06 +0000 (24 20:56 +0200)]
Fix pretty_tree to work in a subdirectory
Without this change a freshly exported branch contains the .top* files
when tg export was started from a subdirectory.
Reported-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Tue, 24 Aug 2010 18:32:39 +0000 (24 20:32 +0200)]
Generalize subcommand selection in "tg depend"
Prepare "tg depend" for new subcommands by moving the implementation
of "tg add" to a function.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Tue, 24 Aug 2010 18:32:05 +0000 (24 20:32 +0200)]
Add "tg base" that prints the base version.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Tue, 24 Aug 2010 18:32:06 +0000 (24 20:32 +0200)]
Ignore Emacs auto-save files
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 24 Aug 2010 18:39:35 +0000 (24 20:39 +0200)]
Order .gitignore alphabetically
This should reduce merge conflicts for commits that add entries (at
least after this commit is handled :-)
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Tue, 24 Aug 2010 18:32:38 +0000 (24 20:32 +0200)]
Don't implement the usage message of tg depend more than once
The implmentation of "tg depend" had the usage message in two places.
Fixed by creating a usage function, so that there is a single place
to edit if the usage changes.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Wed, 14 Jul 2010 16:21:15 +0000 (14 18:21 +0200)]
Added the --deps option to "tg summary".
The --deps option can be used by scripts that need to know
the dependencies between the topic branches.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Per Cederqvist [Wed, 14 Jul 2010 16:21:02 +0000 (14 18:21 +0200)]
Implemented "tg summary --sort".
This uses tsort to sort the branches based on their dependency graph.
Note: only a single sort order that fulfills the dependency graph is
printed. There may be many other possible orderings.
A graphical text view would be much more useful, but this is till
a lot better than nothing.
Signed-off-by: Per Cederqvist <ceder@lysator.liu.se>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Wed, 25 Mar 2009 17:21:04 +0000 (25 18:21 +0100)]
tg patch: treat all files as ascii
This fixes patching binary files, for a problem case check out
http://bugs.debian.org/521173 .
Closes: http://bugs.debian.org/521173
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Sat, 10 Apr 2010 13:24:47 +0000 (10 15:24 +0200)]
tg mail: document config setting to prevent unintended mass mail sending
Addresses: http://bugs.debian.org/506306
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Carsten Hey [Sat, 10 Apr 2010 13:20:10 +0000 (10 15:20 +0200)]
Don't call pre-commit hook if tg is not installed
Signed-off-by: Carsten Hey <carsten@debian.org>
Closes: http://bugs.debian.org/576221
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thomas Schwinge [Sun, 28 Feb 2010 11:39:34 +0000 (28 12:39 +0100)]
tg-delete: Handle the case where the branch has been removed already, but the base is still left.
A user might have used 'git branch -D B' to remove the branch B, and then
certain TopGit commands complain, because the base of branch B is still there.
Signed-off-by: Thomas Schwinge <thomas@schwinge.name>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thomas Schwinge [Sun, 28 Feb 2010 13:24:08 +0000 (28 14:24 +0100)]
tg-mail: Properly quote argument to --in-reply-to
Message-Ids usually contain < and >. These need to be quoted.
Signed-off-by: Thomas Schwinge <thomas@schwinge.name>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thomas Schwinge [Sun, 28 Feb 2010 13:57:41 +0000 (28 14:57 +0100)]
tg-push: Filter out plain SHA1s from being pushed.
Otherwise, problems arise when branches depend (via .topdeps) on SHA1s:
$ tg push -r tmp t/____longjmp_chk_cleanup_linux_x86_64
fatal:
77c84aeb81808c3109665949448dba59965c391e cannot be resolved to branch.
fatal: The remote end hung up unexpectedly
Signed-off-by: Thomas Schwinge <thomas@schwinge.name>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Michal Sojka [Tue, 2 Feb 2010 10:31:12 +0000 (2 11:31 +0100)]
Make 'tg patch' work in subdirectories
When 'tg patch' is called from a subdirectory, it outputs only the
commit message and no diff.
Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
martin f. krafft [Tue, 27 Oct 2009 18:43:15 +0000 (27 19:43 +0100)]
quote $LESS in case it includes spaces
Signed-off-by: martin f. krafft <madduck@debian.org>
martin f. krafft [Tue, 27 Oct 2009 18:43:37 +0000 (27 19:43 +0100)]
deal with single quotes in from/to headers
Signed-off-by: martin f. krafft <madduck@debian.org>
Uwe Kleine-König [Wed, 23 Sep 2009 09:08:14 +0000 (23 11:08 +0200)]
bump version number to 0.8
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Jon Ringle [Wed, 16 Sep 2009 15:39:24 +0000 (16 11:39 -0400)]
Fix tg export --quilt --numbered w/ > 8 patches
Creating a quilt patch series with more than 8 patches with:
tg export --quilt --numbered patchdir
Causes the following error to be produced:
eval: 1: arithmetic expression: expecting EOF: "0008 + 1"
This is due to the leading 0 and the $(()) evaluates as octal rather
than decimal.
Add the leading zeros only to the filename, not the number itself.
Signed-off-by: Jon Ringle <jon@ringle.org>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Tue, 26 May 2009 23:31:34 +0000 (27 01:31 +0200)]
tg-push: add bash completion
Include all options.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Tue, 2 Jun 2009 20:35:12 +0000 (2 22:35 +0200)]
help: use pager
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Wed, 27 May 2009 08:17:01 +0000 (27 10:17 +0200)]
tg-push: handle non-tgish branches
tg push died if you gave it a non-tgish branch:
$ tg push -r push-test master
fatal: Not a valid object name refs/top-bases/master
fatal: ambiguous argument '^{tree}': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions
fatal: Not a valid object name master:.topdeps
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Wed, 27 May 2009 08:16:35 +0000 (27 10:16 +0200)]
tg-push: prevent handing branches more than once to git-push
Doing otherwise can result in a lot of warnings and errors:
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
warning, no base found top-bases/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/master is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/master
error: Ref refs/heads/bw/log is at
a16df35cc7009b36f6f71717ae3d9a3dc29987da but expected
0000000000000000000000000000000000000000
error: failed to lock refs/heads/bw/log
error: Ref refs/top-bases/bw/log is at
b725fc951a37854fc65945ac5bcab3bc61ccbd94 but expected
0000000000000000000000000000000000000000
error: failed to lock refs/top-bases/bw/log
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] master -> master (failed to lock)
! [remote rejected] bw/log -> bw/log (failed to lock)
! [remote rejected] refs/top-bases/bw/log -> refs/top-bases/bw/log (failed to lock)
Note, the result is OK only the output is irritating.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Bert Wesarg [Wed, 27 May 2009 08:16:22 +0000 (27 10:16 +0200)]
tg-push: remove useless warning about missing bases for non-tgish branches
The call to ref_exists() isn't needed because $_dep_is_tgish from
recurse_deps() gives us exactly this information.
Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Ilpo Järvinen [Thu, 28 May 2009 06:04:33 +0000 (28 09:04 +0300)]
tg-update: fix user visible typo in info msg
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Uwe Kleine-König [Wed, 13 May 2009 09:59:51 +0000 (13 11:59 +0200)]
tg-remote: don't add push specs but warn about existing ones.
topgit used to add some push specs to assert that topbases are pushed,
too. This should now be handled by tg-push.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Marc Weber <marco-oweber@gmx.de>
Tested-and-acked-by: martin f. krafft <madduck@debian.org>
Cc: 528442@bugs.debian.org
Marc Weber [Tue, 12 May 2009 08:54:51 +0000 (12 10:54 +0200)]
tg-push: new command pushing a tgish branch
It pushes recursively all deps and bases together with the branch.
Signed-off-by: Marc Weber <marco-oweber@gmx.de>
Tested-and-acked-by: martin f. krafft <madduck@madduck.net>
[ukleinek: fixed some nitpicks and changed remote handling]
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Marc Weber <marco-oweber@gmx.de>
Uwe Kleine-König [Mon, 11 May 2009 20:32:54 +0000 (11 22:32 +0200)]
recurse_deps: if no_remotes is set don't recurse into remote deps
This is based on a patch by Marc Weber. It will be used by tg-push.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Marc Weber <marco-oweber@gmx.de>
Uwe Kleine-König [Sun, 10 May 2009 21:59:46 +0000 (10 23:59 +0200)]
remove test for git send-email
This test didn't work as expected with certain pagers (e.g. vimpager)
when stdout is redirected to a non-terminal. Now it's the actual call
to git send-email that generates a very similar error message.
Reported-by: Antonio Ospite <ospite@studenti.unina.it>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-and-tested-by: Antonio Ospite <ospite@studenti.unina.it>
Uwe Kleine-König [Mon, 20 Apr 2009 09:42:53 +0000 (20 11:42 +0200)]
depend: don't disallow adding a dependency on a non-TopGit-branch
there is no techical reason not to depend on more than one
non-TopGit-branch. You can argue if you want it though. This patch
lets you decide if you want it or not.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Thu, 26 Mar 2009 08:52:26 +0000 (26 09:52 +0100)]
hooks/pre-commit.sh: fix bashism
This was introduced in
fcb488d51e72c7414f9beb40ad06bf529b8b38dc.
A similar fix was suggested by martin f krafft, too.
Reported-by: Bert Wesarg <bert.wesarg@googlemail.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Tested-by: Marc Kleine-Budde <mkl@pengutronix.de>
Acked-by: Bert Wesarg <bert.wesarg@googlemail.com>
Tested-by: Bert Wesarg <bert.wesarg@googlemail.com>
Uwe Kleine-König [Tue, 24 Mar 2009 21:16:48 +0000 (24 22:16 +0100)]
hooks/pre-commit.sh: don't stop commits on non-topgit branches
This is a regression introduced by
c32d1dd4fcafad3f9c570adeda580a90d56
"${head_#refs/heads/#refs/top-bases#}" doesn't substitute refs/heads by
refs/top-bases, but strips the prefix of $head_ if it starts with
"refs/heads/#refs/top-bases#".
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 24 Mar 2009 20:46:23 +0000 (24 21:46 +0100)]
don't use return when being sourced
Fabien Thomas reports that a Bourne (not Again) sh on FreeBSD just
ignores the return and continues executing with the rest of the script.
So just wrap everything that was skipped by the return using other
shells in a big if instead.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Closes: http://bugs.debian.org/516188
Uwe Kleine-König [Fri, 20 Mar 2009 19:40:07 +0000 (20 20:40 +0100)]
hooks/pre-commit.sh: don't wail on detached head for missing .top* files
This fixes a warning
fatal: ref HEAD is not a symbolic ref
when your HEAD is detached.
And branches under refs/top-bases/ don't need these files either.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Fri, 13 Mar 2009 09:18:17 +0000 (13 10:18 +0100)]
Add GPLv2 and description for S-o-b
The intend is to clearify the copyright situation. I'm not a lawyer,
but it should now be better than before.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Sun, 8 Mar 2009 21:15:16 +0000 (8 22:15 +0100)]
Call git-rerere after a failing merge as git-merge does
This maybe does all the hard work for you ...
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Sun, 8 Mar 2009 20:52:14 +0000 (8 21:52 +0100)]
Fix merge failure handling in tg export
There exist two problems that show that up to now the error handling was
completely untested:
- tg.sh uses `set -e`, so `git merge $branch; retmerge=$?` obviously
doesn't do the right thing.
- in recurse_deps stdin is redirected from $_depsfile. Starting a
shell with that doesn't give the user any chance to do something.
Reported-by: "Bernhard R. Link" <brlink@debian.org>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Sat, 7 Mar 2009 20:01:30 +0000 (7 21:01 +0100)]
Pass -- to diff-tree for branch/filename disambiguation
Script to show the need of this patch:
mkdir ty;
cd ty;
git init-db;
touch a;
git add a;
git commit -m "...";
tg create bla;
git commit -m "...";
mkdir bla;
touch bla/blub;
git add bla/blub;
git commit -m "...";
tg export --quilt tt;
Reported-by: "Bernhard R. Link" <brlink@debian.org>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Thu, 5 Mar 2009 10:29:07 +0000 (5 11:29 +0100)]
bump version number to 0.7
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 3 Mar 2009 09:31:22 +0000 (3 10:31 +0100)]
Fix typo s/emmail/email/
This was introduced by a tired coder in
d479474440713.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Tue, 3 Mar 2009 09:30:10 +0000 (3 10:30 +0100)]
Merge branch 'upstream' of git.debian.org:/git/collab-maint/topgit
Uwe Kleine-König [Tue, 3 Mar 2009 09:01:23 +0000 (3 10:01 +0100)]
Add documentation for tg export --linearize
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Sun, 1 Mar 2009 19:55:40 +0000 (1 20:55 +0100)]
Don't throw away already started base on resumed create.
The problem was that after a failure to create the patch base the
resuming tg create did reset HEAD to the next tree to merge in which is
the right thing for a pristine create.
This addresses Debian Bug #513018 and is based on a patch by the bug
reporter Gábor Braun. A recipe triggering the bug is part of the report
that can be found at http://bugs.debian.org/513018.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Thu, 15 Jan 2009 21:45:57 +0000 (15 22:45 +0100)]
[TOPGIT] implement linearize export method
This is a draft that seems to work for my test case. The error handling
is to be improved though.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Wed, 14 Jan 2009 20:26:18 +0000 (14 21:26 +0100)]
[TOPGIT] make creating a commit from a topgit branch a function
This helps avoiding code duplication for the next commit.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Wed, 14 Jan 2009 20:23:51 +0000 (14 21:23 +0100)]
[TOPGIT] make tg remote idempotent
Before this patch each call to tg remote added three config entries
no matter if they already existed. After some time my .git/config was
crowded.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Wed, 25 Feb 2009 19:44:11 +0000 (25 20:44 +0100)]
[TOPGIT] allow working with annihilated branches
If you decide that you want to drop a patch, you can just merge in its
base with strategy "theirs". Then you have base=topic and so no .top*
files any more. This patch fixes tg summary and the helper function
recurse_deps() to handle these annihilated branches as if they don't
exist and don't show up in .topdeps files.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Uwe Kleine-König [Wed, 25 Feb 2009 10:05:00 +0000 (25 11:05 +0100)]
[TOPGIT] limit rev-list in branch_contains to a single rev
This eases reading of debug output using sh -x and probably helps
performance, too.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
martin f. krafft [Fri, 23 Jan 2009 05:33:43 +0000 (23 16:33 +1100)]
bump version number to 0.6
martin f. krafft [Fri, 23 Jan 2009 05:33:29 +0000 (23 16:33 +1100)]
put tg version into a variable at the top
Kirill Smelkov [Wed, 21 Jan 2009 20:18:42 +0000 (21 23:18 +0300)]
tg-patch: add support for generating patches against worktree and index
This implements `tg patch -i` and `tg patch -w` to see current patch as
generated against not-yet-committed index and worktree.
NOTE: unfortunately `git cat-file blob <file>` does not provide an option
to cat file from worktree (only from an object or from index), so I had to
unroll my own `cat file topic:file` with special support for '(i)' and
'(w)' topics.
Signed-off-by: Kirill Smelkov <kirr@landau.phys.spbu.ru>