auth0-deploy-cli 7.6.0 → 7.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. package/.eslintrc +7 -41
  2. package/.husky/pre-commit +4 -0
  3. package/.husky/pre-push +3 -1
  4. package/.prettierignore +10 -0
  5. package/.prettierrc.json +4 -0
  6. package/CHANGELOG.md +194 -7
  7. package/CONTRIBUTING.md +2 -2
  8. package/README.md +3 -0
  9. package/lib/args.js +16 -15
  10. package/lib/commands/export.js +3 -3
  11. package/lib/commands/import.js +6 -6
  12. package/lib/commands/index.js +1 -1
  13. package/lib/configFactory.js +5 -1
  14. package/lib/context/defaults.js +4 -3
  15. package/lib/context/directory/handlers/actions.js +3 -3
  16. package/lib/context/directory/handlers/attackProtection.js +4 -4
  17. package/lib/context/directory/handlers/branding.js +6 -5
  18. package/lib/context/directory/handlers/clientGrants.js +3 -2
  19. package/lib/context/directory/handlers/clients.js +1 -1
  20. package/lib/context/directory/handlers/connections.js +4 -2
  21. package/lib/context/directory/handlers/databases.js +13 -7
  22. package/lib/context/directory/handlers/emailProvider.js +3 -2
  23. package/lib/context/directory/handlers/emailTemplates.js +2 -2
  24. package/lib/context/directory/handlers/guardianFactorProviders.js +3 -2
  25. package/lib/context/directory/handlers/guardianFactorTemplates.js +3 -2
  26. package/lib/context/directory/handlers/guardianFactors.js +3 -2
  27. package/lib/context/directory/handlers/guardianPhoneFactorMessageTypes.js +1 -1
  28. package/lib/context/directory/handlers/guardianPhoneFactorSelectedProvider.js +1 -1
  29. package/lib/context/directory/handlers/guardianPolicies.js +1 -1
  30. package/lib/context/directory/handlers/hooks.js +2 -2
  31. package/lib/context/directory/handlers/index.js +3 -2
  32. package/lib/context/directory/handlers/organizations.js +1 -1
  33. package/lib/context/directory/handlers/pages.js +2 -2
  34. package/lib/context/directory/handlers/resourceServers.js +3 -2
  35. package/lib/context/directory/handlers/roles.js +1 -1
  36. package/lib/context/directory/handlers/rules.js +2 -2
  37. package/lib/context/directory/handlers/rulesConfigs.js +3 -2
  38. package/lib/context/directory/handlers/tenant.js +3 -2
  39. package/lib/context/directory/index.js +21 -18
  40. package/lib/context/index.js +66 -62
  41. package/lib/context/yaml/handlers/actions.js +9 -6
  42. package/lib/context/yaml/handlers/attackProtection.js +1 -1
  43. package/lib/context/yaml/handlers/branding.js +5 -4
  44. package/lib/context/yaml/handlers/clientGrants.js +2 -2
  45. package/lib/context/yaml/handlers/clients.js +6 -4
  46. package/lib/context/yaml/handlers/connections.js +7 -5
  47. package/lib/context/yaml/handlers/databases.js +12 -8
  48. package/lib/context/yaml/handlers/emailProvider.js +4 -3
  49. package/lib/context/yaml/handlers/emailTemplates.js +3 -3
  50. package/lib/context/yaml/handlers/guardianFactorProviders.js +1 -1
  51. package/lib/context/yaml/handlers/guardianFactorTemplates.js +1 -1
  52. package/lib/context/yaml/handlers/guardianFactors.js +1 -1
  53. package/lib/context/yaml/handlers/guardianPhoneFactorMessageTypes.js +1 -1
  54. package/lib/context/yaml/handlers/guardianPhoneFactorSelectedProvider.js +1 -1
  55. package/lib/context/yaml/handlers/guardianPolicies.js +1 -1
  56. package/lib/context/yaml/handlers/hooks.js +4 -3
  57. package/lib/context/yaml/handlers/index.js +3 -2
  58. package/lib/context/yaml/handlers/organizations.js +3 -3
  59. package/lib/context/yaml/handlers/pages.js +3 -3
  60. package/lib/context/yaml/handlers/resourceServers.js +2 -2
  61. package/lib/context/yaml/handlers/roles.js +3 -3
  62. package/lib/context/yaml/handlers/rules.js +3 -3
  63. package/lib/context/yaml/handlers/rulesConfigs.js +2 -2
  64. package/lib/context/yaml/handlers/tenant.js +4 -3
  65. package/lib/context/yaml/handlers/triggers.js +2 -2
  66. package/lib/context/yaml/index.js +31 -23
  67. package/lib/index.js +20 -15
  68. package/lib/logger.js +4 -3
  69. package/lib/readonly.js +11 -16
  70. package/lib/sessionDurationsToMinutes.js +15 -0
  71. package/lib/tools/auth0/client.js +6 -6
  72. package/lib/tools/auth0/handlers/actions.js +21 -23
  73. package/lib/tools/auth0/handlers/attackProtection.js +14 -17
  74. package/lib/tools/auth0/handlers/branding.js +13 -9
  75. package/lib/tools/auth0/handlers/clientGrants.js +17 -10
  76. package/lib/tools/auth0/handlers/clients.js +15 -8
  77. package/lib/tools/auth0/handlers/connections.js +30 -10
  78. package/lib/tools/auth0/handlers/databases.js +24 -12
  79. package/lib/tools/auth0/handlers/default.js +41 -29
  80. package/lib/tools/auth0/handlers/emailTemplates.js +8 -10
  81. package/lib/tools/auth0/handlers/guardianFactorProviders.js +3 -3
  82. package/lib/tools/auth0/handlers/guardianFactorTemplates.js +3 -3
  83. package/lib/tools/auth0/handlers/guardianFactors.js +3 -3
  84. package/lib/tools/auth0/handlers/guardianPhoneFactorMessageTypes.js +11 -10
  85. package/lib/tools/auth0/handlers/guardianPhoneFactorSelectedProvider.js +10 -9
  86. package/lib/tools/auth0/handlers/guardianPolicies.js +5 -4
  87. package/lib/tools/auth0/handlers/hooks.js +34 -21
  88. package/lib/tools/auth0/handlers/index.js +31 -27
  89. package/lib/tools/auth0/handlers/migrations.js +2 -1
  90. package/lib/tools/auth0/handlers/organizations.js +61 -31
  91. package/lib/tools/auth0/handlers/pages.js +20 -14
  92. package/lib/tools/auth0/handlers/prompts.js +1 -0
  93. package/lib/tools/auth0/handlers/resourceServers.js +22 -14
  94. package/lib/tools/auth0/handlers/roles.js +55 -31
  95. package/lib/tools/auth0/handlers/rules.js +49 -32
  96. package/lib/tools/auth0/handlers/rulesConfigs.js +12 -6
  97. package/lib/tools/auth0/handlers/tenant.js +8 -4
  98. package/lib/tools/auth0/handlers/triggers.js +11 -12
  99. package/lib/tools/auth0/index.js +15 -31
  100. package/lib/tools/auth0/schema.js +7 -27
  101. package/lib/tools/calculateChanges.js +11 -6
  102. package/lib/tools/constants.js +162 -161
  103. package/lib/tools/deploy.js +1 -1
  104. package/lib/tools/index.js +1 -1
  105. package/lib/tools/logger.js +14 -8
  106. package/lib/tools/utils.js +2 -2
  107. package/lib/tools/{ValidationError.js → validationError.js} +3 -1
  108. package/lib/types.js +2 -0
  109. package/lib/utils.js +12 -22
  110. package/package.json +8 -1
  111. package/tsconfig.json +1 -3
  112. package/typescript-migration-progress.sh +1 -1
package/.eslintrc CHANGED
@@ -3,11 +3,7 @@
3
3
  "parserOptions": {
4
4
  "ecmaVersion": 2020
5
5
  },
6
- "extends": [
7
- "airbnb-base",
8
- "plugin:import/errors",
9
- "plugin:import/warnings"
10
- ],
6
+ "extends": ["airbnb-base", "plugin:import/errors", "plugin:import/warnings", "prettier"],
11
7
  "env": {
12
8
  "es2020": true,
13
9
  "node": true,
@@ -16,25 +12,15 @@
16
12
  "settings": {
17
13
  "import/resolver": {
18
14
  "node": {
19
- "extensions": [
20
- ".js",
21
- ".ts"
22
- ]
15
+ "extensions": [".js", ".ts"]
23
16
  }
24
17
  }
25
18
  },
26
19
  "rules": {
27
20
  "max-len": 0,
28
21
  "react/display-name": 0,
29
- "array-bracket-spacing": [
30
- 2,
31
- "always"
32
- ],
33
22
  "class-methods-use-this": 0,
34
- "comma-dangle": [
35
- 2,
36
- "never"
37
- ],
23
+ "comma-dangle": 0,
38
24
  "eol-last": 2,
39
25
  "indent": [
40
26
  2,
@@ -66,31 +52,11 @@
66
52
  ],
67
53
  "no-unused-vars": 2,
68
54
  "no-var": 0,
69
- "object-curly-spacing": [
70
- 2,
71
- "always"
72
- ],
73
- "quotes": [
74
- 2,
75
- "single",
76
- "avoid-escape"
77
- ],
78
- "semi": [
79
- 2,
80
- "always"
81
- ],
55
+ "object-curly-spacing": [2, "always"],
56
+ "quotes": [2, "single", "avoid-escape"],
57
+ "semi": [2, "always"],
82
58
  "strict": 0,
83
- "space-before-blocks": [
84
- 2,
85
- "always"
86
- ],
87
- "space-before-function-paren": [
88
- 2,
89
- {
90
- "anonymous": "never",
91
- "named": "never"
92
- }
93
- ],
59
+ "space-before-blocks": [2, "always"],
94
60
  "import/extensions": [
95
61
  "error",
96
62
  "ignorePackages",
package/.husky/pre-commit CHANGED
@@ -3,4 +3,8 @@
3
3
 
4
4
  npm run lint:fix
5
5
 
6
+ npx pretty-quick --staged
7
+
8
+ npx tsc --noEmit # Ensure that code compiles
9
+
6
10
  /bin/bash ./typescript-migration-progress.sh
package/.husky/pre-push CHANGED
@@ -1,4 +1,6 @@
1
1
  #!/bin/sh
2
2
  . "$(dirname "$0")/_/husky.sh"
3
3
 
4
- npm run test && npm run lint
4
+ npm run test
5
+
6
+ npm run lint
@@ -0,0 +1,10 @@
1
+ # Ignore artifacts:
2
+ local
3
+ lib
4
+ .circleci
5
+ .github
6
+ .husky
7
+ node_modules
8
+ examples
9
+ test/**/*.json
10
+ test/**/*.yaml
@@ -0,0 +1,4 @@
1
+ {
2
+ "printWidth": 100,
3
+ "singleQuote": true
4
+ }