diff options
-rw-r--r-- | NEWS | 2 | ||||
-rwxr-xr-x | mgaapplet | 52 | ||||
-rwxr-xr-x | mgaapplet-add-media-helper | 10 | ||||
-rwxr-xr-x | mgaapplet-config | 8 | ||||
-rw-r--r-- | mgaonline.pm | 18 |
5 files changed, 5 insertions, 85 deletions
@@ -1,3 +1,5 @@ +- drop support for Enterprise media (mga#6292) + Version 2.78 - 31 August 2012, Thierry Vignaud - use more modern urpmi API @@ -156,11 +156,6 @@ my %state = ( menu => [ 'check' ], tt => [ N_("No medium found. You must add some media through 'Software Media Manager'.") ], }, - no_enterprise_update_medium => { - colour => [ 'noconf' ], - menu => [ 'add_enterprise_update_medium' , 'check' ], - tt => [ N("An additional package medium is available for your distribution.") ] - }, no_enabled_medium => { colour => [ 'noconf' ], menu => [ 'check' ], @@ -214,17 +209,11 @@ my %comm_codes = ( status => 'unconfigured_restricted_media', log => "Missing restricted media\n", }, - no_enterprise_update_medium => { - code => 10, - status => 'no_enterprise_update_medium', - log => "Missing enterprise update media\n", - }, ); my %actions = ( 'update' => { name => N("Install updates"), launch => \&installUpdates }, 'add_restricted_media' => { name => N("Add additional package medium"), launch => \&prepare_add_restricted }, - 'add_enterprise_update_medium' => { name => N("Add additional package medium"), launch => \&prepare_add_enterprise_update_media }, 'check' => { name => N("Check Updates"), launch => \&checkUpdates }, 'confNetwork' => { name => N("Configure Network"), launch => \&configNetwork }, 'upgrade_distro' => { name => N("Upgrade the system"), launch => \&upgrade }, @@ -240,7 +229,6 @@ $icon->signal_connect(activate => sub { my %click_actions = ( unconfigured_restricted_media => \&prepare_add_restricted, no_update_medium => \&add_media, - no_enterprise_update_medium => \&prepare_add_enterprise_update_media, no_enabled_medium => \&add_media, updates => \&installUpdates, new_distribution => \&upgrade, @@ -376,7 +364,7 @@ sub process_state { $locked_count = 0; } - # busy critical delayed disabled disconnected locked loop_locked new_distribution no_enabled_medium no_enterprise_update_medium no_more_supported no_update_medium notsupported okay unconfigured_restricted_media update + # busy critical delayed disabled disconnected locked loop_locked new_distribution no_enabled_medium no_more_supported no_update_medium notsupported okay unconfigured_restricted_media update if (!member($sub_state, qw(okay))) { go2State($sub_state); } elsif ($no_more_supported @@ -770,11 +758,7 @@ sub silentCheck() { } if (!@update_medias) { - if (is_enterprise_media_supported()) { - checker_exit('no_enterprise_update_medium'); - } else { - checker_exit('no_update_medium'); - } + checker_exit('no_update_medium'); } elsif (!any { ! $_->{ignore} } @update_medias) { checker_exit('no_enabled_medium'); } @@ -928,8 +912,6 @@ sub setState { $bubble->add_action('clicked', N("Install updates"), \&installUpdates); } elsif ($state eq 'unconfigured_restricted_media') { $bubble->add_action('clicked', N("More Information"), \&prepare_add_restricted); - } elsif ($state eq 'no_enterprise_update_medium') { - $bubble->add_action('clicked', N("More Information"), \&prepare_add_enterprise_update_media); } elsif (member($state, qw(no_enabled_medium no_update_medium))) { $bubble->add_action('clicked', N("Add media"), \&add_media); } @@ -1019,33 +1001,3 @@ sub prepare_add_restricted() { $local_config{DO_NOT_ASK_FOR_RESTRICTED} = bool2text($warn_me); $res ? really_prepare_add_restricted() : 0; } - - -sub really_prepare_add_enterprise() { - $mdv_update_pid = run_program::raw( - { detach => 1 }, - 'mgaapplet-add-media-helper', - join('', @$product_id{qw(type product version)}) - ); -} - -sub prepare_add_enterprise_update_media() { - my $warn_me = text2bool($local_config{DO_NOT_ASK_FOR_ENTERPRISE_UPDATE_MEDIA}); - return if $warn_me; - my $w = new_portable_dialog(N("New medium available")); - my $res = - fill_n_run_portable_dialog( - $w, - [ - get_banner(N("New medium available")), - gtknew('Label_Left', text => - N("You use '%s' distribution and therefore have privileged access to additional software.", - N_("Mageia Enterprise Server")) . "\n\n" . - N("Do you want to install this additional software repository?"), @common), - gtknew('CheckButton', text => N("Do not ask me next time"), active_ref => \$warn_me), - create_okcancel($w, N("Next"), N("Cancel")), - ]); - setVar('DO_NOT_ASK_FOR_ENTERPRISE_UPDATE_MEDIA', bool2text($warn_me)); - $local_config{DO_NOT_ASK_FOR_ENTERPRISE_UPDATE_MEDIA} = bool2text($warn_me); - $res ? really_prepare_add_enterprise() : 0; -} diff --git a/mgaapplet-add-media-helper b/mgaapplet-add-media-helper index 7c25e174..668d3740 100755 --- a/mgaapplet-add-media-helper +++ b/mgaapplet-add-media-helper @@ -49,16 +49,6 @@ my %product = ( add_medium => \&mgaonline::add_medium_powerpack }, - server => { - info_url => 'http://www.mageia.org/', - has_rights => sub { - my $profile = shift @_; - $profile->{data}{groups}{'es5-prod'} or - $profile->{data}{groups}{'es5-demo'}; - }, - media_name => 'Update', - add_medium => \&mgaonline::add_medium_enterprise - }, extended => { info_url => 'https://www.mageia.org/', has_rights => sub { diff --git a/mgaapplet-config b/mgaapplet-config index c7959425..768b41a1 100755 --- a/mgaapplet-config +++ b/mgaapplet-config @@ -96,12 +96,6 @@ sub configure() { active_ref => \$config{DO_NOT_ASK_FOR_RESTRICTED}, ), ]), - if_(is_enterprise_media_supported(), - [ gtknew('CheckButton', - text => N("Check for missing \"%s\" media", N("Enterprise")), - active_ref => \$config{DO_NOT_ASK_FOR_ENTERPRISE_UPDATE_MEDIA}, - ), - ]), ]), create_okcancel($w), #, N("Next"), N("Cancel")), ]); @@ -125,7 +119,7 @@ sub configure() { sub invbools_for_display { my ($config) = @_; - foreach (qw(DO_NOT_ASK_FOR_DISTRO_UPGRADE DO_NOT_ASK_FOR_RESTRICTED DO_NOT_ASK_FOR_ENTERPRISE_UPDATE_MEDIA)) { + foreach (qw(DO_NOT_ASK_FOR_DISTRO_UPGRADE DO_NOT_ASK_FOR_RESTRICTED)) { invbool(\$config->{$_}); } } diff --git a/mgaonline.pm b/mgaonline.pm index 2cce07af..cbabd47d 100644 --- a/mgaonline.pm +++ b/mgaonline.pm @@ -45,7 +45,6 @@ our @EXPORT = qw(find_current_distro get_release get_stale_upgrade_filename get_urpmi_options - is_enterprise_media_supported is_extmaint_supported is_restricted_media_supported read_sys_config @@ -59,7 +58,6 @@ our @EXPORT_OK = qw( get_product_info get_my_mdv_profile add_medium_powerpack - add_medium_enterprise add_medium_extended ); @@ -93,10 +91,6 @@ sub is_extmaint_supported() { $product_id->{support} eq 'extended'; } -sub is_enterprise_media_supported() { - return; # NOT SUPPORTED ON MAGEIA - to_bool($product_id->{type} eq 'Enterprise' && $product_id->{product} eq 'Server'); -} sub is_restricted_media_supported() { return; # NOT SUPPORTED ON MAGEIA @@ -168,7 +162,6 @@ sub translate_product { mini => N("Mageia Mini"), one => N("Mageia One"), powerPack => N("Mageia PowerPack"), - server => N("Mageia Enterprise Server"), ); $product ||= lc $product_id->{product}; $strings{$product} || $product; @@ -206,17 +199,6 @@ sub get_urpmi_options() { ({ sensitive_arguments => 1 }, 'urpmi.addmedia', '--xml-info', 'always'); } -sub add_medium_enterprise { - my ($email, $password, $version, $arch) = @_; - my $uri = sprintf('https://%s:%s@download.FIXME.com/%s/rpms/%s/', - uri_escape($email), - uri_escape($password), - $version, - $arch); - my @options = get_urpmi_options(); - run_program::raw(@options, '--update', '--distrib', $uri); -} - sub add_medium_powerpack { my ($email, $password, $version, $arch) = @_; my $uri = sprintf('https://%s:%s@dl.FIXME.com/rpm/comm/%s/', |