HNHacker News
TopNewBestAskShowJobs

bucaran

36 karma · joined November 10, 2014

submissionscomments
bucaran··on D'Oh My Zsh – How I unexpectedly built a monster of an open source project
> The guy behind Fisherman abused DMCA to discredit OMF

I am one of the guys behind Fisherman and I didn't abuse the DMCA to discredit OMF, on the contrary, I used it to have my name properly represented in their AUTHORS file.

Now, one thing I am accountable for is, spending days and weeks nurturing and improving the project when I was involved with it. I don't know where you get your facts from, but I urge you to pay a visit to the contributor graphs in the OMF GitHub page and see who's done what and how much.

> is the preferred and popular plugin framework for Fish.

Not according to reality → http://why.fisherman.sh

bucaran··on Fish Shell Design Principles
2-year old issue proof:

• https://github.com/justinmayer/tackle/issues/3

Tackle support for "modules" and "function" snippets in Fisherman proof:

• https://github.com/fisherman/fisherman/blob/master/functions...

⁣⁣

I exhort you to demonstrate my comment was false.

⁣

Bonus Points ⁣⁣

PRs are ignored for months:

• https://github.com/justinmayer/tackle/pull/16

Issues are left unanswered for months:

• https://github.com/justinmayer/tackle/issues/14

⁣

All I am saying is, if you need first-class support for your fisheries, Fisherman is the man for the job, not Tackle. But hey, Fish is great out of the box and you don't really need anything to get up and running :)

bucaran··on Fish Shell Design Principles
Tackle/Tacklebox is rarely updated and still has open issues from up to 2 years ago.

Fisherman supports Tackle modules and functions, so if you are using Tackle, you can migrate to Fisherman without any hassle and still reuse and enjoy their plugins.

+ http://fisherman.sh

bucaran··on Fish Shell Design Principles
Tackle/Tacklebox is rarely updated and still has open issues from up to 2 years ago.

Fisherman supports Tackle modules and functions, so if you are using Tackle, you can migrate to Fisherman without any hassle and still reuse and enjoy their plugins.

+ http://fisherman.sh

bucaran··on Fish Shell Design Principles
All rubbish. 1 year late to the party and you talk like you knew what happened. By the way, are you chasing me? This is creepy.
bucaran··on Fish Shell Design Principles
You are right. Fish works beautifully out of the box and you should not bother really.
bucaran··on Fish Shell Design Principles
That's not true. Oh My Fish! is down because they are still using my old Wahoo code. I have since moved from that old code base in Fisherman, but they haven't. Do as you please, but learn your facts.
bucaran··on Fish Shell Design Principles
Fish sensible defaults can go a long way and the scripting language is fairly easy to pick up. If you want more that what's provided out of the box, then check out Fisherman: http://fisherman.sh
bucaran··on Show HN: GrapesJS – Open source tool for building templates easily
I love what you are doing. I really think the way we build websites today is fucked up, so I see you are trying to move things forward, but we need something more along the lines of:

+ http://playground.webflow.com/

bucaran··on Show HN: Fisherman – Plugin manager and CLI toolkit for fish shell
Thank you. All I ask is, report back any quirks or issues you encounter. Cheers captain!
bucaran··on Show HN: Fisherman – Plugin manager and CLI toolkit for fish shell
I had heard of this, then forgot about it and now you reminded me of it again. Eshell looks amazing.
bucaran··on Show HN: Fisherman – Plugin manager and CLI toolkit for fish shell
So, to answer the most important question, WHY do I want this thing?

Long wall of text ahead, but I promise this covers a lot.

---

If you are only using fish, you are missing out the ability to effectively share plugins, prompts, configs, missing completions, documentation for external utilities, plain old scripts or bundle of scripts.

If you are using Oh My Fish (OMF) / Wahoo or Tacklebox, you may be already doing some of the above, just very poorly.

---

So, I want to create shell scripts, snippets or let's call them utilities that follow the [UNIX guidelines](http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_...) for option parsing, fish auto-completion out of the box, with bundled documentation using the traditional `man(1)` pages like a boss, and I want my scripts to come not only in the form of `.fish` files, but I want to ship them bundled with scripts in other languages too sometimes, maybe Awk or Perl, or if you are cool, Python. Then I want to commit that to a GitHub repository, or as a Gist, or to BitBucket, GitLabs or my own server if I want.

---

Fisherman makes this process very easy and it also gives me access to an external ["index"](https://github.com/fisherman/fisher-index) to where I can publish these utilities, let's better call them now plugins so that others can discover my stuff without having to know the URL in advance.

Fisherman is not like, say `brew` where you typically share one or more binaries, that's a true package manager indeed.

---

Fisherman, however, is about sharing snippets, prompts, configurations, initialization scripts, like I said above, that kind of stuff. In the Fisherman jargon, I am rolling all that into a bun and calling it "plugin".

---

To Fisherman they are all the same, they should be, and if that's not the case your "framework", "manager", whatever, is not doing you any service.

---

There are several different setups that Fisherman understands and can process. Why? Because there are already existing snippets and plugins with their own idiosyncrasies. The same ones I mentioned above. Also people creating stuff in fish and releasing it without a particular "framework" in mind.

---

Fisherman recognizes packages from all of those dimensions and lets you install them and use them as you wish. Without strange restrictions that these other "frameworks" often pose on you, like strange name conventions or strict URL forms. It _will even__ try to guess the URL and correct your mistakes sometimes.

---

You can also "install" stuff locally and it will symlink a directory to Fisherman's configuration directory so that you can develop, test and iterate :repeat: fast and without having to do anything but `(1)` creating a directory and `(2)` typing `fisher install .` or `fisher install <my_path>`. You can commit your changes to a Git repo and that will not affect the process. It just works™.

---

But also you get a builtin (obviously it's builtin) cache system to let you install stuff while you are offline (assuming you already downloaded the _stuff_ first) and that segues into Fisherman's simplest, but IMO best feature, the flat tree :evergreen_tree:.

Here is the thing, Fisherman is as fast as no* Fisherman.

The [initialization script](https://github.com/fisherman/fisherman/blob/master/config.fi...) basically declares a few variables and evaluates only config files that you allow Fisherman to evaluate. Period.

---

On the other hand, legacy OMF and modern OMF, Wahoo and Tacklebox mutate a variable to add / remove paths as you install / uninstall plugins. This is slower than loading all your functions into a single directory and telling fish to load only that.

---

But wait, you say, a flat tree means every function will be public and there ought to be name collisions and what not. Well, that's how it has always been. If you were under the impression there was such thing as private function scope, I am sorry, there isn't.

* http://stackoverflow.com/questions/25088699/make-fish-functi...

* https://github.com/fish-shell/fish-shell/issues/1799

---

This is a "deficiency" (or feature maybe?) of the language and there is no way around the implications of this. You create a function and then remove it from the scope, but that does not change the fact _that function_ will replace any other function with the same name.

---

Now, you can always add prefixes to your functions or use underscores at the beginning of the function name like most folks do anyway. So, by using an underscore you express your intention to mark this function as private, but it's just as "public" as any other.

Well, if fish has no private function scope, then it makes sense to use a flat tree for speed.

---

In the case of OMF and admitedly Wahoo too, things are even worse :sweat_smile: because these two boys use fish [_event handlers_](http://fishshell.com/docs/current/commands.html#emit) during their initialization process, and since fish does not* automatically load files with events (there is just no convention for this ATM), they need to source every single `.fish` file inside each plugin's directory and inmediately `emit EVENT_NAME` adding yet another step in the process.

---

Events are great for communicating between different components / areas in a complex application, and I originally thought of using them in Fisherman despite the (arguably small) performance overhead, but desisted when I realized whatever happens inside an event handler, does not leak. They are essentially black holes and useless if you want to parse any output generated inside the handler / function.

---

One of Fisherman features is UNIX stinkiness. I don't think the UNIX philosophy (whatever that was) is a creed unbreakble doctrine, but I like to write my functions and utilities so that they can be plug / plumb into one another easily. That's why everything is a "stream" and all the commands Fisherman ships with read the standard input and do what you would expect if you are already familiar in how UNIX typically works. This is one of the principles I based while writing this, so it's everywhere. It's also [here](https://github.com/bucaran/getopts). That is used in Fisherman to make sophisticated CLI apps. It's written in sed/awk and it's really fast.

---

This is not even close to all Fisherman has to offer. There other cool things like the [search](https://github.com/fisherman/fisherman/wiki#search-point_lef...) command that parses the index file and lets you query plugins like you would expect from any modern tool. In OMF/Wahoo (Tacklebox has nothing) you only get a name.

---

In Fisherman every plugin gets a well deserved `name`, `url`, `description`, any number of `tags` and an `author`'s name. Makes sense.

---

And if you install a plugin from an "unknown" URL (one not in [fisher-index](https://github.com/fisherman/fisher-index/blob/master/INDEX), Fisherman will complete the information the best it can querying the Git repository, exhausting all the possibilities, so there's always data. It even looks at the URL itself and tries to guess stuff.

---

This "index" thing, is just a plain text flat database written in a human readable format. One cool thing is, the index is always kept up to date, unlike in OMF where you need to update in order to learn about the new goods. So, you don't have to update the entire application just to see what new packages are available, you are always querying the latest index.

---

A few other features that to mind is Fishfiles (dependency manifest file) that allows plugins to declare dependencies to other plugins and keep track of what plugins you have installed or not in your system.

---

BTW, OMF uses a more naive, but still similar, `bundle` file. Fisherman recognizes this and works with it too. No questions asked :+1:

---

Finally, the bundled help is phenomenal. Everything ships in glorious `man(1)` pages. You are not alone. Every single feature is thoroughly documented like it should be and now the Wiki is also pretty nice with the screencasts for each command.

bucaran··on Show HN: Fisherman – Plugin manager and CLI toolkit for fish shell
Everything is available. Not just plugins, but anything that runs in "fish". Well, that's the promise and the pledge. This includes whatever is the OMF barracks, and also Wahoo <github.com/wa>. If you know anything for Tacklebox, that will run in Fisherman too.

I am working on some tutorials and getting everything ready for the next milestone 0.5.0, but better ways to discover and preview the ecosystem is in the works and I vow to make it awesome.

bucaran··on Show HN: Fisherman – Fish Shell Manager
The problem with OMF is that it is entirely based in an earlier work of mine Wahoo, which I put together over a weekend and while it improved over the very original oh-my-zsh clone, it was not very good.

See the merge commit here:

* https://github.com/oh-my-fish/oh-my-fish/commit/2693a2fd18bd...

And compare to Wahoo here:

* https://github.com/bucaran/wahoo

Fisherman is a project of a different caliber, forged over a longer period of time, truer to the UNIX philosophy in principle "everything is a stream", built for extensibility and to solve OMF slow shell start issue (that has been a problem ever since I joined the project almost 2 years ago) and of course, backward compatible with OMF/Wahoo plugin/theme ecosystem.

bucaran··on Show HN: Fisherman – Fish Shell Manager
The relevant link is here (https://github.com/fish-shell/fish-shell/blob/master/share/t...)

ridiculous_fish, we still use `complete` all over the place for completions don't we. In Fisherman there is a nice little AWK script, still far from perfect that attempts to do a similar thing, parsing a utility's usage help.

usage: utility [...]

-s --short Short option ...

bucaran··on Show HN: Fisherman – Fish Shell Manager
I hope to make that easier with Fisherman. You can install any "package" or snippet if you have an URL. There is also the Fisherman Index with packages you can get by their name.

Sorry, but I like this one https://github.com/bucaran/shark ^^

bucaran··on Show HN: Fisherman – Fish Shell Manager
npm 4 dep management is more complex. In fish there is no private function scope so things are much simpler (but not as powerful indeed).
bucaran··on Show HN: Fisherman – Fish Shell Manager
Thanks for the question. I needed a term that would fit the README without sounding too extravagant either. Here is the explanation from fisher(7) [https://github.com/fisherman/fisherman/blob/master/man/man7/...]

Basically, a flat tree takes advantage of fish's lack of private scope (it bundles everything into the same "public" scope).

Fisherman then only needs to "load" the one single path where plugins/snippets/prompts/etc are transferred after being downloaded to the cache.

This is faster than, loading a path hierarchy per plugin and also means that performance is not affected based in the number of plugins installed.

bucaran··on Show HN: Fisherman – Fish Shell Manager
Fisherman is a shell manager for fish that lets you share and reuse code, prompts and configurations easily.

This tool is not a framework, it does not pollute your shell public scope with superfluous functions, it does not make your shell slow, it's just a handful of 4 ~ 5 commands that let you share and manage your configuration, plugins, prompts, snippets, etc., and does not care whether they come from Oh My Fish!, Wahoo, or other vendors. You get the most of your shell and Fisherman gets out of your way.

Features include a flat tree structure, strong UNIX ties (everything is a stream), unified plugin architecture with automatic completions, documentation via man pages and support for utilities that use Make as a build tool, external self-managed database, cache system, plugin dependencies, quick shell start, extensive documentation and compatibility with Oh My Fish ecosystem of plugins / themes.

bucaran··on DMCA notice against oh-my-fish
We decided to reconcile and end the litigation amicably adding an AUTHORS file and the following copyright:

* Copyright (c) 2015 Oh My Fish!

bucaran··on DMCA notice against oh-my-fish
Creator of Wahoo here. It's correct. I was one of the owners at omf, meaning I could delete, transfer or rename the repo.
bucaran··on DMCA notice against oh-my-fish
No, they did not. The copyright was changed from my name to "Bruno Ferreira Pinto".
bucaran··on Unix compliant arg parser for Node.js (https://github.com/bucaran/parsec)
Link: https://github.com/bucaran/parsec

Long time `minimist` user here. Leanest and simplest of the pack at just 200 LOC with _no_ dependencies by the legendary substack.

Unfortunately the documentation is scarce, it has a growing number of unresolved issues → https://github.com/substack/minimist/issues/50.

Parsec is only 50 LOC and the API is simpler, and still no dependencies!

Features

+ Well documented + Based in → [UNIX Utility Conventions](http://pubs.opengroup.org/onlinepubs/7908799/xbd/utilconv.ht...)

+ Custom aliases + Default shorthands

+ Default values / types + Handle --no-* options

+ Handle unknown options

bucaran··on Mu – 10-bit JavaScript Computer
And the CPU https://github.com/bucaran/nu
bucaran··on Fly.js: New generation build system
Because shell scripts are more complex to write. I, myself, having used grunt and then switched to gulp, ended up favoring shell scripts / npm scripts, only to realize gets much more complex for larger projects. I think a build system abstraction is legit, and Fly is pushing the status quo to an even simpler, thinner, yet flexible alternative.
bucaran··on Fly.js: New generation build system
Innovation fosters more innovation. We are trying to improve status quo. Even if this initiative fails, it may spark the right idea on the next person.

Fly tasks are co-routine-wrapped generators, so you get modern async flow inside your tasks out of the box and right off the bat.

TBH I don't know exactly how Fly is better than make since I don't use make since college years.

bucaran··on Fly.js: New generation build system
@jack_jennings

Thanks! I agree with you. I understand the opinion of the person below, but I think there is room for improvement in this area so I am trying to make the build system the JavaScript community really deserves.

bucaran··on Fly.js: New generation build system
The folks below already gave you the answer, but we are considering adding support for Flyfiles written in ES6 now. It's intrusive and opinionated, and although one of the reasons I like auto loading plugins is so that Flyfiles end up looking as agnostic as possible despite using ES5, I think it would be awesome to have ES6 Flyfiles.
bucaran··on Fly.js: New generation build system
@girvo

I am sorry I missed this post.

You are not required to create packages to use Fly! You can simply pass your transformer function to `Fly.prototype.filter` and be done with it. I think plugins should be true thin wrappers to whatever utilities you are trying to incorporate into your build task.

Compare this to gulp where you sometimes need to use vinyl and other abstractions, plus stream wrappers and other deps.

bucaran··on Civilized terminal styles for Node in ~30 LOC
Clor is a 30 some LOC original and superior alternative to colors.js and Chalk.

See repo for full docs and examples.