stgit
15 years agoDocumentation: Rename link macros
Karl Hasselström [Fri, 13 Mar 2009 03:14:42 +0000 (04:14 +0100)]
Documentation: Rename link macros

They can no longer end with "link", as explained in commit 5162e697 by
Dan McGee <dpmcgee@gmail.com> in the git repository:

    Documentation: rename gitlink macro to linkgit

    Between AsciiDoc 8.2.2 and 8.2.3, the following change was made to the stock
    Asciidoc configuration:

    @@ -149,7 +153,10 @@
     # Inline macros.
     # Backslash prefix required for escape processing.
     # (?s) re flag for line spanning.
    -(?su)[\\]?(?P<name>\w(\w|-)*?):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
    +
    +# Explicit so they can be nested.
    +(?su)[\\]?(?P<name>(http|https|ftp|file|mailto|callto|image|link)):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
    +
     # Anchor: [[[id]]]. Bibliographic anchor.
     (?su)[\\]?\[\[\[(?P<attrlist>[\w][\w-]*?)\]\]\]=anchor3
     # Anchor: [[id,xreflabel]]

    This default regex now matches explicit values, and unfortunately in this
    case gitlink was being matched by just 'link', causing the wrong inline
    macro template to be applied. By renaming the macro, we can avoid being
    matched by the wrong regex.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoDocumentation: Ignore generated .xml files
Karl Hasselström [Fri, 13 Mar 2009 03:10:59 +0000 (04:10 +0100)]
Documentation: Ignore generated .xml files

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostg squash: Improve documentation
Karl Hasselström [Fri, 13 Mar 2009 02:57:20 +0000 (03:57 +0100)]
stg squash: Improve documentation

In particular, mention how the order of the given patches matter, and
exactly what happens in case of conflict.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRename "stg coalesce" to "stg squash"
Karl Hasselström [Thu, 26 Feb 2009 20:13:37 +0000 (21:13 +0100)]
Rename "stg coalesce" to "stg squash"

"squash" is the word git uses for this operation, so we should use it
too to lessen the confusion. Also, it's easier to spell.

We can do the rename without any effort at backwards compatibility
because "stg coalesce" has never been part of any released version.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add "B" for stgit-branch
Gustav Hållberg [Thu, 26 Feb 2009 19:59:07 +0000 (20:59 +0100)]
stgit.el: Add "B" for stgit-branch

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Expand or collapse only the patch at point, instead of rerunning stg-reload.
David Kågedal [Thu, 26 Feb 2009 19:59:07 +0000 (20:59 +0100)]
stgit.el: Expand or collapse only the patch at point, instead of rerunning stg-reload.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: make stgit-delete with prefix argument spill patch contents to index
Gustav Hållberg [Thu, 26 Feb 2009 19:59:07 +0000 (20:59 +0100)]
stgit.el: make stgit-delete with prefix argument spill patch contents to index

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd --file option to pick
Catalin Marinas [Wed, 28 Jan 2009 23:08:13 +0000 (23:08 +0000)]
Add --file option to pick

This allows folding of specific files only.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoMerge branch 'stable'
Catalin Marinas [Wed, 28 Jan 2009 23:07:37 +0000 (23:07 +0000)]
Merge branch 'stable'

Conflicts:
stgit/commands/files.py
stgit/commands/mail.py
stgit/git.py

15 years agoPass the diff flags when statistics are required
Catalin Marinas [Wed, 28 Jan 2009 23:01:24 +0000 (23:01 +0000)]
Pass the diff flags when statistics are required

The --diff-opts were not passed to git.diff() calls when the statistics
were required for the mail and files commands.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoMake bash completion fail to bashdefault before default completion.
Ted Pavlic [Tue, 20 Jan 2009 00:46:13 +0000 (19:46 -0500)]
Make bash completion fail to bashdefault before default completion.

If "-o bashdefault" isn't possible, use old "-o default" only.

(this patch inspired by similar mechanism in Mercurial bash completion
script)

Signed-off-by: Ted Pavlic <ted@tedpavlic.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoModify bash completion to support help, version, and copyright.
Ted Pavlic [Tue, 20 Jan 2009 00:46:12 +0000 (19:46 -0500)]
Modify bash completion to support help, version, and copyright.

"stg <tab>" lists all commands, including "help", "version", and
"copyright".

"stg he<tab>" completes "stg help "
"stg ver<tab>" completes "stg version "
"stg copy<tab>" completes "stg copyright "

"stg help <tab>" lists all commands /other than/ help, version, and
copyright.

"stg version <tab>" goes directly to shell completion.
"stg copyright <tab>" goes directly to shell completion.

Signed-off-by: Ted Pavlic <ted@tedpavlic.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add optional count argument to stgit-commit
Gustav Hållberg [Mon, 12 Jan 2009 20:20:14 +0000 (21:20 +0100)]
stgit.el: Add optional count argument to stgit-commit

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Minor beautification
Gustav Hållberg [Mon, 12 Jan 2009 20:20:14 +0000 (21:20 +0100)]
stgit.el: Minor beautification

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Indicate empty patches
Gustav Hållberg [Mon, 12 Jan 2009 20:20:13 +0000 (21:20 +0100)]
stgit.el: Indicate empty patches

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add message when there are no patches in the series
Gustav Hållberg [Mon, 12 Jan 2009 20:20:13 +0000 (21:20 +0100)]
stgit.el: Add message when there are no patches in the series

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Include stat summary in patch diff
Gustav Hållberg [Mon, 12 Jan 2009 20:20:13 +0000 (21:20 +0100)]
stgit.el: Include stat summary in patch diff

Run 'stg show' with '-O --patch-with-stat' flags.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Make single file diff buffer read-only
Gustav Hållberg [Mon, 12 Jan 2009 20:20:13 +0000 (21:20 +0100)]
stgit.el: Make single file diff buffer read-only

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Consistently use symbols rather than strings for patch names
Gustav Hållberg [Mon, 12 Jan 2009 20:20:13 +0000 (21:20 +0100)]
stgit.el: Consistently use symbols rather than strings for patch names

Also make the stgit-run... functions automatically convert their
arguments to strings.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoMerge branch 'stable'
Karl Hasselström [Thu, 22 Jan 2009 22:57:01 +0000 (23:57 +0100)]
Merge branch 'stable'

* stable:
  stgit.namelength is an integer
  Return None instead of crashing on undefined integer config items

15 years agoFix the patch argument parsing for the "show" command
Catalin Marinas [Wed, 14 Jan 2009 22:25:48 +0000 (22:25 +0000)]
Fix the patch argument parsing for the "show" command

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agostgit.namelength is an integer
Pete Wyckoff [Mon, 12 Jan 2009 20:04:24 +0000 (21:04 +0100)]
stgit.namelength is an integer

Interpret stgit namelength as an integer, else the use of
name_len will fail with

  File "/usr/lib/python2.5/site-packages/stgit/utils.py", line 206, in patch_name_from_msg
    return re.sub('[\W]+', '-', subject_line).strip('-')[:name_len]
TypeError: slice indices must be integers or None or have an __index__ method

Signed-off-by: Pete Wyckoff <pw@padd.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoReturn None instead of crashing on undefined integer config items
Karl Hasselström [Mon, 12 Jan 2009 20:04:10 +0000 (21:04 +0100)]
Return None instead of crashing on undefined integer config items

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoPatch to clarify the "unsolved conflicts" message in Stacked Git
Jason Green [Thu, 18 Dec 2008 14:29:11 +0000 (09:29 -0500)]
Patch to clarify the "unsolved conflicts" message in Stacked Git

I recently started using Stacked Git to manage my patchsets, and it's
been a great tool.  However, I was a bit confused for a while on how
to resolve conflicts when a merge fails.  Here's a patch to hopefully
clarify that message a little.

Signed-off-by: Jason Green <jason@transgaming.com>
Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoMerge branch 'proposed'
Catalin Marinas [Thu, 1 Jan 2009 21:51:22 +0000 (21:51 +0000)]
Merge branch 'proposed'

15 years agostgit.el: Canonicalize some error messages
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
stgit.el: Canonicalize some error messages

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add some missing help texts
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
stgit.el: Add some missing help texts

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Fix some too wide lines
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
stgit.el: Fix some too wide lines

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Bugfix stgit-unmark-down on the last patch
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
stgit.el: Bugfix stgit-unmark-down on the last patch

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Make prefix argument to stgit-new add a Signed-off-by: line
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
stgit.el: Make prefix argument to stgit-new add a Signed-off-by: line

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoman pages: Bugfixed man pages for --sign and --ack flags; e.g., for stg-new
Gustav Hållberg [Mon, 29 Dec 2008 14:32:58 +0000 (15:32 +0100)]
man pages: Bugfixed man pages for --sign and --ack flags; e.g., for stg-new

An optparse argument type 'callback' with a 'dest' setting showed as
"--sign SIGN". Use optparse's Option.takes_value() instead.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoSubmittingPatches: adapt to StGit
Karl Hasselström [Sun, 21 Dec 2008 11:48:27 +0000 (12:48 +0100)]
SubmittingPatches: adapt to StGit

Remove a bunch of Git-specific stuff, and insert the corresponding
StGit stuff where appropriate.

I don't claim the resulting document is perfect, but it should be a
good starting point.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoSteal Documentation/SubmittingPatches from Git
Karl Hasselström [Sun, 21 Dec 2008 11:48:27 +0000 (12:48 +0100)]
Steal Documentation/SubmittingPatches from Git

'git shortlog -- Documentation/SubmittingPatches' shows that the
following people deserve credit for it:

  A Large Angry SCM (2):
        Add footnote about Thunderbird about trimming trailing WS.
        Update Thunderbird specific hints.

  Andrew Ruder (1):
        Add policy on user-interface changes

  Bill Lear (1):
        Document --check option to git diff.

  David Symonds (1):
        Change from using email.com to example.com as example domain, as per RFC 2606.

  Jari Aalto (1):
        Clarify SubmittingPatches Checklist

  Jim Meyering (1):
        SubmittingPatches: fix a typo

  Johannes Schindelin (5):
        Begin SubmittingPatches with a check list
        SubmittingPatches: mention older C compiler compatibility
        Update to SubmittingPatches
        Rename ".dotest/" to ".git/rebase" and ".dotest-merge" to "rebase-merge"
        Rename .git/rebase to .git/rebase-apply

  Junio C Hamano (19):
        Add SubmittingPatches
        Update SubmittingPatches to add MUA specific notes.
        Update SubmittingPatches.
        Add Pine 4.63 help from Daniel.
        SubmittingPatches: note on whitespaces
        Documentation: note about contrib/.
        Documentation/SubmittingPatches: 3+1 != 6
        Documentation/SubmittingPatches: Gnus tips
        Merge branch 'maint'
        Merge branch 'maint-1.5.1' into maint
        Remove git-applypatch
        War on whitespace
        Update my contact address as the maintainer.
        Documentation/SubmittingPatches: Instruct how to use [PATCH] Subject header
        Documentation/SubmittingPatches: discuss first then submit
        Documentation/SubmittingPatches: What's Acked-by and Tested-by?
        Documentation/SubmittingPatches - a suggested patch flow
        Merge branch 'maint'
        Merge branch 'maint' to sync with GIT 1.6.0.6

  Lukas Sandström (2):
        SubmittingPatches: The download location of External Editor has moved
        Add a helper script to send patches with Mozilla Thunderbird

  Michele Ballabio (1):
        Documentation: add KMail in SubmittingPatches

  Miklos Vajna (1):
        SubmittingPatches: mention the usage of real name in Signed-off-by: lines

  Paolo Ciarrocchi (1):
        Teach SubmittingPatches about git-commit -s

  Pavel Roskin (1):
        Assorted typo fixes

  Sergei Organov (1):
        SubmittingPatches: improve the 'Patch:' section of the checklist

  Tom Preston-Werner (1):
        add instructions on how to send patches to the mailing list with Gmail

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostg files: Don't write just an empty line
Karl Hasselström [Sun, 21 Dec 2008 10:55:53 +0000 (11:55 +0100)]
stg files: Don't write just an empty line

If we don't produce any output, we shouldn't print a newline.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Also show mode and type changes of files in patches
Gustav Hållberg [Sun, 21 Dec 2008 10:55:52 +0000 (11:55 +0100)]
stgit.el: Also show mode and type changes of files in patches

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostg mail: Improve error message for unknown sender identity
Gustav Hållberg [Sun, 21 Dec 2008 10:55:52 +0000 (11:55 +0100)]
stg mail: Improve error message for unknown sender identity

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd '--help' to tab completion for all commands
Gustav Hållberg [Sun, 21 Dec 2008 10:55:52 +0000 (11:55 +0100)]
Add '--help' to tab completion for all commands

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Use 'git diff-stat' to show files in a patch
Gustav Hållberg [Sun, 21 Dec 2008 10:55:52 +0000 (11:55 +0100)]
stgit.el: Use 'git diff-stat' to show files in a patch

Print file modification status in human-readable format.

Add stgit-expand-find-copies-harder flag to select whether to use
the --find-copies-harder flag or not.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add an stgit customization group
Gustav Hållberg [Sun, 21 Dec 2008 10:55:51 +0000 (11:55 +0100)]
stgit.el: Add an stgit customization group

This makes it easier to customize faces and (future) variables.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add support for showing which files are affected by a patch
Gustav Hållberg [Sun, 21 Dec 2008 10:55:51 +0000 (11:55 +0100)]
stgit.el: Add support for showing which files are affected by a patch

One can "expand" a patch by pressing RET, which shows the files that
patch modifies. On a line with a modified file, one can:
  RET  find file
  o    find file in other window
  =    show diff in that file

\C-n and \C-p can be used to move between patches when they have been
expanded.

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Automatically update git-status buffer when necessary
Gustav Hållberg [Sun, 21 Dec 2008 10:55:51 +0000 (11:55 +0100)]
stgit.el: Automatically update git-status buffer when necessary

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add flag to signal errors in stgit-patch-at-point
Gustav Hållberg [Sun, 21 Dec 2008 10:55:51 +0000 (11:55 +0100)]
stgit.el: Add flag to signal errors in stgit-patch-at-point

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Unify help text formatting
Gustav Hållberg [Sun, 21 Dec 2008 10:55:50 +0000 (11:55 +0100)]
stgit.el: Unify help text formatting

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Fix working directory bug in stgit-new
Gustav Hållberg [Wed, 10 Dec 2008 20:03:52 +0000 (21:03 +0100)]
stgit.el: Fix working directory bug in stgit-new

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Acked-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add stgit-git-status
Gustav Hållberg [Wed, 10 Dec 2008 20:03:50 +0000 (21:03 +0100)]
stgit.el: Add stgit-git-status

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Acked-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostg series: Explain the list format better
Karl Hasselström [Mon, 8 Dec 2008 20:24:48 +0000 (21:24 +0100)]
stg series: Explain the list format better

Also taking into account the recent format change.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoUse separate column for zero in output of stg series -e
David Kågedal [Mon, 8 Dec 2008 20:24:44 +0000 (21:24 +0100)]
Use separate column for zero in output of stg series -e

This will make the output more regular and easier to parse. It no longer
overwrites the +/-/! status flag with a zero for empty patches, and
instead puts the zero before it.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Fix some indentation
Gustav Hållberg [Mon, 8 Dec 2008 20:24:37 +0000 (21:24 +0100)]
stgit.el: Fix some indentation

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add stgit-unmark-down
Gustav Hållberg [Mon, 8 Dec 2008 20:24:37 +0000 (21:24 +0100)]
stgit.el: Add stgit-unmark-down

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add 'm' as alias for stgit-mark
Gustav Hållberg [Mon, 8 Dec 2008 20:24:37 +0000 (21:24 +0100)]
stgit.el: Add 'm' as alias for stgit-mark

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add 'q' for stgit-quit
Gustav Hållberg [Mon, 8 Dec 2008 20:24:37 +0000 (21:24 +0100)]
stgit.el: Add 'q' for stgit-quit

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Compact code for populating stgit-mode-map
Gustav Hållberg [Mon, 8 Dec 2008 20:24:37 +0000 (21:24 +0100)]
stgit.el: Compact code for populating stgit-mode-map

Signed-off-by: Gustav Hållberg <gustav@virtutech.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Show running commands
David Kågedal [Sun, 7 Dec 2008 12:32:10 +0000 (13:32 +0100)]
stgit.el: Show running commands

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add the stgit-refresh command
David Kågedal [Sun, 7 Dec 2008 12:32:07 +0000 (13:32 +0100)]
stgit.el: Add the stgit-refresh command

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Move stgit-rename to C-c C-r
David Kågedal [Sun, 7 Dec 2008 12:32:04 +0000 (13:32 +0100)]
stgit.el: Move stgit-rename to C-c C-r

This allows us to reuse "r" for refresh.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Rename stgit-refresh to stgit-reload
David Kågedal [Sun, 7 Dec 2008 12:32:00 +0000 (13:32 +0100)]
stgit.el: Rename stgit-refresh to stgit-reload

This allows us to reuse the stgit-refresh for the more obvious
"stg refesh".

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Try to make the point stay on the coalesced patch
David Kågedal [Sun, 7 Dec 2008 12:31:57 +0000 (13:31 +0100)]
stgit.el: Try to make the point stay on the coalesced patch

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoPrint conflict details with the new infrastructure (bug #11181)
Catalin Marinas [Wed, 3 Dec 2008 21:49:23 +0000 (21:49 +0000)]
Print conflict details with the new infrastructure (bug #11181)

The patch modifies the IndexAndWorkTree.merge() function to display
pass the conflict information (files) when raising an exception. The
logic is similar to the one in the old infrastructure.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
Acked-by: Karl Hasselström <kha@treskal.com>
15 years agofix export -s
Dan Williams [Wed, 3 Dec 2008 21:48:17 +0000 (21:48 +0000)]
fix export -s

Resolves:
stg export -s `stg top`
Traceback (most recent call last):
  File "/usr/local/lib/python2.5/site-packages/stgit/main.py", line 152, in _main
    ret = command.func(parser, options, args)
  File "/usr/local/lib/python2.5/site-packages/stgit/commands/export.py", line 169, in func
    f = sys.stdout
NameError: global name 'sys' is not defined

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agomail: add some commonly used tags to --auto
Dan Williams [Wed, 3 Dec 2008 21:48:17 +0000 (21:48 +0000)]
mail: add some commonly used tags to --auto

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoDo not append a new line to the backwards compat files (bug #12656)
Catalin Marinas [Tue, 2 Dec 2008 11:05:27 +0000 (11:05 +0000)]
Do not append a new line to the backwards compat files (bug #12656)

Since the multiline argument wasn't passed to the utils.write_string()
function when writing the compatibility description file from the new
infrastructure, any older command like push would have committed these
new lines.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
Acked-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd "tags" target to Makefile
Catalin Marinas [Tue, 2 Dec 2008 11:05:27 +0000 (11:05 +0000)]
Add "tags" target to Makefile

We could only generate TAGS before. Also added these targets to .PHONY.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agos/GIT/Git/ in the README
Catalin Marinas [Tue, 2 Dec 2008 09:41:09 +0000 (09:41 +0000)]
s/GIT/Git/ in the README

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoFix the HEAD updating during a conflicting push (bug #12609)
Catalin Marinas [Sun, 23 Nov 2008 21:16:19 +0000 (21:16 +0000)]
Fix the HEAD updating during a conflicting push (bug #12609)

Copying most of Karl's comment from the list:

 1. In push_patch(), we delay the final stack update (the update()
    function) since we want to record the state just before the
    conflict in the stack log.

 2. In run(), we update the branch head before running the delayed
    stack update (self.__conflicting_push()).

The patch works around this problem by explicitly specifying what the
branch head should be; this mechanism is used by undo etc. to be able
to set the branch head to something that isn't the stack top.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
Acked-by: Karl Hasselström <kha@treskal.com>
15 years agoDisplay (empty) when appropriate for the goto command
Catalin Marinas [Fri, 21 Nov 2008 22:33:20 +0000 (22:33 +0000)]
Display (empty) when appropriate for the goto command

This is a fix for bug #11810. The original implementation of goto used
to display (empty patch) when a patch became empty during a push + merge
operation. This patch adds this feature again.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
Acked-by: Karl Hasselström <kha@treskal.com>
15 years agoMerge branch 'proposed'
Catalin Marinas [Sat, 8 Nov 2008 22:00:42 +0000 (22:00 +0000)]
Merge branch 'proposed'

15 years agoAdd 'pick' test script
Catalin Marinas [Sat, 8 Nov 2008 21:49:09 +0000 (21:49 +0000)]
Add 'pick' test script

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoGenerate a different patch name if it already exists
Catalin Marinas [Sat, 8 Nov 2008 21:18:09 +0000 (21:18 +0000)]
Generate a different patch name if it already exists

This is a fix for bug #12518. If the patch name already exists, the pick
command generates another by appending a numbered suffix.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoAllow pick --fold to work without applied patches
Catalin Marinas [Sat, 8 Nov 2008 21:18:08 +0000 (21:18 +0000)]
Allow pick --fold to work without applied patches

This patch fixes bug #12517. While there may be other variants for
achieving the same, it makes sense not to restrict the --fold option.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoRefresh of remove-e-mail-address-duplicat
Catalin Marinas [Sat, 8 Nov 2008 21:34:52 +0000 (21:34 +0000)]
Refresh of remove-e-mail-address-duplicat

15 years agoRemove e-mail address duplicates
Catalin Marinas [Sat, 8 Nov 2008 21:18:08 +0000 (21:18 +0000)]
Remove e-mail address duplicates

This is a fix for bug #10902. The 'mail' command now filters the
duplicate e-mail addresses before generating the message to be sent.
This was a problem especially with the --auto option.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoRemove the --committer options
Catalin Marinas [Sat, 8 Nov 2008 21:18:08 +0000 (21:18 +0000)]
Remove the --committer options

As per bug #11977, these options should not be used directly. People
wanting a different committer should set the corresponding Git
environment variables.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agostgit.el: Add undo command
David Kågedal [Thu, 6 Nov 2008 07:34:37 +0000 (08:34 +0100)]
stgit.el: Add undo command

Bound it to the two standard bindings C-/ and C-_.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Adapt to new output from stg series.
David Kågedal [Thu, 6 Nov 2008 07:34:37 +0000 (08:34 +0100)]
stgit.el: Adapt to new output from stg series.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agostgit.el: Add numeric prefix argument to push and pop commands.
David Kågedal [Thu, 6 Nov 2008 07:34:37 +0000 (08:34 +0100)]
stgit.el: Add numeric prefix argument to push and pop commands.

By using a numerical prefix (or simply C-u) it is possible to push or
pop more than one patch.

Signed-off-by: David Kågedal <davidk@lysator.liu.se>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd parse_patches boundary in the delete.py file
Catalin Marinas [Sat, 1 Nov 2008 10:52:27 +0000 (10:52 +0000)]
Add parse_patches boundary in the delete.py file

Specifying open intervals like .. for the delete command would remove
both applied and unapplied patches, which might not be the intended
behaviour. Boundary crossing should be explicit.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoChange e-mail user agent header to StGit
Catalin Marinas [Sat, 1 Nov 2008 10:52:27 +0000 (10:52 +0000)]
Change e-mail user agent header to StGit

For consistency with documentation as it was StGIT.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoTutorial: Importing patches
Karl Hasselström [Wed, 29 Oct 2008 19:06:16 +0000 (20:06 +0100)]
Tutorial: Importing patches

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoTeach "stg import" to import patch series from tar archives
Clark Williams [Fri, 24 Oct 2008 01:10:36 +0000 (03:10 +0200)]
Teach "stg import" to import patch series from tar archives

Signed-off-by: Clark Williams <williams@redhat.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoIgnore compiled elisp files
Clark Williams [Fri, 24 Oct 2008 01:05:35 +0000 (03:05 +0200)]
Ignore compiled elisp files

Signed-off-by: Clark Williams <williams@redhat.com>
Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoFix "show" to allow multiple branch:patch arguments
Catalin Marinas [Sun, 19 Oct 2008 08:16:06 +0000 (09:16 +0100)]
Fix "show" to allow multiple branch:patch arguments

Ranges aren't allow to contain the branch:patch format but individual
patches can be specified this way since they are treated as individual
commits.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoTutorial: Write about rebasing
Karl Hasselström [Sun, 12 Oct 2008 15:03:52 +0000 (17:03 +0200)]
Tutorial: Write about rebasing

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoTutorial: Cover "stg mail"
Karl Hasselström [Sun, 12 Oct 2008 15:03:52 +0000 (17:03 +0200)]
Tutorial: Cover "stg mail"

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoTutorial: Explain diffs a little bit better
Karl Hasselström [Sun, 12 Oct 2008 15:03:52 +0000 (17:03 +0200)]
Tutorial: Explain diffs a little bit better

Say that we use unified diffs, and point to the Wikipedia article
about them. We should probably explain this in more detail ourselves
when we get a proper user guide; but for the tutorial, this is
probably enough.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoTutorial: Talk about conflicts when introducing StGit
Karl Hasselström [Sun, 12 Oct 2008 15:03:51 +0000 (17:03 +0200)]
Tutorial: Talk about conflicts when introducing StGit

Conflicts and conflict resolving are essential features of StGit, so
we'd better tell the user about them.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRefresh and expand the tutorial (not finished)
Karl Hasselström [Sun, 5 Oct 2008 15:37:17 +0000 (17:37 +0200)]
Refresh and expand the tutorial (not finished)

This is a first pass at expanding the tutorial, fixing its formatting,
and updating it with the new things that have happened in StGit.

There are a number of things still left to do in the second half of
the document; they are tagged with "TODO".

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRefresh the main stg man page
Karl Hasselström [Sat, 4 Oct 2008 13:35:57 +0000 (15:35 +0200)]
Refresh the main stg man page

Update the text to reflect what's happened in StGit in the last few
releases. Also, consistently capitalize the names "Git" and "StGit".

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd 1.0 TODO items from recent discussion by private mail
Karl Hasselström [Sat, 4 Oct 2008 09:20:03 +0000 (11:20 +0200)]
Add 1.0 TODO items from recent discussion by private mail

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoWe're half-way there with the separate indexes
Karl Hasselström [Sat, 4 Oct 2008 09:15:43 +0000 (11:15 +0200)]
We're half-way there with the separate indexes

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRemove TODO items that have already been addressed
Karl Hasselström [Sat, 4 Oct 2008 09:03:58 +0000 (11:03 +0200)]
Remove TODO items that have already been addressed

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRemove unused variable
Karl Hasselström [Sun, 5 Oct 2008 15:33:41 +0000 (17:33 +0200)]
Remove unused variable

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoUse --diff rather than --patch in log.py
Catalin Marinas [Thu, 2 Oct 2008 22:11:12 +0000 (23:11 +0100)]
Use --diff rather than --patch in log.py

In a few places in this file options.diff is used already.

Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
15 years agoMerge branch 'stable'
Karl Hasselström [Sun, 28 Sep 2008 12:38:22 +0000 (14:38 +0200)]
Merge branch 'stable'

* stable:
  Fix typo

15 years agoFix typo
Karl Hasselström [Sun, 28 Sep 2008 12:32:12 +0000 (14:32 +0200)]
Fix typo

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoTest the new stg delete --spill flag
Karl Hasselström [Sun, 21 Sep 2008 18:34:07 +0000 (20:34 +0200)]
Test the new stg delete --spill flag

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd a new flag, --spill, to stg delete
Karl Hasselström [Sun, 21 Sep 2008 18:34:07 +0000 (20:34 +0200)]
Add a new flag, --spill, to stg delete

It deletes the patches as usual, but doesn't touch index+worktree.
Useful for splitting up a patch, or undoing an "stg refresh".

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoRemove misleading "stg delete" documentation
Karl Hasselström [Sun, 21 Sep 2008 18:34:07 +0000 (20:34 +0200)]
Remove misleading "stg delete" documentation

With the recent arrival of the stack log, patch
deletion can now be undone.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAdd myself to the AUTHORS file
Karl Hasselström [Sun, 21 Sep 2008 18:34:07 +0000 (20:34 +0200)]
Add myself to the AUTHORS file

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoUntabify
Karl Hasselström [Sun, 21 Sep 2008 18:34:06 +0000 (20:34 +0200)]
Untabify

We don't use tabs anywhere else, so it seems inconsistent to use it
here.

Signed-off-by: Karl Hasselström <kha@treskal.com>
15 years agoAutomatic bash completion
Karl Hasselström [Sun, 21 Sep 2008 12:20:41 +0000 (14:20 +0200)]
Automatic bash completion

Teach the build process to create a bash tab completion script. This
has three benefits:

  1. The tab completion gets faster, since it no longer has to run stg
     to figure out the set of available flags for each command.

  2. The tab completion script used to encode the list of stg
     subcommands, and the kind of arguments each subcommand expected.
     This information now lives in just one place: the subcommand's
     module.

  3. The tab completion script now knows what kind of argument each
     flag wants, and can tab complete those as well. So "stg refresh
     <tab>" will complete dirty files, but "stg refresh -p <tab>" will
     complete patch names.

Signed-off-by: Karl Hasselström <kha@treskal.com>