# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
import os
+import shutil
import tempfile
import time
import urlparse
"""Create empty package for new one under CWD
"""
- import shutil
- shutil.rmtree(prj, ignore_errors = True)
-
core.make_dir(self.apiurl, prj, pkg, pathname = '.')
pkg_path = os.path.join(prj, pkg)
shutil.rmtree(pkg_path, ignore_errors = True)
- core.createPackageDir(pkg_path)
+ os.chdir(prj)
+ core.createPackageDir(pkg)
def submit(self, msg, wd='.'):
if not core.is_package_dir(wd):
from __future__ import with_statement
import os
+import shutil
import buildservice
import runner
import msger
if not os.path.exists(self._bdir):
os.makedirs(self._bdir)
+ with _Workdir(self._bdir):
+ shutil.rmtree(prj, ignore_errors = True)
+
if self._bs.isNewPackage(prj, pkg):
# to init new package in local dir
self._mkpac()