Update readmes for suckless software

This commit is contained in:
mintycube 2024-04-24 21:13:20 +05:00
parent 80c6957729
commit d990a93487
6 changed files with 89 additions and 189 deletions

View File

@ -0,0 +1,24 @@
# dmenu
This build of dmenu was generated using [dmenu-flexipatch](https://github.com/bakkeby/dmenu-flexipatch.git) and finalized by [flexipatch-finalizer](https://github.com/bakkeby/flexipatch-finalizer).
## Patches
The patches used are listed below:
- border [link](http://tools.suckless.org/dmenu/patches/border)
- center [link](https://tools.suckless.org/dmenu/patches/center)
- ctrl_v to paste
- fuzzymatch [link](https://tools.suckless.org/dmenu/patches/fuzzymatch)
- fzfexpect [link](https://github.com/DAFF0D11/dafmenu) [link](https://github.com/DAFF0D11/dafmenu/blob/master/patches/dmenu-fzfexpect-5.1.diff)
- grid [link](https://tools.suckless.org/dmenu/patches/grid)
- gridnav [link](https://tools.suckless.org/dmenu/patches/gridnav)
- instant [link](https://tools.suckless.org/dmenu/patches/instant)
- line height [link](http://tools.suckless.org/dmenu/patches/line-height)
- mouse support [link](https://tools.suckless.org/dmenu/patches/mouse-support)
- password [link](https://tools.suckless.org/dmenu/patches/password)
- scroll [link](https://tools.suckless.org/dmenu/patches/scroll)
- tsv [link](https://tools.suckless.org/dmenu/patches/tsv)
- vertfull [link](https://tools.suckless.org/dmenu/patches/vertfull)
- xresources [link](https://tools.suckless.org/dmenu/patches/xresources)
- xyw [link](https://tools.suckless.org/dmenu/patches/xyw)

View File

@ -1,7 +1,41 @@
# dwm - dynamic window manager
This is my configuration for dwm generated by the awesome [dwm flexipatch](https://github.com/mintycube/dwm-flexipatch) and finalized by [flexipatch-finalizer]().
This build of dwm was generated using [dwm-flexipatch](https://github.com/bakkeby/dwm-flexipatch.git) and finalized by [flexipatch-finalizer](https://github.com/bakkeby/flexipatch-finalizer).
## Patches
The patches used and the accompanying documentation is listed below:
The patches used are listed below:
- bar_dwmblocks
- bar_ltsymbol
- bar_status
- bar_statusbutton
- bar_statuscmd
- bar_status2d
- bar_status2d_xrdb_termcolors
- bar_tags
- bar_hidevacanttags
- center
- cool_autostart
- fakefullscreen_client
- focusdir
- focusfollowmouse
- monoclesymbol
- noborder
- nodmenu
- no_transparent_borders
- on_empty_keys
- pertag
- restartsig
- rotatestack
- scratchpads
- scratchpads_keep_position_and_size
- seamless_restart
- shiftboth
- shiftview_clients
- tapresize
- toggletag
- transfer
- xrdb
- tile_layout
- monocle_layout

View File

@ -1,163 +1,4 @@
# dwmblocks-async
# dwmblocks
A [`dwm`](https://dwm.suckless.org) status bar that has a modular, async
design, so it is always responsive. Imagine `i3blocks`, but for `dwm`.
![A lean config of dwmblocks-async.](preview.png)
## Features
- [Modular](#modifying-the-blocks)
- Lightweight
- [Suckless](https://suckless.org/philosophy)
- Blocks:
- [Clickable](#clickable-blocks)
- Loaded asynchronously
- [Updates can be externally triggered](#signalling-changes)
- Compatible with `i3blocks` scripts
> Additionally, this build of `dwmblocks` is more optimized and fixes the
> flickering of the status bar when scrolling.
## Why `dwmblocks`?
In `dwm`, you have to set the status bar through an infinite loop, like so:
```sh
while :; do
xsetroot -name "$(date)"
sleep 30
done
```
This is inefficient when running multiple commands that need to be updated at
different frequencies. For example, to display an unread mail count and a clock
in the status bar:
```sh
while :; do
xsetroot -name "$(mailCount) $(date)"
sleep 60
done
```
Both are executed at the same rate, which is wasteful. Ideally, the mail
counter would be updated every thirty minutes, since there's a limit to the
number of requests I can make using Gmail's APIs (as a free user).
`dwmblocks` allows you to divide the status bar into multiple blocks, each of
which can be updated at its own interval. This effectively addresses the
previous issue, because the commands in a block are only executed once within
that time frame.
## Why `dwmblocks-async`?
The magic of `dwmblocks-async` is in the `async` part. Since vanilla
`dwmblocks` executes the commands of each block sequentially, it leads to
annoying freezes. In cases where one block takes several seconds to execute,
like in the mail and date blocks example from above, the delay is clearly
visible. Fire up a new instance of `dwmblocks` and you'll see!
With `dwmblocks-async`, the computer executes each block asynchronously
(simultaneously).
## Installation
Clone this repository, modify `config.h` appropriately, then compile the
program:
```sh
git clone https://github.com/UtkarshVerma/dwmblocks-async.git
cd dwmblocks-async
vi config.h
sudo make install
```
## Usage
To set `dwmblocks-async` as your status bar, you need to run it as a background
process on startup. One way is to add the following to `~/.xinitrc`:
```sh
# The binary of `dwmblocks-async` is named `dwmblocks`
dwmblocks &
```
### Modifying the blocks
You can define your status bar blocks in `config.h`:
```c
#define BLOCKS(X) \
...
X("volume", 0, 5), \
X("date", 1800, 1), \
...
```
Each block has the following properties:
| Property | Description |
| --------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- |
| Command | The command you wish to execute in your block. |
| Update interval | Time in seconds, after which you want the block to update. If `0`, the block will never be updated. |
| Update signal | Signal to be used for triggering the block. Must be a positive integer. If `0`, a signal won't be set up for the block and it will be unclickable. |
Apart from defining the blocks, features can be toggled through `config.h`:
```c
// String used to delimit block outputs in the status.
#define DELIMITER " "
// Maximum number of Unicode characters that a block can output.
#define MAX_BLOCK_OUTPUT_LENGTH 45
// Control whether blocks are clickable.
#define CLICKABLE_BLOCKS 1
// Control whether a leading delimiter should be prepended to the status.
#define LEADING_DELIMITER 0
// Control whether a trailing delimiter should be appended to the status.
#define TRAILING_DELIMITER 0
```
### Signalling changes
Most status bars constantly rerun all scripts every few seconds. This is an
option here, but a superior choice is to give your block a signal through which
you can indicate it to update on relevant event, rather than have it rerun
idly.
For example, the volume block has the update signal `5` by default. I run
`kill -39 $(pidof dwmblocks)` alongside my volume shortcuts in `dwm` to only
update it when relevant. Just add `34` to your signal number! You could also
run `pkill -RTMIN+5 dwmblocks`, but it's slower.
To refresh all the blocks, run `kill -10 $(pidof dwmblocks)` or
`pkill -SIGUSR1 dwmblocks`.
> All blocks must have different signal numbers!
### Clickable blocks
Like `i3blocks`, this build allows you to build in additional actions into your
scripts in response to click events. You can check out
[my status bar scripts](https://github.com/UtkarshVerma/dotfiles/tree/main/.local/bin/statusbar)
as references for using the `$BLOCK_BUTTON` variable.
To use this feature, define the `CLICKABLE_BLOCKS` feature macro in your
`config.h`:
```c
#define CLICKABLE_BLOCKS 1
```
Apart from that, you need `dwm` to be patched with
[statuscmd](https://dwm.suckless.org/patches/statuscmd/).
## Credits
This work would not have been possible without
[Luke's build of dwmblocks](https://github.com/LukeSmithxyz/dwmblocks) and
[Daniel Bylinka's statuscmd patch](https://dwm.suckless.org/patches/statuscmd/).
Lightweight, Modular and Async status bar for [dwm](https://dwm.suckless.org)
Borrowed from [dwmblocks-async](https://github.com/UtkarshVerma/dwmblocks-async)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 53 KiB

View File

@ -1,29 +1,30 @@
# st - simple terminal
This build of st was generated by using [st-flexipatch] and finalized by [flexipatch-finalizer].
This build of st was generated using [st-flexipatch](https://github.com/bakkeby/st-flexipatch.git) and finalized by [flexipatch-finalizer](https://github.com/bakkeby/flexipatch-finalizer).
## Patches
The patches used are listed below:
- alpha
- blinking cursor
- bold is not bright
- boxdraw
- clipboard
- externalpipe
- font2
- hidecursor
- hide terminal cursor
- invert
- iso14755
- ligatures
- newterm
- alpha [link](https://st.suckless.org/patches/alpha)
- blinking cursor [link](https://st.suckless.org/patches/blinking_cursor)
- bold is not bright [link](https://st.suckless.org/patches/bold-is-not-bright)
- boxdraw [link](https://st.suckless.org/patches/boxdraw)
- clipboard [link](https://st.suckless.org/patches/clipboard)
- externalpipe [link](https://st.suckless.org/patches/externalpipe)
- font2 [link](https://st.suckless.org/patches/font2)
- hidecursor [link](https://st.suckless.org/patches/hidecursor)
- hide terminal cursor [link](https://www.reddit.com/r/suckless/comments/nvee8h/how_to_hide_cursor_in_st_is_there_a_patch_for_it)
- invert [link](https://st.suckless.org/patches/invert)
- iso14755 [link](https://st.suckless.org/patches/iso14755)
- ligatures [link](https://st.suckless.org/patches/ligatures)
- newterm [link](https://st.suckless.org/patches/newterm)
- reflow
- rightclicktoplumb
- scrollback
- scrollback mouse altscreen
- swapmouse
- use xftfontmatch
- wide glyphs
- xresources
- rightclicktoplumb [link](https://st.suckless.org/patches/right_click_to_plumb)
- scrollback [link](https://st.suckless.org/patches/scrollback)
- scrollback mouse altscreen [link](https://st.suckless.org/patches/scrollback)
- swapmouse [link](https://st.suckless.org/patches/swapmouse)
- use xftfontmatch [link](https://git.suckless.org/st/commit/528241aa3835e2f1f052abeeaf891737712955a0.html)
- wide glyphs [link](https://github.com/Dreomite/st/commit/e3b821dcb3511d60341dec35ee05a4a0abfef7f2) [link](https://www.reddit.com/r/suckless/comments/jt90ai/update_support_for_proper_glyph_rendering_in_st)
- xresources [link](https://st.suckless.org/patches/xresources)
- xresources reload

View File

@ -7,17 +7,17 @@ Here are some details about this setup:
- **OS**: EndeavourOS
- **Login Manager**: None
- **WM**: [dwm](https://github.com/mintycube/dotfiles/tree/dwm/.config/suckless/dwm)
- **Bar**: [dwmblocks](https://github.com/mintycube/dotfiles/tree/dwm/.config/suckless/dwmblocks)
- **WM**: [dwm](https://github.com/mintycube/dotfiles/tree/main/.config/suckless/dwm)
- **Bar**: [dwmblocks](https://github.com/mintycube/dotfiles/tree/main/.config/suckless/dwmblocks)
- **Compositor**: [picom](https://github.com/yshui/picom)
- **Cursor-theme** = [Bibata-Modern-Ice](https://github.com/ful1e5/Bibata_Cursor)
- **Shell**: [zsh](https://wiki.archlinux.org/index.php/Zsh) + [zsh4humans](https://github.com/romkatv/zsh4humans)
- **Terminal**: [st](https://github.com/mintycube/dotfiles/tree/dwm/.config/suckless/st)
- **Terminal**: [st](https://github.com/mintycube/dotfiles/tree/main/.config/suckless/st)
- **Font**: JetBrainsMono Nerd Font
- **Editor**: [Neovim](https://github.com/mintycube/dotfiles/tree/dwm/.config/nvim)
- **File Manager**: [lf](https://github.com/gokcehan/lf) + [ctpv](https://github.com/NikitaIvanovV/ctpv)
- **Browser**: Firefox
- **Menu**: [dmenu](https://github.com/mintycube/dotfiles/tree/dwm/.config/suckless/dmenu)
- **Menu**: [dmenu](https://github.com/mintycube/dotfiles/tree/main/.config/suckless/dmenu)
- **Image-viewer** = [nsxiv](https://github.com/nsxiv/nsxiv)
- **Music-player** = [mpd](https://github.com/MusicPlayerDaemon/MPD) + [ncmpcpp](https://github.com/ncmpcpp/ncmpcpp)
- **Pdf-viewer** = [zathura](https://github.com/pwmt/zathura)