jkaluza / freshmaker

Forked from freshmaker 7 years ago
Clone

f348ff8 Refactor utility scripts

Authored and Committed by cqi 6 years ago
    Refactor utility scripts
    
    This patches introduces a new script `manager` and move the
    functionalities of create_sqlite_db, start_freshmaker_from_here and
    start_frontend_from_here to this new script.
    
    During development, we need to set PYTHONPATH and
    `FRESHMAKER_DEVELOPER_ENV` to run commands from `freshmaker/manage.py`,
    the removed scripts only sets those two variables for limited commands,
    not all. New script `manager` fixes this. That is useful for me
    particularly to run commands related to database migrations as an
    example.
    
    Script manager accepts argument either help, -h, or --help to print
    usage. Command `createdb` maps to `create_sqlite_db`, `runfrontend`
    maps to `start_frontend_from_here`, and `runfreshmaker` maps to
    `start_freshmaker_from_here`. In addition, all commands
    `freshmaker/manage.py` accepts are usable as well, for example `manager
    db revision --help`.
    
    Signed-off-by: Chenxiong Qi <cqi@redhat.com>
    
        
file removed
-4
file added
+51