Long time no see, everyone! Even though it may appear that nothing much has happened in the world of DevAssistant, nothing is further from the truth. We have been working on improving DevAssistant features and planning new ones. We’re all looking forward to having the version 1.0 out, which will be a big milestone in DevAssistant’s life, but that’s still many weeks away, so in order to bring some of the features to you already, we release one more incremental update in the meantime.
The changes this version brings are mostly under the hood, but there are also quite some improvements that you can immediately see and benefit from. Most of the visible changes happened around handling the DAP archives through which assistants are distributed.
Uploading DAPs to DAPI
A feature that was requested by many was the ability to upload a DAP right from the DevAssistant command-line interface. We answered your demand, and now you can upload a DAP with the help of the extra/dap assistant like this:
da extra dap upload -d your_shiny_dap-0.0.1.dap
All you need for that is the DAP
dap, which is either packaged in your distribution (it is in Fedora under the name
devassistant-dap-dap), or can be downloaded by running:
da pkg install dap
When you upload, you must agree to the terms and conditions, which is an interactive step (you need to press
y), but you can use the flag
--agree-with-terms for automated scripts.
Pretty package info output
In this version, we also fixed how information about DAPs is output. If you query a package on the DAPI for info, you get this text (listing DAP
python by running
da pkg info python):
python-0.11 =========== Python assistants (library, Django, Flask, GTK3) Set of crt assistants for Python. Contains assistants that let you kickstart new Django or Flask web application, pure Python library or GTK3 app. Supports both Python 2 and 3. License: GPLv2+ Home page: https://github.com/devassistant/dap-python Issues: https://github.com/devassistant/dap-python/issues User rating: 4.5 (2 votes) The following Assistants are contained in this DAP: * crt python * crt python django * crt python flask * crt python gtk3 * crt python lib After you install this DAP, you can find help, for example about the Assistant "crt python lib", by running "da crt python lib -h".
Snippets contained in the DAP and other developer-related bits of information are not listed on purpose because most users do not care about them. If you want to list them, use the
--full option with the command.
Installing DAPs in different paths
We believe that developers of assistants will appreciate the option to install DAPs into other directories than those set by default. For example, by setting the
DEVASSISTANT_HOME environment variable, you can install DAPs into another directory, which is very useful if you want to test your assistants without breaking anything on your system.
You can find the full information at the DevAssistant documentation site.
Changes in Assistant Syntax
If you write your own assistants, you may have noticed that there have been slight inconsistencies in how Command Runners are invoked – some accept lists, some strings, some mappings. We decided to make the situation as predictable as possible, so all Command Runners now accept only strings or mappings (mappings are dictionaries in Python talk, associative arrays elsewhere).
This means that the
dda_w (write to .devassistant file) and
github commands should only be invoked with a mapping of arguments, instead of a list. In the version 0.11.0, invocation with a list of arguments is still accepted, but we discourage it strongly. In the next version, a warning will be displayed, and in the version after that, assistants using this method won’t work at all.
One further change that affects you is the change of behaviour of the
github command. In previous versions, it guessed the name of the repository and the user. As of version 0.11.0, you need to specify both values in your assistant explicitly. The assistants that we ship are already fixed to use the new behaviour. If you encounter this error in an assistant from a different developer, please ask them to fix this.
All the rest
On top of all the changes mentioned above and some more, there is the new engine for bash completion. Currently, it only fixes the bug when no file paths were autocompleted (so installing a DAP from a different directory could become a bit annoying), but in the near future, you can look forward to features like autocompleting the list of installed DAPs when uninstalling and more.
As usual, you can get DevAssistant through the means listed at the download page.