be.git
15 years agoAdd ability to list all current targets.
Gianluca Montecchi [Wed, 24 Jun 2009 21:20:12 +0000 (17:20 -0400)]
Add ability to list all current targets.

From his Wed, 24 Jun 2009 23:08:25 +0200 email to the list:

Hello

As I noted some time ago, there is not a way to list all the present targets
in the current repository.

At the time, Chris send me a patch to have this feature, but it still not
merged in the last revision (314).

So this is a patch for this feature to apply against revision 314. It is
basically a port of the old Chris's patch.

bye
Gianluca

15 years agoConsolidated outstanding bugs.
W. Trevor King [Mon, 22 Jun 2009 21:31:13 +0000 (17:31 -0400)]
Consolidated outstanding bugs.

Only one live bug left:
  7ec2c071-9630-42b0-b08a-9854616f9144

I've decided (mostly due to the huge Trac post, see bug comments) to
_not_ hardcode dependencies, but to add an attribute-creation
mechanism that a becommand/depend.py could use for dependency
tracking.  Time for a new branch to think this out...

15 years agoAdded `be list --sort *` for user-selectable sorting.
W. Trevor King [Mon, 22 Jun 2009 20:27:46 +0000 (16:27 -0400)]
Added `be list --sort *` for user-selectable sorting.

Also added libbe.bug.cmp_last_modified, which handles part of
9ce2f015-8ea0-43a5-a03d-fc36f6d202fe.  To do better we could extend
the RCS framework.

I also transcribed a few emails from the be-devel list onto their
relavent bugs and closed a few bugs.

Finally, I removed some left over InvalidValue cruft.

15 years agoUse Comment.content_type in xml output.
W. Trevor King [Mon, 22 Jun 2009 18:30:42 +0000 (14:30 -0400)]
Use Comment.content_type in xml output.

15 years agoMerged be-xml-to-mbox
W. Trevor King [Mon, 22 Jun 2009 16:20:09 +0000 (12:20 -0400)]
Merged be-xml-to-mbox

15 years agoCreated be-xml-to-mbox.
W. Trevor King [Mon, 22 Jun 2009 16:16:27 +0000 (12:16 -0400)]
Created be-xml-to-mbox.

Converts the output of `be list --xml` mbox format.
For example:
  $ be list --xml | be-xml-to-mbox | catmutt

15 years agoOnly print RFC 2822 date in bug xml output.
W. Trevor King [Mon, 22 Jun 2009 15:50:09 +0000 (11:50 -0400)]
Only print RFC 2822 date in bug xml output.

15 years agoEscape XML strings.
W. Trevor King [Mon, 22 Jun 2009 14:39:05 +0000 (10:39 -0400)]
Escape XML strings.

Since
  <creator>John Doe <jdoe@example.com></creator>
is not valid XML.

15 years agoAdjusted catmutt for portability following Mortiz' suggestions.
W. Trevor King [Mon, 22 Jun 2009 14:15:07 +0000 (10:15 -0400)]
Adjusted catmutt for portability following Mortiz' suggestions.

15 years agoFixed libbe.settings_object.EMPTY output in bug/comment XML.
W. Trevor King [Mon, 22 Jun 2009 14:02:11 +0000 (10:02 -0400)]
Fixed libbe.settings_object.EMPTY output in bug/comment XML.

The xml() method hadn't been updated since the settings_object revamp.

15 years agoAdjusted comment XML fields for consistency.
W. Trevor King [Mon, 22 Jun 2009 13:15:22 +0000 (09:15 -0400)]
Adjusted comment XML fields for consistency.

Renamed "name" -> "short-name" and "in_reply_to" -> "in-reply-to".
Reordered uuid before short-name.

15 years agoConverted xml/grepm to xml/catmutt.
W. Trevor King [Mon, 22 Jun 2009 12:38:09 +0000 (08:38 -0400)]
Converted xml/grepm to xml/catmutt.

Now
  $ cat example.mbox | catmutt
works.  Onwards to be-xml-to-mbox!

15 years agoAdded grepm as a template for an output-mbox-to-mutt script.
Moritz Barsnick (at dot) [Mon, 22 Jun 2009 11:22:26 +0000 (07:22 -0400)]
Added grepm as a template for an output-mbox-to-mutt script.

The goal is to turn grepm into catmutt, and end up with
  $ be --xml list | be-xml-to-mbox | catmutt
to browse current bugs and comments in mutt.

Moritz has generously donated grepm under GPLv2.  Not GPLv>=2 yet, so
if the project decides to go to GLPv3 for example, this file will have
to stay behind.  Not that I see such a change coming, but I thought it
was worth commenting on, so we don't forget.

15 years agoReplaced some doctest output with ellipses.
W. Trevor King [Mon, 22 Jun 2009 01:54:07 +0000 (21:54 -0400)]
Replaced some doctest output with ellipses.

Following Chris' advice.  Don't know what I was thinking before ;).

15 years agoAdded --xml option to becommands/list.py
W. Trevor King [Sun, 21 Jun 2009 13:41:13 +0000 (09:41 -0400)]
Added --xml option to becommands/list.py

15 years agoRestored completion/be.bash.
W. Trevor King [Sun, 21 Jun 2009 13:22:31 +0000 (09:22 -0400)]
Restored completion/be.bash.

Oops.  I seem to have removed it in my Thu 2008-11-27 19:35:55 -0500
commit.  Luckily, the version I removed was still sitting right were
it belongs as
 /etc/bash_completion.d/be
Now it will be back in the tree.

15 years agoTouch missing userwide config file before read if it's missing.
W. Trevor King [Sun, 21 Jun 2009 11:56:05 +0000 (07:56 -0400)]
Touch missing userwide config file before read if it's missing.

Another bug introduced by James Rowe's user-config patch.  Obviously
it's hard to read a file if there's no file there.  I'm not sure how
it passed the unit tests earlier.  Maybe I forgot to install the
pre-commit version before running the test suite...  Anyhow, fixed
now.

15 years agoMerge from Ben Finney's RCS unittest patch
W. Trevor King [Sun, 21 Jun 2009 11:28:48 +0000 (07:28 -0400)]
Merge from Ben Finney's RCS unittest patch

This involved an `upgrade' of BE's bzr repo
Previous version (via `bzr info path/to/repo`): pack-0.92
Current version: rich-root-pack

The whole rich-root thing is a bzr features-vs-backwards-compatability
thing they've been wrestling with [1,2,3,4,...].  It seems that BE was
in some sort of unstable equilibrium [5], so I'll follow Ben's lead
and make the official switch.  Note that you'll need to use bzr>=1.5
to make the shift [6].  For the sake of completeness, the whole
rich-root thing was introduced here [7], but I don't understand enough
of bzr to make sense of the diff.  It just versions the repo's root
directory the same way it versions other directories [3].  The bzr
people seem to be planning to phase out non-rich-root formats in favor
of brisbane-core, aka 2.0beta [8], by bzr 2.0 [8], which is apparently
on the horizon [9,10,11].  What a headache.

Citations are all titles/X-List-Received-Date from
  https://lists.ubuntu.com/archives/bazaar/
with the exception of the URL [11].

[1] [RFC] rich root pack as default in 1.8 ?
  Sat, 06 Sep 2008 03:33:46 -0000
  (conclusion: none)
[2] Re: 1.9rc1 countdown
  Thu, 30 Oct 2008 08:44:53 -0000
  (conclusion: "primary" format should be rich-root next time we make a new format)
[3] So many repo formats
  Fri, 14 Nov 2008 08:41:33 -0000
  Mon, 17 Nov 2008 07:37:47 -0000  (explains rich-root format)
  Mon, 17 Nov 2008 22:37:39 -0000  (explains no-return policy)
  Mon, 17 Nov 2008 20:57:08 -0000  (explicitly lists non-svn reasons for rich-root)
[4] Branch fails from 'pack-0.92' repo to 'rich-root-pack' repo.
  Wed, 27 Aug 2008 11:31:11 -0000
  (we're not sure again)
[5] Branch fails from 'pack-0.92' repo to 'rich-root-pack' repo.
  Sun, 20 Apr 2008 12:58:09 -0000
[6] Branch fails from 'pack-0.92' repo to 'rich-root-pack' repo.
  Fri, 29 Aug 2008 13:23:52 -0000
[7] [RFC] Knit format 2
  Fri, 25 Aug 2006 22:55:36 -0000
[8] bazaar 2.0beta format for launchpad release
  Fri, 29 May 2009 06:00:03 -0000
[9] Upgrading loggerhead to 1.9-rich-root
  Mon, 11 May 2009 22:35:28 -0000
  (mentions eventual switch to rich-root in 2.0)
[10] bzr 1.16rc1 released!
  Fri, 12 Jun 2009 08:00:08 -0000
  (confirms eventual switch to rich-root in 2.0)
[11] https://launchpad.net/bzr/+announcement/2733
  (current outstanding releases: 1.17, 2.0)

15 years agoConform new docstrings to PEP 257.
John Doe [Sat, 20 Jun 2009 23:51:39 +0000 (09:51 +1000)]
Conform new docstrings to PEP 257.

15 years agoAdded comments-from-stdin, so we can add tracebacks, e.g. with
W. Trevor King [Fri, 19 Jun 2009 20:26:01 +0000 (16:26 -0400)]
Added comments-from-stdin, so we can add tracebacks, e.g. with

  $ be list --invalid-option | be comment <bug-id> -

15 years agoAllow defaults for config.get_val() in case of missing user-config file.
W. Trevor King [Fri, 19 Jun 2009 19:16:49 +0000 (15:16 -0400)]
Allow defaults for config.get_val() in case of missing user-config file.

Fixes bug introduced by James Rowe's previous patch:

  $ be list
  Traceback (most recent call last):
    ...
    File ".../libbe/rcs.py", line 34, in _get_matching_rcs
      import arch
    File ".../libbe/arch.py", line 29, in <module>
      client = config.get_val("arch_client")
    File ".../libbe/config.py", line 70, in get_val
    File "/usr/lib/python2.5/codecs.py", line 817, in open
      file = __builtin__.open(filename, mode, buffering)
  IOError: [Errno 2] No such file or directory: '/home/wking/.bugs_everywhere'

15 years agoMerged James Rowe's arch-shouldn't-create-userwide-config-file patch.
James Rowe [Fri, 19 Jun 2009 19:10:34 +0000 (15:10 -0400)]
Merged James Rowe's arch-shouldn't-create-userwide-config-file patch.

From his email to the be-devel list:

From: James Rowe <jnrowe@ukfsn.org>
Date: Tue, 3 May 2009 11:44:41 +0000
Subject: [PATCH] Don't create config file unless we're using arch.

Hi,

  I find the current behaviour of creating a config file simply to set
a default for a revision control system I'm never going to use to be
a little annoying, the attached patch changes this behaviour to only
set the default in the config file if you're actually using arch.

Thanks,

James

15 years agoMerged Thomas Habets 2009-01-07 XML output for "be show".
W. Trevor King [Fri, 19 Jun 2009 18:42:15 +0000 (14:42 -0400)]
Merged Thomas Habets 2009-01-07 XML output for "be show".

I rewrote a few of his routines, e.g. generalizing
Comment.string_thread to run a caller-specified method avoided the
need for some duplicate code in Comment.xml_thread.  There was also a
reasonable reorganization of libbe.settings_object.versioned_property
because the <in_reply_to> field of the Comment.xml output was giving
me `-1' (= old settings_object.EMPTY) instead of None, even after I
had set comm.in_reply_to to None.  The rewritten versioned_property
avoids the ambiguity of UNPRIMED vs EMPTY, and avoids the stupididy of
my using EMPTY=-1 ;).

15 years agoRemoved unused libbe/restconvert.py and fixed a typo in README.dev
W. Trevor King [Fri, 19 Jun 2009 16:06:32 +0000 (12:06 -0400)]
Removed unused libbe/restconvert.py and fixed a typo in README.dev

15 years agoMerge from main branch.
W. Trevor King [Fri, 19 Jun 2009 15:09:03 +0000 (11:09 -0400)]
Merge from main branch.

15 years agolibbe/encoding.py
W. Trevor King [Fri, 19 Jun 2009 15:06:59 +0000 (11:06 -0400)]
libbe/encoding.py

15 years agoFollow existing docstring whitespace convention.
John Doe [Mon, 15 Jun 2009 10:13:22 +0000 (20:13 +1000)]
Follow existing docstring whitespace convention.

15 years agoDistinguish tests for VCS which can't handle an uninitialised identity.
John Doe [Sun, 14 Jun 2009 07:27:18 +0000 (17:27 +1000)]
Distinguish tests for VCS which can't handle an uninitialised identity.

15 years agoRefactor mega-testcases into separate true-or-false testcases.
John Doe [Sun, 14 Jun 2009 07:24:29 +0000 (17:24 +1000)]
Refactor mega-testcases into separate true-or-false testcases.

15 years agoMake RCS testcase subclasses dynamically.
John Doe [Sun, 14 Jun 2009 04:34:11 +0000 (14:34 +1000)]
Make RCS testcase subclasses dynamically.

15 years agoUse a more general regex to test GIT commits; GIT's output has changed.
Chris Ball [Sat, 13 Jun 2009 12:43:28 +0000 (08:43 -0400)]
Use a more general regex to test GIT commits; GIT's output has changed.

15 years agoXML output for "be show"
Thomas Habets [Wed, 7 Jan 2009 18:39:32 +0000 (19:39 +0100)]
XML output for "be show"

16 years agoFixed spelling mistake in test_usage.sh
W. Trevor King [Sun, 21 Dec 2008 05:35:12 +0000 (00:35 -0500)]
Fixed spelling mistake in test_usage.sh

16 years agoFixed lack of user_id caching in bugdir.BugDir
W. Trevor King [Thu, 4 Dec 2008 23:33:33 +0000 (18:33 -0500)]
Fixed lack of user_id caching in bugdir.BugDir

16 years agoClosed search bug
W. Trevor King [Thu, 4 Dec 2008 18:06:10 +0000 (13:06 -0500)]
Closed search bug

9a942b1d-a3b5-441d-8aef-b844700e1efa

Aaron says it's already implemented in the Bugs-Everywhere-Web, and
  $ be show `be list --status all --uuids` | grep -A5 -B5 XYZ
works pretty well for me on the command line.

16 years agoMerged in the successful per-tree-config branch.
W. Trevor King [Thu, 4 Dec 2008 17:42:22 +0000 (12:42 -0500)]
Merged in the successful per-tree-config branch.

16 years agoAdded per-tree default assignee option.
W. Trevor King [Thu, 4 Dec 2008 17:40:39 +0000 (12:40 -0500)]
Added per-tree default assignee option.

The new setting is currently only used when creating new bugs with
becommand/new.

16 years agoClosed a few old bugs that seem outdated/dealt with.
W. Trevor King [Thu, 4 Dec 2008 17:24:24 +0000 (12:24 -0500)]
Closed a few old bugs that seem outdated/dealt with.

16 years agoFixed missing directory error when merging comments onto a bare bug.
W. Trevor King [Thu, 4 Dec 2008 17:07:49 +0000 (12:07 -0500)]
Fixed missing directory error when merging comments onto a bare bug.

If bug_A had no comments (and so, no comment directory), changing
comment settings before saving raised missing directory errors.
save_settings had previously assumed the
 .be/bugs/XYZ/comments/
directory existed, which wasn't true for comment-less bugs.  Now it
checks, and creates the directory if necessary.

16 years agobecommands/severity and status now handle --complete appropriately.
W. Trevor King [Thu, 4 Dec 2008 16:56:34 +0000 (11:56 -0500)]
becommands/severity and status now handle --complete appropriately.

I also disabled interspersed options and arguments in
cmdutils.CmdOptionParser.  See
  http://docs.python.org/library/optparse.html
Now
  $ be severity xyz --complete
returns available severities.  It had previously returned
  --help --complete

16 years agoPer-tree status levels working.
W. Trevor King [Thu, 4 Dec 2008 16:32:57 +0000 (11:32 -0500)]
Per-tree status levels working.

16 years agoClosed 4a4609c8-1882-47de-9d30-fee410b8a802
W. Trevor King [Thu, 4 Dec 2008 15:44:29 +0000 (10:44 -0500)]
Closed 4a4609c8-1882-47de-9d30-fee410b8a802

Per-tree severity levels working.

16 years agoAdjusted becommands/list.py to use current bug severities levels.
W. Trevor King [Thu, 4 Dec 2008 15:40:24 +0000 (10:40 -0500)]
Adjusted becommands/list.py to use current bug severities levels.

16 years agobug severity verification now works with per-tree severities.
W. Trevor King [Thu, 4 Dec 2008 15:32:10 +0000 (10:32 -0500)]
bug severity verification now works with per-tree severities.

I adjusted the YAML format following
  http://pyyaml.org/ticket/11
  Unicode support
To remove '!!python/unicode' escapes and allow unicode in the output.
We can always have unicode in the output because the output is encoded
(as per the BugFile.encoding setting) before being sent to the outside
world.

16 years agoPer-tree settings now passed into bug module.
W. Trevor King [Thu, 4 Dec 2008 14:54:39 +0000 (09:54 -0500)]
Per-tree settings now passed into bug module.

becommands/severity gets the configured settings appropriately.

Todo:
  adjust setting-validation to compare against the current values.
  setup becommands/severity to --complete severities.

16 years agoAdded per-tree configurable severities.
W. Trevor King [Thu, 4 Dec 2008 14:14:01 +0000 (09:14 -0500)]
Added per-tree configurable severities.

They currently have no effect, but you can see them with
  $ be set
There's a lot of information in this one 'settings' variable.  I think
set will have to be specialized to handle arrays smoothly...

16 years agoCleaned up some older bugs.
W. Trevor King [Thu, 4 Dec 2008 13:52:23 +0000 (08:52 -0500)]
Cleaned up some older bugs.

16 years agoAdded support for bug reporter field.
W. Trevor King [Wed, 3 Dec 2008 00:23:04 +0000 (19:23 -0500)]
Added support for bug reporter field.

Closes e2f6514c-5f9f-4734-a537-daf3fbe7e9a0

16 years agoMerged decorator branch.
W. Trevor King [Wed, 3 Dec 2008 00:11:56 +0000 (19:11 -0500)]
Merged decorator branch.

16 years agoFixed comparison bug in Bug._get_time.
W. Trevor King [Wed, 3 Dec 2008 00:06:24 +0000 (19:06 -0500)]
Fixed comparison bug in Bug._get_time.

16 years agoAdded auto-completion for becommands/set property names.
W. Trevor King [Tue, 2 Dec 2008 16:12:56 +0000 (11:12 -0500)]
Added auto-completion for becommands/set property names.

16 years agoConverted Comment to the settings_object system.
W. Trevor King [Tue, 2 Dec 2008 16:06:00 +0000 (11:06 -0500)]
Converted Comment to the settings_object system.

16 years agoBug moved to the settings_object system.
W. Trevor King [Tue, 2 Dec 2008 15:39:52 +0000 (10:39 -0500)]
Bug moved to the settings_object system.

16 years agoAdded decorator-style properties to bugdir. Created settings_object module.
W. Trevor King [Tue, 2 Dec 2008 15:14:06 +0000 (10:14 -0500)]
Added decorator-style properties to bugdir.  Created settings_object module.

settings_object.SavedSettingsObject encapsulates some of the common
settings functionality in the BE BugDir, Bug, and Comment classes.
It's a bit awkward due to the nature of scoping in python subclasses,
but it's better than reproducing this code in each of the above classes.
Now I need to move Bug and Comment over to *this* system ;).

16 years agoAdded decorator-style properties to libbe/comment.py.
W. Trevor King [Mon, 1 Dec 2008 19:42:20 +0000 (14:42 -0500)]
Added decorator-style properties to libbe/comment.py.

Also some typo corrections and some reworking of bug/bugdir to better
support the lazier loading.

16 years agoFixed some erroneous "no test suite" messages in test.py.
W. Trevor King [Mon, 1 Dec 2008 19:08:59 +0000 (14:08 -0500)]
Fixed some erroneous "no test suite" messages in test.py.

16 years agoAdded libbe/properties to make property management easier.
W. Trevor King [Sat, 29 Nov 2008 04:08:10 +0000 (23:08 -0500)]
Added libbe/properties to make property management easier.

libbe/bug has been moved over to the new system.
comment and bugdir still to go.

16 years agoAdded more helpful error message for libbe modules missing test suites.
W. Trevor King [Fri, 28 Nov 2008 15:15:15 +0000 (10:15 -0500)]
Added more helpful error message for libbe modules missing test suites.

16 years agoOptimized bug loading from becommands/comment with partial-uuid matching.
W. Trevor King [Fri, 28 Nov 2008 00:35:55 +0000 (19:35 -0500)]
Optimized bug loading from becommands/comment with partial-uuid matching.

The code is a bit uglier now, but it's a good deal faster :).

16 years agoAdded becommands/comment completion.
W. Trevor King [Thu, 27 Nov 2008 16:34:44 +0000 (11:34 -0500)]
Added becommands/comment completion.

16 years agoCompletion support added to becommands/help
W. Trevor King [Thu, 27 Nov 2008 16:12:26 +0000 (11:12 -0500)]
Completion support added to becommands/help

16 years agoAdded bugid_args option to cmdutil.default_complete.
W. Trevor King [Thu, 27 Nov 2008 16:03:21 +0000 (11:03 -0500)]
Added bugid_args option to cmdutil.default_complete.

Now most of the bug-id arguments support Bash completion.  Since there
will hopefully be lots of bugs in the database, I decided to filter
the list of available bugs.  Currently, we just auto-complete active
bugs for most commands, with the exceptions of open (obviously) and
status (which needs to work on all types of bugs).

16 years agoCommand completion simplified and working for list, dummies for other cmds.
W. Trevor King [Thu, 27 Nov 2008 15:16:18 +0000 (10:16 -0500)]
Command completion simplified and working for list, dummies for other cmds.

All the other commands currently use default_complete(), which has no
effect other than catching the --complete option and effectively
aborting execution.

This closes 8e1bbda4-35b6-4579-849d-117b1596ee99

16 years agoMerged --commands and --options into --complete. Simpler that way.
W. Trevor King [Thu, 27 Nov 2008 14:34:54 +0000 (09:34 -0500)]
Merged --commands and --options into --complete.  Simpler that way.

16 years agoBasic bash completion is now supported.
W. Trevor King [Thu, 27 Nov 2008 14:26:52 +0000 (09:26 -0500)]
Basic bash completion is now supported.

I'm still working on a clean implementation though...

16 years agoFixed typo in becommands/comment help string.
W. Trevor King [Thu, 27 Nov 2008 13:06:12 +0000 (08:06 -0500)]
Fixed typo in becommands/comment help string.

16 years agoAdded --commands option to be to help with bash completion.
W. Trevor King [Thu, 27 Nov 2008 12:35:40 +0000 (07:35 -0500)]
Added --commands option to be to help with bash completion.

A'la ditz
  http://gitorious.org/projects/ditz

See also this good intro to bash completion
  http://www.debian-administration.org/articles/317

16 years agoAdded -a/n/m/r to becommands/diff.py.
W. Trevor King [Tue, 25 Nov 2008 21:45:42 +0000 (16:45 -0500)]
Added -a/n/m/r to becommands/diff.py.

16 years agoadded -u/uuids option to becommands/list
W. Trevor King [Tue, 25 Nov 2008 21:07:08 +0000 (16:07 -0500)]
added -u/uuids option to becommands/list

16 years agoAdded libbe/encoding.py to wrap input/output/file access appropriately.
W. Trevor King [Tue, 25 Nov 2008 20:47:19 +0000 (15:47 -0500)]
Added libbe/encoding.py to wrap input/output/file access appropriately.

I borrowed most of the code for this.

get_encoding() is from Trac
  http://trac.edgewall.org/browser/trunk/trac/util/datefmt.py
  format_datetime()
Trac has a BSD license
  http://trac.edgewall.org/wiki/TracLicense
I don't know if such a small snippet requires us to "reproduce the
above copyright" or where we need to reproduce it if it is needed.

The stdout/stdin replacement code follows
  http://wiki.python.org/moin/ShellRedirectionFails

Because of the stdout replacement, the doctests executes now need an
optional 'test' argument to turn off replacement during the doctests,
otherwise doctest flips out (since it had set up stdout to catch
output, and then we clobbered it's setup).

References:
  http://wiki.python.org/moin/Unicode
  http://www.amk.ca/python/howto/unicode
  http://www.python.org/dev/peps/pep-0100/

I also split libbe/editor.py off from libbe.utility.py and started
explaining the motivation for the BugDir init flags in it's docstring.

16 years agoOops, should be passing libbe.tree.Tree.sort() args to children. Fixed.
W. Trevor King [Tue, 25 Nov 2008 12:12:52 +0000 (07:12 -0500)]
Oops, should be passing libbe.tree.Tree.sort() args to children.  Fixed.

16 years agoHack to fixe encoding bug in becommands/show
W. Trevor King [Tue, 25 Nov 2008 03:03:20 +0000 (22:03 -0500)]
Hack to fixe encoding bug in becommands/show

The situation really calls for a global encoding setting rather than
lots of hardcoded "utf-8"s.  See bug
  f7ccd916-b5c7-4890-a2e3-8c8ace17ae3a

16 years agoAdded becommands/merge to join duplicate bugs.
W. Trevor King [Tue, 25 Nov 2008 02:20:56 +0000 (21:20 -0500)]
Added becommands/merge to join duplicate bugs.

16 years agoAdjusted becommands/set to handle user_id properly.
W. Trevor King [Tue, 25 Nov 2008 02:15:55 +0000 (21:15 -0500)]
Adjusted becommands/set to handle user_id properly.

16 years agoAdded invalid-value checking to becommands/set.py.
W. Trevor King [Tue, 25 Nov 2008 01:55:24 +0000 (20:55 -0500)]
Added invalid-value checking to becommands/set.py.

Kindof a cludgy check, but there's currently no simpler way to find
valid entries for a given setting name (that I can think of).

16 years agoMerge from W. Trevor King's tree.
W. Trevor King [Mon, 24 Nov 2008 23:29:16 +0000 (18:29 -0500)]
Merge from W. Trevor King's tree.

16 years agoTweaked usage strings to increase consistency. Also added README.dev.
W. Trevor King [Mon, 24 Nov 2008 22:02:16 +0000 (17:02 -0500)]
Tweaked usage strings to increase consistency.  Also added README.dev.

I tried to stick to CAPS for argument placeholders.

16 years agoFixed broken doctest and inconsitent indentation from not wrapping comments.
W. Trevor King [Mon, 24 Nov 2008 21:30:52 +0000 (16:30 -0500)]
Fixed broken doctest and inconsitent indentation from not wrapping comments.

Also emptied becommands/__init__.py.  I didn't understand the plugin
interface when I wrote it.

16 years agoMarked c45e5ece-63e3-4fd2-b33f-0bfd06820cf4 as fixed.
W. Trevor King [Mon, 24 Nov 2008 13:49:44 +0000 (08:49 -0500)]
Marked c45e5ece-63e3-4fd2-b33f-0bfd06820cf4 as fixed.

It's been fixed for a while

16 years agoRemoved auto-wrapping from comment.Comment.string().
W. Trevor King [Mon, 24 Nov 2008 13:11:08 +0000 (08:11 -0500)]
Removed auto-wrapping from comment.Comment.string().

It makes tracebacks almost illegible.  I doubt markup/markdown systax
or auto-formatting is really useful, since bugs-reports are ususally a
short comment and a traceback.

I also closed a4d38ba7-ec28-4096-a4f3-eb8c9790ffb2 and
7bfc591e-584a-476e-8e11-b548f1afcaa6, which have probably been fixed
for a long time...

16 years agoAdded Bug.comments(), BugDir.has_bug() & cleaned up diff.diff().
W. Trevor King [Mon, 24 Nov 2008 12:47:06 +0000 (07:47 -0500)]
Added Bug.comments(), BugDir.has_bug() & cleaned up diff.diff().

+ some other minor fixes and cleanups.

16 years agoReplaced direct filesystem read from bugdir.py with RCS mediated read.
W. Trevor King [Mon, 24 Nov 2008 12:31:51 +0000 (07:31 -0500)]
Replaced direct filesystem read from bugdir.py with RCS mediated read.

Also replaced utility.FileString with StringIO() in cmdutil.py, which
allowed the removal of utility.FileString and utility.get_file.

The only remaining file().read() outside the RCS framework is the read
in utility.editor_string(), but should probably not go through the
RCS.

16 years agoAdded 'allow_no_rcs' flag to RCS file system access methods.
W. Trevor King [Mon, 24 Nov 2008 12:09:03 +0000 (07:09 -0500)]
Added 'allow_no_rcs' flag to RCS file system access methods.

Now mapfile access has fewer special cases, and there is less
redundant rcs.add/update code.

16 years agoCreated bugdir.MultipleBugMatches so bugdir no longer imports cmdutil.
W. Trevor King [Sun, 23 Nov 2008 19:46:51 +0000 (14:46 -0500)]
Created bugdir.MultipleBugMatches so bugdir no longer imports cmdutil.

16 years agoRemoved outdated beuuid import from libbe/bugdir.py
W. Trevor King [Sun, 23 Nov 2008 15:58:40 +0000 (10:58 -0500)]
Removed outdated beuuid import from libbe/bugdir.py

16 years agolibbe/diff.diff() was missing newly created bugs. Fixed.
W. Trevor King [Sun, 23 Nov 2008 15:08:18 +0000 (10:08 -0500)]
libbe/diff.diff() was missing newly created bugs.  Fixed.

Also added blank lines to separate the new/modified/removed groups.

16 years agoGo back to lazy bug loading to get execution speed back up.
W. Trevor King [Sun, 23 Nov 2008 14:50:56 +0000 (09:50 -0500)]
Go back to lazy bug loading to get execution speed back up.

Fixes bug b3c6da51-3a30-42c9-8c75-587c7a1705c5

16 years agoImproved user-id saving/loading/caching & save user-id into duplicate bugdirs.
W. Trevor King [Sun, 23 Nov 2008 13:43:40 +0000 (08:43 -0500)]
Improved user-id saving/loading/caching & save user-id into duplicate bugdirs.

Fixes the duplicate bugs
  a403de79-8f39-41f2-b9ec-15053b175ee2
  c894f10f-197d-4b22-9c5b-19f394df40d4

16 years agoAdded bugdir user-id caching and save/load from settings file.
W. Trevor King [Sun, 23 Nov 2008 13:16:19 +0000 (08:16 -0500)]
Added bugdir user-id caching and save/load from settings file.

16 years ago`be show` now supports showing multiple bugs with a single call.
W. Trevor King [Sun, 23 Nov 2008 12:40:11 +0000 (07:40 -0500)]
`be show` now supports showing multiple bugs with a single call.

16 years agoOops, dba25cfd-aa15-457c-903a-b53ecb5a3b2c was fixed with commit 253.
W. Trevor King [Sun, 23 Nov 2008 12:31:14 +0000 (07:31 -0500)]
Oops, dba25cfd-aa15-457c-903a-b53ecb5a3b2c was fixed with commit 253.

16 years agoOops, dac91856-cb6a-4f69-8c03-38ff0b29aab2 was fixed with commit 242.
W. Trevor King [Sun, 23 Nov 2008 12:26:15 +0000 (07:26 -0500)]
Oops, dac91856-cb6a-4f69-8c03-38ff0b29aab2 was fixed with commit 242.

16 years agoFixed "'NoneType' object is not callable" error in libbe/utility/Dir.__del__
W. Trevor King [Sun, 23 Nov 2008 12:19:36 +0000 (07:19 -0500)]
Fixed "'NoneType' object is not callable" error in libbe/utility/Dir.__del__

16 years agoAdded archive/project init code for `./test_usage.sh arch`.
W. Trevor King [Sun, 23 Nov 2008 11:51:30 +0000 (06:51 -0500)]
Added archive/project init code for `./test_usage.sh arch`.

Also some minor cleanups.

16 years agoExplicit rcs.cleanup() in bugdir test.
W. Trevor King [Sun, 23 Nov 2008 00:45:37 +0000 (19:45 -0500)]
Explicit rcs.cleanup() in bugdir test.

Don't use del(rcs), because if there was an error, there is still a
reference to rcs in the traceback, so it is never cleaned up.  This
can leave the external archive cluttering up your Arch install if
you're using the Arch backend.  See the __del__ documentation

  http://python.active-venture.com/ref/customization.html#l2h-175

for details.

Also fixed some out-of-date method names in libbe.diff

16 years agolibbe.utility.Dir was complaining of a missing shutil in __del__().
W. Trevor King [Sat, 22 Nov 2008 21:46:42 +0000 (16:46 -0500)]
libbe.utility.Dir was complaining of a missing shutil in __del__().

Presumably the cleanup process removed shutil before cleaning up the Dir.
Now Dir keeps a local reference.

16 years agoOops, bug 8e83da06-26f1-4763-a972-dae7e7062233 was fixed by commit 254.
W. Trevor King [Sat, 22 Nov 2008 21:30:24 +0000 (16:30 -0500)]
Oops, bug 8e83da06-26f1-4763-a972-dae7e7062233 was fixed by commit 254.

16 years agoCreated and fixed bug 496edad5-1484-413a-bc68-4b01274a65eb.
W. Trevor King [Sat, 22 Nov 2008 21:15:16 +0000 (16:15 -0500)]
Created and fixed bug 496edad5-1484-413a-bc68-4b01274a65eb.

I figured out why Arch was complaining.  For non-Arch users, file
system access has been tweaked a bit see the BugDir doc string for
details.  Also, you should now set BugDir.rcs instead of .rcs_name.
.rcs_name automatically tracks changes in .rcs (the reverse of the
previous situation), so read from whichever you like.

16 years agoOops, these new submods are used by the new, classified Bug & BugDir.
W. Trevor King [Sat, 22 Nov 2008 21:14:04 +0000 (16:14 -0500)]
Oops, these new submods are used by the new, classified Bug & BugDir.

I'd forgotten tell bzr...

16 years agoAnother major rewrite. Now BugDir, Bug, and Comment are more distinct.
W. Trevor King [Fri, 21 Nov 2008 19:56:05 +0000 (14:56 -0500)]
Another major rewrite.  Now BugDir, Bug, and Comment are more distinct.

I pushed a lot of the little helper functions into the main classes,
which makes it easier for me to keep track of what's going on.  I'm
now at the point where I can run through `python test.py` with each of
the backends (by changing the search order in rcs.py
_get_matching_rcs) without any unexpected errors for each backend
(except Arch).  I can also run `test_usage.sh` without non-Arch errors
either.

However, don't consider this a stable commit yet.  The bzr backend is
*really*slow*, and the other's aren't blazingly fast either.  I think
I'm rewriting the entire database every time I save it :p.  Still, it
passes the checks. and I don't like it when zounds of changes build up.