ldaxar / goblocks Goto Github PK
View Code? Open in Web Editor NEWStatus bar for dwm
License: GNU General Public License v2.0
Status bar for dwm
License: GNU General Public License v2.0
I suggest separating the necessary functions from the unnecessary ones. I.e. the built-ins such as date, cpu and memory should be separated from the rest (maybe put on a separate branch or patch). The RunCmd and Schedule functions should be part of the main package. FunctionMap should not be invoked in the main file either (it is unnecessary to call it when one for example does not want to use the builtin functions). This is all so as to make the program more suckless.
TLDR; The inclusion of the possibility to launch built-in functions is great, but should be made separate so as to better adhere to the suckless philosophy. If the user does not wish to utilise the built-in functions, he need not; if he wants to add more built-in functions, he should be able to.
Edit: it's ttecluk from reddit, we already talked about this.
I was wondering if you have any plans for adding support for signaling clicks to blocks and running a definable command when that happens.
I know this would also involve a patch for dwm, but I think this could be a very neat feature.
Also: I don't mind helping with it, but I also wanted to verify whether this is something you want in Goblocks?
Thanks for the great program.
JSON is not really a config format.
I propose INI for a config format. Here's how I'd structure the default config
[global]
separator = " | "
[weather]
updateSignal = 39
command = (sleep 5 && curl "wttr.in/London?format=3")
timer = 45m
[datetime]
prefix = ๐
updateSignal = 35
command = #Date
format = Monday 02/01/2006 15:04:05
timer = 1s
[volume]
prefix = ๐
updateSignal = 36
command = amixer get Master | awk ' /%/ {print $5 $6}' | head -1 | sed -e 's/][/ /g'
timer = 0
prefix = Mem:
updateSignal = 37
command = "#Memory"
suffix = %
format = %.2f
timer = 2s
[cpu]
prefix = CPU:
updateSignal = 38
command = "#Cpu"
suffix = %
format = %.2f
timer = 2s
It would be way easier to comment-out, to change and to create new blocks.
As for implementation, https://github.com/go-ini/ini looks quite good.
What do you think?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.