Skip to content

Commit

Permalink
feat: replace update alert with standard info window in order to allo…
Browse files Browse the repository at this point in the history
…w stable cli usage
  • Loading branch information
marcantondahmen committed Mar 25, 2022
1 parent 10bef1f commit b572be1
Showing 1 changed file with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from rpm.system.ui import UI
from rpm.system.update import Update
from pyrevit.coreutils.ribbon import ICON_LARGE
from pyrevit import forms
from pyrevit import script

__context__ = 'zero-doc'

Expand All @@ -14,12 +14,16 @@ def __selfinit__(script_cmp, ui_button_cmp, __rvt__):
ui_button_cmp.set_title('Install\nUpdates')
update_icon = script_cmp.get_bundle_file('icon-has-updates.png')
ui_button_cmp.set_icon(update_icon, icon_size=ICON_LARGE)
forms.alert(
'There are some pyRevit updates ready to be installed.\n\n'
'Please run "Revitron > RPM > Install Updates" to update pyRevit and extensions.',
title='pyRevit Updates',
options=['Ok, I got it!']
UI.printLogo()
UI.printTitle()
out = script.get_output()
out.print_html(
'<p>'
'There are some pyRevit updates ready to be installed.\n'
'Please run <strong>Revitron > RPM > Install Updates</strong> to update pyRevit and extensions.'
'</p>'
)

return True


Expand Down

0 comments on commit b572be1

Please sign in to comment.