Add support for provisioning and rebuilding via interface

This commit is contained in:
Tom 2023-07-09 11:18:14 +02:00
parent f5c5999f44
commit ddb4bb3546
76 changed files with 1306 additions and 625 deletions

View file

@ -0,0 +1,14 @@
package composer
import "strings"
// ModuleName extracts the module name from a specification.
// If the module name cannot be found, returns the string unchanged
func ModuleName(spec string) string {
_, name, found := strings.Cut(spec, "/")
if !found {
return spec
}
name, _, _ = strings.Cut(name, ":")
return name
}