|
|
@ -4,6 +4,7 @@
|
|
|
|
from gi.repository import GObject
|
|
|
|
from gi.repository import GObject
|
|
|
|
from sys import argv
|
|
|
|
from sys import argv
|
|
|
|
import dbus
|
|
|
|
import dbus
|
|
|
|
|
|
|
|
from os.path import abspath
|
|
|
|
from pamac import common, transaction, main
|
|
|
|
from pamac import common, transaction, main
|
|
|
|
|
|
|
|
|
|
|
|
# i18n
|
|
|
|
# i18n
|
|
|
@ -42,7 +43,9 @@ def get_pkgs(pkgs):
|
|
|
|
get_error = ''
|
|
|
|
get_error = ''
|
|
|
|
for pkg in pkgs:
|
|
|
|
for pkg in pkgs:
|
|
|
|
if '.pkg.tar.' in pkg:
|
|
|
|
if '.pkg.tar.' in pkg:
|
|
|
|
transaction.to_load.add(pkg)
|
|
|
|
full_path = abspath(pkg)
|
|
|
|
|
|
|
|
print('path',full_path)
|
|
|
|
|
|
|
|
transaction.to_load.add(full_path)
|
|
|
|
elif pkg in transaction.syncpkgs.keys():
|
|
|
|
elif pkg in transaction.syncpkgs.keys():
|
|
|
|
transaction.to_add.add(pkg)
|
|
|
|
transaction.to_add.add(pkg)
|
|
|
|
else:
|
|
|
|
else:
|
|
|
@ -73,6 +76,7 @@ def install(pkgs):
|
|
|
|
exiting(_error)
|
|
|
|
exiting(_error)
|
|
|
|
else:
|
|
|
|
else:
|
|
|
|
main.set_transaction_sum()
|
|
|
|
main.set_transaction_sum()
|
|
|
|
|
|
|
|
if len(main.transaction_sum) != 0:
|
|
|
|
main.ConfDialog.show_all()
|
|
|
|
main.ConfDialog.show_all()
|
|
|
|
loop.run()
|
|
|
|
loop.run()
|
|
|
|
else:
|
|
|
|
else:
|
|
|
@ -81,6 +85,12 @@ def install(pkgs):
|
|
|
|
if response:
|
|
|
|
if response:
|
|
|
|
main.WarningDialog.hide()
|
|
|
|
main.WarningDialog.hide()
|
|
|
|
exiting('')
|
|
|
|
exiting('')
|
|
|
|
|
|
|
|
else:
|
|
|
|
|
|
|
|
main.WarningDialog.format_secondary_text(_('Nothing to do'))
|
|
|
|
|
|
|
|
response = main.WarningDialog.run()
|
|
|
|
|
|
|
|
if response:
|
|
|
|
|
|
|
|
main.WarningDialog.hide()
|
|
|
|
|
|
|
|
exiting('')
|
|
|
|
|
|
|
|
|
|
|
|
loop = GObject.MainLoop()
|
|
|
|
loop = GObject.MainLoop()
|
|
|
|
|
|
|
|
|
|
|
|