noDE -- i3wm -- doc
noDE aka no Desktop Environment ...
some informations about i3wm.
sources : official documentation.
i3wm on nakeDeb
- shortcuts on i3wm
- polybar: display system informations
- conky, i3status & i3blocks: alternative system information display
- user configuration reset
- i3wm user guide
nakeDeb gives you a pre-configured i3 session: use of the forkawesome font for icons, keyboard shortcuts
for your applications, assignment of applications to workspaces, nord theme colorscheme, use of polybar for
the status bar ...
everything is logged in the main i3 configuration file ~/.config/i3/config
fully commented out.
keyboard shortcuts on i3wm
In order to get started with your session quickly and before you start reading the documentation, here are the main keyboard shortcuts used on the i3 session of nakeDeb (note that in the configuration files, the modifier keys are identified as follows: Mod1 = Alt, Mod4 = Super):
shortcut | action |
---|---|
Super+Enter | show/hide the scratchpad (floating terminal) |
Super+Shift+Enter | restart the scratchpad (floating terminal) |
Alt+Enter | open a terminal |
Super+r | open lf file manager (CLI) |
Super+Shift+r | open pcmanfm file manager (GUI) |
Super+e | open geany GUI editor |
Super+x | open weechat IRC client |
Super+w | open w3m web browser (CLI) |
Super+m | open htop system monitor (CLI) |
Super+v | open alsamixer volume control |
Super+z | open mocp music player (CLI) |
Alt+d | open rofi menu in 'run' mode |
Alt+p | open rofi menu in 'drun' mode |
Super+f | start searching |
Super+BackSpace | launch clean tool 'dotcleaner' |
Super+Shift+f | launch rofi-file-manager |
Super+Ctrl+w | launch 'nakedwalls' to set a wallpaper |
Alt+1/2/3... | display the workspace n°x |
Alt+Shift+1/2/3... | move client to workspace n°x |
Alt+↑/↓/←/→ | moce focus between clients |
Alt+Tab | cycle through actives clients |
Super+←/→ | cycle through actives workspaces |
Ctrl+Alt+←/→ | |
Alt+r | dis/enable 'resize' mode |
Alt+Shift+c | reread i3 config file |
Alt+Shift+r | restart i3 |
Super+l | lock screen |
Alt+Shift+e | quit i3 |
polybar: display your system information
the i3 session uses polybar by default to display system information.
polybar is an application that allows you to format a series of modules to display a menu,
workspaces, text, but also progress bars, percentages, glyphs and all in color.
configuration on nakeDeb is mainly based on glyphs for optimal graphics rendering.
however, if you prefer text mode, you can take advantage of the preconfigured alternative
configuration, modify the configuration to your liking or use i3status
,
i3blocks
or conky
detailed in the next chapter.
the configuration of polybar involves editing its main files
~/.config/polybar/config
/ ~/.config/polybar/configtxt
.
on nakeDeb, the polybar configuration is organized as follows for icon mode
(for text mode, the date is reported on the right module):
- left module:
- popmenu managed by rofi activated on left-click
- ssh session and ftp connection indicators
- active i3 workspaces icons
- resize-mode indicator
- online mini-menu activated on left-click with different launchers:
- terminal (only in icon mode)
- lf (only in icon mode)
- web browser (only in icon mode)
- pcmanfm (only in icon mode)
- torbrowser (only in icon mode)
- nakedlocate (only in icon mode)
- config polybar
- restart polybar
- polybar mode text/icon
- nakedhelp
- nakedquit
- capslock/numlock/scrollock indicator
- active window title
- central module::
- time displayed by default, date when left-clicking
- screenlocker icon
- updates notification (if any)
- right module:
- processor load with
htop
triggered by left-clicking on the icon - processor temperature (to be configured)
- memory consumption with
htop
triggered by left-clicking on the icon - primary disk space
- secondary disk space (to be configured)
- network indicator (to be configured) with
connman-gtk
triggered by left-clicking on the icon - battery indicator
- screen brightness indicator (to be configured)
- volume indicator
- redshift coloring daemon indicator (left-click to stop it)
- trash can indicator with
dotcleaner
triggered by right-clicking on the icon - nakedinfos: neofetch on left-click, htop on right-click
- systray
- processor load with
to access the alternative configuration in text mode, pull down the menu integrated in the left module, then choose the icon in T. to return to the configuration in icon mode, open the menu again then select "icon".
not all modules are enabled by default: you will need to configure them to match your hardware.
the possibilities of polybar are multiple ... so much so that a complete page of wiki is available on github.
conky, i3status & i3blocks
although polybar is used by default to display system information, nakeDeb also includes
pre-configurations for conky, i3status and i3blocks. the corresponding sections are commented out
(with a '#') in the ~/.config/i3/config
file. to use either of the previous tools,
simply uncomment the dedicated section.
conky
conky can be used to display information in the i3wm bar, but this requires converting its output to the
json format used by i3 to populate the status bar. conky will be launched in console mode with the
option out_to_x = false
: you will therefore not be able to activate the options dedicated
to the graphic display.
to start conky, nakeDeb uses a ~/.config/i3/i3conkybar
script which will call the conky
configuration file ~/.config/i3/conkyrc
. it is this script that will be entered in the
configuration file of i3wm ~/.config/i3/config
in this way:
bar {
position top
status_command $HOME/.config/i3/i3conkybar
workspace_buttons yes
binding_mode_indicator yes
tray_output yes
font pango:Hack 9
font pango:forkawesome 9
colors {
background #2E3440
statusline #D8DEE9
separator #2E3440
focused_workspace #4C566A #5E81AC #D8DEE9
active_workspace #4C566A #2E3440 #D8DEE9
inactive_workspace #2E3440 #2E3440 #888888
urgent_workspace #4C566A #BF616A #D8DEE9
binding_mode #2E3440 #BF616A #D8DEE9
}
}
the bar will be located at the top, will display the output of the i3conkybar command, with the workspace buttons, the i3wm mode indicator and the notification area. this section is commented out by default on nakeDeb.
the associated conkyrc uses the classic options but it is intended to send information in json
format for i3bar. conky options are formatted according to a scheme like:
{ "full_text":"uptime: ${uptime_short}", "color":"\#81a1c1" },
.
here is the default conkyrc for i3wm on nakeDeb. note that some options are commented out in order to be
edited before being integrated into the final display:
--[[
i3wm conkyrc arpinux@2020©WTFPL
use with forkawesome fonts
nord colors :
#2e3440 – default dark background
#3b4252 – black
#434c5e - black lighter
#4c566a – bright black
#d8dee9 – default clear foreground
#e5e9f0 – white
#eceff4 – bright white
#8fbcbb – bright cyan
#88c0d0 – cyan
#81a1c1 – blue
#5e81ac - bright blue
#bf616a – red
#d08770 – orange
#ebcb8b – yellow
#a3be8c – green
#b48ead – purple8fbcbb
extra infos -- exemples
- notifier un volume externe monté
{ "full_text": "${font forkawesome:size=9}${if_mounted /media/arp/nak3dback} ${fs_used_perc /media/arp/nak3dback}%${endif}" , "color": "\#d8dee9" },
- cpu 4 cœurs
{ "full_text": "${font forkawesome:size=9} ${cpu cpu1}% ${cpu cpu2}% ${cpu cpu3}% ${cpu cpu4}%" ,\
"color": ${if_match ${cpu}>80}"\#bf616a"${else}"\#81a1c1"${endif} },
- température du processeur
{ "full_text": "${font forkawesome:size=9} ${texeci 5 sensors|grep "Core 2"| awk '{print $3}'|cut -c2-}" ,\
"color": ${if_match "${texeci 5 sensors|grep "Core 2"|awk '{print $3}'|cut -d"+" -f 2|sed s/.0°C//g}" > "75"}"\#bf616a"${else}"\#81a1c1"${endif} },
- volume interne en auto-mounting
{ "full_text": " ${font forkawesome:size=9} ${fs_used_perc /media/arp/Xtra}% ${fs_free /media/arp/Xtra}" , "color": "\#d08770" },
- activité réseau
{ "full_text": " ${font forkawesome:size=9}${if_up wlp3s0} ${upspeedf wlp3s0}k/s ${downspeedf wlp3s0}k/s${else}${if_up enp2s0} ${upspeedf enp2s0}k/s ${downspeedf enp2s0}k/s${else}net ${endif}${endif}" , "color": ${if_gw}"\#88c0d0"${else}"\#bf616a"${endif} },
- gestion de l'alimentation
{ "full_text": " ${font forkawesome:size=9}${if_match ${battery_percent}<5}${blink }${else}${if_match "${acpiacadapter}" == "on-line"} ${battery_percent}%${else} ${battery_percent}% ${battery_time}${endif}${endif}" , "color": ${if_match ${battery_percent}<10}"\#bf616a"${else}"\#ebcb8b"${endif} },
]]
conky.config = {
out_to_x = false,
out_to_console = true,
background = false,
update_interval = 2.0,
total_run_times = 0,
top_name_width = 10,
use_spacer = 'none',
double_buffer = yes,
cpu_avg_samples = 2,
short_units = true,
text_buffer_size = 2048,
if_up_strictness = 'address'
}
conky.text = [[
[
{ "full_text": "${font forkawesome:size=9} ${cpu}%" , "color": ${if_match ${cpu}>80}"\#bf616a"${else}"\#81a1c1"${endif} },
{ "full_text": ">${loadavg 1}" , "color": "\#81a1c1" },
{ "full_text": " ${font forkawesome:size=9} ${memperc}% ${mem}" , "color": ${if_match ${memperc} > 50}"\#bf616a"${else}"\#a3be8c"${endif} },
{ "full_text": " ${font forkawesome:size=9} ${fs_used_perc /}% ${fs_free /}" , "color": "\#d08770" },
{ "full_text": " ${font forkawesome:size=9}${if_pa_sink_muted} x${else} ${pa_sink_volume}%${endif}" , "color": ${if_pa_sink_muted}"\#bf616a"${else}"\#b48ead"${endif} },
{ "full_text": " ${font forkawesome:size=9} ${uptime_short}" , "color": "\#81a1c1" },
{ "full_text": " ${font forkawesome:size=9} ${time %a%d/%m}" , "color": "\#d8dee9" },
{ "full_text": "${font forkawesome:size=9} ${time %I:%M} " , "color": "\#ffffff" }
],
]];
apart from the specific formatting in json, you can configure your conky as you want and as you are used to.
as always, a little man conky
to find your happiness.
i3status
i3status is the default application for i3wm to siplay system information. to activate it, you have
to uncomment the corresponding section in ~/.config/i3/config
like this:
bar {
position top
status_command i3status
workspace_buttons yes
binding_mode_indicator yes
tray_output yes
font pango:Hack 9
font pango:forkawesome 9
separator_symbol " | "
colors {
background #2E3440
statusline #D8DEE9
separator #D8DEE9
focused_workspace #4C566A #5E81AC #D8DEE9
active_workspace #4C566A #2E3440 #D8DEE9
inactive_workspace #2E3440 #2E3440 #888888
urgent_workspace #4C566A #BF616A #D8DEE9
binding_mode #2E3440 #BF616A #D8DEE9
}
}
i3status delivers minimalist output sliced into sections. it is configured through
the ~/.config/i3status/config
file. this file is organized around a general
section, the order of the information sections to be displayed and the information sections
itself. the manual is particularly well done with examples, which makes it quite usable by
a non-english speaker: man i3status.
here is the default rendering of i3status on nakeDeb as well as the associated configuration file:
# i3status configuration file.
# see "man i3status" for documentation.
# It is important that this file is edited as UTF-8.
# The following line should contain a sharp s:
# ß
# If the above line is not correctly displayed, fix your editor first!
general {
colors = true
color_good = '#a3be8c'
color_degraded = '#ebcb8b'
color_bad = '#bf616a'
interval = 5
}
order += "cpu_usage"
order += "load"
order += "disk /"
#order += "ipv6"
order += "wireless _first_"
order += "ethernet _first_"
order += "battery all"
order += "volume master"
order += "tztime local"
wireless _first_ {
format_up = " %quality %essid"
format_down = " down"
}
ethernet _first_ {
# if you use %speed, i3status requires root privileges
format_up = " %ip"
format_down = " down"
}
battery all {
format = " %status %percentage"
}
tztime local {
format = " %d/%m %H:%M "
}
cpu_usage {
format = " %usage"
}
load {
format = " %1min"
}
volume master {
format = " %volume"
format_muted = " muted"
device = "default"
mixer = "Master"
mixer_idx = 0
}
disk "/" {
format = " %percentage_used [%avail]"
}
i3status is particularly lightweight if you are not using external scripts. it is therefore perfectly suited to ultra-minimal hardware configurations (where every MB counts).
i3blocks
i3blocks provides a configurable and clickable display for i3bar. As its name suggests, it assembles
blocks to display system information in the i3 statusbar. each block retrieves the output of a dedicated script.
the cofiguration and scripts used are located in ~/.config/i3blocks/
.
nakeDeb uses a series of scripts collected by Anachron
and released under the GPLv3 license.
all scripts are in bash, which makes customization easier.
in order to know the few options of i3blocks, as usual, man i3blocks
to find your happiness. you will
quickly understand that the fine configuration involves editing the dedicated scripts.
polybar, conky, i3status or i3blocks ... nakeDeb gives you the choice to display your system information.
reset user's configuration
if you have changed your configuration and want to revert to the default Debian or nakeDeb configuration, follow these steps.
- revert to Debian configuration:
- save your personal configuration:
mv $HOME/.config/i3 $HOME/.config/i3.back
- quit i3 from its shortcut: Alt+Shift+e then click on 'Exit'
- when you restart your session, i3 will offer you to create the configuration file and you can use a default configuration.
- revert to nakeDeb configuration:
- save your personal configuration:
mv $HOME/.config/i3 $HOME/.config/i3.back
- copy the default nakeDeb configuration:
cp -R /etc/skel/.config/i3 $HOME/.config/i3
- cleanup useless files:
rm $HOME/.config/i3/config-fr $HOME/.config/i3/config
- setup english config:
mv $HOME/.config/i3/config-en $HOME/.config/i3/config
- quit i3 from its shortcut: Alt+Shift+e then click on 'Exit'
- when you restart your session, i3 will be configured as it was when you first launched nakeDeb.
The default configurations are located in /etc/i3
for Debian
and in /etc/skel/.config/i3
for nakeDeb.
i3 - User's Guide
luckily for you, i3wm has more than complete official documentation. I therefore leave you in the hands of the i3wm site and its user guide.