Instalando a última versão do Adobe Flashplayer automaticamente

Publicado por Iago Lira (última atualização em 09/05/2018)

[ Hits: 7.775 ]

Homepage: https://notabug.org/iagolira/

Download 6815.install-flashplayer.sh




Instalação automática de Flash-Player.

Executar estas etapas:

1) chmod + x install-flashplayer.sh

2) Logar como Root

3) ./install-flashplayer.sh ou bash install-flashplayer.sh

**
Se houverem erros, executar:

bash -x install-flashplayer.sh

  



Esconder código-fonte

#!/bin/bash
#+-------------------------------------------------------------+
#| Program: flashinstall                                       |
#| Version: 1.0.0                                              |
#| Date: 04-20-2018                                            |
#| Autor: Francisco Iago Lira Passos                           |
#| Email: iagolirapassos@gmail.com                             |
#| Bugs report: https://notabug.org/iagolira/flashinstall.git  |
#| ssh: git@notabug.org:iagolira/flashinstall.git              |
#+-------------------------------------------------------------+

sitea="https://get.adobe.com/br/flashplayer/?Lang=Brazilian"
sited="https://fpdownload.adobe.com/pub/flashplayer/pdc/"
agent="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36"
version="$(wget --user-agent=$agent -qO - $sitea <<< Versão | grep -E Versão | sed 's/[^0-9.]//g')"
amd="https://fpdownload.adobe.com/pub/flashplayer/pdc/$version/"
i386="https://fpdownload.adobe.com/pub/flashplayer/pdc/$version/"

install(){
    #NPAPI
   if [ $1 == 1  ]; then
        case $2 in
        "x86_64")
                echo "Installing (x86_64)..."
                v64="flash_player_npapi_linux.x86_64.tar.gz"
                pst=`echo $v64 | sed 's/.tar.gz//g'`
                mkdir $pst
                wget --show-progress $amd/$v64 -O $v64
                tar zxvf $v64 -C $pst
                cd $pst
                cp -r usr/* /usr
                cp libflashplayer.so /usr/lib/mozilla/plugins/
                cd ..
                rm -rf $pst
                ;;
          "i386")
                echo "Installing (i386)..."
                v32="flash_player_npapi_linux.i386.tar.gz"
                pst=`echo $v32 | sed 's/.tar.gz//g'`
                mkdir $pst
                wget --show-progress $amd/$v32 -O $v32
                tar zxvf $v32 -C $pst
                cd $pst
                cp -r usr/* /usr
                cp libflashplayer.so /usr/lib/mozilla/plugins/
                cd ..
                rm -rf $pst
                ;;
        *) echo "Invalid option!" ;;
        esac
    #PPAPI
   elif [ $1 == 2 ]; then
        case $2 in
        "x86_64")
                [ -d /usr/lib/adobe-flashplugin/ ] || mkdir /usr/lib/adobe-flashplugin/
                echo "Installing (x86_64)..."
                v64="flash_player_ppapi_linux.x86_64.tar.gz"
                wget --show-progress $amd/$v64 -O $v64
                tar zxvf $v64 -C /usr/lib/adobe-flashplugin/
                ;;
          "i386")
                [ -d /usr/lib/adobe-flashplugin/ ] || mkdir /usr/lib/adobe-flashplugin/
                echo "Installing (i386)..."
                v32="flash_player_npapi_linux.i386.tar.gz"
                wget --show-progress $amd/$v32 -O $v32
                tar zxvf $v32 -C /usr/lib/adobe-flashplugin/
                ;;
        *) echo "Invalid option!" ;;
        esac

   fi
}

menu(){
varch=`uname -m`

    if [ $varch = "x86_64" ]; then
        arch="64 bit"
    elif [ $varch = "i386" ]; then
        arch="32 bit"
    fi

    echo "
    +---- Adobe Flash Player ----+
    | Version $version         |
    +----------------------------+
    |                            |
    |    Architecture $arch     |
    |                            |
    +----------------------------+
    |    Adobe Version           |                             
    |                            |
    |    [1] -> NPAPI            |
    |    [2] -> PPAPI            |
    +----------------------------+
    "
    read -n 1 -p "Enter the desired option: " option
    install $option $varch
}

menu

Scripts recomendados

Importar vários Emolticons de uma vez para amsn

Sambax - Shell - dialog- Xdialog

freeradius: radwho mostrando número de usuários

Instalador do plugin Flash 64 bits para Linux e UNIX/UNIX-like

AptList v1.1 - instalação de pacotes DEB a partir de uma lista


  

Comentários


Contribuir com comentário




Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts