Merge pull request #85 from crazy-max/dev-deps

Update dev deps
This commit is contained in:
CrazyMax 2021-07-06 20:26:29 +02:00 committed by GitHub
commit 5d62c58fc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 4372 additions and 4608 deletions

@ -1,5 +1,5 @@
{
"printWidth": 120,
"printWidth": 240,
"tabWidth": 2,
"useTabs": false,
"semi": true,

@ -74,21 +74,9 @@ describe('getRegion', () => {
describe('getAccountIDs', () => {
test.each([
['012345678901.dkr.ecr.eu-west-3.amazonaws.com', undefined, ['012345678901']],
[
'012345678901.dkr.ecr.eu-west-3.amazonaws.com',
'012345678910,023456789012',
['012345678901', '012345678910', '023456789012']
],
[
'012345678901.dkr.ecr.eu-west-3.amazonaws.com',
'012345678901,012345678910,023456789012',
['012345678901', '012345678910', '023456789012']
],
[
'390948362332.dkr.ecr.cn-northwest-1.amazonaws.com.cn',
'012345678910,023456789012',
['390948362332', '012345678910', '023456789012']
],
['012345678901.dkr.ecr.eu-west-3.amazonaws.com', '012345678910,023456789012', ['012345678901', '012345678910', '023456789012']],
['012345678901.dkr.ecr.eu-west-3.amazonaws.com', '012345678901,012345678910,023456789012', ['012345678901', '012345678910', '023456789012']],
['390948362332.dkr.ecr.cn-northwest-1.amazonaws.com.cn', '012345678910,023456789012', ['390948362332', '012345678910', '023456789012']],
['public.ecr.aws', undefined, []]
])('given registry %p', async (registry, accountIDsEnv, expected) => {
if (accountIDsEnv) {

3
codecov.yml Normal file

@ -0,0 +1,3 @@
comment: false
github_checks:
annotations: false

6867
dist/index.js generated vendored

File diff suppressed because it is too large Load Diff

@ -33,16 +33,16 @@
"semver": "^7.3.5"
},
"devDependencies": {
"@types/jest": "^26.0.3",
"@types/node": "^14.0.14",
"@vercel/ncc": "^0.23.0",
"dotenv": "^8.2.0",
"jest": "^26.1.0",
"jest-circus": "^26.1.0",
"jest-runtime": "^26.1.0",
"prettier": "^2.0.5",
"ts-jest": "^26.1.1",
"typescript": "^3.9.5",
"@types/jest": "^26.0.23",
"@types/node": "^14.17.4",
"@vercel/ncc": "^0.28.6",
"dotenv": "^8.6.0",
"jest": "^26.6.3",
"jest-circus": "^26.6.3",
"jest-runtime": "^26.6.3",
"prettier": "^2.3.2",
"ts-jest": "^26.5.6",
"typescript": "^3.9.10",
"typescript-formatter": "^7.2.2"
}
}

@ -71,27 +71,14 @@ export const parseCLIVersion = async (stdout: string): Promise<string> => {
return semver.clean(matches[1]);
};
export const getDockerLoginCmds = async (
cliVersion: string,
registry: string,
region: string,
accountIDs: string[]
): Promise<string[]> => {
export const getDockerLoginCmds = async (cliVersion: string, registry: string, region: string, accountIDs: string[]): Promise<string[]> => {
let ecrCmd = (await isPubECR(registry)) ? 'ecr-public' : 'ecr';
if (semver.satisfies(cliVersion, '>=2.0.0') || (await isPubECR(registry))) {
return execCLI([ecrCmd, 'get-login-password', '--region', region]).then(pwd => {
return [`docker login --username AWS --password ${pwd} ${registry}`];
});
} else {
return execCLI([
ecrCmd,
'get-login',
'--region',
region,
'--registry-ids',
accountIDs.join(' '),
'--no-include-email'
]).then(dockerLoginCmds => {
return execCLI([ecrCmd, 'get-login', '--region', region, '--registry-ids', accountIDs.join(' '), '--no-include-email']).then(dockerLoginCmds => {
return dockerLoginCmds.trim().split(`\n`);
});
}

2037
yarn.lock

File diff suppressed because it is too large Load Diff