diff --git a/CHANGELOG.md b/CHANGELOG.md index 403cc97..5d4c6db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,17 @@ ## Fixes and improvements - +# 4.0.1 +## Fixes and improvements +- `key` command column width fixed +- Show newly created API keys +- "smoke test" => "init run" in `envvar` command +- "Rapids" => "rapids" in `repo` command + +# 4.0.0 +## Breaking changes +- Reworked everything to fit with Merrymake 2.0 + # 3.4.0 ## Added features - Add timezone to `cron` diff --git a/dist/windows.zip b/dist/windows.zip index 150d237..399e959 100644 Binary files a/dist/windows.zip and b/dist/windows.zip differ diff --git a/newCommands/apikey.js b/newCommands/apikey.js index 3635510..2adb3a5 100644 --- a/newCommands/apikey.js +++ b/newCommands/apikey.js @@ -28,6 +28,7 @@ function do_key_create(organizationId, description, duration) { const reply = yield (0, utils_1.sshReq)(...cmd); if (reply.length !== 8) throw reply; + (0, prompt_1.output)(`Created apikey ${description !== "" ? `'${description}'` : ""}: ${prompt_1.YELLOW}${reply}${prompt_1.NORMAL_COLOR}\n`); const apikeyId = reply; return apikeyId; } @@ -111,7 +112,7 @@ function key(organizationId) { return { long: x.id, text: `${x.id} │ ${(0, executors_1.alignLeft)(n, Math.max(process_1.stdout.getWindowSize()[0] - - 36 - + 8 - 23 - "─┼──┼─".length - " ".length, 12))} │ ${ds}`, @@ -129,7 +130,7 @@ function key(organizationId) { tableHeader = "\n" + (0, executors_1.printTableHeader)(" ", { - Key: 36, + Key: 8, Description: -12, "Expiry time": 23, }); diff --git a/newCommands/apikey.ts b/newCommands/apikey.ts index 4220c80..b36c469 100644 --- a/newCommands/apikey.ts +++ b/newCommands/apikey.ts @@ -4,6 +4,7 @@ import { NORMAL_COLOR, Option, RED, + YELLOW, choice, output, shortText, @@ -26,6 +27,11 @@ export async function do_key_create( if (description !== "") cmd.push(`--description`, description); const reply = await sshReq(...cmd); if (reply.length !== 8) throw reply; + output( + `Created apikey ${ + description !== "" ? `'${description}'` : "" + }: ${YELLOW}${reply}${NORMAL_COLOR}\n` + ); const apikeyId = reply; return apikeyId; } catch (e) { @@ -128,7 +134,7 @@ export async function key(organizationId: OrganizationId) { n, Math.max( stdout.getWindowSize()[0] - - 36 - + 8 - 23 - "─┼──┼─".length - " ".length, @@ -152,7 +158,7 @@ export async function key(organizationId: OrganizationId) { tableHeader = "\n" + printTableHeader(" ", { - Key: 36, + Key: 8, Description: -12, "Expiry time": 23, }); diff --git a/newCommands/envvar.js b/newCommands/envvar.js index db08c36..1bac608 100644 --- a/newCommands/envvar.js +++ b/newCommands/envvar.js @@ -60,7 +60,7 @@ function envvar_key_visible_value(pathToOrganization, organizationId, serviceGro { long: "both", short: "b", - text: "accessible in both prod and smoke test", + text: "accessible in both prod and init run", action: () => envvar_key_value_access_visible(pathToOrganization, organizationId, serviceGroupId, key, value, ["--inProduction", "--inInitRun"], secret), }, { diff --git a/newCommands/envvar.ts b/newCommands/envvar.ts index 38cec65..ae43034 100644 --- a/newCommands/envvar.ts +++ b/newCommands/envvar.ts @@ -105,7 +105,7 @@ function envvar_key_visible_value( { long: "both", short: "b", - text: "accessible in both prod and smoke test", + text: "accessible in both prod and init run", action: () => envvar_key_value_access_visible( pathToOrganization, diff --git a/newCommands/repo.js b/newCommands/repo.js index e0f35aa..869b576 100644 --- a/newCommands/repo.js +++ b/newCommands/repo.js @@ -130,7 +130,7 @@ function after_service_deploy(pathToService, organizationId) { return (0, prompt_1.choice)("Would you like to post and event to the Rapids? (Trigger the service)", [ { long: "post", - text: "post an event to the Rapids", + text: "post an event to the rapids", action: () => (0, post_1.post)(organizationId), }, ], { disableAutoPick: true }); diff --git a/newCommands/repo.ts b/newCommands/repo.ts index 4670861..44cdf4d 100644 --- a/newCommands/repo.ts +++ b/newCommands/repo.ts @@ -183,7 +183,7 @@ async function after_service_deploy( [ { long: "post", - text: "post an event to the Rapids", + text: "post an event to the rapids", action: () => post(organizationId), }, ], diff --git a/package.json b/package.json index 5eddcdb..b7cd86e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@merrymake/cli", - "version": "4.0.0", + "version": "4.0.1", "description": "", "main": "index.js", "scripts": {