6 ms·
No, but really, why? I am not putting it down. I just don’t understand what is happening exactly, and the why might help.
by Hnrobert42 7y ago
No, but really, why? I am not putting it down. I just don’t understand what is happening exactly, and the why might help.
- BlackLotus89 7y agoQuote from the Readme: > Why not?
- IshKebab 7y agoThe "why not" is pretty obvious so that doesn't really answer the question. But anyway the "why" is equally obvious - for fun! There's no way anyone reasonable would consider this useful or even sane so it must just be for fun, or to learn about FUSE.
- PopeDotNinja 7y agoThey address this in the README. https://github.com/pcgrosen/bashfs#why https://github.com/pcgrosen/bashfs#why
- Dylan16807 7y agoI appreciate the attempt to help, but I disagree. The README "addresses" a question of "why?". But because that's not a real answer, it's not a valid response to "but really why?"
- chmod775 7y ago"Why not?" here is an idiom for "I know it serves little purpose but I did it for the fun of tinkering with stuff."
- Dylan16807 7y ago"Why not?" can mean a lot of different things. That's why it can be helpful to get an actual answer.
- PopeDotNinja 7y agoI thing the "Why not?" is another way of saying that you've put more effort into understanding the motivation behind this project than OP did.
- Dylan16807 7y agoThat would be wasted effort, though. Sure, I can come up with a dozen potential reasons. But I want to know the actual reason(s).
- PopeDotNinja 7y agoI can't tell if you're trolling. Sometimes I do stuff because "Why not?" sounded like a good idea, and I reckon others do, too. That's all I've got.
- iguessthislldo 7y agoThe actual "why" is the author did it for fun, there's basically no purpose to it. I can try to explain it though: Interacting with file systems can be generally summed up in a handful of basic operations. Two of the most important operations are open, which asks the filesystem if it has a file of a given name, and read, which reads the contents of that file. FUSE is a Linux wrapper for writing virtual file systems by implementing these basic operations. Here open, instead of taking a filename, is telling the program what command to run and read, instead of returning the contents of a file is returning the output of the command.
- ansible 7y agoI'm glad I'm not the only one who didn't get it. I can understand if you want to do something wacky with FUSE. Something like mounting a PostScript or JSON file, and using the filesystem interface to observe and modify the contents. Or something else that is vaguely hierarchical. I just didn't see any "reasonable" mapping for running a series of commands to a filesystem.
- xfitm3 7y agoI get that it's for fun but the danger is security. Someone could use this as a "fun" feature at work and then get pwned.
- pinusc 7y agoEh, if an attacker has filesystem access you're already pwned.
- bdarnell 7y agoIt's mainly for fun, but to find cases where it might be useful, think about symlinks into this filesystem. `ln -s /bashfs/somescript.sh /etc/hosts` and then your hosts file can be dynamically generated without any changes to programs that read it. It can be a clever way to sneak dynamic behavior into contexts where there would normally just be a static file.