Hi All,
Trying to get back into Pyramid, got a number of projects I want to use
it for, so expect plenty of silly questions, please feel free to punt me
at urls...
First up: does Pyramid have a management command framework like
Django's manage.py?
I couldn't see anything in a quick scan
Hi,
Do you want to create new management commands or do you just want to get
access to the shell?
Regards,
Thierry
2015-06-01 8:56 GMT+02:00 Chris Withers ch...@simplistix.co.uk:
Hi All,
Trying to get back into Pyramid, got a number of projects I want to use it
for, so expect plenty of
On 01/06/15 13:08, Chris Withers wrote:
Yes, I'm wondering if there's a framework for adding in new commands.
setuptools lets you create custom scripts that are installed with your
package. Note that this isn't specific to Pyramid. See [1] and the
initializedb command created by the alchemy
If you want a really easy framework for managing script options and so on, I
recommend http://click.pocoo.org
On 01.06.2015 12:08, Chris Withers wrote:
On 01/06/2015 08:11, Thierry Florac wrote:
Hi,
Do you want to create new management commands or do you just want to get
access to the
Le 01/06/2015 12:08, Chris Withers a écrit :
On 01/06/2015 08:11, Thierry Florac wrote:
Hi,
Do you want to create new management commands or do you just want to
get access to the shell?
Yes, I'm wondering if there's a framework for adding in new commands.
In that case, maybe you just want
Substance D has a few examples of this:
https://github.com/Pylons/substanced/tree/master/substanced/scripts
Also look at setup.py to see how to declare as console scripts.
Carlos de la Guardia
On Mon, Jun 1, 2015 at 1:56 AM, Chris Withers ch...@simplistix.co.uk
wrote:
Hi All,
Trying to get
As far as I know, writing custom command lines tools is achieved through
the bootstrap module :
http://docs.pylonsproject.org/projects/pyramid/en/latest/api/paster.html
You can easily write a generic command builder like it's is done in kotti :
i heartily second that suggestion. click is a joy to work with!
On 01 Jun 2015, at 14:00, Oliver dief...@gmail.com wrote:
If you want a really easy framework for managing script options and so on, I
recommend http://click.pocoo.org
On 01.06.2015 12:08, Chris Withers wrote:
On 01/06/2015
PS: in particular, the INI file's path shouldn't be hardcoded, but
should be read from the command line, as is the case with pserve,
pshell, etc.
from pyramid.paster import bootstrap
env = bootstrap('/path/to/my/development.ini')
From there you could/should add command-line arguments
On 01/06/2015 08:11, Thierry Florac wrote:
Hi,
Do you want to create new management commands or do you just want to
get access to the shell?
Yes, I'm wondering if there's a framework for adding in new commands.
Chris
--
You received this message because you are subscribed to the Google
Hi Chris,
the pyramid shell is described here:
http://docs.pylonsproject.org/projects/pyramid/en/1.5-branch/narr/commandline.html#the-interactive-shell
Basically, it's an (i)python shell with the application environment
(database connection, etc.) enabled. But I'm not sure it does what you
want,
For that type of thing, I'd probably use Mush:
http://pythonhosted.org/mush/examples.html
...unless I'm mistaken, once decorated by click, the callables you
decorate are no longer unit testable, right?
Chris
On 01/06/2015 13:02, Tom Lazar wrote:
i heartily second that suggestion. click is
it changes the global interpreter state - *sigh*
On 01/06/2015 19:07, Oliver wrote:
more or less: http://click.pocoo.org/4/api/#testing
On 01.06.2015 18:33, Chris Withers wrote:
For that type of thing, I'd probably use Mush:
http://pythonhosted.org/mush/examples.html
...unless I'm
more or less: http://click.pocoo.org/4/api/#testing
On 01.06.2015 18:33, Chris Withers wrote:
For that type of thing, I'd probably use Mush:
http://pythonhosted.org/mush/examples.html
...unless I'm mistaken, once decorated by click, the callables you decorate
are no longer unit
I was just looking into this and if you don't want to use
click.testing.CliRunner one can also get the original function
by accessing the `callback` attribute of the decorated function...
On 01.06.2015 20:17, Chris Withers wrote:
it changes the global interpreter state - *sigh*
On
15 matches
Mail list logo