Skip to main content

A TravisCI inspired builder

Project description

Arcli

GitHub Issues GitHub Pull Requests License


Arcli is a lightweight cross-platform builder inspired by TravisCI. It can automate deploying aplications with a single command line, and is highly extensive.

📝 Table of Contents

🧐 About

Arcli started as a hobby and quickly evolved into something incredibly useful that I implement in my daily life. With Arcli you can write code routines to be executed at the time of a deployment, as well as optional steps that can be triggered by certain conditions.

🏁 Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Installing

You can install Arcli using pip

pip install arcli

or by downloading one of our pre-compiled binaries.

# Download
wget https://github.com/guiscaranse/arcli/releases/latest/download/arcli-linux_arm64.tar.gz
# Extract
tar arcli-linux_arm64.tar.gz
# Make executable
chmod u+x arcli

Start using it or add it to your PATH

arcli run

🎈 Usage and Definitions

Arcli will try to find and read an Arcli File (arcli.yml) where it will parse and run it.

Arcli File

An Arcli file is an instruction file written in YAML. Arcli will interpret it, perform validations, and thus run the codes described.

Here it is a sample Arcli file (more samples on samples).

arcli: 0.1
os: linux
dependencies:
  - git
env:
  - TEST=sampleenv
runtime:
  - 'echo Hello World'
  - $step checkgit
  - 'echo Arcli End'
step @checkgit:
  trigger:
    name: GitDiff
    args: ["arcli/*.py"]
  script:
    - 'echo Python Files Modified'

Arcli file definitions

Key Type Optional Description
arcli float No Refers to the version of Arcli that that file was made, it is possible to use Semantic Versioning for this field
os str Yes Which operating system this file was made to run [linux, osx, windows, any (default)]
dependencies list Yes Which executables this file will need to use
env list Yes List of environment variables that will be injected at runtime.
runtime list No List of main commands to be executed by Arcli. You can reference steps using $step [step name]

Step and Triggers definitions

Steps are separate blocks of code that can be executed under certain circumstances when triggered by Triggers.

This is how a step look like:

step @checkgit:
  trigger:
    name: GitDiff
    args: ["arcli/*.py"]
  script:
    - 'echo Python Files Modified'
Key Type Optional Description
step str No It will be used to refer to the step in the runtime, you must name it after the @. Example: step @mystep
trigger obj Yes Not all steps need to have a trigger, in the absence of a trigger it will always be executed. You can see the triggers available in arcli/triggers.
script list Yes Code to be executed if the step is valid (trigger is triggered or trigger is missing)

This is how a trigger looks like:

trigger:
  name: GitDiff
  args: ["arcli/*.py"]
  options:
    autopull: true
Key Type Optional Description
name str No It will be used to identify the trigger, it must be the same as the class name
args list Yes Arguments that can be passed at the time of executing the trigger
options obj Yes Advanced options that can contain keys and values to be passed to the trigger

Triggers documentation can be found in each respective trigger file.

⛏️ Built Using

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

arcli-0.1.1.tar.gz (13.3 kB view details)

Uploaded Source

Built Distribution

arcli-0.1.1-py3-none-any.whl (14.8 kB view details)

Uploaded Python 3

File details

Details for the file arcli-0.1.1.tar.gz.

File metadata

  • Download URL: arcli-0.1.1.tar.gz
  • Upload date:
  • Size: 13.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.6.7 Linux/4.15.0-1037-gcp

File hashes

Hashes for arcli-0.1.1.tar.gz
Algorithm Hash digest
SHA256 13c7203e7bf7669ee6ab162c71affa66659965313786776e66829ca6af74a2a0
MD5 9ebff2f1fb40e0547735cd4c2aa210b2
BLAKE2b-256 570615358ef3458ddce08155c462172f4c2b0460fceac191bd826100d44b82ff

See more details on using hashes here.

File details

Details for the file arcli-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: arcli-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 14.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.6.7 Linux/4.15.0-1037-gcp

File hashes

Hashes for arcli-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 441d146646db0c15c5bdba448eebeb9707cf5bc5b084faea872068213dbec100
MD5 f702d181c84c6e0dbcbe07352f09c1e7
BLAKE2b-256 3f0d14374d588cd56f3207d1532bc9bfc723e15a6a23461315a38da03c456133

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