Amélioration script conversion et diverses màj
This commit is contained in:
parent
5c56dcb71b
commit
cc6f15e243
9 changed files with 73 additions and 46 deletions
|
@ -1,16 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [[ "$1" == "es" ]]
|
||||
then
|
||||
for disk in /dev/sd?
|
||||
do
|
||||
[[ "$disk" == "/dev/sda" ]] && continue
|
||||
[[ "$disk" == "/dev/sdb" ]] && echo
|
||||
echo '${voffset 2}Lecture '$(basename $disk)' ${diskio_read '$(basename $disk)'}${goto 140}Écriture '$(basename $disk)' ${diskio_write '$(basename $disk)'}'
|
||||
done
|
||||
else
|
||||
for dir in /run/media/breizh/*
|
||||
do
|
||||
[[ -d "$dir" ]] && echo -e "\${template3 $dir $(basename $dir)}\n\n"
|
||||
done
|
||||
fi
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@ conky.config = {
|
|||
template0 = [[${cpubar cpu\1 6,125}${goto 140}${cpubar cpu\2}]],
|
||||
template1 = [[${top pid \1} ${top name \1}$alignr${top cpu \1}%]],
|
||||
template2 = [[${top_io pid \1} ${top_io name \1}$alignr${top_io io_perc \1}%]],
|
||||
template3 = [[${scroll wait 20 1 2 \2} ${goto 140}${if_match ${fs_used_perc \1}>85}${color F2777A}$else${if_match ${fs_used_perc \1}>70}${color FFCC66}$else${color 99CC99}$endif$endif${fs_bar \1}${color}\nUtilisé : ${fs_used \1}${goto 140}Libre: ${fs_free \1}\nTaux ut.: ${fs_used_perc \1}%${goto 140}Total: ${fs_size \1}]]
|
||||
template3 = [[${scroll wait 20 1 2 \2} ${goto 140}${if_match ${fs_used_perc \1}>90}${color F2777A}$else${if_match ${fs_used_perc \1}>75}${color FFCC66}$else${color 99CC99}$endif$endif${fs_bar \1}${color}\nUtilisé : ${fs_used \1}${goto 140}Libre: ${fs_free \1}\nTaux ut.: ${fs_used_perc \1}%${goto 140}Total: ${fs_size \1}]]
|
||||
};
|
||||
|
||||
conky.text = [[
|
||||
|
@ -69,27 +69,22 @@ ${template1 9}
|
|||
${template1 10}
|
||||
|
||||
${color2}${font2}Disque E/S $hr${font}${color}
|
||||
${voffset 2}Lecture SSD ${diskio_read /dev/disk/by-id/wwn-0x5002538e39c2174e}${goto 140}Écriture SSD ${diskio_write /dev/disk/by-id/wwn-0x5002538e39c2174e}
|
||||
${diskiograph_read /dev/disk/by-id/wwn-0x5002538e39c2174e 26,125}$alignr${diskiograph_write /dev/disk/by-id/wwn-0x5002538e39c2174e 26,125}
|
||||
Lecture HDD ${diskio_read /dev/disk/by-id/wwn-0x50014ee0af38f135}${goto 140}Écriture HDD ${diskio_write /dev/disk/by-id/wwn-0x50014ee0af38f135}
|
||||
${voffset 2}Lecture ssd ${diskio_read /dev/disk/by-id/ata-Samsung_SSD_860_EVO_1TB_S4X6NJ0MC09727A}${goto 140}Écriture ssd ${diskio_write /dev/disk/by-id/ata-Samsung_SSD_860_EVO_1TB_S4X6NJ0MC09727A}
|
||||
${diskiograph_read /dev/disk/by-id/ata-Samsung_SSD_860_EVO_1TB_S4X6NJ0MC09727A 26,125}$alignr${diskiograph_write /dev/disk/by-id/ata-Samsung_SSD_860_EVO_1TB_S4X6NJ0MC09727A 26,125}
|
||||
Lecture L1V ${diskio_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159L1V}${goto 140}Écriture L1V ${diskio_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159L1V}
|
||||
${diskiograph_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159L1V 26,125}$alignr${diskiograph_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159L1V 26,125}
|
||||
Lecture T9F ${diskio_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX32D6123T9F}${goto 140}Écriture T9F ${diskio_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX32D6123T9F}
|
||||
${diskiograph_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX32D6123T9F 26,125}$alignr${diskiograph_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX32D6123T9F 26,125}
|
||||
Lecture T0W0 ${diskio_read /dev/disk/by-id/wwn-0x50014ee0af38f135}${goto 140}Écriture T0W0 ${diskio_write /dev/disk/by-id/wwn-0x50014ee0af38f135}
|
||||
${diskiograph_read /dev/disk/by-id/wwn-0x50014ee0af38f135 26,125}$alignr${diskiograph_write /dev/disk/by-id/wwn-0x50014ee0af38f135 26,125}
|
||||
Lecture JTP ${diskio_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159JTP}${goto 140}Écriture JTP ${diskio_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159JTP}
|
||||
${diskiograph_read /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159JTP 26,125}$alignr${diskiograph_write /dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX52D7159JTP 26,125}
|
||||
${template2 1}
|
||||
${template2 2}
|
||||
${template2 3}
|
||||
${template2 4}
|
||||
${template2 5}
|
||||
|
||||
${color2}${font2}Carte graphique $hr${font}${color}
|
||||
${voffset 2}Usage${goto 140}${texeci 3 conky_radeon}%
|
||||
VRAM: ${texeci 3 conky_radeon vram mb}M${goto 140}${texeci 3 conky_radeon vram}%
|
||||
Temp${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."edge"."temp1_input"'}>70}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."edge"."temp1_input"' | cut -d. -f1}°C${color}
|
||||
Conso${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."slowPPT"."power1_average"'}>180}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."slowPPT"."power1_average"' | cut -d. -f1} W${color}
|
||||
Ventilo${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."fan1"."fan1_input"'}>3000}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."fan1"."fan1_input"' | cut -d. -f1} RPM${color}
|
||||
|
||||
${color2}${font2}Système $hr$font$color${voffset 2}
|
||||
Kernel${goto 140}$kernel
|
||||
Uptime${goto 140}$uptime
|
||||
|
||||
${color2}${font2}Espace disque $hr${font}${color}
|
||||
${voffset 2}${template3 / /}
|
||||
|
||||
|
@ -97,13 +92,11 @@ ${template3 /home /home}
|
|||
|
||||
${template3 /mnt/data /mnt/data}
|
||||
|
||||
${template3 /mnt/backup /mnt/backup}
|
||||
|
||||
${template3 /home/minecraft /home/minecraft}
|
||||
|
||||
${template3 /tmp /tmp}
|
||||
|
||||
${template3 /dev/shm /dev/shm}
|
||||
|
||||
${template3 /run/user/1000 /run/user/1000}
|
||||
|
||||
${execpi 5 /home/breizh/.config/conky/conky_mount}#${color2}${font2}$hr${font}${color}
|
||||
]]
|
||||
|
|
|
@ -77,6 +77,17 @@ ${endif}
|
|||
${color2}${font2}Capteurs $hr$font$color${voffset 2}
|
||||
CPU${goto 140}${if_match ${execi 5 sensors -j | jq '."zenpower-pci-00c3"."Tdie"."temp1_input"'}>70}${color F2777A}$endif${execi 5 sensors -j | jq '."zenpower-pci-00c3"."Tdie"."temp1_input"' | cut -d. -f1}°C${color}
|
||||
|
||||
${color2}${font2}Carte graphique $hr${font}${color}
|
||||
#${voffset 2}Usage${goto 140}${texeci 3 conky_radeon}%
|
||||
#VRAM: ${texeci 3 conky_radeon vram mb}M${goto 140}${texeci 3 conky_radeon vram}%
|
||||
Temp${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."edge"."temp1_input"'}>70}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."edge"."temp1_input"' | cut -d. -f1}°C${color}
|
||||
Conso${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."PPT"."power1_average"'}>180}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."PPT"."power1_average"' | cut -d. -f1} W${color}
|
||||
Ventilo${goto 140}${if_match ${execi 5 sensors -j | jq '."amdgpu-pci-2900"."fan1"."fan1_input"'}>3000}${color F2777A}$endif${execi 5 sensors -j | jq '."amdgpu-pci-2900"."fan1"."fan1_input"' | cut -d. -f1} RPM${color}
|
||||
|
||||
${color2}${font2}Système $hr$font$color${voffset 2}
|
||||
Kernel${goto 140}$kernel
|
||||
Uptime${goto 140}$uptime
|
||||
|
||||
${color2}${font2}Sylvexplorer $hr$font$color${voffset 2}
|
||||
${texeci 3600 /home/breizh/.config/conky/sylv.sh}
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# Beware! This file is rewritten by htop when settings are changed in the interface.
|
||||
# The parser is also very primitive, and not human-friendly.
|
||||
htop_version=3.2.0
|
||||
htop_version=3.2.1
|
||||
config_reader_min_version=3
|
||||
fields=0 48 17 18 113 38 39 40 119 111 2 46 47 49 1
|
||||
hide_kernel_threads=1
|
||||
|
|
|
@ -156,7 +156,7 @@ handle_image() {
|
|||
## Video
|
||||
video/*)
|
||||
# Thumbnail
|
||||
ffmpegthumbnailer -i "${FILE_PATH}" -o "${IMAGE_CACHE_PATH}" -s 0 && exit 6
|
||||
ffmpegthumbnailer -m -i "${FILE_PATH}" -o "${IMAGE_CACHE_PATH}" -s 0 && exit 6
|
||||
exit 1;;
|
||||
|
||||
## PDF
|
||||
|
|
|
@ -18,6 +18,12 @@
|
|||
#
|
||||
# $3: The third passed parameter is the absolute path to the original wallpaper image (before effects, clock, etc.)
|
||||
#
|
||||
# $4: Fourth parameter comes from the display mode setting: "os" means that set_wallpaper should try to
|
||||
# leave the OS setting unchanged. "zoom" means to try to fill the screen fully with the provided image.
|
||||
# Other parameters that could be passed are the scaling modes used by GNOME:
|
||||
# "centered", "scaled", "stretched", "zoom", "spanned", "wallpaper"
|
||||
# TODO: Ideally all sections below for different DEs would take this setting into account
|
||||
#
|
||||
# EXAMPLE:
|
||||
# echo "$1" # /home/username/.config/variety/wallpaper/wallpaper-clock-fac0eef772f9b03bd9c0f82a79d72506.jpg
|
||||
# echo "$2" # auto
|
||||
|
@ -168,20 +174,28 @@ fi
|
|||
# Gnome 3, Unity
|
||||
gsettings set org.gnome.desktop.background picture-uri "file://$WP" 2> /dev/null
|
||||
gsettings set org.gnome.desktop.background picture-uri-dark "file://$WP" 2> /dev/null
|
||||
if [[ "$4" =~ ^(wallpaper|centered|scaled|stretched|zoom|spanned)$ ]]; then
|
||||
gsettings set org.gnome.desktop.background picture-options "$4"
|
||||
fi
|
||||
if [ "$(gsettings get org.gnome.desktop.background picture-options)" == "'none'" ]; then
|
||||
gsettings set org.gnome.desktop.background picture-options 'zoom'
|
||||
fi
|
||||
|
||||
# GNOME Screensaver / Lock screen - thanks to George C. de Araujo for the patch
|
||||
gsettings set org.gnome.desktop.screensaver picture-uri "file://$WP" 2> /dev/null
|
||||
if [[ "$4" =~ ^(wallpaper|centered|scaled|stretched|zoom|spanned)$ ]]; then
|
||||
gsettings set org.gnome.desktop.screensaver picture-options "$4"
|
||||
fi
|
||||
if [ "$(gsettings get org.gnome.desktop.screensaver picture-options)" == "'none'" ]; then
|
||||
gsettings set org.gnome.desktop.screensaver picture-options 'zoom'
|
||||
fi
|
||||
|
||||
|
||||
# Deepin
|
||||
if [ "$(gsettings list-schemas | grep -c com.deepin.wrap.gnome.desktop.background)" -ge 1 ]; then
|
||||
gsettings set com.deepin.wrap.gnome.desktop.background picture-uri "file://$WP"
|
||||
if [[ "$4" =~ ^(wallpaper|centered|scaled|stretched|zoom|spanned)$ ]]; then
|
||||
gsettings set com.deepin.wrap.gnome.desktop.background picture-options "$4"
|
||||
fi
|
||||
if [ "$(gsettings get com.deepin.wrap.gnome.desktop.background picture-options)" == "'none'" ]; then
|
||||
gsettings set com.deepin.wrap.gnome.desktop.background picture-options 'zoom'
|
||||
fi
|
||||
|
@ -215,8 +229,10 @@ SIMPLE_WMS=("bspwm" "dwm" "herbstluftwm" "i3" "i3-with-shmlog" "jwm" "LeftWM" "o
|
|||
if [[ " ${SIMPLE_WMS[*]} " = *" $XDG_CURRENT_DESKTOP "* || " ${SIMPLE_WMS[*]} " = *" $XDG_SESSION_DESKTOP "* ||
|
||||
" ${SIMPLE_WMS[*]} " = *" $DESKTOP_SESSION "* ]]; then
|
||||
if command -v "feh" >/dev/null 2>&1; then
|
||||
feh --bg-max "$WP" 2> /dev/null
|
||||
# TODO: This should take the scaling parameter $4 into account and use other options than --bg-fill
|
||||
feh --bg-fill "$WP" 2> /dev/null
|
||||
elif command -v "nitrogen" >/dev/null 2>&1; then
|
||||
# TODO: This should take the scaling parameter $4 into account and use other options than --set-zoom-fill
|
||||
nitrogen --set-zoom-fill --save "$WP" 2> /dev/null
|
||||
fi
|
||||
fi
|
||||
|
@ -246,12 +262,21 @@ fi
|
|||
|
||||
# MATE after 1.6
|
||||
gsettings set org.mate.background picture-filename "$WP" 2> /dev/null
|
||||
if [ "$(gsettings get org.mate.desktop.background picture-options 2>/dev/null)" == "'none'" ]; then
|
||||
gsettings set org.mate.desktop.background picture-options 'zoom'
|
||||
fi
|
||||
if [[ "$4" =~ ^(wallpaper|centered|scaled|stretched|zoom|spanned)$ ]]; then
|
||||
gsettings set org.mate.desktop.background picture-options "$4"
|
||||
fi
|
||||
|
||||
# Cinnamon after 2.0
|
||||
gsettings set org.cinnamon.desktop.background picture-uri "file://$WP" 2> /dev/null
|
||||
if [ "$(gsettings get org.cinnamon.desktop.background picture-options 2>/dev/null)" == "'none'" ]; then
|
||||
gsettings set org.cinnamon.desktop.background picture-options 'zoom'
|
||||
fi
|
||||
if [[ "$4" =~ ^(wallpaper|centered|scaled|stretched|zoom|spanned)$ ]]; then
|
||||
gsettings set org.cinnamon.desktop.background picture-options "$4"
|
||||
fi
|
||||
|
||||
# Awesome Window Manager
|
||||
# Be sure to start variety when you start awesome, such as by adding it to ~/.xinitrc
|
||||
|
@ -263,9 +288,4 @@ fi
|
|||
|
||||
# =====================================================================================
|
||||
|
||||
# OPTIONAL: Show a notification on automatic wallpaper change.
|
||||
# Display the original filename in the notification, but actually apply the post-effects image.
|
||||
# name=$(echo "$3" | sed 's/\//\n/g'| tail -n 1)
|
||||
# if [ "$2" == "auto" ]; then notify-send --icon "$WP" "Wallpaper changed" "$name" ; fi
|
||||
|
||||
exit 0
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
-o "%(title)s.%(ext)s"
|
||||
-P "temp:/tmp"
|
||||
--embed-subs
|
||||
--write-subs
|
||||
--write-auto-subs
|
||||
--sub-lang fr,en
|
||||
--embed-thumbnail
|
||||
-i
|
||||
-f "((bestvideo[vcodec^=av01][height<=?1440][width<=?2560]/bestvideo[vcodec=vp9][height<=?1440][width<=?2560]/bestvideo[height<=?1440][width<=?2560]/bestvideo)+(bestaudio[acodec=opus]/bestaudio[acodec=vorbis]/bestaudio))/best"
|
||||
--add-metadata
|
||||
|
|
|
@ -7,10 +7,10 @@ if [[ -n "$button" ]]
|
|||
then
|
||||
if [[ "$currentport" == "Active Port: analog-output-lineout" ]]
|
||||
then
|
||||
pactl set-sink-port "alsa_output.pci-0000_2b_00.3.analog-stereo" "analog-output-headphones"
|
||||
pactl set-sink-port "alsa_output.pci-0000_2b_00.3.analog-stereo.5" "analog-output-headphones"
|
||||
echo "casque"
|
||||
else
|
||||
pactl set-sink-port "alsa_output.pci-0000_2b_00.3.analog-stereo" "analog-output-lineout"
|
||||
pactl set-sink-port "alsa_output.pci-0000_2b_00.3.analog-stereo.5" "analog-output-lineout"
|
||||
echo "front "
|
||||
fi
|
||||
pkill -RTMIN+10 i3blocks
|
||||
|
|
|
@ -8,6 +8,7 @@ shopt -s globstar
|
|||
# Initialisation de la mise en forme
|
||||
blue=$(tput setaf 4)
|
||||
green=$(tput setaf 2)
|
||||
red=$(tput setaf 1)
|
||||
reset=$(tput sgr0)
|
||||
bold=$(tput bold)
|
||||
|
||||
|
@ -58,7 +59,7 @@ do
|
|||
declare -a running
|
||||
|
||||
running=($(jobs -p))
|
||||
if [[ "${#running[@]}" -ge 12 ]]
|
||||
if [[ "${#running[@]}" -ge 6 ]]
|
||||
then
|
||||
wait -n
|
||||
fi
|
||||
|
@ -75,5 +76,14 @@ do
|
|||
fi
|
||||
done
|
||||
wait
|
||||
(
|
||||
cd "${dstdir}"
|
||||
shopt -s nullglob
|
||||
echo "[${blue}GAIN${reset}] $dir"
|
||||
loudgain -S -a -k -q -s e *.opus &>/dev/null && \
|
||||
echo "[${green}GAIN${reset}] $dir" || \
|
||||
echo "[${red}GAIN${reset}] $dir"
|
||||
shopt -u nullglob
|
||||
) & disown $!
|
||||
done
|
||||
wait
|
||||
|
|
Loading…
Reference in a new issue