Skip to content

Commit

Permalink
feat: 'append' and 'rebuild'
Browse files Browse the repository at this point in the history
  • Loading branch information
turadg committed Jan 8, 2024
1 parent fa4a917 commit 941e5cb
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions packages/synthetic-chain/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ const [cmd] = positionals;

// TODO consider a lib like Commander for auto-gen help
const usage = `USAGE:
amend [<tag>] - build on top of an existing image (defaults to latest from a3p)
append [<tag>] - build on top of an existing image (defaults to latest from a3p)
build - build from the beginning
rebuild - build from the beginning
test [--debug] - run the tests of the proposals
`;
Expand All @@ -48,12 +48,14 @@ const buildImages = () => {
};

switch (cmd) {
case 'amend':
case 'amend': // alias for backcompat
case 'append':
const fromTag = positionals[1] || baseImage;
writeDockerfile(allProposals, fromTag);
buildImages();
break;
case 'build':
case 'build': // alias for backcompat
case 'rebuild':
writeDockerfile(allProposals);
buildImages();
break;
Expand Down

0 comments on commit 941e5cb

Please sign in to comment.