Beispiel #1
0
    def exportDocs(self, version):
        branchName = "import-v{}".format(version)

        if not goTo(DOCSDIR):
            User.pause()
            return

        if check_call(shlex.split("make websitedoc")) != 0:
            print("error while calling 'make websitedoc'")
            exit(3)

        Git.chdirToRepositoryTopLevel()
        if not goTo("website"):
            User.pause()
            return

        Git.checkout(branchName, create=True)
        Git.add('.')
        Git.commit("update for offlineimap v{}".format(version))

        User.pause(
            "website: branch '{}' is ready for a merge in master!".format(
                branchName))
        goTo('..')
        return branchName
Beispiel #2
0
 def make(self):
     Git.add('offlineimap/__init__.py')
     Git.add('Changelog.md')
     commitMsg = "v{}\n".format(newVersion)
     for tester in self.testers.getListOk():
         commitMsg = "{}\nTested-by: {} {}".format(
             commitMsg, tester.getName(), tester.getEmail()
         )
     Git.commit(commitMsg)
     self.state.setTag(newVersion)
     Git.tag(newVersion)
     Git.checkout('master')
     Git.mergeFF('next')
     Git.checkout('next')
Beispiel #3
0
    def createImportBranch(self, version):
        branchName = "import-v{}".format(version)

        Git.chdirToRepositoryTopLevel()
        if not goTo("website"):
            User.pause()
            return

        Git.checkout(branchName, create=True)
        Git.add('.')
        Git.commit("update for offlineimap v{}".format(version))

        User.pause(
            "website: branch '{}' is ready for a merge in master!".format(
                branchName))
        goTo('..')
        return branchName
Beispiel #4
0
    def restore(self):
        Git.chdirToRepositoryTopLevel()
        try:
            Git.checkout('-f')
        except:
            pass
        # Git.checkout('master')
        # Git.resetKeep(self.master)
        # Git.checkout('next')
        # Git.resetKeep(self.next)

        if self.tag is not None:
            Git.rmTag(self.tag)

        if self.website is not None:
            if goTo('website'):
                Git.checkout(self.website)
                goTo('..')
Beispiel #5
0
 def prepare(self):
     if not Git.isClean():
         print("The git repository is not clean; aborting")
         exit(1)
     Git.makeCacheDir()
     Git.checkout('next')