Skip to content
This repository was archived by the owner on Jun 11, 2023. It is now read-only.
This repository was archived by the owner on Jun 11, 2023. It is now read-only.

Add custom command classes to generate processed output #5

@aydwi

Description

@aydwi

Instead of dumping a std::string of stream output to the client, Barrel can do some processing based on the exact brew command it executed and return, for example a neat std::unordered_map or other various (applicable) types.

This feature is not finalized because:

  1. It violates the "one job" philosophy.
  2. It comes with a subjective choice of C++ types and might force advanced clients to do ugly casting, which defeats the entire idea of doing it in the first place.
  3. It cannot be fool-proof or comprehensive. brew does dynamic things with certain commands which cannot all be encapsulated before execution (at least with any reasonable effort).
    Details
    Example

But it could still be useful for people who want a baked cake instead of the ingredients.

This feature will not be a part of the inital release, but will remain open for further thought till a decision is made.

Metadata

Metadata

Assignees

Projects

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions