@leverege/build-tools 2.93.3-beta.5 → 2.93.3-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -13,20 +13,20 @@ import { GenericArtifactPuller } from './ArtifactPuller.mjs'
|
|
|
13
13
|
program
|
|
14
14
|
.name( 'pull-artifact' )
|
|
15
15
|
.description( 'Pull artifacts from GCP Artifact Registry' )
|
|
16
|
-
.option( '-f, --file <path>', 'Path to artifacts.yaml file', './artifacts.yaml' )
|
|
17
|
-
.option( '-a, --artifact <artifact-path>', 'GCP artifact path' )
|
|
16
|
+
.option( '-f, --file-path <file-path>', 'Path to artifacts.yaml file', './artifacts.yaml' )
|
|
17
|
+
.option( '-a, --artifact-path <artifact-path>', 'GCP artifact path' )
|
|
18
18
|
.parse()
|
|
19
19
|
|
|
20
20
|
const options = program.opts()
|
|
21
21
|
|
|
22
22
|
async function main() {
|
|
23
|
-
const artifactsSchema = await getArtifactsSchema( options.
|
|
23
|
+
const artifactsSchema = await getArtifactsSchema( options.filePath )
|
|
24
24
|
const flattenedArtifactsSchema = flattenArtifactsSchema( artifactsSchema )
|
|
25
25
|
|
|
26
26
|
let filteredArtifactsSchema = flattenedArtifactsSchema
|
|
27
27
|
|
|
28
|
-
if ( options.
|
|
29
|
-
const artifactPathElements = options.
|
|
28
|
+
if ( options.artifactPath ) {
|
|
29
|
+
const artifactPathElements = options.artifactPath.split( '/' )
|
|
30
30
|
|
|
31
31
|
if ( artifactPathElements.length !== 5 ) {
|
|
32
32
|
warning( 'Invalid artifact path, it must be in the format <project>/<location>/<repository>/<package>/<version>' )
|
|
@@ -13,20 +13,20 @@ import { GenericArtifactPusher } from './ArtifactPusher.mjs'
|
|
|
13
13
|
program
|
|
14
14
|
.name( 'push-artifact' )
|
|
15
15
|
.description( 'Push artifacts to GCP Artifact Registry' )
|
|
16
|
-
.option( '-f, --file <path>', 'Path to artifacts.yaml file', './artifacts.yaml' )
|
|
17
|
-
.option( '-a, --artifact <artifact-path>', 'GCP artifact path' )
|
|
16
|
+
.option( '-f, --file-path <file-path>', 'Path to artifacts.yaml file', './artifacts.yaml' )
|
|
17
|
+
.option( '-a, --artifact-path <artifact-path>', 'GCP artifact path' )
|
|
18
18
|
.parse()
|
|
19
19
|
|
|
20
20
|
const options = program.opts()
|
|
21
21
|
|
|
22
22
|
async function main() {
|
|
23
|
-
const artifactsSchema = await getArtifactsSchema( options.
|
|
23
|
+
const artifactsSchema = await getArtifactsSchema( options.filePath )
|
|
24
24
|
const flattenedArtifactsSchema = flattenArtifactsSchema( artifactsSchema )
|
|
25
25
|
|
|
26
26
|
let filteredArtifactsSchema = flattenedArtifactsSchema
|
|
27
27
|
|
|
28
|
-
if ( options.
|
|
29
|
-
const artifactPathElements = options.
|
|
28
|
+
if ( options.artifactPath ) {
|
|
29
|
+
const artifactPathElements = options.artifactPath.split( '/' )
|
|
30
30
|
if ( artifactPathElements.length !== 5 ) {
|
|
31
31
|
warning( 'Invalid artifact path, it must be in the format <project>/<location>/<repository>/<package>/<version>' )
|
|
32
32
|
return false
|