Metadata-Version: 2.4
Name: evyx
Version: 0.1.0
Summary: Local automation engine: turn complex routines into simple actions.
Project-URL: Homepage, https://github.com/NytroxDev/Evyx
Project-URL: Repository, https://github.com/NytroxDev/Evyx
Project-URL: Issues, https://github.com/NytroxDev/Evyx/issues
License-Expression: MIT
License-File: LICENSE
Keywords: actions,automation,cli,workflow,yaml
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: System :: Shells
Requires-Python: >=3.11
Requires-Dist: pyyaml>=6.0
Description-Content-Type: text/markdown

# Evyx

> Local automation, as simple as a YAML file.

[![CI](https://github.com/NytroxDev/Evyx/actions/workflows/ci.yml/badge.svg)](https://github.com/NytroxDev/Evyx/actions/workflows/ci.yml)
[![License](https://img.shields.io/github/license/NytroxDev/Evyx?cacheSeconds=300)](https://github.com/NytroxDev/Evyx/blob/main/LICENSE)
[![Security Policy](https://img.shields.io/badge/security-policy-blue)](SECURITY.md)
[![AI Guide](https://img.shields.io/badge/for_AI-AGENTS.md-purple)](AGENTS.md)

Routines you type over and over, packaged as small YAML actions you can install, inspect, and run from anywhere.

**Small & tested** - 52 tests · Python 3.11+ · one runtime dependency (PyYAML)

---

## Table of Contents

- [Why Evyx?](#why-evyx)
- [Shell routines vs Evyx](#shell-routines-vs-evyx)
- [Installation](#installation)
- [Quick Start](#quick-start)
- [Key Features](#key-features)
- [Action Reference](#action-reference)
- [When NOT to use Evyx](#when-not-to-use-evyx)
- [Changelog](#changelog)
- [Contributing](#contributing)
- [License](#license)

---

## Why Evyx?

I wrote Evyx because I kept running the same routines by hand: start the dev environment, check Docker, print system
info. Aliases help, but they never follow you to a fresh machine, and Makefiles belong to projects, not to your day to
day.

I wanted a handful of commands that behave the same everywhere I work: install a routine from a file, inspect it, run
it. No framework, no daemon, no configuration file to edit. Just a YAML file and a CLI.

That's the idea behind Evyx: your routines, versioned like code, runnable like scripts.

---

## Shell routines vs Evyx

**A routine as shell one-liners (3 lines):**

```bash
echo "Welcome $(whoami)!"
date "+%A %d %B %Y, %H:%M"
df -h / | tail -1
```

**Same routine as an Evyx action (`day-start.yml`):**

```yaml
name: day-start
description: Morning startup routine
author: nytrox
steps:
  - shell: echo "Welcome $(whoami)!"
  - shell: date "+%A %d %B %Y, %H:%M"
  - shell: df -h / | tail -1
```

```bash
evyx add day-start.yml
evyx day-start
```

One file, one command, and the same routine on any machine you install it on.

**What you get out of the box:**

- **Installable routines**: `evyx add <file>` copies an action to `~/.evyx/actions`
- **Interactive variables**: `{{name}}` placeholders answered at run time
- **Action introspection**: `evyx info <action>` shows questions, steps, and plugins
- **Silent by default**: logs only with `-d`/`--debug`, errors always shown
- **Internationalized**: English by default, French available via `EVYX_LANG=fr`

---

## Installation

```bash
# From source (before the PyPI release)
uv tool install --editable .
# or
pip install .
```

Requirements: Python 3.11+, PyYAML.

---

## Quick Start

**Create an action:**

```yaml
# hello.yml
name: hello
description: Demo action
author: nytrox
steps:
  - shell: echo "Hello from Evyx"
```

**Install and run it:**

```bash
evyx add hello.yml
evyx hello

# and when you forget what you installed
evyx list
evyx info hello
evyx remove hello
```

---

## Key Features

```yaml
name: rust-dev
description: Prepare a Rust project (without creating anything)
author: nytrox
questions:
  - name: project
    question: Project name?
    default: mon-crate
  - name: type
    question: Binary or library?
    options: [binary, library]
steps:
  - shell: echo "cargo new {{project}} --{{type}}"
  - shell: echo "crate {{project}} ready"
```

```bash
$ evyx rust-dev
? Project name? [mon-crate] :
? Binary or library? [binary/library] :
```

- **Questions & variables**: `{{name}}` placeholders in step commands, answered interactively before the action runs.
  Empty input falls back to `default`, or to the first `option`. Invalid options are re-asked.
- **Validation at load time**: an action referencing a variable with no matching question fails on `evyx add`, not at
  run time.
- **Action details**: `evyx info <action>` shows the name, description, author, plugins, steps, and every question with
  its default and options.
- **Explicit run**: `evyx run <action>` and `evyx <action>` are equivalent; logs appear with `-d`/`--debug`.
- **Internationalization**: messages come from bundled catalogs. The locale is detected via `EVYX_LANG`, then
  `LC_ALL`, `LC_MESSAGES`, `LANG` (git-like), and falls back to English. Try `EVYX_LANG=fr evyx list`.

---

## Action Reference

| Key           | Required | Description                                        |
|---------------|:--------:|----------------------------------------------------|
| `name`        |   yes    | Identifier, `[a-z0-9][a-z0-9._-]*`                 |
| `description` |    no    | Shown in `list` and `info`                         |
| `author`      |    no    | Shown in `info`                                    |
| `steps`       |   yes    | Non-empty list of step mappings                    |
| `questions`   |    no    | List of questions, asked before the action runs    |

**Step keys:**

| Key     | Description                                         |
|---------|-----------------------------------------------------|
| `shell` | The command to run. The only supported plugin today |

A `plugin` field is planned so steps can target other executors than `shell`.

**Question keys:**

| Key       | Description                                      |
|-----------|--------------------------------------------------|
| `name`     | Variable name, `[a-z][a-z0-9_]*`        |
| `question` | The text shown to the user              |
| `default` | Fallback on empty input (string or number)       |
| `options` | Non-empty list of allowed answers                |

**Variables:** `{{name}}` in step commands is replaced by the answer to the question of the same name. Any reference
without a matching question is an error at load time.

---

## When NOT to use Evyx

Evyx runs shell commands on your machine, on demand. It is not a scheduler.

- **Scheduling**: use cron, systemd timers, or launchd
- **Remote orchestration**: use Ansible, Fabric, or your deployment tooling
- **CI/CD pipelines**: GitHub Actions and friends run on servers, Evyx runs where you are
- **Anything stateful**: actions are plain shell steps; keep them idempotent and dependency-free

Everything else? Evyx has you covered.

---

## Changelog

See [CHANGELOG.md](CHANGELOG.md) for a per-release history of changes.

---

## Contributing

Contributions are welcome. Please read [CONTRIBUTING.md](CONTRIBUTING.md) before submitting a pull request.

- Bug reports : [Open an issue](https://github.com/NytroxDev/Evyx/issues)
- Feature requests : [Suggest an idea](https://github.com/NytroxDev/Evyx/discussions)
- Pull requests : Follow the contribution guide

All contributors are expected to follow the [Code of Conduct](CODE_OF_CONDUCT.md). Security issues should be reported
privately, see [SECURITY.md](SECURITY.md).

---

## License

MIT License : see [LICENSE](LICENSE) for details.

---

## AI

Evyx is human-led, AI-assisted. See [AI.md](AI.md) for how AI tools are used in this project.
