cerebroapp / cerebro

🔵 Cerebro is an open-source launcher to improve your productivity and efficiency
https://www.cerebroapp.com/
MIT License
8.33k stars 456 forks source link

[Feature/Plugin Request] brew formulas search and install #180

Closed luisdavim closed 7 years ago

luisdavim commented 7 years ago

Hi,

in macOS I use homebrew and it would be cool if cerebro could search and install brew formulas, maybe it could search by scraping http://searchbrew.com/ or http://brewformulas.org/

There is also linuxbrew but I'm not aware of any search page for it's formulas.

KELiON commented 7 years ago

@luisdavim nice! I'd also use this plugin. Implementation looks simple: there is an endpoint, like http://searchbrew.com/search?q=formula. I'd not include installation inside plugin, just open terminal with entered brew install formula

luisdavim commented 7 years ago

I'll give it a try to implement it myself. If you are not working on it.

KELiON commented 7 years ago

@luisdavim no, i'm not. I think you can use cerebro-npm as a basis

setegonz commented 7 years ago

@KELiON 0.2.7 release is not available through homebrew. Will this version be available anytime soon?

KELiON commented 7 years ago

@setegonz sorry for the delay. It will be available in brew cask as soon as this PR is merged

luisdavim commented 7 years ago

Hi, here's my first attempt at it: https://github.com/luisdavim/cerebro-brew

I still need to update the README file and this doesn't work 100% for my case because I'm using tmux and the text gets pasted into the terminal before tmux is initialized, I can increase the delay before pasting the text but that might give a bad experience to who has their terminals initializing faster.

Can you try it out and let me know if you have any suggestions?

Thanks, Luis

luisdavim commented 7 years ago

I've updated the readme file and published the plugin.

KELiON commented 7 years ago

@luisdavim looks great! Do you think that this plugin should react to everything included? I'd like to see brew results only when I type something like brew ruby-build

luisdavim commented 7 years ago

you're right, I'll look into that.

luisdavim commented 7 years ago

@KELiON I've updated the plugin the work as you described.