← Back to team overview

quickly-talk team mailing list archive

Re: Preferences

 

Actually $quickly configure is a better command name than $quickly preferences

$quickly configure dependencies - create an editable file for a
project and apply read_input() to it.

$quickly configure -  create an editable file for quickly and apply
read_input() to it.

 This editable file is a ConfigParser file, has a section for every
template and a [DEFAULT] section

This will complete the configuration structure
quickly      ~/.config/quickly/<filename> [DEFAULT]
template   ~/.config/quickly/<filename> [template name]
project      path/to/project/.quickly

all files are ConfigParser style. Assume developers understand these files.


On 27/05/2011, tony byrne <tony.badwolf@xxxxxxxxx> wrote:
> OK by itself ide does not require a preferences system. A simple ide
> approach is to use QUICKLY_EDITOR (with all the fallbacks) in
> get_quickly_editors() to edit multiple files and EDITOR in
> read_input() to block and edit one file. Currently both
> get_quickly_editors() and read_input() are locked together.
>  I toyed with the idea of using $quickly configure ide but $quickly
> configure is only available inside a project. Perhaps make $quickly
> configure available outside a project.
>
>  A related branch, add_widgets, allows a developer to run quickly add
> <foo> where <foo> is one of the developer's custom favourite file e.g.
> company_logo.png. In order to do that we need $quickly add to look
> inside <a quickly template>/store *and* the developer's files e.g.
> ~/Templates. We need an option somewhere pointing to these outside
> template files.
>
> add_widgets branch creates this file ~/.config/quickly/preferences
>
> [DEFAULT]
> #plugin_path = files which can be used with quickly add command
> plugin_path = /usr/share/pyshared/quickly/widgets
> ide = gedit
> #ide = editor defined in environment
>
> [ubuntu-application]
>
> [ubuntu-flash-game]
>
> [ubuntu-pygame]
>
> [ubuntu-cli]
>
> and uses read_input() to change it.
>
> The point is that configuration is available in 2 of 3 possibilities
> quickly has .bashrc
> projects have .quickly
> templates have nothing
>
> Different templates could need different plugin_path e.g. ~/Templates/java
>
> ubuntu-cli and ubuntu-pygame applications do not have a $quickly add
> command
>
> For user/developer experience $quickly preferences (or $quickly
> configure) -> edit the presented file seems easier than
> $EDITOR ~/.bashrc
> logout (or close terminal)
> login or gnome-terminal
> especially as quickly can fill ~/.config/quickly/preferences with lots
> of comments
>
> On 27/05/2011, Didier Roche <didrocks@xxxxxxxxxx> wrote:
>> Le vendredi 27 mai 2011 à 09:04 -0400, Michael Terry a écrit :
>>> Tony has proposed an interesting idea: preferences for templates.
>>>
>>> https://code.launchpad.net/~quickly-committers/quickly/ide/+merge/61326
>>>
>>> That branch adds a preference system and the first preference: what
>>> editor you want to open files in.
>>>
>>> You might ask as I did, "what about QUICKLY_EDITOR", but Tony says:
>>>
>>> """
>>> Having an environment variable for each template would be unwieldy.
>>> Also the environment variables are effectively
>>> export PARAMETER=value in the ~/.bashrc file
>>> while
>>> parameter=value in the ~/.config/quickly/preferences file allows a
>>> $quickly preferences command to edit them and apply instantly without
>>> requiring a terminal restart.
>>> """
>>>
>>> Anyway, the point of this email is to see what others think, since
>>> this is an arguably big change.
>>
>> I'm not quite sure about this change. I'm all in favor that the
>> get_quickly_editors() get into quickly/templatetools.py rather that
>> adding another preference system.
>>
>> This part is an advanced use case, that is already adressed by some way
>> by QUICKY_EDITOR, I think we should really focus our effort first to get
>> the user/developer experience appealing (which is still not reached at
>> all IMHO) for our resources than trying to add a billions of options for
>> advanced usage (which are already covered in some other way).
>>
>> The restarting the terminal is already needed (maybe will be fixed in
>> the near future btw), after installing Quickly to get shell completion
>> on.
>>
>> Also, for a long time, I try to fight adding to much commands in Quickly
>> itself so that we don't end up with a long list of commands, so really
>> not sure about the preferences one. Less is more. ;)
>>
>> So, I think the idea of still supporting advanced use case is important
>> (and that's why we added EDITOR, and then QUICKLY_EDITOR support), but
>> I'm not really certain that change is relevant? Thoughts? Do we have any
>> idea of people who will change the EDITOR between templates, or who will
>> change the defaults?
>>
>> Just my 2 cents :)
>>
>> Didier
>>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~quickly-talk
>> Post to     : quickly-talk@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~quickly-talk
>> More help   : https://help.launchpad.net/ListHelp
>>
>


Follow ups

References