Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente | ||
| fr:tools:linux:misc-tools [2023/09/30 14:03] – ajout tri fichiers crunchyslime | fr:tools:linux:misc-tools [2024/01/28 12:44] (Version actuelle) – [Download youtube vidéo from clipboard] crunchyslime | ||
|---|---|---|---|
| Ligne 9: | Ligne 9: | ||
| * [[man> | * [[man> | ||
| * [[man> | * [[man> | ||
| - | * ... | + | * [[fr: |
| + | * 3D-2D | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * Dev | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * Network | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * Communication | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * Utilitaires | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| + | * [[man> | ||
| ==== Captures ==== | ==== Captures ==== | ||
| Ligne 26: | Ligne 54: | ||
| </ | </ | ||
| - | ==== Trier des fichiers rapidement par extention | + | ====Update time and date from network clock==== |
| - | Déplace des fichiers en vrac dans un dossier en fonction de leur extension : | + | |
| <code bash> | <code bash> | ||
| - | #!/bin/sh | + | #!/bin/bash |
| + | curlinero=`curl https:// | ||
| + | heure=`echo $curlinero | grep -oE ' | ||
| + | date=`echo $curlinero | grep -oE ' | ||
| + | echo $date | ||
| + | echo $heure | ||
| + | sudo date +%F -s $date | ||
| + | sudo date -s $heure | ||
| + | </ | ||
| - | cd ~/Downloads | + | ====Update timezone==== |
| - | pwd | + | <code bash> |
| + | timedatectl list-timezones | ||
| + | timedatectl set-timezone Europe/Paris | ||
| + | </ | ||
| - | ## Image | + | ====access grub2==== |
| - | echo "+ moving images" | + | |
| - | find . -maxdepth 1 -type f \ | + | appuyer sur '' |
| - | -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | | xargs -I '{}' | + | |
| - | ## Document | + | ====yaourt==== |
| - | echo "+ moving documents" | + | [[https:// |
| + | <code bash> | ||
| + | #!/ | ||
| + | git clone https:// | ||
| + | cd package-query | ||
| + | makepkg -si | ||
| + | cd .. | ||
| + | git clone https:// | ||
| + | cd yaourt | ||
| + | makepkg -si | ||
| + | cd .. | ||
| + | rm -rf package-query | ||
| + | rm -rf yaourt | ||
| + | </ | ||
| - | find . -maxdepth 1 -type f \ | + | ====Thèmes Kvantum==== |
| - | -name " | + | [[https:// |
| - | -o -name "*.doc" -o -name "*.DOC" \ | + | '' |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | | xargs -I '{}' | + | |
| + | - Select Kvantum from System Settings → Application Style → Widget Style and apply it. | ||
| + | - Select Kvantum from System Settings → Color → Scheme and click Apply. You could change the color scheme later if you choose another Kvantum theme with Kvantum Manager (see "Using Other Themes" | ||
| - | ## CAO | + | pour installer un thème, télécharger l' |
| - | echo "+ moving CAO files" | + | |
| - | find . -maxdepth 1 -type f \ | + | [[https:// |
| - | -name " | + | [[https:// |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | | xargs -I ' | + | |
| - | ## Vidéo | + | ====Kill process in 1 line==== |
| - | echo "+ moving videos" | + | |
| - | find . -maxdepth 1 -type f \ | + | show the process : |
| - | -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | | xargs -I ' | + | |
| + | '' | ||
| - | ## Div execs / data / archives | + | pipe to sh to kill it |
| - | echo "+ moving the rest" | + | |
| - | find . -maxdepth 1 -type f \ | + | '' |
| - | -name " | + | |
| - | -o -name "*iso" -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name "*sh" -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | -o -name " | + | |
| - | | xargs -I '{}' | + | |
| - | ## remove ext | + | [[https:// |
| - | echo "- removing exts" | + | |
| - | rm *.ext 2>/dev/null | + | |
| - | ## End information | + | ====Bookmarks==== |
| - | echo "" | + | |
| - | echo " | + | |
| - | ls -al | grep ' | + | |
| - | echo "" | + | |
| - | echo "Size on disk " | + | |
| - | du -sh | + | |
| - | echo "" | + | |
| - | echo "done" | + | un outils de bookmark facile et rapide comme vu dans cette vidéo ([[https:// |
| + | Notre objectif est de pouvoir stocker ce qui est surligné (en utilisant [[man> | ||
| + | |||
| + | <code bash> | ||
| + | # | ||
| + | |||
| + | bookmark=`xclip -o` | ||
| + | file=" | ||
| + | |||
| + | if grep -q " | ||
| + | notify-send " | ||
| + | else | ||
| + | notify-send " | ||
| + | echo "$bookmark" | ||
| + | fi | ||
| </ | </ | ||
| + | puis dans mon '' | ||
| + | < | ||
| + | bindsym $mod+Shift+b exec ~/ | ||
| + | bindsym $mod+b exec xdotool type " | ||
| + | bindsym $mod+n exec xdotool type " | ||
| + | </ | ||
| + | |||
| + | //⚠️ ce script a été rédigé pour i3 sous X, sous Wayland il conviendra de remplacer '' | ||
| + | |||
| + | ====Download youtube vidéo from clipboard==== | ||
| + | Avec X en utilisant [[man> | ||
| + | Avec wayland en utilisant [[man> | ||
| + | <code bash> | ||
| + | #!/bin/bash | ||
| + | cd "/ | ||
| + | wl-paste > / | ||
| + | #launching in a detached terminal to make it work with shortcuts | ||
| + | xfce4-terminal -e ' | ||
| + | rm / | ||
| + | </ | ||
| + | |||
| + | ====bash tools==== | ||
| + | |||
| + | <code bash> | ||
| + | # check for root access | ||
| + | SUDO= | ||
| + | if [ "$(id -u)" -ne 0 ]; then | ||
| + | # Si l' | ||
| + | SUDO=$(command -v sudo 2> /dev/null) | ||
| + | |||
| + | if [ ! -x " | ||
| + | echo " | ||
| + | exit 1 | ||
| + | fi | ||
| + | fi | ||
| + | </ | ||
| + | |||
| + | <code bash> | ||
| + | # check if command is available | ||
| + | check_cmd() { | ||
| + | command -v " | ||
| + | } | ||
| + | |||
| + | if check_cmd curl; then | ||
| + | echo "curl est accessible" | ||
| + | fi | ||
| + | |||
| + | if ! check_cmd curl; then | ||
| + | echo "Curl is needed to proceed with the installation" | ||
| + | exit 1 | ||
| + | fi | ||
| + | </ | ||
| + | |||
| + | <code bash> | ||
| + | # execute script from URL | ||
| + | sh <(curl -sSf https:// | ||
| + | |||
| + | # if curl missing | ||
| + | sh <(wget -qO - https:// | ||
| + | </ | ||
| + | |||