From bc2ef2835fec7d4bb5bc7d443465ffe1676ca14f Mon Sep 17 00:00:00 2001 From: Zane Rockenbaugh Date: Sat, 30 Mar 2024 11:07:00 -0500 Subject: [PATCH 1/5] added support for '--no-reminders' option and used in README.md build --- README.md | 1 + make/55-readme-md.mk | 2 +- src/cli/cloudsite.mjs | 5 ++++- src/cli/constants.mjs | 6 ++++++ 4 files changed, 12 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 94e0ab0d..a1f65e91 100644 --- a/README.md +++ b/README.md @@ -287,6 +287,7 @@ cloudsite update your-domain.com |------|------| |``|(_main argument_,_optional_) The command to run or a sub-command group.| |`--format`|Sets the format for the output. May be 'terminal' (default), 'text', 'json', or 'yaml'.| +|`--no-reminders`, `-R`|Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.| |`--quiet`, `-q`|Makes informational output less chatty.| |`--sso-profile`|The AWS local SSO profile to use for authentication.| |`--throw-error`|In the case of an exception, the default is to print the message. When --throw-error is set, the exception is left uncaught.| diff --git a/make/55-readme-md.mk b/make/55-readme-md.mk index ddd8a34a..d9c8c2da 100644 --- a/make/55-readme-md.mk +++ b/make/55-readme-md.mk @@ -8,6 +8,6 @@ BUILD_TARGETS+=$(CLOUDSITE_README_BUILT) $(CLOUDSITE_README_BUILT): $(CLOUDSITE_README_PREFIX) $(CLOUDSITE_README_SUFFIX) $(CLOUDSITE_CLI_DEF) cp $(CLOUDSITE_README_PREFIX) $@ echo >> $@ - $(SDLC_CLOUDSITE_EXEC_JS) document >> $@ + $(SDLC_CLOUDSITE_EXEC_JS) --no-reminders document >> $@ cat $(CLOUDSITE_README_SUFFIX) >> $@ diff --git a/src/cli/cloudsite.mjs b/src/cli/cloudsite.mjs index 779fddcb..969a7327 100644 --- a/src/cli/cloudsite.mjs +++ b/src/cli/cloudsite.mjs @@ -26,6 +26,7 @@ const cloudsite = async () => { const argv = mainOptions._unknown || [] const { command/*, quiet */ } = mainOptions + const noReminders = mainOptions['no-reminders'] let db try { @@ -46,7 +47,9 @@ const cloudsite = async () => { configureLogger(globalOptions) - checkReminders({ reminders : db.reminders }) + if (noReminders !== true) { + checkReminders({ reminders : db.reminders }) + } const origDB = structuredClone(db) diff --git a/src/cli/constants.mjs b/src/cli/constants.mjs index 41fdeb32..e1e1cae1 100644 --- a/src/cli/constants.mjs +++ b/src/cli/constants.mjs @@ -11,6 +11,12 @@ const globalOptionsSpec = [ name : 'format', description : "Sets the format for the output. May be 'terminal' (default), 'text', 'json', or 'yaml'." }, + { + name: 'no-reminders', + alias: 'R', + type: Boolean, + description: 'Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.' + }, { name : 'quiet', alias : 'q', type : Boolean, description : 'Makes informational output less chatty.' }, { name : 'sso-profile', description : 'The AWS local SSO profile to use for authentication.' }, { From e3d2580e7c9e043b16c99ab621227c841ee489ad Mon Sep 17 00:00:00 2001 From: Zane Rockenbaugh Date: Sat, 30 Mar 2024 11:07:36 -0500 Subject: [PATCH 2/5] factored out errorOut; now all error reporting baised on thrown Errors and handled centrally --- src/cli/lib/check-format.mjs | 3 +-- src/cli/lib/error-out.mjs | 5 ----- src/cli/lib/get-site-info.mjs | 6 ++---- src/cli/lib/get-value-container-and-key.mjs | 4 +--- src/cli/lib/handle-detail.mjs | 3 +-- src/cli/lib/handle-import.mjs | 13 ++++++------- src/cli/lib/options.mjs | 5 ++--- .../plugin-settings/handle-plugin-settings-set.mjs | 9 ++++----- src/cli/lib/process-source-type.mjs | 3 +-- 9 files changed, 18 insertions(+), 33 deletions(-) delete mode 100644 src/cli/lib/error-out.mjs diff --git a/src/cli/lib/check-format.mjs b/src/cli/lib/check-format.mjs index 532e7394..f1f90a04 100644 --- a/src/cli/lib/check-format.mjs +++ b/src/cli/lib/check-format.mjs @@ -1,9 +1,8 @@ -import { errorOut } from './error-out' import { VALID_FORMATS } from '../constants' const checkFormat = (format) => { if (format !== undefined && !VALID_FORMATS.includes(format)) { - errorOut(`Invalid output format '${format}'. Must be one of: ${VALID_FORMATS.join(', ')}`) + throw new Error(`Invalid output format '${format}'. Must be one of: ${VALID_FORMATS.join(', ')}`) } } diff --git a/src/cli/lib/error-out.mjs b/src/cli/lib/error-out.mjs deleted file mode 100644 index 7d83c569..00000000 --- a/src/cli/lib/error-out.mjs +++ /dev/null @@ -1,5 +0,0 @@ -const errorOut = (msg, exitCode = 1) => { - throw new Error(msg, { exitCode }) -} - -export { errorOut } diff --git a/src/cli/lib/get-site-info.mjs b/src/cli/lib/get-site-info.mjs index 17364f10..86d73153 100644 --- a/src/cli/lib/get-site-info.mjs +++ b/src/cli/lib/get-site-info.mjs @@ -1,13 +1,11 @@ -import { errorOut } from './error-out' - const getSiteInfo = ({ apexDomain, db }) => { if (apexDomain === undefined) { - errorOut('Must specify site domain.\n') + throw new Error('Must specify site domain.') } const siteInfo = db.sites[apexDomain] if (siteInfo === undefined) { - errorOut(`No such site '${apexDomain}' found.\n`) + throw new Error(`No such site '${apexDomain}' found.`) } return siteInfo diff --git a/src/cli/lib/get-value-container-and-key.mjs b/src/cli/lib/get-value-container-and-key.mjs index 3a704b18..30976e1f 100644 --- a/src/cli/lib/get-value-container-and-key.mjs +++ b/src/cli/lib/get-value-container-and-key.mjs @@ -1,5 +1,3 @@ -import { errorOut } from './error-out' - const getValueContainerAndKey = ({ path, pathPrefix, rootContainer, skipValueCheck, spec, value }) => { const origPath = (pathPrefix === undefined ? '' : pathPrefix) + path.join('.') // used if validation error if (path === undefined || path.length === 0) { @@ -36,7 +34,7 @@ const getValueContainerAndKey = ({ path, pathPrefix, rootContainer, skipValueChe } else { const currSpec = spec?.[bit] if (currSpec === undefined && i > 0) { - errorOut(`Invalid option path '${origPath}'; no such element '${bit}'.\n`) + throw new Error(`Invalid option path '${origPath}'; no such element '${bit}'.\n`) } const container = currContainer[bit] if (container === undefined) { diff --git a/src/cli/lib/handle-detail.mjs b/src/cli/lib/handle-detail.mjs index 479937fb..323b4235 100644 --- a/src/cli/lib/handle-detail.mjs +++ b/src/cli/lib/handle-detail.mjs @@ -2,7 +2,6 @@ import commandLineArgs from 'command-line-args' import { checkFormat } from './check-format' import { cliSpec } from '../constants' -import { errorOut } from './error-out' import { getOptionsSpec } from './get-options-spec' import { getSiteInfo } from './get-site-info' @@ -13,7 +12,7 @@ const handleDetail = ({ argv, db }) => { const { format } = detailOptions if (apexDomain === undefined) { - errorOut('Apex domain must be specified.') + throw new Error('Apex domain must be specified.') } checkFormat(format) diff --git a/src/cli/lib/handle-import.mjs b/src/cli/lib/handle-import.mjs index 1a1c5465..9717ec23 100644 --- a/src/cli/lib/handle-import.mjs +++ b/src/cli/lib/handle-import.mjs @@ -4,7 +4,6 @@ import commandLineArgs from 'command-line-args' import { cliSpec } from '../constants' import { doImport } from '../../lib/actions/import' -import { errorOut } from './error-out' import { getOptionsSpec } from './get-options-spec' import { processSourceType } from './process-source-type' import { progressLogger } from '../../lib/shared/progress-logger' @@ -27,13 +26,13 @@ const handleImport = async ({ argv, db }) => { const sourceType = processSourceType({ sourcePath, sourceType : importOptions['source-type'] }) if (domainAndStack?.length !== 2) { - errorOut(`Unexpected number of positional arguments, expect 2 (domain and stack name), but got ${domainAndStack?.length || '0'}.\n`) + throw new Error(`Unexpected number of positional arguments, expect 2 (domain and stack name), but got ${domainAndStack?.length || '0'}.\n`) } if (region === undefined) { - errorOut("You must specify the '--region' parameter.\n") + throw new Error("You must specify the '--region' parameter.\n") } if (sourcePath === undefined) { - errorOut("You must specify the '--source-path' parameter.\n") + throw new Error("You must specify the '--source-path' parameter.\n") } let domain, stack @@ -48,13 +47,13 @@ const handleImport = async ({ argv, db }) => { const sitesInfo = db.sites if (sitesInfo[domain] !== undefined && refresh !== true) { - errorOut(`Domain '${domain}' is already in the sites DB. To update/refresh the values, use the '--refresh' option.`) + throw new Error(`Domain '${domain}' is already in the sites DB. To update/refresh the values, use the '--refresh' option.`) } if (domain === undefined) { - errorOut(`Could not determine domain name from arguments (${domainAndStack}).\n`) + throw new Error(`Could not determine domain name from arguments (${domainAndStack}).\n`) } if (stack === undefined) { - errorOut(`Could not determine stack name from arguments (${domainAndStack}).\n`) + throw new Error(`Could not determine stack name from arguments (${domainAndStack}).\n`) } // now, actually do the import diff --git a/src/cli/lib/options.mjs b/src/cli/lib/options.mjs index b9c9a7d8..a89d70d8 100644 --- a/src/cli/lib/options.mjs +++ b/src/cli/lib/options.mjs @@ -1,4 +1,3 @@ -import { errorOut } from './error-out' import { getValueContainerAndKey } from './get-value-container-and-key' import * as plugins from '../../lib/plugins' import { progressLogger } from '../../lib/shared/progress-logger' @@ -20,7 +19,7 @@ const updatePluginSettings = ({ confirmed, doDelete, options, siteInfo }) => { const plugin = plugins[pluginName] if (plugin === undefined) { - errorOut(`No such plugin '${pluginName}'; use one of: ${Object.keys(plugins).join(', ')}.\n`) + throw new Error(`No such plugin '${pluginName}'; use one of: ${Object.keys(plugins).join(', ')}.\n`) } if (siteInfo.plugins === undefined) { @@ -47,7 +46,7 @@ const updatePluginSettings = ({ confirmed, doDelete, options, siteInfo }) => { delete siteInfo.plugins[pluginName] progressLogger.write(`Deleted plugin settings for '${pluginName}'; was:\n${JSON.stringify(pluginSettings, null, ' ')}\n`) } else { - errorOut("Interactive confirmation not yet enabled. Use the '--confirmed' option. Note, this will delete all plugin settings and data and cannot be recovered. You must run 'cloudsite update' for this change to take effect. To re-enable the plugin, you must re-initialize all required settings and update the site.\n", 3) + throw new Error("Interactive confirmation not yet enabled. Use the '--confirmed' option. Note, this will delete all plugin settings and data and cannot be recovered. You must run 'cloudsite update' for this change to take effect. To re-enable the plugin, you must re-initialize all required settings and update the site.\n", 3) } } else if (doDelete === true) { const wasValue = valueContainer[valueKey] diff --git a/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs b/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs index 9cb0c3e5..4627ec02 100644 --- a/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs +++ b/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs @@ -1,7 +1,6 @@ import commandLineArgs from 'command-line-args' import { cliSpec } from '../../constants' -import { errorOut } from '../error-out' import { getOptionsSpec } from '../get-options-spec' import { getSiteInfo } from '../get-site-info' import * as optionsLib from '../options' @@ -23,17 +22,17 @@ const handlePluginSettingsSet = async ({ argv, db }) => { const siteInfo = getSiteInfo({ apexDomain, db }) if (doDelete === true && name === undefined && options.length === 0) { - errorOut("You must specify a '--name' or at least one '--option' when '--delete' is set.\n") + throw new Error("You must specify a '--name' or at least one '--option' when '--delete' is set.\n") } else if (name !== undefined && (value !== undefined || doDelete === true)) { options.push({ name, value : smartConvert(value) }) // the 'option' values are already converted } else if (name !== undefined && value === undefined) { // but delete is not set (checked above) - errorOut("You must specify a '--value' or '--delete' when '--name' is set.\n") + throw new Error("You must specify a '--value' or '--delete' when '--name' is set.\n") } else if (name === undefined && value !== undefined) { - errorOut("You must specify a '--name' when '--value' is set.\n") + throw new Error("You must specify a '--name' when '--value' is set.\n") } if (doDelete !== true && options.length === 0) { - errorOut("Invalid options; specify '--name'+'--value', '--delete'/'--name', or one or more '--option' options.\n") + throw new Error("Invalid options; specify '--name'+'--value', '--delete'/'--name', or one or more '--option' options.\n") } // take actions and update the options diff --git a/src/cli/lib/process-source-type.mjs b/src/cli/lib/process-source-type.mjs index 0c62c99d..46dd1d7a 100644 --- a/src/cli/lib/process-source-type.mjs +++ b/src/cli/lib/process-source-type.mjs @@ -2,14 +2,13 @@ import { existsSync as fileExists } from 'node:fs' import { resolve as resolvePath } from 'node:path' import { SOURCE_TYPES } from '../constants' -import { errorOut } from './error-out' const processSourceType = ({ sourcePath, sourceType }) => { if (sourceType === undefined) { const docusaurusConfigPath = resolvePath(sourcePath, '..', 'docusaurus.config.js') sourceType = fileExists(docusaurusConfigPath) ? 'docusaurus' : 'vanilla' } else if (!SOURCE_TYPES.includes(sourceType)) { - errorOut(`Invalid site source type '${sourceType}'; must be one of ${SOURCE_TYPES.join(', ')}.\n`, 2) + throw new Error(`Invalid site source type '${sourceType}'; must be one of ${SOURCE_TYPES.join(', ')}.\n`, 2) } return sourceType From 4266ec27590971750fc7c20d640f8903c3863485 Mon Sep 17 00:00:00 2001 From: Zane Rockenbaugh Date: Sat, 30 Mar 2024 11:08:02 -0500 Subject: [PATCH 3/5] lint formatting --- src/cli/constants.mjs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/cli/constants.mjs b/src/cli/constants.mjs index e1e1cae1..8f07e980 100644 --- a/src/cli/constants.mjs +++ b/src/cli/constants.mjs @@ -11,11 +11,11 @@ const globalOptionsSpec = [ name : 'format', description : "Sets the format for the output. May be 'terminal' (default), 'text', 'json', or 'yaml'." }, - { - name: 'no-reminders', - alias: 'R', - type: Boolean, - description: 'Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.' + { + name : 'no-reminders', + alias : 'R', + type : Boolean, + description : 'Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.' }, { name : 'quiet', alias : 'q', type : Boolean, description : 'Makes informational output less chatty.' }, { name : 'sso-profile', description : 'The AWS local SSO profile to use for authentication.' }, From 45df44a0cf94cc72addca238583d7b5b7dc20f36 Mon Sep 17 00:00:00 2001 From: Zane Rockenbaugh Date: Sat, 30 Mar 2024 11:08:50 -0500 Subject: [PATCH 4/5] Save QA files. --- qa/coverage/base.css | 224 +++ qa/coverage/block-navigation.js | 87 + qa/coverage/cli/cloudsite.mjs.html | 547 ++++++ qa/coverage/cli/constants.mjs.html | 1129 ++++++++++++ qa/coverage/cli/index.html | 131 ++ .../cli/lib/check-authentication.mjs.html | 124 ++ qa/coverage/cli/lib/check-format.mjs.html | 112 ++ qa/coverage/cli/lib/check-reminders.mjs.html | 154 ++ .../handle-configuration-initialize.mjs.html | 193 ++ .../handle-configuration-show.mjs.html | 145 ++ qa/coverage/cli/lib/configuration/index.html | 131 ++ .../cli/lib/get-global-options.mjs.html | 187 ++ qa/coverage/cli/lib/get-options-spec.mjs.html | 130 ++ qa/coverage/cli/lib/get-site-info.mjs.html | 127 ++ .../lib/get-value-container-and-key.mjs.html | 229 +++ qa/coverage/cli/lib/handle-cleanup.mjs.html | 235 +++ .../cli/lib/handle-configuration.mjs.html | 157 ++ qa/coverage/cli/lib/handle-create.mjs.html | 475 +++++ qa/coverage/cli/lib/handle-destroy.mjs.html | 256 +++ qa/coverage/cli/lib/handle-detail.mjs.html | 160 ++ .../cli/lib/handle-get-iam-policy.mjs.html | 847 +++++++++ qa/coverage/cli/lib/handle-import.mjs.html | 286 +++ qa/coverage/cli/lib/handle-list.mjs.html | 157 ++ .../cli/lib/handle-plugin-settings.mjs.html | 157 ++ qa/coverage/cli/lib/handle-update.mjs.html | 163 ++ qa/coverage/cli/lib/handle-verify.mjs.html | 184 ++ qa/coverage/cli/lib/index.html | 416 +++++ qa/coverage/cli/lib/options.mjs.html | 292 +++ .../handle-plugin-settings-set.mjs.html | 226 +++ .../handle-plugin-settings-show.mjs.html | 145 ++ .../cli/lib/plugin-settings/index.html | 131 ++ .../cli/lib/process-source-type.mjs.html | 136 ++ qa/coverage/cli/lib/smart-convert.mjs.html | 151 ++ qa/coverage/clover.xml | 1635 +++++++++++++++++ qa/coverage/coverage-final.json | 62 + qa/coverage/favicon.png | Bin 0 -> 445 bytes qa/coverage/index.html | 236 +++ qa/coverage/lib/actions/create.mjs.html | 547 ++++++ qa/coverage/lib/actions/destroy.mjs.html | 274 +++ qa/coverage/lib/actions/import.mjs.html | 304 +++ qa/coverage/lib/actions/index.html | 176 ++ .../lib/add-tags-to-hosted-zone.mjs.html | 145 ++ .../associate-cost-allocation-tags.mjs.html | 142 ++ .../lib/create-or-update-dns-records.mjs.html | 214 +++ .../lib/actions/lib/find-certificate.mjs.html | 172 ++ .../lib/actions/lib/get-credentials.mjs.html | 118 ++ .../actions/lib/get-hosted-zone-id.mjs.html | 148 ++ qa/coverage/lib/actions/lib/index.html | 266 +++ .../actions/lib/sync-site-content.mjs.html | 193 ++ .../actions/lib/track-stack-status.mjs.html | 214 +++ .../lib/actions/lib/update-plugins.mjs.html | 145 ++ .../lib/actions/lib/update-site-info.mjs.html | 136 ++ .../lib/actions/lib/update-stack.mjs.html | 283 +++ qa/coverage/lib/actions/update.mjs.html | 361 ++++ qa/coverage/lib/actions/verify.mjs.html | 631 +++++++ qa/coverage/lib/plugins/access-logs.mjs.html | 124 ++ .../lib/plugins/cloudfront-logs.mjs.html | 211 +++ .../contact-handler/lib/constants.mjs.html | 175 ++ .../determine-lambda-function-name.mjs.html | 187 ++ .../plugins/contact-handler/lib/index.html | 221 +++ .../lib/setup-contact-emailer.mjs.html | 544 ++++++ .../lib/setup-contact-form-table.mjs.html | 178 ++ .../lib/setup-contact-handler.mjs.html | 613 ++++++ .../lib/setup-request-signer.mjs.html | 403 ++++ .../stage-lambda-function-zip-files.mjs.html | 361 ++++ .../update-cloud-front-distribution.mjs.html | 220 +++ qa/coverage/lib/plugins/index.html | 131 ++ .../convert-domain-to-bucket-name.js.html | 94 + .../lib/shared/determine-bucket-name.mjs.html | 241 +++ .../lib/shared/determine-oac-name.mjs.html | 235 +++ .../lib/shared/find-bucket-like.mjs.html | 166 ++ .../lib/shared/get-account-id.mjs.html | 124 ++ qa/coverage/lib/shared/get-site-tag.mjs.html | 100 + qa/coverage/lib/shared/index.html | 221 +++ .../lib/shared/progress-logger.mjs.html | 139 ++ qa/coverage/lib/shared/site-template.mjs.html | 892 +++++++++ qa/coverage/prettify.css | 1 + qa/coverage/prettify.js | 2 + qa/coverage/sort-arrow-sprite.png | Bin 0 -> 138 bytes qa/coverage/sorter.js | 196 ++ qa/lint.txt | 1 + qa/unit-test.txt | 84 + 82 files changed, 20490 insertions(+) create mode 100644 qa/coverage/base.css create mode 100644 qa/coverage/block-navigation.js create mode 100644 qa/coverage/cli/cloudsite.mjs.html create mode 100644 qa/coverage/cli/constants.mjs.html create mode 100644 qa/coverage/cli/index.html create mode 100644 qa/coverage/cli/lib/check-authentication.mjs.html create mode 100644 qa/coverage/cli/lib/check-format.mjs.html create mode 100644 qa/coverage/cli/lib/check-reminders.mjs.html create mode 100644 qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html create mode 100644 qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html create mode 100644 qa/coverage/cli/lib/configuration/index.html create mode 100644 qa/coverage/cli/lib/get-global-options.mjs.html create mode 100644 qa/coverage/cli/lib/get-options-spec.mjs.html create mode 100644 qa/coverage/cli/lib/get-site-info.mjs.html create mode 100644 qa/coverage/cli/lib/get-value-container-and-key.mjs.html create mode 100644 qa/coverage/cli/lib/handle-cleanup.mjs.html create mode 100644 qa/coverage/cli/lib/handle-configuration.mjs.html create mode 100644 qa/coverage/cli/lib/handle-create.mjs.html create mode 100644 qa/coverage/cli/lib/handle-destroy.mjs.html create mode 100644 qa/coverage/cli/lib/handle-detail.mjs.html create mode 100644 qa/coverage/cli/lib/handle-get-iam-policy.mjs.html create mode 100644 qa/coverage/cli/lib/handle-import.mjs.html create mode 100644 qa/coverage/cli/lib/handle-list.mjs.html create mode 100644 qa/coverage/cli/lib/handle-plugin-settings.mjs.html create mode 100644 qa/coverage/cli/lib/handle-update.mjs.html create mode 100644 qa/coverage/cli/lib/handle-verify.mjs.html create mode 100644 qa/coverage/cli/lib/index.html create mode 100644 qa/coverage/cli/lib/options.mjs.html create mode 100644 qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html create mode 100644 qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html create mode 100644 qa/coverage/cli/lib/plugin-settings/index.html create mode 100644 qa/coverage/cli/lib/process-source-type.mjs.html create mode 100644 qa/coverage/cli/lib/smart-convert.mjs.html create mode 100644 qa/coverage/clover.xml create mode 100644 qa/coverage/coverage-final.json create mode 100644 qa/coverage/favicon.png create mode 100644 qa/coverage/index.html create mode 100644 qa/coverage/lib/actions/create.mjs.html create mode 100644 qa/coverage/lib/actions/destroy.mjs.html create mode 100644 qa/coverage/lib/actions/import.mjs.html create mode 100644 qa/coverage/lib/actions/index.html create mode 100644 qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html create mode 100644 qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html create mode 100644 qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html create mode 100644 qa/coverage/lib/actions/lib/find-certificate.mjs.html create mode 100644 qa/coverage/lib/actions/lib/get-credentials.mjs.html create mode 100644 qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html create mode 100644 qa/coverage/lib/actions/lib/index.html create mode 100644 qa/coverage/lib/actions/lib/sync-site-content.mjs.html create mode 100644 qa/coverage/lib/actions/lib/track-stack-status.mjs.html create mode 100644 qa/coverage/lib/actions/lib/update-plugins.mjs.html create mode 100644 qa/coverage/lib/actions/lib/update-site-info.mjs.html create mode 100644 qa/coverage/lib/actions/lib/update-stack.mjs.html create mode 100644 qa/coverage/lib/actions/update.mjs.html create mode 100644 qa/coverage/lib/actions/verify.mjs.html create mode 100644 qa/coverage/lib/plugins/access-logs.mjs.html create mode 100644 qa/coverage/lib/plugins/cloudfront-logs.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/index.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html create mode 100644 qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html create mode 100644 qa/coverage/lib/plugins/index.html create mode 100644 qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html create mode 100644 qa/coverage/lib/shared/determine-bucket-name.mjs.html create mode 100644 qa/coverage/lib/shared/determine-oac-name.mjs.html create mode 100644 qa/coverage/lib/shared/find-bucket-like.mjs.html create mode 100644 qa/coverage/lib/shared/get-account-id.mjs.html create mode 100644 qa/coverage/lib/shared/get-site-tag.mjs.html create mode 100644 qa/coverage/lib/shared/index.html create mode 100644 qa/coverage/lib/shared/progress-logger.mjs.html create mode 100644 qa/coverage/lib/shared/site-template.mjs.html create mode 100644 qa/coverage/prettify.css create mode 100644 qa/coverage/prettify.js create mode 100644 qa/coverage/sort-arrow-sprite.png create mode 100644 qa/coverage/sorter.js create mode 100644 qa/lint.txt create mode 100644 qa/unit-test.txt diff --git a/qa/coverage/base.css b/qa/coverage/base.css new file mode 100644 index 00000000..f418035b --- /dev/null +++ b/qa/coverage/base.css @@ -0,0 +1,224 @@ +body, html { + margin:0; padding: 0; + height: 100%; +} +body { + font-family: Helvetica Neue, Helvetica, Arial; + font-size: 14px; + color:#333; +} +.small { font-size: 12px; } +*, *:after, *:before { + -webkit-box-sizing:border-box; + -moz-box-sizing:border-box; + box-sizing:border-box; + } +h1 { font-size: 20px; margin: 0;} +h2 { font-size: 14px; } +pre { + font: 12px/1.4 Consolas, "Liberation Mono", Menlo, Courier, monospace; + margin: 0; + padding: 0; + -moz-tab-size: 2; + -o-tab-size: 2; + tab-size: 2; +} +a { color:#0074D9; text-decoration:none; } +a:hover { text-decoration:underline; } +.strong { font-weight: bold; } +.space-top1 { padding: 10px 0 0 0; } +.pad2y { padding: 20px 0; } +.pad1y { padding: 10px 0; } +.pad2x { padding: 0 20px; } +.pad2 { padding: 20px; } +.pad1 { padding: 10px; } +.space-left2 { padding-left:55px; } +.space-right2 { padding-right:20px; } +.center { text-align:center; } +.clearfix { display:block; } +.clearfix:after { + content:''; + display:block; + height:0; + clear:both; + visibility:hidden; + } +.fl { float: left; } +@media only screen and (max-width:640px) { + .col3 { width:100%; max-width:100%; } + .hide-mobile { display:none!important; } +} + +.quiet { + color: #7f7f7f; + color: rgba(0,0,0,0.5); +} +.quiet a { opacity: 0.7; } + +.fraction { + font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; + font-size: 10px; + color: #555; + background: #E8E8E8; + padding: 4px 5px; + border-radius: 3px; + vertical-align: middle; +} + +div.path a:link, div.path a:visited { color: #333; } +table.coverage { + border-collapse: collapse; + margin: 10px 0 0 0; + padding: 0; +} + +table.coverage td { + margin: 0; + padding: 0; + vertical-align: top; +} +table.coverage td.line-count { + text-align: right; + padding: 0 5px 0 20px; +} +table.coverage td.line-coverage { + text-align: right; + padding-right: 10px; + min-width:20px; +} + +table.coverage td span.cline-any { + display: inline-block; + padding: 0 5px; + width: 100%; +} +.missing-if-branch { + display: inline-block; + margin-right: 5px; + border-radius: 3px; + position: relative; + padding: 0 4px; + background: #333; + color: yellow; +} + +.skip-if-branch { + display: none; + margin-right: 10px; + position: relative; + padding: 0 4px; + background: #ccc; + color: white; +} +.missing-if-branch .typ, .skip-if-branch .typ { + color: inherit !important; +} +.coverage-summary { + border-collapse: collapse; + width: 100%; +} +.coverage-summary tr { border-bottom: 1px solid #bbb; } +.keyline-all { border: 1px solid #ddd; } +.coverage-summary td, .coverage-summary th { padding: 10px; } +.coverage-summary tbody { border: 1px solid #bbb; } +.coverage-summary td { border-right: 1px solid #bbb; } +.coverage-summary td:last-child { border-right: none; } +.coverage-summary th { + text-align: left; + font-weight: normal; + white-space: nowrap; +} +.coverage-summary th.file { border-right: none !important; } +.coverage-summary th.pct { } +.coverage-summary th.pic, +.coverage-summary th.abs, +.coverage-summary td.pct, +.coverage-summary td.abs { text-align: right; } +.coverage-summary td.file { white-space: nowrap; } +.coverage-summary td.pic { min-width: 120px !important; } +.coverage-summary tfoot td { } + +.coverage-summary .sorter { + height: 10px; + width: 7px; + display: inline-block; + margin-left: 0.5em; + background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent; +} +.coverage-summary .sorted .sorter { + background-position: 0 -20px; +} +.coverage-summary .sorted-desc .sorter { + background-position: 0 -10px; +} +.status-line { height: 10px; } +/* yellow */ +.cbranch-no { background: yellow !important; color: #111; } +/* dark red */ +.red.solid, .status-line.low, .low .cover-fill { background:#C21F39 } +.low .chart { border:1px solid #C21F39 } +.highlighted, +.highlighted .cstat-no, .highlighted .fstat-no, .highlighted .cbranch-no{ + background: #C21F39 !important; +} +/* medium red */ +.cstat-no, .fstat-no, .cbranch-no, .cbranch-no { background:#F6C6CE } +/* light red */ +.low, .cline-no { background:#FCE1E5 } +/* light green */ +.high, .cline-yes { background:rgb(230,245,208) } +/* medium green */ +.cstat-yes { background:rgb(161,215,106) } +/* dark green */ +.status-line.high, .high .cover-fill { background:rgb(77,146,33) } +.high .chart { border:1px solid rgb(77,146,33) } +/* dark yellow (gold) */ +.status-line.medium, .medium .cover-fill { background: #f9cd0b; } +.medium .chart { border:1px solid #f9cd0b; } +/* light yellow */ +.medium { background: #fff4c2; } + +.cstat-skip { background: #ddd; color: #111; } +.fstat-skip { background: #ddd; color: #111 !important; } +.cbranch-skip { background: #ddd !important; color: #111; } + +span.cline-neutral { background: #eaeaea; } + +.coverage-summary td.empty { + opacity: .5; + padding-top: 4px; + padding-bottom: 4px; + line-height: 1; + color: #888; +} + +.cover-fill, .cover-empty { + display:inline-block; + height: 12px; +} +.chart { + line-height: 0; +} +.cover-empty { + background: white; +} +.cover-full { + border-right: none !important; +} +pre.prettyprint { + border: none !important; + padding: 0 !important; + margin: 0 !important; +} +.com { color: #999 !important; } +.ignore-none { color: #999; font-weight: normal; } + +.wrapper { + min-height: 100%; + height: auto !important; + height: 100%; + margin: 0 auto -48px; +} +.footer, .push { + height: 48px; +} diff --git a/qa/coverage/block-navigation.js b/qa/coverage/block-navigation.js new file mode 100644 index 00000000..cc121302 --- /dev/null +++ b/qa/coverage/block-navigation.js @@ -0,0 +1,87 @@ +/* eslint-disable */ +var jumpToCode = (function init() { + // Classes of code we would like to highlight in the file view + var missingCoverageClasses = ['.cbranch-no', '.cstat-no', '.fstat-no']; + + // Elements to highlight in the file listing view + var fileListingElements = ['td.pct.low']; + + // We don't want to select elements that are direct descendants of another match + var notSelector = ':not(' + missingCoverageClasses.join('):not(') + ') > '; // becomes `:not(a):not(b) > ` + + // Selecter that finds elements on the page to which we can jump + var selector = + fileListingElements.join(', ') + + ', ' + + notSelector + + missingCoverageClasses.join(', ' + notSelector); // becomes `:not(a):not(b) > a, :not(a):not(b) > b` + + // The NodeList of matching elements + var missingCoverageElements = document.querySelectorAll(selector); + + var currentIndex; + + function toggleClass(index) { + missingCoverageElements + .item(currentIndex) + .classList.remove('highlighted'); + missingCoverageElements.item(index).classList.add('highlighted'); + } + + function makeCurrent(index) { + toggleClass(index); + currentIndex = index; + missingCoverageElements.item(index).scrollIntoView({ + behavior: 'smooth', + block: 'center', + inline: 'center' + }); + } + + function goToPrevious() { + var nextIndex = 0; + if (typeof currentIndex !== 'number' || currentIndex === 0) { + nextIndex = missingCoverageElements.length - 1; + } else if (missingCoverageElements.length > 1) { + nextIndex = currentIndex - 1; + } + + makeCurrent(nextIndex); + } + + function goToNext() { + var nextIndex = 0; + + if ( + typeof currentIndex === 'number' && + currentIndex < missingCoverageElements.length - 1 + ) { + nextIndex = currentIndex + 1; + } + + makeCurrent(nextIndex); + } + + return function jump(event) { + if ( + document.getElementById('fileSearch') === document.activeElement && + document.activeElement != null + ) { + // if we're currently focused on the search input, we don't want to navigate + return; + } + + switch (event.which) { + case 78: // n + case 74: // j + goToNext(); + break; + case 66: // b + case 75: // k + case 80: // p + goToPrevious(); + break; + } + }; +})(); +window.addEventListener('keydown', jumpToCode); diff --git a/qa/coverage/cli/cloudsite.mjs.html b/qa/coverage/cli/cloudsite.mjs.html new file mode 100644 index 00000000..26a6f527 --- /dev/null +++ b/qa/coverage/cli/cloudsite.mjs.html @@ -0,0 +1,547 @@ + + + + + + Code coverage report for cli/cloudsite.mjs + + + + + + + + + +
+
+

All files / cli cloudsite.mjs

+
+ +
+ 0% + Statements + 0/102 +
+ + +
+ 0% + Branches + 0/47 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/91 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as fs from 'node:fs/promises'
+ 
+import commandLineArgs from 'command-line-args'
+import { commandLineDocumentation } from 'command-line-documentation'
+import isEqual from 'lodash/isEqual'
+ 
+import { cliSpec, DB_PATH } from './constants'
+import { checkReminders } from './lib/check-reminders'
+import { configureLogger, progressLogger } from '../lib/shared/progress-logger'
+import { getGlobalOptions } from './lib/get-global-options'
+import { handleCleanup } from './lib/handle-cleanup'
+import { handleConfiguration } from './lib/handle-configuration'
+import { handleCreate } from './lib/handle-create'
+import { handleDestroy } from './lib/handle-destroy'
+import { handleDetail } from './lib/handle-detail'
+import { handleGetIAMPolicy } from './lib/handle-get-iam-policy'
+import { handleList } from './lib/handle-list'
+import { handleImport } from './lib/handle-import'
+import { handlePluginSettings } from './lib/handle-plugin-settings'
+import { handleUpdate } from './lib/handle-update'
+import { handleVerify } from './lib/handle-verify'I
+ 
+const cloudsite = async () => {
+  // we can 'stopAtFirstUnknown' because the globals are defined at the root level
+  const mainOptions = commandLineArgs(cliSpec.mainOptions, { stopAtFirstUnknown : true })
+  const argv = mainOptions._unknown || []
+ 
+  const { command/*, quiet */ } = mainOptions
+  const noReminders = mainOptions['no-reminders']
+ 
+  let db
+  try {
+    const dbContents = await fs.readFile(DB_PATH, { encoding : 'utf8' })
+    db = JSON.parse(dbContents)
+  } catch (e) {
+    Iif (e.code !== 'ENOENT') {
+      throw e
+    }
+    // otherwise, it's fine, there just are no options
+    db = { account : { settings : {} }, sites : {}, toCleanup : {}, reminders : [] }
+  }
+ 
+  const globalOptions = getGlobalOptions({ db })
+  const { format } = globalOptions
+  const ssoProfile = globalOptions['sso-profile']
+  const throwError = globalOptions['throw-error']
+ 
+  configureLogger(globalOptions)
+ 
+  Iif (noReminders !== true) {
+    checkReminders({ reminders : db.reminders })
+  }
+ 
+  const origDB = structuredClone(db)
+ 
+  let data
+  let exitCode = 0
+  let userMessage
+  let success
+  try {
+    switch (command) {
+      case 'cleanup':
+        ({ success, userMessage } = await handleCleanup({ argv, db })); break
+      case 'configuration':
+        ({ data, success, userMessage } = await handleConfiguration({ argv, db })); break
+      case 'create':
+        ({ success, userMessage } = await handleCreate({ argv, db })); break
+      case 'destroy':
+        ({ success, userMessage } = await handleDestroy({ argv, db })); break
+      case 'detail':
+        ({ data, success } = await handleDetail({ argv, db })); break
+      case 'document':
+        console.log(commandLineDocumentation(cliSpec, { sectionDepth : 2, title : 'Command reference' }))
+        success = true
+        userMessage = 'Documentation generated.'
+        break
+      case 'get-iam-policy':
+        await handleGetIAMPolicy({ argv, db })
+        return // get-iam-policy is handles it's own output as the IAM policy is always in JSON format
+      case 'list':
+        ({ data, success } = await handleList({ argv, db })); break
+      case 'import':
+        ({ success, userMessage } = await handleImport({ argv, db })); break
+      case 'plugin-settings':
+        ({ data, success, userMessage } = await handlePluginSettings({ argv, db })); break
+      case 'update':
+        ({ success, userMessage } = await handleUpdate({ argv, db })); break
+      case 'verify':
+        ({ data } = await handleVerify({ argv, db })); break
+      default:
+        process.stderr.write('Uknown command: ' + command + '\n\n')
+        exitCode = 10
+      // TODO: handleHelp() (abstriact from cloudcraft)
+    }
+  } catch (e) {
+    if (throwError === true) {
+      throw e
+    } else if (e.name === 'CredentialsProviderError') {
+      userMessage = 'Your AWS login credentials may have expired. Update your credentials or try refreshing with:\n\naws sso login'
+      Iif (ssoProfile !== undefined) {
+        userMessage += ' --profile ' + ssoProfile
+      }
+      exitCode = 2
+    } else {
+      userMessage = e.message
+      exitCode = e.exitCode || 11
+    }
+  } finally {
+    await checkAndUpdateSitesInfo({ origDB, db })
+  }
+ 
+  globalOptions.quiet = false // always send the final status message
+ 
+  const actionStatus = {
+    success : exitCode === 0 && success === true,
+    status  : exitCode !== 0 ? 'ERROR' : (success === true ? 'SUCCESS' : 'FAILURE'),
+    userMessage
+  }
+ 
+  Iif (data !== undefined) {
+    actionStatus.data = data
+  }
+ 
+  // is it a data format
+  if (format === 'json' || format === 'yaml') {
+    progressLogger.write(actionStatus, '')
+  } else { // then it's a 'human' format
+    Iif (data !== undefined) {
+      progressLogger.write(data, '')
+    }
+ 
+    Iif (userMessage !== undefined) {
+      const { status, userMessage } = actionStatus
+      let message = userMessage
+      if (status === 'ERROR') {
+        message = '<error>!! ERROR !!<rst>: ' + message
+      } else Iif (status === 'FAILURE') {
+        message = '<warn>Command FAILED: <rst>' + message
+      }
+      progressLogger.write(message + '\n')
+    }
+  }
+ 
+  process.exit(exitCode) // eslint-disable-line no-process-exit
+}
+ 
+const checkAndUpdateSitesInfo = async ({ origDB, db }) => {
+  Iif (!isEqual(origDB, db)) {
+    const dbContents = JSON.stringify(db, null, '  ')
+    await fs.writeFile(DB_PATH, dbContents, { encoding : 'utf8' })
+  }
+}
+ 
+export { cloudsite }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/constants.mjs.html b/qa/coverage/cli/constants.mjs.html new file mode 100644 index 00000000..f7b3172d --- /dev/null +++ b/qa/coverage/cli/constants.mjs.html @@ -0,0 +1,1129 @@ + + + + + + Code coverage report for cli/constants.mjs + + + + + + + + + +
+
+

All files / cli constants.mjs

+
+ +
+ 0% + Statements + 0/9 +
+ + +
+ 0% + Branches + 0/6 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/8 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270 +271 +272 +273 +274 +275 +276 +277 +278 +279 +280 +281 +282 +283 +284 +285 +286 +287 +288 +289 +290 +291 +292 +293 +294 +295 +296 +297 +298 +299 +300 +301 +302 +303 +304 +305 +306 +307 +308 +309 +310 +311 +312 +313 +314 +315 +316 +317 +318 +319 +320 +321 +322 +323 +324 +325 +326 +327 +328 +329 +330 +331 +332 +333 +334 +335 +336 +337 +338 +339 +340 +341 +342 +343 +344 +345 +346 +347 +348 +349  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as fsPath from 'node:path'I
+ 
+const SOURCE_TYPES = ['docusaurus', 'vanilla']
+ 
+const VALID_FORMATS = ['json', 'terminal', 'text', 'yaml']
+ 
+const DB_PATH = fsPath.join(process.env.HOME, '.config', 'cloudsite', 'cloudsite-db.json')
+ 
+const globalOptionsSpec = [
+  {
+    name        : 'format',
+    description : "Sets the format for the output. May be 'terminal' (default), 'text', 'json', or 'yaml'."
+  },
+  {
+    name        : 'no-reminders',
+    alias       : 'R',
+    type        : Boolean,
+    description : 'Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.'
+  },
+  { name : 'quiet', alias : 'q', type : Boolean, description : 'Makes informational output less chatty.' },
+  { name : 'sso-profile', description : 'The AWS local SSO profile to use for authentication.' },
+  {
+    name        : 'throw-error',
+    type        : Boolean,
+    description : 'In the case of an exception, the default is to print the message. When --throw-error is set, the exception is left uncaught.'
+  },
+  {
+    name        : 'verbose',
+    type        : Boolean,
+    description : 'Activates verbose (non-quiet mode) even in situations where quiet would normally be implied.'
+  }
+]
+ 
+const optionSpec = {
+  name        : 'option',
+  description : "A combined name-value pair: <name>:<value>. Can be used multiple times. With '--delete', the value portion is ignored and can be omitted, e.g.: '--option <name>'.",
+  multiple    : true
+}
+ 
+const sourceTypeArgSpec = {
+  name        : 'source-type',
+  description : "May be either 'vanilla' or 'docusaurus', otherwise process will attempt to guess."
+}
+ 
+const cliSpec = {
+  mainCommand : 'cloudsite',
+  mainOptions : [
+    { name : 'command', defaultOption : true, description : 'The command to run or a sub-command group.' },
+    ...globalOptionsSpec
+  ],
+  commands : [
+    {
+      name        : 'cleanup',
+      description : "Attempts to fully delete partially deleted sites in the 'needs to be cleaned up' state.",
+      arguments   : [
+        {
+          name          : 'apex-domain',
+          defaultOption : true,
+          description   : 'Specifies the site to clean up rather than trying to cleanup all pending sites.'
+        },
+        {
+          name        : 'list',
+          description : 'Lists the sites in need of cleaning up.',
+          type        : Boolean
+        }
+      ]
+    },
+    {
+      name        : 'configuration',
+      description : 'Command group for managing the Cloudsite CLI configuration.',
+      arguments   : [
+        {
+          name          : 'subcommand',
+          defaultOption : true,
+          required      : true,
+          description   : 'The configuration action to perform.'
+        }
+      ],
+      commands : [
+        {
+          name        : 'initialize',
+          description : 'Runs the initialization wizard and updates all options.'
+        },
+        {
+          name        : 'show',
+          description : 'Displays the current configuration.'
+        }
+      ]
+    },
+    {
+      name        : 'create',
+      description : 'Creates a new website, setting up infrastructure and copying content.',
+      arguments   : [
+        {
+          name          : 'apex-domain',
+          description   : 'The site apex domain.',
+          defaultOption : true
+        },
+        {
+          name        : 'bucket-name',
+          description : 'The name of the bucket to be used. If no option is given, cloudsite will generate a bucket name based on the apex domain.'
+        },
+        {
+          name        : 'no-build',
+          description : 'Supresses the default behavior of building before uploading the site content.',
+          type        : Boolean
+        },
+        {
+          name        : 'no-delete-on-failure',
+          description : 'When true, does not delete the site stack after setup failure.',
+          type        : Boolean
+        },
+        {
+          name        : 'no-interactive',
+          description : 'Suppresses activation of the interactive setup where it would otherwise be activated.',
+          type        : Boolean
+        },
+        optionSpec,
+        {
+          name        : 'region',
+          description : "The region where to create the site resources. Defaults to 'us-east-1'.",
+          default     : 'us-east-1'
+        },
+        {
+          name        : 'source-path',
+          description : 'Local path to the static site root.',
+          required    : true
+        },
+        sourceTypeArgSpec,
+        {
+          name        : 'stack-name',
+          description : 'Specify the name of the stack to be created and override the default name.'
+        }
+      ]
+    },
+    {
+      name        : 'destroy',
+      description : 'Destroys the named site. I.e., deletes all cloud resources associated with the site.',
+      arguments   : [
+        {
+          name          : 'apex-domain',
+          description   : 'The domain of the site to delete.',
+          defaultOption : true,
+          required      : true
+        },
+        {
+          name        : 'confirmed',
+          description : 'Skips the interactive confirmation and destroys the resources without further confirmation.',
+          type        : Boolean
+        }
+      ]
+    },
+    {
+      name        : 'detail',
+      description : 'Prints details for the indicated site.',
+      arguments   : [
+        {
+          name          : 'apex-domain',
+          description   : 'The domain of the site to detail.',
+          defaultOption : true,
+          required      : true
+        }
+      ]
+    },
+    {
+      name        : 'get-iam-policy',
+      description : 'Prints an IAM policy suitable for operating cloudsite.',
+      arguments   : [
+        {
+          name        : 'with-instructions',
+          description : 'When set, will print instructions for creating the policy along with the policy.',
+          type        : Boolean
+        }
+      ]
+    },
+    {
+      name        : 'list',
+      description : 'Lists the sites registered in the local database.',
+      arguments   : [
+        {
+          name        : 'all-fields',
+          description : 'Includes all fields in the output.',
+          type        : Boolean
+        }
+      ]
+    },
+    {
+      name        : 'import',
+      description : 'Generates a site database based on currently deployed site stacks.',
+      arguments   : [
+        {
+          name        : 'common-logs-bucket',
+          description : "Specifies the common logs bucket name. This is only necessary if there are multiple candidates, otherwise cloudsite can usually guess. Set to 'NONE' to suppress guessing and assume there is on common logs bucket."
+        },
+        {
+          name          : 'domain-and-stack',
+          description   : 'The domain and stack are specified as positional parameters, in either order.',
+          defaultOption : true,
+          multiple      : true,
+          required      : true
+        },
+        {
+          name        : 'refresh',
+          description : "By defaualt, cloudsite will refuse to overwrite existing site DB entries. if '--refresh' is true, then it will update/refresh the existing entry.",
+          type        : Boolean
+        },
+        {
+          name        : 'region',
+          description : 'Specifies the region where the stack is to be found.',
+          required    : true
+        },
+        {
+          name        : 'source-path',
+          description : 'Local path to the static site root.',
+          required    : true
+        },
+        sourceTypeArgSpec
+      ]
+    },
+    {
+      name        : 'plugin-settings',
+      description : 'Sets (or deletes) a site option.',
+      arguments   : [
+        {
+          name          : 'subcommand',
+          description   : 'The subcommand to execute.',
+          defaultOption : true,
+          required      : true
+        }
+      ],
+      commands : [
+        {
+          name        : 'set',
+          description : 'Sets and deletes the specified options.',
+          arguments   : [
+            {
+              name          : 'apex-domain',
+              description   : 'The apex domain of the site to configure.',
+              defaultOption : true,
+              required      : true
+            },
+            {
+              name        : 'confirmed',
+              description : "When entirely deleting (disabling) a plugin, you must either confirm interactively or provide the '--confirmed' option.",
+              type        : Boolean
+            },
+            {
+              name        : 'delete',
+              description : "When set, then deletes the setting. Incompatible with the '--value' option. To delete all plugin settings (disable the plugin), set '--name' or '--option' to the bare plugin name; e.g.: --value aPlugin.",
+              type        : Boolean
+            },
+            {
+              name        : 'name',
+              description : 'The option name.'
+            },
+            optionSpec, // the 'options' definition
+            {
+              name        : 'value',
+              description : "The setting value. Incompatible with the '--delete' option."
+            }
+          ]
+        },
+        {
+          name        : 'show',
+          description : 'Displays the plugin settings for the specified site.',
+          arguments   : [
+            {
+              name          : 'apex-domain',
+              description   : 'The apex domain of the site whose settings are to be displayed.',
+              defaultOption : true,
+              required      : true
+            }
+          ]
+        }
+      ]
+    },
+    {
+      name      : 'update',
+      summary   : 'Updates a website content and/or infrastructure.',
+      arguments : [
+        {
+          name          : 'apex-domain',
+          description   : 'The apex domain identifying the site.',
+          defaultOption : true,
+          required      : true
+        },
+        {
+          name        : 'do-billing',
+          description : 'Limits updates to billing related matters (cost allocation tags) and other other specified updates.',
+          type        : Boolean
+        },
+        {
+          name        : 'do-content',
+          description : 'Limits update to site content and any other specified updates.',
+          type        : Boolean
+        },
+        {
+          name        : 'do-dns',
+          description : 'Limits update to DNS entries and any other specified updates.',
+          type        : Boolean
+        },
+        {
+          name        : 'do-stack',
+          description : 'Limits update to stack infrastructure and any other specified updates.',
+          type        : Boolean
+        },
+        {
+          name        : 'no-build',
+          description : 'Supresses the default behavior of building before updating the site.',
+          type        : Boolean
+        },
+        {
+          name        : 'no-cache-invalidation',
+          description : 'Suppresses the default behavior of invalidating the CloudFront cache after the files are updated. Note that invalidation events are chargeable thought at the time of this writing, each account gets 1,000 free requests per year.'
+        }
+      ]
+    },
+    {
+      name      : 'verify',
+      summary   : 'Verifies the site is up and running and that the stack and content are up-to-date.',
+      arguments : [
+        {
+          name          : 'apex-domain',
+          description   : 'The domain of the site to verify.',
+          defaultOption : true,
+          required      : true
+        },
+        {
+          name        : 'check-content',
+          description : 'If set, then checks content and skips other checks unless also specifically specified.',
+          type        : Boolean
+        },
+        {
+          name        : 'check-site-up',
+          description : 'If set, then checks that the site is up and skips other checks unless also specifically specified.',
+          type        : Boolean
+        },
+        {
+          name        : 'check-stack',
+          description : 'If set, then checks for stack drift and skips other checks unless also specifically specified.',
+          type        : Boolean
+        }
+      ]
+    }
+  ]
+}
+ 
+export { cliSpec, DB_PATH, globalOptionsSpec, SOURCE_TYPES, VALID_FORMATS }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/index.html b/qa/coverage/cli/index.html new file mode 100644 index 00000000..0cbf64e7 --- /dev/null +++ b/qa/coverage/cli/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for cli + + + + + + + + + +
+
+

All files cli

+
+ +
+ 0% + Statements + 0/111 +
+ + +
+ 0% + Branches + 0/53 +
+ + +
+ 0% + Functions + 0/4 +
+ + +
+ 0% + Lines + 0/99 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
cloudsite.mjs +
+
0%0/1020%0/470%0/30%0/91
constants.mjs +
+
0%0/90%0/60%0/10%0/8
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-authentication.mjs.html b/qa/coverage/cli/lib/check-authentication.mjs.html new file mode 100644 index 00000000..bf02d48e --- /dev/null +++ b/qa/coverage/cli/lib/check-authentication.mjs.html @@ -0,0 +1,124 @@ + + + + + + Code coverage report for cli/lib/check-authentication.mjs + + + + + + + + + +
+
+

All files / cli/lib check-authentication.mjs

+
+ +
+ 0% + Statements + 0/8 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/8 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { ListBucketsCommand, S3Client } from '@aws-sdk/client-s3'
+ 
+import { getCredentials } from '../../lib/actions/lib/get-credentials' // move to shared
+ 
+const checkAuthentication = async ({ db }) => {
+  const credentials = getCredentials(db.account.settings)
+ 
+  const s3Client = new S3Client({ credentials })
+  const listBucketsCommand = new ListBucketsCommand({})
+  await s3Client.send(listBucketsCommand) // we don't actually care about the result, we're just checking the auth
+}
+ 
+export { checkAuthentication }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-format.mjs.html b/qa/coverage/cli/lib/check-format.mjs.html new file mode 100644 index 00000000..98b8046d --- /dev/null +++ b/qa/coverage/cli/lib/check-format.mjs.html @@ -0,0 +1,112 @@ + + + + + + Code coverage report for cli/lib/check-format.mjs + + + + + + + + + +
+
+

All files / cli/lib check-format.mjs

+
+ +
+ 0% + Statements + 0/5 +
+ + +
+ 0% + Branches + 0/3 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10  +  +  +  +  +  +  +  +  + 
import { VALID_FORMATS } from '../constants'
+ 
+const checkFormat = (format) => {
+  Iif (format !== undefined && !VALID_FORMATS.includes(format)) {
+    throw new Error(`Invalid output format '${format}'. Must be one of: ${VALID_FORMATS.join(', ')}`)
+  }
+}
+ 
+export { checkFormat }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-reminders.mjs.html b/qa/coverage/cli/lib/check-reminders.mjs.html new file mode 100644 index 00000000..4327484e --- /dev/null +++ b/qa/coverage/cli/lib/check-reminders.mjs.html @@ -0,0 +1,154 @@ + + + + + + Code coverage report for cli/lib/check-reminders.mjs + + + + + + + + + +
+
+

All files / cli/lib check-reminders.mjs

+
+ +
+ 0% + Statements + 0/14 +
+ + +
+ 0% + Branches + 0/5 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/14 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { progressLogger } from '../../lib/shared/progress-logger'
+ 
+const checkReminders = ({ reminders }) => {
+  const now = new Date().getTime()
+  const currentReminders = reminders.filter(({ remindAfter }) => {
+    const remindAfterEpoch = Date.parse(remindAfter)
+    return remindAfterEpoch <= now
+  })
+ 
+  Iif (currentReminders.length > 0) {
+    const columnWidth = progressLogger.write.width
+    const opener = '-- <yellow>Reminder<rst>' + (currentReminders.lengith > 1 ? 's ' : ' ')
+    progressLogger.write(opener + '-'.repeat(columnWidth - opener.length + '<yellow>'.length + '<rst>'.length) + '\n')
+ 
+    currentReminders.forEach(({ todo }, i) => {
+      progressLogger.write((currentReminders.length > 1 ? i + '.' : '') + todo + '\n')
+    })
+ 
+    progressLogger.write('-'.repeat(columnWidth) + '\n')
+  }
+}
+ 
+export { checkReminders }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html b/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html new file mode 100644 index 00000000..a280fc78 --- /dev/null +++ b/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html @@ -0,0 +1,193 @@ + + + + + + Code coverage report for cli/lib/configuration/handle-configuration-initialize.mjs + + + + + + + + + +
+
+

All files / cli/lib/configuration handle-configuration-initialize.mjs

+
+ +
+ 100% + Statements + 9/9 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 9/9 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +371x +  +1x +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +1x +  +1x +  +1x +1x +  +  + 
import { Questioner } from 'question-and-answer'
+ 
+import { progressLogger } from '../../../lib/shared/progress-logger'
+ 
+const handleConfigurationInitialize = async ({ db }) => {
+  const interrogationBundle = {
+    actions : [
+      {
+        prompt    : "Which local AWS SSO profile should be used for authentication? Hit '<enter>' to use the default profile.",
+        parameter : 'sso-profile'
+      },
+      {
+        prompt    : 'Which default format would you prefer?',
+        options   : ['json', 'text', 'terminal', 'yaml'],
+        default   : 'terminal',
+        parameter : 'format'
+      },
+      {
+        prompt    : "In 'quiet' mode, you only get output when an command has completed. In 'non-quiet' mode, you will receive updates as the command is processed. Would you like to activate quiet mode?",
+        type      : 'boolean',
+        default   : false,
+        parameter : 'quiet'
+      },
+      { review : 'questions' }
+    ]
+  }
+ 
+  const questioner = new Questioner({ interrogationBundle, output : progressLogger })
+  await questioner.question()
+ 
+  db.account.settings = questioner.values
+ 
+  return { success : true, userMessage : 'Settings updated.' }
+}
+ 
+export { handleConfigurationInitialize }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html b/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html new file mode 100644 index 00000000..47744ac4 --- /dev/null +++ b/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html @@ -0,0 +1,145 @@ + + + + + + Code coverage report for cli/lib/configuration/handle-configuration-show.mjs + + + + + + + + + +
+
+

All files / cli/lib/configuration handle-configuration-show.mjs

+
+ +
+ 100% + Statements + 4/4 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 4/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +1x +1x +1x +  +  + 
/* import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../../constants'
+import { getOptionsSpec } from '../get-options-spec' */
+ 
+const handleConfigurationShow = async ({ /* argv, */ db }) => {
+  /*
+  const myOptionsSpec = cliSpec
+    .commands.find(({ name }) => name === 'configuration')
+    .commands.find(({ name }) => name === 'show')
+    .arguments || []
+  const showConfigurationCLISpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
+  const showConfigurationOptionsSpec = showConfigurationCLISpec.arguments
+  const showConfigurationOptions = commandLineArgs(showConfigurationOptionsSpec, { argv }) */
+ 
+  const accountSettings = db.account.settings || {}
+  return { success : true, data : accountSettings }
+}
+ 
+export { handleConfigurationShow }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/index.html b/qa/coverage/cli/lib/configuration/index.html new file mode 100644 index 00000000..9dc23cde --- /dev/null +++ b/qa/coverage/cli/lib/configuration/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for cli/lib/configuration + + + + + + + + + +
+
+

All files cli/lib/configuration

+
+ +
+ 100% + Statements + 13/13 +
+ + +
+ 50% + Branches + 1/2 +
+ + +
+ 100% + Functions + 2/2 +
+ + +
+ 100% + Lines + 13/13 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
handle-configuration-initialize.mjs +
+
100%9/9100%0/0100%1/1100%9/9
handle-configuration-show.mjs +
+
100%4/450%1/2100%1/1100%4/4
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-global-options.mjs.html b/qa/coverage/cli/lib/get-global-options.mjs.html new file mode 100644 index 00000000..6e1df40e --- /dev/null +++ b/qa/coverage/cli/lib/get-global-options.mjs.html @@ -0,0 +1,187 @@ + + + + + + Code coverage report for cli/lib/get-global-options.mjs + + + + + + + + + +
+
+

All files / cli/lib get-global-options.mjs

+
+ +
+ 0% + Statements + 0/18 +
+ + +
+ 0% + Branches + 0/14 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/18 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { checkFormat } from './check-format'
+import { globalOptionsSpec } from '../constants'
+ 
+let globalOptionsCache
+ 
+const getGlobalOptions = ({ db }) => {
+  Iif (globalOptionsCache !== undefined) {
+    return globalOptionsCache
+  } // else
+ 
+  const defaultOptions = db?.account?.settings || {}
+ 
+  const overrideOptions = commandLineArgs(globalOptionsSpec, { partial : true })
+  delete overrideOptions._unknown // don't need or want this
+ 
+  const globalOptions = Object.assign({}, defaultOptions, overrideOptions)
+ 
+  const { format, verbose } = globalOptions
+ 
+  checkFormat(format)
+ 
+  let { quiet } = globalOptions
+  // process.stdin.isTTY =~ shell program (true) or pipe (false)
+  quiet = quiet || (verbose !== true && (format === 'json' || format === 'yaml' || !process.stdin.isTTY))
+  globalOptions.quiet = quiet
+ 
+  globalOptionsCache = globalOptions
+ 
+  return globalOptions
+}
+ 
+export { getGlobalOptions }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-options-spec.mjs.html b/qa/coverage/cli/lib/get-options-spec.mjs.html new file mode 100644 index 00000000..56eb16f5 --- /dev/null +++ b/qa/coverage/cli/lib/get-options-spec.mjs.html @@ -0,0 +1,130 @@ + + + + + + Code coverage report for cli/lib/get-options-spec.mjs + + + + + + + + + +
+
+

All files / cli/lib get-options-spec.mjs

+
+ +
+ 0% + Statements + 0/7 +
+ + +
+ 0% + Branches + 0/7 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/6 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { globalOptionsSpec } from '../constants'
+ 
+const getOptionsSpec = ({ cliSpec, optionsSpec, name }) => {
+  optionsSpec = optionsSpec || cliSpec?.commands.find(({ name : testName }) => name === testName).arguments || []
+  const finalSpec =
+    [
+      ...optionsSpec,
+      // this is so we can process the global options anywhere while also sounding alarm on unknown options
+      ...globalOptionsSpec
+    ]
+ 
+  return finalSpec
+}
+ 
+export { getOptionsSpec }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-site-info.mjs.html b/qa/coverage/cli/lib/get-site-info.mjs.html new file mode 100644 index 00000000..4415d447 --- /dev/null +++ b/qa/coverage/cli/lib/get-site-info.mjs.html @@ -0,0 +1,127 @@ + + + + + + Code coverage report for cli/lib/get-site-info.mjs + + + + + + + + + +
+
+

All files / cli/lib get-site-info.mjs

+
+ +
+ 0% + Statements + 0/8 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/8 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
const getSiteInfo = ({ apexDomain, db }) => {
+  Iif (apexDomain === undefined) {
+    throw new Error('Must specify site domain.')
+  }
+ 
+  const siteInfo = db.sites[apexDomain]
+  Iif (siteInfo === undefined) {
+    throw new Error(`No such site '${apexDomain}' found.`)
+  }
+ 
+  return siteInfo
+}
+ 
+export { getSiteInfo }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-value-container-and-key.mjs.html b/qa/coverage/cli/lib/get-value-container-and-key.mjs.html new file mode 100644 index 00000000..63d52c09 --- /dev/null +++ b/qa/coverage/cli/lib/get-value-container-and-key.mjs.html @@ -0,0 +1,229 @@ + + + + + + Code coverage report for cli/lib/get-value-container-and-key.mjs + + + + + + + + + +
+
+

All files / cli/lib get-value-container-and-key.mjs

+
+ +
+ 0% + Statements + 0/25 +
+ + +
+ 0% + Branches + 0/35 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/25 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
const getValueContainerAndKey = ({ path, pathPrefix, rootContainer, skipValueCheck, spec, value }) => {
+  const origPath = (pathPrefix === undefined ? '' : pathPrefix) + path.join('.') // used if validation error
+  Iif (path === undefined || path.length === 0) {
+    return [rootContainer, undefined]
+  }
+  // walks the path, creating new containers along the way as necessary
+  return path.reduce(([currContainer, currSpec], bit, i) => {
+    // then we're at the terminal path bit; let's analyze whether it's valid and if value passes validation
+    if (i === path.length - 1) {
+      currSpec = currSpec?.[bit]
+      if (currSpec !== undefined) {
+        const { matches, validation } = currSpec
+        Iif (validation === undefined && matches === undefined) {
+          throw new Error(
+            `Plugin option '${origPath}' spec must define either 'validation' or 'matches'.`,
+            { exitCode : 11 }
+          )
+        }
+        Iif (matches !== undefined && value?.match(matches) === null) {
+          throw new Error(
+            `Invalid value '${value}' for '${origPath}'; must match ${matches.toString()}.`,
+            { exitCode : 3 }
+          )
+        }
+ 
+        Iif (skipValueCheck !== true && validation !== undefined && !validation(value)) {
+          throw new Error(`Value '${value}' for '${origPath}' failed validation.`, { exitCode : 3 })
+        }
+      } else { // currSpec === undefined
+        throw new Error(`Path '${origPath}' incorrect; no such terminal bit '${bit}'.`, { exitCode : 3 })
+      }
+ 
+      return { valueKey : path[i], valueContainer : currContainer }
+    } else {
+      const currSpec = spec?.[bit]
+      Iif (currSpec === undefined && i > 0) {
+        throw new Error(`Invalid option path '${origPath}'; no such element '${bit}'.\n`)
+      }
+      const container = currContainer[bit]
+      Iif (container === undefined) {
+        currContainer[bit] = {}
+      }
+      return [currContainer[bit], currSpec]
+    }
+  }, [rootContainer, spec])
+}
+ 
+export { getValueContainerAndKey }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-cleanup.mjs.html b/qa/coverage/cli/lib/handle-cleanup.mjs.html new file mode 100644 index 00000000..ab5b23f6 --- /dev/null +++ b/qa/coverage/cli/lib/handle-cleanup.mjs.html @@ -0,0 +1,235 @@ + + + + + + Code coverage report for cli/lib/handle-cleanup.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-cleanup.mjs

+
+ +
+ 0% + Statements + 0/32 +
+ + +
+ 0% + Branches + 0/10 +
+ + +
+ 0% + Functions + 0/5 +
+ + +
+ 0% + Lines + 0/30 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { destroy } from '../../lib/actions/destroy'
+import { getOptionsSpec } from './get-options-spec'
+import { progressLogger } from '../../lib/shared/progress-logger'
+ 
+const handleCleanup = async ({ argv, db }) => {
+  const cleanupOptionsSpec = getOptionsSpec({ cliSpec, name : 'cleanup' })
+  const cleanupOptions = commandLineArgs(cleanupOptionsSpec, { argv })
+  const apexDomain = cleanupOptions['apex-domain']
+  const { list } = cleanupOptions
+ 
+  Iif (list === true) {
+    return { data : Object.keys(db.toCleanup) || [] }
+  }
+ 
+  const listOfSitesToCleanup = apexDomain === undefined
+    ? Object.keys(db.toCleanup)
+    : [apexDomain]
+ 
+  const deleteActions = listOfSitesToCleanup
+    .map((apexDomain) => {
+      progressLogger.write(`Cleaning up ${apexDomain}...\n`)
+      return destroy({ db, siteInfo : db.toCleanup[apexDomain], verbose : false })
+    })
+ 
+  progressLogger.write('.')
+  const intervalID = setInterval(() => progressLogger.write('.'), 2000)
+  const cleanupResults = await Promise.all(deleteActions)
+  clearInterval(intervalID)
+  progressLogger.write('\n')
+ 
+  listOfSitesToCleanup.forEach((apexDomain, i) => {
+    const cleanupResult = cleanupResults[i]
+    progressLogger.write(`${apexDomain}: ${cleanupResult === true ? 'CLEANED' : 'NOT cleaned'}\n`)
+    Iif (cleanupResult === true) {
+      delete db.toCleanup[apexDomain]
+      db.reminders.splice(db.reminders.findIndex(({ apexDomain: testDomain }) => testDomain === apexDomain), 1)
+    }
+  })
+ 
+  const userMessage = listOfSitesToCleanup.length === 1
+    ? `Site '${listOfSitesToCleanup[0]}' has been successfully cleaned.`
+    : `Sites '${listOfSitesToCleanup.join("', '")}' have been successfully cleaned.`
+ 
+  return { success : true, userMessage }
+}
+ 
+export { handleCleanup }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-configuration.mjs.html b/qa/coverage/cli/lib/handle-configuration.mjs.html new file mode 100644 index 00000000..eb5b416b --- /dev/null +++ b/qa/coverage/cli/lib/handle-configuration.mjs.html @@ -0,0 +1,157 @@ + + + + + + Code coverage report for cli/lib/handle-configuration.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-configuration.mjs

+
+ +
+ 0% + Statements + 0/15 +
+ + +
+ 0% + Branches + 0/5 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/15 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+import { handleConfigurationInitialize } from './configuration/handle-configuration-initialize'
+import { handleConfigurationShow } from './configuration/handle-configuration-show'
+ 
+const handleConfiguration = async ({ argv, db }) => {
+  const configurationOptionsSpec = getOptionsSpec({ cliSpec, name : 'configuration' })
+  const configurationOptions = commandLineArgs(configurationOptionsSpec, { argv, stopAtFirstUnknown : true })
+  const { subcommand } = configurationOptions
+  argv = configurationOptions._unknown || []
+ 
+  switch (subcommand) {
+    case 'initialize':
+      return await handleConfigurationInitialize({ argv, db })
+    case 'show':
+      return await handleConfigurationShow({ argv, db })
+    default:
+      throw new Error('Unknown configuration command: ' + subcommand)
+  }
+}
+ 
+export { handleConfiguration }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-create.mjs.html b/qa/coverage/cli/lib/handle-create.mjs.html new file mode 100644 index 00000000..5a58b17a --- /dev/null +++ b/qa/coverage/cli/lib/handle-create.mjs.html @@ -0,0 +1,475 @@ + + + + + + Code coverage report for cli/lib/handle-create.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-create.mjs

+
+ +
+ 0% + Statements + 0/74 +
+ + +
+ 0% + Branches + 0/30 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/72 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as fsPath from 'node:path'
+ 
+import commandLineArgs from 'command-line-args'
+import { awsS3TABucketNameRE, awsS3TABucketNameREString } from 'regex-repo'
+import { Questioner } from 'question-and-answer'
+ 
+import { checkAuthentication } from './check-authentication'
+import { cliSpec } from '../constants'
+import { create } from '../../lib/actions/create'
+import { getOptionsSpec } from './get-options-spec'
+import * as optionsLib from './options'
+import * as plugins from '../../lib/plugins'
+import { processSourceType } from './process-source-type'
+import { progressLogger } from '../../lib/shared/progress-logger'I
+ 
+const handleCreate = async ({ argv, db }) => {
+  await checkAuthentication({ db })
+ 
+  const createOptionsSpec = getOptionsSpec({ cliSpec, name : 'create' })
+  const createOptions = commandLineArgs(createOptionsSpec, { argv })
+  // action behavior options
+  const noDeleteOnFailure = createOptions['no-delete-on-failure']
+  // siteInfo options
+  let apexDomain = createOptions['apex-domain']
+  const bucketName = createOptions['bucket-name']
+  const noBuild = createOptions['no-build']
+  const noInteractive = createOptions['no-interactive']
+  // switch any relative sourcePath to absolute
+  let sourcePath = createOptions['source-path']
+  let sourceType = createOptions['source-type']
+  let stackName = createOptions['stack-name']
+  const options = optionsLib.mapRawOptions(createOptions.option)
+ 
+  Iif (noInteractive !== true) {
+    const interrogationBundle = { actions : [{ review : 'questions' }] }
+    Iif (sourcePath === undefined) { // doing these in reverse order because we're 'unshifting' to the front
+      interrogationBundle.actions.unshift({ prompt : 'Source path:', parameter : 'sourcePath' })
+    }
+    Iif (apexDomain === undefined) {
+      interrogationBundle.actions.unshift({ prompt : 'Apex domain:', parameter : 'apexDomain' })
+    }
+    Iif (interrogationBundle.actions.length > 1) {
+      const questioner = new Questioner({ interrogationBundle, output : progressLogger })
+      await questioner.question();
+ 
+      ({ apexDomain = apexDomain, sourcePath = sourcePath } = questioner.values)
+    }
+  }
+  sourcePath = fsPath.resolve(sourcePath)
+ 
+  // don't use 'getSiteInfo', it errors out on blanks
+  const siteInfo = db.sites[apexDomain] || { apexDomain, bucketName, sourcePath, sourceType }
+  siteInfo.region = createOptions.region || siteInfo.region || 'us-east-1'
+  Iif (stackName !== undefined) {
+    siteInfo.stackName = stackName
+  }
+ 
+  db.sites[apexDomain] = siteInfo
+ 
+  // verify the parameters/options
+  for (const [value, option] of [[apexDomain, 'apex-domain'], [sourcePath, 'source-path']]) {
+    Iif (value === undefined) {
+      throw new Error(`Missing required '${option}' option.`, { exitCode : 2 })
+      // TODO: handleHelp({ argv : ['create'] })
+    }
+  }
+  // TODO: verify apex domain matches apex domain RE
+ 
+  sourceType = processSourceType({ sourcePath, sourceType })
+ 
+  Iif (bucketName !== undefined && !awsS3TABucketNameRE.test(bucketName)) {
+    // we're not using Transfer Accelerated ATM, but we might want to at some point.
+    throw new Error(`Invalid bucket name. Must be valid AWS S3 Transfer Accelerated bucket name matching: ${awsS3TABucketNameREString}`, { exitCode : 2 })
+  }
+ 
+  Iif (options.length === 0 && noInteractive !== true) {
+    for (const [plugin, { config }] of Object.entries(plugins)) {
+      const { description, name, options: configOptions } = config
+      const interrogationBundle = {
+        actions : [
+          { statement : `<em>${name}<rst> plugin: ${description}` },
+          { prompt : `Enable '<em>${name}<rst>' plugin?`, options : ['yes', 'no'], default : 'no', parameter : 'enable' }
+        ]
+      }
+      const questioner = new Questioner({ interrogationBundle, output : progressLogger })
+      await questioner.question()
+      const enable = questioner.getResult('enable').value === 'yes'
+ 
+      Iif (enable === true) {
+        const interrogationBundle = { actions : [] }
+        for (const [parameter, configSpec] of Object.entries(configOptions)) {
+          const { default: defaultValue, description, invalidMessage, matches, required, type = 'string' } = configSpec
+          const questionSpec = {
+            default          : defaultValue,
+            invalidMessage,
+            prompt           : `<em>${parameter}<rst>: ${description}\nValue?`,
+            parameter,
+            requireSomething : required,
+            requireMatch     : matches,
+            type
+          }
+          interrogationBundle.actions.push(questionSpec)
+        }
+        const questioner = new Questioner({ interrogationBundle, output : progressLogger })
+        await questioner.question()
+        options.push(...questioner.results.map(({ parameter, value }) => ({ name : `${plugin}.${parameter}`, value })))
+      }
+    }
+  }
+ 
+  optionsLib.updatePluginSettings({ options, siteInfo })
+ 
+  // update siteInfo in case these were manually specified
+  for (const [value, field] of [[bucketName, 'bucketName'], [sourcePath, 'sourcePath'], [sourceType, 'sourceType']]) {
+    Iif (value !== undefined) {
+      siteInfo[field] = value
+    }
+  }
+ 
+  let success
+  ({ stackName, success } = await create({ db, noBuild, noDeleteOnFailure, siteInfo }))
+ 
+  if (success === true) {
+    return { success, userMessage : `Created stack '${stackName}'.` }
+  } else {
+    return { success, userMessage : `Failed to create stack '${stackName}'.` }
+  }
+}
+ 
+export { handleCreate }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-destroy.mjs.html b/qa/coverage/cli/lib/handle-destroy.mjs.html new file mode 100644 index 00000000..80ecdcf0 --- /dev/null +++ b/qa/coverage/cli/lib/handle-destroy.mjs.html @@ -0,0 +1,256 @@ + + + + + + Code coverage report for cli/lib/handle-destroy.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-destroy.mjs

+
+ +
+ 0% + Statements + 0/33 +
+ + +
+ 0% + Branches + 0/4 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/33 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+import { Questioner } from 'question-and-answer'
+ 
+import { cliSpec } from '../constants'
+import { destroy } from '../../lib/actions/destroy'
+import { getOptionsSpec } from './get-options-spec'
+import { getSiteInfo } from './get-site-info'
+import { progressLogger } from '../../lib/shared/progress-logger'
+ 
+const handleDestroy = async ({ argv, db }) => {
+  const destroyOptionsSpec = getOptionsSpec({ cliSpec, name : 'destroy' })
+  const destroyOptions = commandLineArgs(destroyOptionsSpec, { argv })
+  const apexDomain = destroyOptions['apex-domain']
+  let { confirmed } = destroyOptions
+ 
+  const siteInfo = getSiteInfo({ apexDomain, db })
+ 
+  Iif (confirmed !== true) {
+    const interrogationBundle = {
+      actions : [{
+        prompt    : `Confirm destruction of '${apexDomain}'?`,
+        paramType : 'boolean',
+        parameter : 'confirmed'
+      }]
+    }
+    const questioner = new Questioner({ interrogationBundle, output : progressLogger })
+    await questioner.question()
+    confirmed = questioner.getResult('confirmed').value
+ 
+    Iif (confirmed !== true) {
+      progressLogger.write('Not confirmed; canceling operation.\n')
+      return
+    }
+  }
+ 
+  const deleted = await destroy({ db, siteInfo, verbose : true })
+ 
+  if (deleted === true) {
+    delete db.sites[apexDomain]
+    return { success : true, userMessage : `${apexDomain} deleted.\nRemoved ${apexDomain} from local DB.\n` }
+  } else {
+    const now = new Date()
+    const remindAfter = new Date(now.getTime() + 2 * 60 * 60 * 1000)
+    siteInfo.lastCleanupAttempt = now.toISOString()
+    db.toCleanup[apexDomain] = siteInfo
+    db.reminders.push({
+      todo        : `Cleanup partially deleted site '${apexDomain}'. Try:\ncloudsite cleanup`,
+      remindAfter : remindAfter.toISOString(),
+      references  : apexDomain
+    })
+    delete db.sites[apexDomain]
+ 
+    return { success : false, userMessage : `The delete has failed, which is expected because the 'replicated Lambda functions' need to be cleared by AWS before all resources can be deleted. This can take 30 min to a few hours.\n\nThe site has been marked for cleanup and you can now create new sites using the '${apexDomain}' domain.\n\nYou can complete deletion by executing:\ncloudsite cleanup\n` }
+  }
+}
+ 
+export { handleDestroy }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-detail.mjs.html b/qa/coverage/cli/lib/handle-detail.mjs.html new file mode 100644 index 00000000..8484895c --- /dev/null +++ b/qa/coverage/cli/lib/handle-detail.mjs.html @@ -0,0 +1,160 @@ + + + + + + Code coverage report for cli/lib/handle-detail.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-detail.mjs

+
+ +
+ 0% + Statements + 0/16 +
+ + +
+ 0% + Branches + 0/1 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/16 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { checkFormat } from './check-format'
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+import { getSiteInfo } from './get-site-info'
+ 
+const handleDetail = ({ argv, db }) => {
+  const detailOptionsSpec = getOptionsSpec({ cliSpec, name : 'detail' })
+  const detailOptions = commandLineArgs(detailOptionsSpec, { argv })
+  const apexDomain = detailOptions['apex-domain']
+  const { format } = detailOptions
+ 
+  Iif (apexDomain === undefined) {
+    throw new Error('Apex domain must be specified.')
+  }
+ 
+  checkFormat(format)
+ 
+  const output = getSiteInfo({ apexDomain, db })
+ 
+  return { success : true, data : output }
+}
+ 
+export { handleDetail }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html b/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html new file mode 100644 index 00000000..6adc3e63 --- /dev/null +++ b/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html @@ -0,0 +1,847 @@ + + + + + + Code coverage report for cli/lib/handle-get-iam-policy.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-get-iam-policy.mjs

+
+ +
+ 0% + Statements + 0/21 +
+ + +
+ 0% + Branches + 0/6 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/21 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { getAccountID } from '../../lib/shared/get-account-id'
+import { getCredentials } from '../../lib/actions/lib/get-credentials' // TODO: move to shared
+import { getOptionsSpec } from './get-options-spec'
+import { progressLogger } from '../../lib/shared/progress-logger'
+ 
+const generateIAMPolicy = async (db) => {
+  // TODO: once we refactor 'sites.json' into 'cloudsite-db.json', with 'accountID' at the top level, we can pass that
+  // in here and avoid the 'getAccountID' call in many cases
+  let { accountID } = db.account
+  Iif (accountID === undefined) {
+    const credentials = getCredentials(db.account?.settings)
+    accountID = await getAccountID({ credentials })
+  }
+ 
+  return {
+    Version   : '2012-10-17',
+    Statement : [
+      {
+        Sid    : 'CloudsiteAcmGrants',
+        Effect : 'Allow',
+        Action : [
+          'acm:ListCertificates',
+          'acm:RequestCertificate'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteCostExplorerGrants',
+        Effect : 'Allow',
+        Action : [
+          'ce:UpdateCostAllocationTagsStatus'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteCloudFormationGrants',
+        Effect : 'Allow',
+        Action : [
+          'cloudformation:CreateStack',
+          'cloudformation:DeleteStack',
+          'cloudformation:DescribeStackDriftDetectionStatus',
+          'cloudformation:DescribeStackEvents',
+          'cloudformation:DescribeStacks',
+          'cloudformation:DetectStackDrift',
+          'cloudformation:DetectStackResourceDrift',
+          'cloudformation:GetTemplate',
+          'cloudformation:ListChangeSets',
+          'cloudformation:UpdateStack'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteCloudFrontGrants',
+        Effect : 'Allow',
+        Action : [
+          'cloudfront:CreateDistribution',
+          'cloudfront:CreateInvalidation',
+          'cloudfront:CreateOriginAccessControl',
+          'cloudfront:DeleteDistribution',
+          'cloudfront:DeleteOriginAccessControl',
+          'cloudfront:GetDistribution',
+          'cloudfront:GetOriginAccessControl',
+          'cloudfront:ListDistributions',
+          'cloudfront:ListOriginAccessControls',
+          'cloudfront:TagResource',
+          'cloudfront:UpdateDistribution',
+          'cloudfront:UpdateOriginAccessControl'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteDynamoDBGrants',
+        Effect : 'Allow',
+        Action : [
+          'dynamodb:CreateTable',
+          'dynamodb:DeleteTable',
+          'dynamodb:DescribeTable',
+          'dynamodb:ListTagsOfResource',
+          'dynamodb:TagResource',
+          'dynamodb:UntagResource',
+          'dynamodb:UpdateTable'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsitePolicyManagement',
+        Effect : 'Allow',
+        Action : [
+          'iam:AttachRolePolicy',
+          'iam:DetachRolePolicy',
+          'iam:DeleteRolePolicy'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsitePassRole',
+        Effect : 'Allow',
+        Action : [
+          'iam:PassRole'
+        ],
+        Resource : [
+          `arn:aws:iam::${accountID}:role/cloudsite/*`
+        ],
+        Condition : {
+          'ForAnyValue:StringEquals' : {
+            'iam:PassedToService' : [
+              'lambda.amazonaws.com',
+              'edgelambda.amazonaws.com'
+            ]
+          }
+        }
+      },
+      {
+        Sid    : 'CloudsiteRoleManagement',
+        Effect : 'Allow',
+        Action : [
+          'iam:CreateRole',
+          'iam:DeleteRole',
+          'iam:GetRole',
+          'iam:PutRolePolicy',
+          'iam:TagRole',
+          'iam:UntagRole',
+          'iam:UpdateRole'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteLambdaGrants',
+        Effect : 'Allow',
+        Action : [
+          'lambda:AddPermission',
+          'lambda:CreateFunction',
+          'lambda:CreateEventSourceMapping',
+          'lambda:CreateFunctionUrlConfig',
+          'lambda:DeleteEventSourceMapping',
+          'lambda:DeleteFunction',
+          'lambda:DeleteFunctionUrlConfig',
+          'lambda:EnableReplication',
+          'lambda:GetEventSourceMapping',
+          'lambda:GetFunction',
+          'lambda:GetFunctionConfiguration',
+          'lambda:GetFunctionUrlConfig',
+          'lambda:ListFunctions',
+          'lambda:ListFunctionUrlConfigs',
+          'lambda:ListTags',
+          'lambda:ListVersionsByFunction',
+          'lambda:PublishVersion',
+          'lambda:RemovePermission',
+          'lambda:TagResource',
+          'lambda:UpdateEventSourceMapping',
+          'lambda:UpdateFunctionCode',
+          'lambda:UpdateFunctionConfiguration',
+          'lambda:UpdateFunctionUrlConfig'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteLogGrants',
+        Effect : 'Allow',
+        Action : [
+          'logs:CreateLogGroup',
+          'logs:DeleteLogGroup',
+          'logs:DeleteRetentionPolicy',
+          'logs:ListTagsForResource',
+          'logs:PutRetentionPolicy',
+          'logs:TagResource',
+          'logs:UntagResource'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteRoute53Grants',
+        Effect : 'Allow',
+        Action : [
+          'route53:ListHostedZones',
+          'route53:ChangeResourceRecordSets',
+          'route53:ChangeTagsForResource',
+          'route53:ListResourceRecordSets'
+        ],
+        Resource : [
+          '*'
+        ]
+      },
+      {
+        Sid    : 'CloudsiteS3Grants',
+        Effect : 'Allow',
+        Action : [
+          's3:CreateBucket',
+          's3:PutObject',
+          's3:DeleteObject',
+          's3:DeleteBucket',
+          's3:DeleteBucketPolicy',
+          's3:GetObject',
+          's3:ListAllMyBuckets',
+          's3:ListBucket',
+          's3:PutBucketAcl',
+          's3:PutBucketPolicy',
+          's3:PutBucketTagging',
+          's3:*'
+        ],
+        Resource : [
+          'arn:aws:s3:::*'
+        ]
+      }
+    ]
+  }
+}
+ 
+const instructions =
+`1. Log into the AWS console.
+2. Select/navigate to the IAM service.
+3. Select 'Policies' from the left hand menu options.
+4. For a new policy, select 'Create policy' and name it 'CloudsiteManager'.
+   A. Select the 'JSON' option.
+5. For an existing policy, search for 'CloudsiteManager'.
+   A. Select 'Edit
+6. Copy and paste the above policy into the edit box.
+7. Hit 'Next' and then 'Save'.`
+ 
+const handleGetIAMPolicy = async ({ argv, db }) => {
+  const getIAMPolicyOptionsSpec = getOptionsSpec({ cliSpec, name : 'get-iam-policy' })
+  const getIAMPolicyOptions = commandLineArgs(getIAMPolicyOptionsSpec, { argv })
+  const withInstructions = getIAMPolicyOptions['with-instructions']
+ 
+  progressLogger.write(JSON.stringify(await generateIAMPolicy(db), null, '  ') + '\n')
+ 
+  Iif (withInstructions === true) {
+    // As of 2024-03-29, smartIndent does not work with numbered lists, but it should in the future.
+    progressLogger.write('\n' + instructions + '\n', { smartIndent : true })
+  }
+}
+ 
+export { handleGetIAMPolicy }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-import.mjs.html b/qa/coverage/cli/lib/handle-import.mjs.html new file mode 100644 index 00000000..5d62ac4c --- /dev/null +++ b/qa/coverage/cli/lib/handle-import.mjs.html @@ -0,0 +1,286 @@ + + + + + + Code coverage report for cli/lib/handle-import.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-import.mjs

+
+ +
+ 0% + Statements + 0/41 +
+ + +
+ 0% + Branches + 0/22 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/41 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { resolve as resolvePath } from 'node:path'
+ 
+import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { doImport } from '../../lib/actions/import'
+import { getOptionsSpec } from './get-options-spec'
+import { processSourceType } from './process-source-type'
+import { progressLogger } from '../../lib/shared/progress-logger'
+ 
+const handleImport = async ({ argv, db }) => {
+  // gather parameter values
+  const importOptionsSpec = getOptionsSpec({ cliSpec, name : 'import' })
+  const importOptions = commandLineArgs(importOptionsSpec, { argv })
+  const commonLogsBucket = importOptions['common-logs-bucket']
+  const domainAndStack = importOptions['domain-and-stack']
+  const { refresh, region } = importOptions
+  let sourcePath = importOptions['source-path']
+ 
+  // verify input parameters form correct
+  Iif (sourcePath === undefined) {
+    throw new Error("Must define '--source-path'.")
+  }
+ 
+  sourcePath = resolvePath(sourcePath)
+  const sourceType = processSourceType({ sourcePath, sourceType : importOptions['source-type'] })
+ 
+  Iif (domainAndStack?.length !== 2) {
+    throw new Error(`Unexpected number of positional arguments, expect 2 (domain and stack name), but got ${domainAndStack?.length || '0'}.\n`)
+  }
+  Iif (region === undefined) {
+    throw new Error("You must specify the '--region' parameter.\n")
+  }
+  Iif (sourcePath === undefined) {
+    throw new Error("You must specify the '--source-path' parameter.\n")
+  }
+ 
+  let domain, stack
+  for (const domainOrStack of domainAndStack) {
+    if (domainOrStack.match(/\./)) {
+      domain = domainOrStack
+    } else Iif (domainOrStack.match(/^[a-z][a-z0-9-]*$/i)) {
+      stack = domainOrStack
+    }
+  }
+ 
+  const sitesInfo = db.sites
+ 
+  Iif (sitesInfo[domain] !== undefined && refresh !== true) {
+    throw new Error(`Domain '${domain}' is already in the sites DB. To update/refresh the values, use the '--refresh' option.`)
+  }
+  Iif (domain === undefined) {
+    throw new Error(`Could not determine domain name from arguments (${domainAndStack}).\n`)
+  }
+  Iif (stack === undefined) {
+    throw new Error(`Could not determine stack name from arguments (${domainAndStack}).\n`)
+  }
+ 
+  // now, actually do the import
+  const dbEntry = await doImport({ commonLogsBucket, db, domain, region, sourcePath, sourceType, stack })
+  progressLogger.write(`Updating DB entry for '${domain}'...\n`)
+  sitesInfo[domain] = dbEntry
+ 
+  return { success : true, userMessage : `Imported site '${domain}'.` }
+}
+ 
+export { handleImport }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-list.mjs.html b/qa/coverage/cli/lib/handle-list.mjs.html new file mode 100644 index 00000000..d328e875 --- /dev/null +++ b/qa/coverage/cli/lib/handle-list.mjs.html @@ -0,0 +1,157 @@ + + + + + + Code coverage report for cli/lib/handle-list.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-list.mjs

+
+ +
+ 0% + Statements + 0/15 +
+ + +
+ 0% + Branches + 0/4 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/15 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+import pick from 'lodash/pick'
+ 
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+ 
+const handleList = ({ argv, db }) => {
+  const listOptionsSpec = getOptionsSpec({ cliSpec, name : 'list' })
+  const listOptions = commandLineArgs(listOptionsSpec, { argv })
+  const allFields = listOptions['all-fields']
+ 
+  const sitesInfoArray = Object.values(db.sites)
+  const output = allFields === true
+    ? sitesInfoArray
+    : sitesInfoArray.map((siteInfo) => {
+      const trimmed = pick(siteInfo, ['apexDomain', 'region', 'sourcePath'])
+      trimmed.plugins = Object.keys(siteInfo.plugins || {})
+      return trimmed
+    })
+ 
+  return { data : output, success : true }
+}
+ 
+export { handleList }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-plugin-settings.mjs.html b/qa/coverage/cli/lib/handle-plugin-settings.mjs.html new file mode 100644 index 00000000..46584b5e --- /dev/null +++ b/qa/coverage/cli/lib/handle-plugin-settings.mjs.html @@ -0,0 +1,157 @@ + + + + + + Code coverage report for cli/lib/handle-plugin-settings.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-plugin-settings.mjs

+
+ +
+ 0% + Statements + 0/15 +
+ + +
+ 0% + Branches + 0/5 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/15 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+import { handlePluginSettingsSet } from './plugin-settings/handle-plugin-settings-set'
+import { handlePluginSettingsShow } from './plugin-settings/handle-plugin-settings-show'
+ 
+const handlePluginSettings = async ({ argv, db }) => {
+  const setOptionOptionsSpec = getOptionsSpec({ cliSpec, name : 'plugin-settings' })
+  const setOptionOptions = commandLineArgs(setOptionOptionsSpec, { argv, stopAtFirstUnknown : true })
+  const { subcommand } = setOptionOptions
+  argv = setOptionOptions._unknown || []
+ 
+  switch (subcommand) {
+    case 'set':
+      return await handlePluginSettingsSet({ argv, db })
+    case 'show':
+      return await handlePluginSettingsShow({ argv, db })
+    default:
+      throw new Error('Unknown plugin settings command: ' + subcommand)
+  }
+}
+ 
+export { handlePluginSettings }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-update.mjs.html b/qa/coverage/cli/lib/handle-update.mjs.html new file mode 100644 index 00000000..9ce1294b --- /dev/null +++ b/qa/coverage/cli/lib/handle-update.mjs.html @@ -0,0 +1,163 @@ + + + + + + Code coverage report for cli/lib/handle-update.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-update.mjs

+
+ +
+ 0% + Statements + 0/19 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/19 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+import { getSiteInfo } from './get-site-info'
+import { update } from '../../lib/actions/update'
+ 
+const handleUpdate = async ({ argv, db }) => {
+  const updateOptionsSpec = getOptionsSpec({ cliSpec, name : 'update' })
+  const updateOptions = commandLineArgs(updateOptionsSpec, { argv })
+  const apexDomain = updateOptions['apex-domain']
+  const doBilling = updateOptions['do-billing']
+  const doContent = updateOptions['do-content']
+  const doDNS = updateOptions['do-dns']
+  const doStack = updateOptions['do-stack']
+  const noBuild = updateOptions['no-build']
+  const noCacheInvalidation = updateOptions['no-cache-invalidation']
+ 
+  const siteInfo = getSiteInfo({ apexDomain, db })
+ 
+  await update({ db, doBilling, doContent, doDNS, doStack, noBuild, noCacheInvalidation, siteInfo })
+ 
+  return { success : true, userMessage : `Updated '${apexDomain}' site.` }
+}
+ 
+export { handleUpdate }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-verify.mjs.html b/qa/coverage/cli/lib/handle-verify.mjs.html new file mode 100644 index 00000000..a0b0dc88 --- /dev/null +++ b/qa/coverage/cli/lib/handle-verify.mjs.html @@ -0,0 +1,184 @@ + + + + + + Code coverage report for cli/lib/handle-verify.mjs + + + + + + + + + +
+
+

All files / cli/lib handle-verify.mjs

+
+ +
+ 0% + Statements + 0/26 +
+ + +
+ 0% + Branches + 0/4 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/22 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { checkFormat } from './check-format'
+import { cliSpec } from '../constants'
+import { getOptionsSpec } from './get-options-spec'
+import { getSiteInfo } from './get-site-info'
+import { verify } from '../../lib/actions/verify'
+ 
+const handleVerify = async ({ argv, db }) => {
+  const verifyOptionsSpec = getOptionsSpec({ cliSpec, name : 'verify' })
+  const verifyOptions = commandLineArgs(verifyOptionsSpec, { argv })
+  const { format } = verifyOptions
+  const apexDomain = verifyOptions['apex-domain']
+  const checkContent = verifyOptions['check-content']
+  const checkSiteUp = verifyOptions['check-site-up']
+  const checkStack = verifyOptions['check-stack']
+ 
+  checkFormat(format)
+ 
+  const siteInfo = getSiteInfo({ apexDomain, db })
+ 
+  const results =
+    await verify({ checkContent, checkSiteUp, checkStack, db, siteInfo })
+  const summaryStatus = results.reduce((acc, { status : s }) => {
+    if (s === 'error') { return 'error' } else if (s === 'failed') { return 'failed' } else { return acc }
+  }, 'success')
+ 
+  const output = { 'overall status' : summaryStatus, checks : results }
+ 
+  return { data : output }
+}
+ 
+export { handleVerify }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/index.html b/qa/coverage/cli/lib/index.html new file mode 100644 index 00000000..24d1cf26 --- /dev/null +++ b/qa/coverage/cli/lib/index.html @@ -0,0 +1,416 @@ + + + + + + Code coverage report for cli/lib + + + + + + + + + +
+
+

All files cli/lib

+
+ +
+ 0% + Statements + 0/461 +
+ + +
+ 0% + Branches + 0/206 +
+ + +
+ 0% + Functions + 0/37 +
+ + +
+ 0% + Lines + 0/451 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
check-authentication.mjs +
+
0%0/8100%0/00%0/10%0/8
check-format.mjs +
+
0%0/50%0/30%0/10%0/5
check-reminders.mjs +
+
0%0/140%0/50%0/30%0/14
get-global-options.mjs +
+
0%0/180%0/140%0/10%0/18
get-options-spec.mjs +
+
0%0/70%0/70%0/20%0/6
get-site-info.mjs +
+
0%0/80%0/20%0/10%0/8
get-value-container-and-key.mjs +
+
0%0/250%0/350%0/20%0/25
handle-cleanup.mjs +
+
0%0/320%0/100%0/50%0/30
handle-configuration.mjs +
+
0%0/150%0/50%0/10%0/15
handle-create.mjs +
+
0%0/740%0/300%0/30%0/72
handle-destroy.mjs +
+
0%0/330%0/40%0/10%0/33
handle-detail.mjs +
+
0%0/160%0/10%0/10%0/16
handle-get-iam-policy.mjs +
+
0%0/210%0/60%0/20%0/21
handle-import.mjs +
+
0%0/410%0/220%0/10%0/41
handle-list.mjs +
+
0%0/150%0/40%0/20%0/15
handle-plugin-settings.mjs +
+
0%0/150%0/50%0/10%0/15
handle-update.mjs +
+
0%0/19100%0/00%0/10%0/19
handle-verify.mjs +
+
0%0/260%0/40%0/20%0/22
options.mjs +
+
0%0/420%0/280%0/40%0/41
process-source-type.mjs +
+
0%0/110%0/50%0/10%0/11
smart-convert.mjs +
+
0%0/160%0/160%0/10%0/16
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/options.mjs.html b/qa/coverage/cli/lib/options.mjs.html new file mode 100644 index 00000000..2a229124 --- /dev/null +++ b/qa/coverage/cli/lib/options.mjs.html @@ -0,0 +1,292 @@ + + + + + + Code coverage report for cli/lib/options.mjs + + + + + + + + + +
+
+

All files / cli/lib options.mjs

+
+ +
+ 0% + Statements + 0/42 +
+ + +
+ 0% + Branches + 0/28 +
+ + +
+ 0% + Functions + 0/4 +
+ + +
+ 0% + Lines + 0/41 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { getValueContainerAndKey } from './get-value-container-and-key'
+import * as plugins from '../../lib/plugins'
+import { progressLogger } from '../../lib/shared/progress-logger'
+import { smartConvert } from './smart-convert'I
+ 
+const mapRawOptions = (rawOptions = []) =>
+  rawOptions.map((spec) => {
+    let [name, value] = spec.split(/(?!\\):/)
+    value = value?.replaceAll(/\\:/g, ':') || 'true'
+    value = smartConvert(value)
+ 
+    return { name, value }
+  })
+ 
+const updatePluginSettings = ({ confirmed, doDelete, options, siteInfo }) => {
+  for (const { name, value } of options) {
+    const pathBits = name.split('.')
+    const pluginName = pathBits.shift()
+ 
+    const plugin = plugins[pluginName]
+    Iif (plugin === undefined) {
+      throw new Error(`No such plugin '${pluginName}'; use one of: ${Object.keys(plugins).join(', ')}.\n`)
+    }
+ 
+    Iif (siteInfo.plugins === undefined) {
+      siteInfo.plugins = {}
+    }
+    const pluginData = siteInfo.plugins[pluginName] || {}
+    siteInfo.plugins[pluginName] = pluginData // in case we just created it
+    const pluginSettings = siteInfo.plugins[pluginName].settings || {}
+    siteInfo.plugins[pluginName].settings = pluginSettings // in case we just created it
+    const spec = plugin.config.options
+ 
+    const { valueContainer, valueKey } = getValueContainerAndKey({
+      path           : pathBits,
+      pathPrefix     : pluginName + '.',
+      rootContainer  : pluginSettings,
+      skipValueCheck : doDelete,
+      spec,
+      value
+    })
+ 
+    if (doDelete === true && valueKey === undefined) { // then we're deleting/disabling the entire plugin
+      if (confirmed === true) {
+        const pluginSettings = siteInfo.plugins[pluginName]
+        delete siteInfo.plugins[pluginName]
+        progressLogger.write(`Deleted plugin settings for '${pluginName}'; was:\n${JSON.stringify(pluginSettings, null, '  ')}\n`)
+      } else {
+        throw new Error("Interactive confirmation not yet enabled. Use the '--confirmed' option. Note, this will delete all plugin settings and data and cannot be recovered. You must run 'cloudsite update' for this change to take effect. To re-enable the plugin, you must re-initialize all required settings and update the site.\n", 3)
+      }
+    } else if (doDelete === true) {
+      const wasValue = valueContainer[valueKey]
+      delete valueContainer[valueKey]
+      progressLogger.write(`Deleted option '${name}' (was: '${wasValue}').\n`)
+    } else {
+      valueContainer[valueKey] = value
+      progressLogger.write(`Set '${name}' to '${value}'.\n`)
+    }
+ 
+    // delete settings object if empty
+    // TODO: this is insufficient if we have a nested option that's empty, we could get something like:
+    // { settings: { blah: {} }}; we need a recursive 'cleanEmptyObjects' or something.
+    Iif (Object.keys(pluginSettings).length === 0) {
+      delete siteInfo.plugins[plugin].settings
+    }
+  }
+}
+ 
+export { mapRawOptions, updatePluginSettings }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html new file mode 100644 index 00000000..742f3dcc --- /dev/null +++ b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html @@ -0,0 +1,226 @@ + + + + + + Code coverage report for cli/lib/plugin-settings/handle-plugin-settings-set.mjs + + + + + + + + + +
+
+

All files / cli/lib/plugin-settings handle-plugin-settings-set.mjs

+
+ +
+ 0% + Statements + 0/32 +
+ + +
+ 0% + Branches + 0/29 +
+ + +
+ 0% + Functions + 0/4 +
+ + +
+ 0% + Lines + 0/31 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../../constants'
+import { getOptionsSpec } from '../get-options-spec'
+import { getSiteInfo } from '../get-site-info'
+import * as optionsLib from '../options'
+import { smartConvert } from '../smart-convert'I
+ 
+const handlePluginSettingsSet = async ({ argv, db }) => {
+  const myOptionsSpec = cliSpec
+    .commands.find(({ name }) => name === 'plugin-settings')
+    .commands.find(({ name }) => name === 'set')
+    .arguments || []
+  const pluginSettingsSetOptionsSpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
+  const pluginSettingsSetOptions = commandLineArgs(pluginSettingsSetOptionsSpec, { argv })
+  const apexDomain = pluginSettingsSetOptions['apex-domain']
+  const options = optionsLib.mapRawOptions(pluginSettingsSetOptions.option)
+ 
+  const { confirmed, delete: doDelete, name, value } = pluginSettingsSetOptions
+ 
+  // validate options
+  const siteInfo = getSiteInfo({ apexDomain, db })
+ 
+  if (doDelete === true && name === undefined && options.length === 0) {
+    throw new Error("You must specify a '--name' or at least one '--option' when '--delete' is set.\n")
+  } else if (name !== undefined && (value !== undefined || doDelete === true)) {
+    options.push({ name, value : smartConvert(value) }) // the 'option' values are already converted
+  } else if (name !== undefined && value === undefined) { // but delete is not set (checked above)
+    throw new Error("You must specify a '--value' or '--delete' when '--name' is set.\n")
+  } else Iif (name === undefined && value !== undefined) {
+    throw new Error("You must specify a '--name' when '--value' is set.\n")
+  }
+ 
+  Iif (doDelete !== true && options.length === 0) {
+    throw new Error("Invalid options; specify '--name'+'--value', '--delete'/'--name', or one or more '--option' options.\n")
+  }
+ 
+  // take actions and update the options
+  Iif (siteInfo.plugins === undefined) {
+    siteInfo.plugins = {}
+  }
+  optionsLib.updatePluginSettings({ confirmed, doDelete, options, siteInfo })
+ 
+  return { success : true, userMessage : `Plugin options updated for ${apexDomain}.` }
+}
+ 
+export { handlePluginSettingsSet }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html new file mode 100644 index 00000000..5bf88933 --- /dev/null +++ b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html @@ -0,0 +1,145 @@ + + + + + + Code coverage report for cli/lib/plugin-settings/handle-plugin-settings-show.mjs + + + + + + + + + +
+
+

All files / cli/lib/plugin-settings handle-plugin-settings-show.mjs

+
+ +
+ 0% + Statements + 0/13 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/13 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import commandLineArgs from 'command-line-args'
+ 
+import { cliSpec } from '../../constants'
+import { getOptionsSpec } from '../get-options-spec'
+ 
+const handlePluginSettingsShow = async ({ argv, db }) => {
+  const myOptionsSpec = cliSpec
+    .commands.find(({ name }) => name === 'plugin-settings')
+    .commands.find(({ name }) => name === 'show')
+    .arguments || []
+  const handlePluginSettingsShowOptionsSpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
+  const handlePluginSettingsShowOptions = commandLineArgs(handlePluginSettingsShowOptionsSpec, { argv })
+  const apexDomain = handlePluginSettingsShowOptions['apex-domain']
+ 
+  const settings = db.sites[apexDomain].plugins
+ 
+  return { success : true, data : settings }
+}
+ 
+export { handlePluginSettingsShow }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/index.html b/qa/coverage/cli/lib/plugin-settings/index.html new file mode 100644 index 00000000..68acfc88 --- /dev/null +++ b/qa/coverage/cli/lib/plugin-settings/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for cli/lib/plugin-settings + + + + + + + + + +
+
+

All files cli/lib/plugin-settings

+
+ +
+ 0% + Statements + 0/45 +
+ + +
+ 0% + Branches + 0/31 +
+ + +
+ 0% + Functions + 0/7 +
+ + +
+ 0% + Lines + 0/44 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
handle-plugin-settings-set.mjs +
+
0%0/320%0/290%0/40%0/31
handle-plugin-settings-show.mjs +
+
0%0/130%0/20%0/30%0/13
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/process-source-type.mjs.html b/qa/coverage/cli/lib/process-source-type.mjs.html new file mode 100644 index 00000000..a8f1d842 --- /dev/null +++ b/qa/coverage/cli/lib/process-source-type.mjs.html @@ -0,0 +1,136 @@ + + + + + + Code coverage report for cli/lib/process-source-type.mjs + + + + + + + + + +
+
+

All files / cli/lib process-source-type.mjs

+
+ +
+ 0% + Statements + 0/11 +
+ + +
+ 0% + Branches + 0/5 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/11 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { existsSync as fileExists } from 'node:fs'
+import { resolve as resolvePath } from 'node:path'
+ 
+import { SOURCE_TYPES } from '../constants'
+ 
+const processSourceType = ({ sourcePath, sourceType }) => {
+  if (sourceType === undefined) {
+    const docusaurusConfigPath = resolvePath(sourcePath, '..', 'docusaurus.config.js')
+    sourceType = fileExists(docusaurusConfigPath) ? 'docusaurus' : 'vanilla'
+  } else Iif (!SOURCE_TYPES.includes(sourceType)) {
+    throw new Error(`Invalid site source type '${sourceType}'; must be one of ${SOURCE_TYPES.join(', ')}.\n`, 2)
+  }
+ 
+  return sourceType
+}
+ 
+export { processSourceType }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/cli/lib/smart-convert.mjs.html b/qa/coverage/cli/lib/smart-convert.mjs.html new file mode 100644 index 00000000..0f930cdf --- /dev/null +++ b/qa/coverage/cli/lib/smart-convert.mjs.html @@ -0,0 +1,151 @@ + + + + + + Code coverage report for cli/lib/smart-convert.mjs + + + + + + + + + +
+
+

All files / cli/lib smart-convert.mjs

+
+ +
+ 0% + Statements + 0/16 +
+ + +
+ 0% + Branches + 0/16 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/16 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
const smartConvert = (value) => {
+  if (value === undefined) {
+    return ''
+  } else if (value === 'true' || value === 'TRUE') {
+    return true
+  } else if (value === 'false' || value === 'FALSE') {
+    return false
+  } else if (value.match(/^\s*\d+\s*$/)) {
+    return parseInt(value)
+  } else if (value.match(/^\s*(?:\d+(?:\.\d+)|\.\d+)\s*$/)) {
+    return parseFloat(value)
+  } else {
+    value = value.trim()
+    if (value.startsWith('\\')) {
+      return value.slice(1)
+    } else {
+      return value
+    }
+  }
+}
+ 
+export { smartConvert }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/clover.xml b/qa/coverage/clover.xml new file mode 100644 index 00000000..9be49383 --- /dev/null +++ b/qa/coverage/clover.xml @@ -0,0 +1,1635 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/qa/coverage/coverage-final.json b/qa/coverage/coverage-final.json new file mode 100644 index 00000000..7b0367e7 --- /dev/null +++ b/qa/coverage/coverage-final.json @@ -0,0 +1,62 @@ +{"/Users/zane/playground/cloudsite/src/cli/cloudsite.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/cloudsite.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"9":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"10":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"11":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"12":{"start":{"line":15,"column":0},"end":{"line":15,"column":null}},"13":{"start":{"line":16,"column":0},"end":{"line":16,"column":null}},"14":{"start":{"line":17,"column":0},"end":{"line":17,"column":null}},"15":{"start":{"line":18,"column":0},"end":{"line":18,"column":null}},"16":{"start":{"line":19,"column":0},"end":{"line":19,"column":null}},"17":{"start":{"line":20,"column":0},"end":{"line":20,"column":null}},"18":{"start":{"line":21,"column":0},"end":{"line":21,"column":50}},"19":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"20":{"start":{"line":23,"column":18},"end":{"line":145,"column":1}},"21":{"start":{"line":25,"column":22},"end":{"line":25,"column":89}},"22":{"start":{"line":26,"column":15},"end":{"line":26,"column":41}},"23":{"start":{"line":28,"column":34},"end":{"line":28,"column":45}},"24":{"start":{"line":29,"column":22},"end":{"line":29,"column":49}},"25":{"start":{"line":32,"column":2},"end":{"line":41,"column":null}},"26":{"start":{"line":33,"column":23},"end":{"line":33,"column":72}},"27":{"start":{"line":34,"column":4},"end":{"line":34,"column":null}},"28":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"29":{"start":{"line":37,"column":6},"end":{"line":37,"column":null}},"30":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"31":{"start":{"line":43,"column":24},"end":{"line":43,"column":48}},"32":{"start":{"line":44,"column":21},"end":{"line":44,"column":34}},"33":{"start":{"line":45,"column":21},"end":{"line":45,"column":49}},"34":{"start":{"line":46,"column":21},"end":{"line":46,"column":49}},"35":{"start":{"line":48,"column":2},"end":{"line":48,"column":null}},"36":{"start":{"line":50,"column":2},"end":{"line":52,"column":null}},"37":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"38":{"start":{"line":54,"column":17},"end":{"line":54,"column":36}},"39":{"start":{"line":57,"column":17},"end":{"line":57,"column":18}},"40":{"start":{"line":60,"column":2},"end":{"line":110,"column":null}},"41":{"start":{"line":61,"column":4},"end":{"line":94,"column":null}},"42":{"start":{"line":63,"column":8},"end":{"line":63,"column":72}},"43":{"start":{"line":63,"column":72},"end":{"line":63,"column":null}},"44":{"start":{"line":65,"column":8},"end":{"line":65,"column":84}},"45":{"start":{"line":65,"column":84},"end":{"line":65,"column":null}},"46":{"start":{"line":67,"column":8},"end":{"line":67,"column":71}},"47":{"start":{"line":67,"column":71},"end":{"line":67,"column":null}},"48":{"start":{"line":69,"column":8},"end":{"line":69,"column":72}},"49":{"start":{"line":69,"column":72},"end":{"line":69,"column":null}},"50":{"start":{"line":71,"column":8},"end":{"line":71,"column":64}},"51":{"start":{"line":71,"column":64},"end":{"line":71,"column":null}},"52":{"start":{"line":73,"column":8},"end":{"line":73,"column":null}},"53":{"start":{"line":74,"column":8},"end":{"line":74,"column":null}},"54":{"start":{"line":75,"column":8},"end":{"line":75,"column":null}},"55":{"start":{"line":76,"column":8},"end":{"line":76,"column":null}},"56":{"start":{"line":78,"column":8},"end":{"line":78,"column":null}},"57":{"start":{"line":79,"column":8},"end":{"line":79,"column":15}},"58":{"start":{"line":81,"column":8},"end":{"line":81,"column":62}},"59":{"start":{"line":81,"column":62},"end":{"line":81,"column":null}},"60":{"start":{"line":83,"column":8},"end":{"line":83,"column":71}},"61":{"start":{"line":83,"column":71},"end":{"line":83,"column":null}},"62":{"start":{"line":85,"column":8},"end":{"line":85,"column":85}},"63":{"start":{"line":85,"column":85},"end":{"line":85,"column":null}},"64":{"start":{"line":87,"column":8},"end":{"line":87,"column":71}},"65":{"start":{"line":87,"column":71},"end":{"line":87,"column":null}},"66":{"start":{"line":89,"column":8},"end":{"line":89,"column":55}},"67":{"start":{"line":89,"column":55},"end":{"line":89,"column":null}},"68":{"start":{"line":91,"column":8},"end":{"line":91,"column":null}},"69":{"start":{"line":92,"column":8},"end":{"line":92,"column":null}},"70":{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},"71":{"start":{"line":97,"column":6},"end":{"line":97,"column":null}},"72":{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},"73":{"start":{"line":99,"column":6},"end":{"line":99,"column":null}},"74":{"start":{"line":100,"column":6},"end":{"line":102,"column":null}},"75":{"start":{"line":101,"column":8},"end":{"line":101,"column":null}},"76":{"start":{"line":103,"column":6},"end":{"line":103,"column":null}},"77":{"start":{"line":105,"column":6},"end":{"line":105,"column":null}},"78":{"start":{"line":106,"column":6},"end":{"line":106,"column":null}},"79":{"start":{"line":109,"column":4},"end":{"line":109,"column":null}},"80":{"start":{"line":112,"column":2},"end":{"line":112,"column":30}},"81":{"start":{"line":114,"column":23},"end":{"line":118,"column":3}},"82":{"start":{"line":120,"column":2},"end":{"line":122,"column":null}},"83":{"start":{"line":121,"column":4},"end":{"line":121,"column":null}},"84":{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},"85":{"start":{"line":126,"column":4},"end":{"line":126,"column":null}},"86":{"start":{"line":128,"column":4},"end":{"line":130,"column":null}},"87":{"start":{"line":129,"column":6},"end":{"line":129,"column":null}},"88":{"start":{"line":132,"column":4},"end":{"line":141,"column":null}},"89":{"start":{"line":133,"column":38},"end":{"line":133,"column":50}},"90":{"start":{"line":134,"column":20},"end":{"line":134,"column":31}},"91":{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},"92":{"start":{"line":136,"column":8},"end":{"line":136,"column":null}},"93":{"start":{"line":137,"column":13},"end":{"line":139,"column":null}},"94":{"start":{"line":138,"column":8},"end":{"line":138,"column":null}},"95":{"start":{"line":140,"column":6},"end":{"line":140,"column":null}},"96":{"start":{"line":144,"column":2},"end":{"line":144,"column":25}},"97":{"start":{"line":145,"column":1},"end":{"line":145,"column":null}},"98":{"start":{"line":147,"column":32},"end":{"line":152,"column":1}},"99":{"start":{"line":148,"column":2},"end":{"line":151,"column":null}},"100":{"start":{"line":149,"column":23},"end":{"line":149,"column":53}},"101":{"start":{"line":150,"column":4},"end":{"line":150,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":23,"column":18},"end":{"line":23,"column":30}},"loc":{"start":{"line":23,"column":30},"end":{"line":145,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":147,"column":32},"end":{"line":147,"column":39}},"loc":{"start":{"line":147,"column":58},"end":{"line":152,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"1":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"cond-expr","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"2":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"binary-expr","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"3":{"loc":{"start":{"line":26,"column":15},"end":{"line":26,"column":41}},"type":"binary-expr","locations":[{"start":{"line":26,"column":15},"end":{"line":26,"column":35}},{"start":{"line":26,"column":39},"end":{"line":26,"column":41}}]},"4":{"loc":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":4},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":50,"column":2},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":50,"column":2},"end":{"line":52,"column":null}}]},"6":{"loc":{"start":{"line":61,"column":4},"end":{"line":94,"column":null}},"type":"switch","locations":[{"start":{"line":62,"column":6},"end":{"line":63,"column":null}},{"start":{"line":64,"column":6},"end":{"line":65,"column":null}},{"start":{"line":66,"column":6},"end":{"line":67,"column":null}},{"start":{"line":68,"column":6},"end":{"line":69,"column":null}},{"start":{"line":70,"column":6},"end":{"line":71,"column":null}},{"start":{"line":72,"column":6},"end":{"line":76,"column":null}},{"start":{"line":77,"column":6},"end":{"line":79,"column":15}},{"start":{"line":80,"column":6},"end":{"line":81,"column":null}},{"start":{"line":82,"column":6},"end":{"line":83,"column":null}},{"start":{"line":84,"column":6},"end":{"line":85,"column":null}},{"start":{"line":86,"column":6},"end":{"line":87,"column":null}},{"start":{"line":88,"column":6},"end":{"line":89,"column":null}},{"start":{"line":90,"column":6},"end":{"line":92,"column":null}}]},"7":{"loc":{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},{"start":{"line":98,"column":11},"end":{"line":107,"column":null}}]},"8":{"loc":{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},{"start":{"line":104,"column":11},"end":{"line":107,"column":null}}]},"9":{"loc":{"start":{"line":100,"column":6},"end":{"line":102,"column":null}},"type":"if","locations":[{"start":{"line":100,"column":6},"end":{"line":102,"column":null}}]},"10":{"loc":{"start":{"line":106,"column":17},"end":{"line":106,"column":33}},"type":"binary-expr","locations":[{"start":{"line":106,"column":17},"end":{"line":106,"column":27}},{"start":{"line":106,"column":31},"end":{"line":106,"column":33}}]},"11":{"loc":{"start":{"line":115,"column":14},"end":{"line":115,"column":48}},"type":"binary-expr","locations":[{"start":{"line":115,"column":14},"end":{"line":115,"column":28}},{"start":{"line":115,"column":32},"end":{"line":115,"column":48}}]},"12":{"loc":{"start":{"line":116,"column":14},"end":{"line":116,"column":83}},"type":"cond-expr","locations":[{"start":{"line":116,"column":31},"end":{"line":116,"column":38}},{"start":{"line":116,"column":42},"end":{"line":116,"column":83}}]},"13":{"loc":{"start":{"line":116,"column":42},"end":{"line":116,"column":83}},"type":"cond-expr","locations":[{"start":{"line":116,"column":61},"end":{"line":116,"column":70}},{"start":{"line":116,"column":73},"end":{"line":116,"column":83}}]},"14":{"loc":{"start":{"line":120,"column":2},"end":{"line":122,"column":null}},"type":"if","locations":[{"start":{"line":120,"column":2},"end":{"line":122,"column":null}}]},"15":{"loc":{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},"type":"if","locations":[{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},{"start":{"line":127,"column":9},"end":{"line":142,"column":null}}]},"16":{"loc":{"start":{"line":125,"column":6},"end":{"line":125,"column":44}},"type":"binary-expr","locations":[{"start":{"line":125,"column":6},"end":{"line":125,"column":23}},{"start":{"line":125,"column":27},"end":{"line":125,"column":44}}]},"17":{"loc":{"start":{"line":128,"column":4},"end":{"line":130,"column":null}},"type":"if","locations":[{"start":{"line":128,"column":4},"end":{"line":130,"column":null}}]},"18":{"loc":{"start":{"line":132,"column":4},"end":{"line":141,"column":null}},"type":"if","locations":[{"start":{"line":132,"column":4},"end":{"line":141,"column":null}}]},"19":{"loc":{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},{"start":{"line":137,"column":13},"end":{"line":139,"column":null}}]},"20":{"loc":{"start":{"line":137,"column":13},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":137,"column":13},"end":{"line":139,"column":null}}]},"21":{"loc":{"start":{"line":148,"column":2},"end":{"line":151,"column":null}},"type":"if","locations":[{"start":{"line":148,"column":2},"end":{"line":151,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0],"5":[0],"6":[0,0,0,0,0,0,0,0,0,0,0,0,0],"7":[0,0],"8":[0,0],"9":[0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0],"15":[0,0],"16":[0,0],"17":[0],"18":[0],"19":[0,0],"20":[0],"21":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/constants.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/constants.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}},"1":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"2":{"start":{"line":3,"column":18},"end":{"line":3,"column":46}},"3":{"start":{"line":5,"column":19},"end":{"line":5,"column":58}},"4":{"start":{"line":7,"column":13},"end":{"line":7,"column":90}},"5":{"start":{"line":9,"column":23},"end":{"line":31,"column":null}},"6":{"start":{"line":34,"column":19},"end":{"line":38,"column":1}},"7":{"start":{"line":40,"column":26},"end":{"line":43,"column":1}},"8":{"start":{"line":45,"column":13},"end":{"line":346,"column":1}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"if","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]},"1":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]},"2":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"binary-expr","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0},"f":{"0":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/check-authentication.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-authentication.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":71}},"2":{"start":{"line":5,"column":28},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":22},"end":{"line":6,"column":57}},"4":{"start":{"line":8,"column":19},"end":{"line":8,"column":48}},"5":{"start":{"line":9,"column":29},"end":{"line":9,"column":55}},"6":{"start":{"line":10,"column":2},"end":{"line":10,"column":42}},"7":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":28},"end":{"line":5,"column":35}},"loc":{"start":{"line":5,"column":46},"end":{"line":11,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/cli/lib/check-format.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-format.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":21},"end":{"line":7,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":6,"column":null}},"3":{"start":{"line":5,"column":4},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":1},"end":{"line":7,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":21},"end":{"line":3,"column":27}},"loc":{"start":{"line":3,"column":32},"end":{"line":7,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":2},"end":{"line":6,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":2},"end":{"line":6,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":6},"end":{"line":4,"column":61}},"type":"binary-expr","locations":[{"start":{"line":4,"column":6},"end":{"line":4,"column":26}},{"start":{"line":4,"column":30},"end":{"line":4,"column":61}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0},"f":{"0":0},"b":{"0":[0],"1":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/check-reminders.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-reminders.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":21,"column":1}},"2":{"start":{"line":4,"column":14},"end":{"line":4,"column":34}},"3":{"start":{"line":5,"column":27},"end":{"line":8,"column":4}},"4":{"start":{"line":6,"column":29},"end":{"line":6,"column":52}},"5":{"start":{"line":7,"column":4},"end":{"line":7,"column":null}},"6":{"start":{"line":10,"column":2},"end":{"line":20,"column":null}},"7":{"start":{"line":11,"column":24},"end":{"line":11,"column":50}},"8":{"start":{"line":12,"column":19},"end":{"line":12,"column":91}},"9":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"10":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"13":{"start":{"line":21,"column":1},"end":{"line":21,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":42},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":5,"column":44},"end":{"line":5,"column":45}},"loc":{"start":{"line":5,"column":65},"end":{"line":8,"column":3}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":15,"column":29},"end":{"line":15,"column":30}},"loc":{"start":{"line":15,"column":46},"end":{"line":17,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":2},"end":{"line":20,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":2},"end":{"line":20,"column":null}}]},"1":{"loc":{"start":{"line":12,"column":49},"end":{"line":12,"column":90}},"type":"cond-expr","locations":[{"start":{"line":12,"column":80},"end":{"line":12,"column":84}},{"start":{"line":12,"column":87},"end":{"line":12,"column":90}}]},"2":{"loc":{"start":{"line":16,"column":28},"end":{"line":16,"column":70}},"type":"cond-expr","locations":[{"start":{"line":16,"column":58},"end":{"line":16,"column":65}},{"start":{"line":16,"column":68},"end":{"line":16,"column":70}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/get-global-options.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-global-options.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":25},"end":{"line":32,"column":1}},"4":{"start":{"line":9,"column":2},"end":{"line":11,"column":3}},"5":{"start":{"line":10,"column":4},"end":{"line":10,"column":null}},"6":{"start":{"line":13,"column":25},"end":{"line":13,"column":52}},"7":{"start":{"line":15,"column":26},"end":{"line":15,"column":80}},"8":{"start":{"line":16,"column":2},"end":{"line":16,"column":34}},"9":{"start":{"line":18,"column":24},"end":{"line":18,"column":74}},"10":{"start":{"line":20,"column":30},"end":{"line":20,"column":43}},"11":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"12":{"start":{"line":24,"column":18},"end":{"line":24,"column":31}},"13":{"start":{"line":26,"column":2},"end":{"line":26,"column":null}},"14":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"15":{"start":{"line":29,"column":2},"end":{"line":29,"column":null}},"16":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"17":{"start":{"line":32,"column":1},"end":{"line":32,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":25},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":37},"end":{"line":32,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":2},"end":{"line":11,"column":3}},"type":"if","locations":[{"start":{"line":9,"column":2},"end":{"line":11,"column":3}}]},"1":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":52}},"type":"binary-expr","locations":[{"start":{"line":13,"column":25},"end":{"line":13,"column":46}},{"start":{"line":13,"column":50},"end":{"line":13,"column":52}}]},"2":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":46}},"type":"cond-expr","locations":[{"start":{"line":13,"column":36},"end":{"line":13,"column":38}},{"start":{"line":13,"column":25},"end":{"line":13,"column":46}}]},"3":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":38}},"type":"binary-expr","locations":[{"start":{"line":13,"column":25},"end":{"line":13,"column":29}},{"start":{"line":13,"column":25},"end":{"line":13,"column":29}},{"start":{"line":13,"column":27},"end":{"line":13,"column":38}},{"start":{"line":13,"column":36},"end":{"line":13,"column":38}}]},"4":{"loc":{"start":{"line":26,"column":10},"end":{"line":26,"column":105}},"type":"binary-expr","locations":[{"start":{"line":26,"column":10},"end":{"line":26,"column":15}},{"start":{"line":26,"column":20},"end":{"line":26,"column":36}},{"start":{"line":26,"column":41},"end":{"line":26,"column":58}},{"start":{"line":26,"column":62},"end":{"line":26,"column":79}},{"start":{"line":26,"column":83},"end":{"line":26,"column":103}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0,0,0,0],"4":[0,0,0,0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/get-options-spec.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-options-spec.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":13,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":4,"column":null}},"3":{"start":{"line":4,"column":79},"end":{"line":4,"column":96}},"4":{"start":{"line":6,"column":4},"end":{"line":9,"column":null}},"5":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"6":{"start":{"line":13,"column":1},"end":{"line":13,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":59},"end":{"line":13,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":4,"column":54},"end":{"line":4,"column":55}},"loc":{"start":{"line":4,"column":79},"end":{"line":4,"column":96}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":16},"end":{"line":4,"column":113}},"type":"binary-expr","locations":[{"start":{"line":4,"column":16},"end":{"line":4,"column":27}},{"start":{"line":4,"column":31},"end":{"line":4,"column":107}},{"start":{"line":4,"column":111},"end":{"line":4,"column":113}}]},"1":{"loc":{"start":{"line":4,"column":31},"end":{"line":4,"column":107}},"type":"cond-expr","locations":[{"start":{"line":4,"column":38},"end":{"line":4,"column":40}},{"start":{"line":4,"column":31},"end":{"line":4,"column":107}}]},"2":{"loc":{"start":{"line":4,"column":31},"end":{"line":4,"column":40}},"type":"binary-expr","locations":[{"start":{"line":4,"column":31},"end":{"line":4,"column":40}},{"start":{"line":4,"column":31},"end":{"line":4,"column":40}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"f":{"0":0,"1":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/get-site-info.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-site-info.mjs","statementMap":{"0":{"start":{"line":1,"column":20},"end":{"line":12,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":4,"column":null}},"2":{"start":{"line":3,"column":4},"end":{"line":3,"column":null}},"3":{"start":{"line":6,"column":19},"end":{"line":6,"column":39}},"4":{"start":{"line":7,"column":2},"end":{"line":9,"column":null}},"5":{"start":{"line":8,"column":4},"end":{"line":8,"column":null}},"6":{"start":{"line":11,"column":2},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":1},"end":{"line":12,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":20},"end":{"line":1,"column":21}},"loc":{"start":{"line":1,"column":44},"end":{"line":12,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":4,"column":null}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":4,"column":null}}]},"1":{"loc":{"start":{"line":7,"column":2},"end":{"line":9,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":2},"end":{"line":9,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{"0":[0],"1":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/get-value-container-and-key.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-value-container-and-key.mjs","statementMap":{"0":{"start":{"line":1,"column":32},"end":{"line":46,"column":1}},"1":{"start":{"line":2,"column":19},"end":{"line":2,"column":80}},"2":{"start":{"line":3,"column":2},"end":{"line":5,"column":null}},"3":{"start":{"line":4,"column":4},"end":{"line":4,"column":null}},"4":{"start":{"line":7,"column":2},"end":{"line":45,"column":null}},"5":{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},"6":{"start":{"line":10,"column":6},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},"8":{"start":{"line":12,"column":40},"end":{"line":12,"column":48}},"9":{"start":{"line":13,"column":8},"end":{"line":18,"column":null}},"10":{"start":{"line":14,"column":10},"end":{"line":17,"column":null}},"11":{"start":{"line":19,"column":8},"end":{"line":24,"column":null}},"12":{"start":{"line":20,"column":10},"end":{"line":23,"column":null}},"13":{"start":{"line":26,"column":8},"end":{"line":28,"column":null}},"14":{"start":{"line":27,"column":10},"end":{"line":27,"column":null}},"15":{"start":{"line":30,"column":8},"end":{"line":30,"column":null}},"16":{"start":{"line":33,"column":6},"end":{"line":33,"column":null}},"17":{"start":{"line":35,"column":23},"end":{"line":35,"column":34}},"18":{"start":{"line":36,"column":6},"end":{"line":38,"column":null}},"19":{"start":{"line":37,"column":8},"end":{"line":37,"column":null}},"20":{"start":{"line":39,"column":24},"end":{"line":39,"column":42}},"21":{"start":{"line":40,"column":6},"end":{"line":42,"column":null}},"22":{"start":{"line":41,"column":8},"end":{"line":41,"column":null}},"23":{"start":{"line":43,"column":6},"end":{"line":43,"column":null}},"24":{"start":{"line":46,"column":1},"end":{"line":46,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":32},"end":{"line":1,"column":33}},"loc":{"start":{"line":1,"column":102},"end":{"line":46,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":7,"column":21},"end":{"line":7,"column":22}},"loc":{"start":{"line":7,"column":60},"end":{"line":45,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":20},"end":{"line":2,"column":62}},"type":"cond-expr","locations":[{"start":{"line":2,"column":47},"end":{"line":2,"column":49}},{"start":{"line":2,"column":52},"end":{"line":2,"column":62}}]},"1":{"loc":{"start":{"line":3,"column":2},"end":{"line":5,"column":null}},"type":"if","locations":[{"start":{"line":3,"column":2},"end":{"line":5,"column":null}}]},"2":{"loc":{"start":{"line":3,"column":6},"end":{"line":3,"column":45}},"type":"binary-expr","locations":[{"start":{"line":3,"column":6},"end":{"line":3,"column":24}},{"start":{"line":3,"column":28},"end":{"line":3,"column":45}}]},"3":{"loc":{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},{"start":{"line":34,"column":11},"end":{"line":44,"column":null}}]},"4":{"loc":{"start":{"line":10,"column":14},"end":{"line":10,"column":32}},"type":"cond-expr","locations":[{"start":{"line":10,"column":25},"end":{"line":10,"column":28}},{"start":{"line":10,"column":17},"end":{"line":10,"column":32}}]},"5":{"loc":{"start":{"line":10,"column":14},"end":{"line":10,"column":28}},"type":"binary-expr","locations":[{"start":{"line":10,"column":14},"end":{"line":10,"column":28}},{"start":{"line":10,"column":25},"end":{"line":10,"column":28}}]},"6":{"loc":{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},{"start":{"line":29,"column":13},"end":{"line":31,"column":null}}]},"7":{"loc":{"start":{"line":13,"column":8},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":8},"end":{"line":18,"column":null}}]},"8":{"loc":{"start":{"line":13,"column":12},"end":{"line":13,"column":61}},"type":"binary-expr","locations":[{"start":{"line":13,"column":12},"end":{"line":13,"column":36}},{"start":{"line":13,"column":40},"end":{"line":13,"column":61}}]},"9":{"loc":{"start":{"line":19,"column":8},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":8},"end":{"line":24,"column":null}}]},"10":{"loc":{"start":{"line":19,"column":12},"end":{"line":19,"column":67}},"type":"binary-expr","locations":[{"start":{"line":19,"column":12},"end":{"line":19,"column":33}},{"start":{"line":19,"column":37},"end":{"line":19,"column":67}}]},"11":{"loc":{"start":{"line":19,"column":37},"end":{"line":19,"column":58}},"type":"cond-expr","locations":[{"start":{"line":19,"column":42},"end":{"line":19,"column":44}},{"start":{"line":19,"column":37},"end":{"line":19,"column":58}}]},"12":{"loc":{"start":{"line":19,"column":37},"end":{"line":19,"column":44}},"type":"binary-expr","locations":[{"start":{"line":19,"column":37},"end":{"line":19,"column":44}},{"start":{"line":19,"column":37},"end":{"line":19,"column":44}}]},"13":{"loc":{"start":{"line":26,"column":8},"end":{"line":28,"column":null}},"type":"if","locations":[{"start":{"line":26,"column":8},"end":{"line":28,"column":null}}]},"14":{"loc":{"start":{"line":26,"column":12},"end":{"line":26,"column":85}},"type":"binary-expr","locations":[{"start":{"line":26,"column":12},"end":{"line":26,"column":35}},{"start":{"line":26,"column":39},"end":{"line":26,"column":63}},{"start":{"line":26,"column":67},"end":{"line":26,"column":85}}]},"15":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":34}},"type":"cond-expr","locations":[{"start":{"line":35,"column":27},"end":{"line":35,"column":30}},{"start":{"line":35,"column":23},"end":{"line":35,"column":34}}]},"16":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":30}},"type":"binary-expr","locations":[{"start":{"line":35,"column":23},"end":{"line":35,"column":30}},{"start":{"line":35,"column":23},"end":{"line":35,"column":30}}]},"17":{"loc":{"start":{"line":36,"column":6},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":6},"end":{"line":38,"column":null}}]},"18":{"loc":{"start":{"line":36,"column":10},"end":{"line":36,"column":41}},"type":"binary-expr","locations":[{"start":{"line":36,"column":10},"end":{"line":36,"column":32}},{"start":{"line":36,"column":36},"end":{"line":36,"column":41}}]},"19":{"loc":{"start":{"line":40,"column":6},"end":{"line":42,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":6},"end":{"line":42,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0,0],"9":[0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0],"14":[0,0,0],"15":[0,0],"16":[0,0],"17":[0],"18":[0,0],"19":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-cleanup.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-cleanup.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":22},"end":{"line":48,"column":1}},"6":{"start":{"line":9,"column":29},"end":{"line":9,"column":74}},"7":{"start":{"line":10,"column":25},"end":{"line":10,"column":70}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":50}},"9":{"start":{"line":12,"column":19},"end":{"line":12,"column":33}},"10":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"11":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"12":{"start":{"line":18,"column":31},"end":{"line":20,"column":18}},"13":{"start":{"line":22,"column":24},"end":{"line":26,"column":6}},"14":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"15":{"start":{"line":25,"column":6},"end":{"line":25,"column":null}},"16":{"start":{"line":28,"column":2},"end":{"line":28,"column":null}},"17":{"start":{"line":29,"column":21},"end":{"line":29,"column":71}},"18":{"start":{"line":29,"column":39},"end":{"line":29,"column":64}},"19":{"start":{"line":30,"column":25},"end":{"line":30,"column":57}},"20":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"21":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"22":{"start":{"line":34,"column":2},"end":{"line":41,"column":null}},"23":{"start":{"line":35,"column":26},"end":{"line":35,"column":43}},"24":{"start":{"line":36,"column":4},"end":{"line":36,"column":null}},"25":{"start":{"line":37,"column":4},"end":{"line":40,"column":null}},"26":{"start":{"line":38,"column":6},"end":{"line":38,"column":null}},"27":{"start":{"line":39,"column":6},"end":{"line":39,"column":null}},"28":{"start":{"line":39,"column":81},"end":{"line":39,"column":106}},"29":{"start":{"line":43,"column":22},"end":{"line":45,"column":84}},"30":{"start":{"line":47,"column":2},"end":{"line":47,"column":null}},"31":{"start":{"line":48,"column":1},"end":{"line":48,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":22},"end":{"line":8,"column":29}},"loc":{"start":{"line":8,"column":46},"end":{"line":48,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":23,"column":10},"end":{"line":23,"column":20}},"loc":{"start":{"line":23,"column":25},"end":{"line":26,"column":5}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":29,"column":33},"end":{"line":29,"column":39}},"loc":{"start":{"line":29,"column":39},"end":{"line":29,"column":64}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":34,"column":31},"end":{"line":34,"column":32}},"loc":{"start":{"line":34,"column":50},"end":{"line":41,"column":3}}},"4":{"name":"(anonymous_4)","decl":{"start":{"line":39,"column":49},"end":{"line":39,"column":50}},"loc":{"start":{"line":39,"column":81},"end":{"line":39,"column":106}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":16,"column":null}}]},"1":{"loc":{"start":{"line":15,"column":20},"end":{"line":15,"column":52}},"type":"binary-expr","locations":[{"start":{"line":15,"column":20},"end":{"line":15,"column":45}},{"start":{"line":15,"column":49},"end":{"line":15,"column":52}}]},"2":{"loc":{"start":{"line":18,"column":31},"end":{"line":20,"column":18}},"type":"cond-expr","locations":[{"start":{"line":19,"column":6},"end":{"line":19,"column":31}},{"start":{"line":20,"column":6},"end":{"line":20,"column":18}}]},"3":{"loc":{"start":{"line":36,"column":43},"end":{"line":36,"column":94}},"type":"cond-expr","locations":[{"start":{"line":36,"column":68},"end":{"line":36,"column":77}},{"start":{"line":36,"column":80},"end":{"line":36,"column":94}}]},"4":{"loc":{"start":{"line":37,"column":4},"end":{"line":40,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":4},"end":{"line":40,"column":null}}]},"5":{"loc":{"start":{"line":43,"column":22},"end":{"line":45,"column":84}},"type":"cond-expr","locations":[{"start":{"line":44,"column":7},"end":{"line":44,"column":72}},{"start":{"line":45,"column":7},"end":{"line":45,"column":84}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0],"5":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-configuration.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-configuration.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":22,"column":1}},"6":{"start":{"line":9,"column":35},"end":{"line":9,"column":86}},"7":{"start":{"line":10,"column":31},"end":{"line":10,"column":109}},"8":{"start":{"line":11,"column":25},"end":{"line":11,"column":45}},"9":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"10":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":8,"column":52},"end":{"line":22,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":9},"end":{"line":12,"column":44}},"type":"binary-expr","locations":[{"start":{"line":12,"column":9},"end":{"line":12,"column":38}},{"start":{"line":12,"column":42},"end":{"line":12,"column":44}}]},"1":{"loc":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"type":"switch","locations":[{"start":{"line":15,"column":4},"end":{"line":16,"column":null}},{"start":{"line":17,"column":4},"end":{"line":18,"column":null}},{"start":{"line":19,"column":4},"end":{"line":20,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-create.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-create.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"9":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"10":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"11":{"start":{"line":14,"column":0},"end":{"line":14,"column":65}},"12":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"13":{"start":{"line":16,"column":21},"end":{"line":128,"column":1}},"14":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"15":{"start":{"line":19,"column":28},"end":{"line":19,"column":72}},"16":{"start":{"line":20,"column":24},"end":{"line":20,"column":68}},"17":{"start":{"line":22,"column":28},"end":{"line":22,"column":65}},"18":{"start":{"line":24,"column":19},"end":{"line":24,"column":47}},"19":{"start":{"line":25,"column":21},"end":{"line":25,"column":49}},"20":{"start":{"line":26,"column":18},"end":{"line":26,"column":43}},"21":{"start":{"line":27,"column":24},"end":{"line":27,"column":55}},"22":{"start":{"line":29,"column":19},"end":{"line":29,"column":47}},"23":{"start":{"line":30,"column":19},"end":{"line":30,"column":47}},"24":{"start":{"line":31,"column":18},"end":{"line":31,"column":45}},"25":{"start":{"line":32,"column":18},"end":{"line":32,"column":64}},"26":{"start":{"line":34,"column":2},"end":{"line":48,"column":null}},"27":{"start":{"line":35,"column":32},"end":{"line":35,"column":72}},"28":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"29":{"start":{"line":37,"column":6},"end":{"line":37,"column":null}},"30":{"start":{"line":39,"column":4},"end":{"line":41,"column":null}},"31":{"start":{"line":40,"column":6},"end":{"line":40,"column":null}},"32":{"start":{"line":42,"column":4},"end":{"line":47,"column":null}},"33":{"start":{"line":43,"column":25},"end":{"line":43,"column":89}},"34":{"start":{"line":44,"column":6},"end":{"line":44,"column":null}},"35":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"36":{"start":{"line":49,"column":2},"end":{"line":49,"column":null}},"37":{"start":{"line":52,"column":19},"end":{"line":52,"column":93}},"38":{"start":{"line":53,"column":2},"end":{"line":53,"column":null}},"39":{"start":{"line":54,"column":2},"end":{"line":56,"column":null}},"40":{"start":{"line":55,"column":4},"end":{"line":55,"column":null}},"41":{"start":{"line":58,"column":2},"end":{"line":58,"column":null}},"42":{"start":{"line":61,"column":2},"end":{"line":66,"column":null}},"43":{"start":{"line":62,"column":4},"end":{"line":65,"column":null}},"44":{"start":{"line":63,"column":6},"end":{"line":63,"column":null}},"45":{"start":{"line":69,"column":2},"end":{"line":69,"column":null}},"46":{"start":{"line":71,"column":2},"end":{"line":74,"column":null}},"47":{"start":{"line":73,"column":4},"end":{"line":73,"column":null}},"48":{"start":{"line":76,"column":2},"end":{"line":109,"column":null}},"49":{"start":{"line":77,"column":4},"end":{"line":108,"column":null}},"50":{"start":{"line":78,"column":60},"end":{"line":78,"column":66}},"51":{"start":{"line":79,"column":34},"end":{"line":84,"column":7}},"52":{"start":{"line":85,"column":25},"end":{"line":85,"column":89}},"53":{"start":{"line":86,"column":6},"end":{"line":86,"column":null}},"54":{"start":{"line":87,"column":21},"end":{"line":87,"column":67}},"55":{"start":{"line":89,"column":6},"end":{"line":107,"column":null}},"56":{"start":{"line":90,"column":36},"end":{"line":90,"column":52}},"57":{"start":{"line":91,"column":8},"end":{"line":103,"column":null}},"58":{"start":{"line":92,"column":109},"end":{"line":92,"column":119}},"59":{"start":{"line":93,"column":31},"end":{"line":101,"column":11}},"60":{"start":{"line":102,"column":10},"end":{"line":102,"column":null}},"61":{"start":{"line":104,"column":27},"end":{"line":104,"column":91}},"62":{"start":{"line":105,"column":8},"end":{"line":105,"column":null}},"63":{"start":{"line":106,"column":8},"end":{"line":106,"column":null}},"64":{"start":{"line":106,"column":74},"end":{"line":106,"column":116}},"65":{"start":{"line":111,"column":2},"end":{"line":111,"column":null}},"66":{"start":{"line":114,"column":2},"end":{"line":118,"column":null}},"67":{"start":{"line":115,"column":4},"end":{"line":117,"column":null}},"68":{"start":{"line":116,"column":6},"end":{"line":116,"column":null}},"69":{"start":{"line":121,"column":2},"end":{"line":121,"column":null}},"70":{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},"71":{"start":{"line":124,"column":4},"end":{"line":124,"column":null}},"72":{"start":{"line":126,"column":4},"end":{"line":126,"column":null}},"73":{"start":{"line":128,"column":1},"end":{"line":128,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":16,"column":21},"end":{"line":16,"column":28}},"loc":{"start":{"line":16,"column":45},"end":{"line":128,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":106,"column":47},"end":{"line":106,"column":48}},"loc":{"start":{"line":106,"column":74},"end":{"line":106,"column":116}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"1":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"cond-expr","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"binary-expr","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"3":{"loc":{"start":{"line":34,"column":2},"end":{"line":48,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":48,"column":null}}]},"4":{"loc":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":4},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":39,"column":4},"end":{"line":41,"column":null}},"type":"if","locations":[{"start":{"line":39,"column":4},"end":{"line":41,"column":null}}]},"6":{"loc":{"start":{"line":42,"column":4},"end":{"line":47,"column":null}},"type":"if","locations":[{"start":{"line":42,"column":4},"end":{"line":47,"column":null}}]},"7":{"loc":{"start":{"line":46,"column":9},"end":{"line":46,"column":32}},"type":"default-arg","locations":[{"start":{"line":46,"column":22},"end":{"line":46,"column":32}}]},"8":{"loc":{"start":{"line":46,"column":34},"end":{"line":46,"column":58}},"type":"default-arg","locations":[{"start":{"line":46,"column":47},"end":{"line":46,"column":58}}]},"9":{"loc":{"start":{"line":52,"column":19},"end":{"line":52,"column":93}},"type":"binary-expr","locations":[{"start":{"line":52,"column":19},"end":{"line":52,"column":39}},{"start":{"line":52,"column":43},"end":{"line":52,"column":93}}]},"10":{"loc":{"start":{"line":53,"column":20},"end":{"line":53,"column":74}},"type":"binary-expr","locations":[{"start":{"line":53,"column":20},"end":{"line":53,"column":40}},{"start":{"line":53,"column":44},"end":{"line":53,"column":59}},{"start":{"line":53,"column":63},"end":{"line":53,"column":74}}]},"11":{"loc":{"start":{"line":54,"column":2},"end":{"line":56,"column":null}},"type":"if","locations":[{"start":{"line":54,"column":2},"end":{"line":56,"column":null}}]},"12":{"loc":{"start":{"line":62,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":62,"column":4},"end":{"line":65,"column":null}}]},"13":{"loc":{"start":{"line":71,"column":2},"end":{"line":74,"column":null}},"type":"if","locations":[{"start":{"line":71,"column":2},"end":{"line":74,"column":null}}]},"14":{"loc":{"start":{"line":71,"column":6},"end":{"line":71,"column":71}},"type":"binary-expr","locations":[{"start":{"line":71,"column":6},"end":{"line":71,"column":30}},{"start":{"line":71,"column":34},"end":{"line":71,"column":71}}]},"15":{"loc":{"start":{"line":76,"column":2},"end":{"line":109,"column":null}},"type":"if","locations":[{"start":{"line":76,"column":2},"end":{"line":109,"column":null}}]},"16":{"loc":{"start":{"line":76,"column":6},"end":{"line":76,"column":52}},"type":"binary-expr","locations":[{"start":{"line":76,"column":6},"end":{"line":76,"column":26}},{"start":{"line":76,"column":30},"end":{"line":76,"column":52}}]},"17":{"loc":{"start":{"line":89,"column":6},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":89,"column":6},"end":{"line":107,"column":null}}]},"18":{"loc":{"start":{"line":92,"column":89},"end":{"line":92,"column":105}},"type":"default-arg","locations":[{"start":{"line":92,"column":96},"end":{"line":92,"column":105}}]},"19":{"loc":{"start":{"line":115,"column":4},"end":{"line":117,"column":null}},"type":"if","locations":[{"start":{"line":115,"column":4},"end":{"line":117,"column":null}}]},"20":{"loc":{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},"type":"if","locations":[{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},{"start":{"line":125,"column":9},"end":{"line":127,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0],"5":[0],"6":[0],"7":[0],"8":[0],"9":[0,0],"10":[0,0,0],"11":[0],"12":[0],"13":[0],"14":[0,0],"15":[0],"16":[0,0],"17":[0],"18":[0],"19":[0],"20":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-destroy.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-destroy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"7":{"start":{"line":10,"column":22},"end":{"line":55,"column":1}},"8":{"start":{"line":11,"column":29},"end":{"line":11,"column":74}},"9":{"start":{"line":12,"column":25},"end":{"line":12,"column":70}},"10":{"start":{"line":13,"column":21},"end":{"line":13,"column":50}},"11":{"start":{"line":14,"column":22},"end":{"line":14,"column":36}},"12":{"start":{"line":16,"column":19},"end":{"line":16,"column":50}},"13":{"start":{"line":18,"column":2},"end":{"line":34,"column":null}},"14":{"start":{"line":19,"column":32},"end":{"line":25,"column":5}},"15":{"start":{"line":26,"column":23},"end":{"line":26,"column":87}},"16":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"17":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"18":{"start":{"line":30,"column":4},"end":{"line":33,"column":null}},"19":{"start":{"line":31,"column":6},"end":{"line":31,"column":null}},"20":{"start":{"line":32,"column":6},"end":{"line":32,"column":null}},"21":{"start":{"line":36,"column":18},"end":{"line":36,"column":65}},"22":{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},"23":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"24":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"25":{"start":{"line":42,"column":16},"end":{"line":42,"column":26}},"26":{"start":{"line":43,"column":24},"end":{"line":43,"column":68}},"27":{"start":{"line":44,"column":4},"end":{"line":44,"column":null}},"28":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"29":{"start":{"line":46,"column":4},"end":{"line":50,"column":null}},"30":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"31":{"start":{"line":53,"column":4},"end":{"line":53,"column":null}},"32":{"start":{"line":55,"column":1},"end":{"line":55,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":10,"column":22},"end":{"line":10,"column":29}},"loc":{"start":{"line":10,"column":46},"end":{"line":55,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":18,"column":2},"end":{"line":34,"column":null}},"type":"if","locations":[{"start":{"line":18,"column":2},"end":{"line":34,"column":null}}]},"1":{"loc":{"start":{"line":30,"column":4},"end":{"line":33,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":4},"end":{"line":33,"column":null}}]},"2":{"loc":{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},"type":"if","locations":[{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},{"start":{"line":41,"column":9},"end":{"line":54,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-detail.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-detail.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":21},"end":{"line":23,"column":1}},"6":{"start":{"line":9,"column":28},"end":{"line":9,"column":72}},"7":{"start":{"line":10,"column":24},"end":{"line":10,"column":68}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":49}},"9":{"start":{"line":12,"column":21},"end":{"line":12,"column":34}},"10":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"11":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"12":{"start":{"line":18,"column":2},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":17},"end":{"line":20,"column":48}},"14":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"15":{"start":{"line":23,"column":1},"end":{"line":23,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":21},"end":{"line":8,"column":22}},"loc":{"start":{"line":8,"column":39},"end":{"line":23,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":16,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-get-iam-policy.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-get-iam-policy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":71}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":26},"end":{"line":228,"column":1}},"7":{"start":{"line":12,"column":22},"end":{"line":12,"column":32}},"8":{"start":{"line":13,"column":2},"end":{"line":16,"column":null}},"9":{"start":{"line":14,"column":24},"end":{"line":14,"column":60}},"10":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"11":{"start":{"line":18,"column":2},"end":{"line":227,"column":null}},"12":{"start":{"line":231,"column":1},"end":{"line":239,"column":31}},"13":{"start":{"line":241,"column":27},"end":{"line":252,"column":1}},"14":{"start":{"line":242,"column":34},"end":{"line":242,"column":86}},"15":{"start":{"line":243,"column":30},"end":{"line":243,"column":80}},"16":{"start":{"line":244,"column":27},"end":{"line":244,"column":67}},"17":{"start":{"line":246,"column":2},"end":{"line":246,"column":null}},"18":{"start":{"line":248,"column":2},"end":{"line":251,"column":null}},"19":{"start":{"line":250,"column":4},"end":{"line":250,"column":null}},"20":{"start":{"line":252,"column":1},"end":{"line":252,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":26},"end":{"line":9,"column":33}},"loc":{"start":{"line":9,"column":40},"end":{"line":228,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":241,"column":27},"end":{"line":241,"column":34}},"loc":{"start":{"line":241,"column":51},"end":{"line":252,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":13,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":16,"column":null}}]},"1":{"loc":{"start":{"line":14,"column":38},"end":{"line":14,"column":59}},"type":"cond-expr","locations":[{"start":{"line":14,"column":49},"end":{"line":14,"column":51}},{"start":{"line":14,"column":39},"end":{"line":14,"column":59}}]},"2":{"loc":{"start":{"line":14,"column":38},"end":{"line":14,"column":51}},"type":"binary-expr","locations":[{"start":{"line":14,"column":38},"end":{"line":14,"column":51}},{"start":{"line":14,"column":49},"end":{"line":14,"column":51}}]},"3":{"loc":{"start":{"line":248,"column":2},"end":{"line":251,"column":null}},"type":"if","locations":[{"start":{"line":248,"column":2},"end":{"line":251,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-import.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-import.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":11,"column":21},"end":{"line":65,"column":1}},"8":{"start":{"line":13,"column":28},"end":{"line":13,"column":72}},"9":{"start":{"line":14,"column":24},"end":{"line":14,"column":68}},"10":{"start":{"line":15,"column":27},"end":{"line":15,"column":62}},"11":{"start":{"line":16,"column":25},"end":{"line":16,"column":58}},"12":{"start":{"line":17,"column":30},"end":{"line":17,"column":43}},"13":{"start":{"line":18,"column":19},"end":{"line":18,"column":47}},"14":{"start":{"line":21,"column":2},"end":{"line":23,"column":null}},"15":{"start":{"line":22,"column":4},"end":{"line":22,"column":null}},"16":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"17":{"start":{"line":26,"column":21},"end":{"line":26,"column":97}},"18":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"19":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"20":{"start":{"line":31,"column":2},"end":{"line":33,"column":null}},"21":{"start":{"line":32,"column":4},"end":{"line":32,"column":null}},"22":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"23":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"24":{"start":{"line":39,"column":2},"end":{"line":45,"column":null}},"25":{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},"26":{"start":{"line":41,"column":6},"end":{"line":41,"column":null}},"27":{"start":{"line":42,"column":11},"end":{"line":44,"column":null}},"28":{"start":{"line":43,"column":6},"end":{"line":43,"column":null}},"29":{"start":{"line":47,"column":20},"end":{"line":47,"column":28}},"30":{"start":{"line":49,"column":2},"end":{"line":51,"column":null}},"31":{"start":{"line":50,"column":4},"end":{"line":50,"column":null}},"32":{"start":{"line":52,"column":2},"end":{"line":54,"column":null}},"33":{"start":{"line":53,"column":4},"end":{"line":53,"column":null}},"34":{"start":{"line":55,"column":2},"end":{"line":57,"column":null}},"35":{"start":{"line":56,"column":4},"end":{"line":56,"column":null}},"36":{"start":{"line":60,"column":18},"end":{"line":60,"column":105}},"37":{"start":{"line":61,"column":2},"end":{"line":61,"column":null}},"38":{"start":{"line":62,"column":2},"end":{"line":62,"column":null}},"39":{"start":{"line":64,"column":2},"end":{"line":64,"column":null}},"40":{"start":{"line":65,"column":1},"end":{"line":65,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":11,"column":21},"end":{"line":11,"column":28}},"loc":{"start":{"line":11,"column":45},"end":{"line":65,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":21,"column":2},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":2},"end":{"line":23,"column":null}}]},"1":{"loc":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":2},"end":{"line":30,"column":null}}]},"2":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":28}},"type":"cond-expr","locations":[{"start":{"line":28,"column":20},"end":{"line":28,"column":22}},{"start":{"line":28,"column":6},"end":{"line":28,"column":28}}]},"3":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":22}},"type":"binary-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":22}},{"start":{"line":28,"column":6},"end":{"line":28,"column":22}}]},"4":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":138}},"type":"binary-expr","locations":[{"start":{"line":29,"column":108},"end":{"line":29,"column":130}},{"start":{"line":29,"column":134},"end":{"line":29,"column":138}}]},"5":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":130}},"type":"cond-expr","locations":[{"start":{"line":29,"column":122},"end":{"line":29,"column":124}},{"start":{"line":29,"column":108},"end":{"line":29,"column":130}}]},"6":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":124}},"type":"binary-expr","locations":[{"start":{"line":29,"column":108},"end":{"line":29,"column":124}},{"start":{"line":29,"column":108},"end":{"line":29,"column":124}}]},"7":{"loc":{"start":{"line":31,"column":2},"end":{"line":33,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":33,"column":null}}]},"8":{"loc":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":36,"column":null}}]},"9":{"loc":{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},{"start":{"line":42,"column":11},"end":{"line":44,"column":null}}]},"10":{"loc":{"start":{"line":42,"column":11},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":42,"column":11},"end":{"line":44,"column":null}}]},"11":{"loc":{"start":{"line":49,"column":2},"end":{"line":51,"column":null}},"type":"if","locations":[{"start":{"line":49,"column":2},"end":{"line":51,"column":null}}]},"12":{"loc":{"start":{"line":49,"column":6},"end":{"line":49,"column":57}},"type":"binary-expr","locations":[{"start":{"line":49,"column":6},"end":{"line":49,"column":37}},{"start":{"line":49,"column":41},"end":{"line":49,"column":57}}]},"13":{"loc":{"start":{"line":52,"column":2},"end":{"line":54,"column":null}},"type":"if","locations":[{"start":{"line":52,"column":2},"end":{"line":54,"column":null}}]},"14":{"loc":{"start":{"line":55,"column":2},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":55,"column":2},"end":{"line":57,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0],"11":[0],"12":[0,0],"13":[0],"14":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-list.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-list.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":22,"column":1}},"5":{"start":{"line":8,"column":26},"end":{"line":8,"column":68}},"6":{"start":{"line":9,"column":22},"end":{"line":9,"column":64}},"7":{"start":{"line":10,"column":20},"end":{"line":10,"column":45}},"8":{"start":{"line":12,"column":25},"end":{"line":12,"column":48}},"9":{"start":{"line":13,"column":17},"end":{"line":19,"column":6}},"10":{"start":{"line":16,"column":22},"end":{"line":16,"column":76}},"11":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":19},"end":{"line":7,"column":20}},"loc":{"start":{"line":7,"column":37},"end":{"line":22,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":15,"column":26},"end":{"line":15,"column":34}},"loc":{"start":{"line":15,"column":39},"end":{"line":19,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":13,"column":17},"end":{"line":19,"column":6}},"type":"cond-expr","locations":[{"start":{"line":14,"column":6},"end":{"line":14,"column":20}},{"start":{"line":15,"column":6},"end":{"line":19,"column":6}}]},"1":{"loc":{"start":{"line":17,"column":36},"end":{"line":17,"column":58}},"type":"binary-expr","locations":[{"start":{"line":17,"column":36},"end":{"line":17,"column":52}},{"start":{"line":17,"column":56},"end":{"line":17,"column":58}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-plugin-settings.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-plugin-settings.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":29},"end":{"line":22,"column":1}},"6":{"start":{"line":9,"column":31},"end":{"line":9,"column":84}},"7":{"start":{"line":10,"column":27},"end":{"line":10,"column":101}},"8":{"start":{"line":11,"column":25},"end":{"line":11,"column":41}},"9":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"10":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":29},"end":{"line":8,"column":36}},"loc":{"start":{"line":8,"column":53},"end":{"line":22,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":9},"end":{"line":12,"column":40}},"type":"binary-expr","locations":[{"start":{"line":12,"column":9},"end":{"line":12,"column":34}},{"start":{"line":12,"column":38},"end":{"line":12,"column":40}}]},"1":{"loc":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"type":"switch","locations":[{"start":{"line":15,"column":4},"end":{"line":16,"column":null}},{"start":{"line":17,"column":4},"end":{"line":18,"column":null}},{"start":{"line":19,"column":4},"end":{"line":20,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-update.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-update.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":21},"end":{"line":24,"column":1}},"6":{"start":{"line":9,"column":28},"end":{"line":9,"column":72}},"7":{"start":{"line":10,"column":24},"end":{"line":10,"column":68}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":49}},"9":{"start":{"line":12,"column":20},"end":{"line":12,"column":47}},"10":{"start":{"line":13,"column":20},"end":{"line":13,"column":47}},"11":{"start":{"line":14,"column":16},"end":{"line":14,"column":39}},"12":{"start":{"line":15,"column":18},"end":{"line":15,"column":43}},"13":{"start":{"line":16,"column":18},"end":{"line":16,"column":43}},"14":{"start":{"line":17,"column":30},"end":{"line":17,"column":68}},"15":{"start":{"line":19,"column":19},"end":{"line":19,"column":50}},"16":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"17":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"18":{"start":{"line":24,"column":1},"end":{"line":24,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":21},"end":{"line":8,"column":28}},"loc":{"start":{"line":8,"column":45},"end":{"line":24,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/cli/lib/handle-verify.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-verify.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":21},"end":{"line":31,"column":1}},"7":{"start":{"line":10,"column":28},"end":{"line":10,"column":72}},"8":{"start":{"line":11,"column":24},"end":{"line":11,"column":68}},"9":{"start":{"line":12,"column":21},"end":{"line":12,"column":34}},"10":{"start":{"line":13,"column":21},"end":{"line":13,"column":49}},"11":{"start":{"line":14,"column":23},"end":{"line":14,"column":53}},"12":{"start":{"line":15,"column":22},"end":{"line":15,"column":52}},"13":{"start":{"line":16,"column":21},"end":{"line":16,"column":49}},"14":{"start":{"line":18,"column":2},"end":{"line":18,"column":null}},"15":{"start":{"line":20,"column":19},"end":{"line":20,"column":50}},"16":{"start":{"line":23,"column":4},"end":{"line":23,"column":73}},"17":{"start":{"line":24,"column":24},"end":{"line":26,"column":15}},"18":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"19":{"start":{"line":25,"column":25},"end":{"line":25,"column":40}},"20":{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},"21":{"start":{"line":25,"column":69},"end":{"line":25,"column":85}},"22":{"start":{"line":25,"column":94},"end":{"line":25,"column":105}},"23":{"start":{"line":28,"column":17},"end":{"line":28,"column":71}},"24":{"start":{"line":30,"column":2},"end":{"line":30,"column":null}},"25":{"start":{"line":31,"column":1},"end":{"line":31,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":21},"end":{"line":9,"column":28}},"loc":{"start":{"line":9,"column":45},"end":{"line":31,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":24,"column":39},"end":{"line":24,"column":40}},"loc":{"start":{"line":24,"column":64},"end":{"line":26,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},{"start":{"line":25,"column":47},"end":{"line":25,"column":null}}]},"1":{"loc":{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},{"start":{"line":25,"column":92},"end":{"line":25,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/options.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/options.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":46}},"4":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"5":{"start":{"line":6,"column":22},"end":{"line":13,"column":4}},"6":{"start":{"line":7,"column":2},"end":{"line":13,"column":4}},"7":{"start":{"line":8,"column":24},"end":{"line":8,"column":45}},"8":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"9":{"start":{"line":10,"column":4},"end":{"line":10,"column":null}},"10":{"start":{"line":12,"column":4},"end":{"line":12,"column":null}},"11":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"12":{"start":{"line":15,"column":29},"end":{"line":67,"column":1}},"13":{"start":{"line":16,"column":2},"end":{"line":66,"column":null}},"14":{"start":{"line":17,"column":21},"end":{"line":17,"column":36}},"15":{"start":{"line":18,"column":23},"end":{"line":18,"column":39}},"16":{"start":{"line":20,"column":19},"end":{"line":20,"column":38}},"17":{"start":{"line":21,"column":4},"end":{"line":23,"column":null}},"18":{"start":{"line":22,"column":6},"end":{"line":22,"column":null}},"19":{"start":{"line":25,"column":4},"end":{"line":27,"column":null}},"20":{"start":{"line":26,"column":6},"end":{"line":26,"column":null}},"21":{"start":{"line":28,"column":23},"end":{"line":28,"column":57}},"22":{"start":{"line":29,"column":4},"end":{"line":29,"column":46}},"23":{"start":{"line":30,"column":27},"end":{"line":30,"column":70}},"24":{"start":{"line":31,"column":4},"end":{"line":31,"column":59}},"25":{"start":{"line":32,"column":17},"end":{"line":32,"column":38}},"26":{"start":{"line":34,"column":41},"end":{"line":41,"column":6}},"27":{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},"28":{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},"29":{"start":{"line":45,"column":31},"end":{"line":45,"column":59}},"30":{"start":{"line":46,"column":8},"end":{"line":46,"column":null}},"31":{"start":{"line":47,"column":8},"end":{"line":47,"column":null}},"32":{"start":{"line":49,"column":8},"end":{"line":49,"column":null}},"33":{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},"34":{"start":{"line":52,"column":23},"end":{"line":52,"column":47}},"35":{"start":{"line":53,"column":6},"end":{"line":53,"column":null}},"36":{"start":{"line":54,"column":6},"end":{"line":54,"column":null}},"37":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"38":{"start":{"line":57,"column":6},"end":{"line":57,"column":null}},"39":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"40":{"start":{"line":64,"column":6},"end":{"line":64,"column":null}},"41":{"start":{"line":67,"column":1},"end":{"line":67,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":6,"column":22},"end":{"line":6,"column":23}},"loc":{"start":{"line":7,"column":2},"end":{"line":13,"column":4}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":7,"column":18},"end":{"line":7,"column":22}},"loc":{"start":{"line":7,"column":27},"end":{"line":13,"column":3}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":15,"column":29},"end":{"line":15,"column":30}},"loc":{"start":{"line":15,"column":77},"end":{"line":67,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"cond-expr","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"2":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"binary-expr","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"3":{"loc":{"start":{"line":6,"column":23},"end":{"line":6,"column":38}},"type":"default-arg","locations":[{"start":{"line":6,"column":36},"end":{"line":6,"column":38}}]},"4":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":52}},"type":"binary-expr","locations":[{"start":{"line":9,"column":12},"end":{"line":9,"column":42}},{"start":{"line":9,"column":46},"end":{"line":9,"column":52}}]},"5":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":42}},"type":"cond-expr","locations":[{"start":{"line":9,"column":17},"end":{"line":9,"column":19}},{"start":{"line":9,"column":12},"end":{"line":9,"column":42}}]},"6":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":19}},"type":"binary-expr","locations":[{"start":{"line":9,"column":12},"end":{"line":9,"column":19}},{"start":{"line":9,"column":17},"end":{"line":9,"column":19}}]},"7":{"loc":{"start":{"line":21,"column":4},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":4},"end":{"line":23,"column":null}}]},"8":{"loc":{"start":{"line":25,"column":4},"end":{"line":27,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":4},"end":{"line":27,"column":null}}]},"9":{"loc":{"start":{"line":28,"column":23},"end":{"line":28,"column":57}},"type":"binary-expr","locations":[{"start":{"line":28,"column":23},"end":{"line":28,"column":51}},{"start":{"line":28,"column":55},"end":{"line":28,"column":57}}]},"10":{"loc":{"start":{"line":30,"column":27},"end":{"line":30,"column":70}},"type":"binary-expr","locations":[{"start":{"line":30,"column":27},"end":{"line":30,"column":64}},{"start":{"line":30,"column":68},"end":{"line":30,"column":70}}]},"11":{"loc":{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},{"start":{"line":51,"column":11},"end":{"line":58,"column":null}}]},"12":{"loc":{"start":{"line":43,"column":8},"end":{"line":43,"column":51}},"type":"binary-expr","locations":[{"start":{"line":43,"column":8},"end":{"line":43,"column":25}},{"start":{"line":43,"column":29},"end":{"line":43,"column":51}}]},"13":{"loc":{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},"type":"if","locations":[{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},{"start":{"line":48,"column":13},"end":{"line":50,"column":null}}]},"14":{"loc":{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},"type":"if","locations":[{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},{"start":{"line":55,"column":11},"end":{"line":58,"column":null}}]},"15":{"loc":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":65,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0,0],"15":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/process-source-type.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/process-source-type.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":26},"end":{"line":15,"column":1}},"4":{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},"5":{"start":{"line":8,"column":33},"end":{"line":8,"column":86}},"6":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":9},"end":{"line":12,"column":null}},"8":{"start":{"line":11,"column":4},"end":{"line":11,"column":null}},"9":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":1},"end":{"line":15,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":26},"end":{"line":6,"column":27}},"loc":{"start":{"line":6,"column":58},"end":{"line":15,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},{"start":{"line":10,"column":9},"end":{"line":12,"column":null}}]},"1":{"loc":{"start":{"line":9,"column":17},"end":{"line":9,"column":76}},"type":"cond-expr","locations":[{"start":{"line":9,"column":52},"end":{"line":9,"column":64}},{"start":{"line":9,"column":67},"end":{"line":9,"column":76}}]},"2":{"loc":{"start":{"line":10,"column":9},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":9},"end":{"line":12,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0],"2":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/smart-convert.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/smart-convert.mjs","statementMap":{"0":{"start":{"line":1,"column":22},"end":{"line":20,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},"2":{"start":{"line":3,"column":4},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},"4":{"start":{"line":5,"column":4},"end":{"line":5,"column":null}},"5":{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},"6":{"start":{"line":7,"column":4},"end":{"line":7,"column":null}},"7":{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},"8":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"9":{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},"10":{"start":{"line":11,"column":4},"end":{"line":11,"column":null}},"11":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"12":{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},"13":{"start":{"line":15,"column":6},"end":{"line":15,"column":null}},"14":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"15":{"start":{"line":20,"column":1},"end":{"line":20,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":22},"end":{"line":1,"column":27}},"loc":{"start":{"line":1,"column":32},"end":{"line":20,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},{"start":{"line":4,"column":9},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},{"start":{"line":6,"column":9},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":4,"column":13},"end":{"line":4,"column":49}},"type":"binary-expr","locations":[{"start":{"line":4,"column":13},"end":{"line":4,"column":29}},{"start":{"line":4,"column":33},"end":{"line":4,"column":49}}]},"3":{"loc":{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},{"start":{"line":8,"column":9},"end":{"line":19,"column":null}}]},"4":{"loc":{"start":{"line":6,"column":13},"end":{"line":6,"column":51}},"type":"binary-expr","locations":[{"start":{"line":6,"column":13},"end":{"line":6,"column":30}},{"start":{"line":6,"column":34},"end":{"line":6,"column":51}}]},"5":{"loc":{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},{"start":{"line":10,"column":9},"end":{"line":19,"column":null}}]},"6":{"loc":{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},{"start":{"line":12,"column":9},"end":{"line":19,"column":null}}]},"7":{"loc":{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},{"start":{"line":16,"column":11},"end":{"line":18,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-initialize.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-initialize.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":38},"end":{"line":34,"column":1}},"3":{"start":{"line":6,"column":30},"end":{"line":26,"column":3}},"4":{"start":{"line":28,"column":21},"end":{"line":28,"column":85}},"5":{"start":{"line":29,"column":2},"end":{"line":29,"column":null}},"6":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"7":{"start":{"line":33,"column":2},"end":{"line":33,"column":null}},"8":{"start":{"line":34,"column":1},"end":{"line":34,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":38},"end":{"line":5,"column":45}},"loc":{"start":{"line":5,"column":56},"end":{"line":34,"column":1}}}},"branchMap":{},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1},"f":{"0":1},"b":{}} +,"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-show.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-show.mjs","statementMap":{"0":{"start":{"line":6,"column":32},"end":{"line":18,"column":1}},"1":{"start":{"line":16,"column":26},"end":{"line":16,"column":51}},"2":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"3":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":32},"end":{"line":6,"column":39}},"loc":{"start":{"line":6,"column":62},"end":{"line":18,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":26},"end":{"line":16,"column":51}},"type":"binary-expr","locations":[{"start":{"line":16,"column":26},"end":{"line":16,"column":45}},{"start":{"line":16,"column":49},"end":{"line":16,"column":51}}]}},"s":{"0":1,"1":1,"2":1,"3":1},"f":{"0":1},"b":{"0":[1,0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":47}},"6":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"7":{"start":{"line":9,"column":32},"end":{"line":45,"column":1}},"8":{"start":{"line":10,"column":24},"end":{"line":13,"column":20}},"9":{"start":{"line":11,"column":33},"end":{"line":11,"column":59}},"10":{"start":{"line":12,"column":33},"end":{"line":12,"column":47}},"11":{"start":{"line":14,"column":39},"end":{"line":14,"column":86}},"12":{"start":{"line":15,"column":35},"end":{"line":15,"column":90}},"13":{"start":{"line":16,"column":21},"end":{"line":16,"column":60}},"14":{"start":{"line":17,"column":18},"end":{"line":17,"column":75}},"15":{"start":{"line":19,"column":55},"end":{"line":19,"column":79}},"16":{"start":{"line":22,"column":19},"end":{"line":22,"column":50}},"17":{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},"18":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"19":{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},"20":{"start":{"line":27,"column":4},"end":{"line":27,"column":56}},"21":{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},"22":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"23":{"start":{"line":30,"column":9},"end":{"line":32,"column":null}},"24":{"start":{"line":31,"column":4},"end":{"line":31,"column":null}},"25":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"26":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"27":{"start":{"line":39,"column":2},"end":{"line":41,"column":null}},"28":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"29":{"start":{"line":42,"column":2},"end":{"line":42,"column":null}},"30":{"start":{"line":44,"column":2},"end":{"line":44,"column":null}},"31":{"start":{"line":45,"column":1},"end":{"line":45,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":9,"column":32},"end":{"line":9,"column":39}},"loc":{"start":{"line":9,"column":56},"end":{"line":45,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":11,"column":19},"end":{"line":11,"column":20}},"loc":{"start":{"line":11,"column":33},"end":{"line":11,"column":59}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":12,"column":19},"end":{"line":12,"column":20}},"loc":{"start":{"line":12,"column":33},"end":{"line":12,"column":47}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"1":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"cond-expr","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"2":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"binary-expr","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"3":{"loc":{"start":{"line":10,"column":24},"end":{"line":13,"column":20}},"type":"binary-expr","locations":[{"start":{"line":10,"column":24},"end":{"line":13,"column":14}},{"start":{"line":13,"column":18},"end":{"line":13,"column":20}}]},"4":{"loc":{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},{"start":{"line":26,"column":9},"end":{"line":32,"column":null}}]},"5":{"loc":{"start":{"line":24,"column":6},"end":{"line":24,"column":69}},"type":"binary-expr","locations":[{"start":{"line":24,"column":6},"end":{"line":24,"column":23}},{"start":{"line":24,"column":27},"end":{"line":24,"column":45}},{"start":{"line":24,"column":49},"end":{"line":24,"column":69}}]},"6":{"loc":{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},{"start":{"line":28,"column":9},"end":{"line":32,"column":null}}]},"7":{"loc":{"start":{"line":26,"column":13},"end":{"line":26,"column":77}},"type":"binary-expr","locations":[{"start":{"line":26,"column":13},"end":{"line":26,"column":31}},{"start":{"line":26,"column":36},"end":{"line":26,"column":55}},{"start":{"line":26,"column":59},"end":{"line":26,"column":76}}]},"8":{"loc":{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},{"start":{"line":30,"column":9},"end":{"line":32,"column":null}}]},"9":{"loc":{"start":{"line":28,"column":13},"end":{"line":28,"column":54}},"type":"binary-expr","locations":[{"start":{"line":28,"column":13},"end":{"line":28,"column":31}},{"start":{"line":28,"column":35},"end":{"line":28,"column":54}}]},"10":{"loc":{"start":{"line":30,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":9},"end":{"line":32,"column":null}}]},"11":{"loc":{"start":{"line":30,"column":13},"end":{"line":30,"column":54}},"type":"binary-expr","locations":[{"start":{"line":30,"column":13},"end":{"line":30,"column":31}},{"start":{"line":30,"column":35},"end":{"line":30,"column":54}}]},"12":{"loc":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":36,"column":null}}]},"13":{"loc":{"start":{"line":34,"column":6},"end":{"line":34,"column":47}},"type":"binary-expr","locations":[{"start":{"line":34,"column":6},"end":{"line":34,"column":23}},{"start":{"line":34,"column":27},"end":{"line":34,"column":47}}]},"14":{"loc":{"start":{"line":39,"column":2},"end":{"line":41,"column":null}},"type":"if","locations":[{"start":{"line":39,"column":2},"end":{"line":41,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0,0],"5":[0,0,0],"6":[0,0],"7":[0,0,0],"8":[0,0],"9":[0,0],"10":[0],"11":[0,0],"12":[0],"13":[0,0],"14":[0]}} +,"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-show.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-show.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":33},"end":{"line":18,"column":1}},"4":{"start":{"line":7,"column":24},"end":{"line":10,"column":20}},"5":{"start":{"line":8,"column":33},"end":{"line":8,"column":59}},"6":{"start":{"line":9,"column":33},"end":{"line":9,"column":48}},"7":{"start":{"line":11,"column":46},"end":{"line":11,"column":93}},"8":{"start":{"line":12,"column":42},"end":{"line":12,"column":104}},"9":{"start":{"line":13,"column":21},"end":{"line":13,"column":67}},"10":{"start":{"line":15,"column":19},"end":{"line":15,"column":47}},"11":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":33},"end":{"line":6,"column":40}},"loc":{"start":{"line":6,"column":57},"end":{"line":18,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":19},"end":{"line":8,"column":20}},"loc":{"start":{"line":8,"column":33},"end":{"line":8,"column":59}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":19},"end":{"line":9,"column":20}},"loc":{"start":{"line":9,"column":33},"end":{"line":9,"column":48}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":24},"end":{"line":10,"column":20}},"type":"binary-expr","locations":[{"start":{"line":7,"column":24},"end":{"line":10,"column":14}},{"start":{"line":10,"column":18},"end":{"line":10,"column":20}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/create.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/create.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"4":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"5":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"8":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"9":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":0},"end":{"line":15,"column":null}},"11":{"start":{"line":16,"column":0},"end":{"line":16,"column":null}},"12":{"start":{"line":17,"column":0},"end":{"line":17,"column":null}},"13":{"start":{"line":18,"column":0},"end":{"line":18,"column":null}},"14":{"start":{"line":19,"column":0},"end":{"line":19,"column":55}},"15":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"16":{"start":{"line":21,"column":29},"end":{"line":21,"column":31}},"17":{"start":{"line":23,"column":15},"end":{"line":86,"column":1}},"18":{"start":{"line":29,"column":25},"end":{"line":29,"column":33}},"19":{"start":{"line":30,"column":23},"end":{"line":30,"column":31}},"20":{"start":{"line":32,"column":22},"end":{"line":32,"column":57}},"21":{"start":{"line":34,"column":20},"end":{"line":37,"column":4}},"22":{"start":{"line":39,"column":35},"end":{"line":39,"column":83}},"23":{"start":{"line":40,"column":2},"end":{"line":44,"column":null}},"24":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"25":{"start":{"line":42,"column":4},"end":{"line":42,"column":null}},"26":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"27":{"start":{"line":45,"column":2},"end":{"line":45,"column":null}},"28":{"start":{"line":47,"column":2},"end":{"line":52,"column":null}},"29":{"start":{"line":48,"column":31},"end":{"line":48,"column":74}},"30":{"start":{"line":50,"column":7},"end":{"line":50,"column":110}},"31":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"32":{"start":{"line":54,"column":2},"end":{"line":54,"column":null}},"33":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"34":{"start":{"line":56,"column":23},"end":{"line":56,"column":90}},"35":{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},"36":{"start":{"line":59,"column":31},"end":{"line":62,"column":73}},"37":{"start":{"line":60,"column":6},"end":{"line":60,"column":null}},"38":{"start":{"line":62,"column":41},"end":{"line":62,"column":72}},"39":{"start":{"line":64,"column":4},"end":{"line":64,"column":52}},"40":{"start":{"line":66,"column":20},"end":{"line":66,"column":40}},"41":{"start":{"line":69,"column":4},"end":{"line":74,"column":null}},"42":{"start":{"line":73,"column":8},"end":{"line":73,"column":71}},"43":{"start":{"line":76,"column":4},"end":{"line":80,"column":null}},"44":{"start":{"line":77,"column":6},"end":{"line":77,"column":null}},"45":{"start":{"line":79,"column":6},"end":{"line":79,"column":null}},"46":{"start":{"line":82,"column":4},"end":{"line":82,"column":null}},"47":{"start":{"line":84,"column":4},"end":{"line":84,"column":null}},"48":{"start":{"line":86,"column":1},"end":{"line":86,"column":null}},"49":{"start":{"line":88,"column":26},"end":{"line":122,"column":1}},"50":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}},"51":{"start":{"line":90,"column":16},"end":{"line":114,"column":3}},"52":{"start":{"line":116,"column":18},"end":{"line":116,"column":54}},"53":{"start":{"line":117,"column":19},"end":{"line":117,"column":48}},"54":{"start":{"line":119,"column":29},"end":{"line":119,"column":37}},"55":{"start":{"line":121,"column":2},"end":{"line":121,"column":null}},"56":{"start":{"line":124,"column":24},"end":{"line":152,"column":1}},"57":{"start":{"line":125,"column":33},"end":{"line":125,"column":41}},"58":{"start":{"line":127,"column":23},"end":{"line":127,"column":66}},"59":{"start":{"line":128,"column":2},"end":{"line":128,"column":null}},"60":{"start":{"line":129,"column":2},"end":{"line":129,"column":null}},"61":{"start":{"line":131,"column":33},"end":{"line":131,"column":54}},"62":{"start":{"line":133,"column":31},"end":{"line":133,"column":80}},"63":{"start":{"line":134,"column":20},"end":{"line":134,"column":90}},"64":{"start":{"line":135,"column":22},"end":{"line":141,"column":3}},"65":{"start":{"line":142,"column":24},"end":{"line":142,"column":59}},"66":{"start":{"line":143,"column":25},"end":{"line":143,"column":71}},"67":{"start":{"line":145,"column":22},"end":{"line":145,"column":36}},"68":{"start":{"line":147,"column":2},"end":{"line":147,"column":null}},"69":{"start":{"line":148,"column":2},"end":{"line":148,"column":null}},"70":{"start":{"line":150,"column":22},"end":{"line":150,"column":100}},"71":{"start":{"line":151,"column":2},"end":{"line":151,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":23,"column":15},"end":{"line":23,"column":22}},"loc":{"start":{"line":28,"column":6},"end":{"line":86,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":59,"column":72},"end":{"line":59,"column":81}},"loc":{"start":{"line":60,"column":6},"end":{"line":60,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":62,"column":14},"end":{"line":62,"column":15}},"loc":{"start":{"line":62,"column":41},"end":{"line":62,"column":72}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":72,"column":33},"end":{"line":72,"column":34}},"loc":{"start":{"line":73,"column":8},"end":{"line":73,"column":71}}},"5":{"name":"(anonymous_7)","decl":{"start":{"line":88,"column":26},"end":{"line":88,"column":33}},"loc":{"start":{"line":88,"column":63},"end":{"line":122,"column":1}}},"6":{"name":"(anonymous_8)","decl":{"start":{"line":124,"column":24},"end":{"line":124,"column":31}},"loc":{"start":{"line":124,"column":80},"end":{"line":152,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"cond-expr","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"binary-expr","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"3":{"loc":{"start":{"line":40,"column":2},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":2},"end":{"line":44,"column":null}}]},"4":{"loc":{"start":{"line":47,"column":2},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":47,"column":2},"end":{"line":52,"column":null}}]},"5":{"loc":{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},"type":"if","locations":[{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},{"start":{"line":83,"column":9},"end":{"line":85,"column":null}}]},"6":{"loc":{"start":{"line":59,"column":43},"end":{"line":59,"column":65}},"type":"binary-expr","locations":[{"start":{"line":59,"column":43},"end":{"line":59,"column":59}},{"start":{"line":59,"column":63},"end":{"line":59,"column":65}}]},"7":{"loc":{"start":{"line":134,"column":20},"end":{"line":134,"column":90}},"type":"binary-expr","locations":[{"start":{"line":134,"column":20},"end":{"line":134,"column":38}},{"start":{"line":134,"column":42},"end":{"line":134,"column":90}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0],"5":[0,0],"6":[0,0],"7":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/destroy.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/destroy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":11,"column":16},"end":{"line":61,"column":1}},"8":{"start":{"line":12,"column":48},"end":{"line":12,"column":56}},"9":{"start":{"line":14,"column":22},"end":{"line":14,"column":57}},"10":{"start":{"line":15,"column":19},"end":{"line":15,"column":48}},"11":{"start":{"line":18,"column":2},"end":{"line":27,"column":null}},"12":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"13":{"start":{"line":19,"column":28},"end":{"line":19,"column":79}},"14":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"15":{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},"16":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"17":{"start":{"line":23,"column":30},"end":{"line":23,"column":81}},"18":{"start":{"line":25,"column":6},"end":{"line":25,"column":null}},"19":{"start":{"line":29,"column":23},"end":{"line":29,"column":66}},"20":{"start":{"line":30,"column":2},"end":{"line":30,"column":null}},"21":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"22":{"start":{"line":32,"column":26},"end":{"line":32,"column":83}},"23":{"start":{"line":33,"column":31},"end":{"line":33,"column":72}},"24":{"start":{"line":34,"column":29},"end":{"line":34,"column":78}},"25":{"start":{"line":35,"column":2},"end":{"line":35,"column":null}},"26":{"start":{"line":38,"column":2},"end":{"line":60,"column":null}},"27":{"start":{"line":40,"column":6},"end":{"line":40,"column":115}},"28":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"29":{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},"30":{"start":{"line":44,"column":6},"end":{"line":44,"column":null}},"31":{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},"32":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"33":{"start":{"line":48,"column":6},"end":{"line":48,"column":null}},"34":{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},"35":{"start":{"line":54,"column":6},"end":{"line":54,"column":null}},"36":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"37":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"38":{"start":{"line":59,"column":28},"end":{"line":59,"column":56}},"39":{"start":{"line":61,"column":1},"end":{"line":61,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":11,"column":16},"end":{"line":11,"column":23}},"loc":{"start":{"line":11,"column":53},"end":{"line":61,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":4},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":19,"column":28},"end":{"line":19,"column":78}},"type":"binary-expr","locations":[{"start":{"line":19,"column":28},"end":{"line":19,"column":44}},{"start":{"line":19,"column":28},"end":{"line":19,"column":44}},{"start":{"line":19,"column":28},"end":{"line":19,"column":78}}]},"2":{"loc":{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},"type":"if","locations":[{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},{"start":{"line":24,"column":11},"end":{"line":26,"column":null}}]},"3":{"loc":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":23,"column":6},"end":{"line":23,"column":null}}]},"4":{"loc":{"start":{"line":23,"column":30},"end":{"line":23,"column":80}},"type":"binary-expr","locations":[{"start":{"line":23,"column":30},"end":{"line":23,"column":46}},{"start":{"line":23,"column":30},"end":{"line":23,"column":46}},{"start":{"line":23,"column":30},"end":{"line":23,"column":80}}]},"5":{"loc":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":32,"column":2},"end":{"line":32,"column":null}}]},"6":{"loc":{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},{"start":{"line":45,"column":11},"end":{"line":49,"column":null}}]},"7":{"loc":{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},{"start":{"line":47,"column":11},"end":{"line":49,"column":null}}]},"8":{"loc":{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},{"start":{"line":55,"column":11},"end":{"line":57,"column":null}}]},"9":{"loc":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"type":"if","locations":[{"start":{"line":59,"column":4},"end":{"line":59,"column":null}}]},"10":{"loc":{"start":{"line":59,"column":28},"end":{"line":59,"column":55}},"type":"binary-expr","locations":[{"start":{"line":59,"column":28},"end":{"line":59,"column":44}},{"start":{"line":59,"column":28},"end":{"line":59,"column":44}},{"start":{"line":59,"column":28},"end":{"line":59,"column":55}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0},"f":{"0":0},"b":{"0":[0],"1":[0,0,0],"2":[0,0],"3":[0],"4":[0,0,0],"5":[0],"6":[0,0],"7":[0,0],"8":[0,0],"9":[0],"10":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/import.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/import.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":58}},"9":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"10":{"start":{"line":13,"column":17},"end":{"line":71,"column":1}},"11":{"start":{"line":14,"column":19},"end":{"line":14,"column":93}},"12":{"start":{"line":15,"column":22},"end":{"line":15,"column":57}},"13":{"start":{"line":17,"column":20},"end":{"line":17,"column":72}},"14":{"start":{"line":18,"column":29},"end":{"line":18,"column":86}},"15":{"start":{"line":19,"column":2},"end":{"line":19,"column":null}},"16":{"start":{"line":21,"column":20},"end":{"line":21,"column":55}},"17":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"18":{"start":{"line":24,"column":2},"end":{"line":24,"column":null}},"19":{"start":{"line":25,"column":31},"end":{"line":25,"column":80}},"20":{"start":{"line":26,"column":32},"end":{"line":26,"column":80}},"21":{"start":{"line":27,"column":21},"end":{"line":27,"column":75}},"22":{"start":{"line":29,"column":29},"end":{"line":29,"column":74}},"23":{"start":{"line":30,"column":23},"end":{"line":30,"column":89}},"24":{"start":{"line":31,"column":19},"end":{"line":31,"column":42}},"25":{"start":{"line":33,"column":2},"end":{"line":33,"column":null}},"26":{"start":{"line":35,"column":23},"end":{"line":35,"column":57}},"27":{"start":{"line":36,"column":2},"end":{"line":53,"column":3}},"28":{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},"29":{"start":{"line":38,"column":6},"end":{"line":38,"column":null}},"30":{"start":{"line":40,"column":6},"end":{"line":46,"column":null}},"31":{"start":{"line":41,"column":8},"end":{"line":45,"column":null}},"32":{"start":{"line":47,"column":6},"end":{"line":49,"column":null}},"33":{"start":{"line":48,"column":8},"end":{"line":48,"column":null}},"34":{"start":{"line":50,"column":11},"end":{"line":52,"column":null}},"35":{"start":{"line":51,"column":6},"end":{"line":51,"column":null}},"36":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"37":{"start":{"line":57,"column":22},"end":{"line":57,"column":24}},"38":{"start":{"line":58,"column":2},"end":{"line":58,"column":null}},"39":{"start":{"line":60,"column":2},"end":{"line":68,"column":null}},"40":{"start":{"line":61,"column":4},"end":{"line":61,"column":null}},"41":{"start":{"line":62,"column":30},"end":{"line":62,"column":49}},"42":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"43":{"start":{"line":64,"column":6},"end":{"line":64,"column":null}},"44":{"start":{"line":67,"column":4},"end":{"line":67,"column":null}},"45":{"start":{"line":70,"column":2},"end":{"line":70,"column":null}},"46":{"start":{"line":71,"column":1},"end":{"line":71,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":13,"column":17},"end":{"line":13,"column":24}},"loc":{"start":{"line":13,"column":100},"end":{"line":71,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"1":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"cond-expr","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"2":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"binary-expr","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"3":{"loc":{"start":{"line":24,"column":2},"end":{"line":24,"column":66}},"type":"binary-expr","locations":[{"start":{"line":24,"column":2},"end":{"line":24,"column":18}},{"start":{"line":24,"column":2},"end":{"line":24,"column":18}},{"start":{"line":24,"column":2},"end":{"line":24,"column":66}}]},"4":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":57}},"type":"binary-expr","locations":[{"start":{"line":35,"column":23},"end":{"line":35,"column":51}},{"start":{"line":35,"column":55},"end":{"line":35,"column":57}}]},"5":{"loc":{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},{"start":{"line":50,"column":11},"end":{"line":52,"column":null}}]},"6":{"loc":{"start":{"line":40,"column":6},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":6},"end":{"line":46,"column":null}}]},"7":{"loc":{"start":{"line":47,"column":6},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":47,"column":6},"end":{"line":49,"column":null}}]},"8":{"loc":{"start":{"line":47,"column":10},"end":{"line":47,"column":71}},"type":"binary-expr","locations":[{"start":{"line":47,"column":10},"end":{"line":47,"column":40}},{"start":{"line":47,"column":44},"end":{"line":47,"column":71}}]},"9":{"loc":{"start":{"line":50,"column":11},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":50,"column":11},"end":{"line":52,"column":null}}]},"10":{"loc":{"start":{"line":55,"column":2},"end":{"line":55,"column":52}},"type":"binary-expr","locations":[{"start":{"line":55,"column":2},"end":{"line":55,"column":18}},{"start":{"line":55,"column":2},"end":{"line":55,"column":18}},{"start":{"line":55,"column":2},"end":{"line":55,"column":52}}]},"11":{"loc":{"start":{"line":61,"column":4},"end":{"line":61,"column":79}},"type":"binary-expr","locations":[{"start":{"line":61,"column":4},"end":{"line":61,"column":20}},{"start":{"line":61,"column":4},"end":{"line":61,"column":20}},{"start":{"line":61,"column":4},"end":{"line":61,"column":79}}]},"12":{"loc":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":65,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0,0],"4":[0,0],"5":[0,0],"6":[0],"7":[0],"8":[0,0],"9":[0],"10":[0,0,0],"11":[0,0,0],"12":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/update.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/update.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"4":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"5":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"8":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"9":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"10":{"start":{"line":16,"column":15},"end":{"line":71,"column":1}},"11":{"start":{"line":26,"column":16},"end":{"line":26,"column":114}},"12":{"start":{"line":28,"column":22},"end":{"line":28,"column":57}},"13":{"start":{"line":30,"column":28},"end":{"line":30,"column":30}},"14":{"start":{"line":31,"column":2},"end":{"line":34,"column":null}},"15":{"start":{"line":33,"column":4},"end":{"line":33,"column":null}},"16":{"start":{"line":36,"column":2},"end":{"line":38,"column":null}},"17":{"start":{"line":37,"column":4},"end":{"line":37,"column":null}},"18":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"19":{"start":{"line":43,"column":2},"end":{"line":49,"column":null}},"20":{"start":{"line":44,"column":4},"end":{"line":44,"column":null}},"21":{"start":{"line":45,"column":4},"end":{"line":48,"column":null}},"22":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"23":{"start":{"line":51,"column":29},"end":{"line":51,"column":31}},"24":{"start":{"line":53,"column":2},"end":{"line":60,"column":null}},"25":{"start":{"line":54,"column":20},"end":{"line":54,"column":40}},"26":{"start":{"line":55,"column":4},"end":{"line":59,"column":null}},"27":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"28":{"start":{"line":58,"column":6},"end":{"line":58,"column":null}},"29":{"start":{"line":62,"column":2},"end":{"line":64,"column":null}},"30":{"start":{"line":63,"column":4},"end":{"line":63,"column":null}},"31":{"start":{"line":66,"column":2},"end":{"line":68,"column":null}},"32":{"start":{"line":67,"column":4},"end":{"line":67,"column":null}},"33":{"start":{"line":70,"column":2},"end":{"line":70,"column":null}},"34":{"start":{"line":71,"column":1},"end":{"line":71,"column":null}},"35":{"start":{"line":73,"column":24},"end":{"line":90,"column":1}},"36":{"start":{"line":74,"column":2},"end":{"line":74,"column":null}},"37":{"start":{"line":76,"column":39},"end":{"line":76,"column":47}},"38":{"start":{"line":78,"column":27},"end":{"line":78,"column":64}},"39":{"start":{"line":79,"column":33},"end":{"line":88,"column":4}},"40":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":16,"column":15},"end":{"line":16,"column":22}},"loc":{"start":{"line":25,"column":6},"end":{"line":71,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":73,"column":24},"end":{"line":73,"column":31}},"loc":{"start":{"line":73,"column":61},"end":{"line":90,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":26,"column":16},"end":{"line":26,"column":114}},"type":"binary-expr","locations":[{"start":{"line":26,"column":16},"end":{"line":26,"column":39}},{"start":{"line":26,"column":43},"end":{"line":26,"column":66}},{"start":{"line":26,"column":70},"end":{"line":26,"column":89}},{"start":{"line":26,"column":93},"end":{"line":26,"column":114}}]},"1":{"loc":{"start":{"line":31,"column":2},"end":{"line":34,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":34,"column":null}}]},"2":{"loc":{"start":{"line":31,"column":6},"end":{"line":31,"column":42}},"type":"binary-expr","locations":[{"start":{"line":31,"column":6},"end":{"line":31,"column":20}},{"start":{"line":31,"column":24},"end":{"line":31,"column":42}}]},"3":{"loc":{"start":{"line":36,"column":2},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":2},"end":{"line":38,"column":null}}]},"4":{"loc":{"start":{"line":36,"column":6},"end":{"line":36,"column":38}},"type":"binary-expr","locations":[{"start":{"line":36,"column":6},"end":{"line":36,"column":20}},{"start":{"line":36,"column":24},"end":{"line":36,"column":38}}]},"5":{"loc":{"start":{"line":43,"column":2},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":2},"end":{"line":49,"column":null}}]},"6":{"loc":{"start":{"line":43,"column":6},"end":{"line":43,"column":40}},"type":"binary-expr","locations":[{"start":{"line":43,"column":6},"end":{"line":43,"column":20}},{"start":{"line":43,"column":24},"end":{"line":43,"column":40}}]},"7":{"loc":{"start":{"line":45,"column":4},"end":{"line":48,"column":null}},"type":"if","locations":[{"start":{"line":45,"column":4},"end":{"line":48,"column":null}}]},"8":{"loc":{"start":{"line":53,"column":2},"end":{"line":60,"column":null}},"type":"if","locations":[{"start":{"line":53,"column":2},"end":{"line":60,"column":null}}]},"9":{"loc":{"start":{"line":53,"column":6},"end":{"line":53,"column":42}},"type":"binary-expr","locations":[{"start":{"line":53,"column":6},"end":{"line":53,"column":20}},{"start":{"line":53,"column":24},"end":{"line":53,"column":42}}]},"10":{"loc":{"start":{"line":62,"column":2},"end":{"line":64,"column":null}},"type":"if","locations":[{"start":{"line":62,"column":2},"end":{"line":64,"column":null}}]},"11":{"loc":{"start":{"line":62,"column":6},"end":{"line":62,"column":38}},"type":"binary-expr","locations":[{"start":{"line":62,"column":6},"end":{"line":62,"column":20}},{"start":{"line":62,"column":24},"end":{"line":62,"column":38}}]},"12":{"loc":{"start":{"line":66,"column":2},"end":{"line":68,"column":null}},"type":"if","locations":[{"start":{"line":66,"column":2},"end":{"line":68,"column":null}}]},"13":{"loc":{"start":{"line":66,"column":6},"end":{"line":66,"column":76}},"type":"binary-expr","locations":[{"start":{"line":66,"column":7},"end":{"line":66,"column":21}},{"start":{"line":66,"column":25},"end":{"line":66,"column":43}},{"start":{"line":66,"column":48},"end":{"line":66,"column":76}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0},"f":{"0":0,"1":0},"b":{"0":[0,0,0,0],"1":[0],"2":[0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0],"11":[0,0],"12":[0],"13":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/verify.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/verify.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"2":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"3":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"4":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"5":{"start":{"line":12,"column":26},"end":{"line":12,"column":30}},"6":{"start":{"line":14,"column":15},"end":{"line":35,"column":1}},"7":{"start":{"line":15,"column":19},"end":{"line":15,"column":102}},"8":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"9":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"10":{"start":{"line":21,"column":17},"end":{"line":21,"column":19}},"11":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"12":{"start":{"line":23,"column":4},"end":{"line":23,"column":null}},"13":{"start":{"line":25,"column":2},"end":{"line":27,"column":null}},"14":{"start":{"line":26,"column":4},"end":{"line":26,"column":null}},"15":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"16":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"17":{"start":{"line":32,"column":18},"end":{"line":32,"column":43}},"18":{"start":{"line":34,"column":2},"end":{"line":34,"column":null}},"19":{"start":{"line":34,"column":42},"end":{"line":34,"column":62}},"20":{"start":{"line":34,"column":62},"end":{"line":34,"column":73}},"21":{"start":{"line":35,"column":1},"end":{"line":35,"column":null}},"22":{"start":{"line":37,"column":23},"end":{"line":74,"column":1}},"23":{"start":{"line":38,"column":2},"end":{"line":40,"column":null}},"24":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"25":{"start":{"line":41,"column":37},"end":{"line":41,"column":45}},"26":{"start":{"line":43,"column":19},"end":{"line":43,"column":48}},"27":{"start":{"line":44,"column":19},"end":{"line":44,"column":58}},"28":{"start":{"line":46,"column":22},"end":{"line":46,"column":70}},"29":{"start":{"line":47,"column":2},"end":{"line":73,"column":null}},"30":{"start":{"line":48,"column":23},"end":{"line":48,"column":86}},"31":{"start":{"line":50,"column":25},"end":{"line":50,"column":50}},"32":{"start":{"line":51,"column":25},"end":{"line":51,"column":50}},"33":{"start":{"line":52,"column":25},"end":{"line":52,"column":50}},"34":{"start":{"line":53,"column":20},"end":{"line":53,"column":69}},"35":{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},"36":{"start":{"line":55,"column":6},"end":{"line":55,"column":null}},"37":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"38":{"start":{"line":58,"column":6},"end":{"line":58,"column":null}},"39":{"start":{"line":59,"column":6},"end":{"line":60,"column":null}},"40":{"start":{"line":63,"column":4},"end":{"line":63,"column":null}},"41":{"start":{"line":65,"column":4},"end":{"line":65,"column":null}},"42":{"start":{"line":66,"column":4},"end":{"line":66,"column":null}},"43":{"start":{"line":68,"column":4},"end":{"line":68,"column":null}},"44":{"start":{"line":70,"column":4},"end":{"line":72,"column":null}},"45":{"start":{"line":71,"column":6},"end":{"line":71,"column":null}},"46":{"start":{"line":76,"column":22},"end":{"line":104,"column":1}},"47":{"start":{"line":77,"column":2},"end":{"line":79,"column":null}},"48":{"start":{"line":78,"column":4},"end":{"line":78,"column":null}},"49":{"start":{"line":80,"column":25},"end":{"line":80,"column":33}},"50":{"start":{"line":82,"column":2},"end":{"line":103,"column":null}},"51":{"start":{"line":83,"column":27},"end":{"line":86,"column":6}},"52":{"start":{"line":88,"column":20},"end":{"line":90,"column":null}},"53":{"start":{"line":93,"column":4},"end":{"line":93,"column":null}},"54":{"start":{"line":95,"column":4},"end":{"line":98,"column":null}},"55":{"start":{"line":100,"column":4},"end":{"line":102,"column":null}},"56":{"start":{"line":101,"column":6},"end":{"line":101,"column":null}},"57":{"start":{"line":106,"column":21},"end":{"line":165,"column":1}},"58":{"start":{"line":107,"column":2},"end":{"line":109,"column":null}},"59":{"start":{"line":108,"column":4},"end":{"line":108,"column":null}},"60":{"start":{"line":111,"column":22},"end":{"line":111,"column":53}},"61":{"start":{"line":113,"column":2},"end":{"line":162,"column":null}},"62":{"start":{"line":114,"column":26},"end":{"line":114,"column":34}},"63":{"start":{"line":115,"column":21},"end":{"line":115,"column":62}},"64":{"start":{"line":116,"column":31},"end":{"line":116,"column":85}},"65":{"start":{"line":117,"column":34},"end":{"line":117,"column":97}},"66":{"start":{"line":119,"column":47},"end":{"line":121,"column":6}},"67":{"start":{"line":124,"column":4},"end":{"line":132,"column":null}},"68":{"start":{"line":125,"column":6},"end":{"line":127,"column":null}},"69":{"start":{"line":126,"column":8},"end":{"line":126,"column":null}},"70":{"start":{"line":128,"column":6},"end":{"line":128,"column":null}},"71":{"start":{"line":128,"column":35},"end":{"line":128,"column":73}},"72":{"start":{"line":130,"column":6},"end":{"line":130,"column":null}},"73":{"start":{"line":131,"column":6},"end":{"line":131,"column":null}},"74":{"start":{"line":134,"column":29},"end":{"line":134,"column":72}},"75":{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},"76":{"start":{"line":136,"column":6},"end":{"line":136,"column":null}},"77":{"start":{"line":137,"column":6},"end":{"line":140,"column":null}},"78":{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},"79":{"start":{"line":142,"column":6},"end":{"line":142,"column":null}},"80":{"start":{"line":143,"column":6},"end":{"line":143,"column":null}},"81":{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},"82":{"start":{"line":145,"column":6},"end":{"line":145,"column":null}},"83":{"start":{"line":146,"column":6},"end":{"line":146,"column":null}},"84":{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},"85":{"start":{"line":148,"column":6},"end":{"line":148,"column":null}},"86":{"start":{"line":149,"column":6},"end":{"line":150,"column":null}},"87":{"start":{"line":152,"column":6},"end":{"line":152,"column":null}},"88":{"start":{"line":153,"column":6},"end":{"line":153,"column":null}},"89":{"start":{"line":156,"column":4},"end":{"line":156,"column":null}},"90":{"start":{"line":157,"column":4},"end":{"line":157,"column":null}},"91":{"start":{"line":159,"column":4},"end":{"line":161,"column":null}},"92":{"start":{"line":160,"column":6},"end":{"line":160,"column":null}},"93":{"start":{"line":164,"column":2},"end":{"line":164,"column":null}},"94":{"start":{"line":167,"column":28},"end":{"line":180,"column":1}},"95":{"start":{"line":168,"column":17},"end":{"line":171,"column":3}},"96":{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},"97":{"start":{"line":174,"column":4},"end":{"line":174,"column":null}},"98":{"start":{"line":176,"column":4},"end":{"line":176,"column":null}},"99":{"start":{"line":179,"column":2},"end":{"line":179,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":14,"column":15},"end":{"line":14,"column":22}},"loc":{"start":{"line":14,"column":82},"end":{"line":35,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":34,"column":24},"end":{"line":34,"column":25}},"loc":{"start":{"line":34,"column":40},"end":{"line":34,"column":74}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":37,"column":23},"end":{"line":37,"column":30}},"loc":{"start":{"line":37,"column":76},"end":{"line":74,"column":1}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":76,"column":22},"end":{"line":76,"column":29}},"loc":{"start":{"line":76,"column":62},"end":{"line":104,"column":1}}},"4":{"name":"(anonymous_4)","decl":{"start":{"line":106,"column":21},"end":{"line":106,"column":28}},"loc":{"start":{"line":106,"column":74},"end":{"line":165,"column":1}}},"5":{"name":"(anonymous_5)","decl":{"start":{"line":128,"column":24},"end":{"line":128,"column":31}},"loc":{"start":{"line":128,"column":35},"end":{"line":128,"column":73}}},"6":{"name":"(anonymous_6)","decl":{"start":{"line":167,"column":28},"end":{"line":167,"column":29}},"loc":{"start":{"line":167,"column":59},"end":{"line":180,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":15,"column":19},"end":{"line":15,"column":102}},"type":"binary-expr","locations":[{"start":{"line":15,"column":19},"end":{"line":15,"column":45}},{"start":{"line":15,"column":49},"end":{"line":15,"column":74}},{"start":{"line":15,"column":78},"end":{"line":15,"column":102}}]},"1":{"loc":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":2},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":6},"end":{"line":17,"column":44}},"type":"binary-expr","locations":[{"start":{"line":17,"column":6},"end":{"line":17,"column":14}},{"start":{"line":17,"column":18},"end":{"line":17,"column":30}},{"start":{"line":17,"column":34},"end":{"line":17,"column":44}}]},"3":{"loc":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":22,"column":2},"end":{"line":24,"column":null}}]},"4":{"loc":{"start":{"line":22,"column":6},"end":{"line":22,"column":29}},"type":"binary-expr","locations":[{"start":{"line":22,"column":6},"end":{"line":22,"column":14}},{"start":{"line":22,"column":18},"end":{"line":22,"column":29}}]},"5":{"loc":{"start":{"line":25,"column":2},"end":{"line":27,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":2},"end":{"line":27,"column":null}}]},"6":{"loc":{"start":{"line":25,"column":6},"end":{"line":25,"column":30}},"type":"binary-expr","locations":[{"start":{"line":25,"column":6},"end":{"line":25,"column":14}},{"start":{"line":25,"column":18},"end":{"line":25,"column":30}}]},"7":{"loc":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":2},"end":{"line":30,"column":null}}]},"8":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":28}},"type":"binary-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":14}},{"start":{"line":28,"column":18},"end":{"line":28,"column":28}}]},"9":{"loc":{"start":{"line":38,"column":2},"end":{"line":40,"column":null}},"type":"if","locations":[{"start":{"line":38,"column":2},"end":{"line":40,"column":null}}]},"10":{"loc":{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},"type":"if","locations":[{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},{"start":{"line":57,"column":11},"end":{"line":61,"column":null}}]},"11":{"loc":{"start":{"line":70,"column":4},"end":{"line":72,"column":null}},"type":"if","locations":[{"start":{"line":70,"column":4},"end":{"line":72,"column":null}}]},"12":{"loc":{"start":{"line":77,"column":2},"end":{"line":79,"column":null}},"type":"if","locations":[{"start":{"line":77,"column":2},"end":{"line":79,"column":null}}]},"13":{"loc":{"start":{"line":100,"column":4},"end":{"line":102,"column":null}},"type":"if","locations":[{"start":{"line":100,"column":4},"end":{"line":102,"column":null}}]},"14":{"loc":{"start":{"line":107,"column":2},"end":{"line":109,"column":null}},"type":"if","locations":[{"start":{"line":107,"column":2},"end":{"line":109,"column":null}}]},"15":{"loc":{"start":{"line":125,"column":6},"end":{"line":127,"column":null}},"type":"if","locations":[{"start":{"line":125,"column":6},"end":{"line":127,"column":null}}]},"16":{"loc":{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},{"start":{"line":141,"column":11},"end":{"line":154,"column":null}}]},"17":{"loc":{"start":{"line":137,"column":29},"end":{"line":139,"column":35}},"type":"cond-expr","locations":[{"start":{"line":138,"column":10},"end":{"line":138,"column":43}},{"start":{"line":139,"column":10},"end":{"line":139,"column":35}}]},"18":{"loc":{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},{"start":{"line":144,"column":11},"end":{"line":154,"column":null}}]},"19":{"loc":{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},{"start":{"line":147,"column":11},"end":{"line":154,"column":null}}]},"20":{"loc":{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},{"start":{"line":151,"column":11},"end":{"line":154,"column":null}}]},"21":{"loc":{"start":{"line":159,"column":4},"end":{"line":161,"column":null}},"type":"if","locations":[{"start":{"line":159,"column":4},"end":{"line":161,"column":null}}]},"22":{"loc":{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},"type":"if","locations":[{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},{"start":{"line":175,"column":9},"end":{"line":177,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"b":{"0":[0,0,0],"1":[0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0,0],"9":[0],"10":[0,0],"11":[0],"12":[0],"13":[0],"14":[0],"15":[0],"16":[0,0],"17":[0,0],"18":[0,0],"19":[0,0],"20":[0,0],"21":[0],"22":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/add-tags-to-hosted-zone.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/add-tags-to-hosted-zone.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":28},"end":{"line":18,"column":1}},"4":{"start":{"line":7,"column":18},"end":{"line":7,"column":38}},"5":{"start":{"line":8,"column":24},"end":{"line":8,"column":58}},"6":{"start":{"line":10,"column":23},"end":{"line":10,"column":73}},"7":{"start":{"line":12,"column":39},"end":{"line":16,"column":4}},"8":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"9":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":28},"end":{"line":6,"column":35}},"loc":{"start":{"line":6,"column":65},"end":{"line":18,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/associate-cost-allocation-tags.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/associate-cost-allocation-tags.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":36},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":29},"end":{"line":6,"column":68}},"4":{"start":{"line":7,"column":48},"end":{"line":9,"column":4}},"5":{"start":{"line":10,"column":2},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}},"7":{"start":{"line":13,"column":47},"end":{"line":17,"column":1}},"8":{"start":{"line":14,"column":25},"end":{"line":14,"column":33}},"9":{"start":{"line":16,"column":2},"end":{"line":16,"column":null}},"10":{"start":{"line":17,"column":1},"end":{"line":17,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":36},"end":{"line":5,"column":43}},"loc":{"start":{"line":5,"column":68},"end":{"line":11,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":13,"column":47},"end":{"line":13,"column":48}},"loc":{"start":{"line":13,"column":74},"end":{"line":17,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0,"1":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/create-or-update-dns-records.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/create-or-update-dns-records.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":33},"end":{"line":41,"column":1}},"5":{"start":{"line":8,"column":59},"end":{"line":8,"column":67}},"6":{"start":{"line":10,"column":27},"end":{"line":10,"column":72}},"7":{"start":{"line":11,"column":33},"end":{"line":11,"column":94}},"8":{"start":{"line":12,"column":31},"end":{"line":12,"column":82}},"9":{"start":{"line":13,"column":33},"end":{"line":13,"column":77}},"10":{"start":{"line":15,"column":24},"end":{"line":15,"column":66}},"11":{"start":{"line":17,"column":23},"end":{"line":17,"column":73}},"12":{"start":{"line":19,"column":18},"end":{"line":19,"column":51}},"13":{"start":{"line":21,"column":41},"end":{"line":38,"column":4}},"14":{"start":{"line":25,"column":39},"end":{"line":36,"column":7}},"15":{"start":{"line":39,"column":2},"end":{"line":39,"column":null}},"16":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"17":{"start":{"line":41,"column":1},"end":{"line":41,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":33},"end":{"line":7,"column":40}},"loc":{"start":{"line":7,"column":70},"end":{"line":41,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":25,"column":29},"end":{"line":25,"column":33}},"loc":{"start":{"line":25,"column":39},"end":{"line":36,"column":7}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0,"1":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/find-certificate.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/find-certificate.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":24},"end":{"line":27,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":8,"column":2},"end":{"line":22,"column":null}},"5":{"start":{"line":9,"column":36},"end":{"line":11,"column":6}},"6":{"start":{"line":12,"column":25},"end":{"line":12,"column":70}},"7":{"start":{"line":14,"column":19},"end":{"line":14,"column":36}},"8":{"start":{"line":15,"column":4},"end":{"line":20,"column":null}},"9":{"start":{"line":16,"column":6},"end":{"line":19,"column":null}},"10":{"start":{"line":17,"column":8},"end":{"line":17,"column":null}},"11":{"start":{"line":18,"column":8},"end":{"line":18,"column":null}},"12":{"start":{"line":21,"column":4},"end":{"line":21,"column":null}},"13":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"14":{"start":{"line":26,"column":2},"end":{"line":26,"column":null}},"15":{"start":{"line":27,"column":1},"end":{"line":27,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":24},"end":{"line":5,"column":31}},"loc":{"start":{"line":5,"column":61},"end":{"line":27,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":65}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":65}}]},"1":{"loc":{"start":{"line":16,"column":6},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":6},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":8},"end":{"line":17,"column":40}},"type":"binary-expr","locations":[{"start":{"line":17,"column":8},"end":{"line":17,"column":24}},{"start":{"line":17,"column":8},"end":{"line":17,"column":24}},{"start":{"line":17,"column":8},"end":{"line":17,"column":40}}]},"3":{"loc":{"start":{"line":25,"column":2},"end":{"line":25,"column":36}},"type":"binary-expr","locations":[{"start":{"line":25,"column":2},"end":{"line":25,"column":18}},{"start":{"line":25,"column":2},"end":{"line":25,"column":18}},{"start":{"line":25,"column":2},"end":{"line":25,"column":36}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0,0,0],"1":[0],"2":[0,0,0],"3":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-credentials.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-credentials.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":9,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":22},"end":{"line":6,"column":55}},"4":{"start":{"line":8,"column":2},"end":{"line":8,"column":null}},"5":{"start":{"line":9,"column":1},"end":{"line":9,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":58},"end":{"line":9,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":15},"end":{"line":4,"column":65}},"type":"binary-expr","locations":[{"start":{"line":4,"column":15},"end":{"line":4,"column":25}},{"start":{"line":4,"column":29},"end":{"line":4,"column":52}},{"start":{"line":4,"column":56},"end":{"line":4,"column":65}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0},"f":{"0":0},"b":{"0":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-hosted-zone-id.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-hosted-zone-id.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":24},"end":{"line":19,"column":1}},"2":{"start":{"line":5,"column":2},"end":{"line":18,"column":null}},"3":{"start":{"line":6,"column":35},"end":{"line":6,"column":87}},"4":{"start":{"line":7,"column":36},"end":{"line":7,"column":84}},"5":{"start":{"line":9,"column":4},"end":{"line":13,"column":null}},"6":{"start":{"line":10,"column":6},"end":{"line":12,"column":null}},"7":{"start":{"line":11,"column":8},"end":{"line":11,"column":49}},"8":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"9":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"10":{"start":{"line":19,"column":1},"end":{"line":19,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":24},"end":{"line":3,"column":31}},"loc":{"start":{"line":3,"column":63},"end":{"line":19,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":6},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":6},"end":{"line":12,"column":null}}]},"1":{"loc":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"type":"if","locations":[{"start":{"line":15,"column":4},"end":{"line":17,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0],"1":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/sync-site-content.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/sync-site-content.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":61}},"7":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"8":{"start":{"line":11,"column":24},"end":{"line":34,"column":1}},"9":{"start":{"line":12,"column":49},"end":{"line":12,"column":57}},"10":{"start":{"line":14,"column":2},"end":{"line":22,"column":null}},"11":{"start":{"line":15,"column":24},"end":{"line":15,"column":56}},"12":{"start":{"line":16,"column":24},"end":{"line":16,"column":64}},"13":{"start":{"line":17,"column":4},"end":{"line":21,"column":null}},"14":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"15":{"start":{"line":19,"column":6},"end":{"line":19,"column":null}},"16":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"17":{"start":{"line":24,"column":2},"end":{"line":24,"column":null}},"18":{"start":{"line":26,"column":19},"end":{"line":26,"column":48}},"19":{"start":{"line":27,"column":19},"end":{"line":27,"column":58}},"20":{"start":{"line":29,"column":2},"end":{"line":33,"column":null}},"21":{"start":{"line":30,"column":41},"end":{"line":30,"column":111}},"22":{"start":{"line":34,"column":1},"end":{"line":34,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":11,"column":24},"end":{"line":11,"column":31}},"loc":{"start":{"line":11,"column":70},"end":{"line":34,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":30,"column":30},"end":{"line":30,"column":35}},"loc":{"start":{"line":30,"column":41},"end":{"line":30,"column":111}}}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"1":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"cond-expr","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"2":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"binary-expr","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"3":{"loc":{"start":{"line":14,"column":2},"end":{"line":22,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":22,"column":null}}]},"4":{"loc":{"start":{"line":14,"column":6},"end":{"line":14,"column":53}},"type":"binary-expr","locations":[{"start":{"line":14,"column":6},"end":{"line":14,"column":22}},{"start":{"line":14,"column":26},"end":{"line":14,"column":53}}]},"5":{"loc":{"start":{"line":17,"column":4},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":4},"end":{"line":21,"column":null}}]},"6":{"loc":{"start":{"line":30,"column":57},"end":{"line":30,"column":110}},"type":"binary-expr","locations":[{"start":{"line":30,"column":57},"end":{"line":30,"column":79}},{"start":{"line":30,"column":83},"end":{"line":30,"column":110}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/track-stack-status.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/track-stack-status.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":26},"end":{"line":5,"column":30}},"3":{"start":{"line":7,"column":25},"end":{"line":41,"column":1}},"4":{"start":{"line":9,"column":2},"end":{"line":29,"column":null}},"5":{"start":{"line":10,"column":26},"end":{"line":10,"column":51}},"6":{"start":{"line":11,"column":28},"end":{"line":11,"column":68}},"7":{"start":{"line":12,"column":29},"end":{"line":12,"column":77}},"8":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"9":{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},"10":{"start":{"line":18,"column":28},"end":{"line":18,"column":108}},"11":{"start":{"line":19,"column":6},"end":{"line":19,"column":null}},"12":{"start":{"line":20,"column":6},"end":{"line":22,"column":null}},"13":{"start":{"line":21,"column":8},"end":{"line":21,"column":null}},"14":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"15":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"16":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"17":{"start":{"line":28,"column":33},"end":{"line":28,"column":71}},"18":{"start":{"line":31,"column":2},"end":{"line":38,"column":null}},"19":{"start":{"line":32,"column":4},"end":{"line":32,"column":null}},"20":{"start":{"line":33,"column":24},"end":{"line":33,"column":49}},"21":{"start":{"line":34,"column":26},"end":{"line":34,"column":61}},"22":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"23":{"start":{"line":37,"column":4},"end":{"line":37,"column":null}},"24":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"25":{"start":{"line":41,"column":1},"end":{"line":41,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":25},"end":{"line":7,"column":32}},"loc":{"start":{"line":7,"column":108},"end":{"line":41,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":28,"column":22},"end":{"line":28,"column":29}},"loc":{"start":{"line":28,"column":33},"end":{"line":28,"column":71}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},{"start":{"line":23,"column":11},"end":{"line":25,"column":null}}]},"1":{"loc":{"start":{"line":16,"column":8},"end":{"line":16,"column":100}},"type":"binary-expr","locations":[{"start":{"line":16,"column":8},"end":{"line":16,"column":38}},{"start":{"line":16,"column":43},"end":{"line":16,"column":67}},{"start":{"line":16,"column":71},"end":{"line":16,"column":99}}]},"2":{"loc":{"start":{"line":19,"column":28},"end":{"line":19,"column":68}},"type":"cond-expr","locations":[{"start":{"line":19,"column":59},"end":{"line":19,"column":63}},{"start":{"line":19,"column":66},"end":{"line":19,"column":68}}]},"3":{"loc":{"start":{"line":20,"column":6},"end":{"line":22,"column":null}},"type":"if","locations":[{"start":{"line":20,"column":6},"end":{"line":22,"column":null}}]},"4":{"loc":{"start":{"line":31,"column":2},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":31,"column":6},"end":{"line":31,"column":71}},"type":"binary-expr","locations":[{"start":{"line":31,"column":6},"end":{"line":31,"column":41}},{"start":{"line":31,"column":45},"end":{"line":31,"column":71}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0,0],"2":[0,0],"3":[0],"4":[0],"5":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-plugins.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-plugins.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":40}},"1":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"2":{"start":{"line":3,"column":22},"end":{"line":18,"column":1}},"3":{"start":{"line":4,"column":48},"end":{"line":4,"column":56}},"4":{"start":{"line":5,"column":18},"end":{"line":5,"column":20}},"5":{"start":{"line":7,"column":2},"end":{"line":15,"column":null}},"6":{"start":{"line":8,"column":19},"end":{"line":8,"column":37}},"7":{"start":{"line":9,"column":4},"end":{"line":11,"column":null}},"8":{"start":{"line":10,"column":6},"end":{"line":10,"column":null}},"9":{"start":{"line":13,"column":30},"end":{"line":13,"column":36}},"10":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"11":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":3,"column":22},"end":{"line":3,"column":29}},"loc":{"start":{"line":3,"column":59},"end":{"line":18,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"if","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"1":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"2":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"binary-expr","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"3":{"loc":{"start":{"line":9,"column":4},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":4},"end":{"line":11,"column":null}}]},"4":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":71}},"type":"cond-expr","locations":[{"start":{"line":14,"column":30},"end":{"line":14,"column":33}},{"start":{"line":14,"column":17},"end":{"line":14,"column":71}}]},"5":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":33}},"type":"binary-expr","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":33}},{"start":{"line":14,"column":17},"end":{"line":14,"column":33}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-site-info.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-site-info.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":23},"end":{"line":15,"column":1}},"3":{"start":{"line":6,"column":32},"end":{"line":6,"column":40}},"4":{"start":{"line":7,"column":2},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":31},"end":{"line":8,"column":80}},"6":{"start":{"line":9,"column":26},"end":{"line":9,"column":78}},"7":{"start":{"line":10,"column":27},"end":{"line":10,"column":75}},"8":{"start":{"line":11,"column":35},"end":{"line":12,"column":102}},"9":{"start":{"line":12,"column":47},"end":{"line":12,"column":89}},"10":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"11":{"start":{"line":15,"column":1},"end":{"line":15,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":23},"end":{"line":5,"column":30}},"loc":{"start":{"line":5,"column":60},"end":{"line":15,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":12,"column":28},"end":{"line":12,"column":29}},"loc":{"start":{"line":12,"column":47},"end":{"line":12,"column":89}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0},"f":{"0":0,"1":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-stack.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-stack.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":8,"column":0},"end":{"line":8,"column":51}},"7":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"8":{"start":{"line":10,"column":20},"end":{"line":64,"column":1}},"9":{"start":{"line":11,"column":32},"end":{"line":11,"column":40}},"10":{"start":{"line":13,"column":23},"end":{"line":13,"column":66}},"11":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"12":{"start":{"line":15,"column":2},"end":{"line":15,"column":null}},"13":{"start":{"line":17,"column":22},"end":{"line":17,"column":43}},"14":{"start":{"line":19,"column":31},"end":{"line":19,"column":80}},"15":{"start":{"line":20,"column":29},"end":{"line":23,"column":4}},"16":{"start":{"line":24,"column":30},"end":{"line":24,"column":81}},"17":{"start":{"line":25,"column":26},"end":{"line":25,"column":58}},"18":{"start":{"line":27,"column":2},"end":{"line":30,"column":null}},"19":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"20":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"21":{"start":{"line":33,"column":29},"end":{"line":39,"column":4}},"22":{"start":{"line":41,"column":2},"end":{"line":41,"column":null}},"23":{"start":{"line":43,"column":22},"end":{"line":43,"column":107}},"24":{"start":{"line":45,"column":2},"end":{"line":45,"column":50}},"25":{"start":{"line":47,"column":29},"end":{"line":50,"column":71}},"26":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}},"27":{"start":{"line":50,"column":39},"end":{"line":50,"column":70}},"28":{"start":{"line":52,"column":2},"end":{"line":57,"column":null}},"29":{"start":{"line":53,"column":4},"end":{"line":56,"column":null}},"30":{"start":{"line":55,"column":8},"end":{"line":55,"column":76}},"31":{"start":{"line":59,"column":2},"end":{"line":61,"column":null}},"32":{"start":{"line":60,"column":4},"end":{"line":60,"column":null}},"33":{"start":{"line":63,"column":2},"end":{"line":63,"column":null}},"34":{"start":{"line":64,"column":1},"end":{"line":64,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":10,"column":20},"end":{"line":10,"column":27}},"loc":{"start":{"line":10,"column":57},"end":{"line":64,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":47,"column":77},"end":{"line":47,"column":86}},"loc":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":50,"column":12},"end":{"line":50,"column":13}},"loc":{"start":{"line":50,"column":39},"end":{"line":50,"column":70}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":54,"column":33},"end":{"line":54,"column":34}},"loc":{"start":{"line":55,"column":8},"end":{"line":55,"column":76}}}},"branchMap":{"0":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"if","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"1":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"cond-expr","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"2":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"binary-expr","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"3":{"loc":{"start":{"line":27,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":27,"column":2},"end":{"line":30,"column":null}}]},"4":{"loc":{"start":{"line":47,"column":41},"end":{"line":47,"column":70}},"type":"binary-expr","locations":[{"start":{"line":47,"column":41},"end":{"line":47,"column":64}},{"start":{"line":47,"column":68},"end":{"line":47,"column":70}}]},"5":{"loc":{"start":{"line":52,"column":2},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":52,"column":2},"end":{"line":57,"column":null}}]},"6":{"loc":{"start":{"line":59,"column":2},"end":{"line":61,"column":null}},"type":"if","locations":[{"start":{"line":59,"column":2},"end":{"line":61,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/access-logs.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/access-logs.mjs","statementMap":{"0":{"start":{"line":1,"column":15},"end":{"line":3,"column":1}},"1":{"start":{"line":2,"column":50},"end":{"line":2,"column":73}},"2":{"start":{"line":5,"column":16},"end":{"line":7,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":9,"column":22},"end":{"line":9,"column":30}},"5":{"start":{"line":11,"column":16},"end":{"line":11,"column":53}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":2,"column":44},"end":{"line":2,"column":45}},"loc":{"start":{"line":2,"column":50},"end":{"line":2,"column":73}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":5,"column":16},"end":{"line":5,"column":22}},"loc":{"start":{"line":5,"column":22},"end":{"line":7,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":22},"end":{"line":9,"column":28}},"loc":{"start":{"line":9,"column":28},"end":{"line":9,"column":30}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0},"f":{"0":0,"1":0,"2":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/cloudfront-logs.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/cloudfront-logs.mjs","statementMap":{"0":{"start":{"line":1,"column":15},"end":{"line":12,"column":1}},"1":{"start":{"line":9,"column":27},"end":{"line":9,"column":null}},"2":{"start":{"line":14,"column":22},"end":{"line":22,"column":1}},"3":{"start":{"line":15,"column":34},"end":{"line":15,"column":117}},"4":{"start":{"line":16,"column":2},"end":{"line":21,"column":null}},"5":{"start":{"line":17,"column":21},"end":{"line":19,"column":5}},"6":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"7":{"start":{"line":24,"column":31},"end":{"line":26,"column":1}},"8":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"9":{"start":{"line":28,"column":20},"end":{"line":38,"column":1}},"10":{"start":{"line":29,"column":28},"end":{"line":29,"column":40}},"11":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"12":{"start":{"line":33,"column":2},"end":{"line":37,"column":null}},"13":{"start":{"line":40,"column":20},"end":{"line":40,"column":85}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":21},"end":{"line":9,"column":22}},"loc":{"start":{"line":9,"column":27},"end":{"line":9,"column":null}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":14,"column":22},"end":{"line":14,"column":23}},"loc":{"start":{"line":14,"column":94},"end":{"line":22,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":24,"column":31},"end":{"line":24,"column":38}},"loc":{"start":{"line":24,"column":59},"end":{"line":26,"column":1}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":28,"column":20},"end":{"line":28,"column":27}},"loc":{"start":{"line":28,"column":60},"end":{"line":38,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":2},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":2},"end":{"line":21,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/constants.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/constants.mjs","statementMap":{"0":{"start":{"line":1,"column":37},"end":{"line":1,"column":68}},"1":{"start":{"line":2,"column":37},"end":{"line":2,"column":68}},"2":{"start":{"line":3,"column":36},"end":{"line":3,"column":66}},"3":{"start":{"line":5,"column":33},"end":{"line":30,"column":1}}},"fnMap":{},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0},"f":{},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":36},"end":{"line":32,"column":1}},"4":{"start":{"line":8,"column":23},"end":{"line":8,"column":35}},"5":{"start":{"line":9,"column":21},"end":{"line":9,"column":29}},"6":{"start":{"line":10,"column":20},"end":{"line":10,"column":28}},"7":{"start":{"line":12,"column":23},"end":{"line":12,"column":64}},"8":{"start":{"line":13,"column":2},"end":{"line":31,"column":null}},"9":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":31},"end":{"line":15,"column":85}},"11":{"start":{"line":16,"column":4},"end":{"line":26,"column":null}},"12":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"13":{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},"14":{"start":{"line":20,"column":8},"end":{"line":20,"column":null}},"15":{"start":{"line":21,"column":8},"end":{"line":21,"column":null}},"16":{"start":{"line":23,"column":8},"end":{"line":23,"column":null}},"17":{"start":{"line":24,"column":8},"end":{"line":24,"column":null}},"18":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"19":{"start":{"line":28,"column":21},"end":{"line":28,"column":41}},"20":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"21":{"start":{"line":30,"column":4},"end":{"line":30,"column":null}},"22":{"start":{"line":32,"column":1},"end":{"line":32,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":36},"end":{"line":7,"column":43}},"loc":{"start":{"line":7,"column":87},"end":{"line":32,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":89}},"type":"binary-expr","locations":[{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":89}}]},"1":{"loc":{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},{"start":{"line":22,"column":13},"end":{"line":25,"column":null}}]},"2":{"loc":{"start":{"line":19,"column":10},"end":{"line":19,"column":70}},"type":"binary-expr","locations":[{"start":{"line":19,"column":10},"end":{"line":19,"column":31}},{"start":{"line":19,"column":35},"end":{"line":19,"column":70}}]},"3":{"loc":{"start":{"line":19,"column":35},"end":{"line":19,"column":62}},"type":"cond-expr","locations":[{"start":{"line":19,"column":46},"end":{"line":19,"column":48}},{"start":{"line":19,"column":35},"end":{"line":19,"column":62}}]},"4":{"loc":{"start":{"line":19,"column":35},"end":{"line":19,"column":48}},"type":"binary-expr","locations":[{"start":{"line":19,"column":35},"end":{"line":19,"column":48}},{"start":{"line":19,"column":46},"end":{"line":19,"column":48}}]},"5":{"loc":{"start":{"line":20,"column":8},"end":{"line":20,"column":39}},"type":"binary-expr","locations":[{"start":{"line":20,"column":8},"end":{"line":20,"column":24}},{"start":{"line":20,"column":8},"end":{"line":20,"column":24}},{"start":{"line":20,"column":8},"end":{"line":20,"column":39}}]},"6":{"loc":{"start":{"line":23,"column":8},"end":{"line":23,"column":35}},"type":"binary-expr","locations":[{"start":{"line":23,"column":8},"end":{"line":23,"column":24}},{"start":{"line":23,"column":8},"end":{"line":23,"column":24}},{"start":{"line":23,"column":8},"end":{"line":23,"column":35}}]},"7":{"loc":{"start":{"line":27,"column":4},"end":{"line":27,"column":39}},"type":"binary-expr","locations":[{"start":{"line":27,"column":4},"end":{"line":27,"column":20}},{"start":{"line":27,"column":4},"end":{"line":27,"column":20}},{"start":{"line":27,"column":4},"end":{"line":27,"column":39}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0},"f":{"0":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0,0],"6":[0,0,0],"7":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":151,"column":1}},"6":{"start":{"line":9,"column":38},"end":{"line":9,"column":50}},"7":{"start":{"line":10,"column":25},"end":{"line":10,"column":33}},"8":{"start":{"line":15,"column":6},"end":{"line":15,"column":25}},"9":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"10":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"11":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"12":{"start":{"line":26,"column":34},"end":{"line":26,"column":92}},"13":{"start":{"line":27,"column":30},"end":{"line":33,"column":9}},"14":{"start":{"line":34,"column":2},"end":{"line":34,"column":null}},"15":{"start":{"line":35,"column":38},"end":{"line":35,"column":57}},"16":{"start":{"line":37,"column":25},"end":{"line":39,"column":16}},"17":{"start":{"line":41,"column":18},"end":{"line":41,"column":38}},"18":{"start":{"line":42,"column":15},"end":{"line":42,"column":46}},"19":{"start":{"line":44,"column":2},"end":{"line":51,"column":null}},"20":{"start":{"line":53,"column":2},"end":{"line":92,"column":null}},"21":{"start":{"line":94,"column":2},"end":{"line":124,"column":null}},"22":{"start":{"line":126,"column":2},"end":{"line":134,"column":null}},"23":{"start":{"line":136,"column":2},"end":{"line":139,"column":null}},"24":{"start":{"line":137,"column":4},"end":{"line":138,"column":null}},"25":{"start":{"line":141,"column":2},"end":{"line":150,"column":null}},"26":{"start":{"line":142,"column":19},"end":{"line":142,"column":52}},"27":{"start":{"line":143,"column":20},"end":{"line":148,"column":6}},"28":{"start":{"line":149,"column":4},"end":{"line":149,"column":null}},"29":{"start":{"line":151,"column":1},"end":{"line":151,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":8,"column":116},"end":{"line":151,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"type":"default-arg","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":null}}]},"1":{"loc":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":2},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":6},"end":{"line":17,"column":86}},"type":"binary-expr","locations":[{"start":{"line":17,"column":6},"end":{"line":17,"column":43}},{"start":{"line":17,"column":47},"end":{"line":17,"column":86}}]},"3":{"loc":{"start":{"line":27,"column":30},"end":{"line":33,"column":9}},"type":"cond-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":36}},{"start":{"line":29,"column":7},"end":{"line":33,"column":9}}]},"4":{"loc":{"start":{"line":37,"column":25},"end":{"line":39,"column":16}},"type":"cond-expr","locations":[{"start":{"line":38,"column":6},"end":{"line":38,"column":42}},{"start":{"line":39,"column":6},"end":{"line":39,"column":16}}]},"5":{"loc":{"start":{"line":136,"column":2},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":136,"column":2},"end":{"line":139,"column":null}}]},"6":{"loc":{"start":{"line":141,"column":2},"end":{"line":150,"column":null}},"type":"if","locations":[{"start":{"line":141,"column":2},"end":{"line":150,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0],"6":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":30},"end":{"line":29,"column":1}},"2":{"start":{"line":4,"column":43},"end":{"line":4,"column":55}},"3":{"start":{"line":5,"column":25},"end":{"line":5,"column":33}},"4":{"start":{"line":7,"column":18},"end":{"line":7,"column":38}},"5":{"start":{"line":8,"column":15},"end":{"line":8,"column":46}},"6":{"start":{"line":10,"column":2},"end":{"line":25,"column":null}},"7":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"8":{"start":{"line":28,"column":2},"end":{"line":28,"column":null}},"9":{"start":{"line":29,"column":1},"end":{"line":29,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":30},"end":{"line":3,"column":31}},"loc":{"start":{"line":3,"column":62},"end":{"line":29,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-handler.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-handler.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":174,"column":1}},"6":{"start":{"line":16,"column":56},"end":{"line":16,"column":64}},"7":{"start":{"line":17,"column":43},"end":{"line":17,"column":55}},"8":{"start":{"line":19,"column":41},"end":{"line":19,"column":99}},"9":{"start":{"line":20,"column":37},"end":{"line":26,"column":9}},"10":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"11":{"start":{"line":29,"column":37},"end":{"line":29,"column":63}},"12":{"start":{"line":31,"column":38},"end":{"line":31,"column":57}},"13":{"start":{"line":32,"column":25},"end":{"line":34,"column":16}},"14":{"start":{"line":36,"column":18},"end":{"line":36,"column":38}},"15":{"start":{"line":37,"column":15},"end":{"line":37,"column":46}},"16":{"start":{"line":39,"column":2},"end":{"line":86,"column":null}},"17":{"start":{"line":87,"column":2},"end":{"line":87,"column":null}},"18":{"start":{"line":88,"column":2},"end":{"line":88,"column":null}},"19":{"start":{"line":90,"column":2},"end":{"line":98,"column":null}},"20":{"start":{"line":100,"column":2},"end":{"line":129,"column":null}},"21":{"start":{"line":130,"column":2},"end":{"line":130,"column":null}},"22":{"start":{"line":131,"column":2},"end":{"line":131,"column":null}},"23":{"start":{"line":133,"column":2},"end":{"line":145,"column":null}},"24":{"start":{"line":147,"column":2},"end":{"line":160,"column":null}},"25":{"start":{"line":161,"column":2},"end":{"line":161,"column":null}},"26":{"start":{"line":162,"column":2},"end":{"line":162,"column":null}},"27":{"start":{"line":164,"column":2},"end":{"line":173,"column":null}},"28":{"start":{"line":165,"column":19},"end":{"line":165,"column":52}},"29":{"start":{"line":166,"column":20},"end":{"line":171,"column":6}},"30":{"start":{"line":172,"column":4},"end":{"line":172,"column":null}},"31":{"start":{"line":174,"column":1},"end":{"line":174,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":15,"column":6},"end":{"line":174,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":37},"end":{"line":26,"column":9}},"type":"cond-expr","locations":[{"start":{"line":21,"column":6},"end":{"line":21,"column":43}},{"start":{"line":22,"column":7},"end":{"line":26,"column":9}}]},"1":{"loc":{"start":{"line":31,"column":10},"end":{"line":31,"column":34}},"type":"default-arg","locations":[{"start":{"line":31,"column":23},"end":{"line":31,"column":34}}]},"2":{"loc":{"start":{"line":32,"column":25},"end":{"line":34,"column":16}},"type":"cond-expr","locations":[{"start":{"line":33,"column":6},"end":{"line":33,"column":42}},{"start":{"line":34,"column":6},"end":{"line":34,"column":16}}]},"3":{"loc":{"start":{"line":164,"column":2},"end":{"line":173,"column":null}},"type":"if","locations":[{"start":{"line":164,"column":2},"end":{"line":173,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0},"b":{"0":[0,0],"1":[0],"2":[0,0],"3":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-request-signer.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-request-signer.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"4":{"start":{"line":6,"column":27},"end":{"line":104,"column":1}},"5":{"start":{"line":7,"column":38},"end":{"line":7,"column":50}},"6":{"start":{"line":8,"column":25},"end":{"line":8,"column":33}},"7":{"start":{"line":10,"column":18},"end":{"line":10,"column":38}},"8":{"start":{"line":11,"column":15},"end":{"line":11,"column":46}},"9":{"start":{"line":13,"column":40},"end":{"line":13,"column":97}},"10":{"start":{"line":14,"column":36},"end":{"line":20,"column":9}},"11":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"12":{"start":{"line":23,"column":2},"end":{"line":57,"column":null}},"13":{"start":{"line":59,"column":2},"end":{"line":67,"column":null}},"14":{"start":{"line":69,"column":2},"end":{"line":91,"column":null}},"15":{"start":{"line":93,"column":2},"end":{"line":99,"column":null}},"16":{"start":{"line":101,"column":2},"end":{"line":103,"column":null}},"17":{"start":{"line":104,"column":1},"end":{"line":104,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":27},"end":{"line":6,"column":34}},"loc":{"start":{"line":6,"column":115},"end":{"line":104,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":36},"end":{"line":20,"column":9}},"type":"cond-expr","locations":[{"start":{"line":15,"column":6},"end":{"line":15,"column":42}},{"start":{"line":16,"column":7},"end":{"line":20,"column":9}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0},"b":{"0":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":22,"column":36},"end":{"line":75,"column":1}},"9":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"10":{"start":{"line":25,"column":34},"end":{"line":25,"column":44}},"11":{"start":{"line":26,"column":33},"end":{"line":26,"column":41}},"12":{"start":{"line":28,"column":19},"end":{"line":28,"column":56}},"13":{"start":{"line":30,"column":2},"end":{"line":46,"column":null}},"14":{"start":{"line":31,"column":4},"end":{"line":31,"column":null}},"15":{"start":{"line":32,"column":4},"end":{"line":39,"column":null}},"16":{"start":{"line":41,"column":32},"end":{"line":44,"column":6}},"17":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"18":{"start":{"line":48,"column":18},"end":{"line":48,"column":38}},"19":{"start":{"line":49,"column":34},"end":{"line":54,"column":4}},"20":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"21":{"start":{"line":57,"column":2},"end":{"line":57,"column":null}},"22":{"start":{"line":59,"column":22},"end":{"line":61,"column":null}},"23":{"start":{"line":64,"column":2},"end":{"line":70,"column":null}},"24":{"start":{"line":65,"column":4},"end":{"line":69,"column":null}},"25":{"start":{"line":72,"column":2},"end":{"line":72,"column":null}},"26":{"start":{"line":74,"column":2},"end":{"line":74,"column":null}},"27":{"start":{"line":75,"column":1},"end":{"line":75,"column":null}},"28":{"start":{"line":77,"column":19},"end":{"line":90,"column":1}},"29":{"start":{"line":79,"column":18},"end":{"line":79,"column":47}},"30":{"start":{"line":80,"column":21},"end":{"line":80,"column":46}},"31":{"start":{"line":82,"column":27},"end":{"line":87,"column":4}},"32":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":22,"column":36},"end":{"line":22,"column":43}},"loc":{"start":{"line":22,"column":98},"end":{"line":75,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":77,"column":19},"end":{"line":77,"column":26}},"loc":{"start":{"line":77,"column":65},"end":{"line":90,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":30,"column":2},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":2},"end":{"line":46,"column":null}}]},"1":{"loc":{"start":{"line":64,"column":2},"end":{"line":70,"column":null}},"type":"if","locations":[{"start":{"line":64,"column":2},"end":{"line":70,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs","statementMap":{"0":{"start":{"line":1,"column":37},"end":{"line":43,"column":1}},"1":{"start":{"line":2,"column":28},"end":{"line":2,"column":40}},"2":{"start":{"line":3,"column":29},"end":{"line":3,"column":56}},"3":{"start":{"line":5,"column":2},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":20},"end":{"line":7,"column":108}},"5":{"start":{"line":8,"column":2},"end":{"line":17,"column":null}},"6":{"start":{"line":20,"column":4},"end":{"line":20,"column":105}},"7":{"start":{"line":21,"column":2},"end":{"line":39,"column":null}},"8":{"start":{"line":41,"column":2},"end":{"line":41,"column":null}},"9":{"start":{"line":42,"column":2},"end":{"line":42,"column":null}},"10":{"start":{"line":43,"column":1},"end":{"line":43,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":37},"end":{"line":1,"column":38}},"loc":{"start":{"line":1,"column":71},"end":{"line":43,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":4},"end":{"line":20,"column":105}},"type":"binary-expr","locations":[{"start":{"line":20,"column":4},"end":{"line":20,"column":99}},{"start":{"line":20,"column":103},"end":{"line":20,"column":105}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/convert-domain-to-bucket-name.js": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/convert-domain-to-bucket-name.js","statementMap":{"0":{"start":{"line":1,"column":35},"end":{"line":1,"column":106}},"1":{"start":{"line":1,"column":46},"end":{"line":1,"column":106}},"2":{"start":{"line":1,"column":106},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":35},"end":{"line":1,"column":41}},"loc":{"start":{"line":1,"column":46},"end":{"line":1,"column":106}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/shared/determine-bucket-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/determine-bucket-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":9,"column":28},"end":{"line":50,"column":1}},"6":{"start":{"line":10,"column":66},"end":{"line":10,"column":70}},"7":{"start":{"line":11,"column":33},"end":{"line":11,"column":37}},"8":{"start":{"line":13,"column":2},"end":{"line":15,"column":null}},"9":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"10":{"start":{"line":17,"column":24},"end":{"line":17,"column":32}},"11":{"start":{"line":18,"column":2},"end":{"line":21,"column":null}},"12":{"start":{"line":19,"column":22},"end":{"line":19,"column":57}},"13":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"14":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"15":{"start":{"line":25,"column":2},"end":{"line":49,"column":null}},"16":{"start":{"line":26,"column":4},"end":{"line":26,"column":null}},"17":{"start":{"line":28,"column":18},"end":{"line":28,"column":74}},"18":{"start":{"line":30,"column":20},"end":{"line":30,"column":48}},"19":{"start":{"line":31,"column":4},"end":{"line":44,"column":null}},"20":{"start":{"line":32,"column":6},"end":{"line":32,"column":null}},"21":{"start":{"line":33,"column":6},"end":{"line":35,"column":null}},"22":{"start":{"line":34,"column":8},"end":{"line":34,"column":null}},"23":{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},"24":{"start":{"line":38,"column":8},"end":{"line":38,"column":null}},"25":{"start":{"line":39,"column":8},"end":{"line":39,"column":null}},"26":{"start":{"line":40,"column":13},"end":{"line":43,"column":null}},"27":{"start":{"line":41,"column":8},"end":{"line":41,"column":null}},"28":{"start":{"line":42,"column":8},"end":{"line":42,"column":null}},"29":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"30":{"start":{"line":46,"column":23},"end":{"line":46,"column":43}},"31":{"start":{"line":47,"column":4},"end":{"line":47,"column":null}},"32":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}},"33":{"start":{"line":50,"column":1},"end":{"line":50,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":28},"end":{"line":9,"column":35}},"loc":{"start":{"line":9,"column":44},"end":{"line":50,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":35},"end":{"line":10,"column":51}},"type":"default-arg","locations":[{"start":{"line":10,"column":46},"end":{"line":10,"column":51}}]},"1":{"loc":{"start":{"line":13,"column":2},"end":{"line":15,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":15,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":77}},"type":"binary-expr","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":36}},{"start":{"line":14,"column":40},"end":{"line":14,"column":77}}]},"3":{"loc":{"start":{"line":18,"column":2},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":18,"column":2},"end":{"line":21,"column":null}}]},"4":{"loc":{"start":{"line":23,"column":13},"end":{"line":23,"column":54}},"type":"binary-expr","locations":[{"start":{"line":23,"column":13},"end":{"line":23,"column":21}},{"start":{"line":23,"column":25},"end":{"line":23,"column":54}}]},"5":{"loc":{"start":{"line":33,"column":6},"end":{"line":35,"column":null}},"type":"if","locations":[{"start":{"line":33,"column":6},"end":{"line":35,"column":null}}]},"6":{"loc":{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},{"start":{"line":40,"column":13},"end":{"line":43,"column":null}}]},"7":{"loc":{"start":{"line":40,"column":13},"end":{"line":43,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":13},"end":{"line":43,"column":null}}]},"8":{"loc":{"start":{"line":40,"column":17},"end":{"line":40,"column":75}},"type":"binary-expr","locations":[{"start":{"line":40,"column":17},"end":{"line":40,"column":34}},{"start":{"line":40,"column":38},"end":{"line":40,"column":75}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/determine-oac-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/determine-oac-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":25},"end":{"line":27,"column":1}},"4":{"start":{"line":8,"column":21},"end":{"line":8,"column":29}},"5":{"start":{"line":9,"column":20},"end":{"line":9,"column":28}},"6":{"start":{"line":13,"column":22},"end":{"line":13,"column":67}},"7":{"start":{"line":15,"column":2},"end":{"line":26,"column":null}},"8":{"start":{"line":16,"column":4},"end":{"line":16,"column":null}},"9":{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},"10":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"11":{"start":{"line":19,"column":23},"end":{"line":19,"column":43}},"12":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"13":{"start":{"line":21,"column":6},"end":{"line":21,"column":null}},"14":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"15":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"16":{"start":{"line":27,"column":1},"end":{"line":27,"column":null}},"17":{"start":{"line":29,"column":23},"end":{"line":48,"column":1}},"18":{"start":{"line":30,"column":27},"end":{"line":30,"column":72}},"19":{"start":{"line":32,"column":17},"end":{"line":32,"column":19}},"20":{"start":{"line":33,"column":2},"end":{"line":47,"column":null}},"21":{"start":{"line":34,"column":27},"end":{"line":36,"column":6}},"22":{"start":{"line":38,"column":28},"end":{"line":38,"column":71}},"23":{"start":{"line":39,"column":18},"end":{"line":39,"column":69}},"24":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"25":{"start":{"line":41,"column":50},"end":{"line":41,"column":54}},"26":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"27":{"start":{"line":44,"column":4},"end":{"line":46,"column":null}},"28":{"start":{"line":45,"column":6},"end":{"line":45,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":25},"end":{"line":7,"column":32}},"loc":{"start":{"line":7,"column":72},"end":{"line":27,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":29,"column":23},"end":{"line":29,"column":30}},"loc":{"start":{"line":29,"column":58},"end":{"line":48,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":41,"column":29},"end":{"line":41,"column":30}},"loc":{"start":{"line":41,"column":50},"end":{"line":41,"column":54}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":4},"end":{"line":16,"column":78}},"type":"binary-expr","locations":[{"start":{"line":16,"column":4},"end":{"line":16,"column":20}},{"start":{"line":16,"column":4},"end":{"line":16,"column":20}},{"start":{"line":16,"column":4},"end":{"line":16,"column":78}}]},"1":{"loc":{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},{"start":{"line":22,"column":11},"end":{"line":25,"column":null}}]},"2":{"loc":{"start":{"line":18,"column":6},"end":{"line":18,"column":41}},"type":"binary-expr","locations":[{"start":{"line":18,"column":6},"end":{"line":18,"column":22}},{"start":{"line":18,"column":6},"end":{"line":18,"column":22}},{"start":{"line":18,"column":6},"end":{"line":18,"column":41}}]},"3":{"loc":{"start":{"line":23,"column":6},"end":{"line":23,"column":37}},"type":"binary-expr","locations":[{"start":{"line":23,"column":6},"end":{"line":23,"column":22}},{"start":{"line":23,"column":6},"end":{"line":23,"column":22}},{"start":{"line":23,"column":6},"end":{"line":23,"column":37}}]},"4":{"loc":{"start":{"line":39,"column":18},"end":{"line":39,"column":69}},"type":"binary-expr","locations":[{"start":{"line":39,"column":18},"end":{"line":39,"column":63}},{"start":{"line":39,"column":67},"end":{"line":39,"column":69}}]},"5":{"loc":{"start":{"line":44,"column":4},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":44,"column":4},"end":{"line":46,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0,0],"3":[0,0,0],"4":[0,0],"5":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/find-bucket-like.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/find-bucket-like.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":23},"end":{"line":25,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":7,"column":48}},"5":{"start":{"line":8,"column":29},"end":{"line":8,"column":55}},"6":{"start":{"line":9,"column":32},"end":{"line":9,"column":71}},"7":{"start":{"line":11,"column":26},"end":{"line":11,"column":91}},"8":{"start":{"line":11,"column":62},"end":{"line":11,"column":90}},"9":{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},"10":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"11":{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},"12":{"start":{"line":16,"column":29},"end":{"line":16,"column":52}},"13":{"start":{"line":17,"column":4},"end":{"line":17,"column":null}},"14":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"15":{"start":{"line":21,"column":4},"end":{"line":21,"column":null}},"16":{"start":{"line":22,"column":4},"end":{"line":23,"column":null}},"17":{"start":{"line":23,"column":49},"end":{"line":23,"column":53}},"18":{"start":{"line":25,"column":1},"end":{"line":25,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":23},"end":{"line":5,"column":30}},"loc":{"start":{"line":5,"column":76},"end":{"line":25,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":11,"column":41},"end":{"line":11,"column":42}},"loc":{"start":{"line":11,"column":62},"end":{"line":11,"column":90}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":23,"column":28},"end":{"line":23,"column":29}},"loc":{"start":{"line":23,"column":49},"end":{"line":23,"column":53}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":71}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":71}}]},"1":{"loc":{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},{"start":{"line":15,"column":9},"end":{"line":24,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":41}},"type":"binary-expr","locations":[{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":41}}]},"3":{"loc":{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},{"start":{"line":19,"column":9},"end":{"line":24,"column":null}}]},"4":{"loc":{"start":{"line":17,"column":4},"end":{"line":17,"column":62}},"type":"binary-expr","locations":[{"start":{"line":17,"column":4},"end":{"line":17,"column":20}},{"start":{"line":17,"column":4},"end":{"line":17,"column":20}},{"start":{"line":17,"column":4},"end":{"line":17,"column":62}}]},"5":{"loc":{"start":{"line":21,"column":4},"end":{"line":21,"column":45}},"type":"binary-expr","locations":[{"start":{"line":21,"column":4},"end":{"line":21,"column":20}},{"start":{"line":21,"column":4},"end":{"line":21,"column":20}},{"start":{"line":21,"column":4},"end":{"line":21,"column":45}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0,0,0],"5":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/get-account-id.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/get-account-id.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":21},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":7,"column":94}},"5":{"start":{"line":8,"column":20},"end":{"line":8,"column":36}},"6":{"start":{"line":10,"column":2},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":21},"end":{"line":5,"column":28}},"loc":{"start":{"line":5,"column":48},"end":{"line":11,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":60}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":60}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{"0":[0,0,0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/get-site-tag.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/get-site-tag.mjs","statementMap":{"0":{"start":{"line":1,"column":20},"end":{"line":3,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":1},"end":{"line":3,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":20},"end":{"line":1,"column":28}},"loc":{"start":{"line":1,"column":33},"end":{"line":3,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0},"f":{"0":0},"b":{}} +,"/Users/zane/playground/cloudsite/src/lib/shared/progress-logger.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/progress-logger.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":20},"end":{"line":3,"column":25}},"2":{"start":{"line":5,"column":25},"end":{"line":16,"column":1}},"3":{"start":{"line":6,"column":16},"end":{"line":6,"column":35}},"4":{"start":{"line":8,"column":2},"end":{"line":15,"column":null}},"5":{"start":{"line":10,"column":22},"end":{"line":10,"column":29}},"6":{"start":{"line":12,"column":4},"end":{"line":14,"column":null}},"7":{"start":{"line":13,"column":6},"end":{"line":13,"column":null}},"8":{"start":{"line":16,"column":1},"end":{"line":16,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":25},"end":{"line":5,"column":32}},"loc":{"start":{"line":5,"column":37},"end":{"line":16,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":25},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":39},"end":{"line":15,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":4},"end":{"line":14,"column":null}},"type":"if","locations":[{"start":{"line":12,"column":4},"end":{"line":14,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":1,"4":1,"5":0,"6":0,"7":0,"8":2},"f":{"0":1,"1":0},"b":{"0":[0]}} +,"/Users/zane/playground/cloudsite/src/lib/shared/site-template.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/site-template.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"4":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"5":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"6":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":0},"end":{"line":11,"column":50}},"8":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"9":{"start":{"line":17,"column":21},"end":{"line":267,"column":1}},"10":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"11":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"12":{"start":{"line":42,"column":4},"end":{"line":42,"column":null}},"13":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"14":{"start":{"line":47,"column":25},"end":{"line":47,"column":29}},"15":{"start":{"line":48,"column":74},"end":{"line":48,"column":82}},"16":{"start":{"line":49,"column":20},"end":{"line":49,"column":40}},"17":{"start":{"line":51,"column":20},"end":{"line":57,"column":8}},"18":{"start":{"line":58,"column":4},"end":{"line":58,"column":null}},"19":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"20":{"start":{"line":61,"column":4},"end":{"line":164,"column":null}},"21":{"start":{"line":168,"column":25},"end":{"line":168,"column":29}},"22":{"start":{"line":169,"column":33},"end":{"line":169,"column":41}},"23":{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},"24":{"start":{"line":172,"column":6},"end":{"line":172,"column":null}},"25":{"start":{"line":173,"column":23},"end":{"line":173,"column":71}},"26":{"start":{"line":174,"column":6},"end":{"line":179,"column":null}},"27":{"start":{"line":180,"column":6},"end":{"line":180,"column":null}},"28":{"start":{"line":182,"column":6},"end":{"line":182,"column":null}},"29":{"start":{"line":187,"column":27},"end":{"line":187,"column":40}},"30":{"start":{"line":188,"column":61},"end":{"line":188,"column":74}},"31":{"start":{"line":189,"column":20},"end":{"line":189,"column":45}},"32":{"start":{"line":191,"column":4},"end":{"line":198,"column":null}},"33":{"start":{"line":192,"column":6},"end":{"line":197,"column":null}},"34":{"start":{"line":199,"column":4},"end":{"line":199,"column":null}},"35":{"start":{"line":201,"column":4},"end":{"line":211,"column":null}},"36":{"start":{"line":213,"column":4},"end":{"line":213,"column":null}},"37":{"start":{"line":217,"column":25},"end":{"line":217,"column":29}},"38":{"start":{"line":218,"column":27},"end":{"line":218,"column":35}},"39":{"start":{"line":219,"column":24},"end":{"line":219,"column":46}},"40":{"start":{"line":221,"column":4},"end":{"line":231,"column":null}},"41":{"start":{"line":222,"column":21},"end":{"line":222,"column":39}},"42":{"start":{"line":223,"column":6},"end":{"line":225,"column":null}},"43":{"start":{"line":224,"column":8},"end":{"line":224,"column":null}},"44":{"start":{"line":227,"column":41},"end":{"line":227,"column":47}},"45":{"start":{"line":228,"column":6},"end":{"line":230,"column":null}},"46":{"start":{"line":229,"column":8},"end":{"line":229,"column":null}},"47":{"start":{"line":235,"column":25},"end":{"line":235,"column":29}},"48":{"start":{"line":236,"column":27},"end":{"line":236,"column":35}},"49":{"start":{"line":237,"column":24},"end":{"line":237,"column":46}},"50":{"start":{"line":239,"column":26},"end":{"line":239,"column":28}},"51":{"start":{"line":240,"column":4},"end":{"line":247,"column":null}},"52":{"start":{"line":241,"column":21},"end":{"line":241,"column":39}},"53":{"start":{"line":242,"column":6},"end":{"line":244,"column":null}},"54":{"start":{"line":243,"column":8},"end":{"line":243,"column":null}},"55":{"start":{"line":246,"column":6},"end":{"line":246,"column":null}},"56":{"start":{"line":249,"column":4},"end":{"line":249,"column":null}},"57":{"start":{"line":253,"column":27},"end":{"line":253,"column":40}},"58":{"start":{"line":254,"column":26},"end":{"line":254,"column":64}},"59":{"start":{"line":256,"column":27},"end":{"line":261,"column":5}},"60":{"start":{"line":264,"column":19},"end":{"line":264,"column":78}},"61":{"start":{"line":265,"column":4},"end":{"line":265,"column":null}},"62":{"start":{"line":267,"column":1},"end":{"line":267,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":38,"column":2},"end":{"line":38,"column":13}},"loc":{"start":{"line":38,"column":42},"end":{"line":44,"column":null}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":46,"column":2},"end":{"line":46,"column":8}},"loc":{"start":{"line":46,"column":45},"end":{"line":165,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":167,"column":2},"end":{"line":167,"column":8}},"loc":{"start":{"line":167,"column":35},"end":{"line":184,"column":null}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":186,"column":2},"end":{"line":186,"column":8}},"loc":{"start":{"line":186,"column":34},"end":{"line":214,"column":null}}},"5":{"name":"(anonymous_7)","decl":{"start":{"line":216,"column":2},"end":{"line":216,"column":8}},"loc":{"start":{"line":216,"column":26},"end":{"line":232,"column":null}}},"6":{"name":"(anonymous_8)","decl":{"start":{"line":234,"column":2},"end":{"line":234,"column":8}},"loc":{"start":{"line":234,"column":38},"end":{"line":250,"column":null}}},"7":{"name":"(anonymous_9)","decl":{"start":{"line":252,"column":2},"end":{"line":252,"column":8}},"loc":{"start":{"line":252,"column":12},"end":{"line":266,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"1":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"cond-expr","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"2":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"binary-expr","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"3":{"loc":{"start":{"line":46,"column":28},"end":{"line":46,"column":43}},"type":"default-arg","locations":[{"start":{"line":46,"column":41},"end":{"line":46,"column":43}}]},"4":{"loc":{"start":{"line":51,"column":20},"end":{"line":57,"column":8}},"type":"cond-expr","locations":[{"start":{"line":52,"column":8},"end":{"line":52,"column":24}},{"start":{"line":53,"column":8},"end":{"line":57,"column":8}}]},"5":{"loc":{"start":{"line":58,"column":4},"end":{"line":58,"column":57}},"type":"binary-expr","locations":[{"start":{"line":58,"column":4},"end":{"line":58,"column":20}},{"start":{"line":58,"column":4},"end":{"line":58,"column":20}},{"start":{"line":58,"column":4},"end":{"line":58,"column":57}}]},"6":{"loc":{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},"type":"if","locations":[{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},{"start":{"line":181,"column":11},"end":{"line":183,"column":null}}]},"7":{"loc":{"start":{"line":182,"column":6},"end":{"line":182,"column":105}},"type":"binary-expr","locations":[{"start":{"line":182,"column":6},"end":{"line":182,"column":22}},{"start":{"line":182,"column":6},"end":{"line":182,"column":22}},{"start":{"line":182,"column":6},"end":{"line":182,"column":105}}]},"8":{"loc":{"start":{"line":188,"column":10},"end":{"line":188,"column":57}},"type":"default-arg","locations":[{"start":{"line":188,"column":29},"end":{"line":188,"column":57}}]},"9":{"loc":{"start":{"line":191,"column":4},"end":{"line":198,"column":null}},"type":"if","locations":[{"start":{"line":191,"column":4},"end":{"line":198,"column":null}}]},"10":{"loc":{"start":{"line":219,"column":24},"end":{"line":219,"column":46}},"type":"binary-expr","locations":[{"start":{"line":219,"column":24},"end":{"line":219,"column":40}},{"start":{"line":219,"column":44},"end":{"line":219,"column":46}}]},"11":{"loc":{"start":{"line":223,"column":6},"end":{"line":225,"column":null}},"type":"if","locations":[{"start":{"line":223,"column":6},"end":{"line":225,"column":null}}]},"12":{"loc":{"start":{"line":228,"column":6},"end":{"line":230,"column":null}},"type":"if","locations":[{"start":{"line":228,"column":6},"end":{"line":230,"column":null}}]},"13":{"loc":{"start":{"line":234,"column":21},"end":{"line":234,"column":36}},"type":"default-arg","locations":[{"start":{"line":234,"column":34},"end":{"line":234,"column":36}}]},"14":{"loc":{"start":{"line":237,"column":24},"end":{"line":237,"column":46}},"type":"binary-expr","locations":[{"start":{"line":237,"column":24},"end":{"line":237,"column":40}},{"start":{"line":237,"column":44},"end":{"line":237,"column":46}}]},"15":{"loc":{"start":{"line":242,"column":6},"end":{"line":244,"column":null}},"type":"if","locations":[{"start":{"line":242,"column":6},"end":{"line":244,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0,0],"6":[0,0],"7":[0,0,0],"8":[0],"9":[0],"10":[0,0],"11":[0],"12":[0],"13":[0],"14":[0,0],"15":[0]}} +} diff --git a/qa/coverage/favicon.png b/qa/coverage/favicon.png new file mode 100644 index 0000000000000000000000000000000000000000..c1525b811a167671e9de1fa78aab9f5c0b61cef7 GIT binary patch literal 445 zcmV;u0Yd(XP))rP{nL}Ln%S7`m{0DjX9TLF* zFCb$4Oi7vyLOydb!7n&^ItCzb-%BoB`=x@N2jll2Nj`kauio%aw_@fe&*}LqlFT43 z8doAAe))z_%=P%v^@JHp3Hjhj^6*Kr_h|g_Gr?ZAa&y>wxHE99Gk>A)2MplWz2xdG zy8VD2J|Uf#EAw*bo5O*PO_}X2Tob{%bUoO2G~T`@%S6qPyc}VkhV}UifBuRk>%5v( z)x7B{I~z*k<7dv#5tC+m{km(D087J4O%+<<;K|qwefb6@GSX45wCK}Sn*> + + + + Code coverage report for All files + + + + + + + + + +
+
+

All files

+
+ +
+ 1.3% + Statements + 19/1460 +
+ + +
+ 0.16% + Branches + 1/590 +
+ + +
+ 2.38% + Functions + 3/126 +
+ + +
+ 1.33% + Lines + 19/1419 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
cli +
+
0%0/1110%0/530%0/40%0/99
cli/lib +
+
0%0/4610%0/2060%0/370%0/451
cli/lib/configuration +
+
100%13/1350%1/2100%2/2100%13/13
cli/lib/plugin-settings +
+
0%0/450%0/310%0/70%0/44
lib/actions +
+
0%0/3000%0/1210%0/190%0/291
lib/actions/lib +
+
0%0/1810%0/600%0/220%0/177
lib/plugins +
+
0%0/200%0/10%0/70%0/20
lib/plugins/contact-handler/lib +
+
0%0/1610%0/420%0/80%0/161
lib/shared +
+
3.57%6/1680%0/745%1/203.68%6/163
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/create.mjs.html b/qa/coverage/lib/actions/create.mjs.html new file mode 100644 index 00000000..b82a5bfb --- /dev/null +++ b/qa/coverage/lib/actions/create.mjs.html @@ -0,0 +1,547 @@ + + + + + + Code coverage report for lib/actions/create.mjs + + + + + + + + + +
+
+

All files / lib/actions create.mjs

+
+ +
+ 0% + Statements + 0/72 +
+ + +
+ 0% + Branches + 0/14 +
+ + +
+ 0% + Functions + 0/7 +
+ + +
+ 0% + Lines + 0/71 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { ACMClient, RequestCertificateCommand } from '@aws-sdk/client-acm'
+import { CloudFormationClient, CreateStackCommand } from '@aws-sdk/client-cloudformation'
+ 
+import {
+  associateCostAllocationTags,
+  handleAssociateCostAllocationTagsError
+} from './lib/associate-cost-allocation-tags'
+import { convertDomainToBucketName } from '../shared/convert-domain-to-bucket-name'
+import { createOrUpdateDNSRecords } from './lib/create-or-update-dns-records'
+import { determineBucketName } from '../shared/determine-bucket-name'
+import { findCertificate } from './lib/find-certificate'
+import { getCredentials } from './lib/get-credentials'
+import { getSiteTag } from '../shared/get-site-tag'
+import * as plugins from '../plugins'
+import { progressLogger } from '../shared/progress-logger'
+import { SiteTemplate } from '../shared/site-template'
+import { syncSiteContent } from './lib/sync-site-content'
+import { trackStackStatus } from './lib/track-stack-status'
+import { updateSiteInfo } from './lib/update-site-info'I
+ 
+const STACK_CREATE_TIMEOUT = 30 // min
+ 
+const create = async ({
+  db,
+  noBuild,
+  noDeleteOnFailure,
+  siteInfo
+}) => {
+  const { apexDomain } = siteInfo
+  let { bucketName } = siteInfo
+ 
+  const credentials = getCredentials(db.account.settings)
+ 
+  const acmClient = new ACMClient({
+    credentials,
+    region : 'us-east-1' // N. Virginia; required for certificate request
+  })
+ 
+  let { certificateArn, status } = await findCertificate({ acmClient, apexDomain })
+  Iif (certificateArn === null) {
+    progressLogger.write(`Creating wildcard certificate for '${apexDomain}'...`)
+    certificateArn = await createCertificate({ acmClient, apexDomain })
+    status = 'PENDING_VALIDATION'
+  }
+  siteInfo.certificateArn = certificateArn
+ 
+  Iif (status === 'PENDING_VALIDATION') {
+    const accountLocalCertID = certificateArn.replace(/[^/]+\/(.+)/, '$1')
+    const certificateConsoleURL =
+      `https://us-east-1.console.aws.amazon.com/acm/home?region=us-east-1#/certificates/${accountLocalCertID}`
+    throw new Error(`Wildcard certificate for '${apexDomain}' found, but requires validation. Please validate the certificate. To validate on S3 when using Route 53 for DNS service, try navigating to the folliwng URL and select 'Create records in Route 53'::\n\n${certificateConsoleURL}\n\nSubsequent validation may take up to 30 minutes. For further documentation:\n\nhttps://docs.aws.amazon.com/acm/latest/userguide/dns-validation.html`)
+  }
+ 
+  bucketName = await determineBucketName({ apexDomain, bucketName, credentials, findName : true, siteInfo })
+  siteInfo.bucketName = bucketName
+  const stackCreated = await createSiteStack({ credentials, noDeleteOnFailure, siteInfo })
+ 
+  if (stackCreated === true) {
+    const postUpdateHandlers = Object.keys(siteInfo.plugins || {}).map((pluginKey) =>
+      [pluginKey, plugins[pluginKey].postUpdateHandler]
+    )
+      .filter(([, postUpdateHandler]) => postUpdateHandler !== undefined)
+ 
+    await updateSiteInfo({ credentials, siteInfo }) // needed by createOrUpdateDNSRecords
+ 
+    const siteTag = getSiteTag(siteInfo)
+ 
+    // TODO: speeds things up, but if one fail, it all fails and is unclear; maybe we should break it up?
+    await Promise.all([
+      syncSiteContent({ credentials, noBuild, siteInfo }),
+      createOrUpdateDNSRecords({ credentials, siteInfo }),
+      ...(postUpdateHandlers.map(([pluginKey, handler]) =>
+        handler({ pluginData : siteInfo.plugins[pluginKey], siteInfo })))
+    ])
+ 
+    try {
+      await associateCostAllocationTags({ credentials, tag : siteTag })
+    } catch (e) {
+      handleAssociateCostAllocationTagsError({ e, siteInfo })
+    }
+ 
+    return true
+  } else {
+    return false
+  }
+}
+ 
+const createCertificate = async ({ acmClient, apexDomain }) => {
+  progressLogger.write(`Creating wildcard certificate for '${apexDomain}'...`)
+  const input = { // RequestCertificateRequest
+    DomainName              : '*.' + apexDomain, // TODO: support more narrow cert?
+    ValidationMethod        : 'DNS', // TODO: support email
+    SubjectAlternativeNames : [
+      apexDomain, 'www.' + apexDomain
+    ], /*
+    // IdempotencyToken: "STRING_VALUE", TODO: should we use this?
+    /* DomainValidationOptions: [ // DomainValidationOptionList : TODO: is this only used for email verification?
+      { // DomainValidationOption
+        DomainName: "STRING_VALUE", // required
+        ValidationDomain: "STRING_VALUE", // required
+      },
+    ], */
+    Options : { // CertificateOptions
+      CertificateTransparencyLoggingPreference : 'ENABLED'
+    },
+    // CertificateAuthorityArn: "STRING_VALUE", TODO: only used for private certs, I think
+    /* Tags: [ // TagList : TODO: support tags? tag with the website
+      { // Tag
+        Key: "STRING_VALUE", // required
+        Value: "STRING_VALUE",
+      },
+    ], */
+    KeyAlgorithm : 'RSA_2048' // TODO: support key options"RSA_1024" || "RSA_2048" || "RSA_3072" || "RSA_4096" || "EC_prime256v1" || "EC_secp384r1" || "EC_secp521r1",
+  }
+  // this method can safely be called multiple times; it'll  match  existing certs (by domain name I'd assume)
+  const command = new RequestCertificateCommand(input)
+  const response = await acmClient.send(command)
+ 
+  const { CertificateArn } = response
+ 
+  return CertificateArn
+}
+ 
+const createSiteStack = async ({ credentials, noDeleteOnFailure, siteInfo }) => {
+  const { apexDomain, region } = siteInfo
+ 
+  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
+  await siteTemplate.initializeTemplate()
+  await siteTemplate.loadPlugins()
+ 
+  const cloudFormationTemplate = siteTemplate.render()
+ 
+  const cloudFormationClient = new CloudFormationClient({ credentials, region })
+  const stackName = siteInfo.stackName || convertDomainToBucketName(apexDomain) + '-stack'
+  const createInput = {
+    StackName        : stackName,
+    TemplateBody     : cloudFormationTemplate,
+    DisableRollback  : false,
+    Capabilities     : ['CAPABILITY_IAM', 'CAPABILITY_NAMED_IAM'],
+    TimeoutInMinutes : STACK_CREATE_TIMEOUT
+  }
+  const createCommand = new CreateStackCommand(createInput)
+  const createResponse = await cloudFormationClient.send(createCommand)
+ 
+  const { StackId } = createResponse
+ 
+  siteInfo.stackName = stackName
+  siteInfo.stackArn = StackId
+ 
+  const finalStatus = await trackStackStatus({ cloudFormationClient, noDeleteOnFailure, stackName })
+  return { success : finalStatus === 'CREATE_COMPLETE', stackName }
+}
+ 
+export { create }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/destroy.mjs.html b/qa/coverage/lib/actions/destroy.mjs.html new file mode 100644 index 00000000..b0ec2511 --- /dev/null +++ b/qa/coverage/lib/actions/destroy.mjs.html @@ -0,0 +1,274 @@ + + + + + + Code coverage report for lib/actions/destroy.mjs + + + + + + + + + +
+
+

All files / lib/actions destroy.mjs

+
+ +
+ 0% + Statements + 0/40 +
+ + +
+ 0% + Branches + 0/21 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/36 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { S3Client } from '@aws-sdk/client-s3'
+import { CloudFormationClient, DeleteStackCommand } from '@aws-sdk/client-cloudformation'
+ 
+import { emptyBucket } from 's3-empty-bucket'
+ 
+import { getCredentials } from './lib/get-credentials'
+import { progressLogger } from '../shared/progress-logger'
+import { SiteTemplate } from '../shared/site-template'
+import { trackStackStatus } from './lib/track-stack-status'
+ 
+const destroy = async ({ db, siteInfo, verbose }) => {
+  const { apexDomain, bucketName, stackName } = siteInfo
+ 
+  const credentials = getCredentials(db.account.settings)
+  const s3Client = new S3Client({ credentials })
+ 
+  // this method provides user udptaes
+  try {
+    Iif (verbose === true) { progressLogger?.write('Deleting site bucket...\n') }
+    await emptyBucket({ bucketName, doDelete : true, s3Client, verbose })
+  } catch (e) {
+    if (e.name === 'NoSuchBucket') {
+      Iif (verbose === true) { progressLogger?.write('Bucket already deleted.\n') }
+    } else {
+      throw e
+    }
+  }
+ 
+  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
+  await siteTemplate.destroyPlugins()
+ 
+  Iif (verbose === true) { progressLogger.write(`Deleting stack for ${apexDomain}`) }
+  const cloudFormationClient = new CloudFormationClient({ credentials })
+  const deleteStackCommand = new DeleteStackCommand({ StackName : stackName })
+  await cloudFormationClient.send(deleteStackCommand)
+ 
+  // the delete command is doesn't mind if the bucket doesn't exist, but trackStackStatus does
+  try {
+    const finalStatus =
+      await trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, noInitialStatus : true, stackName })
+    progressLogger.write('\n')
+ 
+    if (finalStatus === 'DELETE_FAILED') {
+      return false
+    } else if (finalStatus === 'DELETE_COMPLETE') { // actually, we should never see this, see note below
+      return true
+    } else {
+      throw new Error(`Unexpected final status after delete: ${finalStatus}`)
+    }
+  } catch (e) {
+    // if the stack does not exist we get a ValidationError; so this is the expected outcome when deleting a stack as
+    // the last call for update will result in a validation error.
+    if (e.name === 'ValidationError') {
+      return true
+    } else {
+      throw e
+    }
+  } finally {
+    Iif (verbose === true) { progressLogger?.write('\n') }
+  }
+}
+ 
+export { destroy }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/import.mjs.html b/qa/coverage/lib/actions/import.mjs.html new file mode 100644 index 00000000..94e725fb --- /dev/null +++ b/qa/coverage/lib/actions/import.mjs.html @@ -0,0 +1,304 @@ + + + + + + Code coverage report for lib/actions/import.mjs + + + + + + + + + +
+
+

All files / lib/actions import.mjs

+
+ +
+ 0% + Statements + 0/47 +
+ + +
+ 0% + Branches + 0/25 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/46 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import yaml from 'js-yaml'
+ 
+import { ACMClient } from '@aws-sdk/client-acm'
+import { CloudFormationClient, DescribeStacksCommand, GetTemplateCommand } from '@aws-sdk/client-cloudformation'
+ 
+import { getAccountID } from '../shared/get-account-id'
+import { getCredentials } from './lib/get-credentials'
+import { findBucketLike } from '../shared/find-bucket-like'
+import { findCertificate } from './lib/find-certificate'
+import * as plugins from '../plugins'
+import { progressLogger } from '../shared/progress-logger'I
+ 
+const doImport = async ({ commonLogsBucket, db, domain, region, sourcePath, sourceType, stack }) => {
+  const siteInfo = { apexDomain : domain, stackName : stack, region, sourcePath, sourceType }
+  const credentials = getCredentials(db.account.settings)
+ 
+  const acmClient = new ACMClient({ credentials, region : 'us-east-1' }) // certificates are always in us-east-1
+  const { certificateArn } = await findCertificate({ apexDomain : domain, acmClient })
+  siteInfo.certificateArn = certificateArn
+ 
+  const accountID = await getAccountID({ credentials })
+  siteInfo.accountID = accountID
+ 
+  progressLogger?.write(`Examining stack '${stack}' outputs...\n`)
+  const cloudFormationClient = new CloudFormationClient({ credentials, region })
+  const describeStacksCommand = new DescribeStacksCommand({ StackName : stack })
+  const stacksInfo = await cloudFormationClient.send(describeStacksCommand)
+ 
+  const getTemplateCommand = new GetTemplateCommand({ StackName : stack })
+  const templateBody = (await cloudFormationClient.send(getTemplateCommand)).TemplateBody
+  const template = yaml.load(templateBody)
+ 
+  siteInfo.oacName = template.Resources.SiteCloudFrontOriginAccessControl.Properties.OriginAccessControlConfig.Name
+ 
+  const stackOutputs = stacksInfo.Stacks[0].Outputs || []
+  for (const { OutputKey: key, OutputValue: value } of stackOutputs) {
+    if (key === 'SiteS3Bucket') {
+      siteInfo.bucketName = value
+ 
+      Iif (commonLogsBucket === undefined) {
+        commonLogsBucket = await findBucketLike({
+          credentials,
+          description : 'common logs',
+          partialName : value + '-common-logs'
+        })
+      }
+      Iif (commonLogsBucket !== undefined && commonLogsBucket !== 'NONE') {
+        siteInfo.commonLogsBucket = commonLogsBucket
+      }
+    } else Iif (key === 'SiteCloudFrontDistribution') {
+      siteInfo.cloudFrontDistributionID = value
+    }
+  } // for (... of stackOutputs)
+ 
+  progressLogger?.write('Loading plugins data...\n')
+ 
+  const pluginsData = {}
+  siteInfo.plugins = pluginsData
+ 
+  for (const pluginName of Object.keys(plugins)) {
+    progressLogger?.write(`Importing plugin settings for '${pluginName}'...\n`)
+    const { importHandler } = plugins[pluginName]
+    Iif (importHandler === undefined) {
+      throw new Error(`Plugin '${pluginName}' does not define 'importHandler'; cannot  continue with import.`)
+    }
+ 
+    await importHandler({ credentials, name : pluginName, pluginsData, siteInfo, template })
+  }
+ 
+  return siteInfo
+}
+ 
+export { doImport }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/index.html b/qa/coverage/lib/actions/index.html new file mode 100644 index 00000000..5a662364 --- /dev/null +++ b/qa/coverage/lib/actions/index.html @@ -0,0 +1,176 @@ + + + + + + Code coverage report for lib/actions + + + + + + + + + +
+
+

All files lib/actions

+
+ +
+ 0% + Statements + 0/300 +
+ + +
+ 0% + Branches + 0/121 +
+ + +
+ 0% + Functions + 0/19 +
+ + +
+ 0% + Lines + 0/291 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
create.mjs +
+
0%0/720%0/140%0/70%0/71
destroy.mjs +
+
0%0/400%0/210%0/10%0/36
import.mjs +
+
0%0/470%0/250%0/20%0/46
update.mjs +
+
0%0/410%0/240%0/20%0/41
verify.mjs +
+
0%0/1000%0/370%0/70%0/97
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html b/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html new file mode 100644 index 00000000..2e82fcdf --- /dev/null +++ b/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html @@ -0,0 +1,145 @@ + + + + + + Code coverage report for lib/actions/lib/add-tags-to-hosted-zone.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib add-tags-to-hosted-zone.mjs

+
+ +
+ 0% + Statements + 0/10 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/10 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { Route53Client, ChangeTagsForResourceCommand } from '@aws-sdk/client-route-53'
+ 
+import { getHostedZoneID } from './get-hosted-zone-id'
+import { getSiteTag } from '../../shared/get-site-tag'
+ 
+const addTagsToHostedZone = async ({ credentials, siteInfo }) => {
+  const siteTag = getSiteTag(siteInfo)
+  const route53Client = new Route53Client({ credentials })
+ 
+  const hostedZoneID = await getHostedZoneID({ route53Client, siteInfo })
+ 
+  const changeTagsForResourceCommand = new ChangeTagsForResourceCommand({
+    ResourceType : 'hostedzone',
+    ResourceId   : hostedZoneID,
+    AddTags      : [{ Key : siteTag, Value : '' }]
+  })
+  await route53Client.send(changeTagsForResourceCommand)
+}
+ 
+export { addTagsToHostedZone }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html b/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html new file mode 100644 index 00000000..3c3d71aa --- /dev/null +++ b/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html @@ -0,0 +1,142 @@ + + + + + + Code coverage report for lib/actions/lib/associate-cost-allocation-tags.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib associate-cost-allocation-tags.mjs

+
+ +
+ 0% + Statements + 0/11 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/11 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { CostExplorerClient, UpdateCostAllocationTagsStatusCommand } from '@aws-sdk/client-cost-explorer'
+ 
+import { progressLogger } from '../../shared/progress-logger'
+ 
+const associateCostAllocationTags = async ({ credentials, tag }) => {
+  const costExplorerClient = new CostExplorerClient({ credentials })
+  const updateCostAllocationTagsStatusCommand = new UpdateCostAllocationTagsStatusCommand({
+    CostAllocationTagsStatus : [{ TagKey : tag, Status : 'Active' }]
+  })
+  await costExplorerClient.send(updateCostAllocationTagsStatusCommand)
+}
+ 
+const handleAssociateCostAllocationTagsError = ({ /* e, */ siteInfo }) => {
+  const { apexDomain } = siteInfo
+ 
+  progressLogger.write(`\nThe attempt to setup your cost allocation tags has failed. This is expected as AWS must 'discover' your tags before they can be activated for cost allocation. Wait a little while and try setting up the cost allocation tags again with:\n\ncloudsite update ${apexDomain} --do-billing\n\n`)
+}
+ 
+export { associateCostAllocationTags, handleAssociateCostAllocationTagsError }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html b/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html new file mode 100644 index 00000000..4b819dab --- /dev/null +++ b/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html @@ -0,0 +1,214 @@ + + + + + + Code coverage report for lib/actions/lib/create-or-update-dns-records.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib create-or-update-dns-records.mjs

+
+ +
+ 0% + Statements + 0/18 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/18 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { Route53Client, ChangeResourceRecordSetsCommand } from '@aws-sdk/client-route-53'
+import { CloudFrontClient, GetDistributionCommand } from '@aws-sdk/client-cloudfront'
+ 
+import { getHostedZoneID } from './get-hosted-zone-id'
+import { progressLogger } from '../../shared/progress-logger'
+ 
+const createOrUpdateDNSRecords = async ({ credentials, siteInfo }) => {
+  const { apexDomain, cloudFrontDistributionID, region } = siteInfo
+ 
+  const cloudFrontClient = new CloudFrontClient({ credentials, region })
+  const getDistributionCommand = new GetDistributionCommand({ Id : cloudFrontDistributionID })
+  const distributionResponse = await cloudFrontClient.send(getDistributionCommand)
+  const distributionDomainName = distributionResponse.Distribution.DomainName
+ 
+  const route53Client = new Route53Client({ credentials, region })
+ 
+  const hostedZoneID = await getHostedZoneID({ route53Client, siteInfo })
+ 
+  const domains = [apexDomain, 'www.' + apexDomain]
+ 
+  const changeResourceRecordSetCommand = new ChangeResourceRecordSetsCommand({
+    HostedZoneId : hostedZoneID,
+    ChangeBatch  : {
+      Comment : `Point '${apexDomain}' and 'www.${apexDomain}' to CloudFront distribution.`,
+      Changes : domains.map((name) => ({
+        Action            : 'UPSERT',
+        ResourceRecordSet : {
+          Name        : name,
+          AliasTarget : {
+            DNSName              : distributionDomainName,
+            EvaluateTargetHealth : false,
+            HostedZoneId         : 'Z2FDTNDATAQYW2' // Static value specified by API for use with CloudFront aliases
+          },
+          Type : 'A'
+        }
+      }))
+    }
+  })
+  progressLogger.write(`Creating/updating Route 53 resource record sets/DNS entries for ${domains.join(', ')}...\n`)
+  await route53Client.send(changeResourceRecordSetCommand)
+}
+ 
+export { createOrUpdateDNSRecords }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/find-certificate.mjs.html b/qa/coverage/lib/actions/lib/find-certificate.mjs.html new file mode 100644 index 00000000..466740d2 --- /dev/null +++ b/qa/coverage/lib/actions/lib/find-certificate.mjs.html @@ -0,0 +1,172 @@ + + + + + + Code coverage report for lib/actions/lib/find-certificate.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib find-certificate.mjs

+
+ +
+ 0% + Statements + 0/16 +
+ + +
+ 0% + Branches + 0/10 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/16 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { ListCertificatesCommand } from '@aws-sdk/client-acm'
+ 
+import { progressLogger } from '../../shared/progress-logger'
+ 
+const findCertificate = async ({ apexDomain, acmClient }) => {
+  progressLogger?.write('Searching for existing certificate... ')
+  let nextToken
+  do {
+    const listCertificatesCommand = new ListCertificatesCommand({
+      CertificateStatuses : ['PENDING_VALIDATION', 'ISSUED']
+    })
+    const listResponse = await acmClient.send(listCertificatesCommand)
+ 
+    const domain = '*.' + apexDomain
+    for (const { CertificateArn, DomainName, Status } of listResponse.CertificateSummaryList) {
+      Iif (DomainName === domain) {
+        progressLogger?.write('FOUND\n')
+        return { certificateArn : CertificateArn, status : Status }
+      }
+    }
+    nextToken = listResponse.NextToken
+  } while (nextToken !== undefined)
+ 
+  // if we fall out of the loop without returning, then we never found the named domain
+  progressLogger?.write('NOT found')
+  return { certificateArn : null, status : null }
+}
+ 
+export { findCertificate }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/get-credentials.mjs.html b/qa/coverage/lib/actions/lib/get-credentials.mjs.html new file mode 100644 index 00000000..1a361e6a --- /dev/null +++ b/qa/coverage/lib/actions/lib/get-credentials.mjs.html @@ -0,0 +1,118 @@ + + + + + + Code coverage report for lib/actions/lib/get-credentials.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib get-credentials.mjs

+
+ +
+ 0% + Statements + 0/6 +
+ + +
+ 0% + Branches + 0/3 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/6 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12  +  +  +  +  +  +  +  +  +  +  + 
import { fromIni } from '@aws-sdk/credential-providers'
+ 
+const getCredentials = ({ 'sso-profile': ssoProfile }) => {
+  ssoProfile = ssoProfile || process.env.AWS_PROFILE || 'default'
+ 
+  const credentials = fromIni({ profile : ssoProfile })
+ 
+  return credentials
+}
+ 
+export { getCredentials }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html b/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html new file mode 100644 index 00000000..0c0668ae --- /dev/null +++ b/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html @@ -0,0 +1,148 @@ + + + + + + Code coverage report for lib/actions/lib/get-hosted-zone-id.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib get-hosted-zone-id.mjs

+
+ +
+ 0% + Statements + 0/11 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/11 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { ListHostedZonesCommand } from '@aws-sdk/client-route-53'
+ 
+const getHostedZoneID = async ({ route53Client, siteInfo }) => {
+  let markerToken
+  do {
+    const listHostedZonesCommand = new ListHostedZonesCommand({ Marker : markerToken })
+    const listHostedZonesResponse = await route53Client.send(listHostedZonesCommand)
+ 
+    for (const { Id, Name } of listHostedZonesResponse.HostedZones) {
+      Iif (Name === siteInfo.apexDomain + '.') {
+        return Id.replace(/\/[^/]+\/(.+)/, '$1') // /hostedzone/XXX -> XXX
+      }
+    }
+ 
+    Iif (listHostedZonesResponse.IsTruncated === true) {
+      markerToken = listHostedZonesCommand.NextMarker
+    }
+  } while (markerToken !== undefined)
+}
+ 
+export { getHostedZoneID }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/index.html b/qa/coverage/lib/actions/lib/index.html new file mode 100644 index 00000000..42d9c943 --- /dev/null +++ b/qa/coverage/lib/actions/lib/index.html @@ -0,0 +1,266 @@ + + + + + + Code coverage report for lib/actions/lib + + + + + + + + + +
+
+

All files lib/actions/lib

+
+ +
+ 0% + Statements + 0/181 +
+ + +
+ 0% + Branches + 0/60 +
+ + +
+ 0% + Functions + 0/22 +
+ + +
+ 0% + Lines + 0/177 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
add-tags-to-hosted-zone.mjs +
+
0%0/10100%0/00%0/10%0/10
associate-cost-allocation-tags.mjs +
+
0%0/11100%0/00%0/20%0/11
create-or-update-dns-records.mjs +
+
0%0/18100%0/00%0/20%0/18
find-certificate.mjs +
+
0%0/160%0/100%0/10%0/16
get-credentials.mjs +
+
0%0/60%0/30%0/10%0/6
get-hosted-zone-id.mjs +
+
0%0/110%0/20%0/10%0/11
sync-site-content.mjs +
+
0%0/230%0/120%0/30%0/22
track-stack-status.mjs +
+
0%0/260%0/110%0/20%0/25
update-plugins.mjs +
+
0%0/130%0/110%0/20%0/12
update-site-info.mjs +
+
0%0/12100%0/00%0/20%0/12
update-stack.mjs +
+
0%0/350%0/110%0/50%0/34
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/sync-site-content.mjs.html b/qa/coverage/lib/actions/lib/sync-site-content.mjs.html new file mode 100644 index 00000000..647d19e2 --- /dev/null +++ b/qa/coverage/lib/actions/lib/sync-site-content.mjs.html @@ -0,0 +1,193 @@ + + + + + + Code coverage report for lib/actions/lib/sync-site-content.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib sync-site-content.mjs

+
+ +
+ 0% + Statements + 0/23 +
+ + +
+ 0% + Branches + 0/12 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/22 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { existsSync as fileExists } from 'node:fs'
+import * as fsPath from 'node:path'
+ 
+import { S3Client } from '@aws-sdk/client-s3'
+import { tryExec } from '@liquid-labs/shell-toolkit'
+import mime from 'mime-types'
+import { S3SyncClient } from 's3-sync-client'
+ 
+import { progressLogger } from '../../shared/progress-logger'I
+ 
+const syncSiteContent = async ({ credentials, noBuild, siteInfo }) => {
+  const { bucketName, sourcePath, sourceType } = siteInfo
+ 
+  Iif (noBuild !== true && sourceType === 'docusaurus') {
+    const packageRoot = fsPath.resolve(sourcePath, '..')
+    const packagePath = fsPath.join(packageRoot, 'package.json')
+    Iif (fileExists(packagePath)) {
+      progressLogger.write('Rebuilding site... ')
+      tryExec(`cd "${packageRoot}" && npm run build`)
+      progressLogger.write('done.\n')
+    }
+  }
+ 
+  progressLogger.write(`Syncing files from ${sourcePath}...\n`)
+ 
+  const s3Client = new S3Client({ credentials })
+  const { sync } = new S3SyncClient({ client : s3Client })
+ 
+  await sync(sourcePath, 's3://' + bucketName, {
+    commandInput           : (input) => ({ ContentType : mime.lookup(input.Key) || 'application/octet-stream' }),
+    del                    : true,
+    maxConcurrentTransfers : 10
+  })
+}
+ 
+export { syncSiteContent }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/track-stack-status.mjs.html b/qa/coverage/lib/actions/lib/track-stack-status.mjs.html new file mode 100644 index 00000000..56167996 --- /dev/null +++ b/qa/coverage/lib/actions/lib/track-stack-status.mjs.html @@ -0,0 +1,214 @@ + + + + + + Code coverage report for lib/actions/lib/track-stack-status.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib track-stack-status.mjs

+
+ +
+ 0% + Statements + 0/26 +
+ + +
+ 0% + Branches + 0/11 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/25 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { DeleteStackCommand, DescribeStacksCommand } from '@aws-sdk/client-cloudformation'
+ 
+import { progressLogger } from '../../shared/progress-logger'
+ 
+const RECHECK_WAIT_TIME = 2000 // ms
+ 
+const trackStackStatus = async ({ cloudFormationClient, noDeleteOnFailure, noInitialStatus, stackName }) => {
+  let stackStatus, previousStatus
+  do {
+    const describeInput = { StackName : stackName }
+    const describeCommand = new DescribeStacksCommand(describeInput)
+    const describeResponse = await cloudFormationClient.send(describeCommand)
+ 
+    stackStatus = describeResponse.Stacks[0].StackStatus
+ 
+    if (stackStatus !== previousStatus && (noInitialStatus !== true || previousStatus !== undefined)) {
+      // convert to sentence case
+      const statusMessage = stackStatus.charAt(0) + stackStatus.slice(1).toLowerCase().replaceAll(/_/g, ' ')
+      progressLogger.write((previousStatus !== undefined ? '\n' : '') + statusMessage)
+      Iif (!stackStatus.endsWith('_PROGRESS')) {
+        progressLogger.write('\n')
+      }
+    } else {
+      progressLogger.write('.')
+    }
+ 
+    previousStatus = stackStatus
+    await new Promise(resolve => setTimeout(resolve, RECHECK_WAIT_TIME))
+  } while (stackStatus.endsWith('_IN_PROGRESS'))
+ 
+  Iif (stackStatus === 'ROLLBACK_COMPLETE' && noDeleteOnFailure !== true) {
+    progressLogger.write(`\nDeleting stack '${stackName}' `)
+    const deleteInput = { StackName : stackName }
+    const deleteCommand = new DeleteStackCommand(deleteInput)
+    await cloudFormationClient.send(deleteCommand)
+ 
+    trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, noInitialStatus : true, stackName })
+  }
+ 
+  return stackStatus
+}
+ 
+export { trackStackStatus }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-plugins.mjs.html b/qa/coverage/lib/actions/lib/update-plugins.mjs.html new file mode 100644 index 00000000..e29383a9 --- /dev/null +++ b/qa/coverage/lib/actions/lib/update-plugins.mjs.html @@ -0,0 +1,145 @@ + + + + + + Code coverage report for lib/actions/lib/update-plugins.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib update-plugins.mjs

+
+ +
+ 0% + Statements + 0/13 +
+ + +
+ 0% + Branches + 0/11 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/12 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as plugins from '../../plugins'I
+ 
+const updatePlugins = async ({ credentials, siteInfo }) => {
+  const { apexDomain, plugins : pluginsData } = siteInfo
+  const updates = []
+ 
+  for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
+    const plugin = plugins[pluginKey]
+    Iif (plugin === undefined) {
+      throw new Error(`Unknown plugin found in '${apexDomain}' during update.`)
+    }
+ 
+    const { updateHandler } = plugin
+    updates.push(updateHandler?.({ credentials, pluginData, siteInfo }))
+  }
+ 
+  await Promise.all(updates)
+}
+ 
+export { updatePlugins }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-site-info.mjs.html b/qa/coverage/lib/actions/lib/update-site-info.mjs.html new file mode 100644 index 00000000..f9527807 --- /dev/null +++ b/qa/coverage/lib/actions/lib/update-site-info.mjs.html @@ -0,0 +1,136 @@ + + + + + + Code coverage report for lib/actions/lib/update-site-info.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib update-site-info.mjs

+
+ +
+ 0% + Statements + 0/12 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/12 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { CloudFormationClient, DescribeStacksCommand } from '@aws-sdk/client-cloudformation'
+ 
+import { progressLogger } from '../../shared/progress-logger'
+ 
+const updateSiteInfo = async ({ credentials, siteInfo }) => {
+  const { region, stackName } = siteInfo
+  progressLogger.write('Gathering information from stack...\n')
+  const cloudFormationClient = new CloudFormationClient({ credentials, region })
+  const describeCommand = new DescribeStacksCommand({ StackName : stackName })
+  const describeResponse = await cloudFormationClient.send(describeCommand)
+  const cloudFrontDistributionID = describeResponse
+    .Stacks[0].Outputs.find(({ OutputKey }) => OutputKey === 'SiteCloudFrontDistribution').OutputValue
+ 
+  siteInfo.cloudFrontDistributionID = cloudFrontDistributionID
+}
+ 
+export { updateSiteInfo }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-stack.mjs.html b/qa/coverage/lib/actions/lib/update-stack.mjs.html new file mode 100644 index 00000000..6c954763 --- /dev/null +++ b/qa/coverage/lib/actions/lib/update-stack.mjs.html @@ -0,0 +1,283 @@ + + + + + + Code coverage report for lib/actions/lib/update-stack.mjs + + + + + + + + + +
+
+

All files / lib/actions/lib update-stack.mjs

+
+ +
+ 0% + Statements + 0/35 +
+ + +
+ 0% + Branches + 0/11 +
+ + +
+ 0% + Functions + 0/5 +
+ + +
+ 0% + Lines + 0/34 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { CloudFormationClient, GetTemplateCommand, UpdateStackCommand } from '@aws-sdk/client-cloudformation'
+import isEqual from 'lodash/isEqual'
+ 
+import * as plugins from '../../plugins'
+import { progressLogger } from '../../shared/progress-logger'
+import { SiteTemplate } from '../../shared/site-template'
+import { trackStackStatus } from './track-stack-status'
+import { updateSiteInfo } from './update-site-info'I
+ 
+const updateStack = async ({ credentials, siteInfo }) => {
+  const { region, stackName } = siteInfo
+ 
+  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
+  await siteTemplate.initializeTemplate({ update : true })
+  await siteTemplate.loadPlugins({ update : true })
+ 
+  const newTemplate = siteTemplate.render()
+ 
+  const cloudFormationClient = new CloudFormationClient({ credentials, region })
+  const getTemplateCommand = new GetTemplateCommand({
+    StackName     : stackName,
+    TemplateStage : 'Original'
+  })
+  const getTemplateResponse = await cloudFormationClient.send(getTemplateCommand)
+  const currentTemplate = getTemplateResponse.TemplateBody
+ 
+  Iif (isEqual(currentTemplate, newTemplate)) {
+    progressLogger.write('No change to template; skipping stack update.\n')
+    return
+  }
+  // else, the template has changed
+ 
+  const stackUpdateCommand = new UpdateStackCommand({ // UpdateStackInput
+    StackName           : stackName,
+    TemplateBody        : newTemplate,
+    UsePreviousTemplate : false,
+    Capabilities        : ['CAPABILITY_IAM', 'CAPABILITY_NAMED_IAM'],
+    DisableRollback     : false
+  })
+ 
+  await cloudFormationClient.send(stackUpdateCommand)
+ 
+  const finalStatus = await trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, stackName })
+ 
+  await updateSiteInfo({ credentials, siteInfo }) // needed by createOrUpdateDNSRecords
+ 
+  const postUpdateHandlers = Object.keys(siteInfo.pluginSettings || {}).map((pluginKey) =>
+    [pluginKey, plugins[pluginKey].postUpdateHandler]
+  )
+    .filter(([, postUpdateHandler]) => postUpdateHandler !== undefined)
+ 
+  Iif (postUpdateHandlers.length > 0) {
+    await Promise.all([
+      ...(postUpdateHandlers.map(([pluginKey, handler]) =>
+        handler({ settings : siteInfo.pluginSettings[pluginKey], siteInfo })))
+    ])
+  }
+ 
+  Iif (finalStatus === 'UPDATE_COMPLETE') {
+    progressLogger.write('Stack updated.\n')
+  }
+ 
+  return finalStatus
+}
+ 
+export { updateStack }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/update.mjs.html b/qa/coverage/lib/actions/update.mjs.html new file mode 100644 index 00000000..cebc937e --- /dev/null +++ b/qa/coverage/lib/actions/update.mjs.html @@ -0,0 +1,361 @@ + + + + + + Code coverage report for lib/actions/update.mjs + + + + + + + + + +
+
+

All files / lib/actions update.mjs

+
+ +
+ 0% + Statements + 0/41 +
+ + +
+ 0% + Branches + 0/24 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/41 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { CloudFrontClient, CreateInvalidationCommand } from '@aws-sdk/client-cloudfront'
+ 
+import { addTagsToHostedZone } from './lib/add-tags-to-hosted-zone'
+import {
+  associateCostAllocationTags,
+  handleAssociateCostAllocationTagsError
+} from './lib/associate-cost-allocation-tags'
+import { createOrUpdateDNSRecords } from './lib/create-or-update-dns-records'
+import { getCredentials } from './lib/get-credentials'
+import { getSiteTag } from '../shared/get-site-tag'
+import { progressLogger } from '../shared/progress-logger'
+import { syncSiteContent } from './lib/sync-site-content'
+import { updatePlugins } from './lib/update-plugins'
+import { updateStack } from './lib/update-stack'
+ 
+const update = async ({
+  db,
+  doBilling,
+  doContent,
+  doDNS,
+  doStack,
+  noBuild,
+  noCacheInvalidation,
+  siteInfo
+}) => {
+  const doAll = doBilling === undefined && doContent === undefined && doDNS === undefined && doStack === undefined
+ 
+  const credentials = getCredentials(db.account.settings)
+ 
+  const firstRoundUpdates = []
+  Iif (doAll === true || doContent === true) {
+    // method will report actions to user
+    firstRoundUpdates.push(syncSiteContent({ credentials, noBuild, siteInfo }))
+  }
+ 
+  Iif (doAll === true || doDNS === true) {
+    firstRoundUpdates.push(createOrUpdateDNSRecords({ credentials, siteInfo }))
+  }
+ 
+  await Promise.all(firstRoundUpdates)
+ 
+  let stackUpdateStatus
+  Iif (doAll === true || doStack === true) {
+    stackUpdateStatus = await updateStack({ credentials, siteInfo })
+    Iif (stackUpdateStatus === 'UPDATE_COMPLETE') {
+      await updatePlugins({ credentials, siteInfo })
+      // have to do this after the other updates so that the tags get created first
+    }
+  }
+ 
+  const secondRoundUpdates = []
+ 
+  Iif (doAll === true || doBilling === true) {
+    const siteTag = getSiteTag(siteInfo)
+    try {
+      await associateCostAllocationTags({ credentials, tag : siteTag })
+    } catch (e) {
+      handleAssociateCostAllocationTagsError({ e, siteInfo })
+    }
+  }
+ 
+  Iif (doAll === true || doDNS === true) {
+    secondRoundUpdates.push(addTagsToHostedZone({ credentials, siteInfo }))
+  }
+ 
+  Iif ((doAll === true || doContent === true) && noCacheInvalidation !== true) {
+    secondRoundUpdates.push(invalidateCache({ credentials, siteInfo }))
+  }
+ 
+  await Promise.all(secondRoundUpdates)
+}
+ 
+const invalidateCache = async ({ credentials, siteInfo }) => {
+  progressLogger.write('Invalidating CloudFront cache...\n')
+ 
+  const { cloudFrontDistributionID } = siteInfo
+ 
+  const cloudFrontClient = new CloudFrontClient({ credentials })
+  const invalidateCacheCommand = new CreateInvalidationCommand({
+    DistributionId    : cloudFrontDistributionID,
+    InvalidationBatch : {
+      Paths : {
+        Quantity : 1,
+        Items    : ['/*']
+      },
+      CallerReference : new Date().getTime() + ''
+    }
+  })
+  await cloudFrontClient.send(invalidateCacheCommand)
+}
+ 
+export { update }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/actions/verify.mjs.html b/qa/coverage/lib/actions/verify.mjs.html new file mode 100644 index 00000000..72c3f8c8 --- /dev/null +++ b/qa/coverage/lib/actions/verify.mjs.html @@ -0,0 +1,631 @@ + + + + + + Code coverage report for lib/actions/verify.mjs + + + + + + + + + +
+
+

All files / lib/actions verify.mjs

+
+ +
+ 0% + Statements + 0/100 +
+ + +
+ 0% + Branches + 0/37 +
+ + +
+ 0% + Functions + 0/7 +
+ + +
+ 0% + Lines + 0/97 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import {
+  CloudFormationClient,
+  DescribeStackDriftDetectionStatusCommand,
+  DetectStackDriftCommand
+} from '@aws-sdk/client-cloudformation'
+import { S3Client } from '@aws-sdk/client-s3'
+import { S3SyncClient } from 's3-sync-client'
+ 
+import { getCredentials } from './lib/get-credentials'
+import { progressLogger } from '../shared/progress-logger'
+ 
+const RECHECK_WAIT_TIME = 2000 // ms
+ 
+const verify = async ({ checkContent, checkSiteUp, checkStack, db, siteInfo }) => {
+  const checkAll = checkContent === undefined && checkSiteUp === undefined && checkStack === undefined
+  let credentials
+  Iif (checkAll || checkContent || checkStack) {
+    credentials = getCredentials(db.account.settings)
+  }
+ 
+  const checks = []
+  Iif (checkAll || checkSiteUp) {
+    checks.push(doCheckSiteUp({ progressLogger, siteInfo }))
+  }
+  Iif (checkAll || checkContent) {
+    checks.push(doCheckContent({ credentials, progressLogger, siteInfo }))
+  }
+  Iif (checkAll || checkStack) {
+    checks.push(doCheckStack({ credentials, progressLogger, siteInfo }))
+  }
+ 
+  const results = await Promise.all(checks)
+ 
+  return results.reduce((acc, array) => { acc.push(...array); return acc }, [])
+}
+ 
+const doCheckContent = async ({ credentials, progressLogger, siteInfo }) => {
+  Iif (progressLogger !== undefined) {
+    progressLogger.write('Checking site content in sync...\n')
+  }
+  const { bucketName, sourcePath } = siteInfo
+ 
+  const s3Client = new S3Client({ credentials })
+  const { sync } = new S3SyncClient({ client : s3Client })
+ 
+  const checkResult = { check : 'S3 bucket and local source in sync' }
+  try {
+    const objectData = await sync(sourcePath, 's3://' + bucketName, { dryRun : true })
+ 
+    const createdCount = objectData.created.length
+    const updatedCount = objectData.updated.length
+    const deletedCount = objectData.deleted.length
+    const inSync = (createdCount + updatedCount + deletedCount) === 0
+    if (inSync === true) {
+      checkResult.status = 'success'
+      checkResult.message = 'S3 bucket and local source are up-to-date'
+    } else {
+      checkResult.status = 'failed'
+      checkResult.message =
+        `${createdCount} files to create, ${updatedCount} files to update, and ${deletedCount} files to delete`
+    }
+ 
+    return [checkResult]
+  } catch (e) {
+    checkResult.status = 'error'
+    checkResult.message = e.message
+ 
+    return [checkResult]
+  } finally {
+    Iif (progressLogger !== undefined) {
+      progressLogger.write('Site content check complete.\n')
+    }
+  }
+}
+ 
+const doCheckSiteUp = async ({ progressLogger, siteInfo }) => {
+  Iif (progressLogger !== undefined) {
+    progressLogger.write('Checking site is up...\n')
+  }
+  const { apexDomain } = siteInfo
+ 
+  try {
+    const fetchResponses = await Promise.all([
+      fetch('https://' + apexDomain),
+      fetch('https://www.' + apexDomain)
+    ])
+ 
+    const results = [
+      processFetchResults({ domain : apexDomain, fetchResponse : fetchResponses[0] }),
+      processFetchResults({ domain : 'www.' + apexDomain, fetchResponse : fetchResponses[1] })
+    ]
+ 
+    return results
+  } catch (e) {
+    return [
+      { check : `site ${apexDomain} is up`, status : 'error', message : e.message },
+      { check : `site www.${apexDomain} is up`, status : 'error', message : e.message }
+    ]
+  } finally {
+    Iif (progressLogger !== undefined) {
+      progressLogger.write('Site is up check complete.\n')
+    }
+  }
+}
+ 
+const doCheckStack = async ({ credentials, progressLogger, siteInfo }) => {
+  Iif (progressLogger !== undefined) {
+    progressLogger.write('Checking stack drift status...\n')
+  }
+ 
+  const checkResult = { check : 'Stack drift check' }
+ 
+  try {
+    const { stackName } = siteInfo
+    const cfClient = new CloudFormationClient({ credentials })
+    const detectDriftCommand = new DetectStackDriftCommand({ StackName : stackName })
+    const stackDriftOperationID = (await cfClient.send(detectDriftCommand)).StackDriftDetectionId
+ 
+    const describeStackDriftDetectionCommand = new DescribeStackDriftDetectionStatusCommand({
+      StackDriftDetectionId : stackDriftOperationID
+    })
+    let stackDriftDescribeResponse
+    let detectionStatus
+    do {
+      Iif (progressLogger !== undefined) {
+        progressLogger.write('.')
+      }
+      await new Promise(resolve => setTimeout(resolve, RECHECK_WAIT_TIME))
+ 
+      stackDriftDescribeResponse = await cfClient.send(describeStackDriftDetectionCommand)
+      detectionStatus = stackDriftDescribeResponse.DetectionStatus
+    } while (detectionStatus === 'DETECTION_IN_PROGRESS')
+ 
+    const stackDriftStatus = stackDriftDescribeResponse.StackDriftStatus
+    if (detectionStatus === 'DETECTION_FAILED') {
+      checkResult.status = 'error'
+      checkResult.message = (stackDriftStatus === 'IN_SYNC'
+        ? 'Stack as checked in sync, but: '
+        : 'Stack not in sync and: ') +
+        stackDriftDescribeResponse.DetectionStatusReason
+    } else if (stackDriftStatus === 'IN_SYNC') {
+      checkResult.status = 'success'
+      checkResult.message = stackName + ' is in sync with template'
+    } else if (stackDriftStatus === 'UNKNOWN') {
+      checkResult.status = 'error'
+      checkResult.message = stackName + ' drift status is unknown'
+    } else if (stackDriftStatus === 'DRIFTED') {
+      checkResult.status = 'failed'
+      checkResult.message =
+        `${stackDriftDescribeResponse.DriftedStackResourceCount} resources have drifted on stack ${stackName}`
+    } else {
+      checkResult.status = 'error'
+      checkResult.message = `Unexpected status '${stackDriftStatus} while checking ${stackName}`
+    }
+  } catch (e) {
+    checkResult.status = 'error'
+    checkResult.message = e.message
+  } finally {
+    Iif (progressLogger !== undefined) {
+      progressLogger.write('\nStack drift check complete.\n')
+    }
+  }
+ 
+  return [checkResult]
+}
+ 
+const processFetchResults = ({ domain, fetchResponse }) => {
+  const result = {
+    check   : `site ${domain} is up`,
+    message : `Got HTTP status ${fetchResponse.status} fetching https://${domain}.`
+  }
+ 
+  if (fetchResponse.status === 200) {
+    result.status = 'success'
+  } else {
+    result.status = 'failed'
+  }
+ 
+  return result
+}
+ 
+export { verify }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/access-logs.mjs.html b/qa/coverage/lib/plugins/access-logs.mjs.html new file mode 100644 index 00000000..1a7fdea4 --- /dev/null +++ b/qa/coverage/lib/plugins/access-logs.mjs.html @@ -0,0 +1,124 @@ + + + + + + Code coverage report for lib/plugins/access-logs.mjs + + + + + + + + + +
+
+

All files / lib/plugins access-logs.mjs

+
+ +
+ 0% + Statements + 0/6 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/6 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14  +  +  +  +  +  +  +  +  +  +  +  +  + 
const config = {
+  options : { default : true, validation : (v) => typeof v === 'boolean' }
+}
+ 
+const handler = () => {
+  throw new Error('Not yet implemented')
+}
+ 
+const importHandler = () => {}
+ 
+const accessLogs = { config, handler, importHandler }
+ 
+export { accessLogs }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/cloudfront-logs.mjs.html b/qa/coverage/lib/plugins/cloudfront-logs.mjs.html new file mode 100644 index 00000000..e3201cd7 --- /dev/null +++ b/qa/coverage/lib/plugins/cloudfront-logs.mjs.html @@ -0,0 +1,211 @@ + + + + + + Code coverage report for lib/plugins/cloudfront-logs.mjs + + + + + + + + + +
+
+

All files / lib/plugins cloudfront-logs.mjs

+
+ +
+ 0% + Statements + 0/14 +
+ + +
+ 0% + Branches + 0/1 +
+ + +
+ 0% + Functions + 0/4 +
+ + +
+ 0% + Lines + 0/14 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
const config = {
+  name        : 'CloudFront logs',
+  description : 'Enables logging of CloudFront events.',
+  options     : {
+    includeCookies : {
+      description : 'Whether to log cookies or not.',
+      default     : false,
+      type        : 'boolean',
+      validation  : (v) => typeof v === 'boolean'
+    }
+  }
+}
+ 
+const importHandler = ({ /* credentials, */ name, pluginsData, /* siteInfo, */ template }) => {
+  const cloudFrontLoggingConfig = template.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Logging
+  Iif (cloudFrontLoggingConfig !== undefined) {
+    const settings = {
+      includeCookies : cloudFrontLoggingConfig.IncludeCookies
+    }
+    pluginsData[name] = settings
+  }
+}
+ 
+const preStackDestroyHandler = async ({ siteTemplate }) => {
+  await siteTemplate.destroyCommonLogsBucket()
+}
+ 
+const stackConfig = async ({ siteTemplate, pluginData }) => {
+  const { finalTemplate } = siteTemplate
+ 
+  await siteTemplate.enableCommonLogsBucket()
+ 
+  finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Logging = {
+    Bucket         : { 'Fn::GetAtt' : ['commonLogsBucket', 'DomainName'] },
+    IncludeCookies : pluginData.settings.includeCookies,
+    Prefix         : 'cloudfront-logs/'
+  }
+}
+ 
+const cloudfrontLogs = { config, importHandler, preStackDestroyHandler, stackConfig }
+ 
+export { cloudfrontLogs }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html new file mode 100644 index 00000000..278fa676 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html @@ -0,0 +1,175 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/constants.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib constants.mjs

+
+ +
+ 0% + Statements + 0/4 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 0% + Lines + 0/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
export const CONTACT_EMAILER_ZIP_NAME = 'contact-emailer-lambda.zip'
+export const CONTACT_HANDLER_ZIP_NAME = 'contact-handler-lambda.zip'
+export const REQUEST_SIGNER_ZIP_NAME = 'request-signer-lambda.zip'
+ 
+export const STANDARD_FORM_FIELDS = {
+  // ID
+  given_name            : 'S',
+  family_name           : 'S',
+  company               : 'S',
+  // demo
+  company_size          : 'S',
+  industry              : 'S',
+  revenue               : 'S',
+  // contact
+  email                 : 'S',
+  phone_number_home     : 'S',
+  phone_number_mobile   : 'S',
+  phone_number_work     : 'S',
+  phone_number_work_ext : 'S',
+  // location
+  address_1             : 'S',
+  address_2             : 'S',
+  city                  : 'S',
+  state                 : 'S',
+  zip_code              : 'S',
+  county                : 'S',
+  // purpose
+  message               : 'S',
+  topics                : 'SS'
+}
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html new file mode 100644 index 00000000..408c1632 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html @@ -0,0 +1,187 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib determine-lambda-function-name.mjs

+
+ +
+ 0% + Statements + 0/23 +
+ + +
+ 0% + Branches + 0/20 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/23 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { v4 as uuidv4 } from 'uuid'
+ 
+import { LambdaClient, GetFunctionCommand } from '@aws-sdk/client-lambda'
+ 
+import { progressLogger } from '../../../shared/progress-logger'
+ 
+const determineLambdaFunctionName = async ({ baseName, credentials, siteTemplate }) => {
+  const { siteInfo } = siteTemplate
+  const { region } = siteInfo
+  let currentName = baseName
+ 
+  const lambdaClient = new LambdaClient({ credentials, region })
+  while (true) {
+    progressLogger?.write(`Checking if Lambda function name '${currentName}' is free...`)
+    const getFunctionCommand = new GetFunctionCommand({ FunctionName : currentName })
+    try {
+      await lambdaClient.send(getFunctionCommand)
+    } catch (e) {
+      if (e.name === 'NotFound' || e.$metadata?.httpStatusCode === 404) {
+        progressLogger?.write('FREE\n')
+        return currentName
+      } else {
+        progressLogger?.write('\n')
+        throw e
+      }
+    }
+    progressLogger?.write('NOT free\n')
+    const nameSalt = uuidv4().slice(0, 8)
+    currentName = currentName.replace(/-[A-F0-9]{8}$/i, '')
+    currentName += '-' + nameSalt
+  }
+}
+ 
+export { determineLambdaFunctionName }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/index.html b/qa/coverage/lib/plugins/contact-handler/lib/index.html new file mode 100644 index 00000000..ddb6e3d8 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/index.html @@ -0,0 +1,221 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib + + + + + + + + + +
+
+

All files lib/plugins/contact-handler/lib

+
+ +
+ 0% + Statements + 0/161 +
+ + +
+ 0% + Branches + 0/42 +
+ + +
+ 0% + Functions + 0/8 +
+ + +
+ 0% + Lines + 0/161 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
constants.mjs +
+
0%0/4100%0/0100%0/00%0/4
determine-lambda-function-name.mjs +
+
0%0/230%0/200%0/10%0/23
setup-contact-emailer.mjs +
+
0%0/300%0/100%0/10%0/30
setup-contact-form-table.mjs +
+
0%0/10100%0/00%0/10%0/10
setup-contact-handler.mjs +
+
0%0/320%0/60%0/10%0/32
setup-request-signer.mjs +
+
0%0/180%0/20%0/10%0/18
stage-lambda-function-zip-files.mjs +
+
0%0/330%0/20%0/20%0/33
update-cloud-front-distribution.mjs +
+
0%0/110%0/20%0/10%0/11
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html new file mode 100644 index 00000000..73e4cab7 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html @@ -0,0 +1,544 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/setup-contact-emailer.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib setup-contact-emailer.mjs

+
+ +
+ 0% + Statements + 0/30 +
+ + +
+ 0% + Branches + 0/10 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/30 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { LambdaClient, UpdateFunctionCodeCommand } from '@aws-sdk/client-lambda'
+ 
+import { CONTACT_EMAILER_ZIP_NAME, STANDARD_FORM_FIELDS } from './constants'
+import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
+import { determineLambdaFunctionName } from './determine-lambda-function-name'
+import { getSiteTag } from '../../../shared/get-site-tag'
+ 
+const setupContactEmailer = async ({ credentials, lambdaFunctionsBucketName, update, pluginData, siteTemplate }) => {
+  const { finalTemplate, siteInfo } = siteTemplate
+  const { apexDomain } = siteInfo
+  const {
+    emailFrom : contactHandlerFromEmail,
+    emailTo : contactHandlerTargetEmail,
+    formFields = 'standard'
+  } = pluginData.settings
+ 
+  Iif (contactHandlerFromEmail === undefined && contactHandlerTargetEmail !== undefined) {
+    throw new Error("Found site setting for 'emailTo', but no 'emailFrom'; 'emailFrom' must be set to activate email functionality.")
+  }
+ 
+  // setup stream on table
+  finalTemplate.Resources.ContactHandlerDynamoDB.Properties.StreamSpecification = {
+    StreamViewType : 'NEW_IMAGE'
+  }
+ 
+  const emailerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-contact-emailer'
+  const emailerFunctionName = update
+    ? pluginData.emailerFunctionName
+    : (await determineLambdaFunctionName({
+        baseName : emailerFunctionBaseName,
+        credentials,
+        siteTemplate
+      }))
+  pluginData.emailerFunctionName = emailerFunctionName
+  const emailerFunctionLogGroupName = emailerFunctionName
+ 
+  const formFieldsSpec = formFields === 'standard'
+    ? JSON.stringify(STANDARD_FORM_FIELDS)
+    : formFields
+ 
+  const siteTag = getSiteTag(siteInfo)
+  const tags = [{ Key : siteTag, Value : '' }]
+ 
+  finalTemplate.Resources.ContactEmailerLogGroup = {
+    Type       : 'AWS::Logs::LogGroup',
+    Properties : {
+      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
+      LogGroupName    : emailerFunctionLogGroupName,
+      RetentionInDays : 180 // TODO: support options
+    }
+  }
+ 
+  finalTemplate.Resources.ContactEmailerRole = {
+    Type       : 'AWS::IAM::Role',
+    Properties : {
+      AssumeRolePolicyDocument : {
+        Version   : '2012-10-17',
+        Statement : [
+          {
+            Effect    : 'Allow',
+            Principal : {
+              Service : ['lambda.amazonaws.com']
+            },
+            Action : ['sts:AssumeRole']
+          }
+        ]
+      },
+      Path     : '/cloudsite/contact-emailer/',
+      Policies : [
+        {
+          PolicyName     : emailerFunctionName,
+          PolicyDocument : {
+            Version   : '2012-10-17',
+            Statement : [
+              {
+                Effect   : 'Allow',
+                Action   : ['ses:SendEmail', 'ses:SendEmailRaw', 'ses:GetSendQuota', 'ses:GetSendStatistics'],
+                Resource : '*'
+              }
+            ]
+          }
+        }
+      ],
+      ManagedPolicyArns : [
+        // AWSLambdaBasicExecutionRole: allows logging to CloudWatch
+        'arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole',
+        // Allows reading from DynamoDB streams
+        'arn:aws:iam::aws:policy/service-role/AWSLambdaDynamoDBExecutionRole'
+      ],
+      Tags : tags
+    } // Properties
+  }
+ 
+  finalTemplate.Resources.ContactEmailerFunction = {
+    Type       : 'AWS::Lambda::Function',
+    DependsOn  : ['ContactEmailerRole', 'ContactEmailerLogGroup'],
+    Properties : {
+      FunctionName : emailerFunctionName,
+      Handler      : 'index.handler',
+      Role         : { 'Fn::GetAtt' : ['ContactEmailerRole', 'Arn'] },
+      Runtime      : 'nodejs20.x',
+      MemorySize   : 128,
+      Timeout      : 5,
+      Code         : {
+        S3Bucket : lambdaFunctionsBucketName,
+        S3Key    : CONTACT_EMAILER_ZIP_NAME
+      },
+      Environment : {
+        Variables : {
+          APEX_DOMAIN                : apexDomain,
+          EMAIL_HANDLER_SOURCE_EMAIL : contactHandlerFromEmail,
+          FORM_FIELDS                : formFieldsSpec
+          // EMAIL_HANDSER_TARGET_EMAIL will be added late if defined
+        }
+      },
+      LoggingConfig : {
+        ApplicationLogLevel : 'INFO', // support options
+        LogFormat           : 'JSON', // support options
+        LogGroup            : emailerFunctionLogGroupName,
+        SystemLogLevel      : 'INFO' // support options
+      },
+      Tags : tags
+    } // Properties
+  }
+ 
+  finalTemplate.Resources.ContactEmailerEventsSource = {
+    Type       : 'AWS::Lambda::EventSourceMapping',
+    DependsOn  : ['ContactEmailerFunction'],
+    Properties : {
+      FunctionName     : { 'Fn::GetAtt' : ['ContactEmailerFunction', 'Arn'] },
+      EventSourceArn   : { 'Fn::GetAtt' : ['ContactHandlerDynamoDB', 'StreamArn'] },
+      StartingPosition : 'LATEST'
+    }
+  }
+ 
+  Iif (contactHandlerTargetEmail !== undefined) {
+    finalTemplate.Resources.ContactEmailerFunction.Properties.Environment.Variables.EMAIL_HANDLER_TARGET_EMAIL =
+      contactHandlerTargetEmail
+  }
+ 
+  Iif (update === true) {
+    const client = new LambdaClient({ credentials })
+    const command = new UpdateFunctionCodeCommand({ // UpdateFunctionCodeRequest
+      FunctionName : emailerFunctionName,
+      S3Bucket     : lambdaFunctionsBucketName,
+      S3Key        : CONTACT_EMAILER_ZIP_NAME
+      // Publish: true || false,
+    })
+    await client.send(command)
+  }
+}
+ 
+export { setupContactEmailer }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html new file mode 100644 index 00000000..c6722813 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html @@ -0,0 +1,178 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/setup-contact-form-table.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib setup-contact-form-table.mjs

+
+ +
+ 0% + Statements + 0/10 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/10 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { getSiteTag } from '../../../shared/get-site-tag'
+ 
+const setupContactFormTable = ({ siteInfo, siteTemplate }) => {
+  const { finalTemplate, resourceTypes } = siteTemplate
+  const { bucketName } = siteInfo
+ 
+  const siteTag = getSiteTag(siteInfo)
+  const tags = [{ Key : siteTag, Value : '' }]
+ 
+  finalTemplate.Resources.ContactHandlerDynamoDB = {
+    Type       : 'AWS::DynamoDB::Table',
+    Properties : {
+      TableName            : bucketName + '-ContactFormEntries',
+      AttributeDefinitions : [
+        { AttributeName : 'SubmissionID', AttributeType : 'S' },
+        { AttributeName : 'SubmissionTime', AttributeType : 'S' }
+      ],
+      KeySchema : [
+        { AttributeName : 'SubmissionID', KeyType : 'HASH' },
+        { AttributeName : 'SubmissionTime', KeyType : 'RANGE' }
+      ],
+      BillingMode : 'PAY_PER_REQUEST',
+      Tags        : tags
+    }
+  }
+ 
+  finalTemplate.Outputs.ContactHandlerDynamoDB = { Value : { Ref : 'ContactHandlerDynamoDB' } }
+  resourceTypes['DynamoDB::Table'] = true
+}
+ 
+export { setupContactFormTable }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html new file mode 100644 index 00000000..ebd98a03 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html @@ -0,0 +1,613 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/setup-contact-handler.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib setup-contact-handler.mjs

+
+ +
+ 0% + Statements + 0/32 +
+ + +
+ 0% + Branches + 0/6 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/32 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { LambdaClient, UpdateFunctionCodeCommand } from '@aws-sdk/client-lambda'
+ 
+import { CONTACT_HANDLER_ZIP_NAME, STANDARD_FORM_FIELDS } from './constants'
+import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
+import { determineLambdaFunctionName } from './determine-lambda-function-name'
+import { getSiteTag } from '../../../shared/get-site-tag'
+ 
+const setupContactHandler = async ({
+  credentials,
+  lambdaFunctionsBucketName,
+  pluginData,
+  siteInfo,
+  siteTemplate,
+  update
+}) => {
+  const { accountID, apexDomain, bucketName, region } = siteInfo
+  const { finalTemplate, resourceTypes } = siteTemplate
+ 
+  const contactHandlerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-contact-handler'
+  const contactHandlerFunctionName = update === true
+    ? pluginData.contactHandlerFunctionName
+    : (await determineLambdaFunctionName({
+        baseName : contactHandlerFunctionBaseName,
+        credentials,
+        siteTemplate
+      }))
+  pluginData.contactHandlerFunctionName = contactHandlerFunctionName
+ 
+  const contactHandlerLogGroupName = contactHandlerFunctionName
+ 
+  const { formFields = 'standard' } = pluginData.settings
+  const formFieldsSpec = formFields === 'standard'
+    ? JSON.stringify(STANDARD_FORM_FIELDS)
+    : formFields
+ 
+  const siteTag = getSiteTag(siteInfo)
+  const tags = [{ Key : siteTag, Value : '' }]
+ 
+  finalTemplate.Resources.ContactHandlerRole = {
+    Type       : 'AWS::IAM::Role',
+    Properties : {
+      AssumeRolePolicyDocument : {
+        Version   : '2012-10-17',
+        Statement : [
+          {
+            Effect    : 'Allow',
+            Principal : {
+              Service : ['lambda.amazonaws.com']
+            },
+            Action : ['sts:AssumeRole']
+          }
+        ]
+      },
+      Path     : '/cloudsite/contact-processor/',
+      Policies : [
+        {
+          Version   : '2012-10-17',
+          Statement : [
+            {
+              Action : [
+                'dynamodb:PutItem'
+              ],
+              Resource : { 'Fn::GetAtt' : ['ContactHandlerDynamoDB', 'Arn'] },
+              Effect   : 'Allow'
+            },
+            {
+              Effect   : 'Allow',
+              Action   : 'logs:CreateLogGroup',
+              Resource : `arn:aws:${region}:${accountID}:*`
+            },
+            {
+              Effect : 'Allow',
+              Action : [
+                'logs:CreateLogStream',
+                'logs:PutLogEvents'
+              ],
+              Resource : [
+                `arn:aws:logs:${region}:${accountID}:log-group:${contactHandlerLogGroupName}:*`
+              ]
+            }
+          ]
+        }
+      ],
+      Tags : tags
+    } // Properties
+  }
+  finalTemplate.Outputs.ContactHandlerRole = { Value : { Ref : 'ContactHandlerRole' } }
+  resourceTypes['IAM::Role'] = true
+ 
+  finalTemplate.Resources.ContactHandlerLogGroup = {
+    Type       : 'AWS::Logs::LogGroup',
+    Properties : {
+      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
+      LogGroupName    : contactHandlerLogGroupName,
+      RetentionInDays : 180, // TODO: support options,
+      Tags            : tags
+    }
+  }
+ 
+  finalTemplate.Resources.ContactHandlerLambdaFunction = {
+    Type       : 'AWS::Lambda::Function',
+    DependsOn  : ['ContactHandlerRole', 'ContactHandlerLogGroup'],
+    Properties : {
+      FunctionName : contactHandlerFunctionName,
+      Description  : 'Handles contact form submissions; creates DynamoDB entry and sends email.',
+      Code         : {
+        S3Bucket : lambdaFunctionsBucketName,
+        S3Key    : CONTACT_HANDLER_ZIP_NAME
+      },
+      Handler     : 'index.handler',
+      Role        : { 'Fn::GetAtt' : ['ContactHandlerRole', 'Arn'] },
+      Runtime     : 'nodejs20.x',
+      MemorySize  : 128,
+      Timeout     : 5,
+      Environment : {
+        Variables : {
+          TABLE_PREFIX : bucketName,
+          FORM_FIELDS  : formFieldsSpec
+        }
+      },
+      LoggingConfig : {
+        ApplicationLogLevel : 'INFO', // support options
+        LogFormat           : 'JSON', // support options
+        LogGroup            : contactHandlerLogGroupName,
+        SystemLogLevel      : 'INFO' // support options
+      },
+      Tags : tags
+    } // Properties
+  }
+  finalTemplate.Outputs.ContactHandlerLambdaFunction = { Value : { Ref : 'ContactHandlerLambdaFunction' } }
+  resourceTypes['Lambda::Function'] = true
+ 
+  finalTemplate.Resources.ContactHandlerLambdaPermission = {
+    Type       : 'AWS::Lambda::Permission',
+    DependsOn  : ['SiteCloudFrontDistribution', 'ContactHandlerLambdaFunction'],
+    Properties : {
+      Action              : 'lambda:InvokeFunctionUrl',
+      Principal           : 'cloudfront.amazonaws.com',
+      FunctionName        : contactHandlerFunctionName,
+      FunctionUrlAuthType : 'AWS_IAM',
+      SourceArn           : {
+        'Fn::Join' : ['', [`arn:aws:cloudfront::${accountID}:distribution/`, { 'Fn::GetAtt' : ['SiteCloudFrontDistribution', 'Id'] }]]
+      }
+    }
+  }
+ 
+  finalTemplate.Resources.ContactHandlerLambdaURL = {
+    Type       : 'AWS::Lambda::Url',
+    DependsOn  : ['ContactHandlerLambdaFunction'],
+    Properties : {
+      AuthType : 'AWS_IAM',
+      Cors     : {
+        AllowCredentials : true,
+        AllowHeaders     : ['*'],
+        AllowMethods     : ['POST'],
+        AllowOrigins     : ['*']
+      },
+      TargetFunctionArn : { 'Fn::GetAtt' : ['ContactHandlerLambdaFunction', 'Arn'] }
+    }
+  }
+  finalTemplate.Outputs.ContactHandlerLambdaURL = { Value : { Ref : 'ContactHandlerLambdaURL' } }
+  resourceTypes['Lambda::Url'] = true
+ 
+  Iif (update === true) {
+    const client = new LambdaClient({ credentials })
+    const command = new UpdateFunctionCodeCommand({ // UpdateFunctionCodeRequest
+      FunctionName : contactHandlerFunctionName,
+      S3Bucket     : lambdaFunctionsBucketName,
+      S3Key        : CONTACT_HANDLER_ZIP_NAME
+      // Publish: true || false,
+    })
+    await client.send(command)
+  }
+}
+ 
+export { setupContactHandler }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html new file mode 100644 index 00000000..6995c985 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html @@ -0,0 +1,403 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/setup-request-signer.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib setup-request-signer.mjs

+
+ +
+ 0% + Statements + 0/18 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/18 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { REQUEST_SIGNER_ZIP_NAME } from './constants'
+import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
+import { determineLambdaFunctionName } from './determine-lambda-function-name'
+import { getSiteTag } from '../../../shared/get-site-tag'
+ 
+const setupRequestSigner = async ({ credentials, lambdaFunctionsBucketName, pluginData, update, siteTemplate }) => {
+  const { finalTemplate, siteInfo } = siteTemplate
+  const { apexDomain } = siteInfo
+ 
+  const siteTag = getSiteTag(siteInfo)
+  const tags = [{ Key : siteTag, Value : '' }]
+ 
+  const requestSignerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-request-signer'
+  const requestSignerFunctionName = update === true
+    ? pluginData.requestSignerFunctionName
+    : (await determineLambdaFunctionName({
+        baseName : requestSignerFunctionBaseName,
+        credentials,
+        siteTemplate
+      }))
+  pluginData.requestSignerFunctionName = requestSignerFunctionName
+ 
+  finalTemplate.Resources.RequestSignerRole = {
+    Type       : 'AWS::IAM::Role',
+    DependsOn  : ['ContactHandlerLambdaFunction'],
+    Properties : {
+      AssumeRolePolicyDocument : {
+        Version   : '2012-10-17',
+        Statement : [
+          {
+            Effect    : 'Allow',
+            Principal : { Service : ['lambda.amazonaws.com', 'edgelambda.amazonaws.com'] },
+            Action    : ['sts:AssumeRole']
+          }
+        ]
+      },
+      Path     : '/cloudsite/request-signer/',
+      Policies : [
+        {
+          PolicyName     : requestSignerFunctionName,
+          PolicyDocument : {
+            Version   : '2012-10-17',
+            Statement : [
+              {
+                Effect   : 'Allow',
+                Action   : 'lambda:InvokeFunctionUrl',
+                Resource : { 'Fn::GetAtt' : ['ContactHandlerLambdaFunction', 'Arn'] }
+              }
+            ]
+          }
+        }
+      ],
+      // AWSLambdaBasicExecutionRole: allows logging to CloudWatch
+      ManagedPolicyArns : ['arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole'],
+      Tags              : tags
+    } // Properties
+  }
+ 
+  finalTemplate.Resources.RequestSignerLogGroup = {
+    Type       : 'AWS::Logs::LogGroup',
+    Properties : {
+      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
+      LogGroupName    : requestSignerFunctionName,
+      RetentionInDays : 180, // TODO: support options,
+      Tags            : tags
+    }
+  }
+ 
+  finalTemplate.Resources.SignRequestFunction = {
+    Type       : 'AWS::Lambda::Function',
+    DependsOn  : ['RequestSignerRole'],
+    Properties : {
+      FunctionName : requestSignerFunctionName,
+      Handler      : 'index.handler',
+      Role         : { 'Fn::GetAtt' : ['RequestSignerRole', 'Arn'] },
+      Runtime      : 'nodejs20.x',
+      MemorySize   : 128,
+      Timeout      : 5,
+      Code         : {
+        S3Bucket : lambdaFunctionsBucketName,
+        S3Key    : REQUEST_SIGNER_ZIP_NAME
+      },
+      LoggingConfig : {
+        ApplicationLogLevel : 'INFO', // support options
+        LogFormat           : 'JSON', // support options
+        LogGroup            : requestSignerFunctionName,
+        SystemLogLevel      : 'INFO' // support options
+      },
+      Tags : tags
+    } // Properties
+  }
+ 
+  finalTemplate.Resources.SignRequestFunctionVersion = {
+    Type       : 'AWS::Lambda::Version',
+    DependsOn  : ['SignRequestFunction'],
+    Properties : {
+      FunctionName : { 'Fn::GetAtt' : ['SignRequestFunction', 'Arn'] }
+    }
+  }
+ 
+  finalTemplate.Outputs.SignRequestFunction = {
+    Value : { Ref : 'SignRequestFunction' }
+  }
+}
+ 
+export { setupRequestSigner }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html new file mode 100644 index 00000000..4f437835 --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html @@ -0,0 +1,361 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib stage-lambda-function-zip-files.mjs

+
+ +
+ 0% + Statements + 0/33 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/33 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { join as pathJoin } from 'node:path'
+import { createReadStream } from 'node:fs'
+ 
+import { CreateBucketCommand, PutBucketTaggingCommand, PutObjectCommand, S3Client } from '@aws-sdk/client-s3'
+ 
+import { CONTACT_EMAILER_ZIP_NAME, CONTACT_HANDLER_ZIP_NAME, REQUEST_SIGNER_ZIP_NAME } from './constants'
+import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
+import { determineBucketName } from '../../../shared/determine-bucket-name'
+import { getSiteTag } from '../../../shared/get-site-tag'
+import { progressLogger } from '../../../shared/progress-logger'
+// jsdoc wants this, but it causes a circular dependency
+// import { SiteTemplate } from '../../../shared/site-template'
+ 
+/* eslint-disable  jsdoc/no-undefined-types */ // See note above re. SiteTemplate
+/**
+ * Stages the zipped Lambda function packages on a common S3 bucket.
+ * @param {object} input - Destructured input argument.
+ * @param {boolean} input.enableEmail - True if the site is to be built with email on contact form submission support.
+ * @param {object} input.siteInfo - See {@link SiteTemplate} for details.
+ * @returns {string} The Lambda function bucket name.
+ */ /* eslint-enable  jsdoc/no-undefined-types */
+const stageLambdaFunctionZipFiles = async ({ credentials, enableEmail, pluginData, siteInfo }) => {
+  progressLogger.write('Staging Lambda function zip files...\n')
+ 
+  let { lambdaFunctionsBucket } = pluginData
+  const { apexDomain, region } = siteInfo
+ 
+  const s3Client = new S3Client({ credentials, region })
+ 
+  Iif (lambdaFunctionsBucket === undefined) {
+    lambdaFunctionsBucket = convertDomainToBucketName(apexDomain) + '-lambda-functions'
+    lambdaFunctionsBucket =
+      await determineBucketName({
+        bucketName : lambdaFunctionsBucket,
+        credentials,
+        findName   : true,
+        s3Client,
+        siteInfo
+      })
+ 
+    const createBucketCommand = new CreateBucketCommand({
+      ACL    : 'private',
+      Bucket : lambdaFunctionsBucket
+    })
+    await s3Client.send(createBucketCommand)
+  }
+ 
+  const siteTag = getSiteTag(siteInfo)
+  const putBucketTaggingCommand = new PutBucketTaggingCommand({
+    Bucket  : lambdaFunctionsBucket,
+    Tagging : {
+      TagSet : [{ Key : siteTag, Value : '' }]
+    }
+  })
+  await s3Client.send(putBucketTaggingCommand)
+ 
+  pluginData.lambdaFunctionsBucket = lambdaFunctionsBucket
+ 
+  const putCommands = [
+    putZipFile({ bucketName : lambdaFunctionsBucket, fileName : CONTACT_HANDLER_ZIP_NAME, s3Client }),
+    putZipFile({ bucketName : lambdaFunctionsBucket, fileName : REQUEST_SIGNER_ZIP_NAME, s3Client })
+  ]
+ 
+  Iif (enableEmail === true) {
+    putCommands.push(putZipFile({
+      bucketName : lambdaFunctionsBucket,
+      fileName   : CONTACT_EMAILER_ZIP_NAME,
+      s3Client
+    }))
+  }
+ 
+  await Promise.all(putCommands)
+ 
+  return lambdaFunctionsBucket
+}
+ 
+const putZipFile = async ({ bucketName, fileName, s3Client }) => {
+  // when built, everything sits in './dist' together
+  const zipPath = pathJoin(__dirname, fileName)
+  const readStream = createReadStream(zipPath)
+ 
+  const putObjectCommand = new PutObjectCommand({
+    Body        : readStream,
+    Bucket      : bucketName,
+    Key         : fileName,
+    ContentType : 'application/zip'
+  })
+ 
+  await s3Client.send(putObjectCommand)
+}
+ 
+export { stageLambdaFunctionZipFiles }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html new file mode 100644 index 00000000..924adefd --- /dev/null +++ b/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html @@ -0,0 +1,220 @@ + + + + + + Code coverage report for lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs + + + + + + + + + +
+
+

All files / lib/plugins/contact-handler/lib update-cloud-front-distribution.mjs

+
+ +
+ 0% + Statements + 0/11 +
+ + +
+ 0% + Branches + 0/2 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/11 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
const updateCloudFrontDistribution = ({ pluginData, siteTemplate }) => {
+  const { finalTemplate } = siteTemplate
+  const contactHandlerPath = pluginData.settings.urlPath
+ 
+  finalTemplate.Resources.SiteCloudFrontDistribution.DependsOn.push('ContactHandlerLambdaURL')
+ 
+  const cfOrigins = finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Origins
+  cfOrigins.push({
+    Id         : 'ContactHandlerLambdaOrigin',
+    DomainName : { // strip the https://
+      'Fn::Select' : [2, { 'Fn::Split' : ['/', { 'Fn::GetAtt' : ['ContactHandlerLambdaURL', 'FunctionUrl'] }] }]
+    },
+    CustomOriginConfig : {
+      HTTPSPort            : 443,
+      OriginProtocolPolicy : 'https-only'
+    }
+  })
+ 
+  const cfCacheBehaviors =
+    finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.CacheBehaviors || []
+  cfCacheBehaviors.push({
+    AllowedMethods             : ['DELETE', 'GET', 'HEAD', 'OPTIONS', 'PATCH', 'POST', 'PUT'],
+    CachePolicyId              : '4135ea2d-6df8-44a3-9df3-4b5a84be39ad', // caching disabled managed policy
+    PathPattern                : contactHandlerPath,
+    TargetOriginId             : 'ContactHandlerLambdaOrigin',
+    ViewerProtocolPolicy       : 'https-only',
+    LambdaFunctionAssociations : [
+      {
+        EventType         : 'origin-request',
+        IncludeBody       : true,
+        LambdaFunctionARN : {
+          'Fn::Join' : [':', [
+            { 'Fn::GetAtt' : ['SignRequestFunction', 'Arn'] },
+            { 'Fn::GetAtt' : ['SignRequestFunctionVersion', 'Version'] }]
+          ]
+        }
+      }
+    ]
+  })
+ 
+  finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.CacheBehaviors = cfCacheBehaviors
+  finalTemplate.Resources.SiteCloudFrontDistribution.DependsOn.push('SignRequestFunctionVersion')
+}
+ 
+export { updateCloudFrontDistribution }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/plugins/index.html b/qa/coverage/lib/plugins/index.html new file mode 100644 index 00000000..b61ca4c4 --- /dev/null +++ b/qa/coverage/lib/plugins/index.html @@ -0,0 +1,131 @@ + + + + + + Code coverage report for lib/plugins + + + + + + + + + +
+
+

All files lib/plugins

+
+ +
+ 0% + Statements + 0/20 +
+ + +
+ 0% + Branches + 0/1 +
+ + +
+ 0% + Functions + 0/7 +
+ + +
+ 0% + Lines + 0/20 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
access-logs.mjs +
+
0%0/6100%0/00%0/30%0/6
cloudfront-logs.mjs +
+
0%0/140%0/10%0/40%0/14
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html b/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html new file mode 100644 index 00000000..0636b342 --- /dev/null +++ b/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html @@ -0,0 +1,94 @@ + + + + + + Code coverage report for lib/shared/convert-domain-to-bucket-name.js + + + + + + + + + +
+
+

All files / lib/shared convert-domain-to-bucket-name.js

+
+ +
+ 0% + Statements + 0/3 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4  +  +  + 
const convertDomainToBucketName = (domain) => domain.replaceAll(/\./g, '-').replaceAll(/[^a-z0-9-]/g, 'x')
+ 
+export { convertDomainToBucketName }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/determine-bucket-name.mjs.html b/qa/coverage/lib/shared/determine-bucket-name.mjs.html new file mode 100644 index 00000000..e007b79d --- /dev/null +++ b/qa/coverage/lib/shared/determine-bucket-name.mjs.html @@ -0,0 +1,241 @@ + + + + + + Code coverage report for lib/shared/determine-bucket-name.mjs + + + + + + + + + +
+
+

All files / lib/shared determine-bucket-name.mjs

+
+ +
+ 0% + Statements + 0/34 +
+ + +
+ 0% + Branches + 0/13 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/34 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { v4 as uuidv4 } from 'uuid'
+ 
+import { S3Client, HeadBucketCommand } from '@aws-sdk/client-s3'
+ 
+import { convertDomainToBucketName } from './convert-domain-to-bucket-name'
+import { getAccountID } from './get-account-id'
+import { progressLogger } from './progress-logger'
+ 
+const determineBucketName = async (args) => {
+  const { apexDomain, credentials, findName = false, siteInfo } = args
+  let { bucketName, s3Client } = args
+ 
+  Iif (bucketName === undefined) {
+    bucketName = siteInfo.bucketName || convertDomainToBucketName(apexDomain)
+  }
+ 
+  const { accountID } = siteInfo
+  Iif (accountID === undefined) {
+    const accountID = await getAccountID({ credentials })
+    siteInfo.accountID = accountID
+  }
+ 
+  s3Client = s3Client || new S3Client({ credentials })
+ 
+  while (true) {
+    progressLogger.write(`Checking bucket '${bucketName}' is free... `)
+ 
+    const input = { Bucket : bucketName, ExpectedBucketOwner : accountID }
+ 
+    const command = new HeadBucketCommand(input)
+    try {
+      await s3Client.send(command)
+      Iif (findName !== true) {
+        throw new Error(`Account already owns bucket '${bucketName}'; delete or specify alternate bucket name.`)
+      }
+    } catch (e) {
+      if (e.name === 'NotFound') {
+        progressLogger.write('FREE\n')
+        return bucketName
+      } else Iif (findName !== true || e.name === 'CredentialsProviderError') {
+        progressLogger.write('\n')
+        throw e
+      }
+    }
+    progressLogger.write('NOT free\n')
+    const bucketSalt = uuidv4().slice(0, 8)
+    bucketName = bucketName.replace(/-[A-F0-9]{8}$/i, '')
+    bucketName += '-' + bucketSalt
+  }
+}
+ 
+export { determineBucketName }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/determine-oac-name.mjs.html b/qa/coverage/lib/shared/determine-oac-name.mjs.html new file mode 100644 index 00000000..8792187f --- /dev/null +++ b/qa/coverage/lib/shared/determine-oac-name.mjs.html @@ -0,0 +1,235 @@ + + + + + + Code coverage report for lib/shared/determine-oac-name.mjs + + + + + + + + + +
+
+

All files / lib/shared determine-oac-name.mjs

+
+ +
+ 0% + Statements + 0/29 +
+ + +
+ 0% + Branches + 0/14 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/28 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { v4 as uuidv4 } from 'uuid'
+ 
+import { CloudFrontClient, ListOriginAccessControlsCommand } from '@aws-sdk/client-cloudfront'
+ 
+import { progressLogger } from './progress-logger'
+ 
+const determineOACName = async ({ baseName, credentials, siteInfo }) => {
+  const { region } = siteInfo
+  let currentName = baseName
+ 
+  // there is on way to get an OAC based on teh name alone, you need the ID (ARN?) which we don't have. So, we have to
+  // list the OACs and search for one with the given name
+  const allOACNames = await getAllOACNames({ credentials, region })
+ 
+  while (true) {
+    progressLogger?.write(`Checking if OAC name '${currentName}' is free... `)
+    if (allOACNames.includes(currentName)) {
+      progressLogger?.write('NOT free\n')
+      const nameSalt = uuidv4().slice(0, 8)
+      currentName = currentName.replace(/-[A-F0-9]{8}$/i, '')
+      currentName += '-' + nameSalt
+    } else {
+      progressLogger?.write('FREE\n')
+      return currentName
+    }
+  }
+}
+ 
+const getAllOACNames = async ({ credentials, region }) => {
+  const cloudfrontClient = new CloudFrontClient({ credentials, region })
+  let currentMarker
+  const result = []
+  while (true) {
+    const listOACCommand = new ListOriginAccessControlsCommand({
+      Marker : currentMarker
+    })
+ 
+    const oacListResponse = await cloudfrontClient.send(listOACCommand)
+    const items = oacListResponse.OriginAccessControlList.Items || []
+ 
+    result.push(...items.map(({ Name : name }) => name))
+ 
+    currentMarker = oacListResponse.OriginAccessControlList.NextMarker
+    Iif (currentMarker === undefined) {
+      return result
+    }
+  }
+}
+ 
+export { determineOACName }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/find-bucket-like.mjs.html b/qa/coverage/lib/shared/find-bucket-like.mjs.html new file mode 100644 index 00000000..765e5452 --- /dev/null +++ b/qa/coverage/lib/shared/find-bucket-like.mjs.html @@ -0,0 +1,166 @@ + + + + + + Code coverage report for lib/shared/find-bucket-like.mjs + + + + + + + + + +
+
+

All files / lib/shared find-bucket-like.mjs

+
+ +
+ 0% + Statements + 0/19 +
+ + +
+ 0% + Branches + 0/16 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 0% + Lines + 0/18 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { ListBucketsCommand, S3Client } from '@aws-sdk/client-s3'
+ 
+import { progressLogger } from './progress-logger'
+ 
+const findBucketLike = async ({ credentials, description, partialName }) => {
+  progressLogger?.write(`Attempting to find ${description} bucket... `)
+  const s3Client = new S3Client({ credentials })
+  const listBucketsCommand = new ListBucketsCommand({})
+  const { Buckets : buckets } = await s3Client.send(listBucketsCommand)
+ 
+  const possibleMatches = buckets.filter(({ Name : name }) => name.startsWith(partialName))
+ 
+  if (possibleMatches.length === 0) {
+    progressLogger?.write('NONE found\n')
+  } else if (possibleMatches.length === 1) {
+    const commonLogsBucket = possibleMatches[0].Name
+    progressLogger?.write('found: ' + commonLogsBucket + '\n')
+    return commonLogsBucket
+  } else { // possible matches greater than one, but commonLogsBucket not set
+    // TODO: tailor the message for CLI or library...
+    progressLogger?.write('found multiple\n')
+    throw new Error("Found multiple possible 'common logs' buckets; specify which to use with '--common-logs-bucket': " +
+        possibleMatches.map(({ Name : name }) => name).join(', '))
+  }
+}
+ 
+export { findBucketLike }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/get-account-id.mjs.html b/qa/coverage/lib/shared/get-account-id.mjs.html new file mode 100644 index 00000000..8b53cf26 --- /dev/null +++ b/qa/coverage/lib/shared/get-account-id.mjs.html @@ -0,0 +1,124 @@ + + + + + + Code coverage report for lib/shared/get-account-id.mjs + + + + + + + + + +
+
+

All files / lib/shared get-account-id.mjs

+
+ +
+ 0% + Statements + 0/8 +
+ + +
+ 0% + Branches + 0/3 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/8 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { STSClient, GetCallerIdentityCommand } from '@aws-sdk/client-sts'
+ 
+import { progressLogger } from './progress-logger'
+ 
+const getAccountID = async ({ credentials }) => {
+  progressLogger?.write('Getting effective account ID...\n')
+  const response = await new STSClient({ credentials }).send(new GetCallerIdentityCommand({}))
+  const accountID = response.Account
+ 
+  return accountID
+}
+ 
+export { getAccountID }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/get-site-tag.mjs.html b/qa/coverage/lib/shared/get-site-tag.mjs.html new file mode 100644 index 00000000..55077d11 --- /dev/null +++ b/qa/coverage/lib/shared/get-site-tag.mjs.html @@ -0,0 +1,100 @@ + + + + + + Code coverage report for lib/shared/get-site-tag.mjs + + + + + + + + + +
+
+

All files / lib/shared get-site-tag.mjs

+
+ +
+ 0% + Statements + 0/3 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/1 +
+ + +
+ 0% + Lines + 0/3 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6  +  +  +  +  + 
const getSiteTag = (siteInfo) => {
+  return 'site:' + siteInfo.apexDomain
+}
+ 
+export { getSiteTag }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/index.html b/qa/coverage/lib/shared/index.html new file mode 100644 index 00000000..ea09060e --- /dev/null +++ b/qa/coverage/lib/shared/index.html @@ -0,0 +1,221 @@ + + + + + + Code coverage report for lib/shared + + + + + + + + + +
+
+

All files lib/shared

+
+ +
+ 3.57% + Statements + 6/168 +
+ + +
+ 0% + Branches + 0/74 +
+ + +
+ 5% + Functions + 1/20 +
+ + +
+ 3.68% + Lines + 6/163 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
convert-domain-to-bucket-name.js +
+
0%0/3100%0/00%0/10%0/1
determine-bucket-name.mjs +
+
0%0/340%0/130%0/10%0/34
determine-oac-name.mjs +
+
0%0/290%0/140%0/30%0/28
find-bucket-like.mjs +
+
0%0/190%0/160%0/30%0/18
get-account-id.mjs +
+
0%0/80%0/30%0/10%0/8
get-site-tag.mjs +
+
0%0/3100%0/00%0/10%0/3
progress-logger.mjs +
+
66.66%6/90%0/150%1/266.66%6/9
site-template.mjs +
+
0%0/630%0/270%0/80%0/62
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/progress-logger.mjs.html b/qa/coverage/lib/shared/progress-logger.mjs.html new file mode 100644 index 00000000..5fc613a2 --- /dev/null +++ b/qa/coverage/lib/shared/progress-logger.mjs.html @@ -0,0 +1,139 @@ + + + + + + Code coverage report for lib/shared/progress-logger.mjs + + + + + + + + + +
+
+

All files / lib/shared progress-logger.mjs

+
+ +
+ 66.66% + Statements + 6/9 +
+ + +
+ 0% + Branches + 0/1 +
+ + +
+ 50% + Functions + 1/2 +
+ + +
+ 66.66% + Lines + 6/9 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +192x +  +2x +  +2x +1x +  +1x +  +  +  +  +  +  +  +2x +  +  + 
import { getPrinter } from 'magic-print'
+ 
+const progressLogger = {}
+ 
+const configureLogger = (options) => {
+  const print = getPrinter(options)
+ 
+  progressLogger.write = (...chunk) => {
+    // do options here so it'll react to changes
+    const { quiet } = options
+ 
+    Iif (quiet !== true) {
+      print(...chunk)
+    }
+  }
+}
+ 
+export { configureLogger, progressLogger }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/lib/shared/site-template.mjs.html b/qa/coverage/lib/shared/site-template.mjs.html new file mode 100644 index 00000000..115dd280 --- /dev/null +++ b/qa/coverage/lib/shared/site-template.mjs.html @@ -0,0 +1,892 @@ + + + + + + Code coverage report for lib/shared/site-template.mjs + + + + + + + + + +
+
+

All files / lib/shared site-template.mjs

+
+ +
+ 0% + Statements + 0/63 +
+ + +
+ 0% + Branches + 0/27 +
+ + +
+ 0% + Functions + 0/8 +
+ + +
+ 0% + Lines + 0/62 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+ +
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import yaml from 'js-yaml'
+ 
+import { emptyBucket } from 's3-empty-bucket'
+ 
+import { S3Client } from '@aws-sdk/client-s3'
+ 
+import { determineBucketName } from './determine-bucket-name'
+import { determineOACName } from './determine-oac-name'
+import { getSiteTag } from './get-site-tag'
+import * as plugins from '../plugins'
+import { progressLogger } from './progress-logger'I
+ 
+/**
+ * Class encapsulating site stack configuration. Any enabled plugins are loaded and processed by this class.
+ * @class
+ */
+const SiteTemplate = class {
+  /* eslint-disable jsdoc/check-param-names */ // eslint doesn't believe our 2nd level destructure documentation
+  /**
+   * Creates a new {@link SiteTemplate}.
+   * @param {object} input - Destructured input argument.
+   * @param {object} input.credentials - credentials for AWS SDK clients.
+   * @param {object} input.siteInfo - Collection of site related data elements.
+   * @param {string} input.siteInfo.apexDomain - the sites apex domain
+   * @param {string} input.siteInfo.sourcePath - the path to the site's static source files, may be absolute or CWD
+   *   relative
+   * @param {string} input.siteInfo.region - the region of the site
+   * @param {string} input.siteInfo.certificateArn {string} - the AWS ARN for the site's SSL certificate
+   * @param {string} input.siteInfo.accountID - the ID of the account under which the stack resides (not ARN)
+   * @param {string} input.siteInfo.bucketName - the name of the bucket where the site's static files are stored
+   * @param {string} input.siteInfo.stackName - the name of the stack
+   * @param {string} input.siteInfo.stackArn - the stack's ARN
+   * @param {string} input.siteInfo.cloudFrontDistributionID - the stack's CloudfFront ID (not ARN)
+   * @param {object} input.siteInfo.plugins - collection of plugin settings; settings are grouped/keyed by the
+   *   plugin's name; setting values are dependent on the plugin
+   * @param credentials.siteInfo
+   */ /* eslint-enable jsdoc/check-param-names */
+  constructor ({ credentials, siteInfo }) {
+    this.siteInfo = siteInfo
+    this.credentials = credentials
+ 
+    this.resourceTypes = { 'CloudFormation::Distribution' : true, 'S3::Bucket' : true }
+    this.finalTemplate = this.baseTemplate
+  }
+ 
+  async initializeTemplate ({ update } = {}) {
+    const { siteInfo } = this
+    const { accountID, apexDomain, bucketName, certificateArn, region } = siteInfo
+    const siteTag = getSiteTag(siteInfo)
+ 
+    const oacName = update === true
+      ? siteInfo.oacName
+      : await determineOACName({
+        baseName    : `${bucketName}-OAC`,
+        credentials : this.credentials,
+        siteInfo    : this.siteInfo
+      })
+    progressLogger?.write(`Using OAC name: ${oacName}\n`)
+    this.siteInfo.oacName = oacName
+ 
+    this.finalTemplate = {
+      Resources : {
+        SiteS3Bucket : {
+          Type       : 'AWS::S3::Bucket',
+          Properties : {
+            AccessControl : 'Private',
+            BucketName    : bucketName,
+            Tags          : [{ Key : siteTag, Value : '' }]
+          }
+        },
+        SiteCloudFrontOriginAccessControl : {
+          Type       : 'AWS::CloudFront::OriginAccessControl',
+          Properties : {
+            OriginAccessControlConfig : {
+              Description                   : 'Origin Access Control (OAC) allowing CloudFront Distribution to access site S3 bucket.',
+              Name                          : oacName,
+              OriginAccessControlOriginType : 's3',
+              SigningBehavior               : 'always',
+              SigningProtocol               : 'sigv4'
+            }
+          }
+        },
+        SiteCloudFrontDistribution : {
+          Type       : 'AWS::CloudFront::Distribution',
+          DependsOn  : ['SiteS3Bucket'],
+          Properties : {
+            DistributionConfig : {
+              Origins : [
+                {
+                  DomainName     : `${bucketName}.s3.${region}.amazonaws.com`,
+                  Id             : 'static-hosting',
+                  S3OriginConfig : {
+                    OriginAccessIdentity : ''
+                  },
+                  OriginAccessControlId : { 'Fn::GetAtt' : ['SiteCloudFrontOriginAccessControl', 'Id'] }
+                }
+              ],
+              Enabled              : true,
+              DefaultRootObject    : 'index.html',
+              CustomErrorResponses : [
+                { ErrorCode : 403, ResponseCode : 200, ResponsePagePath : '/index.html' },
+                { ErrorCode : 404, ResponseCode : 200, ResponsePagePath : '/index.html' }
+              ],
+              HttpVersion       : 'http2',
+              Aliases           : [apexDomain, `www.${apexDomain}`],
+              ViewerCertificate : {
+                AcmCertificateArn      : certificateArn,
+                MinimumProtocolVersion : 'TLSv1.2_2021',
+                SslSupportMethod       : 'sni-only'
+              },
+              DefaultCacheBehavior : {
+                AllowedMethods       : ['GET', 'HEAD'],
+                CachePolicyId        : '658327ea-f89d-4fab-a63d-7e88639e58f6', // CachingOptimized cache policy ID
+                Compress             : true,
+                TargetOriginId       : 'static-hosting',
+                ViewerProtocolPolicy : 'redirect-to-https'
+              }
+            }, // DistributionConfig
+            Tags : [{ Key : siteTag, Value : '' }]
+          } // Properties
+        }, // SiteCloudFrontDistribution
+        SiteBucketPolicy : {
+          Type       : 'AWS::S3::BucketPolicy',
+          DependsOn  : ['SiteS3Bucket', 'SiteCloudFrontDistribution'],
+          Properties : {
+            Bucket         : bucketName,
+            PolicyDocument : {
+              Version   : '2012-10-17',
+              Statement : [
+                {
+                  Effect    : 'Allow',
+                  Principal : {
+                    Service : 'cloudfront.amazonaws.com'
+                  },
+                  Action    : 's3:GetObject',
+                  Resource  : `arn:aws:s3:::${bucketName}/*`,
+                  Condition : {
+                    StringEquals : {
+                      'AWS:SourceArn' : {
+                        'Fn::Join' : ['', [`arn:aws:cloudfront::${accountID}:distribution/`, { 'Fn::GetAtt' : ['SiteCloudFrontDistribution', 'Id'] }]]
+                      }
+                    }
+                  }
+                }
+              ]
+            }
+          }
+        }
+      }, // Resources
+      Outputs : {
+        SiteS3Bucket : {
+          Value : { Ref : 'SiteS3Bucket' }
+        },
+        SiteCloudFrontOriginAccessControl : {
+          Value : { Ref : 'SiteCloudFrontOriginAccessControl' }
+        },
+        SiteCloudFrontDistribution : {
+          Value : { Ref : 'SiteCloudFrontDistribution' }
+        },
+        OriginAccessControl : {
+          Value : { Ref : 'SiteCloudFrontOriginAccessControl' }
+        }
+      }
+    }
+  }
+ 
+  async destroyCommonLogsBucket () {
+    const { siteInfo } = this
+    const { commonLogsBucket } = siteInfo
+ 
+    if (commonLogsBucket !== undefined) {
+      progressLogger.write('Deleting common logs bucket...\n')
+      const s3Client = new S3Client({ credentials : this.credentials })
+      emptyBucket({
+        bucketName : commonLogsBucket,
+        doDelete   : true,
+        s3Client,
+        verbose    : progressLogger !== undefined
+      })
+      delete siteInfo.commonLogsBucket
+    } else {
+      progressLogger?.write('Looks like the shared logging bucket has already been deleted; skipping.\n')
+    }
+  }
+ 
+  async enableCommonLogsBucket () {
+    const { bucketName } = this.siteInfo // used to create a name for the shared logging bucket
+    let { commonLogsBucket = bucketName + '-common-logs' } = this.siteInfo
+    const siteTag = getSiteTag(this.siteInfo)
+ 
+    Iif (commonLogsBucket === undefined) {
+      commonLogsBucket = await determineBucketName({
+        bucketName  : commonLogsBucket,
+        credentials : this.credentials,
+        findName    : true,
+        siteInfo    : this.siteInfo
+      })
+    }
+    this.siteInfo.commonLogsBucket = commonLogsBucket
+ 
+    this.finalTemplate.Resources.commonLogsBucket = {
+      Type       : 'AWS::S3::Bucket',
+      Properties : {
+        AccessControl     : 'Private',
+        BucketName        : commonLogsBucket,
+        OwnershipControls : { // this enables ACLs, as required by CloudFront standard logging
+          Rules : [{ ObjectOwnership : 'BucketOwnerPreferred' }]
+        },
+        Tags : [{ Key : siteTag, Value : '' }]
+      }
+    }
+ 
+    return commonLogsBucket
+  }
+ 
+  async destroyPlugins () {
+    const { siteInfo } = this
+    const { apexDomain } = siteInfo
+    const pluginsData = siteInfo.plugins || {}
+ 
+    for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
+      const plugin = plugins[pluginKey]
+      Iif (plugin === undefined) {
+        throw new Error(`Unknown plugin found in '${apexDomain}' plugin settings.`)
+      }
+ 
+      const { preStackDestroyHandler } = plugin
+      Iif (preStackDestroyHandler !== undefined) {
+        await preStackDestroyHandler({ siteTemplate : this, pluginData })
+      }
+    }
+  }
+ 
+  async loadPlugins ({ update } = {}) {
+    const { siteInfo } = this
+    const { apexDomain } = siteInfo
+    const pluginsData = siteInfo.plugins || {}
+ 
+    const pluginConfigs = []
+    for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
+      const plugin = plugins[pluginKey]
+      Iif (plugin === undefined) {
+        throw new Error(`Unknown plugin found in '${apexDomain}' plugin settings.`)
+      }
+ 
+      pluginConfigs.push(plugin.stackConfig({ siteTemplate : this, pluginData, update }))
+    }
+ 
+    await Promise.all(pluginConfigs)
+  }
+ 
+  render () {
+    const { apexDomain } = this.siteInfo
+    const resourceTypes = Object.keys(this.resourceTypes).sort()
+ 
+    const outputTemplate = Object.assign({
+      AWSTemplateFormatVersion : '2010-09-09',
+      Description              : `${apexDomain} site built with ${resourceTypes.slice(0, -1).join(', ')} and ${resourceTypes[resourceTypes.length - 1]}.`
+    },
+    this.finalTemplate
+    )
+ 
+    // turn off multi-line blocks and (must) turn off refs to prevent aliasing of repeated tags objects
+    const output = yaml.dump(outputTemplate, { lineWidth : 0, noRefs : true })
+    return output
+  }
+}
+ 
+export { SiteTemplate }
+ 
+ +
+
+ + + + + + + + \ No newline at end of file diff --git a/qa/coverage/prettify.css b/qa/coverage/prettify.css new file mode 100644 index 00000000..b317a7cd --- /dev/null +++ b/qa/coverage/prettify.css @@ -0,0 +1 @@ +.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee} diff --git a/qa/coverage/prettify.js b/qa/coverage/prettify.js new file mode 100644 index 00000000..b3225238 --- /dev/null +++ b/qa/coverage/prettify.js @@ -0,0 +1,2 @@ +/* eslint-disable */ +window.PR_SHOULD_USE_CONTINUATION=true;(function(){var h=["break,continue,do,else,for,if,return,while"];var u=[h,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"];var p=[u,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"];var l=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"];var x=[p,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"];var R=[x,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"];var r="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes";var w=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"];var s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END";var I=[h,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"];var f=[h,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"];var H=[h,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"];var A=[l,R,w,s+I,f,H];var e=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/;var C="str";var z="kwd";var j="com";var O="typ";var G="lit";var L="pun";var F="pln";var m="tag";var E="dec";var J="src";var P="atn";var n="atv";var N="nocode";var M="(?:^^\\.?|[+-]|\\!|\\!=|\\!==|\\#|\\%|\\%=|&|&&|&&=|&=|\\(|\\*|\\*=|\\+=|\\,|\\-=|\\->|\\/|\\/=|:|::|\\;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\@|\\[|\\^|\\^=|\\^\\^|\\^\\^=|\\{|\\||\\|=|\\|\\||\\|\\|=|\\~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function k(Z){var ad=0;var S=false;var ac=false;for(var V=0,U=Z.length;V122)){if(!(al<65||ag>90)){af.push([Math.max(65,ag)|32,Math.min(al,90)|32])}if(!(al<97||ag>122)){af.push([Math.max(97,ag)&~32,Math.min(al,122)&~32])}}}}af.sort(function(av,au){return(av[0]-au[0])||(au[1]-av[1])});var ai=[];var ap=[NaN,NaN];for(var ar=0;arat[0]){if(at[1]+1>at[0]){an.push("-")}an.push(T(at[1]))}}an.push("]");return an.join("")}function W(al){var aj=al.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g"));var ah=aj.length;var an=[];for(var ak=0,am=0;ak=2&&ai==="["){aj[ak]=X(ag)}else{if(ai!=="\\"){aj[ak]=ag.replace(/[a-zA-Z]/g,function(ao){var ap=ao.charCodeAt(0);return"["+String.fromCharCode(ap&~32,ap|32)+"]"})}}}}return aj.join("")}var aa=[];for(var V=0,U=Z.length;V=0;){S[ac.charAt(ae)]=Y}}var af=Y[1];var aa=""+af;if(!ag.hasOwnProperty(aa)){ah.push(af);ag[aa]=null}}ah.push(/[\0-\uffff]/);V=k(ah)})();var X=T.length;var W=function(ah){var Z=ah.sourceCode,Y=ah.basePos;var ad=[Y,F];var af=0;var an=Z.match(V)||[];var aj={};for(var ae=0,aq=an.length;ae=5&&"lang-"===ap.substring(0,5);if(am&&!(ai&&typeof ai[1]==="string")){am=false;ap=J}if(!am){aj[ag]=ap}}var ab=af;af+=ag.length;if(!am){ad.push(Y+ab,ap)}else{var al=ai[1];var ak=ag.indexOf(al);var ac=ak+al.length;if(ai[2]){ac=ag.length-ai[2].length;ak=ac-al.length}var ar=ap.substring(5);B(Y+ab,ag.substring(0,ak),W,ad);B(Y+ab+ak,al,q(ar,al),ad);B(Y+ab+ac,ag.substring(ac),W,ad)}}ah.decorations=ad};return W}function i(T){var W=[],S=[];if(T.tripleQuotedStrings){W.push([C,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""])}else{if(T.multiLineStrings){W.push([C,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"])}else{W.push([C,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"])}}if(T.verbatimStrings){S.push([C,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null])}var Y=T.hashComments;if(Y){if(T.cStyleComments){if(Y>1){W.push([j,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"])}else{W.push([j,/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"])}S.push([C,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,null])}else{W.push([j,/^#[^\r\n]*/,null,"#"])}}if(T.cStyleComments){S.push([j,/^\/\/[^\r\n]*/,null]);S.push([j,/^\/\*[\s\S]*?(?:\*\/|$)/,null])}if(T.regexLiterals){var X=("/(?=[^/*])(?:[^/\\x5B\\x5C]|\\x5C[\\s\\S]|\\x5B(?:[^\\x5C\\x5D]|\\x5C[\\s\\S])*(?:\\x5D|$))+/");S.push(["lang-regex",new RegExp("^"+M+"("+X+")")])}var V=T.types;if(V){S.push([O,V])}var U=(""+T.keywords).replace(/^ | $/g,"");if(U.length){S.push([z,new RegExp("^(?:"+U.replace(/[\s,]+/g,"|")+")\\b"),null])}W.push([F,/^\s+/,null," \r\n\t\xA0"]);S.push([G,/^@[a-z_$][a-z_$@0-9]*/i,null],[O,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[F,/^[a-z_$][a-z_$@0-9]*/i,null],[G,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[F,/^\\[\s\S]?/,null],[L,/^.[^\s\w\.$@\'\"\`\/\#\\]*/,null]);return g(W,S)}var K=i({keywords:A,hashComments:true,cStyleComments:true,multiLineStrings:true,regexLiterals:true});function Q(V,ag){var U=/(?:^|\s)nocode(?:\s|$)/;var ab=/\r\n?|\n/;var ac=V.ownerDocument;var S;if(V.currentStyle){S=V.currentStyle.whiteSpace}else{if(window.getComputedStyle){S=ac.defaultView.getComputedStyle(V,null).getPropertyValue("white-space")}}var Z=S&&"pre"===S.substring(0,3);var af=ac.createElement("LI");while(V.firstChild){af.appendChild(V.firstChild)}var W=[af];function ae(al){switch(al.nodeType){case 1:if(U.test(al.className)){break}if("BR"===al.nodeName){ad(al);if(al.parentNode){al.parentNode.removeChild(al)}}else{for(var an=al.firstChild;an;an=an.nextSibling){ae(an)}}break;case 3:case 4:if(Z){var am=al.nodeValue;var aj=am.match(ab);if(aj){var ai=am.substring(0,aj.index);al.nodeValue=ai;var ah=am.substring(aj.index+aj[0].length);if(ah){var ak=al.parentNode;ak.insertBefore(ac.createTextNode(ah),al.nextSibling)}ad(al);if(!ai){al.parentNode.removeChild(al)}}}break}}function ad(ak){while(!ak.nextSibling){ak=ak.parentNode;if(!ak){return}}function ai(al,ar){var aq=ar?al.cloneNode(false):al;var ao=al.parentNode;if(ao){var ap=ai(ao,1);var an=al.nextSibling;ap.appendChild(aq);for(var am=an;am;am=an){an=am.nextSibling;ap.appendChild(am)}}return aq}var ah=ai(ak.nextSibling,0);for(var aj;(aj=ah.parentNode)&&aj.nodeType===1;){ah=aj}W.push(ah)}for(var Y=0;Y=S){ah+=2}if(V>=ap){Z+=2}}}var t={};function c(U,V){for(var S=V.length;--S>=0;){var T=V[S];if(!t.hasOwnProperty(T)){t[T]=U}else{if(window.console){console.warn("cannot override language handler %s",T)}}}}function q(T,S){if(!(T&&t.hasOwnProperty(T))){T=/^\s*]*(?:>|$)/],[j,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[L,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);c(g([[F,/^[\s]+/,null," \t\r\n"],[n,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[[m,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[P,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[L,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]);c(g([],[[n,/^[\s\S]+/]]),["uq.val"]);c(i({keywords:l,hashComments:true,cStyleComments:true,types:e}),["c","cc","cpp","cxx","cyc","m"]);c(i({keywords:"null,true,false"}),["json"]);c(i({keywords:R,hashComments:true,cStyleComments:true,verbatimStrings:true,types:e}),["cs"]);c(i({keywords:x,cStyleComments:true}),["java"]);c(i({keywords:H,hashComments:true,multiLineStrings:true}),["bsh","csh","sh"]);c(i({keywords:I,hashComments:true,multiLineStrings:true,tripleQuotedStrings:true}),["cv","py"]);c(i({keywords:s,hashComments:true,multiLineStrings:true,regexLiterals:true}),["perl","pl","pm"]);c(i({keywords:f,hashComments:true,multiLineStrings:true,regexLiterals:true}),["rb"]);c(i({keywords:w,cStyleComments:true,regexLiterals:true}),["js"]);c(i({keywords:r,hashComments:3,cStyleComments:true,multilineStrings:true,tripleQuotedStrings:true,regexLiterals:true}),["coffee"]);c(g([],[[C,/^[\s\S]+/]]),["regex"]);function d(V){var U=V.langExtension;try{var S=a(V.sourceNode);var T=S.sourceCode;V.sourceCode=T;V.spans=S.spans;V.basePos=0;q(U,T)(V);D(V)}catch(W){if("console" in window){console.log(W&&W.stack?W.stack:W)}}}function y(W,V,U){var S=document.createElement("PRE");S.innerHTML=W;if(U){Q(S,U)}var T={langExtension:V,numberLines:U,sourceNode:S};d(T);return S.innerHTML}function b(ad){function Y(af){return document.getElementsByTagName(af)}var ac=[Y("pre"),Y("code"),Y("xmp")];var T=[];for(var aa=0;aa=0){var ah=ai.match(ab);var am;if(!ah&&(am=o(aj))&&"CODE"===am.tagName){ah=am.className.match(ab)}if(ah){ah=ah[1]}var al=false;for(var ak=aj.parentNode;ak;ak=ak.parentNode){if((ak.tagName==="pre"||ak.tagName==="code"||ak.tagName==="xmp")&&ak.className&&ak.className.indexOf("prettyprint")>=0){al=true;break}}if(!al){var af=aj.className.match(/\blinenums\b(?::(\d+))?/);af=af?af[1]&&af[1].length?+af[1]:true:false;if(af){Q(aj,af)}S={langExtension:ah,sourceNode:aj,numberLines:af};d(S)}}}if(X]*(?:>|$)/],[PR.PR_COMMENT,/^<\!--[\s\S]*?(?:-\->|$)/],[PR.PR_PUNCTUATION,/^(?:<[%?]|[%?]>)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-handlebars",/^]*type\s*=\s*['"]?text\/x-handlebars-template['"]?\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i],[PR.PR_DECLARATION,/^{{[#^>/]?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{&?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{{>?\s*[\w.][^}]*}}}/],[PR.PR_COMMENT,/^{{![^}]*}}/]]),["handlebars","hbs"]);PR.registerLangHandler(PR.createSimpleLexer([[PR.PR_PLAIN,/^[ \t\r\n\f]+/,null," \t\r\n\f"]],[[PR.PR_STRING,/^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/,null],[PR.PR_STRING,/^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/,null],["lang-css-str",/^url\(([^\)\"\']*)\)/i],[PR.PR_KEYWORD,/^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],[PR.PR_COMMENT,/^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],[PR.PR_COMMENT,/^(?:)/],[PR.PR_LITERAL,/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],[PR.PR_LITERAL,/^#(?:[0-9a-f]{3}){1,2}/i],[PR.PR_PLAIN,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],[PR.PR_PUNCTUATION,/^[^\s\w\'\"]+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_KEYWORD,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_STRING,/^[^\)\"\']+/]]),["css-str"]); diff --git a/qa/coverage/sort-arrow-sprite.png b/qa/coverage/sort-arrow-sprite.png new file mode 100644 index 0000000000000000000000000000000000000000..6ed68316eb3f65dec9063332d2f69bf3093bbfab GIT binary patch literal 138 zcmeAS@N?(olHy`uVBq!ia0vp^>_9Bd!3HEZxJ@+%Qh}Z>jv*C{$p!i!8j}?a+@3A= zIAGwzjijN=FBi!|L1t?LM;Q;gkwn>2cAy-KV{dn nf0J1DIvEHQu*n~6U}x}qyky7vi4|9XhBJ7&`njxgN@xNA8m%nc literal 0 HcmV?d00001 diff --git a/qa/coverage/sorter.js b/qa/coverage/sorter.js new file mode 100644 index 00000000..2bb296a8 --- /dev/null +++ b/qa/coverage/sorter.js @@ -0,0 +1,196 @@ +/* eslint-disable */ +var addSorting = (function() { + 'use strict'; + var cols, + currentSort = { + index: 0, + desc: false + }; + + // returns the summary table element + function getTable() { + return document.querySelector('.coverage-summary'); + } + // returns the thead element of the summary table + function getTableHeader() { + return getTable().querySelector('thead tr'); + } + // returns the tbody element of the summary table + function getTableBody() { + return getTable().querySelector('tbody'); + } + // returns the th element for nth column + function getNthColumn(n) { + return getTableHeader().querySelectorAll('th')[n]; + } + + function onFilterInput() { + const searchValue = document.getElementById('fileSearch').value; + const rows = document.getElementsByTagName('tbody')[0].children; + for (let i = 0; i < rows.length; i++) { + const row = rows[i]; + if ( + row.textContent + .toLowerCase() + .includes(searchValue.toLowerCase()) + ) { + row.style.display = ''; + } else { + row.style.display = 'none'; + } + } + } + + // loads the search box + function addSearchBox() { + var template = document.getElementById('filterTemplate'); + var templateClone = template.content.cloneNode(true); + templateClone.getElementById('fileSearch').oninput = onFilterInput; + template.parentElement.appendChild(templateClone); + } + + // loads all columns + function loadColumns() { + var colNodes = getTableHeader().querySelectorAll('th'), + colNode, + cols = [], + col, + i; + + for (i = 0; i < colNodes.length; i += 1) { + colNode = colNodes[i]; + col = { + key: colNode.getAttribute('data-col'), + sortable: !colNode.getAttribute('data-nosort'), + type: colNode.getAttribute('data-type') || 'string' + }; + cols.push(col); + if (col.sortable) { + col.defaultDescSort = col.type === 'number'; + colNode.innerHTML = + colNode.innerHTML + ''; + } + } + return cols; + } + // attaches a data attribute to every tr element with an object + // of data values keyed by column name + function loadRowData(tableRow) { + var tableCols = tableRow.querySelectorAll('td'), + colNode, + col, + data = {}, + i, + val; + for (i = 0; i < tableCols.length; i += 1) { + colNode = tableCols[i]; + col = cols[i]; + val = colNode.getAttribute('data-value'); + if (col.type === 'number') { + val = Number(val); + } + data[col.key] = val; + } + return data; + } + // loads all row data + function loadData() { + var rows = getTableBody().querySelectorAll('tr'), + i; + + for (i = 0; i < rows.length; i += 1) { + rows[i].data = loadRowData(rows[i]); + } + } + // sorts the table using the data for the ith column + function sortByIndex(index, desc) { + var key = cols[index].key, + sorter = function(a, b) { + a = a.data[key]; + b = b.data[key]; + return a < b ? -1 : a > b ? 1 : 0; + }, + finalSorter = sorter, + tableBody = document.querySelector('.coverage-summary tbody'), + rowNodes = tableBody.querySelectorAll('tr'), + rows = [], + i; + + if (desc) { + finalSorter = function(a, b) { + return -1 * sorter(a, b); + }; + } + + for (i = 0; i < rowNodes.length; i += 1) { + rows.push(rowNodes[i]); + tableBody.removeChild(rowNodes[i]); + } + + rows.sort(finalSorter); + + for (i = 0; i < rows.length; i += 1) { + tableBody.appendChild(rows[i]); + } + } + // removes sort indicators for current column being sorted + function removeSortIndicators() { + var col = getNthColumn(currentSort.index), + cls = col.className; + + cls = cls.replace(/ sorted$/, '').replace(/ sorted-desc$/, ''); + col.className = cls; + } + // adds sort indicators for current column being sorted + function addSortIndicators() { + getNthColumn(currentSort.index).className += currentSort.desc + ? ' sorted-desc' + : ' sorted'; + } + // adds event listeners for all sorter widgets + function enableUI() { + var i, + el, + ithSorter = function ithSorter(i) { + var col = cols[i]; + + return function() { + var desc = col.defaultDescSort; + + if (currentSort.index === i) { + desc = !currentSort.desc; + } + sortByIndex(i, desc); + removeSortIndicators(); + currentSort.index = i; + currentSort.desc = desc; + addSortIndicators(); + }; + }; + for (i = 0; i < cols.length; i += 1) { + if (cols[i].sortable) { + // add the click event handler on the th so users + // dont have to click on those tiny arrows + el = getNthColumn(i).querySelector('.sorter').parentElement; + if (el.addEventListener) { + el.addEventListener('click', ithSorter(i)); + } else { + el.attachEvent('onclick', ithSorter(i)); + } + } + } + } + // adds sorting functionality to the UI + return function() { + if (!getTable()) { + return; + } + cols = loadColumns(); + loadData(); + addSearchBox(); + addSortIndicators(); + enableUI(); + }; +})(); + +window.addEventListener('load', addSorting); diff --git a/qa/lint.txt b/qa/lint.txt new file mode 100644 index 00000000..917ce637 --- /dev/null +++ b/qa/lint.txt @@ -0,0 +1 @@ +Test git rev: 4266ec27590971750fc7c20d640f8903c3863485 diff --git a/qa/unit-test.txt b/qa/unit-test.txt new file mode 100644 index 00000000..7b7538f0 --- /dev/null +++ b/qa/unit-test.txt @@ -0,0 +1,84 @@ +Test git rev: 4266ec27590971750fc7c20d640f8903c3863485 +PASS cli/lib/configuration/test/handle-configuration-show.test.js +PASS cli/lib/configuration/test/handle-configuration-initialize.test.js +--------------------------------------|---------|----------|---------|---------|------------------- +File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s +--------------------------------------|---------|----------|---------|---------|------------------- +All files | 1.3 | 0.16 | 2.38 | 1.33 | + cli | 0 | 0 | 0 | 0 | + cloudsite.mjs | 0 | 0 | 0 | 0 | 1-150 + constants.mjs | 0 | 0 | 0 | 0 | 1-45 + cli/lib | 0 | 0 | 0 | 0 | + check-authentication.mjs | 0 | 100 | 0 | 0 | 1-11 + check-format.mjs | 0 | 0 | 0 | 0 | 1-7 + check-reminders.mjs | 0 | 0 | 0 | 0 | 1-21 + get-global-options.mjs | 0 | 0 | 0 | 0 | 1-32 + get-options-spec.mjs | 0 | 0 | 0 | 0 | 1-13 + get-site-info.mjs | 0 | 0 | 0 | 0 | 1-12 + get-value-container-and-key.mjs | 0 | 0 | 0 | 0 | 1-46 + handle-cleanup.mjs | 0 | 0 | 0 | 0 | 1-48 + handle-configuration.mjs | 0 | 0 | 0 | 0 | 1-22 + handle-create.mjs | 0 | 0 | 0 | 0 | 1-128 + handle-destroy.mjs | 0 | 0 | 0 | 0 | 1-55 + handle-detail.mjs | 0 | 0 | 0 | 0 | 1-23 + handle-get-iam-policy.mjs | 0 | 0 | 0 | 0 | 1-252 + handle-import.mjs | 0 | 0 | 0 | 0 | 1-65 + handle-list.mjs | 0 | 0 | 0 | 0 | 1-22 + handle-plugin-settings.mjs | 0 | 0 | 0 | 0 | 1-22 + handle-update.mjs | 0 | 100 | 0 | 0 | 1-24 + handle-verify.mjs | 0 | 0 | 0 | 0 | 1-31 + options.mjs | 0 | 0 | 0 | 0 | 1-67 + process-source-type.mjs | 0 | 0 | 0 | 0 | 1-15 + smart-convert.mjs | 0 | 0 | 0 | 0 | 1-20 + cli/lib/configuration | 100 | 50 | 100 | 100 | + handle-configuration-initialize.mjs | 100 | 100 | 100 | 100 | + handle-configuration-show.mjs | 100 | 50 | 100 | 100 | 16 + cli/lib/plugin-settings | 0 | 0 | 0 | 0 | + handle-plugin-settings-set.mjs | 0 | 0 | 0 | 0 | 1-45 + handle-plugin-settings-show.mjs | 0 | 0 | 0 | 0 | 1-18 + lib/actions | 0 | 0 | 0 | 0 | + create.mjs | 0 | 0 | 0 | 0 | 1-151 + destroy.mjs | 0 | 0 | 0 | 0 | 1-61 + import.mjs | 0 | 0 | 0 | 0 | 1-71 + update.mjs | 0 | 0 | 0 | 0 | 1-89 + verify.mjs | 0 | 0 | 0 | 0 | 1-179 + lib/actions/lib | 0 | 0 | 0 | 0 | + add-tags-to-hosted-zone.mjs | 0 | 100 | 0 | 0 | 1-18 + associate-cost-allocation-tags.mjs | 0 | 100 | 0 | 0 | 1-17 + create-or-update-dns-records.mjs | 0 | 100 | 0 | 0 | 1-41 + find-certificate.mjs | 0 | 0 | 0 | 0 | 1-27 + get-credentials.mjs | 0 | 0 | 0 | 0 | 1-9 + get-hosted-zone-id.mjs | 0 | 0 | 0 | 0 | 1-19 + sync-site-content.mjs | 0 | 0 | 0 | 0 | 1-34 + track-stack-status.mjs | 0 | 0 | 0 | 0 | 1-41 + update-plugins.mjs | 0 | 0 | 0 | 0 | 1-18 + update-site-info.mjs | 0 | 100 | 0 | 0 | 1-15 + update-stack.mjs | 0 | 0 | 0 | 0 | 1-64 + lib/plugins | 0 | 0 | 0 | 0 | + access-logs.mjs | 0 | 100 | 0 | 0 | 1-11 + cloudfront-logs.mjs | 0 | 0 | 0 | 0 | 1-40 + lib/plugins/contact-handler/lib | 0 | 0 | 0 | 0 | + constants.mjs | 0 | 100 | 100 | 0 | 1-5 + determine-lambda-function-name.mjs | 0 | 0 | 0 | 0 | 1-32 + setup-contact-emailer.mjs | 0 | 0 | 0 | 0 | 1-151 + setup-contact-form-table.mjs | 0 | 100 | 0 | 0 | 1-29 + setup-contact-handler.mjs | 0 | 0 | 0 | 0 | 1-174 + setup-request-signer.mjs | 0 | 0 | 0 | 0 | 1-104 + stage-lambda-function-zip-files.mjs | 0 | 0 | 0 | 0 | 1-89 + update-cloud-front-distribution.mjs | 0 | 0 | 0 | 0 | 1-43 + lib/shared | 3.57 | 0 | 5 | 3.68 | + convert-domain-to-bucket-name.js | 0 | 100 | 0 | 0 | 1 + determine-bucket-name.mjs | 0 | 0 | 0 | 0 | 1-50 + determine-oac-name.mjs | 0 | 0 | 0 | 0 | 1-45 + find-bucket-like.mjs | 0 | 0 | 0 | 0 | 1-25 + get-account-id.mjs | 0 | 0 | 0 | 0 | 1-11 + get-site-tag.mjs | 0 | 100 | 0 | 0 | 1-3 + progress-logger.mjs | 66.66 | 0 | 50 | 66.66 | 10-13 + site-template.mjs | 0 | 0 | 0 | 0 | 1-267 +--------------------------------------|---------|----------|---------|---------|------------------- + +Test Suites: 2 passed, 2 total +Tests: 3 passed, 3 total +Snapshots: 0 total +Time: 1.426 s +Ran all test suites. From a750b8bfa81dbb077774026d333f9d7a1e8faf10 Mon Sep 17 00:00:00 2001 From: Zane Rockenbaugh Date: Sat, 30 Mar 2024 11:08:50 -0500 Subject: [PATCH 5/5] removed QA files --- qa/coverage/base.css | 224 --- qa/coverage/block-navigation.js | 87 - qa/coverage/cli/cloudsite.mjs.html | 547 ------ qa/coverage/cli/constants.mjs.html | 1129 ------------ qa/coverage/cli/index.html | 131 -- .../cli/lib/check-authentication.mjs.html | 124 -- qa/coverage/cli/lib/check-format.mjs.html | 112 -- qa/coverage/cli/lib/check-reminders.mjs.html | 154 -- .../handle-configuration-initialize.mjs.html | 193 -- .../handle-configuration-show.mjs.html | 145 -- qa/coverage/cli/lib/configuration/index.html | 131 -- .../cli/lib/get-global-options.mjs.html | 187 -- qa/coverage/cli/lib/get-options-spec.mjs.html | 130 -- qa/coverage/cli/lib/get-site-info.mjs.html | 127 -- .../lib/get-value-container-and-key.mjs.html | 229 --- qa/coverage/cli/lib/handle-cleanup.mjs.html | 235 --- .../cli/lib/handle-configuration.mjs.html | 157 -- qa/coverage/cli/lib/handle-create.mjs.html | 475 ----- qa/coverage/cli/lib/handle-destroy.mjs.html | 256 --- qa/coverage/cli/lib/handle-detail.mjs.html | 160 -- .../cli/lib/handle-get-iam-policy.mjs.html | 847 --------- qa/coverage/cli/lib/handle-import.mjs.html | 286 --- qa/coverage/cli/lib/handle-list.mjs.html | 157 -- .../cli/lib/handle-plugin-settings.mjs.html | 157 -- qa/coverage/cli/lib/handle-update.mjs.html | 163 -- qa/coverage/cli/lib/handle-verify.mjs.html | 184 -- qa/coverage/cli/lib/index.html | 416 ----- qa/coverage/cli/lib/options.mjs.html | 292 --- .../handle-plugin-settings-set.mjs.html | 226 --- .../handle-plugin-settings-show.mjs.html | 145 -- .../cli/lib/plugin-settings/index.html | 131 -- .../cli/lib/process-source-type.mjs.html | 136 -- qa/coverage/cli/lib/smart-convert.mjs.html | 151 -- qa/coverage/clover.xml | 1635 ----------------- qa/coverage/coverage-final.json | 62 - qa/coverage/favicon.png | Bin 445 -> 0 bytes qa/coverage/index.html | 236 --- qa/coverage/lib/actions/create.mjs.html | 547 ------ qa/coverage/lib/actions/destroy.mjs.html | 274 --- qa/coverage/lib/actions/import.mjs.html | 304 --- qa/coverage/lib/actions/index.html | 176 -- .../lib/add-tags-to-hosted-zone.mjs.html | 145 -- .../associate-cost-allocation-tags.mjs.html | 142 -- .../lib/create-or-update-dns-records.mjs.html | 214 --- .../lib/actions/lib/find-certificate.mjs.html | 172 -- .../lib/actions/lib/get-credentials.mjs.html | 118 -- .../actions/lib/get-hosted-zone-id.mjs.html | 148 -- qa/coverage/lib/actions/lib/index.html | 266 --- .../actions/lib/sync-site-content.mjs.html | 193 -- .../actions/lib/track-stack-status.mjs.html | 214 --- .../lib/actions/lib/update-plugins.mjs.html | 145 -- .../lib/actions/lib/update-site-info.mjs.html | 136 -- .../lib/actions/lib/update-stack.mjs.html | 283 --- qa/coverage/lib/actions/update.mjs.html | 361 ---- qa/coverage/lib/actions/verify.mjs.html | 631 ------- qa/coverage/lib/plugins/access-logs.mjs.html | 124 -- .../lib/plugins/cloudfront-logs.mjs.html | 211 --- .../contact-handler/lib/constants.mjs.html | 175 -- .../determine-lambda-function-name.mjs.html | 187 -- .../plugins/contact-handler/lib/index.html | 221 --- .../lib/setup-contact-emailer.mjs.html | 544 ------ .../lib/setup-contact-form-table.mjs.html | 178 -- .../lib/setup-contact-handler.mjs.html | 613 ------ .../lib/setup-request-signer.mjs.html | 403 ---- .../stage-lambda-function-zip-files.mjs.html | 361 ---- .../update-cloud-front-distribution.mjs.html | 220 --- qa/coverage/lib/plugins/index.html | 131 -- .../convert-domain-to-bucket-name.js.html | 94 - .../lib/shared/determine-bucket-name.mjs.html | 241 --- .../lib/shared/determine-oac-name.mjs.html | 235 --- .../lib/shared/find-bucket-like.mjs.html | 166 -- .../lib/shared/get-account-id.mjs.html | 124 -- qa/coverage/lib/shared/get-site-tag.mjs.html | 100 - qa/coverage/lib/shared/index.html | 221 --- .../lib/shared/progress-logger.mjs.html | 139 -- qa/coverage/lib/shared/site-template.mjs.html | 892 --------- qa/coverage/prettify.css | 1 - qa/coverage/prettify.js | 2 - qa/coverage/sort-arrow-sprite.png | Bin 138 -> 0 bytes qa/coverage/sorter.js | 196 -- qa/lint.txt | 1 - qa/unit-test.txt | 84 - 82 files changed, 20490 deletions(-) delete mode 100644 qa/coverage/base.css delete mode 100644 qa/coverage/block-navigation.js delete mode 100644 qa/coverage/cli/cloudsite.mjs.html delete mode 100644 qa/coverage/cli/constants.mjs.html delete mode 100644 qa/coverage/cli/index.html delete mode 100644 qa/coverage/cli/lib/check-authentication.mjs.html delete mode 100644 qa/coverage/cli/lib/check-format.mjs.html delete mode 100644 qa/coverage/cli/lib/check-reminders.mjs.html delete mode 100644 qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html delete mode 100644 qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html delete mode 100644 qa/coverage/cli/lib/configuration/index.html delete mode 100644 qa/coverage/cli/lib/get-global-options.mjs.html delete mode 100644 qa/coverage/cli/lib/get-options-spec.mjs.html delete mode 100644 qa/coverage/cli/lib/get-site-info.mjs.html delete mode 100644 qa/coverage/cli/lib/get-value-container-and-key.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-cleanup.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-configuration.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-create.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-destroy.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-detail.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-get-iam-policy.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-import.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-list.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-plugin-settings.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-update.mjs.html delete mode 100644 qa/coverage/cli/lib/handle-verify.mjs.html delete mode 100644 qa/coverage/cli/lib/index.html delete mode 100644 qa/coverage/cli/lib/options.mjs.html delete mode 100644 qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html delete mode 100644 qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html delete mode 100644 qa/coverage/cli/lib/plugin-settings/index.html delete mode 100644 qa/coverage/cli/lib/process-source-type.mjs.html delete mode 100644 qa/coverage/cli/lib/smart-convert.mjs.html delete mode 100644 qa/coverage/clover.xml delete mode 100644 qa/coverage/coverage-final.json delete mode 100644 qa/coverage/favicon.png delete mode 100644 qa/coverage/index.html delete mode 100644 qa/coverage/lib/actions/create.mjs.html delete mode 100644 qa/coverage/lib/actions/destroy.mjs.html delete mode 100644 qa/coverage/lib/actions/import.mjs.html delete mode 100644 qa/coverage/lib/actions/index.html delete mode 100644 qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/find-certificate.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/get-credentials.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/index.html delete mode 100644 qa/coverage/lib/actions/lib/sync-site-content.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/track-stack-status.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/update-plugins.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/update-site-info.mjs.html delete mode 100644 qa/coverage/lib/actions/lib/update-stack.mjs.html delete mode 100644 qa/coverage/lib/actions/update.mjs.html delete mode 100644 qa/coverage/lib/actions/verify.mjs.html delete mode 100644 qa/coverage/lib/plugins/access-logs.mjs.html delete mode 100644 qa/coverage/lib/plugins/cloudfront-logs.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/index.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html delete mode 100644 qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html delete mode 100644 qa/coverage/lib/plugins/index.html delete mode 100644 qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html delete mode 100644 qa/coverage/lib/shared/determine-bucket-name.mjs.html delete mode 100644 qa/coverage/lib/shared/determine-oac-name.mjs.html delete mode 100644 qa/coverage/lib/shared/find-bucket-like.mjs.html delete mode 100644 qa/coverage/lib/shared/get-account-id.mjs.html delete mode 100644 qa/coverage/lib/shared/get-site-tag.mjs.html delete mode 100644 qa/coverage/lib/shared/index.html delete mode 100644 qa/coverage/lib/shared/progress-logger.mjs.html delete mode 100644 qa/coverage/lib/shared/site-template.mjs.html delete mode 100644 qa/coverage/prettify.css delete mode 100644 qa/coverage/prettify.js delete mode 100644 qa/coverage/sort-arrow-sprite.png delete mode 100644 qa/coverage/sorter.js delete mode 100644 qa/lint.txt delete mode 100644 qa/unit-test.txt diff --git a/qa/coverage/base.css b/qa/coverage/base.css deleted file mode 100644 index f418035b..00000000 --- a/qa/coverage/base.css +++ /dev/null @@ -1,224 +0,0 @@ -body, html { - margin:0; padding: 0; - height: 100%; -} -body { - font-family: Helvetica Neue, Helvetica, Arial; - font-size: 14px; - color:#333; -} -.small { font-size: 12px; } -*, *:after, *:before { - -webkit-box-sizing:border-box; - -moz-box-sizing:border-box; - box-sizing:border-box; - } -h1 { font-size: 20px; margin: 0;} -h2 { font-size: 14px; } -pre { - font: 12px/1.4 Consolas, "Liberation Mono", Menlo, Courier, monospace; - margin: 0; - padding: 0; - -moz-tab-size: 2; - -o-tab-size: 2; - tab-size: 2; -} -a { color:#0074D9; text-decoration:none; } -a:hover { text-decoration:underline; } -.strong { font-weight: bold; } -.space-top1 { padding: 10px 0 0 0; } -.pad2y { padding: 20px 0; } -.pad1y { padding: 10px 0; } -.pad2x { padding: 0 20px; } -.pad2 { padding: 20px; } -.pad1 { padding: 10px; } -.space-left2 { padding-left:55px; } -.space-right2 { padding-right:20px; } -.center { text-align:center; } -.clearfix { display:block; } -.clearfix:after { - content:''; - display:block; - height:0; - clear:both; - visibility:hidden; - } -.fl { float: left; } -@media only screen and (max-width:640px) { - .col3 { width:100%; max-width:100%; } - .hide-mobile { display:none!important; } -} - -.quiet { - color: #7f7f7f; - color: rgba(0,0,0,0.5); -} -.quiet a { opacity: 0.7; } - -.fraction { - font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; - font-size: 10px; - color: #555; - background: #E8E8E8; - padding: 4px 5px; - border-radius: 3px; - vertical-align: middle; -} - -div.path a:link, div.path a:visited { color: #333; } -table.coverage { - border-collapse: collapse; - margin: 10px 0 0 0; - padding: 0; -} - -table.coverage td { - margin: 0; - padding: 0; - vertical-align: top; -} -table.coverage td.line-count { - text-align: right; - padding: 0 5px 0 20px; -} -table.coverage td.line-coverage { - text-align: right; - padding-right: 10px; - min-width:20px; -} - -table.coverage td span.cline-any { - display: inline-block; - padding: 0 5px; - width: 100%; -} -.missing-if-branch { - display: inline-block; - margin-right: 5px; - border-radius: 3px; - position: relative; - padding: 0 4px; - background: #333; - color: yellow; -} - -.skip-if-branch { - display: none; - margin-right: 10px; - position: relative; - padding: 0 4px; - background: #ccc; - color: white; -} -.missing-if-branch .typ, .skip-if-branch .typ { - color: inherit !important; -} -.coverage-summary { - border-collapse: collapse; - width: 100%; -} -.coverage-summary tr { border-bottom: 1px solid #bbb; } -.keyline-all { border: 1px solid #ddd; } -.coverage-summary td, .coverage-summary th { padding: 10px; } -.coverage-summary tbody { border: 1px solid #bbb; } -.coverage-summary td { border-right: 1px solid #bbb; } -.coverage-summary td:last-child { border-right: none; } -.coverage-summary th { - text-align: left; - font-weight: normal; - white-space: nowrap; -} -.coverage-summary th.file { border-right: none !important; } -.coverage-summary th.pct { } -.coverage-summary th.pic, -.coverage-summary th.abs, -.coverage-summary td.pct, -.coverage-summary td.abs { text-align: right; } -.coverage-summary td.file { white-space: nowrap; } -.coverage-summary td.pic { min-width: 120px !important; } -.coverage-summary tfoot td { } - -.coverage-summary .sorter { - height: 10px; - width: 7px; - display: inline-block; - margin-left: 0.5em; - background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent; -} -.coverage-summary .sorted .sorter { - background-position: 0 -20px; -} -.coverage-summary .sorted-desc .sorter { - background-position: 0 -10px; -} -.status-line { height: 10px; } -/* yellow */ -.cbranch-no { background: yellow !important; color: #111; } -/* dark red */ -.red.solid, .status-line.low, .low .cover-fill { background:#C21F39 } -.low .chart { border:1px solid #C21F39 } -.highlighted, -.highlighted .cstat-no, .highlighted .fstat-no, .highlighted .cbranch-no{ - background: #C21F39 !important; -} -/* medium red */ -.cstat-no, .fstat-no, .cbranch-no, .cbranch-no { background:#F6C6CE } -/* light red */ -.low, .cline-no { background:#FCE1E5 } -/* light green */ -.high, .cline-yes { background:rgb(230,245,208) } -/* medium green */ -.cstat-yes { background:rgb(161,215,106) } -/* dark green */ -.status-line.high, .high .cover-fill { background:rgb(77,146,33) } -.high .chart { border:1px solid rgb(77,146,33) } -/* dark yellow (gold) */ -.status-line.medium, .medium .cover-fill { background: #f9cd0b; } -.medium .chart { border:1px solid #f9cd0b; } -/* light yellow */ -.medium { background: #fff4c2; } - -.cstat-skip { background: #ddd; color: #111; } -.fstat-skip { background: #ddd; color: #111 !important; } -.cbranch-skip { background: #ddd !important; color: #111; } - -span.cline-neutral { background: #eaeaea; } - -.coverage-summary td.empty { - opacity: .5; - padding-top: 4px; - padding-bottom: 4px; - line-height: 1; - color: #888; -} - -.cover-fill, .cover-empty { - display:inline-block; - height: 12px; -} -.chart { - line-height: 0; -} -.cover-empty { - background: white; -} -.cover-full { - border-right: none !important; -} -pre.prettyprint { - border: none !important; - padding: 0 !important; - margin: 0 !important; -} -.com { color: #999 !important; } -.ignore-none { color: #999; font-weight: normal; } - -.wrapper { - min-height: 100%; - height: auto !important; - height: 100%; - margin: 0 auto -48px; -} -.footer, .push { - height: 48px; -} diff --git a/qa/coverage/block-navigation.js b/qa/coverage/block-navigation.js deleted file mode 100644 index cc121302..00000000 --- a/qa/coverage/block-navigation.js +++ /dev/null @@ -1,87 +0,0 @@ -/* eslint-disable */ -var jumpToCode = (function init() { - // Classes of code we would like to highlight in the file view - var missingCoverageClasses = ['.cbranch-no', '.cstat-no', '.fstat-no']; - - // Elements to highlight in the file listing view - var fileListingElements = ['td.pct.low']; - - // We don't want to select elements that are direct descendants of another match - var notSelector = ':not(' + missingCoverageClasses.join('):not(') + ') > '; // becomes `:not(a):not(b) > ` - - // Selecter that finds elements on the page to which we can jump - var selector = - fileListingElements.join(', ') + - ', ' + - notSelector + - missingCoverageClasses.join(', ' + notSelector); // becomes `:not(a):not(b) > a, :not(a):not(b) > b` - - // The NodeList of matching elements - var missingCoverageElements = document.querySelectorAll(selector); - - var currentIndex; - - function toggleClass(index) { - missingCoverageElements - .item(currentIndex) - .classList.remove('highlighted'); - missingCoverageElements.item(index).classList.add('highlighted'); - } - - function makeCurrent(index) { - toggleClass(index); - currentIndex = index; - missingCoverageElements.item(index).scrollIntoView({ - behavior: 'smooth', - block: 'center', - inline: 'center' - }); - } - - function goToPrevious() { - var nextIndex = 0; - if (typeof currentIndex !== 'number' || currentIndex === 0) { - nextIndex = missingCoverageElements.length - 1; - } else if (missingCoverageElements.length > 1) { - nextIndex = currentIndex - 1; - } - - makeCurrent(nextIndex); - } - - function goToNext() { - var nextIndex = 0; - - if ( - typeof currentIndex === 'number' && - currentIndex < missingCoverageElements.length - 1 - ) { - nextIndex = currentIndex + 1; - } - - makeCurrent(nextIndex); - } - - return function jump(event) { - if ( - document.getElementById('fileSearch') === document.activeElement && - document.activeElement != null - ) { - // if we're currently focused on the search input, we don't want to navigate - return; - } - - switch (event.which) { - case 78: // n - case 74: // j - goToNext(); - break; - case 66: // b - case 75: // k - case 80: // p - goToPrevious(); - break; - } - }; -})(); -window.addEventListener('keydown', jumpToCode); diff --git a/qa/coverage/cli/cloudsite.mjs.html b/qa/coverage/cli/cloudsite.mjs.html deleted file mode 100644 index 26a6f527..00000000 --- a/qa/coverage/cli/cloudsite.mjs.html +++ /dev/null @@ -1,547 +0,0 @@ - - - - - - Code coverage report for cli/cloudsite.mjs - - - - - - - - - -
-
-

All files / cli cloudsite.mjs

-
- -
- 0% - Statements - 0/102 -
- - -
- 0% - Branches - 0/47 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/91 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import * as fs from 'node:fs/promises'
- 
-import commandLineArgs from 'command-line-args'
-import { commandLineDocumentation } from 'command-line-documentation'
-import isEqual from 'lodash/isEqual'
- 
-import { cliSpec, DB_PATH } from './constants'
-import { checkReminders } from './lib/check-reminders'
-import { configureLogger, progressLogger } from '../lib/shared/progress-logger'
-import { getGlobalOptions } from './lib/get-global-options'
-import { handleCleanup } from './lib/handle-cleanup'
-import { handleConfiguration } from './lib/handle-configuration'
-import { handleCreate } from './lib/handle-create'
-import { handleDestroy } from './lib/handle-destroy'
-import { handleDetail } from './lib/handle-detail'
-import { handleGetIAMPolicy } from './lib/handle-get-iam-policy'
-import { handleList } from './lib/handle-list'
-import { handleImport } from './lib/handle-import'
-import { handlePluginSettings } from './lib/handle-plugin-settings'
-import { handleUpdate } from './lib/handle-update'
-import { handleVerify } from './lib/handle-verify'I
- 
-const cloudsite = async () => {
-  // we can 'stopAtFirstUnknown' because the globals are defined at the root level
-  const mainOptions = commandLineArgs(cliSpec.mainOptions, { stopAtFirstUnknown : true })
-  const argv = mainOptions._unknown || []
- 
-  const { command/*, quiet */ } = mainOptions
-  const noReminders = mainOptions['no-reminders']
- 
-  let db
-  try {
-    const dbContents = await fs.readFile(DB_PATH, { encoding : 'utf8' })
-    db = JSON.parse(dbContents)
-  } catch (e) {
-    Iif (e.code !== 'ENOENT') {
-      throw e
-    }
-    // otherwise, it's fine, there just are no options
-    db = { account : { settings : {} }, sites : {}, toCleanup : {}, reminders : [] }
-  }
- 
-  const globalOptions = getGlobalOptions({ db })
-  const { format } = globalOptions
-  const ssoProfile = globalOptions['sso-profile']
-  const throwError = globalOptions['throw-error']
- 
-  configureLogger(globalOptions)
- 
-  Iif (noReminders !== true) {
-    checkReminders({ reminders : db.reminders })
-  }
- 
-  const origDB = structuredClone(db)
- 
-  let data
-  let exitCode = 0
-  let userMessage
-  let success
-  try {
-    switch (command) {
-      case 'cleanup':
-        ({ success, userMessage } = await handleCleanup({ argv, db })); break
-      case 'configuration':
-        ({ data, success, userMessage } = await handleConfiguration({ argv, db })); break
-      case 'create':
-        ({ success, userMessage } = await handleCreate({ argv, db })); break
-      case 'destroy':
-        ({ success, userMessage } = await handleDestroy({ argv, db })); break
-      case 'detail':
-        ({ data, success } = await handleDetail({ argv, db })); break
-      case 'document':
-        console.log(commandLineDocumentation(cliSpec, { sectionDepth : 2, title : 'Command reference' }))
-        success = true
-        userMessage = 'Documentation generated.'
-        break
-      case 'get-iam-policy':
-        await handleGetIAMPolicy({ argv, db })
-        return // get-iam-policy is handles it's own output as the IAM policy is always in JSON format
-      case 'list':
-        ({ data, success } = await handleList({ argv, db })); break
-      case 'import':
-        ({ success, userMessage } = await handleImport({ argv, db })); break
-      case 'plugin-settings':
-        ({ data, success, userMessage } = await handlePluginSettings({ argv, db })); break
-      case 'update':
-        ({ success, userMessage } = await handleUpdate({ argv, db })); break
-      case 'verify':
-        ({ data } = await handleVerify({ argv, db })); break
-      default:
-        process.stderr.write('Uknown command: ' + command + '\n\n')
-        exitCode = 10
-      // TODO: handleHelp() (abstriact from cloudcraft)
-    }
-  } catch (e) {
-    if (throwError === true) {
-      throw e
-    } else if (e.name === 'CredentialsProviderError') {
-      userMessage = 'Your AWS login credentials may have expired. Update your credentials or try refreshing with:\n\naws sso login'
-      Iif (ssoProfile !== undefined) {
-        userMessage += ' --profile ' + ssoProfile
-      }
-      exitCode = 2
-    } else {
-      userMessage = e.message
-      exitCode = e.exitCode || 11
-    }
-  } finally {
-    await checkAndUpdateSitesInfo({ origDB, db })
-  }
- 
-  globalOptions.quiet = false // always send the final status message
- 
-  const actionStatus = {
-    success : exitCode === 0 && success === true,
-    status  : exitCode !== 0 ? 'ERROR' : (success === true ? 'SUCCESS' : 'FAILURE'),
-    userMessage
-  }
- 
-  Iif (data !== undefined) {
-    actionStatus.data = data
-  }
- 
-  // is it a data format
-  if (format === 'json' || format === 'yaml') {
-    progressLogger.write(actionStatus, '')
-  } else { // then it's a 'human' format
-    Iif (data !== undefined) {
-      progressLogger.write(data, '')
-    }
- 
-    Iif (userMessage !== undefined) {
-      const { status, userMessage } = actionStatus
-      let message = userMessage
-      if (status === 'ERROR') {
-        message = '<error>!! ERROR !!<rst>: ' + message
-      } else Iif (status === 'FAILURE') {
-        message = '<warn>Command FAILED: <rst>' + message
-      }
-      progressLogger.write(message + '\n')
-    }
-  }
- 
-  process.exit(exitCode) // eslint-disable-line no-process-exit
-}
- 
-const checkAndUpdateSitesInfo = async ({ origDB, db }) => {
-  Iif (!isEqual(origDB, db)) {
-    const dbContents = JSON.stringify(db, null, '  ')
-    await fs.writeFile(DB_PATH, dbContents, { encoding : 'utf8' })
-  }
-}
- 
-export { cloudsite }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/constants.mjs.html b/qa/coverage/cli/constants.mjs.html deleted file mode 100644 index f7b3172d..00000000 --- a/qa/coverage/cli/constants.mjs.html +++ /dev/null @@ -1,1129 +0,0 @@ - - - - - - Code coverage report for cli/constants.mjs - - - - - - - - - -
-
-

All files / cli constants.mjs

-
- -
- 0% - Statements - 0/9 -
- - -
- 0% - Branches - 0/6 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/8 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183 -184 -185 -186 -187 -188 -189 -190 -191 -192 -193 -194 -195 -196 -197 -198 -199 -200 -201 -202 -203 -204 -205 -206 -207 -208 -209 -210 -211 -212 -213 -214 -215 -216 -217 -218 -219 -220 -221 -222 -223 -224 -225 -226 -227 -228 -229 -230 -231 -232 -233 -234 -235 -236 -237 -238 -239 -240 -241 -242 -243 -244 -245 -246 -247 -248 -249 -250 -251 -252 -253 -254 -255 -256 -257 -258 -259 -260 -261 -262 -263 -264 -265 -266 -267 -268 -269 -270 -271 -272 -273 -274 -275 -276 -277 -278 -279 -280 -281 -282 -283 -284 -285 -286 -287 -288 -289 -290 -291 -292 -293 -294 -295 -296 -297 -298 -299 -300 -301 -302 -303 -304 -305 -306 -307 -308 -309 -310 -311 -312 -313 -314 -315 -316 -317 -318 -319 -320 -321 -322 -323 -324 -325 -326 -327 -328 -329 -330 -331 -332 -333 -334 -335 -336 -337 -338 -339 -340 -341 -342 -343 -344 -345 -346 -347 -348 -349  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import * as fsPath from 'node:path'I
- 
-const SOURCE_TYPES = ['docusaurus', 'vanilla']
- 
-const VALID_FORMATS = ['json', 'terminal', 'text', 'yaml']
- 
-const DB_PATH = fsPath.join(process.env.HOME, '.config', 'cloudsite', 'cloudsite-db.json')
- 
-const globalOptionsSpec = [
-  {
-    name        : 'format',
-    description : "Sets the format for the output. May be 'terminal' (default), 'text', 'json', or 'yaml'."
-  },
-  {
-    name        : 'no-reminders',
-    alias       : 'R',
-    type        : Boolean,
-    description : 'Suppresses any reminders. Particularly useful for programmatic usage where the extra output might break things.'
-  },
-  { name : 'quiet', alias : 'q', type : Boolean, description : 'Makes informational output less chatty.' },
-  { name : 'sso-profile', description : 'The AWS local SSO profile to use for authentication.' },
-  {
-    name        : 'throw-error',
-    type        : Boolean,
-    description : 'In the case of an exception, the default is to print the message. When --throw-error is set, the exception is left uncaught.'
-  },
-  {
-    name        : 'verbose',
-    type        : Boolean,
-    description : 'Activates verbose (non-quiet mode) even in situations where quiet would normally be implied.'
-  }
-]
- 
-const optionSpec = {
-  name        : 'option',
-  description : "A combined name-value pair: <name>:<value>. Can be used multiple times. With '--delete', the value portion is ignored and can be omitted, e.g.: '--option <name>'.",
-  multiple    : true
-}
- 
-const sourceTypeArgSpec = {
-  name        : 'source-type',
-  description : "May be either 'vanilla' or 'docusaurus', otherwise process will attempt to guess."
-}
- 
-const cliSpec = {
-  mainCommand : 'cloudsite',
-  mainOptions : [
-    { name : 'command', defaultOption : true, description : 'The command to run or a sub-command group.' },
-    ...globalOptionsSpec
-  ],
-  commands : [
-    {
-      name        : 'cleanup',
-      description : "Attempts to fully delete partially deleted sites in the 'needs to be cleaned up' state.",
-      arguments   : [
-        {
-          name          : 'apex-domain',
-          defaultOption : true,
-          description   : 'Specifies the site to clean up rather than trying to cleanup all pending sites.'
-        },
-        {
-          name        : 'list',
-          description : 'Lists the sites in need of cleaning up.',
-          type        : Boolean
-        }
-      ]
-    },
-    {
-      name        : 'configuration',
-      description : 'Command group for managing the Cloudsite CLI configuration.',
-      arguments   : [
-        {
-          name          : 'subcommand',
-          defaultOption : true,
-          required      : true,
-          description   : 'The configuration action to perform.'
-        }
-      ],
-      commands : [
-        {
-          name        : 'initialize',
-          description : 'Runs the initialization wizard and updates all options.'
-        },
-        {
-          name        : 'show',
-          description : 'Displays the current configuration.'
-        }
-      ]
-    },
-    {
-      name        : 'create',
-      description : 'Creates a new website, setting up infrastructure and copying content.',
-      arguments   : [
-        {
-          name          : 'apex-domain',
-          description   : 'The site apex domain.',
-          defaultOption : true
-        },
-        {
-          name        : 'bucket-name',
-          description : 'The name of the bucket to be used. If no option is given, cloudsite will generate a bucket name based on the apex domain.'
-        },
-        {
-          name        : 'no-build',
-          description : 'Supresses the default behavior of building before uploading the site content.',
-          type        : Boolean
-        },
-        {
-          name        : 'no-delete-on-failure',
-          description : 'When true, does not delete the site stack after setup failure.',
-          type        : Boolean
-        },
-        {
-          name        : 'no-interactive',
-          description : 'Suppresses activation of the interactive setup where it would otherwise be activated.',
-          type        : Boolean
-        },
-        optionSpec,
-        {
-          name        : 'region',
-          description : "The region where to create the site resources. Defaults to 'us-east-1'.",
-          default     : 'us-east-1'
-        },
-        {
-          name        : 'source-path',
-          description : 'Local path to the static site root.',
-          required    : true
-        },
-        sourceTypeArgSpec,
-        {
-          name        : 'stack-name',
-          description : 'Specify the name of the stack to be created and override the default name.'
-        }
-      ]
-    },
-    {
-      name        : 'destroy',
-      description : 'Destroys the named site. I.e., deletes all cloud resources associated with the site.',
-      arguments   : [
-        {
-          name          : 'apex-domain',
-          description   : 'The domain of the site to delete.',
-          defaultOption : true,
-          required      : true
-        },
-        {
-          name        : 'confirmed',
-          description : 'Skips the interactive confirmation and destroys the resources without further confirmation.',
-          type        : Boolean
-        }
-      ]
-    },
-    {
-      name        : 'detail',
-      description : 'Prints details for the indicated site.',
-      arguments   : [
-        {
-          name          : 'apex-domain',
-          description   : 'The domain of the site to detail.',
-          defaultOption : true,
-          required      : true
-        }
-      ]
-    },
-    {
-      name        : 'get-iam-policy',
-      description : 'Prints an IAM policy suitable for operating cloudsite.',
-      arguments   : [
-        {
-          name        : 'with-instructions',
-          description : 'When set, will print instructions for creating the policy along with the policy.',
-          type        : Boolean
-        }
-      ]
-    },
-    {
-      name        : 'list',
-      description : 'Lists the sites registered in the local database.',
-      arguments   : [
-        {
-          name        : 'all-fields',
-          description : 'Includes all fields in the output.',
-          type        : Boolean
-        }
-      ]
-    },
-    {
-      name        : 'import',
-      description : 'Generates a site database based on currently deployed site stacks.',
-      arguments   : [
-        {
-          name        : 'common-logs-bucket',
-          description : "Specifies the common logs bucket name. This is only necessary if there are multiple candidates, otherwise cloudsite can usually guess. Set to 'NONE' to suppress guessing and assume there is on common logs bucket."
-        },
-        {
-          name          : 'domain-and-stack',
-          description   : 'The domain and stack are specified as positional parameters, in either order.',
-          defaultOption : true,
-          multiple      : true,
-          required      : true
-        },
-        {
-          name        : 'refresh',
-          description : "By defaualt, cloudsite will refuse to overwrite existing site DB entries. if '--refresh' is true, then it will update/refresh the existing entry.",
-          type        : Boolean
-        },
-        {
-          name        : 'region',
-          description : 'Specifies the region where the stack is to be found.',
-          required    : true
-        },
-        {
-          name        : 'source-path',
-          description : 'Local path to the static site root.',
-          required    : true
-        },
-        sourceTypeArgSpec
-      ]
-    },
-    {
-      name        : 'plugin-settings',
-      description : 'Sets (or deletes) a site option.',
-      arguments   : [
-        {
-          name          : 'subcommand',
-          description   : 'The subcommand to execute.',
-          defaultOption : true,
-          required      : true
-        }
-      ],
-      commands : [
-        {
-          name        : 'set',
-          description : 'Sets and deletes the specified options.',
-          arguments   : [
-            {
-              name          : 'apex-domain',
-              description   : 'The apex domain of the site to configure.',
-              defaultOption : true,
-              required      : true
-            },
-            {
-              name        : 'confirmed',
-              description : "When entirely deleting (disabling) a plugin, you must either confirm interactively or provide the '--confirmed' option.",
-              type        : Boolean
-            },
-            {
-              name        : 'delete',
-              description : "When set, then deletes the setting. Incompatible with the '--value' option. To delete all plugin settings (disable the plugin), set '--name' or '--option' to the bare plugin name; e.g.: --value aPlugin.",
-              type        : Boolean
-            },
-            {
-              name        : 'name',
-              description : 'The option name.'
-            },
-            optionSpec, // the 'options' definition
-            {
-              name        : 'value',
-              description : "The setting value. Incompatible with the '--delete' option."
-            }
-          ]
-        },
-        {
-          name        : 'show',
-          description : 'Displays the plugin settings for the specified site.',
-          arguments   : [
-            {
-              name          : 'apex-domain',
-              description   : 'The apex domain of the site whose settings are to be displayed.',
-              defaultOption : true,
-              required      : true
-            }
-          ]
-        }
-      ]
-    },
-    {
-      name      : 'update',
-      summary   : 'Updates a website content and/or infrastructure.',
-      arguments : [
-        {
-          name          : 'apex-domain',
-          description   : 'The apex domain identifying the site.',
-          defaultOption : true,
-          required      : true
-        },
-        {
-          name        : 'do-billing',
-          description : 'Limits updates to billing related matters (cost allocation tags) and other other specified updates.',
-          type        : Boolean
-        },
-        {
-          name        : 'do-content',
-          description : 'Limits update to site content and any other specified updates.',
-          type        : Boolean
-        },
-        {
-          name        : 'do-dns',
-          description : 'Limits update to DNS entries and any other specified updates.',
-          type        : Boolean
-        },
-        {
-          name        : 'do-stack',
-          description : 'Limits update to stack infrastructure and any other specified updates.',
-          type        : Boolean
-        },
-        {
-          name        : 'no-build',
-          description : 'Supresses the default behavior of building before updating the site.',
-          type        : Boolean
-        },
-        {
-          name        : 'no-cache-invalidation',
-          description : 'Suppresses the default behavior of invalidating the CloudFront cache after the files are updated. Note that invalidation events are chargeable thought at the time of this writing, each account gets 1,000 free requests per year.'
-        }
-      ]
-    },
-    {
-      name      : 'verify',
-      summary   : 'Verifies the site is up and running and that the stack and content are up-to-date.',
-      arguments : [
-        {
-          name          : 'apex-domain',
-          description   : 'The domain of the site to verify.',
-          defaultOption : true,
-          required      : true
-        },
-        {
-          name        : 'check-content',
-          description : 'If set, then checks content and skips other checks unless also specifically specified.',
-          type        : Boolean
-        },
-        {
-          name        : 'check-site-up',
-          description : 'If set, then checks that the site is up and skips other checks unless also specifically specified.',
-          type        : Boolean
-        },
-        {
-          name        : 'check-stack',
-          description : 'If set, then checks for stack drift and skips other checks unless also specifically specified.',
-          type        : Boolean
-        }
-      ]
-    }
-  ]
-}
- 
-export { cliSpec, DB_PATH, globalOptionsSpec, SOURCE_TYPES, VALID_FORMATS }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/index.html b/qa/coverage/cli/index.html deleted file mode 100644 index 0cbf64e7..00000000 --- a/qa/coverage/cli/index.html +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - Code coverage report for cli - - - - - - - - - -
-
-

All files cli

-
- -
- 0% - Statements - 0/111 -
- - -
- 0% - Branches - 0/53 -
- - -
- 0% - Functions - 0/4 -
- - -
- 0% - Lines - 0/99 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
cloudsite.mjs -
-
0%0/1020%0/470%0/30%0/91
constants.mjs -
-
0%0/90%0/60%0/10%0/8
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-authentication.mjs.html b/qa/coverage/cli/lib/check-authentication.mjs.html deleted file mode 100644 index bf02d48e..00000000 --- a/qa/coverage/cli/lib/check-authentication.mjs.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - Code coverage report for cli/lib/check-authentication.mjs - - - - - - - - - -
-
-

All files / cli/lib check-authentication.mjs

-
- -
- 0% - Statements - 0/8 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/8 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { ListBucketsCommand, S3Client } from '@aws-sdk/client-s3'
- 
-import { getCredentials } from '../../lib/actions/lib/get-credentials' // move to shared
- 
-const checkAuthentication = async ({ db }) => {
-  const credentials = getCredentials(db.account.settings)
- 
-  const s3Client = new S3Client({ credentials })
-  const listBucketsCommand = new ListBucketsCommand({})
-  await s3Client.send(listBucketsCommand) // we don't actually care about the result, we're just checking the auth
-}
- 
-export { checkAuthentication }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-format.mjs.html b/qa/coverage/cli/lib/check-format.mjs.html deleted file mode 100644 index 98b8046d..00000000 --- a/qa/coverage/cli/lib/check-format.mjs.html +++ /dev/null @@ -1,112 +0,0 @@ - - - - - - Code coverage report for cli/lib/check-format.mjs - - - - - - - - - -
-
-

All files / cli/lib check-format.mjs

-
- -
- 0% - Statements - 0/5 -
- - -
- 0% - Branches - 0/3 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/5 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10  -  -  -  -  -  -  -  -  - 
import { VALID_FORMATS } from '../constants'
- 
-const checkFormat = (format) => {
-  Iif (format !== undefined && !VALID_FORMATS.includes(format)) {
-    throw new Error(`Invalid output format '${format}'. Must be one of: ${VALID_FORMATS.join(', ')}`)
-  }
-}
- 
-export { checkFormat }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/check-reminders.mjs.html b/qa/coverage/cli/lib/check-reminders.mjs.html deleted file mode 100644 index 4327484e..00000000 --- a/qa/coverage/cli/lib/check-reminders.mjs.html +++ /dev/null @@ -1,154 +0,0 @@ - - - - - - Code coverage report for cli/lib/check-reminders.mjs - - - - - - - - - -
-
-

All files / cli/lib check-reminders.mjs

-
- -
- 0% - Statements - 0/14 -
- - -
- 0% - Branches - 0/5 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/14 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { progressLogger } from '../../lib/shared/progress-logger'
- 
-const checkReminders = ({ reminders }) => {
-  const now = new Date().getTime()
-  const currentReminders = reminders.filter(({ remindAfter }) => {
-    const remindAfterEpoch = Date.parse(remindAfter)
-    return remindAfterEpoch <= now
-  })
- 
-  Iif (currentReminders.length > 0) {
-    const columnWidth = progressLogger.write.width
-    const opener = '-- <yellow>Reminder<rst>' + (currentReminders.lengith > 1 ? 's ' : ' ')
-    progressLogger.write(opener + '-'.repeat(columnWidth - opener.length + '<yellow>'.length + '<rst>'.length) + '\n')
- 
-    currentReminders.forEach(({ todo }, i) => {
-      progressLogger.write((currentReminders.length > 1 ? i + '.' : '') + todo + '\n')
-    })
- 
-    progressLogger.write('-'.repeat(columnWidth) + '\n')
-  }
-}
- 
-export { checkReminders }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html b/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html deleted file mode 100644 index a280fc78..00000000 --- a/qa/coverage/cli/lib/configuration/handle-configuration-initialize.mjs.html +++ /dev/null @@ -1,193 +0,0 @@ - - - - - - Code coverage report for cli/lib/configuration/handle-configuration-initialize.mjs - - - - - - - - - -
-
-

All files / cli/lib/configuration handle-configuration-initialize.mjs

-
- -
- 100% - Statements - 9/9 -
- - -
- 100% - Branches - 0/0 -
- - -
- 100% - Functions - 1/1 -
- - -
- 100% - Lines - 9/9 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -371x -  -1x -  -1x -1x -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -1x -1x -  -1x -  -1x -1x -  -  - 
import { Questioner } from 'question-and-answer'
- 
-import { progressLogger } from '../../../lib/shared/progress-logger'
- 
-const handleConfigurationInitialize = async ({ db }) => {
-  const interrogationBundle = {
-    actions : [
-      {
-        prompt    : "Which local AWS SSO profile should be used for authentication? Hit '<enter>' to use the default profile.",
-        parameter : 'sso-profile'
-      },
-      {
-        prompt    : 'Which default format would you prefer?',
-        options   : ['json', 'text', 'terminal', 'yaml'],
-        default   : 'terminal',
-        parameter : 'format'
-      },
-      {
-        prompt    : "In 'quiet' mode, you only get output when an command has completed. In 'non-quiet' mode, you will receive updates as the command is processed. Would you like to activate quiet mode?",
-        type      : 'boolean',
-        default   : false,
-        parameter : 'quiet'
-      },
-      { review : 'questions' }
-    ]
-  }
- 
-  const questioner = new Questioner({ interrogationBundle, output : progressLogger })
-  await questioner.question()
- 
-  db.account.settings = questioner.values
- 
-  return { success : true, userMessage : 'Settings updated.' }
-}
- 
-export { handleConfigurationInitialize }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html b/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html deleted file mode 100644 index 47744ac4..00000000 --- a/qa/coverage/cli/lib/configuration/handle-configuration-show.mjs.html +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - Code coverage report for cli/lib/configuration/handle-configuration-show.mjs - - - - - - - - - -
-
-

All files / cli/lib/configuration handle-configuration-show.mjs

-
- -
- 100% - Statements - 4/4 -
- - -
- 50% - Branches - 1/2 -
- - -
- 100% - Functions - 1/1 -
- - -
- 100% - Lines - 4/4 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21  -  -  -  -  -1x -  -  -  -  -  -  -  -  -  -1x -1x -1x -  -  - 
/* import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../../constants'
-import { getOptionsSpec } from '../get-options-spec' */
- 
-const handleConfigurationShow = async ({ /* argv, */ db }) => {
-  /*
-  const myOptionsSpec = cliSpec
-    .commands.find(({ name }) => name === 'configuration')
-    .commands.find(({ name }) => name === 'show')
-    .arguments || []
-  const showConfigurationCLISpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
-  const showConfigurationOptionsSpec = showConfigurationCLISpec.arguments
-  const showConfigurationOptions = commandLineArgs(showConfigurationOptionsSpec, { argv }) */
- 
-  const accountSettings = db.account.settings || {}
-  return { success : true, data : accountSettings }
-}
- 
-export { handleConfigurationShow }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/configuration/index.html b/qa/coverage/cli/lib/configuration/index.html deleted file mode 100644 index 9dc23cde..00000000 --- a/qa/coverage/cli/lib/configuration/index.html +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - Code coverage report for cli/lib/configuration - - - - - - - - - -
-
-

All files cli/lib/configuration

-
- -
- 100% - Statements - 13/13 -
- - -
- 50% - Branches - 1/2 -
- - -
- 100% - Functions - 2/2 -
- - -
- 100% - Lines - 13/13 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
handle-configuration-initialize.mjs -
-
100%9/9100%0/0100%1/1100%9/9
handle-configuration-show.mjs -
-
100%4/450%1/2100%1/1100%4/4
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-global-options.mjs.html b/qa/coverage/cli/lib/get-global-options.mjs.html deleted file mode 100644 index 6e1df40e..00000000 --- a/qa/coverage/cli/lib/get-global-options.mjs.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - Code coverage report for cli/lib/get-global-options.mjs - - - - - - - - - -
-
-

All files / cli/lib get-global-options.mjs

-
- -
- 0% - Statements - 0/18 -
- - -
- 0% - Branches - 0/14 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/18 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { checkFormat } from './check-format'
-import { globalOptionsSpec } from '../constants'
- 
-let globalOptionsCache
- 
-const getGlobalOptions = ({ db }) => {
-  Iif (globalOptionsCache !== undefined) {
-    return globalOptionsCache
-  } // else
- 
-  const defaultOptions = db?.account?.settings || {}
- 
-  const overrideOptions = commandLineArgs(globalOptionsSpec, { partial : true })
-  delete overrideOptions._unknown // don't need or want this
- 
-  const globalOptions = Object.assign({}, defaultOptions, overrideOptions)
- 
-  const { format, verbose } = globalOptions
- 
-  checkFormat(format)
- 
-  let { quiet } = globalOptions
-  // process.stdin.isTTY =~ shell program (true) or pipe (false)
-  quiet = quiet || (verbose !== true && (format === 'json' || format === 'yaml' || !process.stdin.isTTY))
-  globalOptions.quiet = quiet
- 
-  globalOptionsCache = globalOptions
- 
-  return globalOptions
-}
- 
-export { getGlobalOptions }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-options-spec.mjs.html b/qa/coverage/cli/lib/get-options-spec.mjs.html deleted file mode 100644 index 56eb16f5..00000000 --- a/qa/coverage/cli/lib/get-options-spec.mjs.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - Code coverage report for cli/lib/get-options-spec.mjs - - - - - - - - - -
-
-

All files / cli/lib get-options-spec.mjs

-
- -
- 0% - Statements - 0/7 -
- - -
- 0% - Branches - 0/7 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/6 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { globalOptionsSpec } from '../constants'
- 
-const getOptionsSpec = ({ cliSpec, optionsSpec, name }) => {
-  optionsSpec = optionsSpec || cliSpec?.commands.find(({ name : testName }) => name === testName).arguments || []
-  const finalSpec =
-    [
-      ...optionsSpec,
-      // this is so we can process the global options anywhere while also sounding alarm on unknown options
-      ...globalOptionsSpec
-    ]
- 
-  return finalSpec
-}
- 
-export { getOptionsSpec }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-site-info.mjs.html b/qa/coverage/cli/lib/get-site-info.mjs.html deleted file mode 100644 index 4415d447..00000000 --- a/qa/coverage/cli/lib/get-site-info.mjs.html +++ /dev/null @@ -1,127 +0,0 @@ - - - - - - Code coverage report for cli/lib/get-site-info.mjs - - - - - - - - - -
-
-

All files / cli/lib get-site-info.mjs

-
- -
- 0% - Statements - 0/8 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/8 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
const getSiteInfo = ({ apexDomain, db }) => {
-  Iif (apexDomain === undefined) {
-    throw new Error('Must specify site domain.')
-  }
- 
-  const siteInfo = db.sites[apexDomain]
-  Iif (siteInfo === undefined) {
-    throw new Error(`No such site '${apexDomain}' found.`)
-  }
- 
-  return siteInfo
-}
- 
-export { getSiteInfo }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/get-value-container-and-key.mjs.html b/qa/coverage/cli/lib/get-value-container-and-key.mjs.html deleted file mode 100644 index 63d52c09..00000000 --- a/qa/coverage/cli/lib/get-value-container-and-key.mjs.html +++ /dev/null @@ -1,229 +0,0 @@ - - - - - - Code coverage report for cli/lib/get-value-container-and-key.mjs - - - - - - - - - -
-
-

All files / cli/lib get-value-container-and-key.mjs

-
- -
- 0% - Statements - 0/25 -
- - -
- 0% - Branches - 0/35 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/25 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
const getValueContainerAndKey = ({ path, pathPrefix, rootContainer, skipValueCheck, spec, value }) => {
-  const origPath = (pathPrefix === undefined ? '' : pathPrefix) + path.join('.') // used if validation error
-  Iif (path === undefined || path.length === 0) {
-    return [rootContainer, undefined]
-  }
-  // walks the path, creating new containers along the way as necessary
-  return path.reduce(([currContainer, currSpec], bit, i) => {
-    // then we're at the terminal path bit; let's analyze whether it's valid and if value passes validation
-    if (i === path.length - 1) {
-      currSpec = currSpec?.[bit]
-      if (currSpec !== undefined) {
-        const { matches, validation } = currSpec
-        Iif (validation === undefined && matches === undefined) {
-          throw new Error(
-            `Plugin option '${origPath}' spec must define either 'validation' or 'matches'.`,
-            { exitCode : 11 }
-          )
-        }
-        Iif (matches !== undefined && value?.match(matches) === null) {
-          throw new Error(
-            `Invalid value '${value}' for '${origPath}'; must match ${matches.toString()}.`,
-            { exitCode : 3 }
-          )
-        }
- 
-        Iif (skipValueCheck !== true && validation !== undefined && !validation(value)) {
-          throw new Error(`Value '${value}' for '${origPath}' failed validation.`, { exitCode : 3 })
-        }
-      } else { // currSpec === undefined
-        throw new Error(`Path '${origPath}' incorrect; no such terminal bit '${bit}'.`, { exitCode : 3 })
-      }
- 
-      return { valueKey : path[i], valueContainer : currContainer }
-    } else {
-      const currSpec = spec?.[bit]
-      Iif (currSpec === undefined && i > 0) {
-        throw new Error(`Invalid option path '${origPath}'; no such element '${bit}'.\n`)
-      }
-      const container = currContainer[bit]
-      Iif (container === undefined) {
-        currContainer[bit] = {}
-      }
-      return [currContainer[bit], currSpec]
-    }
-  }, [rootContainer, spec])
-}
- 
-export { getValueContainerAndKey }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-cleanup.mjs.html b/qa/coverage/cli/lib/handle-cleanup.mjs.html deleted file mode 100644 index ab5b23f6..00000000 --- a/qa/coverage/cli/lib/handle-cleanup.mjs.html +++ /dev/null @@ -1,235 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-cleanup.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-cleanup.mjs

-
- -
- 0% - Statements - 0/32 -
- - -
- 0% - Branches - 0/10 -
- - -
- 0% - Functions - 0/5 -
- - -
- 0% - Lines - 0/30 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { destroy } from '../../lib/actions/destroy'
-import { getOptionsSpec } from './get-options-spec'
-import { progressLogger } from '../../lib/shared/progress-logger'
- 
-const handleCleanup = async ({ argv, db }) => {
-  const cleanupOptionsSpec = getOptionsSpec({ cliSpec, name : 'cleanup' })
-  const cleanupOptions = commandLineArgs(cleanupOptionsSpec, { argv })
-  const apexDomain = cleanupOptions['apex-domain']
-  const { list } = cleanupOptions
- 
-  Iif (list === true) {
-    return { data : Object.keys(db.toCleanup) || [] }
-  }
- 
-  const listOfSitesToCleanup = apexDomain === undefined
-    ? Object.keys(db.toCleanup)
-    : [apexDomain]
- 
-  const deleteActions = listOfSitesToCleanup
-    .map((apexDomain) => {
-      progressLogger.write(`Cleaning up ${apexDomain}...\n`)
-      return destroy({ db, siteInfo : db.toCleanup[apexDomain], verbose : false })
-    })
- 
-  progressLogger.write('.')
-  const intervalID = setInterval(() => progressLogger.write('.'), 2000)
-  const cleanupResults = await Promise.all(deleteActions)
-  clearInterval(intervalID)
-  progressLogger.write('\n')
- 
-  listOfSitesToCleanup.forEach((apexDomain, i) => {
-    const cleanupResult = cleanupResults[i]
-    progressLogger.write(`${apexDomain}: ${cleanupResult === true ? 'CLEANED' : 'NOT cleaned'}\n`)
-    Iif (cleanupResult === true) {
-      delete db.toCleanup[apexDomain]
-      db.reminders.splice(db.reminders.findIndex(({ apexDomain: testDomain }) => testDomain === apexDomain), 1)
-    }
-  })
- 
-  const userMessage = listOfSitesToCleanup.length === 1
-    ? `Site '${listOfSitesToCleanup[0]}' has been successfully cleaned.`
-    : `Sites '${listOfSitesToCleanup.join("', '")}' have been successfully cleaned.`
- 
-  return { success : true, userMessage }
-}
- 
-export { handleCleanup }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-configuration.mjs.html b/qa/coverage/cli/lib/handle-configuration.mjs.html deleted file mode 100644 index eb5b416b..00000000 --- a/qa/coverage/cli/lib/handle-configuration.mjs.html +++ /dev/null @@ -1,157 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-configuration.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-configuration.mjs

-
- -
- 0% - Statements - 0/15 -
- - -
- 0% - Branches - 0/5 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/15 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
-import { handleConfigurationInitialize } from './configuration/handle-configuration-initialize'
-import { handleConfigurationShow } from './configuration/handle-configuration-show'
- 
-const handleConfiguration = async ({ argv, db }) => {
-  const configurationOptionsSpec = getOptionsSpec({ cliSpec, name : 'configuration' })
-  const configurationOptions = commandLineArgs(configurationOptionsSpec, { argv, stopAtFirstUnknown : true })
-  const { subcommand } = configurationOptions
-  argv = configurationOptions._unknown || []
- 
-  switch (subcommand) {
-    case 'initialize':
-      return await handleConfigurationInitialize({ argv, db })
-    case 'show':
-      return await handleConfigurationShow({ argv, db })
-    default:
-      throw new Error('Unknown configuration command: ' + subcommand)
-  }
-}
- 
-export { handleConfiguration }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-create.mjs.html b/qa/coverage/cli/lib/handle-create.mjs.html deleted file mode 100644 index 5a58b17a..00000000 --- a/qa/coverage/cli/lib/handle-create.mjs.html +++ /dev/null @@ -1,475 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-create.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-create.mjs

-
- -
- 0% - Statements - 0/74 -
- - -
- 0% - Branches - 0/30 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/72 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import * as fsPath from 'node:path'
- 
-import commandLineArgs from 'command-line-args'
-import { awsS3TABucketNameRE, awsS3TABucketNameREString } from 'regex-repo'
-import { Questioner } from 'question-and-answer'
- 
-import { checkAuthentication } from './check-authentication'
-import { cliSpec } from '../constants'
-import { create } from '../../lib/actions/create'
-import { getOptionsSpec } from './get-options-spec'
-import * as optionsLib from './options'
-import * as plugins from '../../lib/plugins'
-import { processSourceType } from './process-source-type'
-import { progressLogger } from '../../lib/shared/progress-logger'I
- 
-const handleCreate = async ({ argv, db }) => {
-  await checkAuthentication({ db })
- 
-  const createOptionsSpec = getOptionsSpec({ cliSpec, name : 'create' })
-  const createOptions = commandLineArgs(createOptionsSpec, { argv })
-  // action behavior options
-  const noDeleteOnFailure = createOptions['no-delete-on-failure']
-  // siteInfo options
-  let apexDomain = createOptions['apex-domain']
-  const bucketName = createOptions['bucket-name']
-  const noBuild = createOptions['no-build']
-  const noInteractive = createOptions['no-interactive']
-  // switch any relative sourcePath to absolute
-  let sourcePath = createOptions['source-path']
-  let sourceType = createOptions['source-type']
-  let stackName = createOptions['stack-name']
-  const options = optionsLib.mapRawOptions(createOptions.option)
- 
-  Iif (noInteractive !== true) {
-    const interrogationBundle = { actions : [{ review : 'questions' }] }
-    Iif (sourcePath === undefined) { // doing these in reverse order because we're 'unshifting' to the front
-      interrogationBundle.actions.unshift({ prompt : 'Source path:', parameter : 'sourcePath' })
-    }
-    Iif (apexDomain === undefined) {
-      interrogationBundle.actions.unshift({ prompt : 'Apex domain:', parameter : 'apexDomain' })
-    }
-    Iif (interrogationBundle.actions.length > 1) {
-      const questioner = new Questioner({ interrogationBundle, output : progressLogger })
-      await questioner.question();
- 
-      ({ apexDomain = apexDomain, sourcePath = sourcePath } = questioner.values)
-    }
-  }
-  sourcePath = fsPath.resolve(sourcePath)
- 
-  // don't use 'getSiteInfo', it errors out on blanks
-  const siteInfo = db.sites[apexDomain] || { apexDomain, bucketName, sourcePath, sourceType }
-  siteInfo.region = createOptions.region || siteInfo.region || 'us-east-1'
-  Iif (stackName !== undefined) {
-    siteInfo.stackName = stackName
-  }
- 
-  db.sites[apexDomain] = siteInfo
- 
-  // verify the parameters/options
-  for (const [value, option] of [[apexDomain, 'apex-domain'], [sourcePath, 'source-path']]) {
-    Iif (value === undefined) {
-      throw new Error(`Missing required '${option}' option.`, { exitCode : 2 })
-      // TODO: handleHelp({ argv : ['create'] })
-    }
-  }
-  // TODO: verify apex domain matches apex domain RE
- 
-  sourceType = processSourceType({ sourcePath, sourceType })
- 
-  Iif (bucketName !== undefined && !awsS3TABucketNameRE.test(bucketName)) {
-    // we're not using Transfer Accelerated ATM, but we might want to at some point.
-    throw new Error(`Invalid bucket name. Must be valid AWS S3 Transfer Accelerated bucket name matching: ${awsS3TABucketNameREString}`, { exitCode : 2 })
-  }
- 
-  Iif (options.length === 0 && noInteractive !== true) {
-    for (const [plugin, { config }] of Object.entries(plugins)) {
-      const { description, name, options: configOptions } = config
-      const interrogationBundle = {
-        actions : [
-          { statement : `<em>${name}<rst> plugin: ${description}` },
-          { prompt : `Enable '<em>${name}<rst>' plugin?`, options : ['yes', 'no'], default : 'no', parameter : 'enable' }
-        ]
-      }
-      const questioner = new Questioner({ interrogationBundle, output : progressLogger })
-      await questioner.question()
-      const enable = questioner.getResult('enable').value === 'yes'
- 
-      Iif (enable === true) {
-        const interrogationBundle = { actions : [] }
-        for (const [parameter, configSpec] of Object.entries(configOptions)) {
-          const { default: defaultValue, description, invalidMessage, matches, required, type = 'string' } = configSpec
-          const questionSpec = {
-            default          : defaultValue,
-            invalidMessage,
-            prompt           : `<em>${parameter}<rst>: ${description}\nValue?`,
-            parameter,
-            requireSomething : required,
-            requireMatch     : matches,
-            type
-          }
-          interrogationBundle.actions.push(questionSpec)
-        }
-        const questioner = new Questioner({ interrogationBundle, output : progressLogger })
-        await questioner.question()
-        options.push(...questioner.results.map(({ parameter, value }) => ({ name : `${plugin}.${parameter}`, value })))
-      }
-    }
-  }
- 
-  optionsLib.updatePluginSettings({ options, siteInfo })
- 
-  // update siteInfo in case these were manually specified
-  for (const [value, field] of [[bucketName, 'bucketName'], [sourcePath, 'sourcePath'], [sourceType, 'sourceType']]) {
-    Iif (value !== undefined) {
-      siteInfo[field] = value
-    }
-  }
- 
-  let success
-  ({ stackName, success } = await create({ db, noBuild, noDeleteOnFailure, siteInfo }))
- 
-  if (success === true) {
-    return { success, userMessage : `Created stack '${stackName}'.` }
-  } else {
-    return { success, userMessage : `Failed to create stack '${stackName}'.` }
-  }
-}
- 
-export { handleCreate }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-destroy.mjs.html b/qa/coverage/cli/lib/handle-destroy.mjs.html deleted file mode 100644 index 80ecdcf0..00000000 --- a/qa/coverage/cli/lib/handle-destroy.mjs.html +++ /dev/null @@ -1,256 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-destroy.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-destroy.mjs

-
- -
- 0% - Statements - 0/33 -
- - -
- 0% - Branches - 0/4 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/33 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
-import { Questioner } from 'question-and-answer'
- 
-import { cliSpec } from '../constants'
-import { destroy } from '../../lib/actions/destroy'
-import { getOptionsSpec } from './get-options-spec'
-import { getSiteInfo } from './get-site-info'
-import { progressLogger } from '../../lib/shared/progress-logger'
- 
-const handleDestroy = async ({ argv, db }) => {
-  const destroyOptionsSpec = getOptionsSpec({ cliSpec, name : 'destroy' })
-  const destroyOptions = commandLineArgs(destroyOptionsSpec, { argv })
-  const apexDomain = destroyOptions['apex-domain']
-  let { confirmed } = destroyOptions
- 
-  const siteInfo = getSiteInfo({ apexDomain, db })
- 
-  Iif (confirmed !== true) {
-    const interrogationBundle = {
-      actions : [{
-        prompt    : `Confirm destruction of '${apexDomain}'?`,
-        paramType : 'boolean',
-        parameter : 'confirmed'
-      }]
-    }
-    const questioner = new Questioner({ interrogationBundle, output : progressLogger })
-    await questioner.question()
-    confirmed = questioner.getResult('confirmed').value
- 
-    Iif (confirmed !== true) {
-      progressLogger.write('Not confirmed; canceling operation.\n')
-      return
-    }
-  }
- 
-  const deleted = await destroy({ db, siteInfo, verbose : true })
- 
-  if (deleted === true) {
-    delete db.sites[apexDomain]
-    return { success : true, userMessage : `${apexDomain} deleted.\nRemoved ${apexDomain} from local DB.\n` }
-  } else {
-    const now = new Date()
-    const remindAfter = new Date(now.getTime() + 2 * 60 * 60 * 1000)
-    siteInfo.lastCleanupAttempt = now.toISOString()
-    db.toCleanup[apexDomain] = siteInfo
-    db.reminders.push({
-      todo        : `Cleanup partially deleted site '${apexDomain}'. Try:\ncloudsite cleanup`,
-      remindAfter : remindAfter.toISOString(),
-      references  : apexDomain
-    })
-    delete db.sites[apexDomain]
- 
-    return { success : false, userMessage : `The delete has failed, which is expected because the 'replicated Lambda functions' need to be cleared by AWS before all resources can be deleted. This can take 30 min to a few hours.\n\nThe site has been marked for cleanup and you can now create new sites using the '${apexDomain}' domain.\n\nYou can complete deletion by executing:\ncloudsite cleanup\n` }
-  }
-}
- 
-export { handleDestroy }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-detail.mjs.html b/qa/coverage/cli/lib/handle-detail.mjs.html deleted file mode 100644 index 8484895c..00000000 --- a/qa/coverage/cli/lib/handle-detail.mjs.html +++ /dev/null @@ -1,160 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-detail.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-detail.mjs

-
- -
- 0% - Statements - 0/16 -
- - -
- 0% - Branches - 0/1 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/16 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { checkFormat } from './check-format'
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
-import { getSiteInfo } from './get-site-info'
- 
-const handleDetail = ({ argv, db }) => {
-  const detailOptionsSpec = getOptionsSpec({ cliSpec, name : 'detail' })
-  const detailOptions = commandLineArgs(detailOptionsSpec, { argv })
-  const apexDomain = detailOptions['apex-domain']
-  const { format } = detailOptions
- 
-  Iif (apexDomain === undefined) {
-    throw new Error('Apex domain must be specified.')
-  }
- 
-  checkFormat(format)
- 
-  const output = getSiteInfo({ apexDomain, db })
- 
-  return { success : true, data : output }
-}
- 
-export { handleDetail }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html b/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html deleted file mode 100644 index 6adc3e63..00000000 --- a/qa/coverage/cli/lib/handle-get-iam-policy.mjs.html +++ /dev/null @@ -1,847 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-get-iam-policy.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-get-iam-policy.mjs

-
- -
- 0% - Statements - 0/21 -
- - -
- 0% - Branches - 0/6 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/21 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183 -184 -185 -186 -187 -188 -189 -190 -191 -192 -193 -194 -195 -196 -197 -198 -199 -200 -201 -202 -203 -204 -205 -206 -207 -208 -209 -210 -211 -212 -213 -214 -215 -216 -217 -218 -219 -220 -221 -222 -223 -224 -225 -226 -227 -228 -229 -230 -231 -232 -233 -234 -235 -236 -237 -238 -239 -240 -241 -242 -243 -244 -245 -246 -247 -248 -249 -250 -251 -252 -253 -254 -255  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { getAccountID } from '../../lib/shared/get-account-id'
-import { getCredentials } from '../../lib/actions/lib/get-credentials' // TODO: move to shared
-import { getOptionsSpec } from './get-options-spec'
-import { progressLogger } from '../../lib/shared/progress-logger'
- 
-const generateIAMPolicy = async (db) => {
-  // TODO: once we refactor 'sites.json' into 'cloudsite-db.json', with 'accountID' at the top level, we can pass that
-  // in here and avoid the 'getAccountID' call in many cases
-  let { accountID } = db.account
-  Iif (accountID === undefined) {
-    const credentials = getCredentials(db.account?.settings)
-    accountID = await getAccountID({ credentials })
-  }
- 
-  return {
-    Version   : '2012-10-17',
-    Statement : [
-      {
-        Sid    : 'CloudsiteAcmGrants',
-        Effect : 'Allow',
-        Action : [
-          'acm:ListCertificates',
-          'acm:RequestCertificate'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteCostExplorerGrants',
-        Effect : 'Allow',
-        Action : [
-          'ce:UpdateCostAllocationTagsStatus'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteCloudFormationGrants',
-        Effect : 'Allow',
-        Action : [
-          'cloudformation:CreateStack',
-          'cloudformation:DeleteStack',
-          'cloudformation:DescribeStackDriftDetectionStatus',
-          'cloudformation:DescribeStackEvents',
-          'cloudformation:DescribeStacks',
-          'cloudformation:DetectStackDrift',
-          'cloudformation:DetectStackResourceDrift',
-          'cloudformation:GetTemplate',
-          'cloudformation:ListChangeSets',
-          'cloudformation:UpdateStack'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteCloudFrontGrants',
-        Effect : 'Allow',
-        Action : [
-          'cloudfront:CreateDistribution',
-          'cloudfront:CreateInvalidation',
-          'cloudfront:CreateOriginAccessControl',
-          'cloudfront:DeleteDistribution',
-          'cloudfront:DeleteOriginAccessControl',
-          'cloudfront:GetDistribution',
-          'cloudfront:GetOriginAccessControl',
-          'cloudfront:ListDistributions',
-          'cloudfront:ListOriginAccessControls',
-          'cloudfront:TagResource',
-          'cloudfront:UpdateDistribution',
-          'cloudfront:UpdateOriginAccessControl'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteDynamoDBGrants',
-        Effect : 'Allow',
-        Action : [
-          'dynamodb:CreateTable',
-          'dynamodb:DeleteTable',
-          'dynamodb:DescribeTable',
-          'dynamodb:ListTagsOfResource',
-          'dynamodb:TagResource',
-          'dynamodb:UntagResource',
-          'dynamodb:UpdateTable'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsitePolicyManagement',
-        Effect : 'Allow',
-        Action : [
-          'iam:AttachRolePolicy',
-          'iam:DetachRolePolicy',
-          'iam:DeleteRolePolicy'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsitePassRole',
-        Effect : 'Allow',
-        Action : [
-          'iam:PassRole'
-        ],
-        Resource : [
-          `arn:aws:iam::${accountID}:role/cloudsite/*`
-        ],
-        Condition : {
-          'ForAnyValue:StringEquals' : {
-            'iam:PassedToService' : [
-              'lambda.amazonaws.com',
-              'edgelambda.amazonaws.com'
-            ]
-          }
-        }
-      },
-      {
-        Sid    : 'CloudsiteRoleManagement',
-        Effect : 'Allow',
-        Action : [
-          'iam:CreateRole',
-          'iam:DeleteRole',
-          'iam:GetRole',
-          'iam:PutRolePolicy',
-          'iam:TagRole',
-          'iam:UntagRole',
-          'iam:UpdateRole'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteLambdaGrants',
-        Effect : 'Allow',
-        Action : [
-          'lambda:AddPermission',
-          'lambda:CreateFunction',
-          'lambda:CreateEventSourceMapping',
-          'lambda:CreateFunctionUrlConfig',
-          'lambda:DeleteEventSourceMapping',
-          'lambda:DeleteFunction',
-          'lambda:DeleteFunctionUrlConfig',
-          'lambda:EnableReplication',
-          'lambda:GetEventSourceMapping',
-          'lambda:GetFunction',
-          'lambda:GetFunctionConfiguration',
-          'lambda:GetFunctionUrlConfig',
-          'lambda:ListFunctions',
-          'lambda:ListFunctionUrlConfigs',
-          'lambda:ListTags',
-          'lambda:ListVersionsByFunction',
-          'lambda:PublishVersion',
-          'lambda:RemovePermission',
-          'lambda:TagResource',
-          'lambda:UpdateEventSourceMapping',
-          'lambda:UpdateFunctionCode',
-          'lambda:UpdateFunctionConfiguration',
-          'lambda:UpdateFunctionUrlConfig'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteLogGrants',
-        Effect : 'Allow',
-        Action : [
-          'logs:CreateLogGroup',
-          'logs:DeleteLogGroup',
-          'logs:DeleteRetentionPolicy',
-          'logs:ListTagsForResource',
-          'logs:PutRetentionPolicy',
-          'logs:TagResource',
-          'logs:UntagResource'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteRoute53Grants',
-        Effect : 'Allow',
-        Action : [
-          'route53:ListHostedZones',
-          'route53:ChangeResourceRecordSets',
-          'route53:ChangeTagsForResource',
-          'route53:ListResourceRecordSets'
-        ],
-        Resource : [
-          '*'
-        ]
-      },
-      {
-        Sid    : 'CloudsiteS3Grants',
-        Effect : 'Allow',
-        Action : [
-          's3:CreateBucket',
-          's3:PutObject',
-          's3:DeleteObject',
-          's3:DeleteBucket',
-          's3:DeleteBucketPolicy',
-          's3:GetObject',
-          's3:ListAllMyBuckets',
-          's3:ListBucket',
-          's3:PutBucketAcl',
-          's3:PutBucketPolicy',
-          's3:PutBucketTagging',
-          's3:*'
-        ],
-        Resource : [
-          'arn:aws:s3:::*'
-        ]
-      }
-    ]
-  }
-}
- 
-const instructions =
-`1. Log into the AWS console.
-2. Select/navigate to the IAM service.
-3. Select 'Policies' from the left hand menu options.
-4. For a new policy, select 'Create policy' and name it 'CloudsiteManager'.
-   A. Select the 'JSON' option.
-5. For an existing policy, search for 'CloudsiteManager'.
-   A. Select 'Edit
-6. Copy and paste the above policy into the edit box.
-7. Hit 'Next' and then 'Save'.`
- 
-const handleGetIAMPolicy = async ({ argv, db }) => {
-  const getIAMPolicyOptionsSpec = getOptionsSpec({ cliSpec, name : 'get-iam-policy' })
-  const getIAMPolicyOptions = commandLineArgs(getIAMPolicyOptionsSpec, { argv })
-  const withInstructions = getIAMPolicyOptions['with-instructions']
- 
-  progressLogger.write(JSON.stringify(await generateIAMPolicy(db), null, '  ') + '\n')
- 
-  Iif (withInstructions === true) {
-    // As of 2024-03-29, smartIndent does not work with numbered lists, but it should in the future.
-    progressLogger.write('\n' + instructions + '\n', { smartIndent : true })
-  }
-}
- 
-export { handleGetIAMPolicy }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-import.mjs.html b/qa/coverage/cli/lib/handle-import.mjs.html deleted file mode 100644 index 5d62ac4c..00000000 --- a/qa/coverage/cli/lib/handle-import.mjs.html +++ /dev/null @@ -1,286 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-import.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-import.mjs

-
- -
- 0% - Statements - 0/41 -
- - -
- 0% - Branches - 0/22 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/41 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { resolve as resolvePath } from 'node:path'
- 
-import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { doImport } from '../../lib/actions/import'
-import { getOptionsSpec } from './get-options-spec'
-import { processSourceType } from './process-source-type'
-import { progressLogger } from '../../lib/shared/progress-logger'
- 
-const handleImport = async ({ argv, db }) => {
-  // gather parameter values
-  const importOptionsSpec = getOptionsSpec({ cliSpec, name : 'import' })
-  const importOptions = commandLineArgs(importOptionsSpec, { argv })
-  const commonLogsBucket = importOptions['common-logs-bucket']
-  const domainAndStack = importOptions['domain-and-stack']
-  const { refresh, region } = importOptions
-  let sourcePath = importOptions['source-path']
- 
-  // verify input parameters form correct
-  Iif (sourcePath === undefined) {
-    throw new Error("Must define '--source-path'.")
-  }
- 
-  sourcePath = resolvePath(sourcePath)
-  const sourceType = processSourceType({ sourcePath, sourceType : importOptions['source-type'] })
- 
-  Iif (domainAndStack?.length !== 2) {
-    throw new Error(`Unexpected number of positional arguments, expect 2 (domain and stack name), but got ${domainAndStack?.length || '0'}.\n`)
-  }
-  Iif (region === undefined) {
-    throw new Error("You must specify the '--region' parameter.\n")
-  }
-  Iif (sourcePath === undefined) {
-    throw new Error("You must specify the '--source-path' parameter.\n")
-  }
- 
-  let domain, stack
-  for (const domainOrStack of domainAndStack) {
-    if (domainOrStack.match(/\./)) {
-      domain = domainOrStack
-    } else Iif (domainOrStack.match(/^[a-z][a-z0-9-]*$/i)) {
-      stack = domainOrStack
-    }
-  }
- 
-  const sitesInfo = db.sites
- 
-  Iif (sitesInfo[domain] !== undefined && refresh !== true) {
-    throw new Error(`Domain '${domain}' is already in the sites DB. To update/refresh the values, use the '--refresh' option.`)
-  }
-  Iif (domain === undefined) {
-    throw new Error(`Could not determine domain name from arguments (${domainAndStack}).\n`)
-  }
-  Iif (stack === undefined) {
-    throw new Error(`Could not determine stack name from arguments (${domainAndStack}).\n`)
-  }
- 
-  // now, actually do the import
-  const dbEntry = await doImport({ commonLogsBucket, db, domain, region, sourcePath, sourceType, stack })
-  progressLogger.write(`Updating DB entry for '${domain}'...\n`)
-  sitesInfo[domain] = dbEntry
- 
-  return { success : true, userMessage : `Imported site '${domain}'.` }
-}
- 
-export { handleImport }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-list.mjs.html b/qa/coverage/cli/lib/handle-list.mjs.html deleted file mode 100644 index d328e875..00000000 --- a/qa/coverage/cli/lib/handle-list.mjs.html +++ /dev/null @@ -1,157 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-list.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-list.mjs

-
- -
- 0% - Statements - 0/15 -
- - -
- 0% - Branches - 0/4 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/15 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
-import pick from 'lodash/pick'
- 
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
- 
-const handleList = ({ argv, db }) => {
-  const listOptionsSpec = getOptionsSpec({ cliSpec, name : 'list' })
-  const listOptions = commandLineArgs(listOptionsSpec, { argv })
-  const allFields = listOptions['all-fields']
- 
-  const sitesInfoArray = Object.values(db.sites)
-  const output = allFields === true
-    ? sitesInfoArray
-    : sitesInfoArray.map((siteInfo) => {
-      const trimmed = pick(siteInfo, ['apexDomain', 'region', 'sourcePath'])
-      trimmed.plugins = Object.keys(siteInfo.plugins || {})
-      return trimmed
-    })
- 
-  return { data : output, success : true }
-}
- 
-export { handleList }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-plugin-settings.mjs.html b/qa/coverage/cli/lib/handle-plugin-settings.mjs.html deleted file mode 100644 index 46584b5e..00000000 --- a/qa/coverage/cli/lib/handle-plugin-settings.mjs.html +++ /dev/null @@ -1,157 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-plugin-settings.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-plugin-settings.mjs

-
- -
- 0% - Statements - 0/15 -
- - -
- 0% - Branches - 0/5 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/15 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
-import { handlePluginSettingsSet } from './plugin-settings/handle-plugin-settings-set'
-import { handlePluginSettingsShow } from './plugin-settings/handle-plugin-settings-show'
- 
-const handlePluginSettings = async ({ argv, db }) => {
-  const setOptionOptionsSpec = getOptionsSpec({ cliSpec, name : 'plugin-settings' })
-  const setOptionOptions = commandLineArgs(setOptionOptionsSpec, { argv, stopAtFirstUnknown : true })
-  const { subcommand } = setOptionOptions
-  argv = setOptionOptions._unknown || []
- 
-  switch (subcommand) {
-    case 'set':
-      return await handlePluginSettingsSet({ argv, db })
-    case 'show':
-      return await handlePluginSettingsShow({ argv, db })
-    default:
-      throw new Error('Unknown plugin settings command: ' + subcommand)
-  }
-}
- 
-export { handlePluginSettings }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-update.mjs.html b/qa/coverage/cli/lib/handle-update.mjs.html deleted file mode 100644 index 9ce1294b..00000000 --- a/qa/coverage/cli/lib/handle-update.mjs.html +++ /dev/null @@ -1,163 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-update.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-update.mjs

-
- -
- 0% - Statements - 0/19 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/19 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
-import { getSiteInfo } from './get-site-info'
-import { update } from '../../lib/actions/update'
- 
-const handleUpdate = async ({ argv, db }) => {
-  const updateOptionsSpec = getOptionsSpec({ cliSpec, name : 'update' })
-  const updateOptions = commandLineArgs(updateOptionsSpec, { argv })
-  const apexDomain = updateOptions['apex-domain']
-  const doBilling = updateOptions['do-billing']
-  const doContent = updateOptions['do-content']
-  const doDNS = updateOptions['do-dns']
-  const doStack = updateOptions['do-stack']
-  const noBuild = updateOptions['no-build']
-  const noCacheInvalidation = updateOptions['no-cache-invalidation']
- 
-  const siteInfo = getSiteInfo({ apexDomain, db })
- 
-  await update({ db, doBilling, doContent, doDNS, doStack, noBuild, noCacheInvalidation, siteInfo })
- 
-  return { success : true, userMessage : `Updated '${apexDomain}' site.` }
-}
- 
-export { handleUpdate }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/handle-verify.mjs.html b/qa/coverage/cli/lib/handle-verify.mjs.html deleted file mode 100644 index a0b0dc88..00000000 --- a/qa/coverage/cli/lib/handle-verify.mjs.html +++ /dev/null @@ -1,184 +0,0 @@ - - - - - - Code coverage report for cli/lib/handle-verify.mjs - - - - - - - - - -
-
-

All files / cli/lib handle-verify.mjs

-
- -
- 0% - Statements - 0/26 -
- - -
- 0% - Branches - 0/4 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/22 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { checkFormat } from './check-format'
-import { cliSpec } from '../constants'
-import { getOptionsSpec } from './get-options-spec'
-import { getSiteInfo } from './get-site-info'
-import { verify } from '../../lib/actions/verify'
- 
-const handleVerify = async ({ argv, db }) => {
-  const verifyOptionsSpec = getOptionsSpec({ cliSpec, name : 'verify' })
-  const verifyOptions = commandLineArgs(verifyOptionsSpec, { argv })
-  const { format } = verifyOptions
-  const apexDomain = verifyOptions['apex-domain']
-  const checkContent = verifyOptions['check-content']
-  const checkSiteUp = verifyOptions['check-site-up']
-  const checkStack = verifyOptions['check-stack']
- 
-  checkFormat(format)
- 
-  const siteInfo = getSiteInfo({ apexDomain, db })
- 
-  const results =
-    await verify({ checkContent, checkSiteUp, checkStack, db, siteInfo })
-  const summaryStatus = results.reduce((acc, { status : s }) => {
-    if (s === 'error') { return 'error' } else if (s === 'failed') { return 'failed' } else { return acc }
-  }, 'success')
- 
-  const output = { 'overall status' : summaryStatus, checks : results }
- 
-  return { data : output }
-}
- 
-export { handleVerify }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/index.html b/qa/coverage/cli/lib/index.html deleted file mode 100644 index 24d1cf26..00000000 --- a/qa/coverage/cli/lib/index.html +++ /dev/null @@ -1,416 +0,0 @@ - - - - - - Code coverage report for cli/lib - - - - - - - - - -
-
-

All files cli/lib

-
- -
- 0% - Statements - 0/461 -
- - -
- 0% - Branches - 0/206 -
- - -
- 0% - Functions - 0/37 -
- - -
- 0% - Lines - 0/451 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
check-authentication.mjs -
-
0%0/8100%0/00%0/10%0/8
check-format.mjs -
-
0%0/50%0/30%0/10%0/5
check-reminders.mjs -
-
0%0/140%0/50%0/30%0/14
get-global-options.mjs -
-
0%0/180%0/140%0/10%0/18
get-options-spec.mjs -
-
0%0/70%0/70%0/20%0/6
get-site-info.mjs -
-
0%0/80%0/20%0/10%0/8
get-value-container-and-key.mjs -
-
0%0/250%0/350%0/20%0/25
handle-cleanup.mjs -
-
0%0/320%0/100%0/50%0/30
handle-configuration.mjs -
-
0%0/150%0/50%0/10%0/15
handle-create.mjs -
-
0%0/740%0/300%0/30%0/72
handle-destroy.mjs -
-
0%0/330%0/40%0/10%0/33
handle-detail.mjs -
-
0%0/160%0/10%0/10%0/16
handle-get-iam-policy.mjs -
-
0%0/210%0/60%0/20%0/21
handle-import.mjs -
-
0%0/410%0/220%0/10%0/41
handle-list.mjs -
-
0%0/150%0/40%0/20%0/15
handle-plugin-settings.mjs -
-
0%0/150%0/50%0/10%0/15
handle-update.mjs -
-
0%0/19100%0/00%0/10%0/19
handle-verify.mjs -
-
0%0/260%0/40%0/20%0/22
options.mjs -
-
0%0/420%0/280%0/40%0/41
process-source-type.mjs -
-
0%0/110%0/50%0/10%0/11
smart-convert.mjs -
-
0%0/160%0/160%0/10%0/16
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/options.mjs.html b/qa/coverage/cli/lib/options.mjs.html deleted file mode 100644 index 2a229124..00000000 --- a/qa/coverage/cli/lib/options.mjs.html +++ /dev/null @@ -1,292 +0,0 @@ - - - - - - Code coverage report for cli/lib/options.mjs - - - - - - - - - -
-
-

All files / cli/lib options.mjs

-
- -
- 0% - Statements - 0/42 -
- - -
- 0% - Branches - 0/28 -
- - -
- 0% - Functions - 0/4 -
- - -
- 0% - Lines - 0/41 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { getValueContainerAndKey } from './get-value-container-and-key'
-import * as plugins from '../../lib/plugins'
-import { progressLogger } from '../../lib/shared/progress-logger'
-import { smartConvert } from './smart-convert'I
- 
-const mapRawOptions = (rawOptions = []) =>
-  rawOptions.map((spec) => {
-    let [name, value] = spec.split(/(?!\\):/)
-    value = value?.replaceAll(/\\:/g, ':') || 'true'
-    value = smartConvert(value)
- 
-    return { name, value }
-  })
- 
-const updatePluginSettings = ({ confirmed, doDelete, options, siteInfo }) => {
-  for (const { name, value } of options) {
-    const pathBits = name.split('.')
-    const pluginName = pathBits.shift()
- 
-    const plugin = plugins[pluginName]
-    Iif (plugin === undefined) {
-      throw new Error(`No such plugin '${pluginName}'; use one of: ${Object.keys(plugins).join(', ')}.\n`)
-    }
- 
-    Iif (siteInfo.plugins === undefined) {
-      siteInfo.plugins = {}
-    }
-    const pluginData = siteInfo.plugins[pluginName] || {}
-    siteInfo.plugins[pluginName] = pluginData // in case we just created it
-    const pluginSettings = siteInfo.plugins[pluginName].settings || {}
-    siteInfo.plugins[pluginName].settings = pluginSettings // in case we just created it
-    const spec = plugin.config.options
- 
-    const { valueContainer, valueKey } = getValueContainerAndKey({
-      path           : pathBits,
-      pathPrefix     : pluginName + '.',
-      rootContainer  : pluginSettings,
-      skipValueCheck : doDelete,
-      spec,
-      value
-    })
- 
-    if (doDelete === true && valueKey === undefined) { // then we're deleting/disabling the entire plugin
-      if (confirmed === true) {
-        const pluginSettings = siteInfo.plugins[pluginName]
-        delete siteInfo.plugins[pluginName]
-        progressLogger.write(`Deleted plugin settings for '${pluginName}'; was:\n${JSON.stringify(pluginSettings, null, '  ')}\n`)
-      } else {
-        throw new Error("Interactive confirmation not yet enabled. Use the '--confirmed' option. Note, this will delete all plugin settings and data and cannot be recovered. You must run 'cloudsite update' for this change to take effect. To re-enable the plugin, you must re-initialize all required settings and update the site.\n", 3)
-      }
-    } else if (doDelete === true) {
-      const wasValue = valueContainer[valueKey]
-      delete valueContainer[valueKey]
-      progressLogger.write(`Deleted option '${name}' (was: '${wasValue}').\n`)
-    } else {
-      valueContainer[valueKey] = value
-      progressLogger.write(`Set '${name}' to '${value}'.\n`)
-    }
- 
-    // delete settings object if empty
-    // TODO: this is insufficient if we have a nested option that's empty, we could get something like:
-    // { settings: { blah: {} }}; we need a recursive 'cleanEmptyObjects' or something.
-    Iif (Object.keys(pluginSettings).length === 0) {
-      delete siteInfo.plugins[plugin].settings
-    }
-  }
-}
- 
-export { mapRawOptions, updatePluginSettings }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html deleted file mode 100644 index 742f3dcc..00000000 --- a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-set.mjs.html +++ /dev/null @@ -1,226 +0,0 @@ - - - - - - Code coverage report for cli/lib/plugin-settings/handle-plugin-settings-set.mjs - - - - - - - - - -
-
-

All files / cli/lib/plugin-settings handle-plugin-settings-set.mjs

-
- -
- 0% - Statements - 0/32 -
- - -
- 0% - Branches - 0/29 -
- - -
- 0% - Functions - 0/4 -
- - -
- 0% - Lines - 0/31 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../../constants'
-import { getOptionsSpec } from '../get-options-spec'
-import { getSiteInfo } from '../get-site-info'
-import * as optionsLib from '../options'
-import { smartConvert } from '../smart-convert'I
- 
-const handlePluginSettingsSet = async ({ argv, db }) => {
-  const myOptionsSpec = cliSpec
-    .commands.find(({ name }) => name === 'plugin-settings')
-    .commands.find(({ name }) => name === 'set')
-    .arguments || []
-  const pluginSettingsSetOptionsSpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
-  const pluginSettingsSetOptions = commandLineArgs(pluginSettingsSetOptionsSpec, { argv })
-  const apexDomain = pluginSettingsSetOptions['apex-domain']
-  const options = optionsLib.mapRawOptions(pluginSettingsSetOptions.option)
- 
-  const { confirmed, delete: doDelete, name, value } = pluginSettingsSetOptions
- 
-  // validate options
-  const siteInfo = getSiteInfo({ apexDomain, db })
- 
-  if (doDelete === true && name === undefined && options.length === 0) {
-    throw new Error("You must specify a '--name' or at least one '--option' when '--delete' is set.\n")
-  } else if (name !== undefined && (value !== undefined || doDelete === true)) {
-    options.push({ name, value : smartConvert(value) }) // the 'option' values are already converted
-  } else if (name !== undefined && value === undefined) { // but delete is not set (checked above)
-    throw new Error("You must specify a '--value' or '--delete' when '--name' is set.\n")
-  } else Iif (name === undefined && value !== undefined) {
-    throw new Error("You must specify a '--name' when '--value' is set.\n")
-  }
- 
-  Iif (doDelete !== true && options.length === 0) {
-    throw new Error("Invalid options; specify '--name'+'--value', '--delete'/'--name', or one or more '--option' options.\n")
-  }
- 
-  // take actions and update the options
-  Iif (siteInfo.plugins === undefined) {
-    siteInfo.plugins = {}
-  }
-  optionsLib.updatePluginSettings({ confirmed, doDelete, options, siteInfo })
- 
-  return { success : true, userMessage : `Plugin options updated for ${apexDomain}.` }
-}
- 
-export { handlePluginSettingsSet }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html b/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html deleted file mode 100644 index 5bf88933..00000000 --- a/qa/coverage/cli/lib/plugin-settings/handle-plugin-settings-show.mjs.html +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - Code coverage report for cli/lib/plugin-settings/handle-plugin-settings-show.mjs - - - - - - - - - -
-
-

All files / cli/lib/plugin-settings handle-plugin-settings-show.mjs

-
- -
- 0% - Statements - 0/13 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/13 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import commandLineArgs from 'command-line-args'
- 
-import { cliSpec } from '../../constants'
-import { getOptionsSpec } from '../get-options-spec'
- 
-const handlePluginSettingsShow = async ({ argv, db }) => {
-  const myOptionsSpec = cliSpec
-    .commands.find(({ name }) => name === 'plugin-settings')
-    .commands.find(({ name }) => name === 'show')
-    .arguments || []
-  const handlePluginSettingsShowOptionsSpec = getOptionsSpec({ optionsSpec : myOptionsSpec })
-  const handlePluginSettingsShowOptions = commandLineArgs(handlePluginSettingsShowOptionsSpec, { argv })
-  const apexDomain = handlePluginSettingsShowOptions['apex-domain']
- 
-  const settings = db.sites[apexDomain].plugins
- 
-  return { success : true, data : settings }
-}
- 
-export { handlePluginSettingsShow }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/plugin-settings/index.html b/qa/coverage/cli/lib/plugin-settings/index.html deleted file mode 100644 index 68acfc88..00000000 --- a/qa/coverage/cli/lib/plugin-settings/index.html +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - Code coverage report for cli/lib/plugin-settings - - - - - - - - - -
-
-

All files cli/lib/plugin-settings

-
- -
- 0% - Statements - 0/45 -
- - -
- 0% - Branches - 0/31 -
- - -
- 0% - Functions - 0/7 -
- - -
- 0% - Lines - 0/44 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
handle-plugin-settings-set.mjs -
-
0%0/320%0/290%0/40%0/31
handle-plugin-settings-show.mjs -
-
0%0/130%0/20%0/30%0/13
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/process-source-type.mjs.html b/qa/coverage/cli/lib/process-source-type.mjs.html deleted file mode 100644 index a8f1d842..00000000 --- a/qa/coverage/cli/lib/process-source-type.mjs.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - Code coverage report for cli/lib/process-source-type.mjs - - - - - - - - - -
-
-

All files / cli/lib process-source-type.mjs

-
- -
- 0% - Statements - 0/11 -
- - -
- 0% - Branches - 0/5 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/11 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { existsSync as fileExists } from 'node:fs'
-import { resolve as resolvePath } from 'node:path'
- 
-import { SOURCE_TYPES } from '../constants'
- 
-const processSourceType = ({ sourcePath, sourceType }) => {
-  if (sourceType === undefined) {
-    const docusaurusConfigPath = resolvePath(sourcePath, '..', 'docusaurus.config.js')
-    sourceType = fileExists(docusaurusConfigPath) ? 'docusaurus' : 'vanilla'
-  } else Iif (!SOURCE_TYPES.includes(sourceType)) {
-    throw new Error(`Invalid site source type '${sourceType}'; must be one of ${SOURCE_TYPES.join(', ')}.\n`, 2)
-  }
- 
-  return sourceType
-}
- 
-export { processSourceType }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/cli/lib/smart-convert.mjs.html b/qa/coverage/cli/lib/smart-convert.mjs.html deleted file mode 100644 index 0f930cdf..00000000 --- a/qa/coverage/cli/lib/smart-convert.mjs.html +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - Code coverage report for cli/lib/smart-convert.mjs - - - - - - - - - -
-
-

All files / cli/lib smart-convert.mjs

-
- -
- 0% - Statements - 0/16 -
- - -
- 0% - Branches - 0/16 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/16 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
const smartConvert = (value) => {
-  if (value === undefined) {
-    return ''
-  } else if (value === 'true' || value === 'TRUE') {
-    return true
-  } else if (value === 'false' || value === 'FALSE') {
-    return false
-  } else if (value.match(/^\s*\d+\s*$/)) {
-    return parseInt(value)
-  } else if (value.match(/^\s*(?:\d+(?:\.\d+)|\.\d+)\s*$/)) {
-    return parseFloat(value)
-  } else {
-    value = value.trim()
-    if (value.startsWith('\\')) {
-      return value.slice(1)
-    } else {
-      return value
-    }
-  }
-}
- 
-export { smartConvert }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/clover.xml b/qa/coverage/clover.xml deleted file mode 100644 index 9be49383..00000000 --- a/qa/coverage/clover.xml +++ /dev/null @@ -1,1635 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/qa/coverage/coverage-final.json b/qa/coverage/coverage-final.json deleted file mode 100644 index 7b0367e7..00000000 --- a/qa/coverage/coverage-final.json +++ /dev/null @@ -1,62 +0,0 @@ -{"/Users/zane/playground/cloudsite/src/cli/cloudsite.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/cloudsite.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"9":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"10":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"11":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"12":{"start":{"line":15,"column":0},"end":{"line":15,"column":null}},"13":{"start":{"line":16,"column":0},"end":{"line":16,"column":null}},"14":{"start":{"line":17,"column":0},"end":{"line":17,"column":null}},"15":{"start":{"line":18,"column":0},"end":{"line":18,"column":null}},"16":{"start":{"line":19,"column":0},"end":{"line":19,"column":null}},"17":{"start":{"line":20,"column":0},"end":{"line":20,"column":null}},"18":{"start":{"line":21,"column":0},"end":{"line":21,"column":50}},"19":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"20":{"start":{"line":23,"column":18},"end":{"line":145,"column":1}},"21":{"start":{"line":25,"column":22},"end":{"line":25,"column":89}},"22":{"start":{"line":26,"column":15},"end":{"line":26,"column":41}},"23":{"start":{"line":28,"column":34},"end":{"line":28,"column":45}},"24":{"start":{"line":29,"column":22},"end":{"line":29,"column":49}},"25":{"start":{"line":32,"column":2},"end":{"line":41,"column":null}},"26":{"start":{"line":33,"column":23},"end":{"line":33,"column":72}},"27":{"start":{"line":34,"column":4},"end":{"line":34,"column":null}},"28":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"29":{"start":{"line":37,"column":6},"end":{"line":37,"column":null}},"30":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"31":{"start":{"line":43,"column":24},"end":{"line":43,"column":48}},"32":{"start":{"line":44,"column":21},"end":{"line":44,"column":34}},"33":{"start":{"line":45,"column":21},"end":{"line":45,"column":49}},"34":{"start":{"line":46,"column":21},"end":{"line":46,"column":49}},"35":{"start":{"line":48,"column":2},"end":{"line":48,"column":null}},"36":{"start":{"line":50,"column":2},"end":{"line":52,"column":null}},"37":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"38":{"start":{"line":54,"column":17},"end":{"line":54,"column":36}},"39":{"start":{"line":57,"column":17},"end":{"line":57,"column":18}},"40":{"start":{"line":60,"column":2},"end":{"line":110,"column":null}},"41":{"start":{"line":61,"column":4},"end":{"line":94,"column":null}},"42":{"start":{"line":63,"column":8},"end":{"line":63,"column":72}},"43":{"start":{"line":63,"column":72},"end":{"line":63,"column":null}},"44":{"start":{"line":65,"column":8},"end":{"line":65,"column":84}},"45":{"start":{"line":65,"column":84},"end":{"line":65,"column":null}},"46":{"start":{"line":67,"column":8},"end":{"line":67,"column":71}},"47":{"start":{"line":67,"column":71},"end":{"line":67,"column":null}},"48":{"start":{"line":69,"column":8},"end":{"line":69,"column":72}},"49":{"start":{"line":69,"column":72},"end":{"line":69,"column":null}},"50":{"start":{"line":71,"column":8},"end":{"line":71,"column":64}},"51":{"start":{"line":71,"column":64},"end":{"line":71,"column":null}},"52":{"start":{"line":73,"column":8},"end":{"line":73,"column":null}},"53":{"start":{"line":74,"column":8},"end":{"line":74,"column":null}},"54":{"start":{"line":75,"column":8},"end":{"line":75,"column":null}},"55":{"start":{"line":76,"column":8},"end":{"line":76,"column":null}},"56":{"start":{"line":78,"column":8},"end":{"line":78,"column":null}},"57":{"start":{"line":79,"column":8},"end":{"line":79,"column":15}},"58":{"start":{"line":81,"column":8},"end":{"line":81,"column":62}},"59":{"start":{"line":81,"column":62},"end":{"line":81,"column":null}},"60":{"start":{"line":83,"column":8},"end":{"line":83,"column":71}},"61":{"start":{"line":83,"column":71},"end":{"line":83,"column":null}},"62":{"start":{"line":85,"column":8},"end":{"line":85,"column":85}},"63":{"start":{"line":85,"column":85},"end":{"line":85,"column":null}},"64":{"start":{"line":87,"column":8},"end":{"line":87,"column":71}},"65":{"start":{"line":87,"column":71},"end":{"line":87,"column":null}},"66":{"start":{"line":89,"column":8},"end":{"line":89,"column":55}},"67":{"start":{"line":89,"column":55},"end":{"line":89,"column":null}},"68":{"start":{"line":91,"column":8},"end":{"line":91,"column":null}},"69":{"start":{"line":92,"column":8},"end":{"line":92,"column":null}},"70":{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},"71":{"start":{"line":97,"column":6},"end":{"line":97,"column":null}},"72":{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},"73":{"start":{"line":99,"column":6},"end":{"line":99,"column":null}},"74":{"start":{"line":100,"column":6},"end":{"line":102,"column":null}},"75":{"start":{"line":101,"column":8},"end":{"line":101,"column":null}},"76":{"start":{"line":103,"column":6},"end":{"line":103,"column":null}},"77":{"start":{"line":105,"column":6},"end":{"line":105,"column":null}},"78":{"start":{"line":106,"column":6},"end":{"line":106,"column":null}},"79":{"start":{"line":109,"column":4},"end":{"line":109,"column":null}},"80":{"start":{"line":112,"column":2},"end":{"line":112,"column":30}},"81":{"start":{"line":114,"column":23},"end":{"line":118,"column":3}},"82":{"start":{"line":120,"column":2},"end":{"line":122,"column":null}},"83":{"start":{"line":121,"column":4},"end":{"line":121,"column":null}},"84":{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},"85":{"start":{"line":126,"column":4},"end":{"line":126,"column":null}},"86":{"start":{"line":128,"column":4},"end":{"line":130,"column":null}},"87":{"start":{"line":129,"column":6},"end":{"line":129,"column":null}},"88":{"start":{"line":132,"column":4},"end":{"line":141,"column":null}},"89":{"start":{"line":133,"column":38},"end":{"line":133,"column":50}},"90":{"start":{"line":134,"column":20},"end":{"line":134,"column":31}},"91":{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},"92":{"start":{"line":136,"column":8},"end":{"line":136,"column":null}},"93":{"start":{"line":137,"column":13},"end":{"line":139,"column":null}},"94":{"start":{"line":138,"column":8},"end":{"line":138,"column":null}},"95":{"start":{"line":140,"column":6},"end":{"line":140,"column":null}},"96":{"start":{"line":144,"column":2},"end":{"line":144,"column":25}},"97":{"start":{"line":145,"column":1},"end":{"line":145,"column":null}},"98":{"start":{"line":147,"column":32},"end":{"line":152,"column":1}},"99":{"start":{"line":148,"column":2},"end":{"line":151,"column":null}},"100":{"start":{"line":149,"column":23},"end":{"line":149,"column":53}},"101":{"start":{"line":150,"column":4},"end":{"line":150,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":23,"column":18},"end":{"line":23,"column":30}},"loc":{"start":{"line":23,"column":30},"end":{"line":145,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":147,"column":32},"end":{"line":147,"column":39}},"loc":{"start":{"line":147,"column":58},"end":{"line":152,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"1":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"cond-expr","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"2":{"loc":{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},"type":"binary-expr","locations":[{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}},{"start":{"line":21,"column":50},"end":{"line":21,"column":null}}]},"3":{"loc":{"start":{"line":26,"column":15},"end":{"line":26,"column":41}},"type":"binary-expr","locations":[{"start":{"line":26,"column":15},"end":{"line":26,"column":35}},{"start":{"line":26,"column":39},"end":{"line":26,"column":41}}]},"4":{"loc":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":4},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":50,"column":2},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":50,"column":2},"end":{"line":52,"column":null}}]},"6":{"loc":{"start":{"line":61,"column":4},"end":{"line":94,"column":null}},"type":"switch","locations":[{"start":{"line":62,"column":6},"end":{"line":63,"column":null}},{"start":{"line":64,"column":6},"end":{"line":65,"column":null}},{"start":{"line":66,"column":6},"end":{"line":67,"column":null}},{"start":{"line":68,"column":6},"end":{"line":69,"column":null}},{"start":{"line":70,"column":6},"end":{"line":71,"column":null}},{"start":{"line":72,"column":6},"end":{"line":76,"column":null}},{"start":{"line":77,"column":6},"end":{"line":79,"column":15}},{"start":{"line":80,"column":6},"end":{"line":81,"column":null}},{"start":{"line":82,"column":6},"end":{"line":83,"column":null}},{"start":{"line":84,"column":6},"end":{"line":85,"column":null}},{"start":{"line":86,"column":6},"end":{"line":87,"column":null}},{"start":{"line":88,"column":6},"end":{"line":89,"column":null}},{"start":{"line":90,"column":6},"end":{"line":92,"column":null}}]},"7":{"loc":{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":96,"column":4},"end":{"line":107,"column":null}},{"start":{"line":98,"column":11},"end":{"line":107,"column":null}}]},"8":{"loc":{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":98,"column":11},"end":{"line":107,"column":null}},{"start":{"line":104,"column":11},"end":{"line":107,"column":null}}]},"9":{"loc":{"start":{"line":100,"column":6},"end":{"line":102,"column":null}},"type":"if","locations":[{"start":{"line":100,"column":6},"end":{"line":102,"column":null}}]},"10":{"loc":{"start":{"line":106,"column":17},"end":{"line":106,"column":33}},"type":"binary-expr","locations":[{"start":{"line":106,"column":17},"end":{"line":106,"column":27}},{"start":{"line":106,"column":31},"end":{"line":106,"column":33}}]},"11":{"loc":{"start":{"line":115,"column":14},"end":{"line":115,"column":48}},"type":"binary-expr","locations":[{"start":{"line":115,"column":14},"end":{"line":115,"column":28}},{"start":{"line":115,"column":32},"end":{"line":115,"column":48}}]},"12":{"loc":{"start":{"line":116,"column":14},"end":{"line":116,"column":83}},"type":"cond-expr","locations":[{"start":{"line":116,"column":31},"end":{"line":116,"column":38}},{"start":{"line":116,"column":42},"end":{"line":116,"column":83}}]},"13":{"loc":{"start":{"line":116,"column":42},"end":{"line":116,"column":83}},"type":"cond-expr","locations":[{"start":{"line":116,"column":61},"end":{"line":116,"column":70}},{"start":{"line":116,"column":73},"end":{"line":116,"column":83}}]},"14":{"loc":{"start":{"line":120,"column":2},"end":{"line":122,"column":null}},"type":"if","locations":[{"start":{"line":120,"column":2},"end":{"line":122,"column":null}}]},"15":{"loc":{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},"type":"if","locations":[{"start":{"line":125,"column":2},"end":{"line":142,"column":null}},{"start":{"line":127,"column":9},"end":{"line":142,"column":null}}]},"16":{"loc":{"start":{"line":125,"column":6},"end":{"line":125,"column":44}},"type":"binary-expr","locations":[{"start":{"line":125,"column":6},"end":{"line":125,"column":23}},{"start":{"line":125,"column":27},"end":{"line":125,"column":44}}]},"17":{"loc":{"start":{"line":128,"column":4},"end":{"line":130,"column":null}},"type":"if","locations":[{"start":{"line":128,"column":4},"end":{"line":130,"column":null}}]},"18":{"loc":{"start":{"line":132,"column":4},"end":{"line":141,"column":null}},"type":"if","locations":[{"start":{"line":132,"column":4},"end":{"line":141,"column":null}}]},"19":{"loc":{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":135,"column":6},"end":{"line":139,"column":null}},{"start":{"line":137,"column":13},"end":{"line":139,"column":null}}]},"20":{"loc":{"start":{"line":137,"column":13},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":137,"column":13},"end":{"line":139,"column":null}}]},"21":{"loc":{"start":{"line":148,"column":2},"end":{"line":151,"column":null}},"type":"if","locations":[{"start":{"line":148,"column":2},"end":{"line":151,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0],"5":[0],"6":[0,0,0,0,0,0,0,0,0,0,0,0,0],"7":[0,0],"8":[0,0],"9":[0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0],"15":[0,0],"16":[0,0],"17":[0],"18":[0],"19":[0,0],"20":[0],"21":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/constants.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/constants.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":35}},"1":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"2":{"start":{"line":3,"column":18},"end":{"line":3,"column":46}},"3":{"start":{"line":5,"column":19},"end":{"line":5,"column":58}},"4":{"start":{"line":7,"column":13},"end":{"line":7,"column":90}},"5":{"start":{"line":9,"column":23},"end":{"line":31,"column":null}},"6":{"start":{"line":34,"column":19},"end":{"line":38,"column":1}},"7":{"start":{"line":40,"column":26},"end":{"line":43,"column":1}},"8":{"start":{"line":45,"column":13},"end":{"line":346,"column":1}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"if","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]},"1":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]},"2":{"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},"type":"binary-expr","locations":[{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}},{"start":{"line":1,"column":35},"end":{"line":1,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0},"f":{"0":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/check-authentication.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-authentication.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":71}},"2":{"start":{"line":5,"column":28},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":22},"end":{"line":6,"column":57}},"4":{"start":{"line":8,"column":19},"end":{"line":8,"column":48}},"5":{"start":{"line":9,"column":29},"end":{"line":9,"column":55}},"6":{"start":{"line":10,"column":2},"end":{"line":10,"column":42}},"7":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":28},"end":{"line":5,"column":35}},"loc":{"start":{"line":5,"column":46},"end":{"line":11,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/cli/lib/check-format.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-format.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":21},"end":{"line":7,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":6,"column":null}},"3":{"start":{"line":5,"column":4},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":1},"end":{"line":7,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":21},"end":{"line":3,"column":27}},"loc":{"start":{"line":3,"column":32},"end":{"line":7,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":2},"end":{"line":6,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":2},"end":{"line":6,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":6},"end":{"line":4,"column":61}},"type":"binary-expr","locations":[{"start":{"line":4,"column":6},"end":{"line":4,"column":26}},{"start":{"line":4,"column":30},"end":{"line":4,"column":61}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0},"f":{"0":0},"b":{"0":[0],"1":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/check-reminders.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/check-reminders.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":21,"column":1}},"2":{"start":{"line":4,"column":14},"end":{"line":4,"column":34}},"3":{"start":{"line":5,"column":27},"end":{"line":8,"column":4}},"4":{"start":{"line":6,"column":29},"end":{"line":6,"column":52}},"5":{"start":{"line":7,"column":4},"end":{"line":7,"column":null}},"6":{"start":{"line":10,"column":2},"end":{"line":20,"column":null}},"7":{"start":{"line":11,"column":24},"end":{"line":11,"column":50}},"8":{"start":{"line":12,"column":19},"end":{"line":12,"column":91}},"9":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"10":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"13":{"start":{"line":21,"column":1},"end":{"line":21,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":42},"end":{"line":21,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":5,"column":44},"end":{"line":5,"column":45}},"loc":{"start":{"line":5,"column":65},"end":{"line":8,"column":3}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":15,"column":29},"end":{"line":15,"column":30}},"loc":{"start":{"line":15,"column":46},"end":{"line":17,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":2},"end":{"line":20,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":2},"end":{"line":20,"column":null}}]},"1":{"loc":{"start":{"line":12,"column":49},"end":{"line":12,"column":90}},"type":"cond-expr","locations":[{"start":{"line":12,"column":80},"end":{"line":12,"column":84}},{"start":{"line":12,"column":87},"end":{"line":12,"column":90}}]},"2":{"loc":{"start":{"line":16,"column":28},"end":{"line":16,"column":70}},"type":"cond-expr","locations":[{"start":{"line":16,"column":58},"end":{"line":16,"column":65}},{"start":{"line":16,"column":68},"end":{"line":16,"column":70}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/get-global-options.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-global-options.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":25},"end":{"line":32,"column":1}},"4":{"start":{"line":9,"column":2},"end":{"line":11,"column":3}},"5":{"start":{"line":10,"column":4},"end":{"line":10,"column":null}},"6":{"start":{"line":13,"column":25},"end":{"line":13,"column":52}},"7":{"start":{"line":15,"column":26},"end":{"line":15,"column":80}},"8":{"start":{"line":16,"column":2},"end":{"line":16,"column":34}},"9":{"start":{"line":18,"column":24},"end":{"line":18,"column":74}},"10":{"start":{"line":20,"column":30},"end":{"line":20,"column":43}},"11":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"12":{"start":{"line":24,"column":18},"end":{"line":24,"column":31}},"13":{"start":{"line":26,"column":2},"end":{"line":26,"column":null}},"14":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"15":{"start":{"line":29,"column":2},"end":{"line":29,"column":null}},"16":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"17":{"start":{"line":32,"column":1},"end":{"line":32,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":25},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":37},"end":{"line":32,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":2},"end":{"line":11,"column":3}},"type":"if","locations":[{"start":{"line":9,"column":2},"end":{"line":11,"column":3}}]},"1":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":52}},"type":"binary-expr","locations":[{"start":{"line":13,"column":25},"end":{"line":13,"column":46}},{"start":{"line":13,"column":50},"end":{"line":13,"column":52}}]},"2":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":46}},"type":"cond-expr","locations":[{"start":{"line":13,"column":36},"end":{"line":13,"column":38}},{"start":{"line":13,"column":25},"end":{"line":13,"column":46}}]},"3":{"loc":{"start":{"line":13,"column":25},"end":{"line":13,"column":38}},"type":"binary-expr","locations":[{"start":{"line":13,"column":25},"end":{"line":13,"column":29}},{"start":{"line":13,"column":25},"end":{"line":13,"column":29}},{"start":{"line":13,"column":27},"end":{"line":13,"column":38}},{"start":{"line":13,"column":36},"end":{"line":13,"column":38}}]},"4":{"loc":{"start":{"line":26,"column":10},"end":{"line":26,"column":105}},"type":"binary-expr","locations":[{"start":{"line":26,"column":10},"end":{"line":26,"column":15}},{"start":{"line":26,"column":20},"end":{"line":26,"column":36}},{"start":{"line":26,"column":41},"end":{"line":26,"column":58}},{"start":{"line":26,"column":62},"end":{"line":26,"column":79}},{"start":{"line":26,"column":83},"end":{"line":26,"column":103}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0,0,0,0],"4":[0,0,0,0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/get-options-spec.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-options-spec.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":13,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":4,"column":null}},"3":{"start":{"line":4,"column":79},"end":{"line":4,"column":96}},"4":{"start":{"line":6,"column":4},"end":{"line":9,"column":null}},"5":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"6":{"start":{"line":13,"column":1},"end":{"line":13,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":59},"end":{"line":13,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":4,"column":54},"end":{"line":4,"column":55}},"loc":{"start":{"line":4,"column":79},"end":{"line":4,"column":96}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":16},"end":{"line":4,"column":113}},"type":"binary-expr","locations":[{"start":{"line":4,"column":16},"end":{"line":4,"column":27}},{"start":{"line":4,"column":31},"end":{"line":4,"column":107}},{"start":{"line":4,"column":111},"end":{"line":4,"column":113}}]},"1":{"loc":{"start":{"line":4,"column":31},"end":{"line":4,"column":107}},"type":"cond-expr","locations":[{"start":{"line":4,"column":38},"end":{"line":4,"column":40}},{"start":{"line":4,"column":31},"end":{"line":4,"column":107}}]},"2":{"loc":{"start":{"line":4,"column":31},"end":{"line":4,"column":40}},"type":"binary-expr","locations":[{"start":{"line":4,"column":31},"end":{"line":4,"column":40}},{"start":{"line":4,"column":31},"end":{"line":4,"column":40}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"f":{"0":0,"1":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/get-site-info.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-site-info.mjs","statementMap":{"0":{"start":{"line":1,"column":20},"end":{"line":12,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":4,"column":null}},"2":{"start":{"line":3,"column":4},"end":{"line":3,"column":null}},"3":{"start":{"line":6,"column":19},"end":{"line":6,"column":39}},"4":{"start":{"line":7,"column":2},"end":{"line":9,"column":null}},"5":{"start":{"line":8,"column":4},"end":{"line":8,"column":null}},"6":{"start":{"line":11,"column":2},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":1},"end":{"line":12,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":20},"end":{"line":1,"column":21}},"loc":{"start":{"line":1,"column":44},"end":{"line":12,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":4,"column":null}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":4,"column":null}}]},"1":{"loc":{"start":{"line":7,"column":2},"end":{"line":9,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":2},"end":{"line":9,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{"0":[0],"1":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/get-value-container-and-key.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/get-value-container-and-key.mjs","statementMap":{"0":{"start":{"line":1,"column":32},"end":{"line":46,"column":1}},"1":{"start":{"line":2,"column":19},"end":{"line":2,"column":80}},"2":{"start":{"line":3,"column":2},"end":{"line":5,"column":null}},"3":{"start":{"line":4,"column":4},"end":{"line":4,"column":null}},"4":{"start":{"line":7,"column":2},"end":{"line":45,"column":null}},"5":{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},"6":{"start":{"line":10,"column":6},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},"8":{"start":{"line":12,"column":40},"end":{"line":12,"column":48}},"9":{"start":{"line":13,"column":8},"end":{"line":18,"column":null}},"10":{"start":{"line":14,"column":10},"end":{"line":17,"column":null}},"11":{"start":{"line":19,"column":8},"end":{"line":24,"column":null}},"12":{"start":{"line":20,"column":10},"end":{"line":23,"column":null}},"13":{"start":{"line":26,"column":8},"end":{"line":28,"column":null}},"14":{"start":{"line":27,"column":10},"end":{"line":27,"column":null}},"15":{"start":{"line":30,"column":8},"end":{"line":30,"column":null}},"16":{"start":{"line":33,"column":6},"end":{"line":33,"column":null}},"17":{"start":{"line":35,"column":23},"end":{"line":35,"column":34}},"18":{"start":{"line":36,"column":6},"end":{"line":38,"column":null}},"19":{"start":{"line":37,"column":8},"end":{"line":37,"column":null}},"20":{"start":{"line":39,"column":24},"end":{"line":39,"column":42}},"21":{"start":{"line":40,"column":6},"end":{"line":42,"column":null}},"22":{"start":{"line":41,"column":8},"end":{"line":41,"column":null}},"23":{"start":{"line":43,"column":6},"end":{"line":43,"column":null}},"24":{"start":{"line":46,"column":1},"end":{"line":46,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":32},"end":{"line":1,"column":33}},"loc":{"start":{"line":1,"column":102},"end":{"line":46,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":7,"column":21},"end":{"line":7,"column":22}},"loc":{"start":{"line":7,"column":60},"end":{"line":45,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":20},"end":{"line":2,"column":62}},"type":"cond-expr","locations":[{"start":{"line":2,"column":47},"end":{"line":2,"column":49}},{"start":{"line":2,"column":52},"end":{"line":2,"column":62}}]},"1":{"loc":{"start":{"line":3,"column":2},"end":{"line":5,"column":null}},"type":"if","locations":[{"start":{"line":3,"column":2},"end":{"line":5,"column":null}}]},"2":{"loc":{"start":{"line":3,"column":6},"end":{"line":3,"column":45}},"type":"binary-expr","locations":[{"start":{"line":3,"column":6},"end":{"line":3,"column":24}},{"start":{"line":3,"column":28},"end":{"line":3,"column":45}}]},"3":{"loc":{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":4},"end":{"line":44,"column":null}},{"start":{"line":34,"column":11},"end":{"line":44,"column":null}}]},"4":{"loc":{"start":{"line":10,"column":14},"end":{"line":10,"column":32}},"type":"cond-expr","locations":[{"start":{"line":10,"column":25},"end":{"line":10,"column":28}},{"start":{"line":10,"column":17},"end":{"line":10,"column":32}}]},"5":{"loc":{"start":{"line":10,"column":14},"end":{"line":10,"column":28}},"type":"binary-expr","locations":[{"start":{"line":10,"column":14},"end":{"line":10,"column":28}},{"start":{"line":10,"column":25},"end":{"line":10,"column":28}}]},"6":{"loc":{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":6},"end":{"line":31,"column":null}},{"start":{"line":29,"column":13},"end":{"line":31,"column":null}}]},"7":{"loc":{"start":{"line":13,"column":8},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":8},"end":{"line":18,"column":null}}]},"8":{"loc":{"start":{"line":13,"column":12},"end":{"line":13,"column":61}},"type":"binary-expr","locations":[{"start":{"line":13,"column":12},"end":{"line":13,"column":36}},{"start":{"line":13,"column":40},"end":{"line":13,"column":61}}]},"9":{"loc":{"start":{"line":19,"column":8},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":8},"end":{"line":24,"column":null}}]},"10":{"loc":{"start":{"line":19,"column":12},"end":{"line":19,"column":67}},"type":"binary-expr","locations":[{"start":{"line":19,"column":12},"end":{"line":19,"column":33}},{"start":{"line":19,"column":37},"end":{"line":19,"column":67}}]},"11":{"loc":{"start":{"line":19,"column":37},"end":{"line":19,"column":58}},"type":"cond-expr","locations":[{"start":{"line":19,"column":42},"end":{"line":19,"column":44}},{"start":{"line":19,"column":37},"end":{"line":19,"column":58}}]},"12":{"loc":{"start":{"line":19,"column":37},"end":{"line":19,"column":44}},"type":"binary-expr","locations":[{"start":{"line":19,"column":37},"end":{"line":19,"column":44}},{"start":{"line":19,"column":37},"end":{"line":19,"column":44}}]},"13":{"loc":{"start":{"line":26,"column":8},"end":{"line":28,"column":null}},"type":"if","locations":[{"start":{"line":26,"column":8},"end":{"line":28,"column":null}}]},"14":{"loc":{"start":{"line":26,"column":12},"end":{"line":26,"column":85}},"type":"binary-expr","locations":[{"start":{"line":26,"column":12},"end":{"line":26,"column":35}},{"start":{"line":26,"column":39},"end":{"line":26,"column":63}},{"start":{"line":26,"column":67},"end":{"line":26,"column":85}}]},"15":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":34}},"type":"cond-expr","locations":[{"start":{"line":35,"column":27},"end":{"line":35,"column":30}},{"start":{"line":35,"column":23},"end":{"line":35,"column":34}}]},"16":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":30}},"type":"binary-expr","locations":[{"start":{"line":35,"column":23},"end":{"line":35,"column":30}},{"start":{"line":35,"column":23},"end":{"line":35,"column":30}}]},"17":{"loc":{"start":{"line":36,"column":6},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":6},"end":{"line":38,"column":null}}]},"18":{"loc":{"start":{"line":36,"column":10},"end":{"line":36,"column":41}},"type":"binary-expr","locations":[{"start":{"line":36,"column":10},"end":{"line":36,"column":32}},{"start":{"line":36,"column":36},"end":{"line":36,"column":41}}]},"19":{"loc":{"start":{"line":40,"column":6},"end":{"line":42,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":6},"end":{"line":42,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0,0],"9":[0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0],"14":[0,0,0],"15":[0,0],"16":[0,0],"17":[0],"18":[0,0],"19":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-cleanup.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-cleanup.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":22},"end":{"line":48,"column":1}},"6":{"start":{"line":9,"column":29},"end":{"line":9,"column":74}},"7":{"start":{"line":10,"column":25},"end":{"line":10,"column":70}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":50}},"9":{"start":{"line":12,"column":19},"end":{"line":12,"column":33}},"10":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"11":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"12":{"start":{"line":18,"column":31},"end":{"line":20,"column":18}},"13":{"start":{"line":22,"column":24},"end":{"line":26,"column":6}},"14":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"15":{"start":{"line":25,"column":6},"end":{"line":25,"column":null}},"16":{"start":{"line":28,"column":2},"end":{"line":28,"column":null}},"17":{"start":{"line":29,"column":21},"end":{"line":29,"column":71}},"18":{"start":{"line":29,"column":39},"end":{"line":29,"column":64}},"19":{"start":{"line":30,"column":25},"end":{"line":30,"column":57}},"20":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"21":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"22":{"start":{"line":34,"column":2},"end":{"line":41,"column":null}},"23":{"start":{"line":35,"column":26},"end":{"line":35,"column":43}},"24":{"start":{"line":36,"column":4},"end":{"line":36,"column":null}},"25":{"start":{"line":37,"column":4},"end":{"line":40,"column":null}},"26":{"start":{"line":38,"column":6},"end":{"line":38,"column":null}},"27":{"start":{"line":39,"column":6},"end":{"line":39,"column":null}},"28":{"start":{"line":39,"column":81},"end":{"line":39,"column":106}},"29":{"start":{"line":43,"column":22},"end":{"line":45,"column":84}},"30":{"start":{"line":47,"column":2},"end":{"line":47,"column":null}},"31":{"start":{"line":48,"column":1},"end":{"line":48,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":22},"end":{"line":8,"column":29}},"loc":{"start":{"line":8,"column":46},"end":{"line":48,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":23,"column":10},"end":{"line":23,"column":20}},"loc":{"start":{"line":23,"column":25},"end":{"line":26,"column":5}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":29,"column":33},"end":{"line":29,"column":39}},"loc":{"start":{"line":29,"column":39},"end":{"line":29,"column":64}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":34,"column":31},"end":{"line":34,"column":32}},"loc":{"start":{"line":34,"column":50},"end":{"line":41,"column":3}}},"4":{"name":"(anonymous_4)","decl":{"start":{"line":39,"column":49},"end":{"line":39,"column":50}},"loc":{"start":{"line":39,"column":81},"end":{"line":39,"column":106}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":16,"column":null}}]},"1":{"loc":{"start":{"line":15,"column":20},"end":{"line":15,"column":52}},"type":"binary-expr","locations":[{"start":{"line":15,"column":20},"end":{"line":15,"column":45}},{"start":{"line":15,"column":49},"end":{"line":15,"column":52}}]},"2":{"loc":{"start":{"line":18,"column":31},"end":{"line":20,"column":18}},"type":"cond-expr","locations":[{"start":{"line":19,"column":6},"end":{"line":19,"column":31}},{"start":{"line":20,"column":6},"end":{"line":20,"column":18}}]},"3":{"loc":{"start":{"line":36,"column":43},"end":{"line":36,"column":94}},"type":"cond-expr","locations":[{"start":{"line":36,"column":68},"end":{"line":36,"column":77}},{"start":{"line":36,"column":80},"end":{"line":36,"column":94}}]},"4":{"loc":{"start":{"line":37,"column":4},"end":{"line":40,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":4},"end":{"line":40,"column":null}}]},"5":{"loc":{"start":{"line":43,"column":22},"end":{"line":45,"column":84}},"type":"cond-expr","locations":[{"start":{"line":44,"column":7},"end":{"line":44,"column":72}},{"start":{"line":45,"column":7},"end":{"line":45,"column":84}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0],"5":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-configuration.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-configuration.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":22,"column":1}},"6":{"start":{"line":9,"column":35},"end":{"line":9,"column":86}},"7":{"start":{"line":10,"column":31},"end":{"line":10,"column":109}},"8":{"start":{"line":11,"column":25},"end":{"line":11,"column":45}},"9":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"10":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":8,"column":52},"end":{"line":22,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":9},"end":{"line":12,"column":44}},"type":"binary-expr","locations":[{"start":{"line":12,"column":9},"end":{"line":12,"column":38}},{"start":{"line":12,"column":42},"end":{"line":12,"column":44}}]},"1":{"loc":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"type":"switch","locations":[{"start":{"line":15,"column":4},"end":{"line":16,"column":null}},{"start":{"line":17,"column":4},"end":{"line":18,"column":null}},{"start":{"line":19,"column":4},"end":{"line":20,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-create.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-create.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"9":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"10":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"11":{"start":{"line":14,"column":0},"end":{"line":14,"column":65}},"12":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"13":{"start":{"line":16,"column":21},"end":{"line":128,"column":1}},"14":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"15":{"start":{"line":19,"column":28},"end":{"line":19,"column":72}},"16":{"start":{"line":20,"column":24},"end":{"line":20,"column":68}},"17":{"start":{"line":22,"column":28},"end":{"line":22,"column":65}},"18":{"start":{"line":24,"column":19},"end":{"line":24,"column":47}},"19":{"start":{"line":25,"column":21},"end":{"line":25,"column":49}},"20":{"start":{"line":26,"column":18},"end":{"line":26,"column":43}},"21":{"start":{"line":27,"column":24},"end":{"line":27,"column":55}},"22":{"start":{"line":29,"column":19},"end":{"line":29,"column":47}},"23":{"start":{"line":30,"column":19},"end":{"line":30,"column":47}},"24":{"start":{"line":31,"column":18},"end":{"line":31,"column":45}},"25":{"start":{"line":32,"column":18},"end":{"line":32,"column":64}},"26":{"start":{"line":34,"column":2},"end":{"line":48,"column":null}},"27":{"start":{"line":35,"column":32},"end":{"line":35,"column":72}},"28":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"29":{"start":{"line":37,"column":6},"end":{"line":37,"column":null}},"30":{"start":{"line":39,"column":4},"end":{"line":41,"column":null}},"31":{"start":{"line":40,"column":6},"end":{"line":40,"column":null}},"32":{"start":{"line":42,"column":4},"end":{"line":47,"column":null}},"33":{"start":{"line":43,"column":25},"end":{"line":43,"column":89}},"34":{"start":{"line":44,"column":6},"end":{"line":44,"column":null}},"35":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"36":{"start":{"line":49,"column":2},"end":{"line":49,"column":null}},"37":{"start":{"line":52,"column":19},"end":{"line":52,"column":93}},"38":{"start":{"line":53,"column":2},"end":{"line":53,"column":null}},"39":{"start":{"line":54,"column":2},"end":{"line":56,"column":null}},"40":{"start":{"line":55,"column":4},"end":{"line":55,"column":null}},"41":{"start":{"line":58,"column":2},"end":{"line":58,"column":null}},"42":{"start":{"line":61,"column":2},"end":{"line":66,"column":null}},"43":{"start":{"line":62,"column":4},"end":{"line":65,"column":null}},"44":{"start":{"line":63,"column":6},"end":{"line":63,"column":null}},"45":{"start":{"line":69,"column":2},"end":{"line":69,"column":null}},"46":{"start":{"line":71,"column":2},"end":{"line":74,"column":null}},"47":{"start":{"line":73,"column":4},"end":{"line":73,"column":null}},"48":{"start":{"line":76,"column":2},"end":{"line":109,"column":null}},"49":{"start":{"line":77,"column":4},"end":{"line":108,"column":null}},"50":{"start":{"line":78,"column":60},"end":{"line":78,"column":66}},"51":{"start":{"line":79,"column":34},"end":{"line":84,"column":7}},"52":{"start":{"line":85,"column":25},"end":{"line":85,"column":89}},"53":{"start":{"line":86,"column":6},"end":{"line":86,"column":null}},"54":{"start":{"line":87,"column":21},"end":{"line":87,"column":67}},"55":{"start":{"line":89,"column":6},"end":{"line":107,"column":null}},"56":{"start":{"line":90,"column":36},"end":{"line":90,"column":52}},"57":{"start":{"line":91,"column":8},"end":{"line":103,"column":null}},"58":{"start":{"line":92,"column":109},"end":{"line":92,"column":119}},"59":{"start":{"line":93,"column":31},"end":{"line":101,"column":11}},"60":{"start":{"line":102,"column":10},"end":{"line":102,"column":null}},"61":{"start":{"line":104,"column":27},"end":{"line":104,"column":91}},"62":{"start":{"line":105,"column":8},"end":{"line":105,"column":null}},"63":{"start":{"line":106,"column":8},"end":{"line":106,"column":null}},"64":{"start":{"line":106,"column":74},"end":{"line":106,"column":116}},"65":{"start":{"line":111,"column":2},"end":{"line":111,"column":null}},"66":{"start":{"line":114,"column":2},"end":{"line":118,"column":null}},"67":{"start":{"line":115,"column":4},"end":{"line":117,"column":null}},"68":{"start":{"line":116,"column":6},"end":{"line":116,"column":null}},"69":{"start":{"line":121,"column":2},"end":{"line":121,"column":null}},"70":{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},"71":{"start":{"line":124,"column":4},"end":{"line":124,"column":null}},"72":{"start":{"line":126,"column":4},"end":{"line":126,"column":null}},"73":{"start":{"line":128,"column":1},"end":{"line":128,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":16,"column":21},"end":{"line":16,"column":28}},"loc":{"start":{"line":16,"column":45},"end":{"line":128,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":106,"column":47},"end":{"line":106,"column":48}},"loc":{"start":{"line":106,"column":74},"end":{"line":106,"column":116}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"1":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"cond-expr","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},"type":"binary-expr","locations":[{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}},{"start":{"line":14,"column":65},"end":{"line":14,"column":null}}]},"3":{"loc":{"start":{"line":34,"column":2},"end":{"line":48,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":48,"column":null}}]},"4":{"loc":{"start":{"line":36,"column":4},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":4},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":39,"column":4},"end":{"line":41,"column":null}},"type":"if","locations":[{"start":{"line":39,"column":4},"end":{"line":41,"column":null}}]},"6":{"loc":{"start":{"line":42,"column":4},"end":{"line":47,"column":null}},"type":"if","locations":[{"start":{"line":42,"column":4},"end":{"line":47,"column":null}}]},"7":{"loc":{"start":{"line":46,"column":9},"end":{"line":46,"column":32}},"type":"default-arg","locations":[{"start":{"line":46,"column":22},"end":{"line":46,"column":32}}]},"8":{"loc":{"start":{"line":46,"column":34},"end":{"line":46,"column":58}},"type":"default-arg","locations":[{"start":{"line":46,"column":47},"end":{"line":46,"column":58}}]},"9":{"loc":{"start":{"line":52,"column":19},"end":{"line":52,"column":93}},"type":"binary-expr","locations":[{"start":{"line":52,"column":19},"end":{"line":52,"column":39}},{"start":{"line":52,"column":43},"end":{"line":52,"column":93}}]},"10":{"loc":{"start":{"line":53,"column":20},"end":{"line":53,"column":74}},"type":"binary-expr","locations":[{"start":{"line":53,"column":20},"end":{"line":53,"column":40}},{"start":{"line":53,"column":44},"end":{"line":53,"column":59}},{"start":{"line":53,"column":63},"end":{"line":53,"column":74}}]},"11":{"loc":{"start":{"line":54,"column":2},"end":{"line":56,"column":null}},"type":"if","locations":[{"start":{"line":54,"column":2},"end":{"line":56,"column":null}}]},"12":{"loc":{"start":{"line":62,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":62,"column":4},"end":{"line":65,"column":null}}]},"13":{"loc":{"start":{"line":71,"column":2},"end":{"line":74,"column":null}},"type":"if","locations":[{"start":{"line":71,"column":2},"end":{"line":74,"column":null}}]},"14":{"loc":{"start":{"line":71,"column":6},"end":{"line":71,"column":71}},"type":"binary-expr","locations":[{"start":{"line":71,"column":6},"end":{"line":71,"column":30}},{"start":{"line":71,"column":34},"end":{"line":71,"column":71}}]},"15":{"loc":{"start":{"line":76,"column":2},"end":{"line":109,"column":null}},"type":"if","locations":[{"start":{"line":76,"column":2},"end":{"line":109,"column":null}}]},"16":{"loc":{"start":{"line":76,"column":6},"end":{"line":76,"column":52}},"type":"binary-expr","locations":[{"start":{"line":76,"column":6},"end":{"line":76,"column":26}},{"start":{"line":76,"column":30},"end":{"line":76,"column":52}}]},"17":{"loc":{"start":{"line":89,"column":6},"end":{"line":107,"column":null}},"type":"if","locations":[{"start":{"line":89,"column":6},"end":{"line":107,"column":null}}]},"18":{"loc":{"start":{"line":92,"column":89},"end":{"line":92,"column":105}},"type":"default-arg","locations":[{"start":{"line":92,"column":96},"end":{"line":92,"column":105}}]},"19":{"loc":{"start":{"line":115,"column":4},"end":{"line":117,"column":null}},"type":"if","locations":[{"start":{"line":115,"column":4},"end":{"line":117,"column":null}}]},"20":{"loc":{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},"type":"if","locations":[{"start":{"line":123,"column":2},"end":{"line":127,"column":null}},{"start":{"line":125,"column":9},"end":{"line":127,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0],"5":[0],"6":[0],"7":[0],"8":[0],"9":[0,0],"10":[0,0,0],"11":[0],"12":[0],"13":[0],"14":[0,0],"15":[0],"16":[0,0],"17":[0],"18":[0],"19":[0],"20":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-destroy.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-destroy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"7":{"start":{"line":10,"column":22},"end":{"line":55,"column":1}},"8":{"start":{"line":11,"column":29},"end":{"line":11,"column":74}},"9":{"start":{"line":12,"column":25},"end":{"line":12,"column":70}},"10":{"start":{"line":13,"column":21},"end":{"line":13,"column":50}},"11":{"start":{"line":14,"column":22},"end":{"line":14,"column":36}},"12":{"start":{"line":16,"column":19},"end":{"line":16,"column":50}},"13":{"start":{"line":18,"column":2},"end":{"line":34,"column":null}},"14":{"start":{"line":19,"column":32},"end":{"line":25,"column":5}},"15":{"start":{"line":26,"column":23},"end":{"line":26,"column":87}},"16":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"17":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"18":{"start":{"line":30,"column":4},"end":{"line":33,"column":null}},"19":{"start":{"line":31,"column":6},"end":{"line":31,"column":null}},"20":{"start":{"line":32,"column":6},"end":{"line":32,"column":null}},"21":{"start":{"line":36,"column":18},"end":{"line":36,"column":65}},"22":{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},"23":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"24":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"25":{"start":{"line":42,"column":16},"end":{"line":42,"column":26}},"26":{"start":{"line":43,"column":24},"end":{"line":43,"column":68}},"27":{"start":{"line":44,"column":4},"end":{"line":44,"column":null}},"28":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"29":{"start":{"line":46,"column":4},"end":{"line":50,"column":null}},"30":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"31":{"start":{"line":53,"column":4},"end":{"line":53,"column":null}},"32":{"start":{"line":55,"column":1},"end":{"line":55,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":10,"column":22},"end":{"line":10,"column":29}},"loc":{"start":{"line":10,"column":46},"end":{"line":55,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":18,"column":2},"end":{"line":34,"column":null}},"type":"if","locations":[{"start":{"line":18,"column":2},"end":{"line":34,"column":null}}]},"1":{"loc":{"start":{"line":30,"column":4},"end":{"line":33,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":4},"end":{"line":33,"column":null}}]},"2":{"loc":{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},"type":"if","locations":[{"start":{"line":38,"column":2},"end":{"line":54,"column":null}},{"start":{"line":41,"column":9},"end":{"line":54,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-detail.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-detail.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":21},"end":{"line":23,"column":1}},"6":{"start":{"line":9,"column":28},"end":{"line":9,"column":72}},"7":{"start":{"line":10,"column":24},"end":{"line":10,"column":68}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":49}},"9":{"start":{"line":12,"column":21},"end":{"line":12,"column":34}},"10":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"11":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"12":{"start":{"line":18,"column":2},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":17},"end":{"line":20,"column":48}},"14":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"15":{"start":{"line":23,"column":1},"end":{"line":23,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":21},"end":{"line":8,"column":22}},"loc":{"start":{"line":8,"column":39},"end":{"line":23,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":16,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-get-iam-policy.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-get-iam-policy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":71}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":26},"end":{"line":228,"column":1}},"7":{"start":{"line":12,"column":22},"end":{"line":12,"column":32}},"8":{"start":{"line":13,"column":2},"end":{"line":16,"column":null}},"9":{"start":{"line":14,"column":24},"end":{"line":14,"column":60}},"10":{"start":{"line":15,"column":4},"end":{"line":15,"column":null}},"11":{"start":{"line":18,"column":2},"end":{"line":227,"column":null}},"12":{"start":{"line":231,"column":1},"end":{"line":239,"column":31}},"13":{"start":{"line":241,"column":27},"end":{"line":252,"column":1}},"14":{"start":{"line":242,"column":34},"end":{"line":242,"column":86}},"15":{"start":{"line":243,"column":30},"end":{"line":243,"column":80}},"16":{"start":{"line":244,"column":27},"end":{"line":244,"column":67}},"17":{"start":{"line":246,"column":2},"end":{"line":246,"column":null}},"18":{"start":{"line":248,"column":2},"end":{"line":251,"column":null}},"19":{"start":{"line":250,"column":4},"end":{"line":250,"column":null}},"20":{"start":{"line":252,"column":1},"end":{"line":252,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":26},"end":{"line":9,"column":33}},"loc":{"start":{"line":9,"column":40},"end":{"line":228,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":241,"column":27},"end":{"line":241,"column":34}},"loc":{"start":{"line":241,"column":51},"end":{"line":252,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":13,"column":2},"end":{"line":16,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":16,"column":null}}]},"1":{"loc":{"start":{"line":14,"column":38},"end":{"line":14,"column":59}},"type":"cond-expr","locations":[{"start":{"line":14,"column":49},"end":{"line":14,"column":51}},{"start":{"line":14,"column":39},"end":{"line":14,"column":59}}]},"2":{"loc":{"start":{"line":14,"column":38},"end":{"line":14,"column":51}},"type":"binary-expr","locations":[{"start":{"line":14,"column":38},"end":{"line":14,"column":51}},{"start":{"line":14,"column":49},"end":{"line":14,"column":51}}]},"3":{"loc":{"start":{"line":248,"column":2},"end":{"line":251,"column":null}},"type":"if","locations":[{"start":{"line":248,"column":2},"end":{"line":251,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0],"3":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-import.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-import.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":11,"column":21},"end":{"line":65,"column":1}},"8":{"start":{"line":13,"column":28},"end":{"line":13,"column":72}},"9":{"start":{"line":14,"column":24},"end":{"line":14,"column":68}},"10":{"start":{"line":15,"column":27},"end":{"line":15,"column":62}},"11":{"start":{"line":16,"column":25},"end":{"line":16,"column":58}},"12":{"start":{"line":17,"column":30},"end":{"line":17,"column":43}},"13":{"start":{"line":18,"column":19},"end":{"line":18,"column":47}},"14":{"start":{"line":21,"column":2},"end":{"line":23,"column":null}},"15":{"start":{"line":22,"column":4},"end":{"line":22,"column":null}},"16":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"17":{"start":{"line":26,"column":21},"end":{"line":26,"column":97}},"18":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"19":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"20":{"start":{"line":31,"column":2},"end":{"line":33,"column":null}},"21":{"start":{"line":32,"column":4},"end":{"line":32,"column":null}},"22":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"23":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"24":{"start":{"line":39,"column":2},"end":{"line":45,"column":null}},"25":{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},"26":{"start":{"line":41,"column":6},"end":{"line":41,"column":null}},"27":{"start":{"line":42,"column":11},"end":{"line":44,"column":null}},"28":{"start":{"line":43,"column":6},"end":{"line":43,"column":null}},"29":{"start":{"line":47,"column":20},"end":{"line":47,"column":28}},"30":{"start":{"line":49,"column":2},"end":{"line":51,"column":null}},"31":{"start":{"line":50,"column":4},"end":{"line":50,"column":null}},"32":{"start":{"line":52,"column":2},"end":{"line":54,"column":null}},"33":{"start":{"line":53,"column":4},"end":{"line":53,"column":null}},"34":{"start":{"line":55,"column":2},"end":{"line":57,"column":null}},"35":{"start":{"line":56,"column":4},"end":{"line":56,"column":null}},"36":{"start":{"line":60,"column":18},"end":{"line":60,"column":105}},"37":{"start":{"line":61,"column":2},"end":{"line":61,"column":null}},"38":{"start":{"line":62,"column":2},"end":{"line":62,"column":null}},"39":{"start":{"line":64,"column":2},"end":{"line":64,"column":null}},"40":{"start":{"line":65,"column":1},"end":{"line":65,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":11,"column":21},"end":{"line":11,"column":28}},"loc":{"start":{"line":11,"column":45},"end":{"line":65,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":21,"column":2},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":2},"end":{"line":23,"column":null}}]},"1":{"loc":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":2},"end":{"line":30,"column":null}}]},"2":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":28}},"type":"cond-expr","locations":[{"start":{"line":28,"column":20},"end":{"line":28,"column":22}},{"start":{"line":28,"column":6},"end":{"line":28,"column":28}}]},"3":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":22}},"type":"binary-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":22}},{"start":{"line":28,"column":6},"end":{"line":28,"column":22}}]},"4":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":138}},"type":"binary-expr","locations":[{"start":{"line":29,"column":108},"end":{"line":29,"column":130}},{"start":{"line":29,"column":134},"end":{"line":29,"column":138}}]},"5":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":130}},"type":"cond-expr","locations":[{"start":{"line":29,"column":122},"end":{"line":29,"column":124}},{"start":{"line":29,"column":108},"end":{"line":29,"column":130}}]},"6":{"loc":{"start":{"line":29,"column":108},"end":{"line":29,"column":124}},"type":"binary-expr","locations":[{"start":{"line":29,"column":108},"end":{"line":29,"column":124}},{"start":{"line":29,"column":108},"end":{"line":29,"column":124}}]},"7":{"loc":{"start":{"line":31,"column":2},"end":{"line":33,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":33,"column":null}}]},"8":{"loc":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":36,"column":null}}]},"9":{"loc":{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":4},"end":{"line":44,"column":null}},{"start":{"line":42,"column":11},"end":{"line":44,"column":null}}]},"10":{"loc":{"start":{"line":42,"column":11},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":42,"column":11},"end":{"line":44,"column":null}}]},"11":{"loc":{"start":{"line":49,"column":2},"end":{"line":51,"column":null}},"type":"if","locations":[{"start":{"line":49,"column":2},"end":{"line":51,"column":null}}]},"12":{"loc":{"start":{"line":49,"column":6},"end":{"line":49,"column":57}},"type":"binary-expr","locations":[{"start":{"line":49,"column":6},"end":{"line":49,"column":37}},{"start":{"line":49,"column":41},"end":{"line":49,"column":57}}]},"13":{"loc":{"start":{"line":52,"column":2},"end":{"line":54,"column":null}},"type":"if","locations":[{"start":{"line":52,"column":2},"end":{"line":54,"column":null}}]},"14":{"loc":{"start":{"line":55,"column":2},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":55,"column":2},"end":{"line":57,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0],"11":[0],"12":[0,0],"13":[0],"14":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-list.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-list.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":22,"column":1}},"5":{"start":{"line":8,"column":26},"end":{"line":8,"column":68}},"6":{"start":{"line":9,"column":22},"end":{"line":9,"column":64}},"7":{"start":{"line":10,"column":20},"end":{"line":10,"column":45}},"8":{"start":{"line":12,"column":25},"end":{"line":12,"column":48}},"9":{"start":{"line":13,"column":17},"end":{"line":19,"column":6}},"10":{"start":{"line":16,"column":22},"end":{"line":16,"column":76}},"11":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":19},"end":{"line":7,"column":20}},"loc":{"start":{"line":7,"column":37},"end":{"line":22,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":15,"column":26},"end":{"line":15,"column":34}},"loc":{"start":{"line":15,"column":39},"end":{"line":19,"column":5}}}},"branchMap":{"0":{"loc":{"start":{"line":13,"column":17},"end":{"line":19,"column":6}},"type":"cond-expr","locations":[{"start":{"line":14,"column":6},"end":{"line":14,"column":20}},{"start":{"line":15,"column":6},"end":{"line":19,"column":6}}]},"1":{"loc":{"start":{"line":17,"column":36},"end":{"line":17,"column":58}},"type":"binary-expr","locations":[{"start":{"line":17,"column":36},"end":{"line":17,"column":52}},{"start":{"line":17,"column":56},"end":{"line":17,"column":58}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-plugin-settings.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-plugin-settings.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":29},"end":{"line":22,"column":1}},"6":{"start":{"line":9,"column":31},"end":{"line":9,"column":84}},"7":{"start":{"line":10,"column":27},"end":{"line":10,"column":101}},"8":{"start":{"line":11,"column":25},"end":{"line":11,"column":41}},"9":{"start":{"line":12,"column":2},"end":{"line":12,"column":null}},"10":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"11":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"12":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"13":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"14":{"start":{"line":22,"column":1},"end":{"line":22,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":29},"end":{"line":8,"column":36}},"loc":{"start":{"line":8,"column":53},"end":{"line":22,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":9},"end":{"line":12,"column":40}},"type":"binary-expr","locations":[{"start":{"line":12,"column":9},"end":{"line":12,"column":34}},{"start":{"line":12,"column":38},"end":{"line":12,"column":40}}]},"1":{"loc":{"start":{"line":14,"column":2},"end":{"line":21,"column":null}},"type":"switch","locations":[{"start":{"line":15,"column":4},"end":{"line":16,"column":null}},{"start":{"line":17,"column":4},"end":{"line":18,"column":null}},{"start":{"line":19,"column":4},"end":{"line":20,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-update.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-update.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":21},"end":{"line":24,"column":1}},"6":{"start":{"line":9,"column":28},"end":{"line":9,"column":72}},"7":{"start":{"line":10,"column":24},"end":{"line":10,"column":68}},"8":{"start":{"line":11,"column":21},"end":{"line":11,"column":49}},"9":{"start":{"line":12,"column":20},"end":{"line":12,"column":47}},"10":{"start":{"line":13,"column":20},"end":{"line":13,"column":47}},"11":{"start":{"line":14,"column":16},"end":{"line":14,"column":39}},"12":{"start":{"line":15,"column":18},"end":{"line":15,"column":43}},"13":{"start":{"line":16,"column":18},"end":{"line":16,"column":43}},"14":{"start":{"line":17,"column":30},"end":{"line":17,"column":68}},"15":{"start":{"line":19,"column":19},"end":{"line":19,"column":50}},"16":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"17":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"18":{"start":{"line":24,"column":1},"end":{"line":24,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":21},"end":{"line":8,"column":28}},"loc":{"start":{"line":8,"column":45},"end":{"line":24,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/cli/lib/handle-verify.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/handle-verify.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":21},"end":{"line":31,"column":1}},"7":{"start":{"line":10,"column":28},"end":{"line":10,"column":72}},"8":{"start":{"line":11,"column":24},"end":{"line":11,"column":68}},"9":{"start":{"line":12,"column":21},"end":{"line":12,"column":34}},"10":{"start":{"line":13,"column":21},"end":{"line":13,"column":49}},"11":{"start":{"line":14,"column":23},"end":{"line":14,"column":53}},"12":{"start":{"line":15,"column":22},"end":{"line":15,"column":52}},"13":{"start":{"line":16,"column":21},"end":{"line":16,"column":49}},"14":{"start":{"line":18,"column":2},"end":{"line":18,"column":null}},"15":{"start":{"line":20,"column":19},"end":{"line":20,"column":50}},"16":{"start":{"line":23,"column":4},"end":{"line":23,"column":73}},"17":{"start":{"line":24,"column":24},"end":{"line":26,"column":15}},"18":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"19":{"start":{"line":25,"column":25},"end":{"line":25,"column":40}},"20":{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},"21":{"start":{"line":25,"column":69},"end":{"line":25,"column":85}},"22":{"start":{"line":25,"column":94},"end":{"line":25,"column":105}},"23":{"start":{"line":28,"column":17},"end":{"line":28,"column":71}},"24":{"start":{"line":30,"column":2},"end":{"line":30,"column":null}},"25":{"start":{"line":31,"column":1},"end":{"line":31,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":21},"end":{"line":9,"column":28}},"loc":{"start":{"line":9,"column":45},"end":{"line":31,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":24,"column":39},"end":{"line":24,"column":40}},"loc":{"start":{"line":24,"column":64},"end":{"line":26,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},{"start":{"line":25,"column":47},"end":{"line":25,"column":null}}]},"1":{"loc":{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":47},"end":{"line":25,"column":null}},{"start":{"line":25,"column":92},"end":{"line":25,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/options.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/options.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":46}},"4":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"5":{"start":{"line":6,"column":22},"end":{"line":13,"column":4}},"6":{"start":{"line":7,"column":2},"end":{"line":13,"column":4}},"7":{"start":{"line":8,"column":24},"end":{"line":8,"column":45}},"8":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"9":{"start":{"line":10,"column":4},"end":{"line":10,"column":null}},"10":{"start":{"line":12,"column":4},"end":{"line":12,"column":null}},"11":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"12":{"start":{"line":15,"column":29},"end":{"line":67,"column":1}},"13":{"start":{"line":16,"column":2},"end":{"line":66,"column":null}},"14":{"start":{"line":17,"column":21},"end":{"line":17,"column":36}},"15":{"start":{"line":18,"column":23},"end":{"line":18,"column":39}},"16":{"start":{"line":20,"column":19},"end":{"line":20,"column":38}},"17":{"start":{"line":21,"column":4},"end":{"line":23,"column":null}},"18":{"start":{"line":22,"column":6},"end":{"line":22,"column":null}},"19":{"start":{"line":25,"column":4},"end":{"line":27,"column":null}},"20":{"start":{"line":26,"column":6},"end":{"line":26,"column":null}},"21":{"start":{"line":28,"column":23},"end":{"line":28,"column":57}},"22":{"start":{"line":29,"column":4},"end":{"line":29,"column":46}},"23":{"start":{"line":30,"column":27},"end":{"line":30,"column":70}},"24":{"start":{"line":31,"column":4},"end":{"line":31,"column":59}},"25":{"start":{"line":32,"column":17},"end":{"line":32,"column":38}},"26":{"start":{"line":34,"column":41},"end":{"line":41,"column":6}},"27":{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},"28":{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},"29":{"start":{"line":45,"column":31},"end":{"line":45,"column":59}},"30":{"start":{"line":46,"column":8},"end":{"line":46,"column":null}},"31":{"start":{"line":47,"column":8},"end":{"line":47,"column":null}},"32":{"start":{"line":49,"column":8},"end":{"line":49,"column":null}},"33":{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},"34":{"start":{"line":52,"column":23},"end":{"line":52,"column":47}},"35":{"start":{"line":53,"column":6},"end":{"line":53,"column":null}},"36":{"start":{"line":54,"column":6},"end":{"line":54,"column":null}},"37":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"38":{"start":{"line":57,"column":6},"end":{"line":57,"column":null}},"39":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"40":{"start":{"line":64,"column":6},"end":{"line":64,"column":null}},"41":{"start":{"line":67,"column":1},"end":{"line":67,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":6,"column":22},"end":{"line":6,"column":23}},"loc":{"start":{"line":7,"column":2},"end":{"line":13,"column":4}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":7,"column":18},"end":{"line":7,"column":22}},"loc":{"start":{"line":7,"column":27},"end":{"line":13,"column":3}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":15,"column":29},"end":{"line":15,"column":30}},"loc":{"start":{"line":15,"column":77},"end":{"line":67,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"cond-expr","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"2":{"loc":{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},"type":"binary-expr","locations":[{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}},{"start":{"line":4,"column":46},"end":{"line":4,"column":null}}]},"3":{"loc":{"start":{"line":6,"column":23},"end":{"line":6,"column":38}},"type":"default-arg","locations":[{"start":{"line":6,"column":36},"end":{"line":6,"column":38}}]},"4":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":52}},"type":"binary-expr","locations":[{"start":{"line":9,"column":12},"end":{"line":9,"column":42}},{"start":{"line":9,"column":46},"end":{"line":9,"column":52}}]},"5":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":42}},"type":"cond-expr","locations":[{"start":{"line":9,"column":17},"end":{"line":9,"column":19}},{"start":{"line":9,"column":12},"end":{"line":9,"column":42}}]},"6":{"loc":{"start":{"line":9,"column":12},"end":{"line":9,"column":19}},"type":"binary-expr","locations":[{"start":{"line":9,"column":12},"end":{"line":9,"column":19}},{"start":{"line":9,"column":17},"end":{"line":9,"column":19}}]},"7":{"loc":{"start":{"line":21,"column":4},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":21,"column":4},"end":{"line":23,"column":null}}]},"8":{"loc":{"start":{"line":25,"column":4},"end":{"line":27,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":4},"end":{"line":27,"column":null}}]},"9":{"loc":{"start":{"line":28,"column":23},"end":{"line":28,"column":57}},"type":"binary-expr","locations":[{"start":{"line":28,"column":23},"end":{"line":28,"column":51}},{"start":{"line":28,"column":55},"end":{"line":28,"column":57}}]},"10":{"loc":{"start":{"line":30,"column":27},"end":{"line":30,"column":70}},"type":"binary-expr","locations":[{"start":{"line":30,"column":27},"end":{"line":30,"column":64}},{"start":{"line":30,"column":68},"end":{"line":30,"column":70}}]},"11":{"loc":{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":4},"end":{"line":58,"column":null}},{"start":{"line":51,"column":11},"end":{"line":58,"column":null}}]},"12":{"loc":{"start":{"line":43,"column":8},"end":{"line":43,"column":51}},"type":"binary-expr","locations":[{"start":{"line":43,"column":8},"end":{"line":43,"column":25}},{"start":{"line":43,"column":29},"end":{"line":43,"column":51}}]},"13":{"loc":{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},"type":"if","locations":[{"start":{"line":44,"column":6},"end":{"line":50,"column":null}},{"start":{"line":48,"column":13},"end":{"line":50,"column":null}}]},"14":{"loc":{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},"type":"if","locations":[{"start":{"line":51,"column":11},"end":{"line":58,"column":null}},{"start":{"line":55,"column":11},"end":{"line":58,"column":null}}]},"15":{"loc":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":65,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0,0],"15":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/process-source-type.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/process-source-type.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":26},"end":{"line":15,"column":1}},"4":{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},"5":{"start":{"line":8,"column":33},"end":{"line":8,"column":86}},"6":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":9},"end":{"line":12,"column":null}},"8":{"start":{"line":11,"column":4},"end":{"line":11,"column":null}},"9":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":1},"end":{"line":15,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":26},"end":{"line":6,"column":27}},"loc":{"start":{"line":6,"column":58},"end":{"line":15,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":2},"end":{"line":12,"column":null}},{"start":{"line":10,"column":9},"end":{"line":12,"column":null}}]},"1":{"loc":{"start":{"line":9,"column":17},"end":{"line":9,"column":76}},"type":"cond-expr","locations":[{"start":{"line":9,"column":52},"end":{"line":9,"column":64}},{"start":{"line":9,"column":67},"end":{"line":9,"column":76}}]},"2":{"loc":{"start":{"line":10,"column":9},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":9},"end":{"line":12,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0],"2":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/smart-convert.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/smart-convert.mjs","statementMap":{"0":{"start":{"line":1,"column":22},"end":{"line":20,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},"2":{"start":{"line":3,"column":4},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},"4":{"start":{"line":5,"column":4},"end":{"line":5,"column":null}},"5":{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},"6":{"start":{"line":7,"column":4},"end":{"line":7,"column":null}},"7":{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},"8":{"start":{"line":9,"column":4},"end":{"line":9,"column":null}},"9":{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},"10":{"start":{"line":11,"column":4},"end":{"line":11,"column":null}},"11":{"start":{"line":13,"column":4},"end":{"line":13,"column":null}},"12":{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},"13":{"start":{"line":15,"column":6},"end":{"line":15,"column":null}},"14":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"15":{"start":{"line":20,"column":1},"end":{"line":20,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":22},"end":{"line":1,"column":27}},"loc":{"start":{"line":1,"column":32},"end":{"line":20,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":19,"column":null}},{"start":{"line":4,"column":9},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":4,"column":9},"end":{"line":19,"column":null}},{"start":{"line":6,"column":9},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":4,"column":13},"end":{"line":4,"column":49}},"type":"binary-expr","locations":[{"start":{"line":4,"column":13},"end":{"line":4,"column":29}},{"start":{"line":4,"column":33},"end":{"line":4,"column":49}}]},"3":{"loc":{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":6,"column":9},"end":{"line":19,"column":null}},{"start":{"line":8,"column":9},"end":{"line":19,"column":null}}]},"4":{"loc":{"start":{"line":6,"column":13},"end":{"line":6,"column":51}},"type":"binary-expr","locations":[{"start":{"line":6,"column":13},"end":{"line":6,"column":30}},{"start":{"line":6,"column":34},"end":{"line":6,"column":51}}]},"5":{"loc":{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":8,"column":9},"end":{"line":19,"column":null}},{"start":{"line":10,"column":9},"end":{"line":19,"column":null}}]},"6":{"loc":{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":9},"end":{"line":19,"column":null}},{"start":{"line":12,"column":9},"end":{"line":19,"column":null}}]},"7":{"loc":{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":4},"end":{"line":18,"column":null}},{"start":{"line":16,"column":11},"end":{"line":18,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-initialize.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-initialize.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":38},"end":{"line":34,"column":1}},"3":{"start":{"line":6,"column":30},"end":{"line":26,"column":3}},"4":{"start":{"line":28,"column":21},"end":{"line":28,"column":85}},"5":{"start":{"line":29,"column":2},"end":{"line":29,"column":null}},"6":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"7":{"start":{"line":33,"column":2},"end":{"line":33,"column":null}},"8":{"start":{"line":34,"column":1},"end":{"line":34,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":38},"end":{"line":5,"column":45}},"loc":{"start":{"line":5,"column":56},"end":{"line":34,"column":1}}}},"branchMap":{},"s":{"0":1,"1":1,"2":1,"3":1,"4":1,"5":1,"6":1,"7":1,"8":1},"f":{"0":1},"b":{}} -,"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-show.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/configuration/handle-configuration-show.mjs","statementMap":{"0":{"start":{"line":6,"column":32},"end":{"line":18,"column":1}},"1":{"start":{"line":16,"column":26},"end":{"line":16,"column":51}},"2":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"3":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":32},"end":{"line":6,"column":39}},"loc":{"start":{"line":6,"column":62},"end":{"line":18,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":26},"end":{"line":16,"column":51}},"type":"binary-expr","locations":[{"start":{"line":16,"column":26},"end":{"line":16,"column":45}},{"start":{"line":16,"column":49},"end":{"line":16,"column":51}}]}},"s":{"0":1,"1":1,"2":1,"3":1},"f":{"0":1},"b":{"0":[1,0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-set.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":47}},"6":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"7":{"start":{"line":9,"column":32},"end":{"line":45,"column":1}},"8":{"start":{"line":10,"column":24},"end":{"line":13,"column":20}},"9":{"start":{"line":11,"column":33},"end":{"line":11,"column":59}},"10":{"start":{"line":12,"column":33},"end":{"line":12,"column":47}},"11":{"start":{"line":14,"column":39},"end":{"line":14,"column":86}},"12":{"start":{"line":15,"column":35},"end":{"line":15,"column":90}},"13":{"start":{"line":16,"column":21},"end":{"line":16,"column":60}},"14":{"start":{"line":17,"column":18},"end":{"line":17,"column":75}},"15":{"start":{"line":19,"column":55},"end":{"line":19,"column":79}},"16":{"start":{"line":22,"column":19},"end":{"line":22,"column":50}},"17":{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},"18":{"start":{"line":25,"column":4},"end":{"line":25,"column":null}},"19":{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},"20":{"start":{"line":27,"column":4},"end":{"line":27,"column":56}},"21":{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},"22":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"23":{"start":{"line":30,"column":9},"end":{"line":32,"column":null}},"24":{"start":{"line":31,"column":4},"end":{"line":31,"column":null}},"25":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"26":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"27":{"start":{"line":39,"column":2},"end":{"line":41,"column":null}},"28":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"29":{"start":{"line":42,"column":2},"end":{"line":42,"column":null}},"30":{"start":{"line":44,"column":2},"end":{"line":44,"column":null}},"31":{"start":{"line":45,"column":1},"end":{"line":45,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":9,"column":32},"end":{"line":9,"column":39}},"loc":{"start":{"line":9,"column":56},"end":{"line":45,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":11,"column":19},"end":{"line":11,"column":20}},"loc":{"start":{"line":11,"column":33},"end":{"line":11,"column":59}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":12,"column":19},"end":{"line":12,"column":20}},"loc":{"start":{"line":12,"column":33},"end":{"line":12,"column":47}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"if","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"1":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"cond-expr","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"2":{"loc":{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},"type":"binary-expr","locations":[{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}},{"start":{"line":7,"column":47},"end":{"line":7,"column":null}}]},"3":{"loc":{"start":{"line":10,"column":24},"end":{"line":13,"column":20}},"type":"binary-expr","locations":[{"start":{"line":10,"column":24},"end":{"line":13,"column":14}},{"start":{"line":13,"column":18},"end":{"line":13,"column":20}}]},"4":{"loc":{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":24,"column":2},"end":{"line":32,"column":null}},{"start":{"line":26,"column":9},"end":{"line":32,"column":null}}]},"5":{"loc":{"start":{"line":24,"column":6},"end":{"line":24,"column":69}},"type":"binary-expr","locations":[{"start":{"line":24,"column":6},"end":{"line":24,"column":23}},{"start":{"line":24,"column":27},"end":{"line":24,"column":45}},{"start":{"line":24,"column":49},"end":{"line":24,"column":69}}]},"6":{"loc":{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":26,"column":9},"end":{"line":32,"column":null}},{"start":{"line":28,"column":9},"end":{"line":32,"column":null}}]},"7":{"loc":{"start":{"line":26,"column":13},"end":{"line":26,"column":77}},"type":"binary-expr","locations":[{"start":{"line":26,"column":13},"end":{"line":26,"column":31}},{"start":{"line":26,"column":36},"end":{"line":26,"column":55}},{"start":{"line":26,"column":59},"end":{"line":26,"column":76}}]},"8":{"loc":{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":9},"end":{"line":32,"column":null}},{"start":{"line":30,"column":9},"end":{"line":32,"column":null}}]},"9":{"loc":{"start":{"line":28,"column":13},"end":{"line":28,"column":54}},"type":"binary-expr","locations":[{"start":{"line":28,"column":13},"end":{"line":28,"column":31}},{"start":{"line":28,"column":35},"end":{"line":28,"column":54}}]},"10":{"loc":{"start":{"line":30,"column":9},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":9},"end":{"line":32,"column":null}}]},"11":{"loc":{"start":{"line":30,"column":13},"end":{"line":30,"column":54}},"type":"binary-expr","locations":[{"start":{"line":30,"column":13},"end":{"line":30,"column":31}},{"start":{"line":30,"column":35},"end":{"line":30,"column":54}}]},"12":{"loc":{"start":{"line":34,"column":2},"end":{"line":36,"column":null}},"type":"if","locations":[{"start":{"line":34,"column":2},"end":{"line":36,"column":null}}]},"13":{"loc":{"start":{"line":34,"column":6},"end":{"line":34,"column":47}},"type":"binary-expr","locations":[{"start":{"line":34,"column":6},"end":{"line":34,"column":23}},{"start":{"line":34,"column":27},"end":{"line":34,"column":47}}]},"14":{"loc":{"start":{"line":39,"column":2},"end":{"line":41,"column":null}},"type":"if","locations":[{"start":{"line":39,"column":2},"end":{"line":41,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0,0],"5":[0,0,0],"6":[0,0],"7":[0,0,0],"8":[0,0],"9":[0,0],"10":[0],"11":[0,0],"12":[0],"13":[0,0],"14":[0]}} -,"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-show.mjs": {"path":"/Users/zane/playground/cloudsite/src/cli/lib/plugin-settings/handle-plugin-settings-show.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":33},"end":{"line":18,"column":1}},"4":{"start":{"line":7,"column":24},"end":{"line":10,"column":20}},"5":{"start":{"line":8,"column":33},"end":{"line":8,"column":59}},"6":{"start":{"line":9,"column":33},"end":{"line":9,"column":48}},"7":{"start":{"line":11,"column":46},"end":{"line":11,"column":93}},"8":{"start":{"line":12,"column":42},"end":{"line":12,"column":104}},"9":{"start":{"line":13,"column":21},"end":{"line":13,"column":67}},"10":{"start":{"line":15,"column":19},"end":{"line":15,"column":47}},"11":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":33},"end":{"line":6,"column":40}},"loc":{"start":{"line":6,"column":57},"end":{"line":18,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":19},"end":{"line":8,"column":20}},"loc":{"start":{"line":8,"column":33},"end":{"line":8,"column":59}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":19},"end":{"line":9,"column":20}},"loc":{"start":{"line":9,"column":33},"end":{"line":9,"column":48}}}},"branchMap":{"0":{"loc":{"start":{"line":7,"column":24},"end":{"line":10,"column":20}},"type":"binary-expr","locations":[{"start":{"line":7,"column":24},"end":{"line":10,"column":14}},{"start":{"line":10,"column":18},"end":{"line":10,"column":20}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/create.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/create.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"4":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"5":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"8":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"9":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":0},"end":{"line":15,"column":null}},"11":{"start":{"line":16,"column":0},"end":{"line":16,"column":null}},"12":{"start":{"line":17,"column":0},"end":{"line":17,"column":null}},"13":{"start":{"line":18,"column":0},"end":{"line":18,"column":null}},"14":{"start":{"line":19,"column":0},"end":{"line":19,"column":55}},"15":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"16":{"start":{"line":21,"column":29},"end":{"line":21,"column":31}},"17":{"start":{"line":23,"column":15},"end":{"line":86,"column":1}},"18":{"start":{"line":29,"column":25},"end":{"line":29,"column":33}},"19":{"start":{"line":30,"column":23},"end":{"line":30,"column":31}},"20":{"start":{"line":32,"column":22},"end":{"line":32,"column":57}},"21":{"start":{"line":34,"column":20},"end":{"line":37,"column":4}},"22":{"start":{"line":39,"column":35},"end":{"line":39,"column":83}},"23":{"start":{"line":40,"column":2},"end":{"line":44,"column":null}},"24":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"25":{"start":{"line":42,"column":4},"end":{"line":42,"column":null}},"26":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"27":{"start":{"line":45,"column":2},"end":{"line":45,"column":null}},"28":{"start":{"line":47,"column":2},"end":{"line":52,"column":null}},"29":{"start":{"line":48,"column":31},"end":{"line":48,"column":74}},"30":{"start":{"line":50,"column":7},"end":{"line":50,"column":110}},"31":{"start":{"line":51,"column":4},"end":{"line":51,"column":null}},"32":{"start":{"line":54,"column":2},"end":{"line":54,"column":null}},"33":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"34":{"start":{"line":56,"column":23},"end":{"line":56,"column":90}},"35":{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},"36":{"start":{"line":59,"column":31},"end":{"line":62,"column":73}},"37":{"start":{"line":60,"column":6},"end":{"line":60,"column":null}},"38":{"start":{"line":62,"column":41},"end":{"line":62,"column":72}},"39":{"start":{"line":64,"column":4},"end":{"line":64,"column":52}},"40":{"start":{"line":66,"column":20},"end":{"line":66,"column":40}},"41":{"start":{"line":69,"column":4},"end":{"line":74,"column":null}},"42":{"start":{"line":73,"column":8},"end":{"line":73,"column":71}},"43":{"start":{"line":76,"column":4},"end":{"line":80,"column":null}},"44":{"start":{"line":77,"column":6},"end":{"line":77,"column":null}},"45":{"start":{"line":79,"column":6},"end":{"line":79,"column":null}},"46":{"start":{"line":82,"column":4},"end":{"line":82,"column":null}},"47":{"start":{"line":84,"column":4},"end":{"line":84,"column":null}},"48":{"start":{"line":86,"column":1},"end":{"line":86,"column":null}},"49":{"start":{"line":88,"column":26},"end":{"line":122,"column":1}},"50":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}},"51":{"start":{"line":90,"column":16},"end":{"line":114,"column":3}},"52":{"start":{"line":116,"column":18},"end":{"line":116,"column":54}},"53":{"start":{"line":117,"column":19},"end":{"line":117,"column":48}},"54":{"start":{"line":119,"column":29},"end":{"line":119,"column":37}},"55":{"start":{"line":121,"column":2},"end":{"line":121,"column":null}},"56":{"start":{"line":124,"column":24},"end":{"line":152,"column":1}},"57":{"start":{"line":125,"column":33},"end":{"line":125,"column":41}},"58":{"start":{"line":127,"column":23},"end":{"line":127,"column":66}},"59":{"start":{"line":128,"column":2},"end":{"line":128,"column":null}},"60":{"start":{"line":129,"column":2},"end":{"line":129,"column":null}},"61":{"start":{"line":131,"column":33},"end":{"line":131,"column":54}},"62":{"start":{"line":133,"column":31},"end":{"line":133,"column":80}},"63":{"start":{"line":134,"column":20},"end":{"line":134,"column":90}},"64":{"start":{"line":135,"column":22},"end":{"line":141,"column":3}},"65":{"start":{"line":142,"column":24},"end":{"line":142,"column":59}},"66":{"start":{"line":143,"column":25},"end":{"line":143,"column":71}},"67":{"start":{"line":145,"column":22},"end":{"line":145,"column":36}},"68":{"start":{"line":147,"column":2},"end":{"line":147,"column":null}},"69":{"start":{"line":148,"column":2},"end":{"line":148,"column":null}},"70":{"start":{"line":150,"column":22},"end":{"line":150,"column":100}},"71":{"start":{"line":151,"column":2},"end":{"line":151,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":23,"column":15},"end":{"line":23,"column":22}},"loc":{"start":{"line":28,"column":6},"end":{"line":86,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":59,"column":72},"end":{"line":59,"column":81}},"loc":{"start":{"line":60,"column":6},"end":{"line":60,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":62,"column":14},"end":{"line":62,"column":15}},"loc":{"start":{"line":62,"column":41},"end":{"line":62,"column":72}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":72,"column":33},"end":{"line":72,"column":34}},"loc":{"start":{"line":73,"column":8},"end":{"line":73,"column":71}}},"5":{"name":"(anonymous_7)","decl":{"start":{"line":88,"column":26},"end":{"line":88,"column":33}},"loc":{"start":{"line":88,"column":63},"end":{"line":122,"column":1}}},"6":{"name":"(anonymous_8)","decl":{"start":{"line":124,"column":24},"end":{"line":124,"column":31}},"loc":{"start":{"line":124,"column":80},"end":{"line":152,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"cond-expr","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},"type":"binary-expr","locations":[{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}},{"start":{"line":19,"column":55},"end":{"line":19,"column":null}}]},"3":{"loc":{"start":{"line":40,"column":2},"end":{"line":44,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":2},"end":{"line":44,"column":null}}]},"4":{"loc":{"start":{"line":47,"column":2},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":47,"column":2},"end":{"line":52,"column":null}}]},"5":{"loc":{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},"type":"if","locations":[{"start":{"line":58,"column":2},"end":{"line":85,"column":null}},{"start":{"line":83,"column":9},"end":{"line":85,"column":null}}]},"6":{"loc":{"start":{"line":59,"column":43},"end":{"line":59,"column":65}},"type":"binary-expr","locations":[{"start":{"line":59,"column":43},"end":{"line":59,"column":59}},{"start":{"line":59,"column":63},"end":{"line":59,"column":65}}]},"7":{"loc":{"start":{"line":134,"column":20},"end":{"line":134,"column":90}},"type":"binary-expr","locations":[{"start":{"line":134,"column":20},"end":{"line":134,"column":38}},{"start":{"line":134,"column":42},"end":{"line":134,"column":90}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0],"5":[0,0],"6":[0,0],"7":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/destroy.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/destroy.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":11,"column":16},"end":{"line":61,"column":1}},"8":{"start":{"line":12,"column":48},"end":{"line":12,"column":56}},"9":{"start":{"line":14,"column":22},"end":{"line":14,"column":57}},"10":{"start":{"line":15,"column":19},"end":{"line":15,"column":48}},"11":{"start":{"line":18,"column":2},"end":{"line":27,"column":null}},"12":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"13":{"start":{"line":19,"column":28},"end":{"line":19,"column":79}},"14":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"15":{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},"16":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"17":{"start":{"line":23,"column":30},"end":{"line":23,"column":81}},"18":{"start":{"line":25,"column":6},"end":{"line":25,"column":null}},"19":{"start":{"line":29,"column":23},"end":{"line":29,"column":66}},"20":{"start":{"line":30,"column":2},"end":{"line":30,"column":null}},"21":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"22":{"start":{"line":32,"column":26},"end":{"line":32,"column":83}},"23":{"start":{"line":33,"column":31},"end":{"line":33,"column":72}},"24":{"start":{"line":34,"column":29},"end":{"line":34,"column":78}},"25":{"start":{"line":35,"column":2},"end":{"line":35,"column":null}},"26":{"start":{"line":38,"column":2},"end":{"line":60,"column":null}},"27":{"start":{"line":40,"column":6},"end":{"line":40,"column":115}},"28":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"29":{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},"30":{"start":{"line":44,"column":6},"end":{"line":44,"column":null}},"31":{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},"32":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"33":{"start":{"line":48,"column":6},"end":{"line":48,"column":null}},"34":{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},"35":{"start":{"line":54,"column":6},"end":{"line":54,"column":null}},"36":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"37":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"38":{"start":{"line":59,"column":28},"end":{"line":59,"column":56}},"39":{"start":{"line":61,"column":1},"end":{"line":61,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":11,"column":16},"end":{"line":11,"column":23}},"loc":{"start":{"line":11,"column":53},"end":{"line":61,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":19,"column":4},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":4},"end":{"line":19,"column":null}}]},"1":{"loc":{"start":{"line":19,"column":28},"end":{"line":19,"column":78}},"type":"binary-expr","locations":[{"start":{"line":19,"column":28},"end":{"line":19,"column":44}},{"start":{"line":19,"column":28},"end":{"line":19,"column":44}},{"start":{"line":19,"column":28},"end":{"line":19,"column":78}}]},"2":{"loc":{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},"type":"if","locations":[{"start":{"line":22,"column":4},"end":{"line":26,"column":null}},{"start":{"line":24,"column":11},"end":{"line":26,"column":null}}]},"3":{"loc":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"type":"if","locations":[{"start":{"line":23,"column":6},"end":{"line":23,"column":null}}]},"4":{"loc":{"start":{"line":23,"column":30},"end":{"line":23,"column":80}},"type":"binary-expr","locations":[{"start":{"line":23,"column":30},"end":{"line":23,"column":46}},{"start":{"line":23,"column":30},"end":{"line":23,"column":46}},{"start":{"line":23,"column":30},"end":{"line":23,"column":80}}]},"5":{"loc":{"start":{"line":32,"column":2},"end":{"line":32,"column":null}},"type":"if","locations":[{"start":{"line":32,"column":2},"end":{"line":32,"column":null}}]},"6":{"loc":{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":4},"end":{"line":49,"column":null}},{"start":{"line":45,"column":11},"end":{"line":49,"column":null}}]},"7":{"loc":{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":45,"column":11},"end":{"line":49,"column":null}},{"start":{"line":47,"column":11},"end":{"line":49,"column":null}}]},"8":{"loc":{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":53,"column":4},"end":{"line":57,"column":null}},{"start":{"line":55,"column":11},"end":{"line":57,"column":null}}]},"9":{"loc":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"type":"if","locations":[{"start":{"line":59,"column":4},"end":{"line":59,"column":null}}]},"10":{"loc":{"start":{"line":59,"column":28},"end":{"line":59,"column":55}},"type":"binary-expr","locations":[{"start":{"line":59,"column":28},"end":{"line":59,"column":44}},{"start":{"line":59,"column":28},"end":{"line":59,"column":44}},{"start":{"line":59,"column":28},"end":{"line":59,"column":55}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0},"f":{"0":0},"b":{"0":[0],"1":[0,0,0],"2":[0,0],"3":[0],"4":[0,0,0],"5":[0],"6":[0,0],"7":[0,0],"8":[0,0],"9":[0],"10":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/import.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/import.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":11,"column":0},"end":{"line":11,"column":58}},"9":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"10":{"start":{"line":13,"column":17},"end":{"line":71,"column":1}},"11":{"start":{"line":14,"column":19},"end":{"line":14,"column":93}},"12":{"start":{"line":15,"column":22},"end":{"line":15,"column":57}},"13":{"start":{"line":17,"column":20},"end":{"line":17,"column":72}},"14":{"start":{"line":18,"column":29},"end":{"line":18,"column":86}},"15":{"start":{"line":19,"column":2},"end":{"line":19,"column":null}},"16":{"start":{"line":21,"column":20},"end":{"line":21,"column":55}},"17":{"start":{"line":22,"column":2},"end":{"line":22,"column":null}},"18":{"start":{"line":24,"column":2},"end":{"line":24,"column":null}},"19":{"start":{"line":25,"column":31},"end":{"line":25,"column":80}},"20":{"start":{"line":26,"column":32},"end":{"line":26,"column":80}},"21":{"start":{"line":27,"column":21},"end":{"line":27,"column":75}},"22":{"start":{"line":29,"column":29},"end":{"line":29,"column":74}},"23":{"start":{"line":30,"column":23},"end":{"line":30,"column":89}},"24":{"start":{"line":31,"column":19},"end":{"line":31,"column":42}},"25":{"start":{"line":33,"column":2},"end":{"line":33,"column":null}},"26":{"start":{"line":35,"column":23},"end":{"line":35,"column":57}},"27":{"start":{"line":36,"column":2},"end":{"line":53,"column":3}},"28":{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},"29":{"start":{"line":38,"column":6},"end":{"line":38,"column":null}},"30":{"start":{"line":40,"column":6},"end":{"line":46,"column":null}},"31":{"start":{"line":41,"column":8},"end":{"line":45,"column":null}},"32":{"start":{"line":47,"column":6},"end":{"line":49,"column":null}},"33":{"start":{"line":48,"column":8},"end":{"line":48,"column":null}},"34":{"start":{"line":50,"column":11},"end":{"line":52,"column":null}},"35":{"start":{"line":51,"column":6},"end":{"line":51,"column":null}},"36":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"37":{"start":{"line":57,"column":22},"end":{"line":57,"column":24}},"38":{"start":{"line":58,"column":2},"end":{"line":58,"column":null}},"39":{"start":{"line":60,"column":2},"end":{"line":68,"column":null}},"40":{"start":{"line":61,"column":4},"end":{"line":61,"column":null}},"41":{"start":{"line":62,"column":30},"end":{"line":62,"column":49}},"42":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"43":{"start":{"line":64,"column":6},"end":{"line":64,"column":null}},"44":{"start":{"line":67,"column":4},"end":{"line":67,"column":null}},"45":{"start":{"line":70,"column":2},"end":{"line":70,"column":null}},"46":{"start":{"line":71,"column":1},"end":{"line":71,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":13,"column":17},"end":{"line":13,"column":24}},"loc":{"start":{"line":13,"column":100},"end":{"line":71,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"1":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"cond-expr","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"2":{"loc":{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},"type":"binary-expr","locations":[{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}},{"start":{"line":11,"column":58},"end":{"line":11,"column":null}}]},"3":{"loc":{"start":{"line":24,"column":2},"end":{"line":24,"column":66}},"type":"binary-expr","locations":[{"start":{"line":24,"column":2},"end":{"line":24,"column":18}},{"start":{"line":24,"column":2},"end":{"line":24,"column":18}},{"start":{"line":24,"column":2},"end":{"line":24,"column":66}}]},"4":{"loc":{"start":{"line":35,"column":23},"end":{"line":35,"column":57}},"type":"binary-expr","locations":[{"start":{"line":35,"column":23},"end":{"line":35,"column":51}},{"start":{"line":35,"column":55},"end":{"line":35,"column":57}}]},"5":{"loc":{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":4},"end":{"line":52,"column":null}},{"start":{"line":50,"column":11},"end":{"line":52,"column":null}}]},"6":{"loc":{"start":{"line":40,"column":6},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":6},"end":{"line":46,"column":null}}]},"7":{"loc":{"start":{"line":47,"column":6},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":47,"column":6},"end":{"line":49,"column":null}}]},"8":{"loc":{"start":{"line":47,"column":10},"end":{"line":47,"column":71}},"type":"binary-expr","locations":[{"start":{"line":47,"column":10},"end":{"line":47,"column":40}},{"start":{"line":47,"column":44},"end":{"line":47,"column":71}}]},"9":{"loc":{"start":{"line":50,"column":11},"end":{"line":52,"column":null}},"type":"if","locations":[{"start":{"line":50,"column":11},"end":{"line":52,"column":null}}]},"10":{"loc":{"start":{"line":55,"column":2},"end":{"line":55,"column":52}},"type":"binary-expr","locations":[{"start":{"line":55,"column":2},"end":{"line":55,"column":18}},{"start":{"line":55,"column":2},"end":{"line":55,"column":18}},{"start":{"line":55,"column":2},"end":{"line":55,"column":52}}]},"11":{"loc":{"start":{"line":61,"column":4},"end":{"line":61,"column":79}},"type":"binary-expr","locations":[{"start":{"line":61,"column":4},"end":{"line":61,"column":20}},{"start":{"line":61,"column":4},"end":{"line":61,"column":20}},{"start":{"line":61,"column":4},"end":{"line":61,"column":79}}]},"12":{"loc":{"start":{"line":63,"column":4},"end":{"line":65,"column":null}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":65,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0,0,0],"4":[0,0],"5":[0,0],"6":[0],"7":[0],"8":[0,0],"9":[0],"10":[0,0,0],"11":[0,0,0],"12":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/update.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/update.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"4":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"5":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":0},"end":{"line":11,"column":null}},"7":{"start":{"line":12,"column":0},"end":{"line":12,"column":null}},"8":{"start":{"line":13,"column":0},"end":{"line":13,"column":null}},"9":{"start":{"line":14,"column":0},"end":{"line":14,"column":null}},"10":{"start":{"line":16,"column":15},"end":{"line":71,"column":1}},"11":{"start":{"line":26,"column":16},"end":{"line":26,"column":114}},"12":{"start":{"line":28,"column":22},"end":{"line":28,"column":57}},"13":{"start":{"line":30,"column":28},"end":{"line":30,"column":30}},"14":{"start":{"line":31,"column":2},"end":{"line":34,"column":null}},"15":{"start":{"line":33,"column":4},"end":{"line":33,"column":null}},"16":{"start":{"line":36,"column":2},"end":{"line":38,"column":null}},"17":{"start":{"line":37,"column":4},"end":{"line":37,"column":null}},"18":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"19":{"start":{"line":43,"column":2},"end":{"line":49,"column":null}},"20":{"start":{"line":44,"column":4},"end":{"line":44,"column":null}},"21":{"start":{"line":45,"column":4},"end":{"line":48,"column":null}},"22":{"start":{"line":46,"column":6},"end":{"line":46,"column":null}},"23":{"start":{"line":51,"column":29},"end":{"line":51,"column":31}},"24":{"start":{"line":53,"column":2},"end":{"line":60,"column":null}},"25":{"start":{"line":54,"column":20},"end":{"line":54,"column":40}},"26":{"start":{"line":55,"column":4},"end":{"line":59,"column":null}},"27":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"28":{"start":{"line":58,"column":6},"end":{"line":58,"column":null}},"29":{"start":{"line":62,"column":2},"end":{"line":64,"column":null}},"30":{"start":{"line":63,"column":4},"end":{"line":63,"column":null}},"31":{"start":{"line":66,"column":2},"end":{"line":68,"column":null}},"32":{"start":{"line":67,"column":4},"end":{"line":67,"column":null}},"33":{"start":{"line":70,"column":2},"end":{"line":70,"column":null}},"34":{"start":{"line":71,"column":1},"end":{"line":71,"column":null}},"35":{"start":{"line":73,"column":24},"end":{"line":90,"column":1}},"36":{"start":{"line":74,"column":2},"end":{"line":74,"column":null}},"37":{"start":{"line":76,"column":39},"end":{"line":76,"column":47}},"38":{"start":{"line":78,"column":27},"end":{"line":78,"column":64}},"39":{"start":{"line":79,"column":33},"end":{"line":88,"column":4}},"40":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":16,"column":15},"end":{"line":16,"column":22}},"loc":{"start":{"line":25,"column":6},"end":{"line":71,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":73,"column":24},"end":{"line":73,"column":31}},"loc":{"start":{"line":73,"column":61},"end":{"line":90,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":26,"column":16},"end":{"line":26,"column":114}},"type":"binary-expr","locations":[{"start":{"line":26,"column":16},"end":{"line":26,"column":39}},{"start":{"line":26,"column":43},"end":{"line":26,"column":66}},{"start":{"line":26,"column":70},"end":{"line":26,"column":89}},{"start":{"line":26,"column":93},"end":{"line":26,"column":114}}]},"1":{"loc":{"start":{"line":31,"column":2},"end":{"line":34,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":34,"column":null}}]},"2":{"loc":{"start":{"line":31,"column":6},"end":{"line":31,"column":42}},"type":"binary-expr","locations":[{"start":{"line":31,"column":6},"end":{"line":31,"column":20}},{"start":{"line":31,"column":24},"end":{"line":31,"column":42}}]},"3":{"loc":{"start":{"line":36,"column":2},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":36,"column":2},"end":{"line":38,"column":null}}]},"4":{"loc":{"start":{"line":36,"column":6},"end":{"line":36,"column":38}},"type":"binary-expr","locations":[{"start":{"line":36,"column":6},"end":{"line":36,"column":20}},{"start":{"line":36,"column":24},"end":{"line":36,"column":38}}]},"5":{"loc":{"start":{"line":43,"column":2},"end":{"line":49,"column":null}},"type":"if","locations":[{"start":{"line":43,"column":2},"end":{"line":49,"column":null}}]},"6":{"loc":{"start":{"line":43,"column":6},"end":{"line":43,"column":40}},"type":"binary-expr","locations":[{"start":{"line":43,"column":6},"end":{"line":43,"column":20}},{"start":{"line":43,"column":24},"end":{"line":43,"column":40}}]},"7":{"loc":{"start":{"line":45,"column":4},"end":{"line":48,"column":null}},"type":"if","locations":[{"start":{"line":45,"column":4},"end":{"line":48,"column":null}}]},"8":{"loc":{"start":{"line":53,"column":2},"end":{"line":60,"column":null}},"type":"if","locations":[{"start":{"line":53,"column":2},"end":{"line":60,"column":null}}]},"9":{"loc":{"start":{"line":53,"column":6},"end":{"line":53,"column":42}},"type":"binary-expr","locations":[{"start":{"line":53,"column":6},"end":{"line":53,"column":20}},{"start":{"line":53,"column":24},"end":{"line":53,"column":42}}]},"10":{"loc":{"start":{"line":62,"column":2},"end":{"line":64,"column":null}},"type":"if","locations":[{"start":{"line":62,"column":2},"end":{"line":64,"column":null}}]},"11":{"loc":{"start":{"line":62,"column":6},"end":{"line":62,"column":38}},"type":"binary-expr","locations":[{"start":{"line":62,"column":6},"end":{"line":62,"column":20}},{"start":{"line":62,"column":24},"end":{"line":62,"column":38}}]},"12":{"loc":{"start":{"line":66,"column":2},"end":{"line":68,"column":null}},"type":"if","locations":[{"start":{"line":66,"column":2},"end":{"line":68,"column":null}}]},"13":{"loc":{"start":{"line":66,"column":6},"end":{"line":66,"column":76}},"type":"binary-expr","locations":[{"start":{"line":66,"column":7},"end":{"line":66,"column":21}},{"start":{"line":66,"column":25},"end":{"line":66,"column":43}},{"start":{"line":66,"column":48},"end":{"line":66,"column":76}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0},"f":{"0":0,"1":0},"b":{"0":[0,0,0,0],"1":[0],"2":[0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0],"9":[0,0],"10":[0],"11":[0,0],"12":[0],"13":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/verify.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/verify.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"2":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"3":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"4":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"5":{"start":{"line":12,"column":26},"end":{"line":12,"column":30}},"6":{"start":{"line":14,"column":15},"end":{"line":35,"column":1}},"7":{"start":{"line":15,"column":19},"end":{"line":15,"column":102}},"8":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"9":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"10":{"start":{"line":21,"column":17},"end":{"line":21,"column":19}},"11":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"12":{"start":{"line":23,"column":4},"end":{"line":23,"column":null}},"13":{"start":{"line":25,"column":2},"end":{"line":27,"column":null}},"14":{"start":{"line":26,"column":4},"end":{"line":26,"column":null}},"15":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"16":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"17":{"start":{"line":32,"column":18},"end":{"line":32,"column":43}},"18":{"start":{"line":34,"column":2},"end":{"line":34,"column":null}},"19":{"start":{"line":34,"column":42},"end":{"line":34,"column":62}},"20":{"start":{"line":34,"column":62},"end":{"line":34,"column":73}},"21":{"start":{"line":35,"column":1},"end":{"line":35,"column":null}},"22":{"start":{"line":37,"column":23},"end":{"line":74,"column":1}},"23":{"start":{"line":38,"column":2},"end":{"line":40,"column":null}},"24":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"25":{"start":{"line":41,"column":37},"end":{"line":41,"column":45}},"26":{"start":{"line":43,"column":19},"end":{"line":43,"column":48}},"27":{"start":{"line":44,"column":19},"end":{"line":44,"column":58}},"28":{"start":{"line":46,"column":22},"end":{"line":46,"column":70}},"29":{"start":{"line":47,"column":2},"end":{"line":73,"column":null}},"30":{"start":{"line":48,"column":23},"end":{"line":48,"column":86}},"31":{"start":{"line":50,"column":25},"end":{"line":50,"column":50}},"32":{"start":{"line":51,"column":25},"end":{"line":51,"column":50}},"33":{"start":{"line":52,"column":25},"end":{"line":52,"column":50}},"34":{"start":{"line":53,"column":20},"end":{"line":53,"column":69}},"35":{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},"36":{"start":{"line":55,"column":6},"end":{"line":55,"column":null}},"37":{"start":{"line":56,"column":6},"end":{"line":56,"column":null}},"38":{"start":{"line":58,"column":6},"end":{"line":58,"column":null}},"39":{"start":{"line":59,"column":6},"end":{"line":60,"column":null}},"40":{"start":{"line":63,"column":4},"end":{"line":63,"column":null}},"41":{"start":{"line":65,"column":4},"end":{"line":65,"column":null}},"42":{"start":{"line":66,"column":4},"end":{"line":66,"column":null}},"43":{"start":{"line":68,"column":4},"end":{"line":68,"column":null}},"44":{"start":{"line":70,"column":4},"end":{"line":72,"column":null}},"45":{"start":{"line":71,"column":6},"end":{"line":71,"column":null}},"46":{"start":{"line":76,"column":22},"end":{"line":104,"column":1}},"47":{"start":{"line":77,"column":2},"end":{"line":79,"column":null}},"48":{"start":{"line":78,"column":4},"end":{"line":78,"column":null}},"49":{"start":{"line":80,"column":25},"end":{"line":80,"column":33}},"50":{"start":{"line":82,"column":2},"end":{"line":103,"column":null}},"51":{"start":{"line":83,"column":27},"end":{"line":86,"column":6}},"52":{"start":{"line":88,"column":20},"end":{"line":90,"column":null}},"53":{"start":{"line":93,"column":4},"end":{"line":93,"column":null}},"54":{"start":{"line":95,"column":4},"end":{"line":98,"column":null}},"55":{"start":{"line":100,"column":4},"end":{"line":102,"column":null}},"56":{"start":{"line":101,"column":6},"end":{"line":101,"column":null}},"57":{"start":{"line":106,"column":21},"end":{"line":165,"column":1}},"58":{"start":{"line":107,"column":2},"end":{"line":109,"column":null}},"59":{"start":{"line":108,"column":4},"end":{"line":108,"column":null}},"60":{"start":{"line":111,"column":22},"end":{"line":111,"column":53}},"61":{"start":{"line":113,"column":2},"end":{"line":162,"column":null}},"62":{"start":{"line":114,"column":26},"end":{"line":114,"column":34}},"63":{"start":{"line":115,"column":21},"end":{"line":115,"column":62}},"64":{"start":{"line":116,"column":31},"end":{"line":116,"column":85}},"65":{"start":{"line":117,"column":34},"end":{"line":117,"column":97}},"66":{"start":{"line":119,"column":47},"end":{"line":121,"column":6}},"67":{"start":{"line":124,"column":4},"end":{"line":132,"column":null}},"68":{"start":{"line":125,"column":6},"end":{"line":127,"column":null}},"69":{"start":{"line":126,"column":8},"end":{"line":126,"column":null}},"70":{"start":{"line":128,"column":6},"end":{"line":128,"column":null}},"71":{"start":{"line":128,"column":35},"end":{"line":128,"column":73}},"72":{"start":{"line":130,"column":6},"end":{"line":130,"column":null}},"73":{"start":{"line":131,"column":6},"end":{"line":131,"column":null}},"74":{"start":{"line":134,"column":29},"end":{"line":134,"column":72}},"75":{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},"76":{"start":{"line":136,"column":6},"end":{"line":136,"column":null}},"77":{"start":{"line":137,"column":6},"end":{"line":140,"column":null}},"78":{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},"79":{"start":{"line":142,"column":6},"end":{"line":142,"column":null}},"80":{"start":{"line":143,"column":6},"end":{"line":143,"column":null}},"81":{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},"82":{"start":{"line":145,"column":6},"end":{"line":145,"column":null}},"83":{"start":{"line":146,"column":6},"end":{"line":146,"column":null}},"84":{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},"85":{"start":{"line":148,"column":6},"end":{"line":148,"column":null}},"86":{"start":{"line":149,"column":6},"end":{"line":150,"column":null}},"87":{"start":{"line":152,"column":6},"end":{"line":152,"column":null}},"88":{"start":{"line":153,"column":6},"end":{"line":153,"column":null}},"89":{"start":{"line":156,"column":4},"end":{"line":156,"column":null}},"90":{"start":{"line":157,"column":4},"end":{"line":157,"column":null}},"91":{"start":{"line":159,"column":4},"end":{"line":161,"column":null}},"92":{"start":{"line":160,"column":6},"end":{"line":160,"column":null}},"93":{"start":{"line":164,"column":2},"end":{"line":164,"column":null}},"94":{"start":{"line":167,"column":28},"end":{"line":180,"column":1}},"95":{"start":{"line":168,"column":17},"end":{"line":171,"column":3}},"96":{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},"97":{"start":{"line":174,"column":4},"end":{"line":174,"column":null}},"98":{"start":{"line":176,"column":4},"end":{"line":176,"column":null}},"99":{"start":{"line":179,"column":2},"end":{"line":179,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":14,"column":15},"end":{"line":14,"column":22}},"loc":{"start":{"line":14,"column":82},"end":{"line":35,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":34,"column":24},"end":{"line":34,"column":25}},"loc":{"start":{"line":34,"column":40},"end":{"line":34,"column":74}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":37,"column":23},"end":{"line":37,"column":30}},"loc":{"start":{"line":37,"column":76},"end":{"line":74,"column":1}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":76,"column":22},"end":{"line":76,"column":29}},"loc":{"start":{"line":76,"column":62},"end":{"line":104,"column":1}}},"4":{"name":"(anonymous_4)","decl":{"start":{"line":106,"column":21},"end":{"line":106,"column":28}},"loc":{"start":{"line":106,"column":74},"end":{"line":165,"column":1}}},"5":{"name":"(anonymous_5)","decl":{"start":{"line":128,"column":24},"end":{"line":128,"column":31}},"loc":{"start":{"line":128,"column":35},"end":{"line":128,"column":73}}},"6":{"name":"(anonymous_6)","decl":{"start":{"line":167,"column":28},"end":{"line":167,"column":29}},"loc":{"start":{"line":167,"column":59},"end":{"line":180,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":15,"column":19},"end":{"line":15,"column":102}},"type":"binary-expr","locations":[{"start":{"line":15,"column":19},"end":{"line":15,"column":45}},{"start":{"line":15,"column":49},"end":{"line":15,"column":74}},{"start":{"line":15,"column":78},"end":{"line":15,"column":102}}]},"1":{"loc":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":2},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":6},"end":{"line":17,"column":44}},"type":"binary-expr","locations":[{"start":{"line":17,"column":6},"end":{"line":17,"column":14}},{"start":{"line":17,"column":18},"end":{"line":17,"column":30}},{"start":{"line":17,"column":34},"end":{"line":17,"column":44}}]},"3":{"loc":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":22,"column":2},"end":{"line":24,"column":null}}]},"4":{"loc":{"start":{"line":22,"column":6},"end":{"line":22,"column":29}},"type":"binary-expr","locations":[{"start":{"line":22,"column":6},"end":{"line":22,"column":14}},{"start":{"line":22,"column":18},"end":{"line":22,"column":29}}]},"5":{"loc":{"start":{"line":25,"column":2},"end":{"line":27,"column":null}},"type":"if","locations":[{"start":{"line":25,"column":2},"end":{"line":27,"column":null}}]},"6":{"loc":{"start":{"line":25,"column":6},"end":{"line":25,"column":30}},"type":"binary-expr","locations":[{"start":{"line":25,"column":6},"end":{"line":25,"column":14}},{"start":{"line":25,"column":18},"end":{"line":25,"column":30}}]},"7":{"loc":{"start":{"line":28,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":28,"column":2},"end":{"line":30,"column":null}}]},"8":{"loc":{"start":{"line":28,"column":6},"end":{"line":28,"column":28}},"type":"binary-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":14}},{"start":{"line":28,"column":18},"end":{"line":28,"column":28}}]},"9":{"loc":{"start":{"line":38,"column":2},"end":{"line":40,"column":null}},"type":"if","locations":[{"start":{"line":38,"column":2},"end":{"line":40,"column":null}}]},"10":{"loc":{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},"type":"if","locations":[{"start":{"line":54,"column":4},"end":{"line":61,"column":null}},{"start":{"line":57,"column":11},"end":{"line":61,"column":null}}]},"11":{"loc":{"start":{"line":70,"column":4},"end":{"line":72,"column":null}},"type":"if","locations":[{"start":{"line":70,"column":4},"end":{"line":72,"column":null}}]},"12":{"loc":{"start":{"line":77,"column":2},"end":{"line":79,"column":null}},"type":"if","locations":[{"start":{"line":77,"column":2},"end":{"line":79,"column":null}}]},"13":{"loc":{"start":{"line":100,"column":4},"end":{"line":102,"column":null}},"type":"if","locations":[{"start":{"line":100,"column":4},"end":{"line":102,"column":null}}]},"14":{"loc":{"start":{"line":107,"column":2},"end":{"line":109,"column":null}},"type":"if","locations":[{"start":{"line":107,"column":2},"end":{"line":109,"column":null}}]},"15":{"loc":{"start":{"line":125,"column":6},"end":{"line":127,"column":null}},"type":"if","locations":[{"start":{"line":125,"column":6},"end":{"line":127,"column":null}}]},"16":{"loc":{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":135,"column":4},"end":{"line":154,"column":null}},{"start":{"line":141,"column":11},"end":{"line":154,"column":null}}]},"17":{"loc":{"start":{"line":137,"column":29},"end":{"line":139,"column":35}},"type":"cond-expr","locations":[{"start":{"line":138,"column":10},"end":{"line":138,"column":43}},{"start":{"line":139,"column":10},"end":{"line":139,"column":35}}]},"18":{"loc":{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":141,"column":11},"end":{"line":154,"column":null}},{"start":{"line":144,"column":11},"end":{"line":154,"column":null}}]},"19":{"loc":{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":144,"column":11},"end":{"line":154,"column":null}},{"start":{"line":147,"column":11},"end":{"line":154,"column":null}}]},"20":{"loc":{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},"type":"if","locations":[{"start":{"line":147,"column":11},"end":{"line":154,"column":null}},{"start":{"line":151,"column":11},"end":{"line":154,"column":null}}]},"21":{"loc":{"start":{"line":159,"column":4},"end":{"line":161,"column":null}},"type":"if","locations":[{"start":{"line":159,"column":4},"end":{"line":161,"column":null}}]},"22":{"loc":{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},"type":"if","locations":[{"start":{"line":173,"column":2},"end":{"line":177,"column":null}},{"start":{"line":175,"column":9},"end":{"line":177,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0},"b":{"0":[0,0,0],"1":[0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0,0],"9":[0],"10":[0,0],"11":[0],"12":[0],"13":[0],"14":[0],"15":[0],"16":[0,0],"17":[0,0],"18":[0,0],"19":[0,0],"20":[0,0],"21":[0],"22":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/add-tags-to-hosted-zone.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/add-tags-to-hosted-zone.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":28},"end":{"line":18,"column":1}},"4":{"start":{"line":7,"column":18},"end":{"line":7,"column":38}},"5":{"start":{"line":8,"column":24},"end":{"line":8,"column":58}},"6":{"start":{"line":10,"column":23},"end":{"line":10,"column":73}},"7":{"start":{"line":12,"column":39},"end":{"line":16,"column":4}},"8":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"9":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":28},"end":{"line":6,"column":35}},"loc":{"start":{"line":6,"column":65},"end":{"line":18,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/associate-cost-allocation-tags.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/associate-cost-allocation-tags.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":36},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":29},"end":{"line":6,"column":68}},"4":{"start":{"line":7,"column":48},"end":{"line":9,"column":4}},"5":{"start":{"line":10,"column":2},"end":{"line":10,"column":null}},"6":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}},"7":{"start":{"line":13,"column":47},"end":{"line":17,"column":1}},"8":{"start":{"line":14,"column":25},"end":{"line":14,"column":33}},"9":{"start":{"line":16,"column":2},"end":{"line":16,"column":null}},"10":{"start":{"line":17,"column":1},"end":{"line":17,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":36},"end":{"line":5,"column":43}},"loc":{"start":{"line":5,"column":68},"end":{"line":11,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":13,"column":47},"end":{"line":13,"column":48}},"loc":{"start":{"line":13,"column":74},"end":{"line":17,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0,"1":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/create-or-update-dns-records.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/create-or-update-dns-records.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":33},"end":{"line":41,"column":1}},"5":{"start":{"line":8,"column":59},"end":{"line":8,"column":67}},"6":{"start":{"line":10,"column":27},"end":{"line":10,"column":72}},"7":{"start":{"line":11,"column":33},"end":{"line":11,"column":94}},"8":{"start":{"line":12,"column":31},"end":{"line":12,"column":82}},"9":{"start":{"line":13,"column":33},"end":{"line":13,"column":77}},"10":{"start":{"line":15,"column":24},"end":{"line":15,"column":66}},"11":{"start":{"line":17,"column":23},"end":{"line":17,"column":73}},"12":{"start":{"line":19,"column":18},"end":{"line":19,"column":51}},"13":{"start":{"line":21,"column":41},"end":{"line":38,"column":4}},"14":{"start":{"line":25,"column":39},"end":{"line":36,"column":7}},"15":{"start":{"line":39,"column":2},"end":{"line":39,"column":null}},"16":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"17":{"start":{"line":41,"column":1},"end":{"line":41,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":33},"end":{"line":7,"column":40}},"loc":{"start":{"line":7,"column":70},"end":{"line":41,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":25,"column":29},"end":{"line":25,"column":33}},"loc":{"start":{"line":25,"column":39},"end":{"line":36,"column":7}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0,"1":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/find-certificate.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/find-certificate.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":24},"end":{"line":27,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":8,"column":2},"end":{"line":22,"column":null}},"5":{"start":{"line":9,"column":36},"end":{"line":11,"column":6}},"6":{"start":{"line":12,"column":25},"end":{"line":12,"column":70}},"7":{"start":{"line":14,"column":19},"end":{"line":14,"column":36}},"8":{"start":{"line":15,"column":4},"end":{"line":20,"column":null}},"9":{"start":{"line":16,"column":6},"end":{"line":19,"column":null}},"10":{"start":{"line":17,"column":8},"end":{"line":17,"column":null}},"11":{"start":{"line":18,"column":8},"end":{"line":18,"column":null}},"12":{"start":{"line":21,"column":4},"end":{"line":21,"column":null}},"13":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"14":{"start":{"line":26,"column":2},"end":{"line":26,"column":null}},"15":{"start":{"line":27,"column":1},"end":{"line":27,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":24},"end":{"line":5,"column":31}},"loc":{"start":{"line":5,"column":61},"end":{"line":27,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":65}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":65}}]},"1":{"loc":{"start":{"line":16,"column":6},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":6},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":8},"end":{"line":17,"column":40}},"type":"binary-expr","locations":[{"start":{"line":17,"column":8},"end":{"line":17,"column":24}},{"start":{"line":17,"column":8},"end":{"line":17,"column":24}},{"start":{"line":17,"column":8},"end":{"line":17,"column":40}}]},"3":{"loc":{"start":{"line":25,"column":2},"end":{"line":25,"column":36}},"type":"binary-expr","locations":[{"start":{"line":25,"column":2},"end":{"line":25,"column":18}},{"start":{"line":25,"column":2},"end":{"line":25,"column":18}},{"start":{"line":25,"column":2},"end":{"line":25,"column":36}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0},"f":{"0":0},"b":{"0":[0,0,0],"1":[0],"2":[0,0,0],"3":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-credentials.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-credentials.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":23},"end":{"line":9,"column":1}},"2":{"start":{"line":4,"column":2},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":22},"end":{"line":6,"column":55}},"4":{"start":{"line":8,"column":2},"end":{"line":8,"column":null}},"5":{"start":{"line":9,"column":1},"end":{"line":9,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":23},"end":{"line":3,"column":24}},"loc":{"start":{"line":3,"column":58},"end":{"line":9,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":15},"end":{"line":4,"column":65}},"type":"binary-expr","locations":[{"start":{"line":4,"column":15},"end":{"line":4,"column":25}},{"start":{"line":4,"column":29},"end":{"line":4,"column":52}},{"start":{"line":4,"column":56},"end":{"line":4,"column":65}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0},"f":{"0":0},"b":{"0":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-hosted-zone-id.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/get-hosted-zone-id.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":24},"end":{"line":19,"column":1}},"2":{"start":{"line":5,"column":2},"end":{"line":18,"column":null}},"3":{"start":{"line":6,"column":35},"end":{"line":6,"column":87}},"4":{"start":{"line":7,"column":36},"end":{"line":7,"column":84}},"5":{"start":{"line":9,"column":4},"end":{"line":13,"column":null}},"6":{"start":{"line":10,"column":6},"end":{"line":12,"column":null}},"7":{"start":{"line":11,"column":8},"end":{"line":11,"column":49}},"8":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"9":{"start":{"line":16,"column":6},"end":{"line":16,"column":null}},"10":{"start":{"line":19,"column":1},"end":{"line":19,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":24},"end":{"line":3,"column":31}},"loc":{"start":{"line":3,"column":63},"end":{"line":19,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":6},"end":{"line":12,"column":null}},"type":"if","locations":[{"start":{"line":10,"column":6},"end":{"line":12,"column":null}}]},"1":{"loc":{"start":{"line":15,"column":4},"end":{"line":17,"column":null}},"type":"if","locations":[{"start":{"line":15,"column":4},"end":{"line":17,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0],"1":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/sync-site-content.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/sync-site-content.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":61}},"7":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"8":{"start":{"line":11,"column":24},"end":{"line":34,"column":1}},"9":{"start":{"line":12,"column":49},"end":{"line":12,"column":57}},"10":{"start":{"line":14,"column":2},"end":{"line":22,"column":null}},"11":{"start":{"line":15,"column":24},"end":{"line":15,"column":56}},"12":{"start":{"line":16,"column":24},"end":{"line":16,"column":64}},"13":{"start":{"line":17,"column":4},"end":{"line":21,"column":null}},"14":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"15":{"start":{"line":19,"column":6},"end":{"line":19,"column":null}},"16":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"17":{"start":{"line":24,"column":2},"end":{"line":24,"column":null}},"18":{"start":{"line":26,"column":19},"end":{"line":26,"column":48}},"19":{"start":{"line":27,"column":19},"end":{"line":27,"column":58}},"20":{"start":{"line":29,"column":2},"end":{"line":33,"column":null}},"21":{"start":{"line":30,"column":41},"end":{"line":30,"column":111}},"22":{"start":{"line":34,"column":1},"end":{"line":34,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":11,"column":24},"end":{"line":11,"column":31}},"loc":{"start":{"line":11,"column":70},"end":{"line":34,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":30,"column":30},"end":{"line":30,"column":35}},"loc":{"start":{"line":30,"column":41},"end":{"line":30,"column":111}}}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"1":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"cond-expr","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"2":{"loc":{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},"type":"binary-expr","locations":[{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}},{"start":{"line":9,"column":61},"end":{"line":9,"column":null}}]},"3":{"loc":{"start":{"line":14,"column":2},"end":{"line":22,"column":null}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":22,"column":null}}]},"4":{"loc":{"start":{"line":14,"column":6},"end":{"line":14,"column":53}},"type":"binary-expr","locations":[{"start":{"line":14,"column":6},"end":{"line":14,"column":22}},{"start":{"line":14,"column":26},"end":{"line":14,"column":53}}]},"5":{"loc":{"start":{"line":17,"column":4},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":4},"end":{"line":21,"column":null}}]},"6":{"loc":{"start":{"line":30,"column":57},"end":{"line":30,"column":110}},"type":"binary-expr","locations":[{"start":{"line":30,"column":57},"end":{"line":30,"column":79}},{"start":{"line":30,"column":83},"end":{"line":30,"column":110}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/track-stack-status.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/track-stack-status.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":26},"end":{"line":5,"column":30}},"3":{"start":{"line":7,"column":25},"end":{"line":41,"column":1}},"4":{"start":{"line":9,"column":2},"end":{"line":29,"column":null}},"5":{"start":{"line":10,"column":26},"end":{"line":10,"column":51}},"6":{"start":{"line":11,"column":28},"end":{"line":11,"column":68}},"7":{"start":{"line":12,"column":29},"end":{"line":12,"column":77}},"8":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"9":{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},"10":{"start":{"line":18,"column":28},"end":{"line":18,"column":108}},"11":{"start":{"line":19,"column":6},"end":{"line":19,"column":null}},"12":{"start":{"line":20,"column":6},"end":{"line":22,"column":null}},"13":{"start":{"line":21,"column":8},"end":{"line":21,"column":null}},"14":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"15":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"16":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"17":{"start":{"line":28,"column":33},"end":{"line":28,"column":71}},"18":{"start":{"line":31,"column":2},"end":{"line":38,"column":null}},"19":{"start":{"line":32,"column":4},"end":{"line":32,"column":null}},"20":{"start":{"line":33,"column":24},"end":{"line":33,"column":49}},"21":{"start":{"line":34,"column":26},"end":{"line":34,"column":61}},"22":{"start":{"line":35,"column":4},"end":{"line":35,"column":null}},"23":{"start":{"line":37,"column":4},"end":{"line":37,"column":null}},"24":{"start":{"line":40,"column":2},"end":{"line":40,"column":null}},"25":{"start":{"line":41,"column":1},"end":{"line":41,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":25},"end":{"line":7,"column":32}},"loc":{"start":{"line":7,"column":108},"end":{"line":41,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":28,"column":22},"end":{"line":28,"column":29}},"loc":{"start":{"line":28,"column":33},"end":{"line":28,"column":71}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":25,"column":null}},{"start":{"line":23,"column":11},"end":{"line":25,"column":null}}]},"1":{"loc":{"start":{"line":16,"column":8},"end":{"line":16,"column":100}},"type":"binary-expr","locations":[{"start":{"line":16,"column":8},"end":{"line":16,"column":38}},{"start":{"line":16,"column":43},"end":{"line":16,"column":67}},{"start":{"line":16,"column":71},"end":{"line":16,"column":99}}]},"2":{"loc":{"start":{"line":19,"column":28},"end":{"line":19,"column":68}},"type":"cond-expr","locations":[{"start":{"line":19,"column":59},"end":{"line":19,"column":63}},{"start":{"line":19,"column":66},"end":{"line":19,"column":68}}]},"3":{"loc":{"start":{"line":20,"column":6},"end":{"line":22,"column":null}},"type":"if","locations":[{"start":{"line":20,"column":6},"end":{"line":22,"column":null}}]},"4":{"loc":{"start":{"line":31,"column":2},"end":{"line":38,"column":null}},"type":"if","locations":[{"start":{"line":31,"column":2},"end":{"line":38,"column":null}}]},"5":{"loc":{"start":{"line":31,"column":6},"end":{"line":31,"column":71}},"type":"binary-expr","locations":[{"start":{"line":31,"column":6},"end":{"line":31,"column":41}},{"start":{"line":31,"column":45},"end":{"line":31,"column":71}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0},"f":{"0":0,"1":0},"b":{"0":[0,0],"1":[0,0,0],"2":[0,0],"3":[0],"4":[0],"5":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-plugins.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-plugins.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":40}},"1":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"2":{"start":{"line":3,"column":22},"end":{"line":18,"column":1}},"3":{"start":{"line":4,"column":48},"end":{"line":4,"column":56}},"4":{"start":{"line":5,"column":18},"end":{"line":5,"column":20}},"5":{"start":{"line":7,"column":2},"end":{"line":15,"column":null}},"6":{"start":{"line":8,"column":19},"end":{"line":8,"column":37}},"7":{"start":{"line":9,"column":4},"end":{"line":11,"column":null}},"8":{"start":{"line":10,"column":6},"end":{"line":10,"column":null}},"9":{"start":{"line":13,"column":30},"end":{"line":13,"column":36}},"10":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"11":{"start":{"line":17,"column":2},"end":{"line":17,"column":null}},"12":{"start":{"line":18,"column":1},"end":{"line":18,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":3,"column":22},"end":{"line":3,"column":29}},"loc":{"start":{"line":3,"column":59},"end":{"line":18,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"if","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"1":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"cond-expr","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"2":{"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},"type":"binary-expr","locations":[{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}},{"start":{"line":1,"column":40},"end":{"line":1,"column":null}}]},"3":{"loc":{"start":{"line":9,"column":4},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":9,"column":4},"end":{"line":11,"column":null}}]},"4":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":71}},"type":"cond-expr","locations":[{"start":{"line":14,"column":30},"end":{"line":14,"column":33}},{"start":{"line":14,"column":17},"end":{"line":14,"column":71}}]},"5":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":33}},"type":"binary-expr","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":33}},{"start":{"line":14,"column":17},"end":{"line":14,"column":33}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-site-info.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-site-info.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":23},"end":{"line":15,"column":1}},"3":{"start":{"line":6,"column":32},"end":{"line":6,"column":40}},"4":{"start":{"line":7,"column":2},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":31},"end":{"line":8,"column":80}},"6":{"start":{"line":9,"column":26},"end":{"line":9,"column":78}},"7":{"start":{"line":10,"column":27},"end":{"line":10,"column":75}},"8":{"start":{"line":11,"column":35},"end":{"line":12,"column":102}},"9":{"start":{"line":12,"column":47},"end":{"line":12,"column":89}},"10":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"11":{"start":{"line":15,"column":1},"end":{"line":15,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":23},"end":{"line":5,"column":30}},"loc":{"start":{"line":5,"column":60},"end":{"line":15,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":12,"column":28},"end":{"line":12,"column":29}},"loc":{"start":{"line":12,"column":47},"end":{"line":12,"column":89}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0},"f":{"0":0,"1":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-stack.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/actions/lib/update-stack.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"6":{"start":{"line":8,"column":0},"end":{"line":8,"column":51}},"7":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"8":{"start":{"line":10,"column":20},"end":{"line":64,"column":1}},"9":{"start":{"line":11,"column":32},"end":{"line":11,"column":40}},"10":{"start":{"line":13,"column":23},"end":{"line":13,"column":66}},"11":{"start":{"line":14,"column":2},"end":{"line":14,"column":null}},"12":{"start":{"line":15,"column":2},"end":{"line":15,"column":null}},"13":{"start":{"line":17,"column":22},"end":{"line":17,"column":43}},"14":{"start":{"line":19,"column":31},"end":{"line":19,"column":80}},"15":{"start":{"line":20,"column":29},"end":{"line":23,"column":4}},"16":{"start":{"line":24,"column":30},"end":{"line":24,"column":81}},"17":{"start":{"line":25,"column":26},"end":{"line":25,"column":58}},"18":{"start":{"line":27,"column":2},"end":{"line":30,"column":null}},"19":{"start":{"line":28,"column":4},"end":{"line":28,"column":null}},"20":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"21":{"start":{"line":33,"column":29},"end":{"line":39,"column":4}},"22":{"start":{"line":41,"column":2},"end":{"line":41,"column":null}},"23":{"start":{"line":43,"column":22},"end":{"line":43,"column":107}},"24":{"start":{"line":45,"column":2},"end":{"line":45,"column":50}},"25":{"start":{"line":47,"column":29},"end":{"line":50,"column":71}},"26":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}},"27":{"start":{"line":50,"column":39},"end":{"line":50,"column":70}},"28":{"start":{"line":52,"column":2},"end":{"line":57,"column":null}},"29":{"start":{"line":53,"column":4},"end":{"line":56,"column":null}},"30":{"start":{"line":55,"column":8},"end":{"line":55,"column":76}},"31":{"start":{"line":59,"column":2},"end":{"line":61,"column":null}},"32":{"start":{"line":60,"column":4},"end":{"line":60,"column":null}},"33":{"start":{"line":63,"column":2},"end":{"line":63,"column":null}},"34":{"start":{"line":64,"column":1},"end":{"line":64,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":10,"column":20},"end":{"line":10,"column":27}},"loc":{"start":{"line":10,"column":57},"end":{"line":64,"column":1}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":47,"column":77},"end":{"line":47,"column":86}},"loc":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":50,"column":12},"end":{"line":50,"column":13}},"loc":{"start":{"line":50,"column":39},"end":{"line":50,"column":70}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":54,"column":33},"end":{"line":54,"column":34}},"loc":{"start":{"line":55,"column":8},"end":{"line":55,"column":76}}}},"branchMap":{"0":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"if","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"1":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"cond-expr","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"2":{"loc":{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},"type":"binary-expr","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}},{"start":{"line":8,"column":51},"end":{"line":8,"column":null}}]},"3":{"loc":{"start":{"line":27,"column":2},"end":{"line":30,"column":null}},"type":"if","locations":[{"start":{"line":27,"column":2},"end":{"line":30,"column":null}}]},"4":{"loc":{"start":{"line":47,"column":41},"end":{"line":47,"column":70}},"type":"binary-expr","locations":[{"start":{"line":47,"column":41},"end":{"line":47,"column":64}},{"start":{"line":47,"column":68},"end":{"line":47,"column":70}}]},"5":{"loc":{"start":{"line":52,"column":2},"end":{"line":57,"column":null}},"type":"if","locations":[{"start":{"line":52,"column":2},"end":{"line":57,"column":null}}]},"6":{"loc":{"start":{"line":59,"column":2},"end":{"line":61,"column":null}},"type":"if","locations":[{"start":{"line":59,"column":2},"end":{"line":61,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0],"6":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/access-logs.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/access-logs.mjs","statementMap":{"0":{"start":{"line":1,"column":15},"end":{"line":3,"column":1}},"1":{"start":{"line":2,"column":50},"end":{"line":2,"column":73}},"2":{"start":{"line":5,"column":16},"end":{"line":7,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":9,"column":22},"end":{"line":9,"column":30}},"5":{"start":{"line":11,"column":16},"end":{"line":11,"column":53}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":2,"column":44},"end":{"line":2,"column":45}},"loc":{"start":{"line":2,"column":50},"end":{"line":2,"column":73}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":5,"column":16},"end":{"line":5,"column":22}},"loc":{"start":{"line":5,"column":22},"end":{"line":7,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":9,"column":22},"end":{"line":9,"column":28}},"loc":{"start":{"line":9,"column":28},"end":{"line":9,"column":30}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0},"f":{"0":0,"1":0,"2":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/cloudfront-logs.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/cloudfront-logs.mjs","statementMap":{"0":{"start":{"line":1,"column":15},"end":{"line":12,"column":1}},"1":{"start":{"line":9,"column":27},"end":{"line":9,"column":null}},"2":{"start":{"line":14,"column":22},"end":{"line":22,"column":1}},"3":{"start":{"line":15,"column":34},"end":{"line":15,"column":117}},"4":{"start":{"line":16,"column":2},"end":{"line":21,"column":null}},"5":{"start":{"line":17,"column":21},"end":{"line":19,"column":5}},"6":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"7":{"start":{"line":24,"column":31},"end":{"line":26,"column":1}},"8":{"start":{"line":25,"column":2},"end":{"line":25,"column":null}},"9":{"start":{"line":28,"column":20},"end":{"line":38,"column":1}},"10":{"start":{"line":29,"column":28},"end":{"line":29,"column":40}},"11":{"start":{"line":31,"column":2},"end":{"line":31,"column":null}},"12":{"start":{"line":33,"column":2},"end":{"line":37,"column":null}},"13":{"start":{"line":40,"column":20},"end":{"line":40,"column":85}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":21},"end":{"line":9,"column":22}},"loc":{"start":{"line":9,"column":27},"end":{"line":9,"column":null}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":14,"column":22},"end":{"line":14,"column":23}},"loc":{"start":{"line":14,"column":94},"end":{"line":22,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":24,"column":31},"end":{"line":24,"column":38}},"loc":{"start":{"line":24,"column":59},"end":{"line":26,"column":1}}},"3":{"name":"(anonymous_3)","decl":{"start":{"line":28,"column":20},"end":{"line":28,"column":27}},"loc":{"start":{"line":28,"column":60},"end":{"line":38,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":2},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":16,"column":2},"end":{"line":21,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0},"f":{"0":0,"1":0,"2":0,"3":0},"b":{"0":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/constants.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/constants.mjs","statementMap":{"0":{"start":{"line":1,"column":37},"end":{"line":1,"column":68}},"1":{"start":{"line":2,"column":37},"end":{"line":2,"column":68}},"2":{"start":{"line":3,"column":36},"end":{"line":3,"column":66}},"3":{"start":{"line":5,"column":33},"end":{"line":30,"column":1}}},"fnMap":{},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0},"f":{},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":36},"end":{"line":32,"column":1}},"4":{"start":{"line":8,"column":23},"end":{"line":8,"column":35}},"5":{"start":{"line":9,"column":21},"end":{"line":9,"column":29}},"6":{"start":{"line":10,"column":20},"end":{"line":10,"column":28}},"7":{"start":{"line":12,"column":23},"end":{"line":12,"column":64}},"8":{"start":{"line":13,"column":2},"end":{"line":31,"column":null}},"9":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"10":{"start":{"line":15,"column":31},"end":{"line":15,"column":85}},"11":{"start":{"line":16,"column":4},"end":{"line":26,"column":null}},"12":{"start":{"line":17,"column":6},"end":{"line":17,"column":null}},"13":{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},"14":{"start":{"line":20,"column":8},"end":{"line":20,"column":null}},"15":{"start":{"line":21,"column":8},"end":{"line":21,"column":null}},"16":{"start":{"line":23,"column":8},"end":{"line":23,"column":null}},"17":{"start":{"line":24,"column":8},"end":{"line":24,"column":null}},"18":{"start":{"line":27,"column":4},"end":{"line":27,"column":null}},"19":{"start":{"line":28,"column":21},"end":{"line":28,"column":41}},"20":{"start":{"line":29,"column":4},"end":{"line":29,"column":null}},"21":{"start":{"line":30,"column":4},"end":{"line":30,"column":null}},"22":{"start":{"line":32,"column":1},"end":{"line":32,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":36},"end":{"line":7,"column":43}},"loc":{"start":{"line":7,"column":87},"end":{"line":32,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":89}},"type":"binary-expr","locations":[{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":89}}]},"1":{"loc":{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":19,"column":6},"end":{"line":25,"column":null}},{"start":{"line":22,"column":13},"end":{"line":25,"column":null}}]},"2":{"loc":{"start":{"line":19,"column":10},"end":{"line":19,"column":70}},"type":"binary-expr","locations":[{"start":{"line":19,"column":10},"end":{"line":19,"column":31}},{"start":{"line":19,"column":35},"end":{"line":19,"column":70}}]},"3":{"loc":{"start":{"line":19,"column":35},"end":{"line":19,"column":62}},"type":"cond-expr","locations":[{"start":{"line":19,"column":46},"end":{"line":19,"column":48}},{"start":{"line":19,"column":35},"end":{"line":19,"column":62}}]},"4":{"loc":{"start":{"line":19,"column":35},"end":{"line":19,"column":48}},"type":"binary-expr","locations":[{"start":{"line":19,"column":35},"end":{"line":19,"column":48}},{"start":{"line":19,"column":46},"end":{"line":19,"column":48}}]},"5":{"loc":{"start":{"line":20,"column":8},"end":{"line":20,"column":39}},"type":"binary-expr","locations":[{"start":{"line":20,"column":8},"end":{"line":20,"column":24}},{"start":{"line":20,"column":8},"end":{"line":20,"column":24}},{"start":{"line":20,"column":8},"end":{"line":20,"column":39}}]},"6":{"loc":{"start":{"line":23,"column":8},"end":{"line":23,"column":35}},"type":"binary-expr","locations":[{"start":{"line":23,"column":8},"end":{"line":23,"column":24}},{"start":{"line":23,"column":8},"end":{"line":23,"column":24}},{"start":{"line":23,"column":8},"end":{"line":23,"column":35}}]},"7":{"loc":{"start":{"line":27,"column":4},"end":{"line":27,"column":39}},"type":"binary-expr","locations":[{"start":{"line":27,"column":4},"end":{"line":27,"column":20}},{"start":{"line":27,"column":4},"end":{"line":27,"column":20}},{"start":{"line":27,"column":4},"end":{"line":27,"column":39}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0},"f":{"0":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0,0],"6":[0,0,0],"7":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":151,"column":1}},"6":{"start":{"line":9,"column":38},"end":{"line":9,"column":50}},"7":{"start":{"line":10,"column":25},"end":{"line":10,"column":33}},"8":{"start":{"line":15,"column":6},"end":{"line":15,"column":25}},"9":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"10":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"11":{"start":{"line":22,"column":2},"end":{"line":24,"column":null}},"12":{"start":{"line":26,"column":34},"end":{"line":26,"column":92}},"13":{"start":{"line":27,"column":30},"end":{"line":33,"column":9}},"14":{"start":{"line":34,"column":2},"end":{"line":34,"column":null}},"15":{"start":{"line":35,"column":38},"end":{"line":35,"column":57}},"16":{"start":{"line":37,"column":25},"end":{"line":39,"column":16}},"17":{"start":{"line":41,"column":18},"end":{"line":41,"column":38}},"18":{"start":{"line":42,"column":15},"end":{"line":42,"column":46}},"19":{"start":{"line":44,"column":2},"end":{"line":51,"column":null}},"20":{"start":{"line":53,"column":2},"end":{"line":92,"column":null}},"21":{"start":{"line":94,"column":2},"end":{"line":124,"column":null}},"22":{"start":{"line":126,"column":2},"end":{"line":134,"column":null}},"23":{"start":{"line":136,"column":2},"end":{"line":139,"column":null}},"24":{"start":{"line":137,"column":4},"end":{"line":138,"column":null}},"25":{"start":{"line":141,"column":2},"end":{"line":150,"column":null}},"26":{"start":{"line":142,"column":19},"end":{"line":142,"column":52}},"27":{"start":{"line":143,"column":20},"end":{"line":148,"column":6}},"28":{"start":{"line":149,"column":4},"end":{"line":149,"column":null}},"29":{"start":{"line":151,"column":1},"end":{"line":151,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":8,"column":116},"end":{"line":151,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"type":"default-arg","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":null}}]},"1":{"loc":{"start":{"line":17,"column":2},"end":{"line":19,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":2},"end":{"line":19,"column":null}}]},"2":{"loc":{"start":{"line":17,"column":6},"end":{"line":17,"column":86}},"type":"binary-expr","locations":[{"start":{"line":17,"column":6},"end":{"line":17,"column":43}},{"start":{"line":17,"column":47},"end":{"line":17,"column":86}}]},"3":{"loc":{"start":{"line":27,"column":30},"end":{"line":33,"column":9}},"type":"cond-expr","locations":[{"start":{"line":28,"column":6},"end":{"line":28,"column":36}},{"start":{"line":29,"column":7},"end":{"line":33,"column":9}}]},"4":{"loc":{"start":{"line":37,"column":25},"end":{"line":39,"column":16}},"type":"cond-expr","locations":[{"start":{"line":38,"column":6},"end":{"line":38,"column":42}},{"start":{"line":39,"column":6},"end":{"line":39,"column":16}}]},"5":{"loc":{"start":{"line":136,"column":2},"end":{"line":139,"column":null}},"type":"if","locations":[{"start":{"line":136,"column":2},"end":{"line":139,"column":null}}]},"6":{"loc":{"start":{"line":141,"column":2},"end":{"line":150,"column":null}},"type":"if","locations":[{"start":{"line":141,"column":2},"end":{"line":150,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0],"6":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":30},"end":{"line":29,"column":1}},"2":{"start":{"line":4,"column":43},"end":{"line":4,"column":55}},"3":{"start":{"line":5,"column":25},"end":{"line":5,"column":33}},"4":{"start":{"line":7,"column":18},"end":{"line":7,"column":38}},"5":{"start":{"line":8,"column":15},"end":{"line":8,"column":46}},"6":{"start":{"line":10,"column":2},"end":{"line":25,"column":null}},"7":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"8":{"start":{"line":28,"column":2},"end":{"line":28,"column":null}},"9":{"start":{"line":29,"column":1},"end":{"line":29,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":3,"column":30},"end":{"line":3,"column":31}},"loc":{"start":{"line":3,"column":62},"end":{"line":29,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-handler.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-contact-handler.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"4":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"5":{"start":{"line":8,"column":28},"end":{"line":174,"column":1}},"6":{"start":{"line":16,"column":56},"end":{"line":16,"column":64}},"7":{"start":{"line":17,"column":43},"end":{"line":17,"column":55}},"8":{"start":{"line":19,"column":41},"end":{"line":19,"column":99}},"9":{"start":{"line":20,"column":37},"end":{"line":26,"column":9}},"10":{"start":{"line":27,"column":2},"end":{"line":27,"column":null}},"11":{"start":{"line":29,"column":37},"end":{"line":29,"column":63}},"12":{"start":{"line":31,"column":38},"end":{"line":31,"column":57}},"13":{"start":{"line":32,"column":25},"end":{"line":34,"column":16}},"14":{"start":{"line":36,"column":18},"end":{"line":36,"column":38}},"15":{"start":{"line":37,"column":15},"end":{"line":37,"column":46}},"16":{"start":{"line":39,"column":2},"end":{"line":86,"column":null}},"17":{"start":{"line":87,"column":2},"end":{"line":87,"column":null}},"18":{"start":{"line":88,"column":2},"end":{"line":88,"column":null}},"19":{"start":{"line":90,"column":2},"end":{"line":98,"column":null}},"20":{"start":{"line":100,"column":2},"end":{"line":129,"column":null}},"21":{"start":{"line":130,"column":2},"end":{"line":130,"column":null}},"22":{"start":{"line":131,"column":2},"end":{"line":131,"column":null}},"23":{"start":{"line":133,"column":2},"end":{"line":145,"column":null}},"24":{"start":{"line":147,"column":2},"end":{"line":160,"column":null}},"25":{"start":{"line":161,"column":2},"end":{"line":161,"column":null}},"26":{"start":{"line":162,"column":2},"end":{"line":162,"column":null}},"27":{"start":{"line":164,"column":2},"end":{"line":173,"column":null}},"28":{"start":{"line":165,"column":19},"end":{"line":165,"column":52}},"29":{"start":{"line":166,"column":20},"end":{"line":171,"column":6}},"30":{"start":{"line":172,"column":4},"end":{"line":172,"column":null}},"31":{"start":{"line":174,"column":1},"end":{"line":174,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":28},"end":{"line":8,"column":35}},"loc":{"start":{"line":15,"column":6},"end":{"line":174,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":37},"end":{"line":26,"column":9}},"type":"cond-expr","locations":[{"start":{"line":21,"column":6},"end":{"line":21,"column":43}},{"start":{"line":22,"column":7},"end":{"line":26,"column":9}}]},"1":{"loc":{"start":{"line":31,"column":10},"end":{"line":31,"column":34}},"type":"default-arg","locations":[{"start":{"line":31,"column":23},"end":{"line":31,"column":34}}]},"2":{"loc":{"start":{"line":32,"column":25},"end":{"line":34,"column":16}},"type":"cond-expr","locations":[{"start":{"line":33,"column":6},"end":{"line":33,"column":42}},{"start":{"line":34,"column":6},"end":{"line":34,"column":16}}]},"3":{"loc":{"start":{"line":164,"column":2},"end":{"line":173,"column":null}},"type":"if","locations":[{"start":{"line":164,"column":2},"end":{"line":173,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0},"f":{"0":0},"b":{"0":[0,0],"1":[0],"2":[0,0],"3":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-request-signer.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/setup-request-signer.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"3":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"4":{"start":{"line":6,"column":27},"end":{"line":104,"column":1}},"5":{"start":{"line":7,"column":38},"end":{"line":7,"column":50}},"6":{"start":{"line":8,"column":25},"end":{"line":8,"column":33}},"7":{"start":{"line":10,"column":18},"end":{"line":10,"column":38}},"8":{"start":{"line":11,"column":15},"end":{"line":11,"column":46}},"9":{"start":{"line":13,"column":40},"end":{"line":13,"column":97}},"10":{"start":{"line":14,"column":36},"end":{"line":20,"column":9}},"11":{"start":{"line":21,"column":2},"end":{"line":21,"column":null}},"12":{"start":{"line":23,"column":2},"end":{"line":57,"column":null}},"13":{"start":{"line":59,"column":2},"end":{"line":67,"column":null}},"14":{"start":{"line":69,"column":2},"end":{"line":91,"column":null}},"15":{"start":{"line":93,"column":2},"end":{"line":99,"column":null}},"16":{"start":{"line":101,"column":2},"end":{"line":103,"column":null}},"17":{"start":{"line":104,"column":1},"end":{"line":104,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":27},"end":{"line":6,"column":34}},"loc":{"start":{"line":6,"column":115},"end":{"line":104,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":14,"column":36},"end":{"line":20,"column":9}},"type":"cond-expr","locations":[{"start":{"line":15,"column":6},"end":{"line":15,"column":42}},{"start":{"line":16,"column":7},"end":{"line":20,"column":9}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0},"f":{"0":0},"b":{"0":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":2,"column":0},"end":{"line":2,"column":null}},"2":{"start":{"line":4,"column":0},"end":{"line":4,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"6":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"7":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"8":{"start":{"line":22,"column":36},"end":{"line":75,"column":1}},"9":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"10":{"start":{"line":25,"column":34},"end":{"line":25,"column":44}},"11":{"start":{"line":26,"column":33},"end":{"line":26,"column":41}},"12":{"start":{"line":28,"column":19},"end":{"line":28,"column":56}},"13":{"start":{"line":30,"column":2},"end":{"line":46,"column":null}},"14":{"start":{"line":31,"column":4},"end":{"line":31,"column":null}},"15":{"start":{"line":32,"column":4},"end":{"line":39,"column":null}},"16":{"start":{"line":41,"column":32},"end":{"line":44,"column":6}},"17":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"18":{"start":{"line":48,"column":18},"end":{"line":48,"column":38}},"19":{"start":{"line":49,"column":34},"end":{"line":54,"column":4}},"20":{"start":{"line":55,"column":2},"end":{"line":55,"column":null}},"21":{"start":{"line":57,"column":2},"end":{"line":57,"column":null}},"22":{"start":{"line":59,"column":22},"end":{"line":61,"column":null}},"23":{"start":{"line":64,"column":2},"end":{"line":70,"column":null}},"24":{"start":{"line":65,"column":4},"end":{"line":69,"column":null}},"25":{"start":{"line":72,"column":2},"end":{"line":72,"column":null}},"26":{"start":{"line":74,"column":2},"end":{"line":74,"column":null}},"27":{"start":{"line":75,"column":1},"end":{"line":75,"column":null}},"28":{"start":{"line":77,"column":19},"end":{"line":90,"column":1}},"29":{"start":{"line":79,"column":18},"end":{"line":79,"column":47}},"30":{"start":{"line":80,"column":21},"end":{"line":80,"column":46}},"31":{"start":{"line":82,"column":27},"end":{"line":87,"column":4}},"32":{"start":{"line":89,"column":2},"end":{"line":89,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":22,"column":36},"end":{"line":22,"column":43}},"loc":{"start":{"line":22,"column":98},"end":{"line":75,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":77,"column":19},"end":{"line":77,"column":26}},"loc":{"start":{"line":77,"column":65},"end":{"line":90,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":30,"column":2},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":30,"column":2},"end":{"line":46,"column":null}}]},"1":{"loc":{"start":{"line":64,"column":2},"end":{"line":70,"column":null}},"type":"if","locations":[{"start":{"line":64,"column":2},"end":{"line":70,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0},"f":{"0":0,"1":0},"b":{"0":[0],"1":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs","statementMap":{"0":{"start":{"line":1,"column":37},"end":{"line":43,"column":1}},"1":{"start":{"line":2,"column":28},"end":{"line":2,"column":40}},"2":{"start":{"line":3,"column":29},"end":{"line":3,"column":56}},"3":{"start":{"line":5,"column":2},"end":{"line":5,"column":null}},"4":{"start":{"line":7,"column":20},"end":{"line":7,"column":108}},"5":{"start":{"line":8,"column":2},"end":{"line":17,"column":null}},"6":{"start":{"line":20,"column":4},"end":{"line":20,"column":105}},"7":{"start":{"line":21,"column":2},"end":{"line":39,"column":null}},"8":{"start":{"line":41,"column":2},"end":{"line":41,"column":null}},"9":{"start":{"line":42,"column":2},"end":{"line":42,"column":null}},"10":{"start":{"line":43,"column":1},"end":{"line":43,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":37},"end":{"line":1,"column":38}},"loc":{"start":{"line":1,"column":71},"end":{"line":43,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":4},"end":{"line":20,"column":105}},"type":"binary-expr","locations":[{"start":{"line":20,"column":4},"end":{"line":20,"column":99}},{"start":{"line":20,"column":103},"end":{"line":20,"column":105}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0},"f":{"0":0},"b":{"0":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/convert-domain-to-bucket-name.js": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/convert-domain-to-bucket-name.js","statementMap":{"0":{"start":{"line":1,"column":35},"end":{"line":1,"column":106}},"1":{"start":{"line":1,"column":46},"end":{"line":1,"column":106}},"2":{"start":{"line":1,"column":106},"end":{"line":1,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":35},"end":{"line":1,"column":41}},"loc":{"start":{"line":1,"column":46},"end":{"line":1,"column":106}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/shared/determine-bucket-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/determine-bucket-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":6,"column":0},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"5":{"start":{"line":9,"column":28},"end":{"line":50,"column":1}},"6":{"start":{"line":10,"column":66},"end":{"line":10,"column":70}},"7":{"start":{"line":11,"column":33},"end":{"line":11,"column":37}},"8":{"start":{"line":13,"column":2},"end":{"line":15,"column":null}},"9":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"10":{"start":{"line":17,"column":24},"end":{"line":17,"column":32}},"11":{"start":{"line":18,"column":2},"end":{"line":21,"column":null}},"12":{"start":{"line":19,"column":22},"end":{"line":19,"column":57}},"13":{"start":{"line":20,"column":4},"end":{"line":20,"column":null}},"14":{"start":{"line":23,"column":2},"end":{"line":23,"column":null}},"15":{"start":{"line":25,"column":2},"end":{"line":49,"column":null}},"16":{"start":{"line":26,"column":4},"end":{"line":26,"column":null}},"17":{"start":{"line":28,"column":18},"end":{"line":28,"column":74}},"18":{"start":{"line":30,"column":20},"end":{"line":30,"column":48}},"19":{"start":{"line":31,"column":4},"end":{"line":44,"column":null}},"20":{"start":{"line":32,"column":6},"end":{"line":32,"column":null}},"21":{"start":{"line":33,"column":6},"end":{"line":35,"column":null}},"22":{"start":{"line":34,"column":8},"end":{"line":34,"column":null}},"23":{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},"24":{"start":{"line":38,"column":8},"end":{"line":38,"column":null}},"25":{"start":{"line":39,"column":8},"end":{"line":39,"column":null}},"26":{"start":{"line":40,"column":13},"end":{"line":43,"column":null}},"27":{"start":{"line":41,"column":8},"end":{"line":41,"column":null}},"28":{"start":{"line":42,"column":8},"end":{"line":42,"column":null}},"29":{"start":{"line":45,"column":4},"end":{"line":45,"column":null}},"30":{"start":{"line":46,"column":23},"end":{"line":46,"column":43}},"31":{"start":{"line":47,"column":4},"end":{"line":47,"column":null}},"32":{"start":{"line":48,"column":4},"end":{"line":48,"column":null}},"33":{"start":{"line":50,"column":1},"end":{"line":50,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":9,"column":28},"end":{"line":9,"column":35}},"loc":{"start":{"line":9,"column":44},"end":{"line":50,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":35},"end":{"line":10,"column":51}},"type":"default-arg","locations":[{"start":{"line":10,"column":46},"end":{"line":10,"column":51}}]},"1":{"loc":{"start":{"line":13,"column":2},"end":{"line":15,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":15,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":17},"end":{"line":14,"column":77}},"type":"binary-expr","locations":[{"start":{"line":14,"column":17},"end":{"line":14,"column":36}},{"start":{"line":14,"column":40},"end":{"line":14,"column":77}}]},"3":{"loc":{"start":{"line":18,"column":2},"end":{"line":21,"column":null}},"type":"if","locations":[{"start":{"line":18,"column":2},"end":{"line":21,"column":null}}]},"4":{"loc":{"start":{"line":23,"column":13},"end":{"line":23,"column":54}},"type":"binary-expr","locations":[{"start":{"line":23,"column":13},"end":{"line":23,"column":21}},{"start":{"line":23,"column":25},"end":{"line":23,"column":54}}]},"5":{"loc":{"start":{"line":33,"column":6},"end":{"line":35,"column":null}},"type":"if","locations":[{"start":{"line":33,"column":6},"end":{"line":35,"column":null}}]},"6":{"loc":{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},"type":"if","locations":[{"start":{"line":37,"column":6},"end":{"line":43,"column":null}},{"start":{"line":40,"column":13},"end":{"line":43,"column":null}}]},"7":{"loc":{"start":{"line":40,"column":13},"end":{"line":43,"column":null}},"type":"if","locations":[{"start":{"line":40,"column":13},"end":{"line":43,"column":null}}]},"8":{"loc":{"start":{"line":40,"column":17},"end":{"line":40,"column":75}},"type":"binary-expr","locations":[{"start":{"line":40,"column":17},"end":{"line":40,"column":34}},{"start":{"line":40,"column":38},"end":{"line":40,"column":75}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0},"f":{"0":0},"b":{"0":[0],"1":[0],"2":[0,0],"3":[0],"4":[0,0],"5":[0],"6":[0,0],"7":[0],"8":[0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/determine-oac-name.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/determine-oac-name.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":25},"end":{"line":27,"column":1}},"4":{"start":{"line":8,"column":21},"end":{"line":8,"column":29}},"5":{"start":{"line":9,"column":20},"end":{"line":9,"column":28}},"6":{"start":{"line":13,"column":22},"end":{"line":13,"column":67}},"7":{"start":{"line":15,"column":2},"end":{"line":26,"column":null}},"8":{"start":{"line":16,"column":4},"end":{"line":16,"column":null}},"9":{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},"10":{"start":{"line":18,"column":6},"end":{"line":18,"column":null}},"11":{"start":{"line":19,"column":23},"end":{"line":19,"column":43}},"12":{"start":{"line":20,"column":6},"end":{"line":20,"column":null}},"13":{"start":{"line":21,"column":6},"end":{"line":21,"column":null}},"14":{"start":{"line":23,"column":6},"end":{"line":23,"column":null}},"15":{"start":{"line":24,"column":6},"end":{"line":24,"column":null}},"16":{"start":{"line":27,"column":1},"end":{"line":27,"column":null}},"17":{"start":{"line":29,"column":23},"end":{"line":48,"column":1}},"18":{"start":{"line":30,"column":27},"end":{"line":30,"column":72}},"19":{"start":{"line":32,"column":17},"end":{"line":32,"column":19}},"20":{"start":{"line":33,"column":2},"end":{"line":47,"column":null}},"21":{"start":{"line":34,"column":27},"end":{"line":36,"column":6}},"22":{"start":{"line":38,"column":28},"end":{"line":38,"column":71}},"23":{"start":{"line":39,"column":18},"end":{"line":39,"column":69}},"24":{"start":{"line":41,"column":4},"end":{"line":41,"column":null}},"25":{"start":{"line":41,"column":50},"end":{"line":41,"column":54}},"26":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"27":{"start":{"line":44,"column":4},"end":{"line":46,"column":null}},"28":{"start":{"line":45,"column":6},"end":{"line":45,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":7,"column":25},"end":{"line":7,"column":32}},"loc":{"start":{"line":7,"column":72},"end":{"line":27,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":29,"column":23},"end":{"line":29,"column":30}},"loc":{"start":{"line":29,"column":58},"end":{"line":48,"column":1}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":41,"column":29},"end":{"line":41,"column":30}},"loc":{"start":{"line":41,"column":50},"end":{"line":41,"column":54}}}},"branchMap":{"0":{"loc":{"start":{"line":16,"column":4},"end":{"line":16,"column":78}},"type":"binary-expr","locations":[{"start":{"line":16,"column":4},"end":{"line":16,"column":20}},{"start":{"line":16,"column":4},"end":{"line":16,"column":20}},{"start":{"line":16,"column":4},"end":{"line":16,"column":78}}]},"1":{"loc":{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},"type":"if","locations":[{"start":{"line":17,"column":4},"end":{"line":25,"column":null}},{"start":{"line":22,"column":11},"end":{"line":25,"column":null}}]},"2":{"loc":{"start":{"line":18,"column":6},"end":{"line":18,"column":41}},"type":"binary-expr","locations":[{"start":{"line":18,"column":6},"end":{"line":18,"column":22}},{"start":{"line":18,"column":6},"end":{"line":18,"column":22}},{"start":{"line":18,"column":6},"end":{"line":18,"column":41}}]},"3":{"loc":{"start":{"line":23,"column":6},"end":{"line":23,"column":37}},"type":"binary-expr","locations":[{"start":{"line":23,"column":6},"end":{"line":23,"column":22}},{"start":{"line":23,"column":6},"end":{"line":23,"column":22}},{"start":{"line":23,"column":6},"end":{"line":23,"column":37}}]},"4":{"loc":{"start":{"line":39,"column":18},"end":{"line":39,"column":69}},"type":"binary-expr","locations":[{"start":{"line":39,"column":18},"end":{"line":39,"column":63}},{"start":{"line":39,"column":67},"end":{"line":39,"column":69}}]},"5":{"loc":{"start":{"line":44,"column":4},"end":{"line":46,"column":null}},"type":"if","locations":[{"start":{"line":44,"column":4},"end":{"line":46,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0,0],"3":[0,0,0],"4":[0,0],"5":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/find-bucket-like.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/find-bucket-like.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":23},"end":{"line":25,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":7,"column":48}},"5":{"start":{"line":8,"column":29},"end":{"line":8,"column":55}},"6":{"start":{"line":9,"column":32},"end":{"line":9,"column":71}},"7":{"start":{"line":11,"column":26},"end":{"line":11,"column":91}},"8":{"start":{"line":11,"column":62},"end":{"line":11,"column":90}},"9":{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},"10":{"start":{"line":14,"column":4},"end":{"line":14,"column":null}},"11":{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},"12":{"start":{"line":16,"column":29},"end":{"line":16,"column":52}},"13":{"start":{"line":17,"column":4},"end":{"line":17,"column":null}},"14":{"start":{"line":18,"column":4},"end":{"line":18,"column":null}},"15":{"start":{"line":21,"column":4},"end":{"line":21,"column":null}},"16":{"start":{"line":22,"column":4},"end":{"line":23,"column":null}},"17":{"start":{"line":23,"column":49},"end":{"line":23,"column":53}},"18":{"start":{"line":25,"column":1},"end":{"line":25,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":23},"end":{"line":5,"column":30}},"loc":{"start":{"line":5,"column":76},"end":{"line":25,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":11,"column":41},"end":{"line":11,"column":42}},"loc":{"start":{"line":11,"column":62},"end":{"line":11,"column":90}}},"2":{"name":"(anonymous_2)","decl":{"start":{"line":23,"column":28},"end":{"line":23,"column":29}},"loc":{"start":{"line":23,"column":49},"end":{"line":23,"column":53}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":71}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":71}}]},"1":{"loc":{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":13,"column":2},"end":{"line":24,"column":null}},{"start":{"line":15,"column":9},"end":{"line":24,"column":null}}]},"2":{"loc":{"start":{"line":14,"column":4},"end":{"line":14,"column":41}},"type":"binary-expr","locations":[{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":20}},{"start":{"line":14,"column":4},"end":{"line":14,"column":41}}]},"3":{"loc":{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},"type":"if","locations":[{"start":{"line":15,"column":9},"end":{"line":24,"column":null}},{"start":{"line":19,"column":9},"end":{"line":24,"column":null}}]},"4":{"loc":{"start":{"line":17,"column":4},"end":{"line":17,"column":62}},"type":"binary-expr","locations":[{"start":{"line":17,"column":4},"end":{"line":17,"column":20}},{"start":{"line":17,"column":4},"end":{"line":17,"column":20}},{"start":{"line":17,"column":4},"end":{"line":17,"column":62}}]},"5":{"loc":{"start":{"line":21,"column":4},"end":{"line":21,"column":45}},"type":"binary-expr","locations":[{"start":{"line":21,"column":4},"end":{"line":21,"column":20}},{"start":{"line":21,"column":4},"end":{"line":21,"column":20}},{"start":{"line":21,"column":4},"end":{"line":21,"column":45}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0},"f":{"0":0,"1":0,"2":0},"b":{"0":[0,0,0],"1":[0,0],"2":[0,0,0],"3":[0,0],"4":[0,0,0],"5":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/get-account-id.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/get-account-id.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":21},"end":{"line":11,"column":1}},"3":{"start":{"line":6,"column":2},"end":{"line":6,"column":null}},"4":{"start":{"line":7,"column":19},"end":{"line":7,"column":94}},"5":{"start":{"line":8,"column":20},"end":{"line":8,"column":36}},"6":{"start":{"line":10,"column":2},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":1},"end":{"line":11,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":21},"end":{"line":5,"column":28}},"loc":{"start":{"line":5,"column":48},"end":{"line":11,"column":1}}}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":2},"end":{"line":6,"column":60}},"type":"binary-expr","locations":[{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":18}},{"start":{"line":6,"column":2},"end":{"line":6,"column":60}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"f":{"0":0},"b":{"0":[0,0,0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/get-site-tag.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/get-site-tag.mjs","statementMap":{"0":{"start":{"line":1,"column":20},"end":{"line":3,"column":1}},"1":{"start":{"line":2,"column":2},"end":{"line":2,"column":null}},"2":{"start":{"line":3,"column":1},"end":{"line":3,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":20},"end":{"line":1,"column":28}},"loc":{"start":{"line":1,"column":33},"end":{"line":3,"column":1}}}},"branchMap":{},"s":{"0":0,"1":0,"2":0},"f":{"0":0},"b":{}} -,"/Users/zane/playground/cloudsite/src/lib/shared/progress-logger.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/progress-logger.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":20},"end":{"line":3,"column":25}},"2":{"start":{"line":5,"column":25},"end":{"line":16,"column":1}},"3":{"start":{"line":6,"column":16},"end":{"line":6,"column":35}},"4":{"start":{"line":8,"column":2},"end":{"line":15,"column":null}},"5":{"start":{"line":10,"column":22},"end":{"line":10,"column":29}},"6":{"start":{"line":12,"column":4},"end":{"line":14,"column":null}},"7":{"start":{"line":13,"column":6},"end":{"line":13,"column":null}},"8":{"start":{"line":16,"column":1},"end":{"line":16,"column":null}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":5,"column":25},"end":{"line":5,"column":32}},"loc":{"start":{"line":5,"column":37},"end":{"line":16,"column":1}}},"1":{"name":"(anonymous_1)","decl":{"start":{"line":8,"column":25},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":39},"end":{"line":15,"column":3}}}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":4},"end":{"line":14,"column":null}},"type":"if","locations":[{"start":{"line":12,"column":4},"end":{"line":14,"column":null}}]}},"s":{"0":2,"1":2,"2":2,"3":1,"4":1,"5":0,"6":0,"7":0,"8":2},"f":{"0":1,"1":0},"b":{"0":[0]}} -,"/Users/zane/playground/cloudsite/src/lib/shared/site-template.mjs": {"path":"/Users/zane/playground/cloudsite/src/lib/shared/site-template.mjs","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":null}},"1":{"start":{"line":3,"column":0},"end":{"line":3,"column":null}},"2":{"start":{"line":5,"column":0},"end":{"line":5,"column":null}},"3":{"start":{"line":7,"column":0},"end":{"line":7,"column":null}},"4":{"start":{"line":8,"column":0},"end":{"line":8,"column":null}},"5":{"start":{"line":9,"column":0},"end":{"line":9,"column":null}},"6":{"start":{"line":10,"column":0},"end":{"line":10,"column":null}},"7":{"start":{"line":11,"column":0},"end":{"line":11,"column":50}},"8":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"9":{"start":{"line":17,"column":21},"end":{"line":267,"column":1}},"10":{"start":{"line":39,"column":4},"end":{"line":39,"column":null}},"11":{"start":{"line":40,"column":4},"end":{"line":40,"column":null}},"12":{"start":{"line":42,"column":4},"end":{"line":42,"column":null}},"13":{"start":{"line":43,"column":4},"end":{"line":43,"column":null}},"14":{"start":{"line":47,"column":25},"end":{"line":47,"column":29}},"15":{"start":{"line":48,"column":74},"end":{"line":48,"column":82}},"16":{"start":{"line":49,"column":20},"end":{"line":49,"column":40}},"17":{"start":{"line":51,"column":20},"end":{"line":57,"column":8}},"18":{"start":{"line":58,"column":4},"end":{"line":58,"column":null}},"19":{"start":{"line":59,"column":4},"end":{"line":59,"column":null}},"20":{"start":{"line":61,"column":4},"end":{"line":164,"column":null}},"21":{"start":{"line":168,"column":25},"end":{"line":168,"column":29}},"22":{"start":{"line":169,"column":33},"end":{"line":169,"column":41}},"23":{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},"24":{"start":{"line":172,"column":6},"end":{"line":172,"column":null}},"25":{"start":{"line":173,"column":23},"end":{"line":173,"column":71}},"26":{"start":{"line":174,"column":6},"end":{"line":179,"column":null}},"27":{"start":{"line":180,"column":6},"end":{"line":180,"column":null}},"28":{"start":{"line":182,"column":6},"end":{"line":182,"column":null}},"29":{"start":{"line":187,"column":27},"end":{"line":187,"column":40}},"30":{"start":{"line":188,"column":61},"end":{"line":188,"column":74}},"31":{"start":{"line":189,"column":20},"end":{"line":189,"column":45}},"32":{"start":{"line":191,"column":4},"end":{"line":198,"column":null}},"33":{"start":{"line":192,"column":6},"end":{"line":197,"column":null}},"34":{"start":{"line":199,"column":4},"end":{"line":199,"column":null}},"35":{"start":{"line":201,"column":4},"end":{"line":211,"column":null}},"36":{"start":{"line":213,"column":4},"end":{"line":213,"column":null}},"37":{"start":{"line":217,"column":25},"end":{"line":217,"column":29}},"38":{"start":{"line":218,"column":27},"end":{"line":218,"column":35}},"39":{"start":{"line":219,"column":24},"end":{"line":219,"column":46}},"40":{"start":{"line":221,"column":4},"end":{"line":231,"column":null}},"41":{"start":{"line":222,"column":21},"end":{"line":222,"column":39}},"42":{"start":{"line":223,"column":6},"end":{"line":225,"column":null}},"43":{"start":{"line":224,"column":8},"end":{"line":224,"column":null}},"44":{"start":{"line":227,"column":41},"end":{"line":227,"column":47}},"45":{"start":{"line":228,"column":6},"end":{"line":230,"column":null}},"46":{"start":{"line":229,"column":8},"end":{"line":229,"column":null}},"47":{"start":{"line":235,"column":25},"end":{"line":235,"column":29}},"48":{"start":{"line":236,"column":27},"end":{"line":236,"column":35}},"49":{"start":{"line":237,"column":24},"end":{"line":237,"column":46}},"50":{"start":{"line":239,"column":26},"end":{"line":239,"column":28}},"51":{"start":{"line":240,"column":4},"end":{"line":247,"column":null}},"52":{"start":{"line":241,"column":21},"end":{"line":241,"column":39}},"53":{"start":{"line":242,"column":6},"end":{"line":244,"column":null}},"54":{"start":{"line":243,"column":8},"end":{"line":243,"column":null}},"55":{"start":{"line":246,"column":6},"end":{"line":246,"column":null}},"56":{"start":{"line":249,"column":4},"end":{"line":249,"column":null}},"57":{"start":{"line":253,"column":27},"end":{"line":253,"column":40}},"58":{"start":{"line":254,"column":26},"end":{"line":254,"column":64}},"59":{"start":{"line":256,"column":27},"end":{"line":261,"column":5}},"60":{"start":{"line":264,"column":19},"end":{"line":264,"column":78}},"61":{"start":{"line":265,"column":4},"end":{"line":265,"column":null}},"62":{"start":{"line":267,"column":1},"end":{"line":267,"column":null}}},"fnMap":{"0":{"name":"_getRequireWildcardCache","decl":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}},"1":{"name":"(anonymous_3)","decl":{"start":{"line":38,"column":2},"end":{"line":38,"column":13}},"loc":{"start":{"line":38,"column":42},"end":{"line":44,"column":null}}},"2":{"name":"(anonymous_4)","decl":{"start":{"line":46,"column":2},"end":{"line":46,"column":8}},"loc":{"start":{"line":46,"column":45},"end":{"line":165,"column":null}}},"3":{"name":"(anonymous_5)","decl":{"start":{"line":167,"column":2},"end":{"line":167,"column":8}},"loc":{"start":{"line":167,"column":35},"end":{"line":184,"column":null}}},"4":{"name":"(anonymous_6)","decl":{"start":{"line":186,"column":2},"end":{"line":186,"column":8}},"loc":{"start":{"line":186,"column":34},"end":{"line":214,"column":null}}},"5":{"name":"(anonymous_7)","decl":{"start":{"line":216,"column":2},"end":{"line":216,"column":8}},"loc":{"start":{"line":216,"column":26},"end":{"line":232,"column":null}}},"6":{"name":"(anonymous_8)","decl":{"start":{"line":234,"column":2},"end":{"line":234,"column":8}},"loc":{"start":{"line":234,"column":38},"end":{"line":250,"column":null}}},"7":{"name":"(anonymous_9)","decl":{"start":{"line":252,"column":2},"end":{"line":252,"column":8}},"loc":{"start":{"line":252,"column":12},"end":{"line":266,"column":null}}}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"if","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"1":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"cond-expr","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"2":{"loc":{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},"type":"binary-expr","locations":[{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}},{"start":{"line":11,"column":50},"end":{"line":11,"column":null}}]},"3":{"loc":{"start":{"line":46,"column":28},"end":{"line":46,"column":43}},"type":"default-arg","locations":[{"start":{"line":46,"column":41},"end":{"line":46,"column":43}}]},"4":{"loc":{"start":{"line":51,"column":20},"end":{"line":57,"column":8}},"type":"cond-expr","locations":[{"start":{"line":52,"column":8},"end":{"line":52,"column":24}},{"start":{"line":53,"column":8},"end":{"line":57,"column":8}}]},"5":{"loc":{"start":{"line":58,"column":4},"end":{"line":58,"column":57}},"type":"binary-expr","locations":[{"start":{"line":58,"column":4},"end":{"line":58,"column":20}},{"start":{"line":58,"column":4},"end":{"line":58,"column":20}},{"start":{"line":58,"column":4},"end":{"line":58,"column":57}}]},"6":{"loc":{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},"type":"if","locations":[{"start":{"line":171,"column":4},"end":{"line":183,"column":null}},{"start":{"line":181,"column":11},"end":{"line":183,"column":null}}]},"7":{"loc":{"start":{"line":182,"column":6},"end":{"line":182,"column":105}},"type":"binary-expr","locations":[{"start":{"line":182,"column":6},"end":{"line":182,"column":22}},{"start":{"line":182,"column":6},"end":{"line":182,"column":22}},{"start":{"line":182,"column":6},"end":{"line":182,"column":105}}]},"8":{"loc":{"start":{"line":188,"column":10},"end":{"line":188,"column":57}},"type":"default-arg","locations":[{"start":{"line":188,"column":29},"end":{"line":188,"column":57}}]},"9":{"loc":{"start":{"line":191,"column":4},"end":{"line":198,"column":null}},"type":"if","locations":[{"start":{"line":191,"column":4},"end":{"line":198,"column":null}}]},"10":{"loc":{"start":{"line":219,"column":24},"end":{"line":219,"column":46}},"type":"binary-expr","locations":[{"start":{"line":219,"column":24},"end":{"line":219,"column":40}},{"start":{"line":219,"column":44},"end":{"line":219,"column":46}}]},"11":{"loc":{"start":{"line":223,"column":6},"end":{"line":225,"column":null}},"type":"if","locations":[{"start":{"line":223,"column":6},"end":{"line":225,"column":null}}]},"12":{"loc":{"start":{"line":228,"column":6},"end":{"line":230,"column":null}},"type":"if","locations":[{"start":{"line":228,"column":6},"end":{"line":230,"column":null}}]},"13":{"loc":{"start":{"line":234,"column":21},"end":{"line":234,"column":36}},"type":"default-arg","locations":[{"start":{"line":234,"column":34},"end":{"line":234,"column":36}}]},"14":{"loc":{"start":{"line":237,"column":24},"end":{"line":237,"column":46}},"type":"binary-expr","locations":[{"start":{"line":237,"column":24},"end":{"line":237,"column":40}},{"start":{"line":237,"column":44},"end":{"line":237,"column":46}}]},"15":{"loc":{"start":{"line":242,"column":6},"end":{"line":244,"column":null}},"type":"if","locations":[{"start":{"line":242,"column":6},"end":{"line":244,"column":null}}]}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0},"b":{"0":[0],"1":[0,0],"2":[0,0,0],"3":[0],"4":[0,0],"5":[0,0,0],"6":[0,0],"7":[0,0,0],"8":[0],"9":[0],"10":[0,0],"11":[0],"12":[0],"13":[0],"14":[0,0],"15":[0]}} -} diff --git a/qa/coverage/favicon.png b/qa/coverage/favicon.png deleted file mode 100644 index c1525b811a167671e9de1fa78aab9f5c0b61cef7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 445 zcmV;u0Yd(XP))rP{nL}Ln%S7`m{0DjX9TLF* zFCb$4Oi7vyLOydb!7n&^ItCzb-%BoB`=x@N2jll2Nj`kauio%aw_@fe&*}LqlFT43 z8doAAe))z_%=P%v^@JHp3Hjhj^6*Kr_h|g_Gr?ZAa&y>wxHE99Gk>A)2MplWz2xdG zy8VD2J|Uf#EAw*bo5O*PO_}X2Tob{%bUoO2G~T`@%S6qPyc}VkhV}UifBuRk>%5v( z)x7B{I~z*k<7dv#5tC+m{km(D087J4O%+<<;K|qwefb6@GSX45wCK}Sn*> - - - - Code coverage report for All files - - - - - - - - - -
-
-

All files

-
- -
- 1.3% - Statements - 19/1460 -
- - -
- 0.16% - Branches - 1/590 -
- - -
- 2.38% - Functions - 3/126 -
- - -
- 1.33% - Lines - 19/1419 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
cli -
-
0%0/1110%0/530%0/40%0/99
cli/lib -
-
0%0/4610%0/2060%0/370%0/451
cli/lib/configuration -
-
100%13/1350%1/2100%2/2100%13/13
cli/lib/plugin-settings -
-
0%0/450%0/310%0/70%0/44
lib/actions -
-
0%0/3000%0/1210%0/190%0/291
lib/actions/lib -
-
0%0/1810%0/600%0/220%0/177
lib/plugins -
-
0%0/200%0/10%0/70%0/20
lib/plugins/contact-handler/lib -
-
0%0/1610%0/420%0/80%0/161
lib/shared -
-
3.57%6/1680%0/745%1/203.68%6/163
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/create.mjs.html b/qa/coverage/lib/actions/create.mjs.html deleted file mode 100644 index b82a5bfb..00000000 --- a/qa/coverage/lib/actions/create.mjs.html +++ /dev/null @@ -1,547 +0,0 @@ - - - - - - Code coverage report for lib/actions/create.mjs - - - - - - - - - -
-
-

All files / lib/actions create.mjs

-
- -
- 0% - Statements - 0/72 -
- - -
- 0% - Branches - 0/14 -
- - -
- 0% - Functions - 0/7 -
- - -
- 0% - Lines - 0/71 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { ACMClient, RequestCertificateCommand } from '@aws-sdk/client-acm'
-import { CloudFormationClient, CreateStackCommand } from '@aws-sdk/client-cloudformation'
- 
-import {
-  associateCostAllocationTags,
-  handleAssociateCostAllocationTagsError
-} from './lib/associate-cost-allocation-tags'
-import { convertDomainToBucketName } from '../shared/convert-domain-to-bucket-name'
-import { createOrUpdateDNSRecords } from './lib/create-or-update-dns-records'
-import { determineBucketName } from '../shared/determine-bucket-name'
-import { findCertificate } from './lib/find-certificate'
-import { getCredentials } from './lib/get-credentials'
-import { getSiteTag } from '../shared/get-site-tag'
-import * as plugins from '../plugins'
-import { progressLogger } from '../shared/progress-logger'
-import { SiteTemplate } from '../shared/site-template'
-import { syncSiteContent } from './lib/sync-site-content'
-import { trackStackStatus } from './lib/track-stack-status'
-import { updateSiteInfo } from './lib/update-site-info'I
- 
-const STACK_CREATE_TIMEOUT = 30 // min
- 
-const create = async ({
-  db,
-  noBuild,
-  noDeleteOnFailure,
-  siteInfo
-}) => {
-  const { apexDomain } = siteInfo
-  let { bucketName } = siteInfo
- 
-  const credentials = getCredentials(db.account.settings)
- 
-  const acmClient = new ACMClient({
-    credentials,
-    region : 'us-east-1' // N. Virginia; required for certificate request
-  })
- 
-  let { certificateArn, status } = await findCertificate({ acmClient, apexDomain })
-  Iif (certificateArn === null) {
-    progressLogger.write(`Creating wildcard certificate for '${apexDomain}'...`)
-    certificateArn = await createCertificate({ acmClient, apexDomain })
-    status = 'PENDING_VALIDATION'
-  }
-  siteInfo.certificateArn = certificateArn
- 
-  Iif (status === 'PENDING_VALIDATION') {
-    const accountLocalCertID = certificateArn.replace(/[^/]+\/(.+)/, '$1')
-    const certificateConsoleURL =
-      `https://us-east-1.console.aws.amazon.com/acm/home?region=us-east-1#/certificates/${accountLocalCertID}`
-    throw new Error(`Wildcard certificate for '${apexDomain}' found, but requires validation. Please validate the certificate. To validate on S3 when using Route 53 for DNS service, try navigating to the folliwng URL and select 'Create records in Route 53'::\n\n${certificateConsoleURL}\n\nSubsequent validation may take up to 30 minutes. For further documentation:\n\nhttps://docs.aws.amazon.com/acm/latest/userguide/dns-validation.html`)
-  }
- 
-  bucketName = await determineBucketName({ apexDomain, bucketName, credentials, findName : true, siteInfo })
-  siteInfo.bucketName = bucketName
-  const stackCreated = await createSiteStack({ credentials, noDeleteOnFailure, siteInfo })
- 
-  if (stackCreated === true) {
-    const postUpdateHandlers = Object.keys(siteInfo.plugins || {}).map((pluginKey) =>
-      [pluginKey, plugins[pluginKey].postUpdateHandler]
-    )
-      .filter(([, postUpdateHandler]) => postUpdateHandler !== undefined)
- 
-    await updateSiteInfo({ credentials, siteInfo }) // needed by createOrUpdateDNSRecords
- 
-    const siteTag = getSiteTag(siteInfo)
- 
-    // TODO: speeds things up, but if one fail, it all fails and is unclear; maybe we should break it up?
-    await Promise.all([
-      syncSiteContent({ credentials, noBuild, siteInfo }),
-      createOrUpdateDNSRecords({ credentials, siteInfo }),
-      ...(postUpdateHandlers.map(([pluginKey, handler]) =>
-        handler({ pluginData : siteInfo.plugins[pluginKey], siteInfo })))
-    ])
- 
-    try {
-      await associateCostAllocationTags({ credentials, tag : siteTag })
-    } catch (e) {
-      handleAssociateCostAllocationTagsError({ e, siteInfo })
-    }
- 
-    return true
-  } else {
-    return false
-  }
-}
- 
-const createCertificate = async ({ acmClient, apexDomain }) => {
-  progressLogger.write(`Creating wildcard certificate for '${apexDomain}'...`)
-  const input = { // RequestCertificateRequest
-    DomainName              : '*.' + apexDomain, // TODO: support more narrow cert?
-    ValidationMethod        : 'DNS', // TODO: support email
-    SubjectAlternativeNames : [
-      apexDomain, 'www.' + apexDomain
-    ], /*
-    // IdempotencyToken: "STRING_VALUE", TODO: should we use this?
-    /* DomainValidationOptions: [ // DomainValidationOptionList : TODO: is this only used for email verification?
-      { // DomainValidationOption
-        DomainName: "STRING_VALUE", // required
-        ValidationDomain: "STRING_VALUE", // required
-      },
-    ], */
-    Options : { // CertificateOptions
-      CertificateTransparencyLoggingPreference : 'ENABLED'
-    },
-    // CertificateAuthorityArn: "STRING_VALUE", TODO: only used for private certs, I think
-    /* Tags: [ // TagList : TODO: support tags? tag with the website
-      { // Tag
-        Key: "STRING_VALUE", // required
-        Value: "STRING_VALUE",
-      },
-    ], */
-    KeyAlgorithm : 'RSA_2048' // TODO: support key options"RSA_1024" || "RSA_2048" || "RSA_3072" || "RSA_4096" || "EC_prime256v1" || "EC_secp384r1" || "EC_secp521r1",
-  }
-  // this method can safely be called multiple times; it'll  match  existing certs (by domain name I'd assume)
-  const command = new RequestCertificateCommand(input)
-  const response = await acmClient.send(command)
- 
-  const { CertificateArn } = response
- 
-  return CertificateArn
-}
- 
-const createSiteStack = async ({ credentials, noDeleteOnFailure, siteInfo }) => {
-  const { apexDomain, region } = siteInfo
- 
-  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
-  await siteTemplate.initializeTemplate()
-  await siteTemplate.loadPlugins()
- 
-  const cloudFormationTemplate = siteTemplate.render()
- 
-  const cloudFormationClient = new CloudFormationClient({ credentials, region })
-  const stackName = siteInfo.stackName || convertDomainToBucketName(apexDomain) + '-stack'
-  const createInput = {
-    StackName        : stackName,
-    TemplateBody     : cloudFormationTemplate,
-    DisableRollback  : false,
-    Capabilities     : ['CAPABILITY_IAM', 'CAPABILITY_NAMED_IAM'],
-    TimeoutInMinutes : STACK_CREATE_TIMEOUT
-  }
-  const createCommand = new CreateStackCommand(createInput)
-  const createResponse = await cloudFormationClient.send(createCommand)
- 
-  const { StackId } = createResponse
- 
-  siteInfo.stackName = stackName
-  siteInfo.stackArn = StackId
- 
-  const finalStatus = await trackStackStatus({ cloudFormationClient, noDeleteOnFailure, stackName })
-  return { success : finalStatus === 'CREATE_COMPLETE', stackName }
-}
- 
-export { create }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/destroy.mjs.html b/qa/coverage/lib/actions/destroy.mjs.html deleted file mode 100644 index b0ec2511..00000000 --- a/qa/coverage/lib/actions/destroy.mjs.html +++ /dev/null @@ -1,274 +0,0 @@ - - - - - - Code coverage report for lib/actions/destroy.mjs - - - - - - - - - -
-
-

All files / lib/actions destroy.mjs

-
- -
- 0% - Statements - 0/40 -
- - -
- 0% - Branches - 0/21 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/36 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { S3Client } from '@aws-sdk/client-s3'
-import { CloudFormationClient, DeleteStackCommand } from '@aws-sdk/client-cloudformation'
- 
-import { emptyBucket } from 's3-empty-bucket'
- 
-import { getCredentials } from './lib/get-credentials'
-import { progressLogger } from '../shared/progress-logger'
-import { SiteTemplate } from '../shared/site-template'
-import { trackStackStatus } from './lib/track-stack-status'
- 
-const destroy = async ({ db, siteInfo, verbose }) => {
-  const { apexDomain, bucketName, stackName } = siteInfo
- 
-  const credentials = getCredentials(db.account.settings)
-  const s3Client = new S3Client({ credentials })
- 
-  // this method provides user udptaes
-  try {
-    Iif (verbose === true) { progressLogger?.write('Deleting site bucket...\n') }
-    await emptyBucket({ bucketName, doDelete : true, s3Client, verbose })
-  } catch (e) {
-    if (e.name === 'NoSuchBucket') {
-      Iif (verbose === true) { progressLogger?.write('Bucket already deleted.\n') }
-    } else {
-      throw e
-    }
-  }
- 
-  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
-  await siteTemplate.destroyPlugins()
- 
-  Iif (verbose === true) { progressLogger.write(`Deleting stack for ${apexDomain}`) }
-  const cloudFormationClient = new CloudFormationClient({ credentials })
-  const deleteStackCommand = new DeleteStackCommand({ StackName : stackName })
-  await cloudFormationClient.send(deleteStackCommand)
- 
-  // the delete command is doesn't mind if the bucket doesn't exist, but trackStackStatus does
-  try {
-    const finalStatus =
-      await trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, noInitialStatus : true, stackName })
-    progressLogger.write('\n')
- 
-    if (finalStatus === 'DELETE_FAILED') {
-      return false
-    } else if (finalStatus === 'DELETE_COMPLETE') { // actually, we should never see this, see note below
-      return true
-    } else {
-      throw new Error(`Unexpected final status after delete: ${finalStatus}`)
-    }
-  } catch (e) {
-    // if the stack does not exist we get a ValidationError; so this is the expected outcome when deleting a stack as
-    // the last call for update will result in a validation error.
-    if (e.name === 'ValidationError') {
-      return true
-    } else {
-      throw e
-    }
-  } finally {
-    Iif (verbose === true) { progressLogger?.write('\n') }
-  }
-}
- 
-export { destroy }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/import.mjs.html b/qa/coverage/lib/actions/import.mjs.html deleted file mode 100644 index 94e725fb..00000000 --- a/qa/coverage/lib/actions/import.mjs.html +++ /dev/null @@ -1,304 +0,0 @@ - - - - - - Code coverage report for lib/actions/import.mjs - - - - - - - - - -
-
-

All files / lib/actions import.mjs

-
- -
- 0% - Statements - 0/47 -
- - -
- 0% - Branches - 0/25 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/46 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import yaml from 'js-yaml'
- 
-import { ACMClient } from '@aws-sdk/client-acm'
-import { CloudFormationClient, DescribeStacksCommand, GetTemplateCommand } from '@aws-sdk/client-cloudformation'
- 
-import { getAccountID } from '../shared/get-account-id'
-import { getCredentials } from './lib/get-credentials'
-import { findBucketLike } from '../shared/find-bucket-like'
-import { findCertificate } from './lib/find-certificate'
-import * as plugins from '../plugins'
-import { progressLogger } from '../shared/progress-logger'I
- 
-const doImport = async ({ commonLogsBucket, db, domain, region, sourcePath, sourceType, stack }) => {
-  const siteInfo = { apexDomain : domain, stackName : stack, region, sourcePath, sourceType }
-  const credentials = getCredentials(db.account.settings)
- 
-  const acmClient = new ACMClient({ credentials, region : 'us-east-1' }) // certificates are always in us-east-1
-  const { certificateArn } = await findCertificate({ apexDomain : domain, acmClient })
-  siteInfo.certificateArn = certificateArn
- 
-  const accountID = await getAccountID({ credentials })
-  siteInfo.accountID = accountID
- 
-  progressLogger?.write(`Examining stack '${stack}' outputs...\n`)
-  const cloudFormationClient = new CloudFormationClient({ credentials, region })
-  const describeStacksCommand = new DescribeStacksCommand({ StackName : stack })
-  const stacksInfo = await cloudFormationClient.send(describeStacksCommand)
- 
-  const getTemplateCommand = new GetTemplateCommand({ StackName : stack })
-  const templateBody = (await cloudFormationClient.send(getTemplateCommand)).TemplateBody
-  const template = yaml.load(templateBody)
- 
-  siteInfo.oacName = template.Resources.SiteCloudFrontOriginAccessControl.Properties.OriginAccessControlConfig.Name
- 
-  const stackOutputs = stacksInfo.Stacks[0].Outputs || []
-  for (const { OutputKey: key, OutputValue: value } of stackOutputs) {
-    if (key === 'SiteS3Bucket') {
-      siteInfo.bucketName = value
- 
-      Iif (commonLogsBucket === undefined) {
-        commonLogsBucket = await findBucketLike({
-          credentials,
-          description : 'common logs',
-          partialName : value + '-common-logs'
-        })
-      }
-      Iif (commonLogsBucket !== undefined && commonLogsBucket !== 'NONE') {
-        siteInfo.commonLogsBucket = commonLogsBucket
-      }
-    } else Iif (key === 'SiteCloudFrontDistribution') {
-      siteInfo.cloudFrontDistributionID = value
-    }
-  } // for (... of stackOutputs)
- 
-  progressLogger?.write('Loading plugins data...\n')
- 
-  const pluginsData = {}
-  siteInfo.plugins = pluginsData
- 
-  for (const pluginName of Object.keys(plugins)) {
-    progressLogger?.write(`Importing plugin settings for '${pluginName}'...\n`)
-    const { importHandler } = plugins[pluginName]
-    Iif (importHandler === undefined) {
-      throw new Error(`Plugin '${pluginName}' does not define 'importHandler'; cannot  continue with import.`)
-    }
- 
-    await importHandler({ credentials, name : pluginName, pluginsData, siteInfo, template })
-  }
- 
-  return siteInfo
-}
- 
-export { doImport }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/index.html b/qa/coverage/lib/actions/index.html deleted file mode 100644 index 5a662364..00000000 --- a/qa/coverage/lib/actions/index.html +++ /dev/null @@ -1,176 +0,0 @@ - - - - - - Code coverage report for lib/actions - - - - - - - - - -
-
-

All files lib/actions

-
- -
- 0% - Statements - 0/300 -
- - -
- 0% - Branches - 0/121 -
- - -
- 0% - Functions - 0/19 -
- - -
- 0% - Lines - 0/291 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
create.mjs -
-
0%0/720%0/140%0/70%0/71
destroy.mjs -
-
0%0/400%0/210%0/10%0/36
import.mjs -
-
0%0/470%0/250%0/20%0/46
update.mjs -
-
0%0/410%0/240%0/20%0/41
verify.mjs -
-
0%0/1000%0/370%0/70%0/97
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html b/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html deleted file mode 100644 index 2e82fcdf..00000000 --- a/qa/coverage/lib/actions/lib/add-tags-to-hosted-zone.mjs.html +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/add-tags-to-hosted-zone.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib add-tags-to-hosted-zone.mjs

-
- -
- 0% - Statements - 0/10 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/10 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { Route53Client, ChangeTagsForResourceCommand } from '@aws-sdk/client-route-53'
- 
-import { getHostedZoneID } from './get-hosted-zone-id'
-import { getSiteTag } from '../../shared/get-site-tag'
- 
-const addTagsToHostedZone = async ({ credentials, siteInfo }) => {
-  const siteTag = getSiteTag(siteInfo)
-  const route53Client = new Route53Client({ credentials })
- 
-  const hostedZoneID = await getHostedZoneID({ route53Client, siteInfo })
- 
-  const changeTagsForResourceCommand = new ChangeTagsForResourceCommand({
-    ResourceType : 'hostedzone',
-    ResourceId   : hostedZoneID,
-    AddTags      : [{ Key : siteTag, Value : '' }]
-  })
-  await route53Client.send(changeTagsForResourceCommand)
-}
- 
-export { addTagsToHostedZone }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html b/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html deleted file mode 100644 index 3c3d71aa..00000000 --- a/qa/coverage/lib/actions/lib/associate-cost-allocation-tags.mjs.html +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/associate-cost-allocation-tags.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib associate-cost-allocation-tags.mjs

-
- -
- 0% - Statements - 0/11 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/11 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { CostExplorerClient, UpdateCostAllocationTagsStatusCommand } from '@aws-sdk/client-cost-explorer'
- 
-import { progressLogger } from '../../shared/progress-logger'
- 
-const associateCostAllocationTags = async ({ credentials, tag }) => {
-  const costExplorerClient = new CostExplorerClient({ credentials })
-  const updateCostAllocationTagsStatusCommand = new UpdateCostAllocationTagsStatusCommand({
-    CostAllocationTagsStatus : [{ TagKey : tag, Status : 'Active' }]
-  })
-  await costExplorerClient.send(updateCostAllocationTagsStatusCommand)
-}
- 
-const handleAssociateCostAllocationTagsError = ({ /* e, */ siteInfo }) => {
-  const { apexDomain } = siteInfo
- 
-  progressLogger.write(`\nThe attempt to setup your cost allocation tags has failed. This is expected as AWS must 'discover' your tags before they can be activated for cost allocation. Wait a little while and try setting up the cost allocation tags again with:\n\ncloudsite update ${apexDomain} --do-billing\n\n`)
-}
- 
-export { associateCostAllocationTags, handleAssociateCostAllocationTagsError }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html b/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html deleted file mode 100644 index 4b819dab..00000000 --- a/qa/coverage/lib/actions/lib/create-or-update-dns-records.mjs.html +++ /dev/null @@ -1,214 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/create-or-update-dns-records.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib create-or-update-dns-records.mjs

-
- -
- 0% - Statements - 0/18 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/18 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { Route53Client, ChangeResourceRecordSetsCommand } from '@aws-sdk/client-route-53'
-import { CloudFrontClient, GetDistributionCommand } from '@aws-sdk/client-cloudfront'
- 
-import { getHostedZoneID } from './get-hosted-zone-id'
-import { progressLogger } from '../../shared/progress-logger'
- 
-const createOrUpdateDNSRecords = async ({ credentials, siteInfo }) => {
-  const { apexDomain, cloudFrontDistributionID, region } = siteInfo
- 
-  const cloudFrontClient = new CloudFrontClient({ credentials, region })
-  const getDistributionCommand = new GetDistributionCommand({ Id : cloudFrontDistributionID })
-  const distributionResponse = await cloudFrontClient.send(getDistributionCommand)
-  const distributionDomainName = distributionResponse.Distribution.DomainName
- 
-  const route53Client = new Route53Client({ credentials, region })
- 
-  const hostedZoneID = await getHostedZoneID({ route53Client, siteInfo })
- 
-  const domains = [apexDomain, 'www.' + apexDomain]
- 
-  const changeResourceRecordSetCommand = new ChangeResourceRecordSetsCommand({
-    HostedZoneId : hostedZoneID,
-    ChangeBatch  : {
-      Comment : `Point '${apexDomain}' and 'www.${apexDomain}' to CloudFront distribution.`,
-      Changes : domains.map((name) => ({
-        Action            : 'UPSERT',
-        ResourceRecordSet : {
-          Name        : name,
-          AliasTarget : {
-            DNSName              : distributionDomainName,
-            EvaluateTargetHealth : false,
-            HostedZoneId         : 'Z2FDTNDATAQYW2' // Static value specified by API for use with CloudFront aliases
-          },
-          Type : 'A'
-        }
-      }))
-    }
-  })
-  progressLogger.write(`Creating/updating Route 53 resource record sets/DNS entries for ${domains.join(', ')}...\n`)
-  await route53Client.send(changeResourceRecordSetCommand)
-}
- 
-export { createOrUpdateDNSRecords }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/find-certificate.mjs.html b/qa/coverage/lib/actions/lib/find-certificate.mjs.html deleted file mode 100644 index 466740d2..00000000 --- a/qa/coverage/lib/actions/lib/find-certificate.mjs.html +++ /dev/null @@ -1,172 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/find-certificate.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib find-certificate.mjs

-
- -
- 0% - Statements - 0/16 -
- - -
- 0% - Branches - 0/10 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/16 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { ListCertificatesCommand } from '@aws-sdk/client-acm'
- 
-import { progressLogger } from '../../shared/progress-logger'
- 
-const findCertificate = async ({ apexDomain, acmClient }) => {
-  progressLogger?.write('Searching for existing certificate... ')
-  let nextToken
-  do {
-    const listCertificatesCommand = new ListCertificatesCommand({
-      CertificateStatuses : ['PENDING_VALIDATION', 'ISSUED']
-    })
-    const listResponse = await acmClient.send(listCertificatesCommand)
- 
-    const domain = '*.' + apexDomain
-    for (const { CertificateArn, DomainName, Status } of listResponse.CertificateSummaryList) {
-      Iif (DomainName === domain) {
-        progressLogger?.write('FOUND\n')
-        return { certificateArn : CertificateArn, status : Status }
-      }
-    }
-    nextToken = listResponse.NextToken
-  } while (nextToken !== undefined)
- 
-  // if we fall out of the loop without returning, then we never found the named domain
-  progressLogger?.write('NOT found')
-  return { certificateArn : null, status : null }
-}
- 
-export { findCertificate }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/get-credentials.mjs.html b/qa/coverage/lib/actions/lib/get-credentials.mjs.html deleted file mode 100644 index 1a361e6a..00000000 --- a/qa/coverage/lib/actions/lib/get-credentials.mjs.html +++ /dev/null @@ -1,118 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/get-credentials.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib get-credentials.mjs

-
- -
- 0% - Statements - 0/6 -
- - -
- 0% - Branches - 0/3 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/6 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12  -  -  -  -  -  -  -  -  -  -  - 
import { fromIni } from '@aws-sdk/credential-providers'
- 
-const getCredentials = ({ 'sso-profile': ssoProfile }) => {
-  ssoProfile = ssoProfile || process.env.AWS_PROFILE || 'default'
- 
-  const credentials = fromIni({ profile : ssoProfile })
- 
-  return credentials
-}
- 
-export { getCredentials }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html b/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html deleted file mode 100644 index 0c0668ae..00000000 --- a/qa/coverage/lib/actions/lib/get-hosted-zone-id.mjs.html +++ /dev/null @@ -1,148 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/get-hosted-zone-id.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib get-hosted-zone-id.mjs

-
- -
- 0% - Statements - 0/11 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/11 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { ListHostedZonesCommand } from '@aws-sdk/client-route-53'
- 
-const getHostedZoneID = async ({ route53Client, siteInfo }) => {
-  let markerToken
-  do {
-    const listHostedZonesCommand = new ListHostedZonesCommand({ Marker : markerToken })
-    const listHostedZonesResponse = await route53Client.send(listHostedZonesCommand)
- 
-    for (const { Id, Name } of listHostedZonesResponse.HostedZones) {
-      Iif (Name === siteInfo.apexDomain + '.') {
-        return Id.replace(/\/[^/]+\/(.+)/, '$1') // /hostedzone/XXX -> XXX
-      }
-    }
- 
-    Iif (listHostedZonesResponse.IsTruncated === true) {
-      markerToken = listHostedZonesCommand.NextMarker
-    }
-  } while (markerToken !== undefined)
-}
- 
-export { getHostedZoneID }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/index.html b/qa/coverage/lib/actions/lib/index.html deleted file mode 100644 index 42d9c943..00000000 --- a/qa/coverage/lib/actions/lib/index.html +++ /dev/null @@ -1,266 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib - - - - - - - - - -
-
-

All files lib/actions/lib

-
- -
- 0% - Statements - 0/181 -
- - -
- 0% - Branches - 0/60 -
- - -
- 0% - Functions - 0/22 -
- - -
- 0% - Lines - 0/177 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
add-tags-to-hosted-zone.mjs -
-
0%0/10100%0/00%0/10%0/10
associate-cost-allocation-tags.mjs -
-
0%0/11100%0/00%0/20%0/11
create-or-update-dns-records.mjs -
-
0%0/18100%0/00%0/20%0/18
find-certificate.mjs -
-
0%0/160%0/100%0/10%0/16
get-credentials.mjs -
-
0%0/60%0/30%0/10%0/6
get-hosted-zone-id.mjs -
-
0%0/110%0/20%0/10%0/11
sync-site-content.mjs -
-
0%0/230%0/120%0/30%0/22
track-stack-status.mjs -
-
0%0/260%0/110%0/20%0/25
update-plugins.mjs -
-
0%0/130%0/110%0/20%0/12
update-site-info.mjs -
-
0%0/12100%0/00%0/20%0/12
update-stack.mjs -
-
0%0/350%0/110%0/50%0/34
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/sync-site-content.mjs.html b/qa/coverage/lib/actions/lib/sync-site-content.mjs.html deleted file mode 100644 index 647d19e2..00000000 --- a/qa/coverage/lib/actions/lib/sync-site-content.mjs.html +++ /dev/null @@ -1,193 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/sync-site-content.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib sync-site-content.mjs

-
- -
- 0% - Statements - 0/23 -
- - -
- 0% - Branches - 0/12 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/22 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { existsSync as fileExists } from 'node:fs'
-import * as fsPath from 'node:path'
- 
-import { S3Client } from '@aws-sdk/client-s3'
-import { tryExec } from '@liquid-labs/shell-toolkit'
-import mime from 'mime-types'
-import { S3SyncClient } from 's3-sync-client'
- 
-import { progressLogger } from '../../shared/progress-logger'I
- 
-const syncSiteContent = async ({ credentials, noBuild, siteInfo }) => {
-  const { bucketName, sourcePath, sourceType } = siteInfo
- 
-  Iif (noBuild !== true && sourceType === 'docusaurus') {
-    const packageRoot = fsPath.resolve(sourcePath, '..')
-    const packagePath = fsPath.join(packageRoot, 'package.json')
-    Iif (fileExists(packagePath)) {
-      progressLogger.write('Rebuilding site... ')
-      tryExec(`cd "${packageRoot}" && npm run build`)
-      progressLogger.write('done.\n')
-    }
-  }
- 
-  progressLogger.write(`Syncing files from ${sourcePath}...\n`)
- 
-  const s3Client = new S3Client({ credentials })
-  const { sync } = new S3SyncClient({ client : s3Client })
- 
-  await sync(sourcePath, 's3://' + bucketName, {
-    commandInput           : (input) => ({ ContentType : mime.lookup(input.Key) || 'application/octet-stream' }),
-    del                    : true,
-    maxConcurrentTransfers : 10
-  })
-}
- 
-export { syncSiteContent }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/track-stack-status.mjs.html b/qa/coverage/lib/actions/lib/track-stack-status.mjs.html deleted file mode 100644 index 56167996..00000000 --- a/qa/coverage/lib/actions/lib/track-stack-status.mjs.html +++ /dev/null @@ -1,214 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/track-stack-status.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib track-stack-status.mjs

-
- -
- 0% - Statements - 0/26 -
- - -
- 0% - Branches - 0/11 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/25 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { DeleteStackCommand, DescribeStacksCommand } from '@aws-sdk/client-cloudformation'
- 
-import { progressLogger } from '../../shared/progress-logger'
- 
-const RECHECK_WAIT_TIME = 2000 // ms
- 
-const trackStackStatus = async ({ cloudFormationClient, noDeleteOnFailure, noInitialStatus, stackName }) => {
-  let stackStatus, previousStatus
-  do {
-    const describeInput = { StackName : stackName }
-    const describeCommand = new DescribeStacksCommand(describeInput)
-    const describeResponse = await cloudFormationClient.send(describeCommand)
- 
-    stackStatus = describeResponse.Stacks[0].StackStatus
- 
-    if (stackStatus !== previousStatus && (noInitialStatus !== true || previousStatus !== undefined)) {
-      // convert to sentence case
-      const statusMessage = stackStatus.charAt(0) + stackStatus.slice(1).toLowerCase().replaceAll(/_/g, ' ')
-      progressLogger.write((previousStatus !== undefined ? '\n' : '') + statusMessage)
-      Iif (!stackStatus.endsWith('_PROGRESS')) {
-        progressLogger.write('\n')
-      }
-    } else {
-      progressLogger.write('.')
-    }
- 
-    previousStatus = stackStatus
-    await new Promise(resolve => setTimeout(resolve, RECHECK_WAIT_TIME))
-  } while (stackStatus.endsWith('_IN_PROGRESS'))
- 
-  Iif (stackStatus === 'ROLLBACK_COMPLETE' && noDeleteOnFailure !== true) {
-    progressLogger.write(`\nDeleting stack '${stackName}' `)
-    const deleteInput = { StackName : stackName }
-    const deleteCommand = new DeleteStackCommand(deleteInput)
-    await cloudFormationClient.send(deleteCommand)
- 
-    trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, noInitialStatus : true, stackName })
-  }
- 
-  return stackStatus
-}
- 
-export { trackStackStatus }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-plugins.mjs.html b/qa/coverage/lib/actions/lib/update-plugins.mjs.html deleted file mode 100644 index e29383a9..00000000 --- a/qa/coverage/lib/actions/lib/update-plugins.mjs.html +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/update-plugins.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib update-plugins.mjs

-
- -
- 0% - Statements - 0/13 -
- - -
- 0% - Branches - 0/11 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/12 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import * as plugins from '../../plugins'I
- 
-const updatePlugins = async ({ credentials, siteInfo }) => {
-  const { apexDomain, plugins : pluginsData } = siteInfo
-  const updates = []
- 
-  for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
-    const plugin = plugins[pluginKey]
-    Iif (plugin === undefined) {
-      throw new Error(`Unknown plugin found in '${apexDomain}' during update.`)
-    }
- 
-    const { updateHandler } = plugin
-    updates.push(updateHandler?.({ credentials, pluginData, siteInfo }))
-  }
- 
-  await Promise.all(updates)
-}
- 
-export { updatePlugins }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-site-info.mjs.html b/qa/coverage/lib/actions/lib/update-site-info.mjs.html deleted file mode 100644 index f9527807..00000000 --- a/qa/coverage/lib/actions/lib/update-site-info.mjs.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/update-site-info.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib update-site-info.mjs

-
- -
- 0% - Statements - 0/12 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/12 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { CloudFormationClient, DescribeStacksCommand } from '@aws-sdk/client-cloudformation'
- 
-import { progressLogger } from '../../shared/progress-logger'
- 
-const updateSiteInfo = async ({ credentials, siteInfo }) => {
-  const { region, stackName } = siteInfo
-  progressLogger.write('Gathering information from stack...\n')
-  const cloudFormationClient = new CloudFormationClient({ credentials, region })
-  const describeCommand = new DescribeStacksCommand({ StackName : stackName })
-  const describeResponse = await cloudFormationClient.send(describeCommand)
-  const cloudFrontDistributionID = describeResponse
-    .Stacks[0].Outputs.find(({ OutputKey }) => OutputKey === 'SiteCloudFrontDistribution').OutputValue
- 
-  siteInfo.cloudFrontDistributionID = cloudFrontDistributionID
-}
- 
-export { updateSiteInfo }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/lib/update-stack.mjs.html b/qa/coverage/lib/actions/lib/update-stack.mjs.html deleted file mode 100644 index 6c954763..00000000 --- a/qa/coverage/lib/actions/lib/update-stack.mjs.html +++ /dev/null @@ -1,283 +0,0 @@ - - - - - - Code coverage report for lib/actions/lib/update-stack.mjs - - - - - - - - - -
-
-

All files / lib/actions/lib update-stack.mjs

-
- -
- 0% - Statements - 0/35 -
- - -
- 0% - Branches - 0/11 -
- - -
- 0% - Functions - 0/5 -
- - -
- 0% - Lines - 0/34 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { CloudFormationClient, GetTemplateCommand, UpdateStackCommand } from '@aws-sdk/client-cloudformation'
-import isEqual from 'lodash/isEqual'
- 
-import * as plugins from '../../plugins'
-import { progressLogger } from '../../shared/progress-logger'
-import { SiteTemplate } from '../../shared/site-template'
-import { trackStackStatus } from './track-stack-status'
-import { updateSiteInfo } from './update-site-info'I
- 
-const updateStack = async ({ credentials, siteInfo }) => {
-  const { region, stackName } = siteInfo
- 
-  const siteTemplate = new SiteTemplate({ credentials, siteInfo })
-  await siteTemplate.initializeTemplate({ update : true })
-  await siteTemplate.loadPlugins({ update : true })
- 
-  const newTemplate = siteTemplate.render()
- 
-  const cloudFormationClient = new CloudFormationClient({ credentials, region })
-  const getTemplateCommand = new GetTemplateCommand({
-    StackName     : stackName,
-    TemplateStage : 'Original'
-  })
-  const getTemplateResponse = await cloudFormationClient.send(getTemplateCommand)
-  const currentTemplate = getTemplateResponse.TemplateBody
- 
-  Iif (isEqual(currentTemplate, newTemplate)) {
-    progressLogger.write('No change to template; skipping stack update.\n')
-    return
-  }
-  // else, the template has changed
- 
-  const stackUpdateCommand = new UpdateStackCommand({ // UpdateStackInput
-    StackName           : stackName,
-    TemplateBody        : newTemplate,
-    UsePreviousTemplate : false,
-    Capabilities        : ['CAPABILITY_IAM', 'CAPABILITY_NAMED_IAM'],
-    DisableRollback     : false
-  })
- 
-  await cloudFormationClient.send(stackUpdateCommand)
- 
-  const finalStatus = await trackStackStatus({ cloudFormationClient, noDeleteOnFailure : true, stackName })
- 
-  await updateSiteInfo({ credentials, siteInfo }) // needed by createOrUpdateDNSRecords
- 
-  const postUpdateHandlers = Object.keys(siteInfo.pluginSettings || {}).map((pluginKey) =>
-    [pluginKey, plugins[pluginKey].postUpdateHandler]
-  )
-    .filter(([, postUpdateHandler]) => postUpdateHandler !== undefined)
- 
-  Iif (postUpdateHandlers.length > 0) {
-    await Promise.all([
-      ...(postUpdateHandlers.map(([pluginKey, handler]) =>
-        handler({ settings : siteInfo.pluginSettings[pluginKey], siteInfo })))
-    ])
-  }
- 
-  Iif (finalStatus === 'UPDATE_COMPLETE') {
-    progressLogger.write('Stack updated.\n')
-  }
- 
-  return finalStatus
-}
- 
-export { updateStack }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/update.mjs.html b/qa/coverage/lib/actions/update.mjs.html deleted file mode 100644 index cebc937e..00000000 --- a/qa/coverage/lib/actions/update.mjs.html +++ /dev/null @@ -1,361 +0,0 @@ - - - - - - Code coverage report for lib/actions/update.mjs - - - - - - - - - -
-
-

All files / lib/actions update.mjs

-
- -
- 0% - Statements - 0/41 -
- - -
- 0% - Branches - 0/24 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/41 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { CloudFrontClient, CreateInvalidationCommand } from '@aws-sdk/client-cloudfront'
- 
-import { addTagsToHostedZone } from './lib/add-tags-to-hosted-zone'
-import {
-  associateCostAllocationTags,
-  handleAssociateCostAllocationTagsError
-} from './lib/associate-cost-allocation-tags'
-import { createOrUpdateDNSRecords } from './lib/create-or-update-dns-records'
-import { getCredentials } from './lib/get-credentials'
-import { getSiteTag } from '../shared/get-site-tag'
-import { progressLogger } from '../shared/progress-logger'
-import { syncSiteContent } from './lib/sync-site-content'
-import { updatePlugins } from './lib/update-plugins'
-import { updateStack } from './lib/update-stack'
- 
-const update = async ({
-  db,
-  doBilling,
-  doContent,
-  doDNS,
-  doStack,
-  noBuild,
-  noCacheInvalidation,
-  siteInfo
-}) => {
-  const doAll = doBilling === undefined && doContent === undefined && doDNS === undefined && doStack === undefined
- 
-  const credentials = getCredentials(db.account.settings)
- 
-  const firstRoundUpdates = []
-  Iif (doAll === true || doContent === true) {
-    // method will report actions to user
-    firstRoundUpdates.push(syncSiteContent({ credentials, noBuild, siteInfo }))
-  }
- 
-  Iif (doAll === true || doDNS === true) {
-    firstRoundUpdates.push(createOrUpdateDNSRecords({ credentials, siteInfo }))
-  }
- 
-  await Promise.all(firstRoundUpdates)
- 
-  let stackUpdateStatus
-  Iif (doAll === true || doStack === true) {
-    stackUpdateStatus = await updateStack({ credentials, siteInfo })
-    Iif (stackUpdateStatus === 'UPDATE_COMPLETE') {
-      await updatePlugins({ credentials, siteInfo })
-      // have to do this after the other updates so that the tags get created first
-    }
-  }
- 
-  const secondRoundUpdates = []
- 
-  Iif (doAll === true || doBilling === true) {
-    const siteTag = getSiteTag(siteInfo)
-    try {
-      await associateCostAllocationTags({ credentials, tag : siteTag })
-    } catch (e) {
-      handleAssociateCostAllocationTagsError({ e, siteInfo })
-    }
-  }
- 
-  Iif (doAll === true || doDNS === true) {
-    secondRoundUpdates.push(addTagsToHostedZone({ credentials, siteInfo }))
-  }
- 
-  Iif ((doAll === true || doContent === true) && noCacheInvalidation !== true) {
-    secondRoundUpdates.push(invalidateCache({ credentials, siteInfo }))
-  }
- 
-  await Promise.all(secondRoundUpdates)
-}
- 
-const invalidateCache = async ({ credentials, siteInfo }) => {
-  progressLogger.write('Invalidating CloudFront cache...\n')
- 
-  const { cloudFrontDistributionID } = siteInfo
- 
-  const cloudFrontClient = new CloudFrontClient({ credentials })
-  const invalidateCacheCommand = new CreateInvalidationCommand({
-    DistributionId    : cloudFrontDistributionID,
-    InvalidationBatch : {
-      Paths : {
-        Quantity : 1,
-        Items    : ['/*']
-      },
-      CallerReference : new Date().getTime() + ''
-    }
-  })
-  await cloudFrontClient.send(invalidateCacheCommand)
-}
- 
-export { update }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/actions/verify.mjs.html b/qa/coverage/lib/actions/verify.mjs.html deleted file mode 100644 index 72c3f8c8..00000000 --- a/qa/coverage/lib/actions/verify.mjs.html +++ /dev/null @@ -1,631 +0,0 @@ - - - - - - Code coverage report for lib/actions/verify.mjs - - - - - - - - - -
-
-

All files / lib/actions verify.mjs

-
- -
- 0% - Statements - 0/100 -
- - -
- 0% - Branches - 0/37 -
- - -
- 0% - Functions - 0/7 -
- - -
- 0% - Lines - 0/97 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import {
-  CloudFormationClient,
-  DescribeStackDriftDetectionStatusCommand,
-  DetectStackDriftCommand
-} from '@aws-sdk/client-cloudformation'
-import { S3Client } from '@aws-sdk/client-s3'
-import { S3SyncClient } from 's3-sync-client'
- 
-import { getCredentials } from './lib/get-credentials'
-import { progressLogger } from '../shared/progress-logger'
- 
-const RECHECK_WAIT_TIME = 2000 // ms
- 
-const verify = async ({ checkContent, checkSiteUp, checkStack, db, siteInfo }) => {
-  const checkAll = checkContent === undefined && checkSiteUp === undefined && checkStack === undefined
-  let credentials
-  Iif (checkAll || checkContent || checkStack) {
-    credentials = getCredentials(db.account.settings)
-  }
- 
-  const checks = []
-  Iif (checkAll || checkSiteUp) {
-    checks.push(doCheckSiteUp({ progressLogger, siteInfo }))
-  }
-  Iif (checkAll || checkContent) {
-    checks.push(doCheckContent({ credentials, progressLogger, siteInfo }))
-  }
-  Iif (checkAll || checkStack) {
-    checks.push(doCheckStack({ credentials, progressLogger, siteInfo }))
-  }
- 
-  const results = await Promise.all(checks)
- 
-  return results.reduce((acc, array) => { acc.push(...array); return acc }, [])
-}
- 
-const doCheckContent = async ({ credentials, progressLogger, siteInfo }) => {
-  Iif (progressLogger !== undefined) {
-    progressLogger.write('Checking site content in sync...\n')
-  }
-  const { bucketName, sourcePath } = siteInfo
- 
-  const s3Client = new S3Client({ credentials })
-  const { sync } = new S3SyncClient({ client : s3Client })
- 
-  const checkResult = { check : 'S3 bucket and local source in sync' }
-  try {
-    const objectData = await sync(sourcePath, 's3://' + bucketName, { dryRun : true })
- 
-    const createdCount = objectData.created.length
-    const updatedCount = objectData.updated.length
-    const deletedCount = objectData.deleted.length
-    const inSync = (createdCount + updatedCount + deletedCount) === 0
-    if (inSync === true) {
-      checkResult.status = 'success'
-      checkResult.message = 'S3 bucket and local source are up-to-date'
-    } else {
-      checkResult.status = 'failed'
-      checkResult.message =
-        `${createdCount} files to create, ${updatedCount} files to update, and ${deletedCount} files to delete`
-    }
- 
-    return [checkResult]
-  } catch (e) {
-    checkResult.status = 'error'
-    checkResult.message = e.message
- 
-    return [checkResult]
-  } finally {
-    Iif (progressLogger !== undefined) {
-      progressLogger.write('Site content check complete.\n')
-    }
-  }
-}
- 
-const doCheckSiteUp = async ({ progressLogger, siteInfo }) => {
-  Iif (progressLogger !== undefined) {
-    progressLogger.write('Checking site is up...\n')
-  }
-  const { apexDomain } = siteInfo
- 
-  try {
-    const fetchResponses = await Promise.all([
-      fetch('https://' + apexDomain),
-      fetch('https://www.' + apexDomain)
-    ])
- 
-    const results = [
-      processFetchResults({ domain : apexDomain, fetchResponse : fetchResponses[0] }),
-      processFetchResults({ domain : 'www.' + apexDomain, fetchResponse : fetchResponses[1] })
-    ]
- 
-    return results
-  } catch (e) {
-    return [
-      { check : `site ${apexDomain} is up`, status : 'error', message : e.message },
-      { check : `site www.${apexDomain} is up`, status : 'error', message : e.message }
-    ]
-  } finally {
-    Iif (progressLogger !== undefined) {
-      progressLogger.write('Site is up check complete.\n')
-    }
-  }
-}
- 
-const doCheckStack = async ({ credentials, progressLogger, siteInfo }) => {
-  Iif (progressLogger !== undefined) {
-    progressLogger.write('Checking stack drift status...\n')
-  }
- 
-  const checkResult = { check : 'Stack drift check' }
- 
-  try {
-    const { stackName } = siteInfo
-    const cfClient = new CloudFormationClient({ credentials })
-    const detectDriftCommand = new DetectStackDriftCommand({ StackName : stackName })
-    const stackDriftOperationID = (await cfClient.send(detectDriftCommand)).StackDriftDetectionId
- 
-    const describeStackDriftDetectionCommand = new DescribeStackDriftDetectionStatusCommand({
-      StackDriftDetectionId : stackDriftOperationID
-    })
-    let stackDriftDescribeResponse
-    let detectionStatus
-    do {
-      Iif (progressLogger !== undefined) {
-        progressLogger.write('.')
-      }
-      await new Promise(resolve => setTimeout(resolve, RECHECK_WAIT_TIME))
- 
-      stackDriftDescribeResponse = await cfClient.send(describeStackDriftDetectionCommand)
-      detectionStatus = stackDriftDescribeResponse.DetectionStatus
-    } while (detectionStatus === 'DETECTION_IN_PROGRESS')
- 
-    const stackDriftStatus = stackDriftDescribeResponse.StackDriftStatus
-    if (detectionStatus === 'DETECTION_FAILED') {
-      checkResult.status = 'error'
-      checkResult.message = (stackDriftStatus === 'IN_SYNC'
-        ? 'Stack as checked in sync, but: '
-        : 'Stack not in sync and: ') +
-        stackDriftDescribeResponse.DetectionStatusReason
-    } else if (stackDriftStatus === 'IN_SYNC') {
-      checkResult.status = 'success'
-      checkResult.message = stackName + ' is in sync with template'
-    } else if (stackDriftStatus === 'UNKNOWN') {
-      checkResult.status = 'error'
-      checkResult.message = stackName + ' drift status is unknown'
-    } else if (stackDriftStatus === 'DRIFTED') {
-      checkResult.status = 'failed'
-      checkResult.message =
-        `${stackDriftDescribeResponse.DriftedStackResourceCount} resources have drifted on stack ${stackName}`
-    } else {
-      checkResult.status = 'error'
-      checkResult.message = `Unexpected status '${stackDriftStatus} while checking ${stackName}`
-    }
-  } catch (e) {
-    checkResult.status = 'error'
-    checkResult.message = e.message
-  } finally {
-    Iif (progressLogger !== undefined) {
-      progressLogger.write('\nStack drift check complete.\n')
-    }
-  }
- 
-  return [checkResult]
-}
- 
-const processFetchResults = ({ domain, fetchResponse }) => {
-  const result = {
-    check   : `site ${domain} is up`,
-    message : `Got HTTP status ${fetchResponse.status} fetching https://${domain}.`
-  }
- 
-  if (fetchResponse.status === 200) {
-    result.status = 'success'
-  } else {
-    result.status = 'failed'
-  }
- 
-  return result
-}
- 
-export { verify }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/access-logs.mjs.html b/qa/coverage/lib/plugins/access-logs.mjs.html deleted file mode 100644 index 1a7fdea4..00000000 --- a/qa/coverage/lib/plugins/access-logs.mjs.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - Code coverage report for lib/plugins/access-logs.mjs - - - - - - - - - -
-
-

All files / lib/plugins access-logs.mjs

-
- -
- 0% - Statements - 0/6 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/6 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14  -  -  -  -  -  -  -  -  -  -  -  -  - 
const config = {
-  options : { default : true, validation : (v) => typeof v === 'boolean' }
-}
- 
-const handler = () => {
-  throw new Error('Not yet implemented')
-}
- 
-const importHandler = () => {}
- 
-const accessLogs = { config, handler, importHandler }
- 
-export { accessLogs }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/cloudfront-logs.mjs.html b/qa/coverage/lib/plugins/cloudfront-logs.mjs.html deleted file mode 100644 index e3201cd7..00000000 --- a/qa/coverage/lib/plugins/cloudfront-logs.mjs.html +++ /dev/null @@ -1,211 +0,0 @@ - - - - - - Code coverage report for lib/plugins/cloudfront-logs.mjs - - - - - - - - - -
-
-

All files / lib/plugins cloudfront-logs.mjs

-
- -
- 0% - Statements - 0/14 -
- - -
- 0% - Branches - 0/1 -
- - -
- 0% - Functions - 0/4 -
- - -
- 0% - Lines - 0/14 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
const config = {
-  name        : 'CloudFront logs',
-  description : 'Enables logging of CloudFront events.',
-  options     : {
-    includeCookies : {
-      description : 'Whether to log cookies or not.',
-      default     : false,
-      type        : 'boolean',
-      validation  : (v) => typeof v === 'boolean'
-    }
-  }
-}
- 
-const importHandler = ({ /* credentials, */ name, pluginsData, /* siteInfo, */ template }) => {
-  const cloudFrontLoggingConfig = template.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Logging
-  Iif (cloudFrontLoggingConfig !== undefined) {
-    const settings = {
-      includeCookies : cloudFrontLoggingConfig.IncludeCookies
-    }
-    pluginsData[name] = settings
-  }
-}
- 
-const preStackDestroyHandler = async ({ siteTemplate }) => {
-  await siteTemplate.destroyCommonLogsBucket()
-}
- 
-const stackConfig = async ({ siteTemplate, pluginData }) => {
-  const { finalTemplate } = siteTemplate
- 
-  await siteTemplate.enableCommonLogsBucket()
- 
-  finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Logging = {
-    Bucket         : { 'Fn::GetAtt' : ['commonLogsBucket', 'DomainName'] },
-    IncludeCookies : pluginData.settings.includeCookies,
-    Prefix         : 'cloudfront-logs/'
-  }
-}
- 
-const cloudfrontLogs = { config, importHandler, preStackDestroyHandler, stackConfig }
- 
-export { cloudfrontLogs }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html deleted file mode 100644 index 278fa676..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/constants.mjs.html +++ /dev/null @@ -1,175 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/constants.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib constants.mjs

-
- -
- 0% - Statements - 0/4 -
- - -
- 100% - Branches - 0/0 -
- - -
- 100% - Functions - 0/0 -
- - -
- 0% - Lines - 0/4 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
export const CONTACT_EMAILER_ZIP_NAME = 'contact-emailer-lambda.zip'
-export const CONTACT_HANDLER_ZIP_NAME = 'contact-handler-lambda.zip'
-export const REQUEST_SIGNER_ZIP_NAME = 'request-signer-lambda.zip'
- 
-export const STANDARD_FORM_FIELDS = {
-  // ID
-  given_name            : 'S',
-  family_name           : 'S',
-  company               : 'S',
-  // demo
-  company_size          : 'S',
-  industry              : 'S',
-  revenue               : 'S',
-  // contact
-  email                 : 'S',
-  phone_number_home     : 'S',
-  phone_number_mobile   : 'S',
-  phone_number_work     : 'S',
-  phone_number_work_ext : 'S',
-  // location
-  address_1             : 'S',
-  address_2             : 'S',
-  city                  : 'S',
-  state                 : 'S',
-  zip_code              : 'S',
-  county                : 'S',
-  // purpose
-  message               : 'S',
-  topics                : 'SS'
-}
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html deleted file mode 100644 index 408c1632..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/determine-lambda-function-name.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib determine-lambda-function-name.mjs

-
- -
- 0% - Statements - 0/23 -
- - -
- 0% - Branches - 0/20 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/23 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { v4 as uuidv4 } from 'uuid'
- 
-import { LambdaClient, GetFunctionCommand } from '@aws-sdk/client-lambda'
- 
-import { progressLogger } from '../../../shared/progress-logger'
- 
-const determineLambdaFunctionName = async ({ baseName, credentials, siteTemplate }) => {
-  const { siteInfo } = siteTemplate
-  const { region } = siteInfo
-  let currentName = baseName
- 
-  const lambdaClient = new LambdaClient({ credentials, region })
-  while (true) {
-    progressLogger?.write(`Checking if Lambda function name '${currentName}' is free...`)
-    const getFunctionCommand = new GetFunctionCommand({ FunctionName : currentName })
-    try {
-      await lambdaClient.send(getFunctionCommand)
-    } catch (e) {
-      if (e.name === 'NotFound' || e.$metadata?.httpStatusCode === 404) {
-        progressLogger?.write('FREE\n')
-        return currentName
-      } else {
-        progressLogger?.write('\n')
-        throw e
-      }
-    }
-    progressLogger?.write('NOT free\n')
-    const nameSalt = uuidv4().slice(0, 8)
-    currentName = currentName.replace(/-[A-F0-9]{8}$/i, '')
-    currentName += '-' + nameSalt
-  }
-}
- 
-export { determineLambdaFunctionName }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/index.html b/qa/coverage/lib/plugins/contact-handler/lib/index.html deleted file mode 100644 index ddb6e3d8..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/index.html +++ /dev/null @@ -1,221 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib - - - - - - - - - -
-
-

All files lib/plugins/contact-handler/lib

-
- -
- 0% - Statements - 0/161 -
- - -
- 0% - Branches - 0/42 -
- - -
- 0% - Functions - 0/8 -
- - -
- 0% - Lines - 0/161 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
constants.mjs -
-
0%0/4100%0/0100%0/00%0/4
determine-lambda-function-name.mjs -
-
0%0/230%0/200%0/10%0/23
setup-contact-emailer.mjs -
-
0%0/300%0/100%0/10%0/30
setup-contact-form-table.mjs -
-
0%0/10100%0/00%0/10%0/10
setup-contact-handler.mjs -
-
0%0/320%0/60%0/10%0/32
setup-request-signer.mjs -
-
0%0/180%0/20%0/10%0/18
stage-lambda-function-zip-files.mjs -
-
0%0/330%0/20%0/20%0/33
update-cloud-front-distribution.mjs -
-
0%0/110%0/20%0/10%0/11
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html deleted file mode 100644 index 73e4cab7..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-emailer.mjs.html +++ /dev/null @@ -1,544 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/setup-contact-emailer.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib setup-contact-emailer.mjs

-
- -
- 0% - Statements - 0/30 -
- - -
- 0% - Branches - 0/10 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/30 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { LambdaClient, UpdateFunctionCodeCommand } from '@aws-sdk/client-lambda'
- 
-import { CONTACT_EMAILER_ZIP_NAME, STANDARD_FORM_FIELDS } from './constants'
-import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
-import { determineLambdaFunctionName } from './determine-lambda-function-name'
-import { getSiteTag } from '../../../shared/get-site-tag'
- 
-const setupContactEmailer = async ({ credentials, lambdaFunctionsBucketName, update, pluginData, siteTemplate }) => {
-  const { finalTemplate, siteInfo } = siteTemplate
-  const { apexDomain } = siteInfo
-  const {
-    emailFrom : contactHandlerFromEmail,
-    emailTo : contactHandlerTargetEmail,
-    formFields = 'standard'
-  } = pluginData.settings
- 
-  Iif (contactHandlerFromEmail === undefined && contactHandlerTargetEmail !== undefined) {
-    throw new Error("Found site setting for 'emailTo', but no 'emailFrom'; 'emailFrom' must be set to activate email functionality.")
-  }
- 
-  // setup stream on table
-  finalTemplate.Resources.ContactHandlerDynamoDB.Properties.StreamSpecification = {
-    StreamViewType : 'NEW_IMAGE'
-  }
- 
-  const emailerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-contact-emailer'
-  const emailerFunctionName = update
-    ? pluginData.emailerFunctionName
-    : (await determineLambdaFunctionName({
-        baseName : emailerFunctionBaseName,
-        credentials,
-        siteTemplate
-      }))
-  pluginData.emailerFunctionName = emailerFunctionName
-  const emailerFunctionLogGroupName = emailerFunctionName
- 
-  const formFieldsSpec = formFields === 'standard'
-    ? JSON.stringify(STANDARD_FORM_FIELDS)
-    : formFields
- 
-  const siteTag = getSiteTag(siteInfo)
-  const tags = [{ Key : siteTag, Value : '' }]
- 
-  finalTemplate.Resources.ContactEmailerLogGroup = {
-    Type       : 'AWS::Logs::LogGroup',
-    Properties : {
-      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
-      LogGroupName    : emailerFunctionLogGroupName,
-      RetentionInDays : 180 // TODO: support options
-    }
-  }
- 
-  finalTemplate.Resources.ContactEmailerRole = {
-    Type       : 'AWS::IAM::Role',
-    Properties : {
-      AssumeRolePolicyDocument : {
-        Version   : '2012-10-17',
-        Statement : [
-          {
-            Effect    : 'Allow',
-            Principal : {
-              Service : ['lambda.amazonaws.com']
-            },
-            Action : ['sts:AssumeRole']
-          }
-        ]
-      },
-      Path     : '/cloudsite/contact-emailer/',
-      Policies : [
-        {
-          PolicyName     : emailerFunctionName,
-          PolicyDocument : {
-            Version   : '2012-10-17',
-            Statement : [
-              {
-                Effect   : 'Allow',
-                Action   : ['ses:SendEmail', 'ses:SendEmailRaw', 'ses:GetSendQuota', 'ses:GetSendStatistics'],
-                Resource : '*'
-              }
-            ]
-          }
-        }
-      ],
-      ManagedPolicyArns : [
-        // AWSLambdaBasicExecutionRole: allows logging to CloudWatch
-        'arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole',
-        // Allows reading from DynamoDB streams
-        'arn:aws:iam::aws:policy/service-role/AWSLambdaDynamoDBExecutionRole'
-      ],
-      Tags : tags
-    } // Properties
-  }
- 
-  finalTemplate.Resources.ContactEmailerFunction = {
-    Type       : 'AWS::Lambda::Function',
-    DependsOn  : ['ContactEmailerRole', 'ContactEmailerLogGroup'],
-    Properties : {
-      FunctionName : emailerFunctionName,
-      Handler      : 'index.handler',
-      Role         : { 'Fn::GetAtt' : ['ContactEmailerRole', 'Arn'] },
-      Runtime      : 'nodejs20.x',
-      MemorySize   : 128,
-      Timeout      : 5,
-      Code         : {
-        S3Bucket : lambdaFunctionsBucketName,
-        S3Key    : CONTACT_EMAILER_ZIP_NAME
-      },
-      Environment : {
-        Variables : {
-          APEX_DOMAIN                : apexDomain,
-          EMAIL_HANDLER_SOURCE_EMAIL : contactHandlerFromEmail,
-          FORM_FIELDS                : formFieldsSpec
-          // EMAIL_HANDSER_TARGET_EMAIL will be added late if defined
-        }
-      },
-      LoggingConfig : {
-        ApplicationLogLevel : 'INFO', // support options
-        LogFormat           : 'JSON', // support options
-        LogGroup            : emailerFunctionLogGroupName,
-        SystemLogLevel      : 'INFO' // support options
-      },
-      Tags : tags
-    } // Properties
-  }
- 
-  finalTemplate.Resources.ContactEmailerEventsSource = {
-    Type       : 'AWS::Lambda::EventSourceMapping',
-    DependsOn  : ['ContactEmailerFunction'],
-    Properties : {
-      FunctionName     : { 'Fn::GetAtt' : ['ContactEmailerFunction', 'Arn'] },
-      EventSourceArn   : { 'Fn::GetAtt' : ['ContactHandlerDynamoDB', 'StreamArn'] },
-      StartingPosition : 'LATEST'
-    }
-  }
- 
-  Iif (contactHandlerTargetEmail !== undefined) {
-    finalTemplate.Resources.ContactEmailerFunction.Properties.Environment.Variables.EMAIL_HANDLER_TARGET_EMAIL =
-      contactHandlerTargetEmail
-  }
- 
-  Iif (update === true) {
-    const client = new LambdaClient({ credentials })
-    const command = new UpdateFunctionCodeCommand({ // UpdateFunctionCodeRequest
-      FunctionName : emailerFunctionName,
-      S3Bucket     : lambdaFunctionsBucketName,
-      S3Key        : CONTACT_EMAILER_ZIP_NAME
-      // Publish: true || false,
-    })
-    await client.send(command)
-  }
-}
- 
-export { setupContactEmailer }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html deleted file mode 100644 index c6722813..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-form-table.mjs.html +++ /dev/null @@ -1,178 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/setup-contact-form-table.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib setup-contact-form-table.mjs

-
- -
- 0% - Statements - 0/10 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/10 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { getSiteTag } from '../../../shared/get-site-tag'
- 
-const setupContactFormTable = ({ siteInfo, siteTemplate }) => {
-  const { finalTemplate, resourceTypes } = siteTemplate
-  const { bucketName } = siteInfo
- 
-  const siteTag = getSiteTag(siteInfo)
-  const tags = [{ Key : siteTag, Value : '' }]
- 
-  finalTemplate.Resources.ContactHandlerDynamoDB = {
-    Type       : 'AWS::DynamoDB::Table',
-    Properties : {
-      TableName            : bucketName + '-ContactFormEntries',
-      AttributeDefinitions : [
-        { AttributeName : 'SubmissionID', AttributeType : 'S' },
-        { AttributeName : 'SubmissionTime', AttributeType : 'S' }
-      ],
-      KeySchema : [
-        { AttributeName : 'SubmissionID', KeyType : 'HASH' },
-        { AttributeName : 'SubmissionTime', KeyType : 'RANGE' }
-      ],
-      BillingMode : 'PAY_PER_REQUEST',
-      Tags        : tags
-    }
-  }
- 
-  finalTemplate.Outputs.ContactHandlerDynamoDB = { Value : { Ref : 'ContactHandlerDynamoDB' } }
-  resourceTypes['DynamoDB::Table'] = true
-}
- 
-export { setupContactFormTable }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html deleted file mode 100644 index ebd98a03..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/setup-contact-handler.mjs.html +++ /dev/null @@ -1,613 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/setup-contact-handler.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib setup-contact-handler.mjs

-
- -
- 0% - Statements - 0/32 -
- - -
- 0% - Branches - 0/6 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/32 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { LambdaClient, UpdateFunctionCodeCommand } from '@aws-sdk/client-lambda'
- 
-import { CONTACT_HANDLER_ZIP_NAME, STANDARD_FORM_FIELDS } from './constants'
-import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
-import { determineLambdaFunctionName } from './determine-lambda-function-name'
-import { getSiteTag } from '../../../shared/get-site-tag'
- 
-const setupContactHandler = async ({
-  credentials,
-  lambdaFunctionsBucketName,
-  pluginData,
-  siteInfo,
-  siteTemplate,
-  update
-}) => {
-  const { accountID, apexDomain, bucketName, region } = siteInfo
-  const { finalTemplate, resourceTypes } = siteTemplate
- 
-  const contactHandlerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-contact-handler'
-  const contactHandlerFunctionName = update === true
-    ? pluginData.contactHandlerFunctionName
-    : (await determineLambdaFunctionName({
-        baseName : contactHandlerFunctionBaseName,
-        credentials,
-        siteTemplate
-      }))
-  pluginData.contactHandlerFunctionName = contactHandlerFunctionName
- 
-  const contactHandlerLogGroupName = contactHandlerFunctionName
- 
-  const { formFields = 'standard' } = pluginData.settings
-  const formFieldsSpec = formFields === 'standard'
-    ? JSON.stringify(STANDARD_FORM_FIELDS)
-    : formFields
- 
-  const siteTag = getSiteTag(siteInfo)
-  const tags = [{ Key : siteTag, Value : '' }]
- 
-  finalTemplate.Resources.ContactHandlerRole = {
-    Type       : 'AWS::IAM::Role',
-    Properties : {
-      AssumeRolePolicyDocument : {
-        Version   : '2012-10-17',
-        Statement : [
-          {
-            Effect    : 'Allow',
-            Principal : {
-              Service : ['lambda.amazonaws.com']
-            },
-            Action : ['sts:AssumeRole']
-          }
-        ]
-      },
-      Path     : '/cloudsite/contact-processor/',
-      Policies : [
-        {
-          Version   : '2012-10-17',
-          Statement : [
-            {
-              Action : [
-                'dynamodb:PutItem'
-              ],
-              Resource : { 'Fn::GetAtt' : ['ContactHandlerDynamoDB', 'Arn'] },
-              Effect   : 'Allow'
-            },
-            {
-              Effect   : 'Allow',
-              Action   : 'logs:CreateLogGroup',
-              Resource : `arn:aws:${region}:${accountID}:*`
-            },
-            {
-              Effect : 'Allow',
-              Action : [
-                'logs:CreateLogStream',
-                'logs:PutLogEvents'
-              ],
-              Resource : [
-                `arn:aws:logs:${region}:${accountID}:log-group:${contactHandlerLogGroupName}:*`
-              ]
-            }
-          ]
-        }
-      ],
-      Tags : tags
-    } // Properties
-  }
-  finalTemplate.Outputs.ContactHandlerRole = { Value : { Ref : 'ContactHandlerRole' } }
-  resourceTypes['IAM::Role'] = true
- 
-  finalTemplate.Resources.ContactHandlerLogGroup = {
-    Type       : 'AWS::Logs::LogGroup',
-    Properties : {
-      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
-      LogGroupName    : contactHandlerLogGroupName,
-      RetentionInDays : 180, // TODO: support options,
-      Tags            : tags
-    }
-  }
- 
-  finalTemplate.Resources.ContactHandlerLambdaFunction = {
-    Type       : 'AWS::Lambda::Function',
-    DependsOn  : ['ContactHandlerRole', 'ContactHandlerLogGroup'],
-    Properties : {
-      FunctionName : contactHandlerFunctionName,
-      Description  : 'Handles contact form submissions; creates DynamoDB entry and sends email.',
-      Code         : {
-        S3Bucket : lambdaFunctionsBucketName,
-        S3Key    : CONTACT_HANDLER_ZIP_NAME
-      },
-      Handler     : 'index.handler',
-      Role        : { 'Fn::GetAtt' : ['ContactHandlerRole', 'Arn'] },
-      Runtime     : 'nodejs20.x',
-      MemorySize  : 128,
-      Timeout     : 5,
-      Environment : {
-        Variables : {
-          TABLE_PREFIX : bucketName,
-          FORM_FIELDS  : formFieldsSpec
-        }
-      },
-      LoggingConfig : {
-        ApplicationLogLevel : 'INFO', // support options
-        LogFormat           : 'JSON', // support options
-        LogGroup            : contactHandlerLogGroupName,
-        SystemLogLevel      : 'INFO' // support options
-      },
-      Tags : tags
-    } // Properties
-  }
-  finalTemplate.Outputs.ContactHandlerLambdaFunction = { Value : { Ref : 'ContactHandlerLambdaFunction' } }
-  resourceTypes['Lambda::Function'] = true
- 
-  finalTemplate.Resources.ContactHandlerLambdaPermission = {
-    Type       : 'AWS::Lambda::Permission',
-    DependsOn  : ['SiteCloudFrontDistribution', 'ContactHandlerLambdaFunction'],
-    Properties : {
-      Action              : 'lambda:InvokeFunctionUrl',
-      Principal           : 'cloudfront.amazonaws.com',
-      FunctionName        : contactHandlerFunctionName,
-      FunctionUrlAuthType : 'AWS_IAM',
-      SourceArn           : {
-        'Fn::Join' : ['', [`arn:aws:cloudfront::${accountID}:distribution/`, { 'Fn::GetAtt' : ['SiteCloudFrontDistribution', 'Id'] }]]
-      }
-    }
-  }
- 
-  finalTemplate.Resources.ContactHandlerLambdaURL = {
-    Type       : 'AWS::Lambda::Url',
-    DependsOn  : ['ContactHandlerLambdaFunction'],
-    Properties : {
-      AuthType : 'AWS_IAM',
-      Cors     : {
-        AllowCredentials : true,
-        AllowHeaders     : ['*'],
-        AllowMethods     : ['POST'],
-        AllowOrigins     : ['*']
-      },
-      TargetFunctionArn : { 'Fn::GetAtt' : ['ContactHandlerLambdaFunction', 'Arn'] }
-    }
-  }
-  finalTemplate.Outputs.ContactHandlerLambdaURL = { Value : { Ref : 'ContactHandlerLambdaURL' } }
-  resourceTypes['Lambda::Url'] = true
- 
-  Iif (update === true) {
-    const client = new LambdaClient({ credentials })
-    const command = new UpdateFunctionCodeCommand({ // UpdateFunctionCodeRequest
-      FunctionName : contactHandlerFunctionName,
-      S3Bucket     : lambdaFunctionsBucketName,
-      S3Key        : CONTACT_HANDLER_ZIP_NAME
-      // Publish: true || false,
-    })
-    await client.send(command)
-  }
-}
- 
-export { setupContactHandler }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html deleted file mode 100644 index 6995c985..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/setup-request-signer.mjs.html +++ /dev/null @@ -1,403 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/setup-request-signer.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib setup-request-signer.mjs

-
- -
- 0% - Statements - 0/18 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/18 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { REQUEST_SIGNER_ZIP_NAME } from './constants'
-import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
-import { determineLambdaFunctionName } from './determine-lambda-function-name'
-import { getSiteTag } from '../../../shared/get-site-tag'
- 
-const setupRequestSigner = async ({ credentials, lambdaFunctionsBucketName, pluginData, update, siteTemplate }) => {
-  const { finalTemplate, siteInfo } = siteTemplate
-  const { apexDomain } = siteInfo
- 
-  const siteTag = getSiteTag(siteInfo)
-  const tags = [{ Key : siteTag, Value : '' }]
- 
-  const requestSignerFunctionBaseName = convertDomainToBucketName(apexDomain) + '-request-signer'
-  const requestSignerFunctionName = update === true
-    ? pluginData.requestSignerFunctionName
-    : (await determineLambdaFunctionName({
-        baseName : requestSignerFunctionBaseName,
-        credentials,
-        siteTemplate
-      }))
-  pluginData.requestSignerFunctionName = requestSignerFunctionName
- 
-  finalTemplate.Resources.RequestSignerRole = {
-    Type       : 'AWS::IAM::Role',
-    DependsOn  : ['ContactHandlerLambdaFunction'],
-    Properties : {
-      AssumeRolePolicyDocument : {
-        Version   : '2012-10-17',
-        Statement : [
-          {
-            Effect    : 'Allow',
-            Principal : { Service : ['lambda.amazonaws.com', 'edgelambda.amazonaws.com'] },
-            Action    : ['sts:AssumeRole']
-          }
-        ]
-      },
-      Path     : '/cloudsite/request-signer/',
-      Policies : [
-        {
-          PolicyName     : requestSignerFunctionName,
-          PolicyDocument : {
-            Version   : '2012-10-17',
-            Statement : [
-              {
-                Effect   : 'Allow',
-                Action   : 'lambda:InvokeFunctionUrl',
-                Resource : { 'Fn::GetAtt' : ['ContactHandlerLambdaFunction', 'Arn'] }
-              }
-            ]
-          }
-        }
-      ],
-      // AWSLambdaBasicExecutionRole: allows logging to CloudWatch
-      ManagedPolicyArns : ['arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole'],
-      Tags              : tags
-    } // Properties
-  }
- 
-  finalTemplate.Resources.RequestSignerLogGroup = {
-    Type       : 'AWS::Logs::LogGroup',
-    Properties : {
-      LogGroupClass   : 'STANDARD', // TODO: support option for INFREQUENT_ACCESS
-      LogGroupName    : requestSignerFunctionName,
-      RetentionInDays : 180, // TODO: support options,
-      Tags            : tags
-    }
-  }
- 
-  finalTemplate.Resources.SignRequestFunction = {
-    Type       : 'AWS::Lambda::Function',
-    DependsOn  : ['RequestSignerRole'],
-    Properties : {
-      FunctionName : requestSignerFunctionName,
-      Handler      : 'index.handler',
-      Role         : { 'Fn::GetAtt' : ['RequestSignerRole', 'Arn'] },
-      Runtime      : 'nodejs20.x',
-      MemorySize   : 128,
-      Timeout      : 5,
-      Code         : {
-        S3Bucket : lambdaFunctionsBucketName,
-        S3Key    : REQUEST_SIGNER_ZIP_NAME
-      },
-      LoggingConfig : {
-        ApplicationLogLevel : 'INFO', // support options
-        LogFormat           : 'JSON', // support options
-        LogGroup            : requestSignerFunctionName,
-        SystemLogLevel      : 'INFO' // support options
-      },
-      Tags : tags
-    } // Properties
-  }
- 
-  finalTemplate.Resources.SignRequestFunctionVersion = {
-    Type       : 'AWS::Lambda::Version',
-    DependsOn  : ['SignRequestFunction'],
-    Properties : {
-      FunctionName : { 'Fn::GetAtt' : ['SignRequestFunction', 'Arn'] }
-    }
-  }
- 
-  finalTemplate.Outputs.SignRequestFunction = {
-    Value : { Ref : 'SignRequestFunction' }
-  }
-}
- 
-export { setupRequestSigner }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html deleted file mode 100644 index 4f437835..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs.html +++ /dev/null @@ -1,361 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/stage-lambda-function-zip-files.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib stage-lambda-function-zip-files.mjs

-
- -
- 0% - Statements - 0/33 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/2 -
- - -
- 0% - Lines - 0/33 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { join as pathJoin } from 'node:path'
-import { createReadStream } from 'node:fs'
- 
-import { CreateBucketCommand, PutBucketTaggingCommand, PutObjectCommand, S3Client } from '@aws-sdk/client-s3'
- 
-import { CONTACT_EMAILER_ZIP_NAME, CONTACT_HANDLER_ZIP_NAME, REQUEST_SIGNER_ZIP_NAME } from './constants'
-import { convertDomainToBucketName } from '../../../shared/convert-domain-to-bucket-name'
-import { determineBucketName } from '../../../shared/determine-bucket-name'
-import { getSiteTag } from '../../../shared/get-site-tag'
-import { progressLogger } from '../../../shared/progress-logger'
-// jsdoc wants this, but it causes a circular dependency
-// import { SiteTemplate } from '../../../shared/site-template'
- 
-/* eslint-disable  jsdoc/no-undefined-types */ // See note above re. SiteTemplate
-/**
- * Stages the zipped Lambda function packages on a common S3 bucket.
- * @param {object} input - Destructured input argument.
- * @param {boolean} input.enableEmail - True if the site is to be built with email on contact form submission support.
- * @param {object} input.siteInfo - See {@link SiteTemplate} for details.
- * @returns {string} The Lambda function bucket name.
- */ /* eslint-enable  jsdoc/no-undefined-types */
-const stageLambdaFunctionZipFiles = async ({ credentials, enableEmail, pluginData, siteInfo }) => {
-  progressLogger.write('Staging Lambda function zip files...\n')
- 
-  let { lambdaFunctionsBucket } = pluginData
-  const { apexDomain, region } = siteInfo
- 
-  const s3Client = new S3Client({ credentials, region })
- 
-  Iif (lambdaFunctionsBucket === undefined) {
-    lambdaFunctionsBucket = convertDomainToBucketName(apexDomain) + '-lambda-functions'
-    lambdaFunctionsBucket =
-      await determineBucketName({
-        bucketName : lambdaFunctionsBucket,
-        credentials,
-        findName   : true,
-        s3Client,
-        siteInfo
-      })
- 
-    const createBucketCommand = new CreateBucketCommand({
-      ACL    : 'private',
-      Bucket : lambdaFunctionsBucket
-    })
-    await s3Client.send(createBucketCommand)
-  }
- 
-  const siteTag = getSiteTag(siteInfo)
-  const putBucketTaggingCommand = new PutBucketTaggingCommand({
-    Bucket  : lambdaFunctionsBucket,
-    Tagging : {
-      TagSet : [{ Key : siteTag, Value : '' }]
-    }
-  })
-  await s3Client.send(putBucketTaggingCommand)
- 
-  pluginData.lambdaFunctionsBucket = lambdaFunctionsBucket
- 
-  const putCommands = [
-    putZipFile({ bucketName : lambdaFunctionsBucket, fileName : CONTACT_HANDLER_ZIP_NAME, s3Client }),
-    putZipFile({ bucketName : lambdaFunctionsBucket, fileName : REQUEST_SIGNER_ZIP_NAME, s3Client })
-  ]
- 
-  Iif (enableEmail === true) {
-    putCommands.push(putZipFile({
-      bucketName : lambdaFunctionsBucket,
-      fileName   : CONTACT_EMAILER_ZIP_NAME,
-      s3Client
-    }))
-  }
- 
-  await Promise.all(putCommands)
- 
-  return lambdaFunctionsBucket
-}
- 
-const putZipFile = async ({ bucketName, fileName, s3Client }) => {
-  // when built, everything sits in './dist' together
-  const zipPath = pathJoin(__dirname, fileName)
-  const readStream = createReadStream(zipPath)
- 
-  const putObjectCommand = new PutObjectCommand({
-    Body        : readStream,
-    Bucket      : bucketName,
-    Key         : fileName,
-    ContentType : 'application/zip'
-  })
- 
-  await s3Client.send(putObjectCommand)
-}
- 
-export { stageLambdaFunctionZipFiles }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html b/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html deleted file mode 100644 index 924adefd..00000000 --- a/qa/coverage/lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs.html +++ /dev/null @@ -1,220 +0,0 @@ - - - - - - Code coverage report for lib/plugins/contact-handler/lib/update-cloud-front-distribution.mjs - - - - - - - - - -
-
-

All files / lib/plugins/contact-handler/lib update-cloud-front-distribution.mjs

-
- -
- 0% - Statements - 0/11 -
- - -
- 0% - Branches - 0/2 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/11 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
const updateCloudFrontDistribution = ({ pluginData, siteTemplate }) => {
-  const { finalTemplate } = siteTemplate
-  const contactHandlerPath = pluginData.settings.urlPath
- 
-  finalTemplate.Resources.SiteCloudFrontDistribution.DependsOn.push('ContactHandlerLambdaURL')
- 
-  const cfOrigins = finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.Origins
-  cfOrigins.push({
-    Id         : 'ContactHandlerLambdaOrigin',
-    DomainName : { // strip the https://
-      'Fn::Select' : [2, { 'Fn::Split' : ['/', { 'Fn::GetAtt' : ['ContactHandlerLambdaURL', 'FunctionUrl'] }] }]
-    },
-    CustomOriginConfig : {
-      HTTPSPort            : 443,
-      OriginProtocolPolicy : 'https-only'
-    }
-  })
- 
-  const cfCacheBehaviors =
-    finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.CacheBehaviors || []
-  cfCacheBehaviors.push({
-    AllowedMethods             : ['DELETE', 'GET', 'HEAD', 'OPTIONS', 'PATCH', 'POST', 'PUT'],
-    CachePolicyId              : '4135ea2d-6df8-44a3-9df3-4b5a84be39ad', // caching disabled managed policy
-    PathPattern                : contactHandlerPath,
-    TargetOriginId             : 'ContactHandlerLambdaOrigin',
-    ViewerProtocolPolicy       : 'https-only',
-    LambdaFunctionAssociations : [
-      {
-        EventType         : 'origin-request',
-        IncludeBody       : true,
-        LambdaFunctionARN : {
-          'Fn::Join' : [':', [
-            { 'Fn::GetAtt' : ['SignRequestFunction', 'Arn'] },
-            { 'Fn::GetAtt' : ['SignRequestFunctionVersion', 'Version'] }]
-          ]
-        }
-      }
-    ]
-  })
- 
-  finalTemplate.Resources.SiteCloudFrontDistribution.Properties.DistributionConfig.CacheBehaviors = cfCacheBehaviors
-  finalTemplate.Resources.SiteCloudFrontDistribution.DependsOn.push('SignRequestFunctionVersion')
-}
- 
-export { updateCloudFrontDistribution }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/plugins/index.html b/qa/coverage/lib/plugins/index.html deleted file mode 100644 index b61ca4c4..00000000 --- a/qa/coverage/lib/plugins/index.html +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - Code coverage report for lib/plugins - - - - - - - - - -
-
-

All files lib/plugins

-
- -
- 0% - Statements - 0/20 -
- - -
- 0% - Branches - 0/1 -
- - -
- 0% - Functions - 0/7 -
- - -
- 0% - Lines - 0/20 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
access-logs.mjs -
-
0%0/6100%0/00%0/30%0/6
cloudfront-logs.mjs -
-
0%0/140%0/10%0/40%0/14
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html b/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html deleted file mode 100644 index 0636b342..00000000 --- a/qa/coverage/lib/shared/convert-domain-to-bucket-name.js.html +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - Code coverage report for lib/shared/convert-domain-to-bucket-name.js - - - - - - - - - -
-
-

All files / lib/shared convert-domain-to-bucket-name.js

-
- -
- 0% - Statements - 0/3 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/1 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4  -  -  - 
const convertDomainToBucketName = (domain) => domain.replaceAll(/\./g, '-').replaceAll(/[^a-z0-9-]/g, 'x')
- 
-export { convertDomainToBucketName }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/determine-bucket-name.mjs.html b/qa/coverage/lib/shared/determine-bucket-name.mjs.html deleted file mode 100644 index e007b79d..00000000 --- a/qa/coverage/lib/shared/determine-bucket-name.mjs.html +++ /dev/null @@ -1,241 +0,0 @@ - - - - - - Code coverage report for lib/shared/determine-bucket-name.mjs - - - - - - - - - -
-
-

All files / lib/shared determine-bucket-name.mjs

-
- -
- 0% - Statements - 0/34 -
- - -
- 0% - Branches - 0/13 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/34 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { v4 as uuidv4 } from 'uuid'
- 
-import { S3Client, HeadBucketCommand } from '@aws-sdk/client-s3'
- 
-import { convertDomainToBucketName } from './convert-domain-to-bucket-name'
-import { getAccountID } from './get-account-id'
-import { progressLogger } from './progress-logger'
- 
-const determineBucketName = async (args) => {
-  const { apexDomain, credentials, findName = false, siteInfo } = args
-  let { bucketName, s3Client } = args
- 
-  Iif (bucketName === undefined) {
-    bucketName = siteInfo.bucketName || convertDomainToBucketName(apexDomain)
-  }
- 
-  const { accountID } = siteInfo
-  Iif (accountID === undefined) {
-    const accountID = await getAccountID({ credentials })
-    siteInfo.accountID = accountID
-  }
- 
-  s3Client = s3Client || new S3Client({ credentials })
- 
-  while (true) {
-    progressLogger.write(`Checking bucket '${bucketName}' is free... `)
- 
-    const input = { Bucket : bucketName, ExpectedBucketOwner : accountID }
- 
-    const command = new HeadBucketCommand(input)
-    try {
-      await s3Client.send(command)
-      Iif (findName !== true) {
-        throw new Error(`Account already owns bucket '${bucketName}'; delete or specify alternate bucket name.`)
-      }
-    } catch (e) {
-      if (e.name === 'NotFound') {
-        progressLogger.write('FREE\n')
-        return bucketName
-      } else Iif (findName !== true || e.name === 'CredentialsProviderError') {
-        progressLogger.write('\n')
-        throw e
-      }
-    }
-    progressLogger.write('NOT free\n')
-    const bucketSalt = uuidv4().slice(0, 8)
-    bucketName = bucketName.replace(/-[A-F0-9]{8}$/i, '')
-    bucketName += '-' + bucketSalt
-  }
-}
- 
-export { determineBucketName }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/determine-oac-name.mjs.html b/qa/coverage/lib/shared/determine-oac-name.mjs.html deleted file mode 100644 index 8792187f..00000000 --- a/qa/coverage/lib/shared/determine-oac-name.mjs.html +++ /dev/null @@ -1,235 +0,0 @@ - - - - - - Code coverage report for lib/shared/determine-oac-name.mjs - - - - - - - - - -
-
-

All files / lib/shared determine-oac-name.mjs

-
- -
- 0% - Statements - 0/29 -
- - -
- 0% - Branches - 0/14 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/28 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { v4 as uuidv4 } from 'uuid'
- 
-import { CloudFrontClient, ListOriginAccessControlsCommand } from '@aws-sdk/client-cloudfront'
- 
-import { progressLogger } from './progress-logger'
- 
-const determineOACName = async ({ baseName, credentials, siteInfo }) => {
-  const { region } = siteInfo
-  let currentName = baseName
- 
-  // there is on way to get an OAC based on teh name alone, you need the ID (ARN?) which we don't have. So, we have to
-  // list the OACs and search for one with the given name
-  const allOACNames = await getAllOACNames({ credentials, region })
- 
-  while (true) {
-    progressLogger?.write(`Checking if OAC name '${currentName}' is free... `)
-    if (allOACNames.includes(currentName)) {
-      progressLogger?.write('NOT free\n')
-      const nameSalt = uuidv4().slice(0, 8)
-      currentName = currentName.replace(/-[A-F0-9]{8}$/i, '')
-      currentName += '-' + nameSalt
-    } else {
-      progressLogger?.write('FREE\n')
-      return currentName
-    }
-  }
-}
- 
-const getAllOACNames = async ({ credentials, region }) => {
-  const cloudfrontClient = new CloudFrontClient({ credentials, region })
-  let currentMarker
-  const result = []
-  while (true) {
-    const listOACCommand = new ListOriginAccessControlsCommand({
-      Marker : currentMarker
-    })
- 
-    const oacListResponse = await cloudfrontClient.send(listOACCommand)
-    const items = oacListResponse.OriginAccessControlList.Items || []
- 
-    result.push(...items.map(({ Name : name }) => name))
- 
-    currentMarker = oacListResponse.OriginAccessControlList.NextMarker
-    Iif (currentMarker === undefined) {
-      return result
-    }
-  }
-}
- 
-export { determineOACName }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/find-bucket-like.mjs.html b/qa/coverage/lib/shared/find-bucket-like.mjs.html deleted file mode 100644 index 765e5452..00000000 --- a/qa/coverage/lib/shared/find-bucket-like.mjs.html +++ /dev/null @@ -1,166 +0,0 @@ - - - - - - Code coverage report for lib/shared/find-bucket-like.mjs - - - - - - - - - -
-
-

All files / lib/shared find-bucket-like.mjs

-
- -
- 0% - Statements - 0/19 -
- - -
- 0% - Branches - 0/16 -
- - -
- 0% - Functions - 0/3 -
- - -
- 0% - Lines - 0/18 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { ListBucketsCommand, S3Client } from '@aws-sdk/client-s3'
- 
-import { progressLogger } from './progress-logger'
- 
-const findBucketLike = async ({ credentials, description, partialName }) => {
-  progressLogger?.write(`Attempting to find ${description} bucket... `)
-  const s3Client = new S3Client({ credentials })
-  const listBucketsCommand = new ListBucketsCommand({})
-  const { Buckets : buckets } = await s3Client.send(listBucketsCommand)
- 
-  const possibleMatches = buckets.filter(({ Name : name }) => name.startsWith(partialName))
- 
-  if (possibleMatches.length === 0) {
-    progressLogger?.write('NONE found\n')
-  } else if (possibleMatches.length === 1) {
-    const commonLogsBucket = possibleMatches[0].Name
-    progressLogger?.write('found: ' + commonLogsBucket + '\n')
-    return commonLogsBucket
-  } else { // possible matches greater than one, but commonLogsBucket not set
-    // TODO: tailor the message for CLI or library...
-    progressLogger?.write('found multiple\n')
-    throw new Error("Found multiple possible 'common logs' buckets; specify which to use with '--common-logs-bucket': " +
-        possibleMatches.map(({ Name : name }) => name).join(', '))
-  }
-}
- 
-export { findBucketLike }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/get-account-id.mjs.html b/qa/coverage/lib/shared/get-account-id.mjs.html deleted file mode 100644 index 8b53cf26..00000000 --- a/qa/coverage/lib/shared/get-account-id.mjs.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - Code coverage report for lib/shared/get-account-id.mjs - - - - - - - - - -
-
-

All files / lib/shared get-account-id.mjs

-
- -
- 0% - Statements - 0/8 -
- - -
- 0% - Branches - 0/3 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/8 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14  -  -  -  -  -  -  -  -  -  -  -  -  - 
import { STSClient, GetCallerIdentityCommand } from '@aws-sdk/client-sts'
- 
-import { progressLogger } from './progress-logger'
- 
-const getAccountID = async ({ credentials }) => {
-  progressLogger?.write('Getting effective account ID...\n')
-  const response = await new STSClient({ credentials }).send(new GetCallerIdentityCommand({}))
-  const accountID = response.Account
- 
-  return accountID
-}
- 
-export { getAccountID }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/get-site-tag.mjs.html b/qa/coverage/lib/shared/get-site-tag.mjs.html deleted file mode 100644 index 55077d11..00000000 --- a/qa/coverage/lib/shared/get-site-tag.mjs.html +++ /dev/null @@ -1,100 +0,0 @@ - - - - - - Code coverage report for lib/shared/get-site-tag.mjs - - - - - - - - - -
-
-

All files / lib/shared get-site-tag.mjs

-
- -
- 0% - Statements - 0/3 -
- - -
- 100% - Branches - 0/0 -
- - -
- 0% - Functions - 0/1 -
- - -
- 0% - Lines - 0/3 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6  -  -  -  -  - 
const getSiteTag = (siteInfo) => {
-  return 'site:' + siteInfo.apexDomain
-}
- 
-export { getSiteTag }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/index.html b/qa/coverage/lib/shared/index.html deleted file mode 100644 index ea09060e..00000000 --- a/qa/coverage/lib/shared/index.html +++ /dev/null @@ -1,221 +0,0 @@ - - - - - - Code coverage report for lib/shared - - - - - - - - - -
-
-

All files lib/shared

-
- -
- 3.57% - Statements - 6/168 -
- - -
- 0% - Branches - 0/74 -
- - -
- 5% - Functions - 1/20 -
- - -
- 3.68% - Lines - 6/163 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
FileStatementsBranchesFunctionsLines
convert-domain-to-bucket-name.js -
-
0%0/3100%0/00%0/10%0/1
determine-bucket-name.mjs -
-
0%0/340%0/130%0/10%0/34
determine-oac-name.mjs -
-
0%0/290%0/140%0/30%0/28
find-bucket-like.mjs -
-
0%0/190%0/160%0/30%0/18
get-account-id.mjs -
-
0%0/80%0/30%0/10%0/8
get-site-tag.mjs -
-
0%0/3100%0/00%0/10%0/3
progress-logger.mjs -
-
66.66%6/90%0/150%1/266.66%6/9
site-template.mjs -
-
0%0/630%0/270%0/80%0/62
-
-
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/progress-logger.mjs.html b/qa/coverage/lib/shared/progress-logger.mjs.html deleted file mode 100644 index 5fc613a2..00000000 --- a/qa/coverage/lib/shared/progress-logger.mjs.html +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - Code coverage report for lib/shared/progress-logger.mjs - - - - - - - - - -
-
-

All files / lib/shared progress-logger.mjs

-
- -
- 66.66% - Statements - 6/9 -
- - -
- 0% - Branches - 0/1 -
- - -
- 50% - Functions - 1/2 -
- - -
- 66.66% - Lines - 6/9 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -192x -  -2x -  -2x -1x -  -1x -  -  -  -  -  -  -  -2x -  -  - 
import { getPrinter } from 'magic-print'
- 
-const progressLogger = {}
- 
-const configureLogger = (options) => {
-  const print = getPrinter(options)
- 
-  progressLogger.write = (...chunk) => {
-    // do options here so it'll react to changes
-    const { quiet } = options
- 
-    Iif (quiet !== true) {
-      print(...chunk)
-    }
-  }
-}
- 
-export { configureLogger, progressLogger }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/lib/shared/site-template.mjs.html b/qa/coverage/lib/shared/site-template.mjs.html deleted file mode 100644 index 115dd280..00000000 --- a/qa/coverage/lib/shared/site-template.mjs.html +++ /dev/null @@ -1,892 +0,0 @@ - - - - - - Code coverage report for lib/shared/site-template.mjs - - - - - - - - - -
-
-

All files / lib/shared site-template.mjs

-
- -
- 0% - Statements - 0/63 -
- - -
- 0% - Branches - 0/27 -
- - -
- 0% - Functions - 0/8 -
- - -
- 0% - Lines - 0/62 -
- - -
-

- Press n or j to go to the next uncovered block, b, p or k for the previous block. -

- -
-
-

-
1 -2 -3 -4 -5 -6 -7 -8 -9 -10 -11 -12 -13 -14 -15 -16 -17 -18 -19 -20 -21 -22 -23 -24 -25 -26 -27 -28 -29 -30 -31 -32 -33 -34 -35 -36 -37 -38 -39 -40 -41 -42 -43 -44 -45 -46 -47 -48 -49 -50 -51 -52 -53 -54 -55 -56 -57 -58 -59 -60 -61 -62 -63 -64 -65 -66 -67 -68 -69 -70 -71 -72 -73 -74 -75 -76 -77 -78 -79 -80 -81 -82 -83 -84 -85 -86 -87 -88 -89 -90 -91 -92 -93 -94 -95 -96 -97 -98 -99 -100 -101 -102 -103 -104 -105 -106 -107 -108 -109 -110 -111 -112 -113 -114 -115 -116 -117 -118 -119 -120 -121 -122 -123 -124 -125 -126 -127 -128 -129 -130 -131 -132 -133 -134 -135 -136 -137 -138 -139 -140 -141 -142 -143 -144 -145 -146 -147 -148 -149 -150 -151 -152 -153 -154 -155 -156 -157 -158 -159 -160 -161 -162 -163 -164 -165 -166 -167 -168 -169 -170 -171 -172 -173 -174 -175 -176 -177 -178 -179 -180 -181 -182 -183 -184 -185 -186 -187 -188 -189 -190 -191 -192 -193 -194 -195 -196 -197 -198 -199 -200 -201 -202 -203 -204 -205 -206 -207 -208 -209 -210 -211 -212 -213 -214 -215 -216 -217 -218 -219 -220 -221 -222 -223 -224 -225 -226 -227 -228 -229 -230 -231 -232 -233 -234 -235 -236 -237 -238 -239 -240 -241 -242 -243 -244 -245 -246 -247 -248 -249 -250 -251 -252 -253 -254 -255 -256 -257 -258 -259 -260 -261 -262 -263 -264 -265 -266 -267 -268 -269 -270  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  - 
import yaml from 'js-yaml'
- 
-import { emptyBucket } from 's3-empty-bucket'
- 
-import { S3Client } from '@aws-sdk/client-s3'
- 
-import { determineBucketName } from './determine-bucket-name'
-import { determineOACName } from './determine-oac-name'
-import { getSiteTag } from './get-site-tag'
-import * as plugins from '../plugins'
-import { progressLogger } from './progress-logger'I
- 
-/**
- * Class encapsulating site stack configuration. Any enabled plugins are loaded and processed by this class.
- * @class
- */
-const SiteTemplate = class {
-  /* eslint-disable jsdoc/check-param-names */ // eslint doesn't believe our 2nd level destructure documentation
-  /**
-   * Creates a new {@link SiteTemplate}.
-   * @param {object} input - Destructured input argument.
-   * @param {object} input.credentials - credentials for AWS SDK clients.
-   * @param {object} input.siteInfo - Collection of site related data elements.
-   * @param {string} input.siteInfo.apexDomain - the sites apex domain
-   * @param {string} input.siteInfo.sourcePath - the path to the site's static source files, may be absolute or CWD
-   *   relative
-   * @param {string} input.siteInfo.region - the region of the site
-   * @param {string} input.siteInfo.certificateArn {string} - the AWS ARN for the site's SSL certificate
-   * @param {string} input.siteInfo.accountID - the ID of the account under which the stack resides (not ARN)
-   * @param {string} input.siteInfo.bucketName - the name of the bucket where the site's static files are stored
-   * @param {string} input.siteInfo.stackName - the name of the stack
-   * @param {string} input.siteInfo.stackArn - the stack's ARN
-   * @param {string} input.siteInfo.cloudFrontDistributionID - the stack's CloudfFront ID (not ARN)
-   * @param {object} input.siteInfo.plugins - collection of plugin settings; settings are grouped/keyed by the
-   *   plugin's name; setting values are dependent on the plugin
-   * @param credentials.siteInfo
-   */ /* eslint-enable jsdoc/check-param-names */
-  constructor ({ credentials, siteInfo }) {
-    this.siteInfo = siteInfo
-    this.credentials = credentials
- 
-    this.resourceTypes = { 'CloudFormation::Distribution' : true, 'S3::Bucket' : true }
-    this.finalTemplate = this.baseTemplate
-  }
- 
-  async initializeTemplate ({ update } = {}) {
-    const { siteInfo } = this
-    const { accountID, apexDomain, bucketName, certificateArn, region } = siteInfo
-    const siteTag = getSiteTag(siteInfo)
- 
-    const oacName = update === true
-      ? siteInfo.oacName
-      : await determineOACName({
-        baseName    : `${bucketName}-OAC`,
-        credentials : this.credentials,
-        siteInfo    : this.siteInfo
-      })
-    progressLogger?.write(`Using OAC name: ${oacName}\n`)
-    this.siteInfo.oacName = oacName
- 
-    this.finalTemplate = {
-      Resources : {
-        SiteS3Bucket : {
-          Type       : 'AWS::S3::Bucket',
-          Properties : {
-            AccessControl : 'Private',
-            BucketName    : bucketName,
-            Tags          : [{ Key : siteTag, Value : '' }]
-          }
-        },
-        SiteCloudFrontOriginAccessControl : {
-          Type       : 'AWS::CloudFront::OriginAccessControl',
-          Properties : {
-            OriginAccessControlConfig : {
-              Description                   : 'Origin Access Control (OAC) allowing CloudFront Distribution to access site S3 bucket.',
-              Name                          : oacName,
-              OriginAccessControlOriginType : 's3',
-              SigningBehavior               : 'always',
-              SigningProtocol               : 'sigv4'
-            }
-          }
-        },
-        SiteCloudFrontDistribution : {
-          Type       : 'AWS::CloudFront::Distribution',
-          DependsOn  : ['SiteS3Bucket'],
-          Properties : {
-            DistributionConfig : {
-              Origins : [
-                {
-                  DomainName     : `${bucketName}.s3.${region}.amazonaws.com`,
-                  Id             : 'static-hosting',
-                  S3OriginConfig : {
-                    OriginAccessIdentity : ''
-                  },
-                  OriginAccessControlId : { 'Fn::GetAtt' : ['SiteCloudFrontOriginAccessControl', 'Id'] }
-                }
-              ],
-              Enabled              : true,
-              DefaultRootObject    : 'index.html',
-              CustomErrorResponses : [
-                { ErrorCode : 403, ResponseCode : 200, ResponsePagePath : '/index.html' },
-                { ErrorCode : 404, ResponseCode : 200, ResponsePagePath : '/index.html' }
-              ],
-              HttpVersion       : 'http2',
-              Aliases           : [apexDomain, `www.${apexDomain}`],
-              ViewerCertificate : {
-                AcmCertificateArn      : certificateArn,
-                MinimumProtocolVersion : 'TLSv1.2_2021',
-                SslSupportMethod       : 'sni-only'
-              },
-              DefaultCacheBehavior : {
-                AllowedMethods       : ['GET', 'HEAD'],
-                CachePolicyId        : '658327ea-f89d-4fab-a63d-7e88639e58f6', // CachingOptimized cache policy ID
-                Compress             : true,
-                TargetOriginId       : 'static-hosting',
-                ViewerProtocolPolicy : 'redirect-to-https'
-              }
-            }, // DistributionConfig
-            Tags : [{ Key : siteTag, Value : '' }]
-          } // Properties
-        }, // SiteCloudFrontDistribution
-        SiteBucketPolicy : {
-          Type       : 'AWS::S3::BucketPolicy',
-          DependsOn  : ['SiteS3Bucket', 'SiteCloudFrontDistribution'],
-          Properties : {
-            Bucket         : bucketName,
-            PolicyDocument : {
-              Version   : '2012-10-17',
-              Statement : [
-                {
-                  Effect    : 'Allow',
-                  Principal : {
-                    Service : 'cloudfront.amazonaws.com'
-                  },
-                  Action    : 's3:GetObject',
-                  Resource  : `arn:aws:s3:::${bucketName}/*`,
-                  Condition : {
-                    StringEquals : {
-                      'AWS:SourceArn' : {
-                        'Fn::Join' : ['', [`arn:aws:cloudfront::${accountID}:distribution/`, { 'Fn::GetAtt' : ['SiteCloudFrontDistribution', 'Id'] }]]
-                      }
-                    }
-                  }
-                }
-              ]
-            }
-          }
-        }
-      }, // Resources
-      Outputs : {
-        SiteS3Bucket : {
-          Value : { Ref : 'SiteS3Bucket' }
-        },
-        SiteCloudFrontOriginAccessControl : {
-          Value : { Ref : 'SiteCloudFrontOriginAccessControl' }
-        },
-        SiteCloudFrontDistribution : {
-          Value : { Ref : 'SiteCloudFrontDistribution' }
-        },
-        OriginAccessControl : {
-          Value : { Ref : 'SiteCloudFrontOriginAccessControl' }
-        }
-      }
-    }
-  }
- 
-  async destroyCommonLogsBucket () {
-    const { siteInfo } = this
-    const { commonLogsBucket } = siteInfo
- 
-    if (commonLogsBucket !== undefined) {
-      progressLogger.write('Deleting common logs bucket...\n')
-      const s3Client = new S3Client({ credentials : this.credentials })
-      emptyBucket({
-        bucketName : commonLogsBucket,
-        doDelete   : true,
-        s3Client,
-        verbose    : progressLogger !== undefined
-      })
-      delete siteInfo.commonLogsBucket
-    } else {
-      progressLogger?.write('Looks like the shared logging bucket has already been deleted; skipping.\n')
-    }
-  }
- 
-  async enableCommonLogsBucket () {
-    const { bucketName } = this.siteInfo // used to create a name for the shared logging bucket
-    let { commonLogsBucket = bucketName + '-common-logs' } = this.siteInfo
-    const siteTag = getSiteTag(this.siteInfo)
- 
-    Iif (commonLogsBucket === undefined) {
-      commonLogsBucket = await determineBucketName({
-        bucketName  : commonLogsBucket,
-        credentials : this.credentials,
-        findName    : true,
-        siteInfo    : this.siteInfo
-      })
-    }
-    this.siteInfo.commonLogsBucket = commonLogsBucket
- 
-    this.finalTemplate.Resources.commonLogsBucket = {
-      Type       : 'AWS::S3::Bucket',
-      Properties : {
-        AccessControl     : 'Private',
-        BucketName        : commonLogsBucket,
-        OwnershipControls : { // this enables ACLs, as required by CloudFront standard logging
-          Rules : [{ ObjectOwnership : 'BucketOwnerPreferred' }]
-        },
-        Tags : [{ Key : siteTag, Value : '' }]
-      }
-    }
- 
-    return commonLogsBucket
-  }
- 
-  async destroyPlugins () {
-    const { siteInfo } = this
-    const { apexDomain } = siteInfo
-    const pluginsData = siteInfo.plugins || {}
- 
-    for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
-      const plugin = plugins[pluginKey]
-      Iif (plugin === undefined) {
-        throw new Error(`Unknown plugin found in '${apexDomain}' plugin settings.`)
-      }
- 
-      const { preStackDestroyHandler } = plugin
-      Iif (preStackDestroyHandler !== undefined) {
-        await preStackDestroyHandler({ siteTemplate : this, pluginData })
-      }
-    }
-  }
- 
-  async loadPlugins ({ update } = {}) {
-    const { siteInfo } = this
-    const { apexDomain } = siteInfo
-    const pluginsData = siteInfo.plugins || {}
- 
-    const pluginConfigs = []
-    for (const [pluginKey, pluginData] of Object.entries(pluginsData)) {
-      const plugin = plugins[pluginKey]
-      Iif (plugin === undefined) {
-        throw new Error(`Unknown plugin found in '${apexDomain}' plugin settings.`)
-      }
- 
-      pluginConfigs.push(plugin.stackConfig({ siteTemplate : this, pluginData, update }))
-    }
- 
-    await Promise.all(pluginConfigs)
-  }
- 
-  render () {
-    const { apexDomain } = this.siteInfo
-    const resourceTypes = Object.keys(this.resourceTypes).sort()
- 
-    const outputTemplate = Object.assign({
-      AWSTemplateFormatVersion : '2010-09-09',
-      Description              : `${apexDomain} site built with ${resourceTypes.slice(0, -1).join(', ')} and ${resourceTypes[resourceTypes.length - 1]}.`
-    },
-    this.finalTemplate
-    )
- 
-    // turn off multi-line blocks and (must) turn off refs to prevent aliasing of repeated tags objects
-    const output = yaml.dump(outputTemplate, { lineWidth : 0, noRefs : true })
-    return output
-  }
-}
- 
-export { SiteTemplate }
- 
- -
-
- - - - - - - - \ No newline at end of file diff --git a/qa/coverage/prettify.css b/qa/coverage/prettify.css deleted file mode 100644 index b317a7cd..00000000 --- a/qa/coverage/prettify.css +++ /dev/null @@ -1 +0,0 @@ -.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee} diff --git a/qa/coverage/prettify.js b/qa/coverage/prettify.js deleted file mode 100644 index b3225238..00000000 --- a/qa/coverage/prettify.js +++ /dev/null @@ -1,2 +0,0 @@ -/* eslint-disable */ -window.PR_SHOULD_USE_CONTINUATION=true;(function(){var h=["break,continue,do,else,for,if,return,while"];var u=[h,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"];var p=[u,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"];var l=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"];var x=[p,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"];var R=[x,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"];var r="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes";var w=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"];var s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END";var I=[h,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"];var f=[h,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"];var H=[h,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"];var A=[l,R,w,s+I,f,H];var e=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/;var C="str";var z="kwd";var j="com";var O="typ";var G="lit";var L="pun";var F="pln";var m="tag";var E="dec";var J="src";var P="atn";var n="atv";var N="nocode";var M="(?:^^\\.?|[+-]|\\!|\\!=|\\!==|\\#|\\%|\\%=|&|&&|&&=|&=|\\(|\\*|\\*=|\\+=|\\,|\\-=|\\->|\\/|\\/=|:|::|\\;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\@|\\[|\\^|\\^=|\\^\\^|\\^\\^=|\\{|\\||\\|=|\\|\\||\\|\\|=|\\~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function k(Z){var ad=0;var S=false;var ac=false;for(var V=0,U=Z.length;V122)){if(!(al<65||ag>90)){af.push([Math.max(65,ag)|32,Math.min(al,90)|32])}if(!(al<97||ag>122)){af.push([Math.max(97,ag)&~32,Math.min(al,122)&~32])}}}}af.sort(function(av,au){return(av[0]-au[0])||(au[1]-av[1])});var ai=[];var ap=[NaN,NaN];for(var ar=0;arat[0]){if(at[1]+1>at[0]){an.push("-")}an.push(T(at[1]))}}an.push("]");return an.join("")}function W(al){var aj=al.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g"));var ah=aj.length;var an=[];for(var ak=0,am=0;ak=2&&ai==="["){aj[ak]=X(ag)}else{if(ai!=="\\"){aj[ak]=ag.replace(/[a-zA-Z]/g,function(ao){var ap=ao.charCodeAt(0);return"["+String.fromCharCode(ap&~32,ap|32)+"]"})}}}}return aj.join("")}var aa=[];for(var V=0,U=Z.length;V=0;){S[ac.charAt(ae)]=Y}}var af=Y[1];var aa=""+af;if(!ag.hasOwnProperty(aa)){ah.push(af);ag[aa]=null}}ah.push(/[\0-\uffff]/);V=k(ah)})();var X=T.length;var W=function(ah){var Z=ah.sourceCode,Y=ah.basePos;var ad=[Y,F];var af=0;var an=Z.match(V)||[];var aj={};for(var ae=0,aq=an.length;ae=5&&"lang-"===ap.substring(0,5);if(am&&!(ai&&typeof ai[1]==="string")){am=false;ap=J}if(!am){aj[ag]=ap}}var ab=af;af+=ag.length;if(!am){ad.push(Y+ab,ap)}else{var al=ai[1];var ak=ag.indexOf(al);var ac=ak+al.length;if(ai[2]){ac=ag.length-ai[2].length;ak=ac-al.length}var ar=ap.substring(5);B(Y+ab,ag.substring(0,ak),W,ad);B(Y+ab+ak,al,q(ar,al),ad);B(Y+ab+ac,ag.substring(ac),W,ad)}}ah.decorations=ad};return W}function i(T){var W=[],S=[];if(T.tripleQuotedStrings){W.push([C,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""])}else{if(T.multiLineStrings){W.push([C,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"])}else{W.push([C,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"])}}if(T.verbatimStrings){S.push([C,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null])}var Y=T.hashComments;if(Y){if(T.cStyleComments){if(Y>1){W.push([j,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"])}else{W.push([j,/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"])}S.push([C,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,null])}else{W.push([j,/^#[^\r\n]*/,null,"#"])}}if(T.cStyleComments){S.push([j,/^\/\/[^\r\n]*/,null]);S.push([j,/^\/\*[\s\S]*?(?:\*\/|$)/,null])}if(T.regexLiterals){var X=("/(?=[^/*])(?:[^/\\x5B\\x5C]|\\x5C[\\s\\S]|\\x5B(?:[^\\x5C\\x5D]|\\x5C[\\s\\S])*(?:\\x5D|$))+/");S.push(["lang-regex",new RegExp("^"+M+"("+X+")")])}var V=T.types;if(V){S.push([O,V])}var U=(""+T.keywords).replace(/^ | $/g,"");if(U.length){S.push([z,new RegExp("^(?:"+U.replace(/[\s,]+/g,"|")+")\\b"),null])}W.push([F,/^\s+/,null," \r\n\t\xA0"]);S.push([G,/^@[a-z_$][a-z_$@0-9]*/i,null],[O,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[F,/^[a-z_$][a-z_$@0-9]*/i,null],[G,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[F,/^\\[\s\S]?/,null],[L,/^.[^\s\w\.$@\'\"\`\/\#\\]*/,null]);return g(W,S)}var K=i({keywords:A,hashComments:true,cStyleComments:true,multiLineStrings:true,regexLiterals:true});function Q(V,ag){var U=/(?:^|\s)nocode(?:\s|$)/;var ab=/\r\n?|\n/;var ac=V.ownerDocument;var S;if(V.currentStyle){S=V.currentStyle.whiteSpace}else{if(window.getComputedStyle){S=ac.defaultView.getComputedStyle(V,null).getPropertyValue("white-space")}}var Z=S&&"pre"===S.substring(0,3);var af=ac.createElement("LI");while(V.firstChild){af.appendChild(V.firstChild)}var W=[af];function ae(al){switch(al.nodeType){case 1:if(U.test(al.className)){break}if("BR"===al.nodeName){ad(al);if(al.parentNode){al.parentNode.removeChild(al)}}else{for(var an=al.firstChild;an;an=an.nextSibling){ae(an)}}break;case 3:case 4:if(Z){var am=al.nodeValue;var aj=am.match(ab);if(aj){var ai=am.substring(0,aj.index);al.nodeValue=ai;var ah=am.substring(aj.index+aj[0].length);if(ah){var ak=al.parentNode;ak.insertBefore(ac.createTextNode(ah),al.nextSibling)}ad(al);if(!ai){al.parentNode.removeChild(al)}}}break}}function ad(ak){while(!ak.nextSibling){ak=ak.parentNode;if(!ak){return}}function ai(al,ar){var aq=ar?al.cloneNode(false):al;var ao=al.parentNode;if(ao){var ap=ai(ao,1);var an=al.nextSibling;ap.appendChild(aq);for(var am=an;am;am=an){an=am.nextSibling;ap.appendChild(am)}}return aq}var ah=ai(ak.nextSibling,0);for(var aj;(aj=ah.parentNode)&&aj.nodeType===1;){ah=aj}W.push(ah)}for(var Y=0;Y=S){ah+=2}if(V>=ap){Z+=2}}}var t={};function c(U,V){for(var S=V.length;--S>=0;){var T=V[S];if(!t.hasOwnProperty(T)){t[T]=U}else{if(window.console){console.warn("cannot override language handler %s",T)}}}}function q(T,S){if(!(T&&t.hasOwnProperty(T))){T=/^\s*]*(?:>|$)/],[j,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[L,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);c(g([[F,/^[\s]+/,null," \t\r\n"],[n,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[[m,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[P,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[L,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]);c(g([],[[n,/^[\s\S]+/]]),["uq.val"]);c(i({keywords:l,hashComments:true,cStyleComments:true,types:e}),["c","cc","cpp","cxx","cyc","m"]);c(i({keywords:"null,true,false"}),["json"]);c(i({keywords:R,hashComments:true,cStyleComments:true,verbatimStrings:true,types:e}),["cs"]);c(i({keywords:x,cStyleComments:true}),["java"]);c(i({keywords:H,hashComments:true,multiLineStrings:true}),["bsh","csh","sh"]);c(i({keywords:I,hashComments:true,multiLineStrings:true,tripleQuotedStrings:true}),["cv","py"]);c(i({keywords:s,hashComments:true,multiLineStrings:true,regexLiterals:true}),["perl","pl","pm"]);c(i({keywords:f,hashComments:true,multiLineStrings:true,regexLiterals:true}),["rb"]);c(i({keywords:w,cStyleComments:true,regexLiterals:true}),["js"]);c(i({keywords:r,hashComments:3,cStyleComments:true,multilineStrings:true,tripleQuotedStrings:true,regexLiterals:true}),["coffee"]);c(g([],[[C,/^[\s\S]+/]]),["regex"]);function d(V){var U=V.langExtension;try{var S=a(V.sourceNode);var T=S.sourceCode;V.sourceCode=T;V.spans=S.spans;V.basePos=0;q(U,T)(V);D(V)}catch(W){if("console" in window){console.log(W&&W.stack?W.stack:W)}}}function y(W,V,U){var S=document.createElement("PRE");S.innerHTML=W;if(U){Q(S,U)}var T={langExtension:V,numberLines:U,sourceNode:S};d(T);return S.innerHTML}function b(ad){function Y(af){return document.getElementsByTagName(af)}var ac=[Y("pre"),Y("code"),Y("xmp")];var T=[];for(var aa=0;aa=0){var ah=ai.match(ab);var am;if(!ah&&(am=o(aj))&&"CODE"===am.tagName){ah=am.className.match(ab)}if(ah){ah=ah[1]}var al=false;for(var ak=aj.parentNode;ak;ak=ak.parentNode){if((ak.tagName==="pre"||ak.tagName==="code"||ak.tagName==="xmp")&&ak.className&&ak.className.indexOf("prettyprint")>=0){al=true;break}}if(!al){var af=aj.className.match(/\blinenums\b(?::(\d+))?/);af=af?af[1]&&af[1].length?+af[1]:true:false;if(af){Q(aj,af)}S={langExtension:ah,sourceNode:aj,numberLines:af};d(S)}}}if(X]*(?:>|$)/],[PR.PR_COMMENT,/^<\!--[\s\S]*?(?:-\->|$)/],[PR.PR_PUNCTUATION,/^(?:<[%?]|[%?]>)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-handlebars",/^]*type\s*=\s*['"]?text\/x-handlebars-template['"]?\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i],[PR.PR_DECLARATION,/^{{[#^>/]?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{&?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{{>?\s*[\w.][^}]*}}}/],[PR.PR_COMMENT,/^{{![^}]*}}/]]),["handlebars","hbs"]);PR.registerLangHandler(PR.createSimpleLexer([[PR.PR_PLAIN,/^[ \t\r\n\f]+/,null," \t\r\n\f"]],[[PR.PR_STRING,/^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/,null],[PR.PR_STRING,/^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/,null],["lang-css-str",/^url\(([^\)\"\']*)\)/i],[PR.PR_KEYWORD,/^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],[PR.PR_COMMENT,/^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],[PR.PR_COMMENT,/^(?:)/],[PR.PR_LITERAL,/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],[PR.PR_LITERAL,/^#(?:[0-9a-f]{3}){1,2}/i],[PR.PR_PLAIN,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],[PR.PR_PUNCTUATION,/^[^\s\w\'\"]+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_KEYWORD,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_STRING,/^[^\)\"\']+/]]),["css-str"]); diff --git a/qa/coverage/sort-arrow-sprite.png b/qa/coverage/sort-arrow-sprite.png deleted file mode 100644 index 6ed68316eb3f65dec9063332d2f69bf3093bbfab..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 138 zcmeAS@N?(olHy`uVBq!ia0vp^>_9Bd!3HEZxJ@+%Qh}Z>jv*C{$p!i!8j}?a+@3A= zIAGwzjijN=FBi!|L1t?LM;Q;gkwn>2cAy-KV{dn nf0J1DIvEHQu*n~6U}x}qyky7vi4|9XhBJ7&`njxgN@xNA8m%nc diff --git a/qa/coverage/sorter.js b/qa/coverage/sorter.js deleted file mode 100644 index 2bb296a8..00000000 --- a/qa/coverage/sorter.js +++ /dev/null @@ -1,196 +0,0 @@ -/* eslint-disable */ -var addSorting = (function() { - 'use strict'; - var cols, - currentSort = { - index: 0, - desc: false - }; - - // returns the summary table element - function getTable() { - return document.querySelector('.coverage-summary'); - } - // returns the thead element of the summary table - function getTableHeader() { - return getTable().querySelector('thead tr'); - } - // returns the tbody element of the summary table - function getTableBody() { - return getTable().querySelector('tbody'); - } - // returns the th element for nth column - function getNthColumn(n) { - return getTableHeader().querySelectorAll('th')[n]; - } - - function onFilterInput() { - const searchValue = document.getElementById('fileSearch').value; - const rows = document.getElementsByTagName('tbody')[0].children; - for (let i = 0; i < rows.length; i++) { - const row = rows[i]; - if ( - row.textContent - .toLowerCase() - .includes(searchValue.toLowerCase()) - ) { - row.style.display = ''; - } else { - row.style.display = 'none'; - } - } - } - - // loads the search box - function addSearchBox() { - var template = document.getElementById('filterTemplate'); - var templateClone = template.content.cloneNode(true); - templateClone.getElementById('fileSearch').oninput = onFilterInput; - template.parentElement.appendChild(templateClone); - } - - // loads all columns - function loadColumns() { - var colNodes = getTableHeader().querySelectorAll('th'), - colNode, - cols = [], - col, - i; - - for (i = 0; i < colNodes.length; i += 1) { - colNode = colNodes[i]; - col = { - key: colNode.getAttribute('data-col'), - sortable: !colNode.getAttribute('data-nosort'), - type: colNode.getAttribute('data-type') || 'string' - }; - cols.push(col); - if (col.sortable) { - col.defaultDescSort = col.type === 'number'; - colNode.innerHTML = - colNode.innerHTML + ''; - } - } - return cols; - } - // attaches a data attribute to every tr element with an object - // of data values keyed by column name - function loadRowData(tableRow) { - var tableCols = tableRow.querySelectorAll('td'), - colNode, - col, - data = {}, - i, - val; - for (i = 0; i < tableCols.length; i += 1) { - colNode = tableCols[i]; - col = cols[i]; - val = colNode.getAttribute('data-value'); - if (col.type === 'number') { - val = Number(val); - } - data[col.key] = val; - } - return data; - } - // loads all row data - function loadData() { - var rows = getTableBody().querySelectorAll('tr'), - i; - - for (i = 0; i < rows.length; i += 1) { - rows[i].data = loadRowData(rows[i]); - } - } - // sorts the table using the data for the ith column - function sortByIndex(index, desc) { - var key = cols[index].key, - sorter = function(a, b) { - a = a.data[key]; - b = b.data[key]; - return a < b ? -1 : a > b ? 1 : 0; - }, - finalSorter = sorter, - tableBody = document.querySelector('.coverage-summary tbody'), - rowNodes = tableBody.querySelectorAll('tr'), - rows = [], - i; - - if (desc) { - finalSorter = function(a, b) { - return -1 * sorter(a, b); - }; - } - - for (i = 0; i < rowNodes.length; i += 1) { - rows.push(rowNodes[i]); - tableBody.removeChild(rowNodes[i]); - } - - rows.sort(finalSorter); - - for (i = 0; i < rows.length; i += 1) { - tableBody.appendChild(rows[i]); - } - } - // removes sort indicators for current column being sorted - function removeSortIndicators() { - var col = getNthColumn(currentSort.index), - cls = col.className; - - cls = cls.replace(/ sorted$/, '').replace(/ sorted-desc$/, ''); - col.className = cls; - } - // adds sort indicators for current column being sorted - function addSortIndicators() { - getNthColumn(currentSort.index).className += currentSort.desc - ? ' sorted-desc' - : ' sorted'; - } - // adds event listeners for all sorter widgets - function enableUI() { - var i, - el, - ithSorter = function ithSorter(i) { - var col = cols[i]; - - return function() { - var desc = col.defaultDescSort; - - if (currentSort.index === i) { - desc = !currentSort.desc; - } - sortByIndex(i, desc); - removeSortIndicators(); - currentSort.index = i; - currentSort.desc = desc; - addSortIndicators(); - }; - }; - for (i = 0; i < cols.length; i += 1) { - if (cols[i].sortable) { - // add the click event handler on the th so users - // dont have to click on those tiny arrows - el = getNthColumn(i).querySelector('.sorter').parentElement; - if (el.addEventListener) { - el.addEventListener('click', ithSorter(i)); - } else { - el.attachEvent('onclick', ithSorter(i)); - } - } - } - } - // adds sorting functionality to the UI - return function() { - if (!getTable()) { - return; - } - cols = loadColumns(); - loadData(); - addSearchBox(); - addSortIndicators(); - enableUI(); - }; -})(); - -window.addEventListener('load', addSorting); diff --git a/qa/lint.txt b/qa/lint.txt deleted file mode 100644 index 917ce637..00000000 --- a/qa/lint.txt +++ /dev/null @@ -1 +0,0 @@ -Test git rev: 4266ec27590971750fc7c20d640f8903c3863485 diff --git a/qa/unit-test.txt b/qa/unit-test.txt deleted file mode 100644 index 7b7538f0..00000000 --- a/qa/unit-test.txt +++ /dev/null @@ -1,84 +0,0 @@ -Test git rev: 4266ec27590971750fc7c20d640f8903c3863485 -PASS cli/lib/configuration/test/handle-configuration-show.test.js -PASS cli/lib/configuration/test/handle-configuration-initialize.test.js ---------------------------------------|---------|----------|---------|---------|------------------- -File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s ---------------------------------------|---------|----------|---------|---------|------------------- -All files | 1.3 | 0.16 | 2.38 | 1.33 | - cli | 0 | 0 | 0 | 0 | - cloudsite.mjs | 0 | 0 | 0 | 0 | 1-150 - constants.mjs | 0 | 0 | 0 | 0 | 1-45 - cli/lib | 0 | 0 | 0 | 0 | - check-authentication.mjs | 0 | 100 | 0 | 0 | 1-11 - check-format.mjs | 0 | 0 | 0 | 0 | 1-7 - check-reminders.mjs | 0 | 0 | 0 | 0 | 1-21 - get-global-options.mjs | 0 | 0 | 0 | 0 | 1-32 - get-options-spec.mjs | 0 | 0 | 0 | 0 | 1-13 - get-site-info.mjs | 0 | 0 | 0 | 0 | 1-12 - get-value-container-and-key.mjs | 0 | 0 | 0 | 0 | 1-46 - handle-cleanup.mjs | 0 | 0 | 0 | 0 | 1-48 - handle-configuration.mjs | 0 | 0 | 0 | 0 | 1-22 - handle-create.mjs | 0 | 0 | 0 | 0 | 1-128 - handle-destroy.mjs | 0 | 0 | 0 | 0 | 1-55 - handle-detail.mjs | 0 | 0 | 0 | 0 | 1-23 - handle-get-iam-policy.mjs | 0 | 0 | 0 | 0 | 1-252 - handle-import.mjs | 0 | 0 | 0 | 0 | 1-65 - handle-list.mjs | 0 | 0 | 0 | 0 | 1-22 - handle-plugin-settings.mjs | 0 | 0 | 0 | 0 | 1-22 - handle-update.mjs | 0 | 100 | 0 | 0 | 1-24 - handle-verify.mjs | 0 | 0 | 0 | 0 | 1-31 - options.mjs | 0 | 0 | 0 | 0 | 1-67 - process-source-type.mjs | 0 | 0 | 0 | 0 | 1-15 - smart-convert.mjs | 0 | 0 | 0 | 0 | 1-20 - cli/lib/configuration | 100 | 50 | 100 | 100 | - handle-configuration-initialize.mjs | 100 | 100 | 100 | 100 | - handle-configuration-show.mjs | 100 | 50 | 100 | 100 | 16 - cli/lib/plugin-settings | 0 | 0 | 0 | 0 | - handle-plugin-settings-set.mjs | 0 | 0 | 0 | 0 | 1-45 - handle-plugin-settings-show.mjs | 0 | 0 | 0 | 0 | 1-18 - lib/actions | 0 | 0 | 0 | 0 | - create.mjs | 0 | 0 | 0 | 0 | 1-151 - destroy.mjs | 0 | 0 | 0 | 0 | 1-61 - import.mjs | 0 | 0 | 0 | 0 | 1-71 - update.mjs | 0 | 0 | 0 | 0 | 1-89 - verify.mjs | 0 | 0 | 0 | 0 | 1-179 - lib/actions/lib | 0 | 0 | 0 | 0 | - add-tags-to-hosted-zone.mjs | 0 | 100 | 0 | 0 | 1-18 - associate-cost-allocation-tags.mjs | 0 | 100 | 0 | 0 | 1-17 - create-or-update-dns-records.mjs | 0 | 100 | 0 | 0 | 1-41 - find-certificate.mjs | 0 | 0 | 0 | 0 | 1-27 - get-credentials.mjs | 0 | 0 | 0 | 0 | 1-9 - get-hosted-zone-id.mjs | 0 | 0 | 0 | 0 | 1-19 - sync-site-content.mjs | 0 | 0 | 0 | 0 | 1-34 - track-stack-status.mjs | 0 | 0 | 0 | 0 | 1-41 - update-plugins.mjs | 0 | 0 | 0 | 0 | 1-18 - update-site-info.mjs | 0 | 100 | 0 | 0 | 1-15 - update-stack.mjs | 0 | 0 | 0 | 0 | 1-64 - lib/plugins | 0 | 0 | 0 | 0 | - access-logs.mjs | 0 | 100 | 0 | 0 | 1-11 - cloudfront-logs.mjs | 0 | 0 | 0 | 0 | 1-40 - lib/plugins/contact-handler/lib | 0 | 0 | 0 | 0 | - constants.mjs | 0 | 100 | 100 | 0 | 1-5 - determine-lambda-function-name.mjs | 0 | 0 | 0 | 0 | 1-32 - setup-contact-emailer.mjs | 0 | 0 | 0 | 0 | 1-151 - setup-contact-form-table.mjs | 0 | 100 | 0 | 0 | 1-29 - setup-contact-handler.mjs | 0 | 0 | 0 | 0 | 1-174 - setup-request-signer.mjs | 0 | 0 | 0 | 0 | 1-104 - stage-lambda-function-zip-files.mjs | 0 | 0 | 0 | 0 | 1-89 - update-cloud-front-distribution.mjs | 0 | 0 | 0 | 0 | 1-43 - lib/shared | 3.57 | 0 | 5 | 3.68 | - convert-domain-to-bucket-name.js | 0 | 100 | 0 | 0 | 1 - determine-bucket-name.mjs | 0 | 0 | 0 | 0 | 1-50 - determine-oac-name.mjs | 0 | 0 | 0 | 0 | 1-45 - find-bucket-like.mjs | 0 | 0 | 0 | 0 | 1-25 - get-account-id.mjs | 0 | 0 | 0 | 0 | 1-11 - get-site-tag.mjs | 0 | 100 | 0 | 0 | 1-3 - progress-logger.mjs | 66.66 | 0 | 50 | 66.66 | 10-13 - site-template.mjs | 0 | 0 | 0 | 0 | 1-267 ---------------------------------------|---------|----------|---------|---------|------------------- - -Test Suites: 2 passed, 2 total -Tests: 3 passed, 3 total -Snapshots: 0 total -Time: 1.426 s -Ran all test suites.