[Users] Cancel startup from password dialog

Chad Wallace cwallace at lodgingcompany.com
Fri Oct 21 18:52:27 CEST 2016


On Fri, 21 Oct 2016 18:06:44 +0200
Johan Vromans <jvromans at squirrel.nl> wrote:

> On Fri, 21 Oct 2016 14:20:52 +0200
> Ricardo Mones <ricardo at mones.org> wrote:
> 
> > Anyway, another idea to protect yourself from unwanted keystrokes:
> > put your a simple yes/no dialog wrapper¹ around your call to
> > claws-mail, so you have to confirm the launch :-)  
> 
> Yes, but I only want to do this if claws is not ye running.

Will this work?

#!/bin/bash

if ! ps -C claws-mail > /dev/null; then
    zenity --question --title="Confirm Claws Mail Launch" \
        --text="Do you really want to run Claws Mail?" \
        --width=400 2>/dev/null
    if [ $? -ne 1 ]; then
        claws-mail "$@"
    fi
fi


-- 

C. Chad Wallace, B.Sc.
The Lodging Company
http://www.lodgingcompany.com/
OpenPGP Public Key ID: 0x262208A0

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: OpenPGP digital signature
URL: <http://lists.claws-mail.org/pipermail/users/attachments/20161021/81b0e559/attachment.sig>


More information about the Users mailing list