#!/bin/bash #panel for BigLinux # #Authors: # Bruno Goncalves Araujo # #License: GPLv2 or later ################################################# . /usr/share/bigcontrolcenter/default/theme-categories.sh.htm #Translation export TEXTDOMAINDIR="/usr/share/locale-langpack" export TEXTDOMAIN=bigcontrolcenter-system-repositories echo ' ' ################# # Disponibilidade ################# if [ "$p_disponibilidade" = "reduzida" ] then p_biglinux=yes p_partner=yes p_restricted=yes p_security=yes p_updates=yes p_universe=yes p_multiverse=yes echo "$p_disponibilidade" > /usr/share/bigcontrolcenter/categories/system/repositories/disponibilidade.txt fi if [ "$p_disponibilidade" = "recomendada" ] then p_frasten=yes p_getdeb=yes p_amsn=yes p_google=yes p_medibuntu=yes p_opera=yes p_playdeb=yes p_mplayer=yes p_smplayer=yes p_samrog=yes p_audio=yes p_wine=yes p_xorg=yes p_xorgdriver=yes p_partner=yes p_telepathy=yes p_multiverse=yes p_restricted=yes p_universe=yes p_proposed=yes p_security=yes p_updates=yes p_backports=yes p_biglinux=yes echo "$p_disponibilidade" > /usr/share/bigcontrolcenter/categories/system/repositories/disponibilidade.txt fi if [ "$p_disponibilidade" = "agressiva" ] then p_frasten=yes p_getdeb=yes p_amsn=yes p_google=yes p_medibuntu=yes p_opera=yes p_playdeb=yes p_mplayer=yes p_smplayer=yes p_samrog=yes p_audio=yes p_gimp=yes p_wine=yes p_xorg=yes p_xorgdriver=yes p_partner=yes p_telepathy=yes p_multiverse=yes p_restricted=yes p_universe=yes p_proposed=yes p_security=yes p_updates=yes p_backports=yes p_biglinux=yes p_kubuntu_ppa=yes echo "$p_disponibilidade" > /usr/share/bigcontrolcenter/categories/system/repositories/disponibilidade.txt fi if [ "$p_disponibilidade" = "personalizada" ] then echo "" > /usr/share/bigcontrolcenter/categories/system/repositories/disponibilidade.txt echo "" exit 0 fi ######### # Caminho ######### caminho="/usr/share/bigcontrolcenter/categories/system/repositories/karmic/sources" ######### # Frasten ######### if [ "$p_frasten" = "yes" ] then cp -f $caminho/frasten-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/frasten-ppa.list fi ############## # www.getdeb.net ############## if [ "$p_getdeb" = "yes" ] then cp -f $caminho/getdeb.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/getdeb.list fi ############## # Amsn ############## if [ "$p_amsn" = "yes" ] then cp -f $caminho/amsn-daily-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/amsn-daily-ppa.list fi ############## # Google ############## if [ "$p_google" = "yes" ] then cp -f $caminho/google.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/google.list fi ############## # Medibuntu ############## if [ "$p_medibuntu" = "yes" ] then cp -f $caminho/medibuntu.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/medibuntu.list fi ############## # Opera ############## if [ "$p_opera" = "yes" ] then cp -f $caminho/opera.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/opera.list fi ############## # www.playdeb.net ############## if [ "$p_playdeb" = "yes" ] then cp -f $caminho/playdeb.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/playdeb.list fi ############## # MPlayer ############## if [ "$p_mplayer" = "yes" ] then cp -f $caminho/rvm-mplayer.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/rvm-mplayer.list fi ############## # SMPlayer ############## if [ "$p_smplayer" = "yes" ] then cp -f $caminho/rvm-smplayer.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/rvm-smplayer.list fi ############## # Sam Rog ############## if [ "$p_samrog" = "yes" ] then cp -f $caminho/samrog131-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/samrog131-ppa.list fi ############## # Audio Dev ############## if [ "$p_audio" = "yes" ] then cp -f $caminho/ubuntu-audio-dev-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/ubuntu-audio-dev-ppa.list fi ############## # Gimp ############## if [ "$p_gimp" = "yes" ] then cp -f $caminho/matthaeus123-mrw-gimp-svn.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/matthaeus123-mrw-gimp-svn.list fi ############## # Wine ############## if [ "$p_wine" = "yes" ] then cp -f $caminho/ubuntu-wine-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/ubuntu-wine-ppa.list fi ############## # Xorg ############## if [ "$p_xorg" = "yes" ] then cp -f $caminho/ubuntu-x-swat-x-updates.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/ubuntu-x-swat-x-updates.list fi ############## # Xorg Driver ############## if [ "$p_xorgdriver" = "yes" ] then cp -f $caminho/xorg-edgers-drivers-only.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/xorg-edgers-drivers-only.list fi ############## # Partner ############## if [ "$p_partner" = "yes" ] then cp -f $caminho/partner.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/partner.list fi ############## # Telepathy ############## if [ "$p_telepathy" = "yes" ] then cp -f $caminho/telepathy-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/telepathy-ppa.list fi ############## # Kubuntu-ppa ############## if [ "$p_kubuntu_ppa" = "yes" ] then cp -f $caminho/kubuntu-ppa.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/kubuntu-ppa.list fi ############## # BigLinux ############## if [ "$p_biglinux" = "yes" ] then cp -f $caminho/biglinux.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/biglinux.list fi ################# # BigLinux-pop-sc ################# if [ "$p_biglinux_pop_sc" = "yes" ] then cp -f $caminho/biglinux-pop-sc.list /etc/apt/sources.list.d/ else rm -f /etc/apt/sources.list.d/biglinux-pop-sc.list fi ############## # Multiverse ############## if [ "$p_multiverse" = "yes" ] then if [ "$(grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep multiverse)" = "" ]; then software-properties-gtk -e multiverse fi else sed -i 's/ multiverse//g' /etc/apt/sources.list fi ############## # Restricted ############## if [ "$p_restricted" = "yes" ] then if [ "$(grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep restricted)" = "" ]; then software-properties-gtk -e restricted fi else sed -i 's/ restricted//g' /etc/apt/sources.list fi ############## # Universe ############## if [ "$p_universe" = "yes" ] then if [ "$(grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep universe)" = "" ]; then software-properties-gtk -e universe fi else sed -i 's/ universe//g' /etc/apt/sources.list fi ############## # Proposed ############## if [ "$p_proposed" = "yes" ] then if [ "$(grep "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep karmic-proposed)" = "" ]; then grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | awk '{print $1, $2 " karmic-proposed " $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15}' >> /etc/apt/sources.list fi else sed -i '/karmic-proposed/d' /etc/apt/sources.list fi ############## # Security ############## if [ "$p_security" = "yes" ] then if [ "$(grep "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep karmic-security)" = "" ]; then grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | awk '{print $1, $2 " karmic-security " $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15}' >> /etc/apt/sources.list fi else sed -i '/karmic-security/d' /etc/apt/sources.list fi ############## # Updates ############## if [ "$p_updates" = "yes" ] then if [ "$(grep "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep karmic-updates)" = "" ]; then grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | awk '{print $1, $2 " karmic-updates " $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15}' >> /etc/apt/sources.list fi else sed -i '/karmic-updates/d' /etc/apt/sources.list fi ############## # Backports ############## if [ "$p_backports" = "yes" ] then if [ "$(grep "^deb .*archive.ubuntu.com" /etc/apt/sources.list | grep karmic-backports)" = "" ]; then grep -m1 "^deb .*archive.ubuntu.com" /etc/apt/sources.list | awk '{print $1, $2 " karmic-backports " $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15}' >> /etc/apt/sources.list fi else sed -i '/karmic-backports/d' /etc/apt/sources.list fi ########################## # Atualizando repositorios ########################## bigsynaptic --update ############## # Redirecionar ############## if [ "$p_redirecionar" != "" ] then echo "" fi title=$"Atualizacoes e repositorios" apply=$"Aplicar" close=$"Sair" back=$"Voltar para tela de configuracao" #title echo "$title" #header open_header echo "$title" '
' $"Defina os programas disponiveis e atualizacoes desejadas." close_header #Exibir resposta para o usuario echo "




" echo $"Configuracao aplicada." echo "
"