10 ms·
BitBar: put the output from any script/program in your Mac OS X Menu Bar
- seanwilson 11y agoThis is a great idea; looks really practical and easy to extend. Is there a list of more plugins anywhere? There's only a few in the repo: https://github.com/matryer/bitbar/tree/master/Plugins https://github.com/matryer/bitbar/tree/master/Plugins
- benwills 11y agoI won't be able to get to tinkering with this for a couple weeks, but if it does what it says it does, I've been wanting almost exactly this for a very long time. Thanks for getting it out there.
- nikisweeting 11y agoLooks very similar to: http://sveinbjorn.org/platypus/ http://sveinbjorn.org/platypus/ (http://sveinbjorn.org/files/manpages/PlatypusDocumentation.html#235 http://sveinbjorn.org/files/manpages/PlatypusDocumentation.h...) BitBar focuses on just the Menu Bar use case though, and does a more polished job than Platypus.
- voaie 11y agoSee also https://github.com/HackPlan/quark-shell-mac https://github.com/HackPlan/quark-shell-mac :)
- jamessb 11y agoAlso AnyBar, which displays a coloured dot in the menu bar: https://github.com/tonsky/AnyBar https://github.com/tonsky/AnyBar Or TextBar, which is a $3 utility: http://www.richsomerfield.com/apps/ http://www.richsomerfield.com/apps/
- deleted 11y ago[deleted]
- sciencerobot 11y agoAwesome tool! I've always wanted to make menubar apps but never wanted to learn Xcode+ObjectiveC. Related: Is there no simple way to get the current temperature for location based off of GeoIP using `curl`? I had to use this monstrosity to get the current temperature: #!/bin/bash export PATH='/usr/local/bin:$PATH' ansiweather -a off -l 'San Francisco' \ | cut -d '>' -f 2 \ | cut -d '-' -f1 \ | awk '{ print $1 $2 }' \ | tr -d 'C'
- grahamg 11y agoNot curl, but this script may be a worthy replacement? https://raw.githubusercontent.com/grahamg/Practice/master/weather_pexpect.py https://raw.githubusercontent.com/grahamg/Practice/master/we...
- taylorzane 11y agoYou could use OpenWeatherMap's API. Something like this is pure (remove the `&units=imperial` if you prefer Celsius): curl -s "http://api.openweathermap.org/data/2.5/weather?zip=$(curl -s ipinfo.io/postal),us&appid=2de143494c0b295cca9337e1e96b00e0&units=imperial" \ | sed -e 's/\(.*\)temp":\([0-9.]*\),\(.*\)/\2/' or you could replace the `sed` pipe with a call to `jq`: curl really_long_url | jq '.main.temp'
- mkagenius 11y ago> remove the `&units=imperial` if you prefer Celsius That would get you Kelvin, use `&units=metric` for Celsius
- taylorzane 11y agoGood call! I completely forgot the default units were in Kelvin, and not Celsius.
- dmsimard 11y agoSweet. Does anyone happen to know if there is something similar for gnome-based environments on Linux ?
- vanous 11y agoI have been using https://extensions.gnome.org/extension/437/mylauncher/ https://extensions.gnome.org/extension/437/mylauncher/ to execute shell commands, to see output I have just found this: https://extensions.gnome.org/extension/912/command-output/ https://extensions.gnome.org/extension/912/command-output/, but I haven't tried it yet.
- ghoul2 11y agoI wrote one for the Cinnamon Desktop a while ago: https://github.com/abgoyal/ShellToolsApplet https://github.com/abgoyal/ShellToolsApplet http://cinnamon-spices.linuxmint.com/applets/view/136 http://cinnamon-spices.linuxmint.com/applets/view/136
- tbrock 11y agoConky is great for this sort of thing.
- rovr138 11y agoI haven't used conky in a while, but can you interact with it now? I was checking the plugins and some of them allow clicking on items in the dropdown and having an action execute. The clipboard history now has code for this.
- soheil 11y agoIn case you made the mistake of choosing a directory with thousands of files as the plugin directory and BitBar getting stuck forever, do this from terminal to reset it: defaults delete com.matryer.BitBar
- iaw 11y agoThis should be somewhere in the documentation if it's not already.
- zepolen 11y agoI've been using https://github.com/jaredks/rumps https://github.com/jaredks/rumps for this sort of thing.
- subnaught 11y agoAnother vote for rumps.
- evanb 11y agoThis reminds me of geektool http://projects.tynsoe.org/en/geektool/ http://projects.tynsoe.org/en/geektool/ which seems like it may have been abandoned? It was one of my favorite tools.
- arm 11y agoIt doesn’t seem to be abandoned. The latest version of Geektool (3.1.3) seems to have been released in October and even has support for El Capitan¹. ―――――― ¹ — http://projects.tynsoe.org/en/geektool/download.php http://projects.tynsoe.org/en/geektool/download.php
- provemewrong 11y agoA bit more modern and customizable alternative is Übersicht. Widgets are created in HTML5 and CoffeScript. http://tracesof.net/uebersicht/ http://tracesof.net/uebersicht/
- binaryapparatus 11y agoLast time I checked this tool they didn't support multiple monitors. Is that fixed now? Also big minus was menu bar icon, such tools don't need one.
- provemewrong 11y agoI only use one though, so I can't say for sure but judging by their blog posts they offer to choose which monitor Ubersicht runs on, but I believe it can't be displayed on multiple monitors at the same time. That's true about the menubar icon, but it doesn't bother me.
- jtokoph 11y agoAs my way of playing around with what BitBar can do, I created a Spotify script. Until it's merged you can check out the pull request: https://github.com/matryer/bitbar/pull/34 https://github.com/matryer/bitbar/pull/34 Shows current track name and artist in menu bar. Shows track/artist/album in dropdown along with play/pause/next/previous buttons. Raw script here: https://raw.githubusercontent.com/jtokoph/bitbar/jtokoph-spotify/Plugins/Media/spotify.10s.sh https://raw.githubusercontent.com/jtokoph/bitbar/jtokoph-spo...
- onion2k 11y agoVery nice, but none of the multiline bits after the pipe works for me (might be Bitbar rather than your script though). EDIT: The reason for this is the version installed by brew is 1.2, and that bug was fixed in 1.3.1.
- jtokoph 11y agoHijacking my own post. Been having lots of fun playing with BitBar. Just finished a clipboard history plugin: https://github.com/matryer/bitbar/pull/47 https://github.com/matryer/bitbar/pull/47
- chinchang 11y agoAmazing!!!!! Thanks for this :)
- daviddoran 11y agoVery clever approach, I like the simple text-based format.
- luke-stanley 11y agoAnyone know how to do similar for Xfce or LXDE?
- thwarted 11y agoXFCE has an applet called "generic monitor" that can be used for this.
- pentlander 11y agoThere's also a lightweight menu bar for X11 systems called bar. https://github.com/LemonBoy/bar https://github.com/LemonBoy/bar
- luke-stanley 11y agoAwesome, now I can run quick Python commands and see the output in my XFCE panel: sudo apt-get install xfce4-genmon-plugin Right click panel > Panel > Add New Items > Generic Monitor > Add Right click "(genmon)XXX", > Properties Try this command: python -c "import time;print time.time()" You might set it to run every 10 seconds. You could get results from a webpage or all kinds of things. It supports images, tooltips, progress bar, buttons... This is great! Thanks!
- javajosh 11y agoCould also use Hammerspoon (http://www.hammerspoon.org/ http://www.hammerspoon.org/) for this. It uses Lua but you can invoke processes and modify the toolbar. In addition you can hook into keystrokes, do window management, and all kinds of stuff.
- cmsj 11y agoand the upcoming 0.9.44 release will be even more flexible for this sort of use, because the process invoking stuff (http://www.hammerspoon.org/docs/hs.task.html http://www.hammerspoon.org/docs/hs.task.html ) will support processes that run indefinitely, so you could do crazy stuff like have a menubar item that shows the most recent line of a log file, or whatever you want :)
- hipjiveguy 11y agoYeah hammerspoon rocks and is very lightweight and easy to use... This simple example shows how powerful it is for automation: http://www.hammerspoon.org/go/#simplemenubar http://www.hammerspoon.org/go/#simplemenubar -- Creating a simple menubar item -- Lots of Mac utilities place a small icon in the system menubar to display their -- status and let you interact with them. We're going to use two of Hammerspoon's -- extensions to whip up a very simple replacement for the popular utility Caffeine. local caffeine = hs.menubar.new() function setCaffeineDisplay(state) if state then caffeine:setTitle("AWAKE") else caffeine:setTitle("SLEEPY") end end function caffeineClicked() setCaffeineDisplay(hs.caffeinate.toggle("displayIdle")) end if caffeine then caffeine:setClickCallback(caffeineClicked) setCaffeineDisplay(hs.caffeinate.get("displayIdle")) end
- pinkunicorn 11y agoThis is fantastic, I wanted to donate - but do not have a Bitcoin wallet. Any other options?
- matryer 11y agoYou're too kind - these words are enough. But if you insist, I do need some socks :) http://amzn.to/1Pd9yOt http://amzn.to/1Pd9yOt
- ghoul2 11y agoI made something quite similar a while ago for Linux (Cinnamon). https://github.com/abgoyal/ShellToolsApplet https://github.com/abgoyal/ShellToolsApplet http://cinnamon-spices.linuxmint.com/applets/view/136 http://cinnamon-spices.linuxmint.com/applets/view/136
- daemonk 11y agoNice. There are already a couple of programs that do this I think, but maybe use AWS CLI to write a plugin for monitoring ec2 instances' status.
- djhworld 11y agoI just wrote a plugin to allow me to set my Network location (we sit behind a corporate proxy at work) AND my bash proxy settings at the same time. So when I'm not in the office switching to my "home" profile is just a menu click away. This has been a long standing dream of mine to automate - so thanks! EDIT: also it works with emojis, which is handy, here's a screenshot http://imgur.com/CVxchnI http://imgur.com/CVxchnI
- daturkel 11y agoI hope you submitted a pull request!
- djhworld 11y agoSadly it's too bespoke to release, I had all the profile switching scripts written already and have been using them for a few years now. On top of updating environment variables with proxy settings etc, they also update a bunch of configuration files for maven, ssh, stunnel etc via symlinks All this bitbar thing does is call those existing scripts, very simple, but saves me a) wondering what profile I have enabled (now in the menubar) b) opening a terminal and typing "update-env (work|home)" (one click switch)
- dannyrosen 11y agoAnyone know of a solution like this for KDE Plasma?
- enedil 11y agoAnd nobody is restricted to shell scripts. Any program that writes to STDOUT will work.
- reacweb 11y agoVery nice. Does anyone have entry points to do the same with gnome 3 ?
- vanous 11y agoSee this two comments of mine. Perhaps time to study these and make a nice universal, working extension. https://news.ycombinator.com/item?id=10843704 https://news.ycombinator.com/item?id=10843704 https://news.ycombinator.com/item?id=10841525 https://news.ycombinator.com/item?id=10841525
- vanous 11y agoThe issue i can see in gnome-shell (on linux) implementations is that long running script can block the UI. Async script execution, on the other hand, exhaust open file resources due to non closed file descriptors. Do OSX tools like this suffer the same problem?
- daturkel 11y agoThis is awesome. Can't wait to see more plugins.
- matryer 11y agoMe too :) We didn't have to wait long - check these out: https://github.com/matryer/bitbar-plugins https://github.com/matryer/bitbar-plugins Some of them are like full apps in their own right.
- zlalanne 11y agoFor i3, i3blocks does the same job: https://github.com/vivien/i3blocks https://github.com/vivien/i3blocks
- rasur 11y agoWhy thank you, I use i3 (i love it) and this will be very useful.
- vowelless 11y agoAnyway I can hook up custom keyboard shortcuts to BitBar scripts?
- matryer 11y agoNice idea - you should raise an issue: https://github.com/matryer/bitbar/issues https://github.com/matryer/bitbar/issues
- rrggrr 11y agoI almost bought TextBar (www.richsomerfield.com). You for saved me $2.99 and 5 minutes of time. I'm disproportionately grateful for this.
- deleted 11y ago[deleted]
- lambrettaman 11y agoI'm missing something. I have it installed. My plugins are executable. I've Reset. I've changed the folder. But BitBar says "No Plugins Found"
- lambrettaman 11y agoMust be a Mac thing. I downloaded the .zip file and the plugins work.
- mofle 11y agoI made a Node.js module with a nice API for it to ease plugin creation: https://github.com/sindresorhus/bitbar https://github.com/sindresorhus/bitbar