equal
deleted
inserted
replaced
29 from logilab.common import IGNORED_EXTENSIONS |
29 from logilab.common import IGNORED_EXTENSIONS |
30 from logilab.common.decorators import cached |
30 from logilab.common.decorators import cached |
31 from logilab.common.configuration import REQUIRED, read_old_config |
31 from logilab.common.configuration import REQUIRED, read_old_config |
32 from logilab.common.shellutils import ASK |
32 from logilab.common.shellutils import ASK |
33 from logilab.common.changelog import Version |
33 from logilab.common.changelog import Version |
|
34 from logilab.common.deprecation import deprecated |
34 |
35 |
35 from cubicweb import ConfigurationError, ExecutionError |
36 from cubicweb import ConfigurationError, ExecutionError |
36 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg |
37 from cubicweb.cwconfig import CubicWebConfiguration as cwcfg |
37 from cubicweb.toolsutils import show_diffs |
38 from cubicweb.toolsutils import show_diffs |
38 |
39 |
405 if not p in origcubes] |
406 if not p in origcubes] |
406 if newcubes: |
407 if newcubes: |
407 self.config.add_cubes(newcubes) |
408 self.config.add_cubes(newcubes) |
408 return newcubes |
409 return newcubes |
409 |
410 |
|
411 @deprecated('[3.20] use drop_cube() instead of remove_cube()') |
410 def cmd_remove_cube(self, cube, removedeps=False): |
412 def cmd_remove_cube(self, cube, removedeps=False): |
|
413 return self.cmd_drop_cube(cube, removedeps) |
|
414 |
|
415 def cmd_drop_cube(self, cube, removedeps=False): |
411 if removedeps: |
416 if removedeps: |
412 toremove = self.config.expand_cubes([cube]) |
417 toremove = self.config.expand_cubes([cube]) |
413 else: |
418 else: |
414 toremove = (cube,) |
419 toremove = (cube,) |
415 origcubes = self.config._cubes |
420 origcubes = self.config._cubes |