Skip to main content

ogc, a runner of things

Project description

Build Status

OGC, a runner of things

ogc - Task runner with a focus on deployment/testing/reporting.

Description

OGC is powered by plugins that can be discovered on https://pypi.org with the prefix of ogc-plugins. With plugins installed different aspects of a run can be defined through a spec file, which is a yaml file setting up plugin configuration for the particular goal.

Usage

> pip install ogc
> ogc --spec ogc-spec-runner.yml execute

# Or with a ogc.yml file in same directory running ogc from
> ogc execute

Add plugins

To make OGC a bit more useful, install a few plugins:

> pip install ogc-plugins-runner
> pip install ogc-plugins-env

This will allow you to add functionality such as running scripts and preparing environment variables. Please see the plugins section of the docs for more information.

meta:
  name: A test spec
  description: A simple spec showing how to run commands

# Phases
setup:
  - runner:    # This is the plugin from ogc-plugins-runner
      description: Clean out build directory
      cmd: rm -rf build
      tags: [clean]

Show plugin dependencies

OGC doesn't install plugin dependencies automatically, but will give you a summary that you can pass to whatever automation strategy you want.

> ogc --spec ogc-spec-runner.yml plugin-deps

Output:

Plugin dependency summary ::

  - apt:python3-markdown
  - snap:juju/latest/stable:classic
  - snap:juju-wait/latest/stable:classic
  - pip:pytest==5.0.1

To get the install commands for the plugin deps you can pass --installable:

> ogc --spec ogc-spec-runner.yml plugin-deps --installable

Output:

sudo apt install -qyf python3-markdown
sudo snap install juju --channel=latest/stable --classic
sudo snap install juju-wait --channel=latest/stable --classic
pip install --user pytest==5.0.1

Or to handle installing those packages automatically (like in a CI run):

> ogc --spec ogc-spec-runner.yml plugin-deps --installable | sh -

More information

Project details


Release history Release notifications | RSS feed

This version

0.3.9

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

ogc-0.3.9-py3-none-any.whl (13.3 kB view details)

Uploaded Python 3

File details

Details for the file ogc-0.3.9-py3-none-any.whl.

File metadata

  • Download URL: ogc-0.3.9-py3-none-any.whl
  • Upload date:
  • Size: 13.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.3

File hashes

Hashes for ogc-0.3.9-py3-none-any.whl
Algorithm Hash digest
SHA256 9a0a6e415f7e513ba9f7d55edab360c5693edd7c0049fc0a51eff69d91ff8ac2
MD5 c9777beb62c234761a7f079b81666a88
BLAKE2b-256 80606aabc8a632fe6aab83387c5b43d7d36d270f618674d57909baf16edffb34

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page