From 859fbf4a83f2806fdd785ca2f312d7dca8b2163e Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 14 Jul 2009 08:13:47 -0400 Subject: Updated GPLv2 to current GPLv2. Fixes Ben's bug 00f26f04-9202-4288-8744-b29abc2342d6. I also tweaked update_copyright.sh to make possible future copyright-blurb revision easier. The new algorithm is greedier, overwriting _all_ consecutive comments after a '^# Copyright' line, so do # Copyright # GPL ... GPL ... GPL # Your comment here... not # Copyright # GPL ... GPL ... GPL # # Your comment here... Without the blank line, your comment would get overwritten by the next run of update_copyright.sh. Note that catmutt is ignored by update_copyright.sh because Moritz Barsnick has only licensed his grepm code under the GPLv2 (not GPLv>=2). See the initial catmutt commit for details. --- libbe/cmdutil.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'libbe/cmdutil.py') diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py index 7589241..36d5d96 100644 --- a/libbe/cmdutil.py +++ b/libbe/cmdutil.py @@ -2,19 +2,19 @@ # Oleg Romanyshyn # W. Trevor King # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. # -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# You should have received a copy of the GNU General Public License along +# with this program; if not, write to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. import glob import optparse import os -- cgit From b3ce47285a66a35904e5e50636ce471ecb4ce29d Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sun, 19 Jul 2009 10:48:12 -0400 Subject: Added becommands/commit.py and minor fixes. Now we can commit changes from the command line with a unified interface. The interface is much less flexible than using your particular version control system's commit command directly, so this command is mostly intended for user-interfaces and other tools that don't want to be bothered with the extra flexibility. Normalized spacing in rcs.RCS.commit to produce: summary body messages regardless of the input string format. Also fixed a "--complete" handline bug in cmdutil, and some minor docstring typos in libbe.rcs and .editor. --- libbe/cmdutil.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libbe/cmdutil.py') diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py index 36d5d96..bba3e0e 100644 --- a/libbe/cmdutil.py +++ b/libbe/cmdutil.py @@ -163,7 +163,7 @@ def default_complete(options, args, parser, bugid_args={}): """ for option,value in option_value_pairs(options, parser): if value == "--complete": - raise cmdutil.GetCompletions() + raise GetCompletions() if len(bugid_args.keys()) > 0: max_pos_arg = max(bugid_args.keys()) else: -- cgit From a6d5f2891dc353ebe5d9d8598790a6674c174eec Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sun, 19 Jul 2009 15:24:51 -0400 Subject: Added --allow-empty to "be commit" Previously many backends would silently add an empty commit. Not very useful. When the new --allow-empty flag and related allow_empty options are false, every versioning backend is guaranteed to raise the EmptyCommit exception in the case of an attempted empty commit. --- libbe/cmdutil.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'libbe/cmdutil.py') diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py index bba3e0e..853a75a 100644 --- a/libbe/cmdutil.py +++ b/libbe/cmdutil.py @@ -73,8 +73,10 @@ def get_command(command_name): def execute(cmd, args): enc = encoding.get_encoding() cmd = get_command(cmd) - cmd.execute([a.decode(enc) for a in args]) - return 0 + ret = cmd.execute([a.decode(enc) for a in args]) + if ret == None: + ret = 0 + return ret def help(cmd=None, parser=None): if cmd != None: -- cgit