From: Catalin Marinas <catalin.marinas@gmail.com>
To: git@vger.kernel.org
Cc: "Karl Hasselström" <kha@treskal.com>
Subject: [StGIT PATCH 4/5] Convert "init" to the new StGIT infrastructure
Date: Fri, 06 Jun 2008 21:46:02 +0100 [thread overview]
Message-ID: <20080606204602.8805.44240.stgit@localhost.localdomain> (raw)
In-Reply-To: <20080606204322.8805.32313.stgit@localhost.localdomain>
Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
---
stgit/commands/init.py | 14 ++++----------
1 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/stgit/commands/init.py b/stgit/commands/init.py
index 475a4ce..b68acd7 100644
--- a/stgit/commands/init.py
+++ b/stgit/commands/init.py
@@ -16,13 +16,8 @@ along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"""
-import sys, os
-from optparse import OptionParser, make_option
-
-from stgit.commands.common import *
-from stgit.utils import *
-from stgit import stack, git
-
+from stgit.commands import common
+from stgit.lib import stack
help = 'initialise the current branch for use with StGIT'
usage = """%prog [options]
@@ -31,14 +26,13 @@ Initialise the current GIT branch to be used as an StGIT stack. Note
that you must already be in a GIT repository and .git/HEAD must point
to a valid file in refs/heads/."""
-directory = DirectoryHasRepository()
+directory = common.DirectoryHasRepositoryLib()
options = []
-
def func(parser, options, args):
"""Performs the repository initialisation
"""
if len(args) != 0:
parser.error('incorrect number of arguments')
- crt_series.init()
+ stack.Stack.initialise(directory.repository)
next prev parent reply other threads:[~2008-06-06 20:47 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-06 20:45 [StGIT PATCH 0/5] Proposed patches Catalin Marinas
2008-06-06 20:45 ` [StGIT PATCH 1/5] Rename Repository.head to Repository.head_ref Catalin Marinas
2008-06-07 9:09 ` Karl Hasselström
2008-06-06 20:45 ` [StGIT PATCH 2/5] Create a git.Branch class as ancestor of stack.Stack Catalin Marinas
2008-06-07 9:16 ` Karl Hasselström
2008-06-06 20:45 ` [StGIT PATCH 3/5] Add stack creation and initialisation support to lib.Stack Catalin Marinas
2008-06-07 9:30 ` Karl Hasselström
2008-06-08 22:03 ` Catalin Marinas
2008-06-06 20:46 ` Catalin Marinas [this message]
2008-06-07 9:32 ` [StGIT PATCH 4/5] Convert "init" to the new StGIT infrastructure Karl Hasselström
2008-06-06 20:46 ` [StGIT PATCH 5/5] Add test_patches target to Makefile Catalin Marinas
2008-06-07 9:42 ` Karl Hasselström
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=20080606204602.8805.44240.stgit@localhost.localdomain \
--to=catalin.marinas@gmail.com \
--cc=git@vger.kernel.org \
--cc=kha@treskal.com \
/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