Script to put usbdrive icon in systray (Solved)

For discussions about programming, programming questions/advice, and projects that don't really have anything to do with Puppy.
Message
Author
User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

Script to put usbdrive icon in systray (Solved)

#1 Post by nilsonmorales »

The code never ends, but I feel comfortable with version 11, it's just more than I expected, thanks
http://wikisend.com/download/342974/desmontarusbipc11

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Hello im trying to make a little script using yad that notify me when un/plug a usbdrive device in the systray ( just because somethimes forget unplug when leave )
Currently run a udev rule that notify with sound when un/plug, here the example.
/etc/udev/rules.d/90-sonidos_usb.rules
DRIVER=="usb", ACTION=="add", RUN+="/usr/local/bin/hotplug_usbsounds +"
SUBSYSTEM=="usb", ACTION=="remove", RUN+="/usr/local/bin/hotplug_usbsounds -"
/usr/local/bin/hotplug_usbsounds

Code: Select all

#!/bin/sh
DIR="/usr/share/sounds"
CMD="aplay"
case "$1" in
	+)
		$CMD $DIR/insert.wav &
	;;
	-)
		$CMD $DIR/remove.wav &
	;;
esac
then in terminal

Code: Select all

udevadm control --reload
everything is ok at this point, my problem is when try to setting the icon in the systray, here's the script.

Code: Select all

#!/bin/sh -x

ICON=/usr/local/lib/X11/pixmaps/usbdrv48.png
TOOLTIP="Botón Izquierdo: Actualizar | Botón Derecho: Menú"
mkfifo /tmp/01
exec 3<> /tmp/01

function func_menu() {
   exec 3<> /tmp/01
   # Obtener lista de unidades de almacenamiento montadas
   LISTSDX=($(df | grep /sd | cut -f1 -d ' '))

   for DRIVE in ${LISTSDX[@]}; do
   # Comprobar si los dispositivo de la lista son USB. True: Crear menu. False: Remover de la lista
      udevadm info -q path -n $DRIVE | grep usb && MENUCMD+="
Last edited by nilsonmorales on Fri 24 Mar 2017, 04:09, edited 2 times in total.
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#2 Post by wow »

Cambios, ahora actualiza el menú luego de desmontar y muestra un mensaje con yaf-splash.

Code: Select all

#!/bin/sh

ICON=/usr/local/lib/X11/pixmaps/usbdrv48.png
TOOLTIP="Botón Izquierdo: Actualizar | Botón Derecho: Menú"

PIPE=$(mktemp -u --tmpdir ${0##*/}.XXXXXXXX)

mkfifo $PIPE
exec 3<> $PIPE

export PIPE

function func_menu() {
   exec 3<> $PIPE
   # Obtener lista de unidades de almacenamiento montadas
   LISTSDX=($(df | grep /sd | cut -f1 -d ' '))

   for DRIVE in ${LISTSDX[@]}; do
   # Comprobar si los dispositivo de la lista son USB. True: Crear menu. False: Remover de la lista
      udevadm info -q path -n $DRIVE | grep usb && MENUCMD+="
[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

Re: Help with systray icon usbdrive script

#3 Post by MochiMoppel »

nilsonmorales wrote:everything is ok at this point
Not for me, but I wonder if you really need this
I would like that script showme a icon in systray when plug my usbdrive, and if possible showme some kind of info like mount point, space left, i dont know, mount/umount would be great.
When you plug in your USB drive, it is still unmounted. I don't think that you can get this kind of information without mounting the drive.

I also don't know how you expect yad to handle the insertion event. Even if you get it to work you would need to keep yad running all the time. Seems pretty wasteful. Why not hook it to some of Puppy's already existing system events?

Just an idea: edit /usr/local/pup_event/frontend_funcs and find add_pinboard_func().
Originally the function adds an icon to the desktop whenever a new drive is plugged in. You could add some code that plays a sound and puts an icon into the tray. Clicking on the tray icon will remove it, but you could as well add other commands.
  • add_pinboard_func() { #needs ONEDRVNAME, DRV_CATEGORY, FSTYPE
    if [[ $DRV_CATEGORY == usbdrv ]]; then
    aplay /usr/share/sounds/ok.wav
    ICON=/usr/local/lib/X11/pixmaps/usbdrv48.png
    TOOLTIP="USB drive added at /dev/$ONEDRVNAME"
    yad --text="$TOOLTIP" --notification --image=$ICON &
    fi

    echo "<?xml version="1.0"?>
    <env:Envelope xmlns:env="http://www.w3.org/2001/12/soap-envelope">

User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

#4 Post by nilsonmorales »

thanks wow your script works well
MochiMoppel you are right, i can't have information without mount the drive, i just need the icon in systray because i always forget unplug the usb, and i like my pinboard without drive icons, i think have information in the systray is better than have in the pinboard, your idea is great. ill test and report later.
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#5 Post by wow »

and if possible showme some kind of info like mount point, space left, i dont know, mount/umount would be great.

Code: Select all

yad --notification --text Pmount --command pmount --image "/usr/local/lib/X11/pixmaps/usbdrv48.png"

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

Re: Script to put usbdrive icon in systray

#6 Post by wow »

nilsonmorales wrote:... notify with sound when un/plug
Done.

Code: Select all

SND_CMD=aplay # Cambiar a "echo" para desactivar/Change to "echo" to disable
# Reemplazar por cualquier otro archivo de sonido/Replace sound file for whatever you want
SND_ADD="/usr/share/sounds/bark.au" # conectar/connect
SND_REM="/usr/share/sounds/2barks.au" # desconectar/disconnect
nilsonmorales wrote:... show an icon in systray when I plug my usbdrive, and if possible showme some kind of info like mount point, space left, i dont know, mount/umount
Done.

Work in progress...

Icon and menu:
  • Image
Notifications: echo or gxmessage or yaf-splash or notify-send

Code: Select all

# Establecer el comando para las ventanas de información/notificación.
# Set which command will be used for notitications
MSG_CMD="echo"
[ "$(which gxmessage)" ] && MSG_CMD="gxmessage -borderless -nofocus -bg black -fg white -timeout 3" 
[ "$(which yaf-splash)" ] && MSG_CMD="yaf-splash -close box -timeout 3 -placement bottom-right -bg black -fg white -text"
[ -e "/usr/lib/gtkdialog/box_splash" ] && MSG_CMD="/usr/lib/gtkdialog/box_splash -close box -timeout 3 -placement bottom-right -bg black -fg white -text"
[ "$(which yad)" ] && MSG_CMD="yad --no-buttons --borders 10 --skip-taskbar --no-focus --undecorated --timeout-indicator bottom --text-align=left --timeout 5 --geometry=200x50-10-50 --text"
[ "$(which notify-send)" ] && MSG_CMD="notify-send -t 5000 -u normal"
Marcar la línea como comentario para desactivar/Coment out the line you want to disable.

Code: Select all

#[ "$(which notify-send)" ] && MSG_CMD="notify-send -t 5000 -u normal"

Code: Select all

#[ "$(which yad)" ] && MSG_CMD="yad --no-buttons --borders 10 --skip-taskbar --no-focus --undecorated --timeout-indicator bottom --text-align=left --timeout 5 --geometry=200x50-10-50 --text"
  • Image Image
Tooltip Text Can be disabled with: -n
  • Image
Localization. Spanish is the base language.
  • Download [pusitray_langpack_english01.zip by tenochslb](working title) attached below or [pusitray_fr.tar.gz by argolance].Extract InsertScriptNameHere.mo rename it and copy/move to /usr/share/locale/en/LC_MESSAGES/
    Say your script is named 'pusitray'(it must be a simple filename without extension like .sh .something), so extract InsertScriptNameHere.mo and rename it to 'pusitray.mo', Now move or copy to your locale folder then start/restart the script.

Code: Select all

cp pusitray.mo /usr/share/locale/${LANG::2}/LC_MESSAGES/
  • Image
Edit1: [ -e "$PIPE" ] && rm -f "$PIPE"

Edit2:
- Replaced 'guess_fstype' with 'blkid' in DRIVEFS
- Excluded '*initrd*' from list in DRIVESPC
- Added ERROR_FILE to store error messages.

Edit3:
- Check yad version >= 0.19
- Check if its already running
- Added fallback MSG_CMD
- Switched menu order for Mounted devices | Unmounted devices.

Edit4:
- Bugfix: garmin gps sdcard sdb/sdc/etc. instead of sdb1/sdc1/etc.

Edit5:
- Now supports dunst/notify-send
- Hardware info in tooltip text.
- Still in spanish.

Edit6;
- Fixed yaf-splash notitications.

Edit7:
- Added Native Language Support, but Spanish is the base language.
- Fixed volume label only showing first word in the string.
- Attached .zip file with translation to english. Template(InsertScriptNameHere_en.po) translated by tenochslb

Edit8:
- Menu, New layout: Pmount || Device1 Name | Device1 partitions || Device2 Name | Device2 partitions || Actualizar/Reload/Refresh
- Menu: Added button [Device name] to open mount-point(s) if any.

Edit9:
- vfat partitions should now be mounted faster.

Edit10:
- Fixed some typos.
- Fixed: vfat partitions mounting too fast for the menu to update.

Edit11:
- Fixed: puppy boot(usbflash) device is now detected properly.

Version 0.11b (testing): http://murga-linux.com/puppy/viewtopic. ... 722#948722

Version 0.10d (stable?):

Code: Select all

#!/bin/bash
TEXTDOMAINDIR="/usr/local/share/locale/" TEXTDOMAIN=${0##*/}
# Parametros de inicio.
case "$1" in
   -n)
    DISABLETOOLTIP="true"
    export DISABLETOOLTIP
    ;;
   -*)
    printf "\n"$"Opciones"":\n\n-n   "$"Desactivar actualizaciones del tooltip \n     al conectar o desconectar unidades usb.""\n\n"
    exit
    ;;
esac

# Establecer el comando para las ventanas de información/notificación.
MSG_CMD="echo"
[ "$(which gxmessage)" ] && MSG_CMD="gxmessage -borderless -nofocus -bg black -fg white -timeout 3" 
[ "$(which yaf-splash)" ] && MSG_CMD="yaf-splash -close box -timeout 3 -placement bottom-right -bg black -fg white -text"
[ -e "/usr/lib/gtkdialog/box_splash" ] && MSG_CMD="/usr/lib/gtkdialog/box_splash -close box -timeout 3 -placement bottom-right -bg black -fg white -text"
[ "$(which yad)" ] && MSG_CMD="yad --no-buttons --borders 10 --skip-taskbar --no-focus --undecorated --timeout-indicator bottom --text-align=left --timeout 5 --geometry=200x50-10-50 --text"
[ "$(which notify-send)" ] && MSG_CMD="notify-send -t 5000 -u normal"

# Debug, mostrar en CLI el software para las notificaciones.
printf "\nMSG_CMD=${MSG_CMD%%[[:blank:]]*}\n"

# yad >= 0.19
NOAPP_MSG=$"Necesitas instalar yad 0.19 o superior"
if [ "$(which yad)" ]; then 
   YAD_VER="$(yad --version | cut -f 1-2 -d '.')"
   if [ $(echo "$YAD_VER >= 0.19" | bc -l) = 0 ]; then
      exec $MSG_CMD "$NOAPP_MSG"
      exit   
   fi
else
   exec $MSG_CMD "$NOAPP_MSG"
   exit
fi

# Iconos para el systray TRAY_ICON_MNT=UnMounted  TRAY_ICON_MNTD=Mounted
TRAY_ICON_MNT="/usr/local/lib/X11/pixmaps/usbdrv48.png"
TRAY_ICON_MNTD="/usr/local/lib/X11/pixmaps/usbdrv_mntd48.png"
MENU_ICON_PUPPY="/usr/share/pixmaps/puppy/puppy.svg"
MENU_ICON_MNT=list-add
MENU_ICON_MNTD=list-remove
TOOLTIP=$"Botón Izquierdo: Actualizar \nBotón Derecho: Menú"
# Sonidos al conectar y desconectar usb drives.
SND_CMD=aplay # Cambiar a "echo" para desactivar
SND_ADD="/usr/share/sounds/bark.au"
SND_REM="/usr/share/sounds/2barks.au"
ERROR_FILE="/tmp/${0##*/}_error" # Almacenar los mensajes de error del comando: mount
PIPE="/tmp/${0##*/}_tmp" # Archivo para comunicarse con yad

# Debug, mostrar algo de información.
printf "SND_CMD=$SND_CMD\nSND_ADD=$SND_ADD\nSND_REM=$SND_ADD\nERROR_FILE=$ERROR_FILE\nPIPE=$PIPE\n\n"

# Terminar script si existe "$PIPE".
[ -e "$PIPE" ] &&  echo $"Script ya está en ejecución. Saliendo..." && exit
mkfifo "$PIPE"
exec 3<> "$PIPE"

trap 'func_term' SIGINT SIGQUIT SIGTSTP EXIT

export PIPE ERROR_FILE TRAY_ICON_MNT TRAY_ICON_MNTD MENU_ICON_MNT MENU_ICON_MNTD MSG_CMD TOOLTIP

function func_term() { # Limpiar archivos temporales al cerrar el script.
   rm -f "$PIPE" "$ERROR_FILE" "/tmp/pup_event_ipc/block_${0##*/}" 
   echo "quit" >&3
   exit
}

function func_menu() {
   echo $"# Generando menú #"
   exec 3<> "$PIPE"
   # Elementos adicionales para el menú.
   MENU_CMD1=$"PMount""!pmount!media-floppy"
   MENU_CMD2=$"Actualizar""!bash -c func_menu!view-refresh"
   # Resetear variables.
   unset -v MENU_MNT MENU_UMNT SEP_MNT SEP_UMNT TOOLTIPDRV MENU_DRV NUM_MNTD
   # Obtener lista de particiones sd* en formato "tamaño|nombre" ejemplo: "4194304|sdb1"
   LISTSDX=($(grep 'sd[a-z]' /proc/partitions | tr -s ' ' | tr ' ' '|' | cut -f 4-5 -d '|')) # "grep 'sd[a-z][0-9]' /proc/partitions" no detecta sdcard en garmin gps (sdb/sdc/etc.)
   # Crear lista de dispositivos de almacenamiento.
   BLOCKDEVICES=($(printf '%s\n' "${LISTSDX[@]//[[:digit:]|]/}" | sort -u))

   for BLOCKDEVICE in ${BLOCKDEVICES[@]}; do
      # Comprobar si los dispositivos de la lista son USB.
      if udevadm info -q path -n /dev/$BLOCKDEVICE | grep usb > /dev/null ; then
         if [ -z "$DISABLETOOLTIP" ]; then
            # Obtener información adicional como fabricante y modelo de la unidad.
            VENDOR=$(cat /sys/block/$BLOCKDEVICE/device/vendor | tr -s ' ')
            MODEL=$(cat /sys/block/$BLOCKDEVICE/device/model | tr -s ' ')
            # Nombre del dispositivo como encabezado de tooltip y menú, luego añadir particiones.
            # Ejemplo: Kingston DT microDuo
            TOOLTIPDRV+="<span font="12"><sub><b>$VENDOR $MODEL</b></sub></span>\n"
            MENU_DRV+="|$VENDOR $MODEL"'!'"bash -c 'func_open $BLOCKDEVICE'"'!'"folder-open|"
         fi
         PARTITIONS=($(printf '%s\n' "${LISTSDX[@]}" | grep $BLOCKDEVICE))
         for PARTITION in ${PARTITIONS[@]}; do
            # Usar blkid para tomar datos de la partición.
            PARTITIONBLKID=$(blkid /dev/${PARTITION#*|})
            if [ "$PARTITIONBLKID" ]; then
               # Asignar: sistema de archivos, tamaño y etiqueta; a variables.
               PARTITIONFS=$(grep -oP 'TYPE="\K[^"]+' <<< $PARTITIONBLKID)
               PARTITIONGB=$(echo "scale=2 ; ${PARTITION%|*} / 1048576" | bc)
               PARTITIONLBL=$(grep -oP 'LABEL="\K[^"]+' <<< $PARTITIONBLKID)
               # df muestra el espacio de almacenamiento usado si la partición está montada.
               PARTITIONSPC=$(df | grep ${PARTITION#*|}[[:blank:]] | tr -s ' ' | cut -f 5-6 -d ' ' | tr ' ' '|')
               # Comprobar si la partición está montada.
               if [ "$PARTITIONSPC" ]; then
                  . /etc/DISTRO_SPECS
                  echo "${PARTITION#*|} $PARTITIONFS $PARTITIONGB GB "$"Montado" # Debug.
                  NUM_MNTD=$[NUM_MNTD + 1] # Cantidad de particiones montadas
                  # Crear un elemento para el menú. Ejemplo: "Desmontar LABEL ‣ sdb1 ‣ vfat ‣ 32 GB ‣ 50% ◔"
                  CHECK_INITRD=$(grep '/initrd/' <<< "$PARTITIONSPC")
                  if [ "$CHECK_INITRD" ] ; then
                     # Puppy boot.
                     MENU_PART="$DISTRO_NAME $DISTRO_VERSION $DISTRO_TARGETARCH ‣ $PARTITIONLBL ‣ ${PARTITION#*|} ‣ $PARTITIONFS ‣ $PARTITIONGB GB ‣ ${PARTITIONSPC%|*} ◔"'!'"bash -c 'func_open ${PARTITION#*|}'"'!'"folder-open|"
                  else
                     MENU_PART=$"Desmontar"" $PARTITIONLBL ‣ ${PARTITION#*|} ‣ $PARTITIONFS ‣ $PARTITIONGB GB ‣ ${PARTITIONSPC%|*} ◔"'!'"bash -c 'func_umount ${PARTITION#*|}'"'!'"$MENU_ICON_MNTD|"
                  fi
                  if [ -z "$DISABLETOOLTIP" ]; then
                     # Puppy boot.
                     [ "$CHECK_INITRD" ] && TOOLTIPDRVICON="◎ $DISTRO_NAME $DISTRO_VERSION $DISTRO_TARGETARCH ‣" || TOOLTIPDRVICON="
Attachments
pusitray_langpack_english01.zip
Extract InsertScriptNameHere.mo(English) rename it and copy/move to /usr/share/locale/en/LC_MESSAGES/
(2.78 KiB) Downloaded 194 times
Last edited by wow on Wed 29 Mar 2017, 19:06, edited 16 times in total.
[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

#7 Post by nilsonmorales »

wow wrote:
Work in progress...

Hey wow your script runs very good, hide the icon if no usbdevice is plug in the pc, the icon appear immediately when insert my devices, and the list looks great, even open the usb mounted in thunar, everything works ok, thank you for your help, i think is enough to me. look the pic
Image
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#8 Post by wow »

[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

#9 Post by nilsonmorales »

updated script works fine, if some problem appear ill report back.
thank you again.
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#10 Post by wow »

Script updated. Small bugfix for device partition sd[a-z] instead of sd[a-z][0-9] like garmin gps sdcard
http://www.murga-linux.com/puppy/viewto ... 888#946888
[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

#11 Post by nilsonmorales »

testing last script update, everything looks fine.
Image
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#12 Post by wow »

And more changes:
http://www.murga-linux.com/puppy/viewto ... 888#946888

Notifications:
  • Image
Tooltip Text
  • Image
[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#13 Post by wow »

Bugfix: yad-splash messages were partially broken with the last update.
http://www.murga-linux.com/puppy/viewto ... 888#946888

User avatar
corvus
Posts: 153
Joined: Fri 12 Jun 2015, 18:00
Location: In the peninsula shaped like a boot.

Safely remove USB device

#14 Post by corvus »

Greetings to all, I would like to propose to add the ability to safely remove the USB device. I personally use, via command line, a script (created by Yan Li in 2009), that need sdparm.
Attached the pet I created with the 64-bit version of sdparm, I also have the 32-bit version.
I hope it can help improve your script wow.
Best Regards.
Attachments
suspend_usb_drv-1.0-x64.pet
(77.09 KiB) Downloaded 219 times
[b]We are waves of the same sea, leaves of the same tree, flowers of the same garden.[/b]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#15 Post by wow »

http://www.murga-linux.com/puppy/viewto ... 888#946888

Now with native language support:
  • Image Image
Download [pusitray_langpack_english01.zip](working title) (InsertScriptNameHere_en.po=Template translated to english InsertScriptNameHere.pot=Template)attached here.Extract InsertScriptNameHere.mo rename it and copy/move to /usr/share/locale/en/LC_MESSAGES/
Say your script is named 'pusitray'(it must be a simple filename without extension like .sh .something), so extract InsertScriptNameHere.mo and rename it to 'pusitray.mo', Now move or copy to your locale folder then start/restart the script. Example:

Code: Select all

cp pusitray.mo /usr/share/locale/${LANG::2}/LC_MESSAGES/
[url=http://www.puppylinux.com][img]http://i.imgur.com/M4OyHe1.gif[/img][/url]

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#16 Post by wow »

http://www.murga-linux.com/puppy/viewto ... 888#946888

Español Algunos cambios:
  • Nueva diseño u orden para los elementos del menú: Pmount || Nombre de Dispositivo1 | Particiones de Dispositivo1 || Nombre de Dispositivo2 | Particiones de Dispositivo2 || Actualizar.
    Menu: Añadido un nuevo botón [Nombre de Dispositivo] para abrir la/las carpeta/"punto de montaje" si está montada alguna partición del dispositivo
English: Few changes:
  • Menu, New layout: Pmount || Device1 Name | Device1 partitions || Device2 Name | Device2 partitions || Reload/Refresh.
    Menu: Added button [Device name] to open mount-point(s) if mounted.
Por defecto/Default:
Image

Mínimo/Minimal: -n
Image

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#17 Post by Argolance »

Bonjour,
Waou, this script is really a good idea and the result quite amazing!
Thank you!
May I say 2 little (silly?) things?
  • - Why not use English inside the script to comment how it is built and how it works (I am of those who are very interested in this - it is how I learn - but do absolutely/unfortunately not speak Spanish!)?
    - There is a window that displays messages down right of the screen. For me and probably some other users, who have their taskbar top of the screen and (or) run in dualscreen, it is not convenient. I firstly didn't see this popup window so much I was glazing over my notification area in the taskbar on the other screen :P ...
[EDIT]: French po/mo as attached files.

Cordialement.
Attachments
pusitray_fr.tar.gz
(1.81 KiB) Downloaded 332 times

User avatar
nilsonmorales
Posts: 972
Joined: Fri 15 Apr 2011, 14:39
Location: El Salvador

#18 Post by nilsonmorales »

Hello Argolance, you mean the comment lines translated in english?
what notifier are you using, dunst, gxmessage, yaf-splash, i think you need configure that thing in you local configuration.
[b][url=http://nilsonmorales.blogspot.com/]My blog |[/url][/b][b][url=https://github.com/woofshahenzup]| Github[/url][/b]
[img]https://i.postimg.cc/5tz5vrrX/imag018la6.gif[/img]
[img]http://s5.postimg.org/7h2fid8pz/botones_logos3.png[/img]

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#19 Post by Argolance »

Hello Nilson,
nilsonmorales wrote:you mean the comment lines translated in english?
what notifier are you using, dunst, gxmessage, yaf-splash, i think you need configure that thing in you local configuration.
The only language we have in common is English. We may regret it but that is the way it is. So I think it is a pity not to use English to comment code lines inside scripts (to make them understandable), instead of the creator's native language (here Spanish!) as well as gettexted lines which are originally in Spanish, excluding all the people who do NOT speak Spanish and overall, must be translated into English... for English speaking users (as long as you have got the language package):, :shock:
Obviously, that is my personal opinion. On the French Forum, we have a talented script creator (musher0), who does the same, against all odds, and I still believe it is (not a shame!) just a pity! :wink:

Cordialement.

wow
Posts: 1052
Joined: Fri 30 Jun 2006, 00:18
Location: Peru

#20 Post by wow »

http://www.murga-linux.com/puppy/viewto ... 888#946888
Particiones de tipo vfat ahora deberían montarse rápidamente.

vfat partitions should now be mounted faster.

Post Reply