Flash-Shell - A small utility I created as a side project.
To compile and run, just type:
makeThis will automatically create a new bin/ folder that will have the fsh and it will also compile all the existing plugins
and put them inside the bin/plugins folder.
To run it, just simply run:
cd bin && ./fshand you'll drop inside fsh.
Currently, the only customizations I have added are modifications to prompt using the config.hxx file and creating your own custom
plugins.
Looking at ./src/config.hxx, you can see that all the variables are modifiable. Currently, I have not added the integration with .fshrc file but in the near future, I will surely do that and then we'll have much more control over everything using files rather than recompiling the project every single time.
Each plugin is basically a program that can be integrated directly with fsh.
To create custom plugins, you can get the [_template].cxx from the src/plugins/ directory. Then, all you really need to do is just modify the variables accordingly and inside the _impl method, you need to write the actual implementation of the command you're trying to implement.
Make sure to also modify the plugin_create export methods because those will be invoked to fetch the class itself when dynamically loading.
To build, just run the make plugins command and you'll have your plugin built.
If you want to just build this plugin, you can use the following g++ command:
g++ -o lib<cmd>.so -fPIC -shared <cmd>.cxxThen just move the .so file to the plugins folder and it will be implemented automatically.
During runtime, you can also use the load-plugin command to dynamically load a plugin.
This is just a side project and there may be some bugs here and there. If you find any, just open an issue and I'll try and fix them. But, I'm fairly certain I won't be looking after this project that much but whenever I'm bored and want to do something different.