Run Python localhost via Grunt

I am relatively new to Gruntjs, but I managed to run everything except my local host.

How can I make grunt run python manage.py runserver 0.0.0.0:8000 --insecure?

+4
source share
1 answer

You can use grunt-shell https://github.com/sindresorhus/grunt-shell

Try something like this:

grunt.initConfig({
    shell: {
        pythonServer: {
            options: {
                stdout: true
            },
            command: 'python manage.py runserver 0.0.0.0:8000 --insecure'
        }
    }
});

grunt.loadNpmTasks('grunt-shell');
grunt.registerTask('default', ['shell:pythonServer']);

Hope this helps :) Greetings

+12
source

All Articles