Skip to content

Commit

Permalink
Improve readme (#28)
Browse files Browse the repository at this point in the history
* better readme

* Update README.md
  • Loading branch information
lubomirkurcak authored May 20, 2024
1 parent d3d535f commit b565328
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 24 deletions.
1 change: 0 additions & 1 deletion .github/workflows/publish-to-snapcraft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ jobs:
- build-for: 'armhf'
- build-for: 'i386'
- build-for: 'riscv64'
- bulid-for: 'ppc64el'

runs-on: ubuntu-latest
outputs:
Expand Down
53 changes: 30 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,28 @@

### Installation

**[Download latest release](https://github.com/lubomirkurcak/tend/releases/latest)** if you are using **Windows**, **macOS** or **Linux**.
**[Download binaries](https://github.com/lubomirkurcak/tend/releases)** if you are using **Windows**, **macOS** or **Linux**.

You can install `tend` using `snap`:

```sh
sudo snap install tend
```

Or using `cargo`:

If you have `cargo` you can install `tend` with it:
```sh
cargo install tend
```

Or build from source, make sure you have [Rust](https://www.rust-lang.org/tools/install) installed:

```sh
git clone https://github.com/lubomirkurcak/tend
cd tend
cargo build --release
```

### Usage

#### Basic
Expand All @@ -34,40 +49,32 @@ List jobs:
tend list
```

```
+-------+---------+---------+-------------------+------------+---------+
| Job | Program | Args | Working Directory | Restart | Group |
+-------+---------+---------+-------------------+------------+---------+
| hello | ping | 8.8.8.8 | C:\repos\tend | on failure | default |
+-------+---------+---------+-------------------+------------+---------+
```

Reconfigure `hello` to always restart on completion (even successful):
```sh
tend create hello ping 8.8.8.8 --restart=always --overwrite
```

> [!NOTE]
> Based on your platform and configuration you will have access to different programs and shells. Make sure the programs are accessible from your current working directory.
>
> For example, you could write this on Linux:
> ```sh
> tend create time sh -- -c 'echo Time: $(date)'
> ```
> to achieve something similar as this on Windows:
> ```sh
> tend create time cmd -- /C 'echo Time: %TIME%'
> ```
#### Available Programs
Based on your platform and configuration you will have access to different programs and shells. Make sure the programs are accessible from your current working directory.

For example, you could write this on Linux:
```sh
tend create "time" sh -- -c 'echo Time: $(date)'
```
to achieve something similar as this on Windows:
```sh
tend create "time" cmd -- /C 'echo Time: %TIME%'
```

#### Groups

Create a job as a part of a group:
```sh
tend create dev-pg --group=dev kubectl port-forward svc/postgres 5432:5432
tend create "postgres" --group="dev" kubectl port-forward svc/postgres 5432:5432
```

Start all jobs from a specific group:
```sh
tend run --group dev
tend run --group "dev"
```

0 comments on commit b565328

Please sign in to comment.