True.machinebacon wrote:thanks to drew i quit posting scrots :D
cwm
Forum rules
Post your scrot in the appropriate section. If the section does not exist yet - open a new thread ;)
Post your scrot in the appropriate section. If the section does not exist yet - open a new thread ;)
- ivanovnegro
- Minister of Truth
- Posts: 5450
- Joined: Wed Oct 17, 2012 11:12 pm
Re: cwm
Re: cwm
damn. that's more beautiful than my GF.
All statements are true in some sense, false in some sense, meaningless in some sense, true and false in some sense, true and meaningless in some sense, false and meaningless in some sense, and true and false and meaningless in some sense.
- ivanovnegro
- Minister of Truth
- Posts: 5450
- Joined: Wed Oct 17, 2012 11:12 pm
Re: cwm
And Tim complaining about OpenSuse on IRC, oops. :)
Re: cwm
With a desktop like that who wouldn't be relaxed ;)
If you can do it go ahead and do it, if you can't do it then don't even criticize it. - gingerdesu
- franksinistra
- Ivana Fukalot
- Posts: 1093
- Joined: Mon Jan 27, 2014 2:03 am
- Location: 印尼国
- Dr_Chroot
- Alfalfa
- Posts: 1100
- Joined: Mon Jun 09, 2014 9:49 pm
- Location: among the sagebrush
- Contact:
Re: cwm
Wow, dkeg! Fantastic as always. You didn't by chance post your bar config anywhere, did you?
Fight internet censorship.
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
Re: cwm
on my github somewhere. Nothing special. Its a combination of my old stats scripts (which is around here somewhere) and some ideas from one of z3bra's creations. And thanks Joe for the amixer piece.
Code: Select all
#!/bin/sh
#
# mix of inspiration from z3bra and my own shit
temp() {
awk '{print $1/1000}' /sys/class/thermal/thermal_zone0/temp
}
mem() {
free -m | awk 'NR==3 {print $3}'
}
clock() {
date +'%e %b %R'
}
batt() {
cat /sys/class/power_supply/BAT0/capacity 2>/dev/null
}
music() {
cmusbar 2>/dev/null
}
vol() {
amixer get Master | tail -1 | sed 's/.*\[\([0-9]*%\)\].*/\1/' | sed -e 's/%//g'
}
groups() {
xprop -root _NET_CURRENT_DESKTOP | awk '{print $3}'
}
tags() {
herbstclient list_monitors | awk '{gsub(/"/," ");print $5}'
#herbstclient tag_status
}
pingd() {
$HOME/bin/pingd
}
# Fill buffer, output it to stdout.
while :; do
buf="%{l} %{B#FF1a1b1d} "
buf="${buf} %{F#FFa69c8e} GRP #"
buf="${buf} %{F#FFf9f9f9} $(groups) "
#buf="${buf} %{F#FFabacae} $(tags) "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFa69c8e} batt "
buf="${buf} %{F#FFdfdfdf} $(batt) "
buf="${buf} %{F#FFa69c8e} mem "
buf="${buf} %{F#FFdfdfdf} $(mem) "
buf="${buf} %{F#FFa69c8e} vol "
buf="${buf} %{F#FFdfdfdf} $(vol) %{c}"
buf="${buf} %{F#FFabacae} $(music) %{r}"
buf="${buf} %{F#FFa69c8e} $(pingd) "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFf8eaec} $(clock) "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
buf="${buf} %{F#FFFFFFFF} $() "
echo $buf
sleep 1
done
Work hard; Complain less
Re: cwm
^ Sorry, guys newbie question. I was wondering what "2>/dev/null" does, or is home to? Battery and music are both using it, and it got me puzzled. I am complete rookie in bash, but curious on it. Sorry for the inconvenience.
Simon
PS: Dkeg, Herbstluftswm script?
Simon
PS: Dkeg, Herbstluftswm script?
Someone told me that I am delusional, I almost fell off my unicorn.
Re: cwm
the 2 is for STDERR. So any error output is sent to /dev/null. The battery line has it b/c my original did not offer anything if the user has no battery. The cmus line includes it b/c I was testing something. It didn't work, but caused no issues, so I forgot about it. I should have cleaned it up better.
You could look up more information under say 'linux IO redirection'
What herbstluftwm script you looking for? Oh, cwm uses groups, herbst, uses tags. So would comment out what I don't need. Was playing around recently with herbstclient.
You could look up more information under say 'linux IO redirection'
What herbstluftwm script you looking for? Oh, cwm uses groups, herbst, uses tags. So would comment out what I don't need. Was playing around recently with herbstclient.
Work hard; Complain less
Re: cwm
Ahh ok, thank you very much dkeg, much appreciated. Will look up the IO stuff. Didn't know where to start searching and for what. I was just nosey with your script :)
Cheers mate
simon
Cheers mate
simon
Someone told me that I am delusional, I almost fell off my unicorn.
- Dr_Chroot
- Alfalfa
- Posts: 1100
- Joined: Mon Jun 09, 2014 9:49 pm
- Location: among the sagebrush
- Contact:
Re: cwm
Thanks dkeg! You da man B)
Fight internet censorship.
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
-
- Baconator
- Posts: 10253
- Joined: Thu Sep 16, 2010 11:03 am
- Location: Pfälzerwald
- Contact:
Re: cwm
Simon, check this: http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO-3.html
Anyway one of the best resources for Bash :)
Anyway one of the best resources for Bash :)
..gnutella..
- Dr_Chroot
- Alfalfa
- Posts: 1100
- Joined: Mon Jun 09, 2014 9:49 pm
- Location: among the sagebrush
- Contact:
Re: cwm
^ Fantastic, dkeg! I am really digging gohu; very nice font. And that perfect window alignment... how? Everything in your scrot is simply superb. +1
Fight internet censorship.
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
EFF | Tor Project | Bitcoin
"There have been times throughout American history where what is right is not the same as what is legal. Sometimes to do the right thing you have to break the law." - Edward Snowden
-
- Baconator
- Posts: 10253
- Joined: Thu Sep 16, 2010 11:03 am
- Location: Pfälzerwald
- Contact:
- franksinistra
- Ivana Fukalot
- Posts: 1093
- Joined: Mon Jan 27, 2014 2:03 am
- Location: 印尼国
Re: cwm
i like your blush scrot better dkeg, but i like it nonetheless
btw what's that next to ttytter?
btw what's that next to ttytter?
rice no more.
-
- Baconator
- Posts: 10253
- Joined: Thu Sep 16, 2010 11:03 am
- Location: Pfälzerwald
- Contact:
Re: cwm
^ looks like vim with nerd tree explorer (http://www.vim.org/scripts/script.php?script_id=1658)
..gnutella..