Skip to main content

Posts

11th gsoc week report

Nearly out of time! Some final adjustments were made this week, documentation was accordingly updated and preparations are being made to the deliver GSoC's official final submission. Check out the latest changes in this week's blogpost! Events Code 1 - prosodyctl: fixed a typo
2 - util.startup: changed the way util.paths.complement_lua_path was being accessed
3 - util.paths: fixed another typo
4 - util.pluginloader: Added a new path to the variable local_names
5 - core.configmanager: Removed code related to complement_lua_path
6 - prosodyctl: install, remove and list commands now use the call_luarocks function
7 - util.prosodyctl: Removed the check_flags and execute_command functions
8 - util.prosodyctl: call_luarocks function now sets the directory variable itself

Documentation These are planned changes to the already existing documentation that you can access at prosody's website. For example, you can check prosodyctl's page through the link:  https://prosody.im/doc/proso…
Recent posts

10th gsoc week report

Last week has been spent mostly on writing good documentation and trying to see what else can be improved around whats done. Check out below, to see which doc files are about to be updated so far! Prosody documentation: /doc/prosodyctl- added command entries
/doc/prosodyctl - Added a reference to the plugin installer documentation page
/doc - Added a reference to the plugin installer documentation page
/doc/plugin_installer - Created this new page
/doc/plugin_installer - Added introduction, pointing to links regarding prosodyctl, core and community modules, installing modules manually
/doc/example_config - Added the new field for the plugin installer directory
/doc/configure - Added info about configuring the installer's path
Difficulties/Considerations Not too sure what to do with /doc/installing_modules. I could update the installer info here, but I feel it needs a dedicated space. This space is still useful on its own, since core plugins are still coming installed in the …

9th GSoC Week report

Code review was in order last week, and some major improvements were made regarding my pseudo-spaghetti code, which now should be more readable and maintainable. Down below you can check out the complete list of changes made recently to prosody files, in order to polish the Installer! Events prosodyctl1: Swapped prints for the show_message function
2: Removed a comment from the remove command
3: Rewrote the install command
4: Rewrote the remove command
5: Rewrote the list command, to make it cleaner and easier to work with
6: Install, remove and list now use the execute_command instead
7: Removed the auxiliary command enabled_plugins
core/configmanager1: Added support to complement_lua_path
util//prosodyctl 1: Added the check_flags function - changeset 2: Added the call_luarocks function 3: call_luarocks command differentiates output, when being called by install/remove 4: The call_luarocks function can now also deal with the list command 5: Added the execute_command function 6: check_flags n…

8th GSoC Week Report

After some fusion dance, we have some stuff working neatly! Last week was all about the lua environment and improvements aimed at user-friendliness, which you can check down below with the latest changesets and demos. Events prosodyctlRemoved most development/experimental commands Created a script that is automatically setting up a ready to be served repository will rockspecs for all of prosody's plugins (demo)Various improvements/updates to the main commands:list - demoinstall demos:installing a prosody plugininstalling a luarocks libraryInstallation also prints configuration helpremove - demoprosody uses a separate folder to deal with non-standard plugins - demoUsers can configure their own path, and override it at any time from the command line if needed - demoUpdated the startup utility script regarding management of default/custom installer directories and lua environment Difficulties The greatest obstacles this past week were everything related with the concept of lua envir…

Luarocks tutorial

Prosody's plugin installer is making use of Luarocks to get things working. Therefore, it makes sense that we look a bit into Luarocks to see how it works. Concepts Here is what you need to know. Luarocks uses files, called rockspecs, to get things installed around. These are basically instruction files and they tell the program how to do the work. We can pack the sources and the rockspecs into a single file, called a rock. We can install libraries from both rocks and rockspec files. The code is installed in what is called a rock tree, which is a folder with a specific structure inside, organized in a way to help with the required management of libraries and servers. Installing, removing and list If you are working on debian you can just use: sudo apt-get install luarocks Now, there might be some trouble here and there, depending on your machine, or if you are in a different OS, but the guys at luarocks have tips for almost every possible situation, just check here: https:/…

Mid July GSoC Report

Improving Prosody
We are past mid-way through GSoC's coding period already! Check out the most recent improvements made through keyboard and mouse in recent times of history. Events prosodyctl Added the following commands: get_modules - development command, downloads all of prosody modules to a folder, downloaded_modules, in the working directorywrite_rockspec - development command, writes a rockspec from one of the modules at the auxiliary folder and saves it theremake - Installs a rockspec. The rockspec name is the only argument it accepts. The file and its sources have to be located at downloaded_modules/module_we_are_installing.install/remove - Installs/removes a rockspec, either at the working directory's plugins path or at a directory specified by the --tree flag. We need to be in the same folder as the rockspec, otherwise it will search for rocks from Luarock's repository.list - Shows a list of installed rocks. If no argument is passed it will look at the working di…

Remainder of GSoC's first phase summary

A long way to climb

End of first phase is here! This post reflects last weeks' development as I juggle hands and feet through the climb. Events Prosodyctl - Added support for luarocks: admin-add (Flags supported: --tree, --server, --no-refresh, --help)admin-remove (Flags supported: --tree, --server, --no-refresh, --help)list commands(Flags supported: --tree, --help) - Various bug fixes, to make added functions comply with prosodyctl functionality and coding style
Software usage - Solved some issues I was having when using ZeroBrane's studio to debug - Tinkering around the creation of rocks and rockspecs from mod_smacks
Difficulties - Still clumsy using different tools, like ZBS's IDE, Mercurial and Luarocks - Some challenges with blog posts formatting
Future goals - Enabling and disabling the mod_smacks plugin through prosodyctl 
Considerations Albeit still going too slowly for my taste, some progress is being made in most fronts. University evaluation period will be ove…