Skip to main content

A wrapper package designed for running continuous integration (CI) build steps using Python 3.5+.

Project description

Managing cross platform build scripts for CI can become tedious at times when you need to e.g., maintain two nearly identical scripts install_deps.sh and install_deps.bat due to incompatible syntaxes. ci_exec enables a single file to manage this using Python.

The ci_exec package provides a set of wrappers / utility functions designed specifically for running build steps on CI providers. It is

Logging by Default

Commands executed, including their full command-line arguments, are logged. This includes any output on stdout / stderr from the commands. The logging resembles what set -x would give you in a shell script. For commands that will take a long time, as long as output is being produced, this will additionally prevent timeouts on the build.

Failing by Default

Any command that does not succeed will fail the entire build. An attempt to exit with the same exit code as the command that failed will be performed. Meaning the CI provider will correctly report a failed build.

Convenient

ci_exec affords users the ability to write shell-like scripts that will work on any platform that Python can run on. A simple example:

from ci_exec import cd, which

cmake = which("cmake")
ninja = which("ninja")
with cd("build", create=True):
    cmake("..", "-G", "Ninja", "-DCMAKE_BUILD_TYPE=Release")
    ninja("-j", "2", "test")

Please refer to the full documentation for more information.

Project details


Download files

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

Source Distribution

ci_exec-0.1.0.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ci_exec-0.1.0-py3-none-any.whl (26.7 kB view details)

Uploaded Python 3

File details

Details for the file ci_exec-0.1.0.tar.gz.

File metadata

  • Download URL: ci_exec-0.1.0.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.2

File hashes

Hashes for ci_exec-0.1.0.tar.gz
Algorithm Hash digest
SHA256 4369733e5e96f371ef4bdd488a48db80fdc2987d13202a483f3eae2db160aea6
MD5 d889e07cf5d6b7b6acb37bea3e412058
BLAKE2b-256 4b29869f71066f98ad87cd673d49277bec63f303d29dc063a9382d1760ebd918

See more details on using hashes here.

File details

Details for the file ci_exec-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: ci_exec-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 26.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.2

File hashes

Hashes for ci_exec-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 86cb003890352a48dabcb43ce78b8143bdc64f39e15c26ececb18f4dc934aa64
MD5 31a5be9c687531e08fcce026127ec51b
BLAKE2b-256 9541b6df2e9bc6131604d7593c7513e3e122e9a4a1018a1a65d0aab3986fe043

See more details on using hashes here.

Supported by

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