Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
uzbl [Le 09/04/2011, 15:54] – [Le fichier de configuration] 86.221.201.126 | uzbl [Le 09/02/2017, 16:17] (Version actuelle) – Maj de la page L'Africain | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
+ | {{tag> | ||
+ | ---- | ||
+ | ====== Uzbl ====== | ||
+ | |||
+ | **Uzbl** est un navigateur web qui utilise le moteur de rendu de page web [[wpfr> | ||
+ | |||
+ | {{: | ||
+ | |||
+ | Il est présenté comme le [[:vim]] du navigateur web. | ||
+ | |||
+ | ===== Pré-requis ===== | ||
+ | |||
+ | * Disposer des [[: | ||
+ | * Disposer d'une connexion à Internet configurée et activée. | ||
+ | |||
+ | ===== Installation ===== | ||
+ | |||
+ | |||
+ | [[: | ||
+ | Optionnel : Logiciel à installer [[:xclip]]. | ||
+ | |||
+ | |||
+ | ===== Configuration ===== | ||
+ | Pour pouvoir utiliser uzbl, lancez les commandes suivantes : | ||
+ | On copie la configuration de base dans le répertoire | ||
+ | < | ||
+ | cp -r / | ||
+ | |||
+ | On ajoute l' | ||
+ | < | ||
+ | |||
+ | Votre nouveau navigateur est maintenant prêt à l' | ||
+ | |||
+ | ==== Suppression (et éventuellement ajout...) de favoris, cookies, historique ==== | ||
+ | Tout d' | ||
+ | Dans ce dossier sont présents d' | ||
+ | Si vous voulez supprimer des cookies, ouvrez le dossier cookies.txt et supprimez les lignes voulues.\\ | ||
+ | Si vous voulez supprimer des sites contenus dans l' | ||
+ | Si vous voulez supprimer des marques pages, ouvrez le dossier bookmarks et supprimez les lignes voulues. | ||
+ | |||
+ | ===== Utilisation ===== | ||
+ | |||
+ | Lancez l' | ||
+ | |||
+ | ==== Commandes utiles ==== | ||
+ | <note tip>Pour voir l' | ||
+ | **o < | ||
+ | **gg < | ||
+ | **b** : retourner à la page précédente\\ | ||
+ | **u** : ouvre le gestionnaire de favoris\\ | ||
+ | **U** : ouvre le gestionnaire d' | ||
+ | **B** : ajoute la page actuelle aux favoris\\ | ||
+ | **Echap** | ||
+ | **S** : stop\\ | ||
+ | **ZZ** | ||
+ | **r ou R** : actualiser (reload / Reload_ign_cache)\\ | ||
+ | **t** : enlève la barre du bas, écrit dans le titre de la fenêtre\\ | ||
+ | \\ | ||
+ | ** //Recherche d' | ||
+ | \\ | ||
+ | **/ | ||
+ | **n** : mettre en valeur l' | ||
+ | **N** : mettre en valeur l' | ||
+ | \\ | ||
+ | ** // | ||
+ | \\ | ||
+ | **j** : descend progressivement\\ | ||
+ | **k** : monte progressivement\\ | ||
+ | **h** : à gauche progressivement\\ | ||
+ | **l** : à droite progressivement (L minuscule)\\ | ||
+ | \\ | ||
+ | ** // | ||
+ | \\ | ||
+ | **< < (collés)** | ||
+ | **> > (collés)** | ||
+ | **Espace** | ||
+ | **$** : droite de la page\\ | ||
+ | \\ | ||
+ | ** //Zooms ://**\\ | ||
+ | \\ | ||
+ | **+** : zoom +\\ | ||
+ | **-** : zoom -\\ | ||
+ | **T** : toogle zoom\\ | ||
+ | \\ | ||
+ | ** // | ||
+ | \\ | ||
+ | **i** : passer en mode insertion\\ | ||
+ | **Tab** | ||
+ | **Maj + Tab** : sélectionner le lien ou la zone de texte précédente\\ | ||
+ | \\ | ||
+ | ** //Gestion des onglets (uniquement avec uzbl-tabbed) ://**\\ | ||
+ | **gn** | ||
+ | **go< | ||
+ | **gY** | ||
+ | **ZZ** | ||
+ | **gt** | ||
+ | **gT** | ||
+ | \\ | ||
+ | **Entrée** | ||
+ | __ou__\\ | ||
+ | **Espace** | ||
+ | ==== Le fichier de configuration ==== | ||
+ | Les commandes de base ainsi que les alias de uzbl sont contenus dans le fichier **~/ | ||
+ | Voici un exemple de fichier config opérationnel : | ||
+ | <file config> | ||
+ | # config uzbl revue par helly | ||
+ | # la config est optionnelle . vous pouvez utiliser uzbl sans elle (mais uzbl ne ferra pas grand chose) | ||
+ | |||
+ | #les commandes sont inspirées de vim | ||
+ | |||
+ | # Handlers | ||
+ | set download_handler = spawn $XDG_DATA_HOME/ | ||
+ | set cookie_handler | ||
+ | #set new_window | ||
+ | set new_window | ||
+ | set scheme_handler | ||
+ | set load_start_handler = chain 'set keycmd = ' 'set status_message = <span foreground=" | ||
+ | set load_commit_handler = set status_message = <span foreground=" | ||
+ | set load_finish_handler = chain 'set status_message = <span foreground=" | ||
+ | |||
+ | ## desactiver Javascript | ||
+ | #set disable_scripts = 1 | ||
+ | |||
+ | # Apparences | ||
+ | set show_status | ||
+ | set status_background = #303030 | ||
+ | set status_format | ||
+ | set status_top | ||
+ | set insert_indicator = I | ||
+ | set command_indicator = C | ||
+ | set useragent | ||
+ | |||
+ | set fifo_dir = /tmp | ||
+ | set socket_dir = /tmp | ||
+ | set shell_cmd | ||
+ | |||
+ | # déclaration des commandes | ||
+ | set modkey = Mod1 | ||
+ | # like this you can enter any command at runtime, interactively. prefixed by ':' | ||
+ | bind :_ = chain ' | ||
+ | |||
+ | bind j = scroll_vert 20 | ||
+ | bind k = scroll_vert -20 | ||
+ | bind h = scroll_horz -20 | ||
+ | bind l = scroll_horz 20 | ||
+ | bind << | ||
+ | bind >> | ||
+ | bind b = back | ||
+ | bind m = forward | ||
+ | bind S = stop | ||
+ | bind r = reload | ||
+ | bind R = reload_ign_cache | ||
+ | bind + = zoom_in | ||
+ | bind - = zoom_out | ||
+ | bind T = toggle_zoom_type | ||
+ | bind 1 = sh "echo set zoom_level = 1.0 > $4" | ||
+ | bind 2 = sh "echo set zoom_level = 2.0 > $4" | ||
+ | bind t = toggle_status | ||
+ | bind /* = search %s | ||
+ | bind ?* = search_reverse %s | ||
+ | #jump to next | ||
+ | bind n = search | ||
+ | bind N = search_reverse | ||
+ | bind gh _ = uri http:// | ||
+ | # shortcut to set the uri. TODO: i think we can abandon the uri command in favor of 'set uri = ..' | ||
+ | bind o _ = uri %s | ||
+ | # shortcut to set variables | ||
+ | bind s _ = set %s | ||
+ | bind \wiki _ = uri http:// | ||
+ | bind \doc _ = uri http:// | ||
+ | bind \des _ = uri http:// | ||
+ | bind gg _ = uri http:// | ||
+ | #bin gg _ = uri http:// | ||
+ | bind i = toggle_insert_mode | ||
+ | # disable insert mode (1 to enable). | ||
+ | bind I = toggle_insert_mode 0 | ||
+ | # Enclose the executable in quotes if it has spaces. | ||
+ | # appear AFTER the default parameters | ||
+ | bind B = spawn $XDG_DATA_HOME/ | ||
+ | bind U = spawn $XDG_DATA_HOME/ | ||
+ | bind u = spawn $XDG_DATA_HOME/ | ||
+ | # with the sample yank script, you can yank one of the arguments into clipboard/ | ||
+ | bind yurl = spawn $XDG_DATA_HOME/ | ||
+ | bind ytitle | ||
+ | # does the same as yurl but without needing a script | ||
+ | bind y2url = sh 'echo -n $6 | xclip' | ||
+ | # go the page from primary selection | ||
+ | bind p = sh 'echo "uri `xclip -selection primary -o`" > $4' | ||
+ | # go to the page in clipboard | ||
+ | bind P = sh 'echo "uri `xclip -selection clipboard -o`" > $4' | ||
+ | # start a new uzbl instance from the page in primary selection | ||
+ | bind ' | ||
+ | bind ZZ = exit | ||
+ | bind Xs = js alert(" | ||
+ | # example showing how to use sh | ||
+ | # it sends a command to the fifo, whose path is told via a positional param | ||
+ | # if fifo_dir is not set, it'll echo to a file named (null) somewhere >:) remember to delete it | ||
+ | # The body of the shell command should be one parameter, so if it has spaces like here, | ||
+ | # you must enclose it in quotes. | ||
+ | # in the body. Any additional parameters you use will appear AFTER the default parameters (cfg file | ||
+ | # path, fifo & socket dirs, etc.) | ||
+ | bind XS = sh 'echo "js alert (\\" | ||
+ | |||
+ | bind !dump = sh "echo dump_config > $4" | ||
+ | bind !reload | ||
+ | |||
+ | # this script allows you to configure (per domain) values to fill in form fields (eg login information) and to fill in these values automatically | ||
+ | bind za = spawn $XDG_DATA_HOME/ | ||
+ | bind ze = spawn $XDG_DATA_HOME/ | ||
+ | bind zn = spawn $XDG_DATA_HOME/ | ||
+ | bind zl = spawn $XDG_DATA_HOME/ | ||
+ | |||
+ | # other - more advanced - implementation using perl: (could not get this to run - Dieter ) | ||
+ | bind LL = spawn $XDG_DATA_HOME/ | ||
+ | bind LN = spawn $XDG_DATA_HOME/ | ||
+ | bind LE = spawn $XDG_DATA_HOME/ | ||
+ | |||
+ | # we ship some javascripts to do keyboard based link hinting/ | ||
+ | # this is similar to how it works in vimperator (and konqueror) | ||
+ | # TODO: did we resolve: "no click() event for hyperlinks so no referrer set" ? | ||
+ | #hit F to toggle the Hints (now in form of link numbering) | ||
+ | bind F = script $XDG_DATA_HOME/ | ||
+ | # the most stable version: | ||
+ | bind fl* = script $XDG_DATA_HOME/ | ||
+ | # using strings, not polished yet: | ||
+ | bind fL* = script $XDG_DATA_HOME/ | ||
+ | </ | ||
+ | |||
+ | **Note :**\\ | ||
+ | Pour mettre la recherche Google (commande **gg**) en français, vous pouvez modifier la ligne adéquate du fichier de configuration.\\ | ||
+ | Il vous suffit de remplacer dans l' | ||
+ | |||
+ | ==== Raccourcis pratiques ==== | ||
+ | Voici une liste de quelques raccourcis pouvant s' | ||
+ | Pour lancer par exemple le raccourci Wikipédia, il suffit de taper | ||
+ | < | ||
+ | Pour rechercher dans wikipedia | ||
+ | < | ||
+ | </ | ||
+ | Pour rechercher dans le forum ubuntu-fr.org | ||
+ | < | ||
+ | Pour rechercher dans la doc ubuntu-fr.org | ||
+ | < | ||
+ | Pour chercher un package ubuntu | ||
+ | < | ||
+ | </ | ||
+ | Pour avoir la conjugaison d'un verbe (:P) | ||
+ | < | ||
+ | </ | ||
+ | Quelques autres exemples de fichiers de configuration sont disponibles sur le [[http:// | ||
+ | ===== Les scripts ===== | ||
+ | uzbl dépend à 100% des scripts, en effet comme vous avez pu le voir lors de l' | ||
+ | Les scripts se trouvent sous le dossier **~/ | ||
+ | Ils sont pour la plupart en python et en shell. | ||
+ | |||
+ | ==== Marque-pages ==== | ||
+ | Il semble que le script load_url_from_bookmarks.sh soit mal codé, il n' | ||
+ | <code bash># | ||
+ | #revu par helly le 9/04/2010 | ||
+ | |||
+ | #NOTE: it's the job of the script that inserts bookmarks to make sure there are no dupes. | ||
+ | |||
+ | file=${XDG_DATA_HOME: | ||
+ | [ -r " | ||
+ | COLORS=" | ||
+ | |||
+ | if dmenu --help 2>&1 | grep -q ' | ||
+ | then | ||
+ | DMENU=" | ||
+ | # show tags as well | ||
+ | goto=`$DMENU $COLORS < $file | awk ' | ||
+ | else | ||
+ | DMENU=" | ||
+ | tag=`awk ' | ||
+ | fi | ||
+ | |||
+ | lien=$(grep " | ||
+ | |||
+ | #[ -n " | ||
+ | [ -n " | ||
+ | Par la suite, il faut modifier le fichier .local/ | ||
+ | <code bash> | ||
+ | |||
+ | ==== Téléchargements ==== | ||
+ | Par deffaut, uzbl enregistre tous les fichiers dans le dossier utilisateur, | ||
+ | <code bash># | ||
+ | # | ||
+ | # the original dget.sh script: | ||
+ | # (c) 2007 by Robert Manea | ||
+ | # | ||
+ | # bashtardized and heavily modded for uzbl: | ||
+ | # 2009 by pbrisbin | ||
+ | # | ||
+ | # modified for zenity | ||
+ | # 2009 by iosonofabio | ||
+ | # | ||
+ | # requires: | ||
+ | # | ||
+ | # wget | ||
+ | # | ||
+ | ### | ||
+ | # auto open the file post-download based on the file's extension | ||
+ | open() { | ||
+ | case " | ||
+ | *.pdf|*.ps|*.eps) | ||
+ | *.jpg|*.png|*.jpeg|*.png) | ||
+ | *.txt|*README*|*.pl|*.sh|*.py|*.hs) | ||
+ | *.mov|*.avi|*.mpeg|*.mpg|*.flv|*.wmv|*.mp4) vlc " | ||
+ | *.zip|*.zipx) | ||
+ | esac | ||
+ | } | ||
+ | # | ||
+ | # | ||
+ | # these are passed in from uzbl | ||
+ | PID=" | ||
+ | XID=" | ||
+ | ACTUAL_URL=" | ||
+ | DOWN_URL=" | ||
+ | # | ||
+ | # get filename from the url and convert some hex codes | ||
+ | # i hate spaces in filenames so i'm switching them | ||
+ | # with underscores here, adjust the first s///g if | ||
+ | # you want to keep the spaces | ||
+ | FILE=" | ||
+ | ' | ||
+ | s/ | ||
+ | s/ | ||
+ | s/ | ||
+ | s/ | ||
+ | s/ | ||
+ | s/ | ||
+ | # | ||
+ | # show zenity directory selection window to ask the user | ||
+ | # for the destination folder. Wait until the user answers | ||
+ | # for beginning download (this could be improved). | ||
+ | DIRFILE=$(zenity --file-selection --save --filename=" | ||
+ | # This command is used to download: | ||
+ | GET=" | ||
+ | ZEN=" | ||
+ | # download | ||
+ | if [ " | ||
+ | then | ||
+ | ( $GET " | ||
+ | sed -u ' | ||
+ | $ZEN; \ | ||
+ | open " | ||
+ | fi | ||
+ | exit 0</ | ||
+ | === Autres scripts === | ||
+ | |||
+ | Beaucoup d' | ||
+ | |||
+ | ===== Voir aussi ===== | ||
+ | * **(en)** [[http:// | ||
+ | * [[http:// | ||
+ | |||
+ | -------- | ||
+ | |||
+ | // |