hello everyone, dwm is the best window manager you can use it's fast and minimalism and this the best thing i love ofsuckless philosophy , in this post i'll show you how to configure your dwm, we will configure keybinds & color schema & some tasks can help you for make an awesome WM
for configure your dwm (or any suckless programs) you need to change somethings inconfig.h
first let's start with keybinds, dwm works withALT key if you wan't to change it fromALT toSUPER key, changeconfig.h from#define MODKEY Mod1Mask to#define MODKEY Mod4Mask for add/remove keybinds for dwm go tokeys list fromconfig.h
staticKeykeys[]={/* modifier key function argument */{MODKEY,XK_d,spawn,{.v=dmenucmd}},{MODKEY,XK_Return,spawn,{.v=termcmd}},.....etc........
dwm default keys for kill programs isSUPER + c , i'll change it toq
keys[] =... ..+ { MODKEY, XK_q, killclient, {0} },...
if you wan't to add more keybinds add a varible with your command you wan't to run with your keybind for example i need to run$ pamixer --allow-boost -i 10 for up the audio
static const char *audioup[] = { "pamixer --allow-boost -i 10",NULL };// EXAMPLE{ MODKEY, XK_{KEY}, spawn, {.v = {COMMAND} } }// REAL{ MODKEY, XK_p, spawn, {.v = audioup}},// SUPER + p = audioup command
take the idea and make your own keybinds or if you hate to configure your keybind fromC code you can usesxhkd with simple config file :)
for change the terminal fromST to your fav terminal go toconfig.h and search fortermcmd[] and change the value fromst toterminator for example
for change the font of dwm go to yourconfig.h file and search forfonts[] and change the value to your fav font name & size for example
staticconstchar*fonts[]={"monospace:size=13"};
for change your colorschema search forstatic const char col_gray and change what you wan't with color picker, or you can usePywal to generate colorschema with your wallpaper
$ wal -i wallpaper.png
and add this line#include "/home/${your username}/.cache/wal/colors-wal-dwm.h" for yourconfig.h and remove this lines fromconfig.h
static const char *colors[][3] = { /* fg bg border */ [SchemeNorm] = { col_gray3, col_gray1, col_gray2 }, [SchemeSel] = { col_gray4, col_cyan, col_cyan },};
and remove[SchemeUrg] = { urg_fg, urg_bg, urg_border }, from~/.cache/wal/colors-wal-dwm.h, now your colorschema will generate with your wallpaper.png
if you want to add auto start function for your dwm you can usecool autostart patch , after patch with$ git apply cool-autostart.diff you need to add this line forconfig.h with your commands
static const char *const autostart[] = { "compton", NULL, "sxhkd",NULL, "wal -R",NULL, NULL};
after that run$ sudo make clean install and enjoy :)
Top comments(0)
For further actions, you may consider blocking this person and/orreporting abuse