miliskur.py-guncelleme

This commit is contained in:
milisman 2016-10-09 02:10:44 +03:00
parent e10feb7fc5
commit 91f3cc0d43
1 changed files with 9 additions and 6 deletions

View File

@ -101,30 +101,33 @@ def formatDialog(part):
choosePart()
def formatPart(part):
runShellCommand("mkfs.ext4 "+"/dev/"+part)
os.system("mkfs.ext4 "+"/dev/"+part)
d.infobox(text="/dev/"+part+" Disk Formatlandı")
chooseSwap()
hedef="/dev/"+part
hedefBagla(hedef)
def hedefBagla(hedef):
runShellCommand("umount /mnt && mount "+hedef+" /mnt")
os.system("umount /mnt && mount "+hedef+" /mnt")
sistemKopyala()
def sistemKopyala():
runShellCommand("cp -axvnu / /mnt")
os.system("cp -axvnu / /mnt")
initrdOlustur()
def initrdOlustur():
runShellCommand("chroot /mnt dracut --no-hostonly --add-drivers "'ahci'" -f /boot/initramfs")
os.system("mount —bind /dev /mnt/dev")
os.system("mount —bind /sys /mnt/sys")
os.system("mount —bind /proc /mnt/proc")
os.system("chroot /mnt dracut --no-hostonly --add-drivers "'ahci'" -f /boot/initramfs")
if d.yesno(text="Grub kurmak istiyor musunuz ?") == "ok":
grubKur()
else:
kurulumBitir()
def grubKur():
runShellCommand("chroot /mnt grub-install --boot-directory=/mnt/boot /dev/sda")
runShellCommand("chroot /mnt grub-mkconfig -o /boot/grub/grub.cfg")
os.system("grub-install --boot-directory=/mnt/boot /dev/sda")
os.system("grub-mkconfig -o /boot/grub/grub.cfg")
kurulumBitir()
def kurulumBitir():