Implement shared-root publish execution
This commit is contained in:
@@ -50,10 +50,23 @@ func DisplayPath(path string) string {
|
||||
}
|
||||
|
||||
func ManagedBundleTargets(bundlePath string, managedOutputPaths []string) ([]string, error) {
|
||||
targets, err := ManagedOutputTargets(bundlePath, managedOutputPaths)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
statePath, err := StatePath(bundlePath)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
targets = append(targets, statePath)
|
||||
return targets, nil
|
||||
}
|
||||
|
||||
func ManagedOutputTargets(bundlePath string, managedOutputPaths []string) ([]string, error) {
|
||||
if err := ValidatePrefix(bundlePath); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
targets := make([]string, 0, len(managedOutputPaths)+1)
|
||||
targets := make([]string, 0, len(managedOutputPaths))
|
||||
for _, outputPath := range managedOutputPaths {
|
||||
target, err := Join(bundlePath, outputPath)
|
||||
if err != nil {
|
||||
@@ -61,11 +74,6 @@ func ManagedBundleTargets(bundlePath string, managedOutputPaths []string) ([]str
|
||||
}
|
||||
targets = append(targets, target)
|
||||
}
|
||||
statePath, err := StatePath(bundlePath)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
targets = append(targets, statePath)
|
||||
return targets, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user