I would like to programmatically run the operations in butane_cli . e.g. make_migration needs to be part of our build process, and ideally be run from within build.rs. This can be done using only butane, however there are a bunch of utilities and struct CliState which need to be duplicated to achieve this.
The simplest approach is to move these to a lib.rs within butane_cli , and document that anything pub in it is very volatile. That way these dont become part of the more stable butane API. We can also use some rustdoc specific attributes to hide them from the crate.io docs, to make it even less likely people will use them without being aware of the risks involved.
This will also make it easier to write tests for the cli.
I would like to programmatically run the operations in
butane_cli
. e.g.make_migration
needs to be part of our build process, and ideally be run from withinbuild.rs
. This can be done using onlybutane
, however there are a bunch of utilities andstruct CliState
which need to be duplicated to achieve this.The simplest approach is to move these to a
lib.rs
withinbutane_cli
, and document that anythingpub
in it is very volatile. That way these dont become part of the more stablebutane
API. We can also use some rustdoc specific attributes to hide them from the crate.io docs, to make it even less likely people will use them without being aware of the risks involved.This will also make it easier to write tests for the cli.