Skip to content
Snippets Groups Projects
Commit 38fe0ff4 authored by STEVAN Antoine's avatar STEVAN Antoine 🦀
Browse files

add `container list` for Docker containers (!207)

## examples
```bash
./make.rs container list --json
    | from ndjson
    | into datetime CreatedAt
    | into filesize Size VirtualSize
    | reject CreatedSince
```
or
```bash
./make.rs container list --json
    | from ndjson
    | into datetime CreatedAt
    | into filesize Size VirtualSize
    | reject CreatedSince
    | select ID Repository Tag CreatedAt VirtualSize
    | update Tag { str substring 0..<7 }
```

## changelog
- transform options of `container` to sub-subcommands
  - `container` --> `container build`
  - `container --login` --> `container login`
  - `container --push` --> `container push`
- add `container list` to print the local images for the GitLab and GitHub repositories
  - `container list` will print in a pretty table
  - `container list --json` will print as NDJSON, i.e. one image per line as JSON
- use wrappers around `nob::run_cmd_as_vec_and_fail!`
  - `extend_and_run` to run a partial command with an extra vector of args
  - `extend_and_run_and_capture_silent` to run a partial command with an extra vector of args and silently capture the stdout into a string
  - this allows to get rid of the `#[rustfmt::skip]` _directive_ on `main` and format the code not too aggressively
parent 34062030
No related branches found
No related tags found
Loading
Checking pipeline status
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment