[anaconda/blivet][master] Move installation specific code to anaconda's codebase

Vratislav Podzimek vpodzime at redhat.com
Fri Jan 23 14:14:47 UTC 2015


These four patches move installation specific code from blivet to
anaconda. Being used only as part of the installation process such code doesn't
belong to blivet's codebase.

The GH Blivet issue [0] suggests moving also shouldClear and clearPartitions,
but clearPartitions is used by blivet's tests to initialize loop devices for
running tests and shouldClear is used by clearPartitions and getFreeSpace. It
would be possible to pass shouldClear-type-of-function as a parameter to
clearPartitions and getFreeSpace with a default value of None meaning nothing
(or everything?) should be cleared, but I'm leaving that for future patch set.

[0] https://github.com/rhinstaller/blivet/issues/25

This is the first step, the other two are dealing with shouldClear as mentioned
above and cleaning up the new code in pyanaconda/autopart.py and
storage_utils.py so that it better matches coding style etc.

Although it is quite a big number of added/changed lines, it's mainly just a
copy-paste from blivet sources with fixed imports and Blivet's _sysroot replaced
by iutil.getSysroot(). I ran several autopart installations and everything seems
to be okay.

Vratislav Podzimek (2):
  Move autopart and swap suggesting functionality to anaconda
  Move code related to finding existing installations to anaconda

 anaconda                                |   4 +-
 pyanaconda/autopart.py                  | 497 ++++++++++++++++++++++++++++++++
 pyanaconda/installclass.py              |   4 +-
 pyanaconda/kickstart.py                 |  10 +-
 pyanaconda/rescue.py                    |   6 +-
 pyanaconda/storage_utils.py             | 218 ++++++++++++++
 pyanaconda/ui/gui/spokes/custom.py      |   4 +-
 pyanaconda/ui/gui/spokes/lib/refresh.py |   5 +-
 pyanaconda/ui/gui/spokes/storage.py     |   6 +-
 pyanaconda/ui/tui/spokes/storage.py     |   3 +-
 10 files changed, 738 insertions(+), 19 deletions(-)
 create mode 100644 pyanaconda/autopart.py

-- 
2.1.0



More information about the anaconda-patches mailing list