<s> import logging <EOL> import subprocess <EOL> import click <EOL> try : <EOL> from instance import settings <EOL> APP_ROOT = settings . APP_ROOT <EOL> except ImportError : <EOL> logging . error ( '<STR_LIT>' ) <EOL> exit ( <NUM_LIT:1> ) <EOL> except AttributeError : <EOL> from config import settings <EOL> APP_ROOT = settings . APP_ROOT <EOL> PACKAGE_PATH = '<STR_LIT>' . format ( APP_ROOT , '<STR_LIT>' ) <EOL> @ click . command ( ) <EOL> @ click . argument ( '<STR_LIT:path>' , default = PACKAGE_PATH ) <EOL> def cli ( path ) : <EOL> """<STR_LIT>""" <EOL> cmd = '<STR_LIT>' . format ( path ) <EOL> return subprocess . call ( cmd , shell = True ) </s>
