snippets / sha1sum

All snippets tagged sha1sum (1)

  1. zsha1sum (Hash sha1sum d'un fichier avec sortie Zenity)

    Idéal couplé à Nautilus Actions. Requiers Zenity

     1 #!/bin/bash
    2 ###############################################################################
    3 #
    4 # zsha1sum :
    5 # Scripts permettant d'utiliser SHA1Sum avec une sortie dans Zenity.
    6 #
    7 # by Guillaume Kulakowski a.k.a LLaumgui <guillaume at llaumgui dot com>
    8 # Version 1.0
    9 #
    10 ###############################################################################
    11 # This program is free software; you can redistribute it and/or
    12 # modify it under the terms of the GNU General Public License
    13 # as published by the Free Software Foundation; either version 2
    14 # of the License, or (at your option) any later version.
    15 #
    16 # This program is distributed in the hope that it will be useful,
    17 # but WITHOUT ANY WARRANTY; without even the implied warranty of
    18 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    19 # GNU General Public License for more details.
    20 #
    21 # You should have received a copy of the GNU General Public License
    22 # along with this program; if not,
    23 # - write to the Free Software
    24 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
    25 # - See http://www.gnu.org/licenses/gpl.html
    26 ###############################################################################
    27
    28 if [ $# = 0 ]; then
    29 zenity --info \
    30 --width=600 \
    31 --title="Usage incorrect de gSHA1Sum !" \
    32 --text="L'usage correct est :
    33 gSHA1Sum &#60;fichier&#62;";
    34 exit
    35 fi
    36
    37
    38 action=`sha1sum $1`
    39 zenity --info \
    40 --title=SHA1SUM \
    41 --no-wrap \
    42 --text="SHA1Sum du fichier $1:\n
    43 $action"
    Posted by llaumgui to shell zenity sha1sum gpl ... saved by 1 person ... 0 comments ... 1 year, 2 months
showing 10, 25, 50 items per pages

Pages : 1

Flux RSS friendsnippetLatest snippets


More...