Metadata-Version: 2.4
Name: lus
Version: 0.6.0
Summary: A simple task-runner using KDL for configuration
Home-page: https://github.com/jhasse/lus
Download-URL: https://github.com/jhasse/lus/archive/v0.6.0.tar.gz
Author-email: Jan Niklas Hasse <jhasse@bixense.com>
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE.txt
Requires-Dist: kdl-py
Requires-Dist: expandvars
Requires-Dist: termcolor
Requires-Dist: click
Dynamic: download-url
Dynamic: home-page
Dynamic: license-file

# lus

`lus` is a task runner similar to [just](https://just.systems). It's key differentiators are:

* No DSL, `lus` uses the existing [KDL](https://kdl.dev)
* Runs tasks directly without a shell
* Comes with a simple built-in shell, so it works out-of-the-box on Windows
* Less features

```kdl
b {
    - lus build
}

- host="$(uname -a)"

// build main
build {
    - cc *.a -o main
}

// test everything
test-all {
    - lus build
    - "./test" --all
}

// run a specific test
test {
    - lus build
    - "./test" --test $args
}
```

## Special environment variables

| Variable                   | Description                        |
|----------------------------|------------------------------------|
| `$args`                    | Additional arguments passed to lus |
| `$subcommand`              | Current subcommand being executed  |
| `$flags`                   | Arguments starting with `--`       |
| `$invocation_directory`    | Directory where `lus` was invoked  |

## Shell Completions

`lus` supports tab completion for bash, zsh, fish, and PowerShell. Add one of the following to your shell configuration:

**Bash** (`~/.bashrc`):
```bash
eval "$(lus --completions bash)"
```

**Zsh** (`~/.zshrc`):
```zsh
autoload -Uz compinit && compinit; source <(lus --completions zsh)
```

**Fish** (`~/.config/fish/config.fish`):
```fish
lus --completions fish | source
```

**PowerShell** (`$PROFILE`):
```powershell
Invoke-Expression (& lus --completions powershell)
```

# Development

Run unit and integration tests:

```
python -m venv .venv
. .venv/bin/activate.fish
pip install kdl-py expandvars pytest
pytest
```
