Skip to main content

Code generator for automating configuration, setup, and yak shaving.

Project description

qwikstart: Code generator for fun and profit

https://img.shields.io/badge/License-BSD%203--Clause-blue.svg https://travis-ci.com/tonysyu/qwikstart.svg?branch=master https://codecov.io/gh/tonysyu/qwikstart/branch/master/graph/badge.svg https://readthedocs.org/projects/qwikstart/badge/

qwikstart is a code generator for integrating code into existing projects. It’s similar to code generators like cookiecutter, yeoman, and hygen but with a focus on adding code to existing projects.

A simple hello-world.yml script in qwikstart would look something like:

steps:
    "Ask for name":
        name: prompt
        inputs:
            - name: "name"
              default: "World"
    "Display message":
        name: echo
        message: |

            Hello, {{ qwikstart.name }}!

The first step uses the prompt operation with a single input "name", with a default value of "World" (which is editable when running the script). The next step just uses the echo operation to display a message. This script can be using qwikstart run:

$ qwikstart run hello-world.yml

Please enter the following information:
name: World

Hello, World!

Install

The recommended way of installing qwikstart is to use pipx:

pipx install qwikstart

If you happen to be setting up pipx for the first time, the pipx installation instructions suggest running pipx ensurepath to update the user path. Note, if you use ~/.profile instead of ~/.bash_profile, this will add ~/.bash_profile, which will take precendence over ~/.profile. Either move the code from ~/.bash_profile to ~/.profile or link your profiles.

Basic Usage

After installing qwikstart, you can run a simple hello-world example using the following:

$ qwikstart run --repo https://github.com/tonysyu/qwikstart examples/hello_world.yml

By default, there are abbreviations for common git repos, so the above can also be written:

qwikstart run --repo gh:tonysyu/qwikstart examples/hello_world.yml

See Also

There are a lot code generators and scaffolding tools out there, and the following is just a selection of some of the most popular ones:

  • cookiecutter: A command-line utility that creates projects from cookiecutters (project templates)
  • hygen: The scalable code generator that saves you time.
  • yeoman: The web’s scaffolding tool for modern webapps

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for qwikstart, version 0.7.1
Filename, size File type Python version Upload date Hashes
Filename, size qwikstart-0.7.1-py3-none-any.whl (49.3 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size qwikstart-0.7.1.tar.gz (32.0 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page