#!/bin/bash # # Flash # # Installer une version de flash if [ ! $EUID -eq 0 ] then echo "[ ERROR ] script a executer en sudo/root" exit 1 fi case $# in 0) flashtype='adobe' ;; 1) flashtype=$1 ;; *) echo "[ ERROR ] flashinstall [adobe|gnu|shumway|pipelight]" ;; esac # Remove all flash things related aptitude remove --purge -y flashplugin-installer gnash lightspark browser-plugin-lightspark pipelight-multi # Install only what is wanted case $flashtype in 'adobe') # Adobe aptitude install -y flashplugin-installer ;; 'gnu') # Gnash + Lightspark aptitude install -y gnash gstreamer0.10-ffmpeg gstreamer0.10-plugins-bad lightspark browser-plugin-lightspark ;; 'shumway') # Shumway wget http://mozilla.github.io/shumway/extension/firefox/shumway.xpi unzip shumway.xpi -d {ec8030f7-c20a-464f-9b0e-13a3a9e97384} cp -rf {ec8030f7-c20a-464f-9b0e-13a3a9e97384} /usr/lib/firefox-addons/extensions ;; 'pipelight') # Pipelight add-apt-repository ppa:pipelight/stable -y aptitude update aptitude install --with-recommends -y pipelight-multi echo Y | pipelight-plugin --enable flash ;; 'remove'|'rm') add-apt-repository -r ppa:pipelight/stable -y echo "[ INFO ] Suppression des version pipelight shumway gnu et adobe" ;; *) echo "[ ERROR ] Flash version non valide" ;; esac exit 0