Opened 15 years ago

Last modified 15 years ago

#279 closed task (FIXED)

Make scripts default to mediagoblin_local.ini if exists, mediagoblin.ini otherwise

Reported by: Christopher Allan Webber Owned by: Christopher Allan Webber
Priority: minor Milestone: 0.2.0
Component: documentation Keywords:
Cc: Parent Tickets:

Description

It's both hard to document and hard to follow to provide commands where you can specify your own config file, but then you have to specify that config file every single time for every command afterwards.

We know people are going to write their own config files... we've already .gitignore'd paste_local.ini and mediagoblin_local.ini. When no config file is passed in, we should make it so that it checks for and uses mediagoblin_local.ini first and if that doesn't exist uses mediagoblin.ini. This will allow for a simple way for users to configure mediagoblin and be able to run commands without accidentally running them on the wrong (non-custom) config files, and reduce a certain amount of verbage in our docs.

Change History (7)

comment:1 by Christopher Allan Webber, 15 years ago

Additionally we should change the paste config's reference to the mediagoblin config file to be a list which includes mediagoblin_local.ini. Then we should also update the paste factory to treat this like a list:

def paste_app_factory(global_config, **app_config):
    mgoblin_app = MediaGoblinApp(app_config['config'])

    return mgoblin_app

Shouldn't be too hard to change that!

comment:2 by Christopher Allan Webber, 15 years ago

lazyserver should default to paste_local also. Runtests doesn't need to though :)

comment:3 by Elrond, 15 years ago

The last point is simple. Done in branch: misc/lazyserver_paste_local

This also adds the --server-name option in the help's example section, might help someone!

comment:4 by Christopher Allan Webber, 15 years ago

Milestone: 0.1.0
Owner: set to Christopher Webber

Updates made, including those in Elrond's branch! Merged & pushed!

comment:5 by Christopher Allan Webber, 15 years ago

Milestone: 0.1.00.2.0

comment:5 by Christopher Allan Webber, 15 years ago

Status: NewClosed

Oh yeah, this is done :D

comment:6 by Will Kahn-Greene, 14 years ago

The original url for this bug was http://bugs.foocorp.net/issues/620 .
Relations:
#270: related

Note: See TracTickets for help on using tickets.