From: Yann Dirson <ydirson@altern.org>
To: Catalin Marinas <catalin.marinas@gmail.com>
Cc: git@vger.kernel.org
Subject: [PATCH 1/2] Cleanup variable names in pick.
Date: Sat, 05 May 2007 16:00:23 +0200 [thread overview]
Message-ID: <20070505140023.5194.8083.stgit@gandelf.nowhere.earth> (raw)
In-Reply-To: <20070505135830.5194.90861.stgit@gandelf.nowhere.earth>
I'm going to need patch objects there, so avoid using variable "patch"
to store only a patchname.
Signed-off-by: Yann Dirson <ydirson@altern.org>
---
stgit/commands/pick.py | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/stgit/commands/pick.py b/stgit/commands/pick.py
index edd614d..4eb79a3 100644
--- a/stgit/commands/pick.py
+++ b/stgit/commands/pick.py
@@ -71,11 +71,11 @@ def func(parser, options, args):
else:
patch_branch = commit_str.split('@')
if options.name:
- patch = options.name
+ patchname = options.name
elif len(patch_branch) == 2:
- patch = patch_branch[0]
+ patchname = patch_branch[0]
else:
- patch = make_patch_name(commit.get_log(), crt_series.patch_exists)
+ patchname = make_patch_name(commit.get_log(), crt_series.patch_exists)
if options.parent:
parent = git_id(options.parent)
@@ -118,17 +118,17 @@ def func(parser, options, args):
print 'Importing commit %s...' % commit_id,
sys.stdout.flush()
- crt_series.new_patch(patch, message = message, can_edit = False,
+ crt_series.new_patch(patchname, message = message, can_edit = False,
unapplied = True, bottom = bottom, top = top,
author_name = author_name,
author_email = author_email,
author_date = author_date)
if not options.unapplied:
- modified = crt_series.push_patch(patch)
+ modified = crt_series.push_patch(patchname)
else:
modified = False
- if crt_series.empty_patch(patch):
+ if crt_series.empty_patch(patchname):
print 'done (empty patch)'
elif modified:
print 'done (modified)'
next prev parent reply other threads:[~2007-05-05 16:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-05 14:00 [StGIT PATCH 0/2] Improving patchlogs Yann Dirson
2007-05-05 14:00 ` Yann Dirson [this message]
2007-05-05 14:00 ` [PATCH 2/2] Copy patchlogs when cloning a stack or picking a patch Yann Dirson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070505140023.5194.8083.stgit@gandelf.nowhere.earth \
--to=ydirson@altern.org \
--cc=catalin.marinas@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).