@adinsure-ops/ops-cli 4.0.0-rc6

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 (71) hide show
  1. package/CHANGELOGS.md +55 -0
  2. package/LICENSE +1 -0
  3. package/README.md +576 -0
  4. package/bin/run +5 -0
  5. package/bin/run.cmd +3 -0
  6. package/lib/command.base.d.ts +17 -0
  7. package/lib/command.base.jira.d.ts +11 -0
  8. package/lib/command.base.jira.js +37 -0
  9. package/lib/command.base.js +73 -0
  10. package/lib/commands/doctor.d.ts +54 -0
  11. package/lib/commands/doctor.js +311 -0
  12. package/lib/commands/download/client.d.ts +18 -0
  13. package/lib/commands/download/client.js +72 -0
  14. package/lib/commands/download/identity-server.d.ts +18 -0
  15. package/lib/commands/download/identity-server.js +72 -0
  16. package/lib/commands/download/platform.d.ts +18 -0
  17. package/lib/commands/download/platform.js +72 -0
  18. package/lib/commands/download/scheduler.d.ts +18 -0
  19. package/lib/commands/download/scheduler.js +72 -0
  20. package/lib/commands/download/server.d.ts +18 -0
  21. package/lib/commands/download/server.js +72 -0
  22. package/lib/commands/download/studio.d.ts +20 -0
  23. package/lib/commands/download/studio.js +89 -0
  24. package/lib/commands/gitlab/next-nightly-tag.d.ts +30 -0
  25. package/lib/commands/gitlab/next-nightly-tag.js +171 -0
  26. package/lib/commands/jira/issue.d.ts +17 -0
  27. package/lib/commands/jira/issue.js +31 -0
  28. package/lib/commands/jira/labels.d.ts +22 -0
  29. package/lib/commands/jira/labels.js +70 -0
  30. package/lib/commands/log/add.d.ts +17 -0
  31. package/lib/commands/log/add.js +107 -0
  32. package/lib/commands/log/generate.d.ts +22 -0
  33. package/lib/commands/log/generate.js +155 -0
  34. package/lib/commands/log/validate.d.ts +11 -0
  35. package/lib/commands/log/validate.js +58 -0
  36. package/lib/commands/login.d.ts +23 -0
  37. package/lib/commands/login.js +144 -0
  38. package/lib/commands/npm/check.publish.d.ts +17 -0
  39. package/lib/commands/npm/check.publish.js +78 -0
  40. package/lib/commands/npm/publish.d.ts +23 -0
  41. package/lib/commands/npm/publish.js +163 -0
  42. package/lib/commands/prepare-content.d.ts +29 -0
  43. package/lib/commands/prepare-content.js +386 -0
  44. package/lib/commands/sql.d.ts +24 -0
  45. package/lib/commands/sql.js +147 -0
  46. package/lib/commands/translate.d.ts +37 -0
  47. package/lib/commands/translate.js +149 -0
  48. package/lib/commands/version.d.ts +48 -0
  49. package/lib/commands/version.js +267 -0
  50. package/lib/config.d.ts +7 -0
  51. package/lib/config.js +9 -0
  52. package/lib/hooks/init/version-override.d.ts +2 -0
  53. package/lib/hooks/init/version-override.js +15 -0
  54. package/lib/index.d.ts +1 -0
  55. package/lib/index.js +4 -0
  56. package/lib/lib/command.d.ts +9 -0
  57. package/lib/lib/command.js +71 -0
  58. package/lib/lib/npm.d.ts +15 -0
  59. package/lib/lib/npm.js +79 -0
  60. package/lib/lib/npmrc.d.ts +17 -0
  61. package/lib/lib/npmrc.js +44 -0
  62. package/lib/security/cache.d.ts +7 -0
  63. package/lib/security/cache.js +33 -0
  64. package/lib/security/context.d.ts +58 -0
  65. package/lib/security/context.js +224 -0
  66. package/lib/types/changelog.types.d.ts +6 -0
  67. package/lib/types/changelog.types.js +2 -0
  68. package/lib/types/npm.types.d.ts +34 -0
  69. package/lib/types/npm.types.js +2 -0
  70. package/oclif.manifest.json +1 -0
  71. package/package.json +118 -0
@@ -0,0 +1 @@
1
+ {"version":"4.0.0-rc6","commands":{"doctor":{"id":"doctor","description":"check if everyting is installed","usage":"doctor","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops doctor"],"flags":{"fix":{"name":"fix","type":"boolean","char":"p","description":"try to install missing packages","allowNo":false}},"args":[]},"login":{"id":"login","description":"log in to use ops services","usage":"login","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops login","$ ops login -c {client id} -s {secret}"],"flags":{"deviceFlow":{"name":"deviceFlow","type":"boolean","description":"authenticate using device flow","allowNo":false},"clientId":{"name":"clientId","type":"option","char":"c","description":"(application) client id"},"clientSecret":{"name":"clientSecret","type":"option","char":"s","description":"client secret"},"npm":{"name":"npm","type":"boolean","description":"register also for npm","allowNo":false},"skipCI":{"name":"skipCI","type":"option","description":"Skip login if environment variables is set"}},"args":[]},"prepare-content":{"id":"prepare-content","description":"copies files as described in .opsprepare which is at root of source directory","usage":"prepare-content -d <destination> [-s <source>]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops prepare-content -d .\\my_workspace","$ ops prepare-content -d .\\my_workspace -s .\\my_repository","$ ops prepare-content -d C:\\git\\my_workspace","$ ops prepare-content -d C:\\git\\my_workspace -s C:\\git\\my_repository\\my_repository"],"flags":{"destination":{"name":"destination","type":"option","char":"d","description":"where to copy the workspace files","required":true},"source":{"name":"source","type":"option","char":"s","description":"[optional] source directory, default: current dir","required":false,"default":"."}},"args":[]},"sql":{"id":"sql","description":"creates a new database script","usage":"sql <type> <module> [flags]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops sql schema ","$ ops sql data shared --layer basic"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version for which you're generating database script"},"layer":{"name":"layer","type":"option","char":"l","description":"name of the configuration layer for which you are generating database script"}},"args":[{"name":"type","description":"Type of database scripts","options":["schema","data","migration"]},{"name":"module","description":"Module of data database scripts","options":["acc","claims","core","pas","reins","shared"]}]},"translate":{"id":"translate","description":"downloads translate from AdDictionary service","usage":"translate <language> [flags]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops translate \"en-US=en-US;ru-Ru=ru-RU\" -f json -m \"Client business accounting;Client business base;\"","$ ops translate \"en-US=en-US;ru-Ru=ru-RU\" -f xml -o translationDestination"],"flags":{"format":{"name":"format","type":"option","char":"f","description":"translations format [xml - server translations, json - client translations]","required":true,"options":["json","xml"]},"module":{"name":"module","type":"option","char":"m","description":"module name you want to download. Values must be semi-colon (;) separated."},"output":{"name":"output","type":"option","char":"o","description":"absolute or relative destination path to a folder where translations are extracted.","default":"."},"filename":{"name":"filename","type":"option","description":"specify filename of output (XML only)."},"respectServerFilename":{"name":"respectServerFilename","type":"boolean","description":"respect filename that is returned from AdDictionary server (XML only).","allowNo":false}},"args":[{"name":"language","description":"language id you want to download. Values must be semi-colon (;) separated.","required":true}]},"version":{"id":"version","description":"release new version","usage":"version <type> [flags]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops version patch","$ ops version prerelease -i","$ ops version new -v 3.4.3"],"flags":{"independent":{"name":"independent","type":"boolean","char":"i","description":"increment npm packages independent of VERSION file","allowNo":false},"version":{"name":"version","type":"option","char":"v","description":"force version"},"script-prefix":{"name":"script-prefix","type":"option","description":"prefix for db script version creation. (default: 7.10)","default":"7.10"},"no-deps":{"name":"no-deps","type":"boolean","description":"skip dependency update","allowNo":false},"no-script":{"name":"no-script","type":"boolean","description":"skip creation of script","allowNo":false},"only-npm-packages":{"name":"only-npm-packages","type":"option","description":"regular expression for which NPM packages to include","default":".*"},"exclude-dir":{"name":"exclude-dir","type":"option","description":"exclude directories where to search for package.json"}},"args":[{"name":"type","description":"Type of release","required":true,"options":["patch","minor","major","prerelease","preminor","premajor","new"]}]},"download:client":{"id":"download:client","description":"download AdInsure Client from Azure storage","usage":"download:client <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download:client"],"examples":["$ ops download:client -v 3.2.0 -o ~/Downloads"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"}},"args":[]},"download:identity-server":{"id":"download:identity-server","description":"download AdInsure Identity Server from Azure storage","usage":"download:identity-server <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download:identity-server"],"examples":["$ ops download:identity-server -v 3.0.3 -o ~/Downloads"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"}},"args":[]},"download:platform":{"id":"download:platform","description":"download platform from azure storage","usage":"download <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download","download:platform"],"examples":["$ ops download -v 6.0.0 -o ~/Downloads"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"}},"args":[]},"download:scheduler":{"id":"download:scheduler","description":"download scheduler from azure storage","usage":"download:scheduler <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download:scheduler"],"examples":["$ ops download:scheduler -v 3.2.0 -o ~/Downloads"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"}},"args":[]},"download:server":{"id":"download:server","description":"download AdInsure Server from Azure storage","usage":"download:server <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download:server"],"examples":["$ ops download:server -v 3.2.0 -o ~/Downloads"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"}},"args":[]},"download:studio":{"id":"download:studio","description":"download studio vsix from azure storage","usage":"download:studio <flags>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["download:studio"],"examples":["$ ops download:studio -v 15.0.0 -o ~/Downloads","$ ops download:studio -v 15.0.0 -i"],"flags":{"version":{"name":"version","type":"option","char":"v","description":"version we want to download","required":true},"output":{"name":"output","type":"option","char":"o","description":"output directory","default":"./"},"install":{"name":"install","type":"boolean","char":"i","description":"install plugin to vscode. save to temp folder and remove vsix after.","allowNo":false}},"args":[]},"gitlab:next-nightly-tag":{"id":"gitlab:next-nightly-tag","description":"creates new gitlab tag","usage":"gitlab:next-nightly-tag <version> -n","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["gitlab:next-nightly-tag"],"examples":["$ ops gitlab:tag 17.0.0","$ ops gitlab:tag 17.0.0 -n"],"flags":{"pat":{"name":"pat","type":"option","description":"Token from user that has permissions to list and create tags","required":true},"host":{"name":"host","type":"option","description":"Server hostname","required":true,"default":"https://git.adacta-fintech.com"},"project":{"name":"project","type":"option","description":"Project ID","required":true,"default":"413"},"reference":{"name":"reference","type":"option","description":"Reference to create tag on (branch, commit, tag)","required":true},"dryRun":{"name":"dryRun","type":"boolean","description":"Only printout version and don't create it","allowNo":false}},"args":[{"name":"version","description":"Tag version"}]},"jira:issue":{"id":"jira:issue","description":"get Jira issue","usage":"jira:issue <issue>","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops jira:issue LJADIRD-1337"],"flags":{"username":{"name":"username","type":"option","description":"jira username","required":true},"password":{"name":"password","type":"option","description":"jira password","required":true},"hostname":{"name":"hostname","type":"option","description":"jira hostname","default":"https://jira.adacta-fintech.com"}},"args":[{"name":"issue","description":"Jira issue number","required":true}]},"jira:labels":{"id":"jira:labels","description":"list or edit labels on Jira issue","usage":"jira:labels <issue> -a [label] -r [label]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":[],"examples":["$ ops jira:labels LJADIRD-1337"],"flags":{"username":{"name":"username","type":"option","description":"jira username","required":true},"password":{"name":"password","type":"option","description":"jira password","required":true},"hostname":{"name":"hostname","type":"option","description":"jira hostname","default":"https://jira.adacta-fintech.com"},"add":{"name":"add","type":"option","char":"a","description":"add label"},"remove":{"name":"remove","type":"option","char":"r","description":"remove label"}},"args":[{"name":"issue","description":"Jira issue number","required":true}]},"log:add":{"id":"log:add","description":"creates a new changelog entry","usage":"log <issue> -t [type] -c [options]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["log","log:add"],"examples":["$ ops log LJADIRD-1234 -t feature","$ ops log LJADIRD-5678 -t fixed","$ ops log LJADIRD-8765 -t breaking -c Platform","$ ops log LJADIRD-4321 -t improve -c Configuration"],"flags":{"type":{"name":"type","type":"option","char":"t","description":"type of changelog","options":["feature","fixed","improve","breaking"]},"component":{"name":"component","type":"option","char":"c","description":"Component for which new changelog should be generated","default":""}},"args":[{"name":"issue","description":"Jira issue number"}]},"log:generate":{"id":"log:generate","description":"generates final changelog from unreleased notes","usage":"log:gen [options]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["log:gen"],"examples":["$ ops log:gen","$ ops log:gen -p","$ ops log:gen -c Platform","$ ops log:gen -c Platform,Configuration","$ ops log:gen -c Implementation -f CHANGELOG.Implementation.md"],"flags":{"components":{"name":"components","type":"option","char":"c","description":"components separated by comma (,) to process for final changelog","default":""},"file":{"name":"file","type":"option","char":"f","description":"file to update with new changelogs","default":"CHANGELOG.md"},"force":{"name":"force","type":"boolean","description":"update target file without prompting for confirmation","allowNo":false},"preview":{"name":"preview","type":"boolean","char":"p","description":"generates a preview markdown of current unreleased changelogs","allowNo":false},"version":{"name":"version","type":"option","char":"v","description":"version for which you're generating changelogs"},"ignore-no-changelogs":{"name":"ignore-no-changelogs","type":"boolean","description":"generate final changelog even if no unreleased changelogs exist","allowNo":false}},"args":[]},"log:validate":{"id":"log:validate","description":"validates formatting of all unreleased changelogs","usage":"log:validate [options]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["log:validate"],"examples":["$ ops log:validate"],"flags":{},"args":[]},"npm:check.publish":{"id":"npm:check.publish","description":"check if npm packages was published","usage":"npm:check-publish [options]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["npm:check-publish"],"examples":["$ ops npm:check-publish -v 6.0.1","$ ops npm:check-publish -p @adinsure/* -v 6.0.0","$ ops npm:check-publish -p @adinsure/* -x @adisure/demo -v 6.0.0"],"flags":{"package":{"name":"package","type":"option","char":"p","description":"package name filter you want to check"},"exclude":{"name":"exclude","type":"option","char":"x","description":"exclude packages from filter"},"version":{"name":"version","type":"option","char":"v","description":"version we want to check if published","required":true},"pat":{"name":"pat","type":"option","description":"PAT token or AZURE_DEVOPS_EXT_PAT environment variable"}},"args":[]},"npm:publish":{"id":"npm:publish","description":"Publish npm packages","usage":"npm:publish [options]","pluginName":"@adinsure-ops/ops-cli","pluginType":"core","aliases":["npm:publish"],"examples":["$ ops npm:publish -v 15.0.0","$ ops npm:publish -v 15.0.0","$ ops npm:publish -p @adinsure-tooling/* -v 15.0.0","$ ops npm:publish -p @adinsure-tooling/* -x @adisure-tooling/studio-services -v 6.0.0"],"flags":{"package":{"name":"package","type":"option","char":"p","description":"package name filter you want to check"},"exclude":{"name":"exclude","type":"option","char":"x","description":"exclude packages from filter"},"version":{"name":"version","type":"option","char":"v","description":"version we want to check if published","required":true},"pat":{"name":"pat","type":"option","description":"PAT token or AZURE_DEVOPS_EXT_PAT environment variable"}},"args":[]}}}
package/package.json ADDED
@@ -0,0 +1,118 @@
1
+ {
2
+ "name": "@adinsure-ops/ops-cli",
3
+ "description": "Operations CLI for working with AdInsure",
4
+ "version": "4.0.0-rc6",
5
+ "author": "Adacta Digital Service Department",
6
+ "bin": {
7
+ "ops": "./bin/run"
8
+ },
9
+ "dependencies": {
10
+ "@azure/msal-node": "^1.9.0",
11
+ "@oclif/command": "^1",
12
+ "@oclif/config": "^1",
13
+ "@oclif/plugin-help": "^2",
14
+ "@oclif/plugin-not-found": "^1.2.2",
15
+ "@oclif/plugin-update": "^1.3.9",
16
+ "@oclif/plugin-warn-if-update-available": "^1.7.0",
17
+ "@types/semver": "^6.0.2",
18
+ "axios": "^0.27.2",
19
+ "chalk": "^2.4.2",
20
+ "cli-ux": "^5.2.1",
21
+ "fs-extra": "^8.0.1",
22
+ "globby": "^10.0.0",
23
+ "gray-matter": "^4.0.2",
24
+ "ini": "^3.0.0",
25
+ "inquirer": "^7.3.3",
26
+ "jira-client": "^6.23.0",
27
+ "jszip": "^3.2.2",
28
+ "lodash": "^4.17.11",
29
+ "minimatch": "^3.0.4",
30
+ "moment": "^2.24.0",
31
+ "oauth": "^0.9.15",
32
+ "open": "^6.4.0",
33
+ "replace-in-file": "^4.3.1",
34
+ "request-promise": "^4.2.4",
35
+ "rimraf": "^2.6.3",
36
+ "semver": "^7.3.7",
37
+ "tslib": "^1"
38
+ },
39
+ "devDependencies": {
40
+ "@oclif/dev-cli": "^1",
41
+ "@oclif/test": "^1",
42
+ "@oclif/tslint": "^3",
43
+ "@types/chai": "^4",
44
+ "@types/fs-extra": "^7.0.0",
45
+ "@types/ini": "^1.3.31",
46
+ "@types/inquirer": "^7.3.1",
47
+ "@types/jira-client": "^6.21.3",
48
+ "@types/jszip": "^3.4.1",
49
+ "@types/mocha": "^5",
50
+ "@types/mock-fs": "^3.6.30",
51
+ "@types/node": "^10",
52
+ "@types/oauth": "^0.9.1",
53
+ "@types/request-promise": "^4.1.44",
54
+ "@types/rimraf": "^2.0.2",
55
+ "chai": "^4",
56
+ "mocha": "^5",
57
+ "mock-fs": "^5.1.1",
58
+ "mock-spawn": "^0.2.6",
59
+ "nock": "^13.1.3",
60
+ "nyc": "^15.0.0",
61
+ "timekeeper": "^2.2.0",
62
+ "ts-node": "^8",
63
+ "tslint": "^5",
64
+ "typescript": "^3.3"
65
+ },
66
+ "engines": {
67
+ "node": "^12 || ^14 || ^16"
68
+ },
69
+ "files": [
70
+ "/bin",
71
+ "/lib",
72
+ "/npm-shrinkwrap.json",
73
+ "/oclif.manifest.json"
74
+ ],
75
+ "homepage": "https://git.adacta-fintech.com/ops/ops-cli",
76
+ "keywords": [
77
+ "operations",
78
+ "cli"
79
+ ],
80
+ "license": "SEE LICENSE IN LICENSE",
81
+ "main": "lib/index.js",
82
+ "oclif": {
83
+ "commands": "./lib/commands",
84
+ "bin": "ops",
85
+ "hooks": {
86
+ "init": "./lib/hooks/init/version-override"
87
+ },
88
+ "plugins": [
89
+ "@oclif/plugin-help",
90
+ "@oclif/plugin-not-found",
91
+ "@oclif/plugin-warn-if-update-available",
92
+ "@oclif/plugin-update"
93
+ ],
94
+ "warn-if-update-available": {
95
+ "timeoutInDays": 1,
96
+ "message": "ops-cli update available from <%= chalk.greenBright(config.version) %> to <%= chalk.greenBright(latest) %>.",
97
+ "registry": "https://pkgs.dev.azure.com/adacta-fintech/_packaging/adacta-fintech/npm/registry/",
98
+ "authorization": "Basic OnlibHJ5dm15NXZhd3lyM2VueHB4a3J1bWd2bG02em9nNHdqNHRxb3V0Z3pzZDNwM2ZtdmE="
99
+ },
100
+ "update": {
101
+ "s3": {
102
+ "host": "https://adinsure.blob.core.windows.net/ops-cli"
103
+ }
104
+ }
105
+ },
106
+ "repository": "ops/ops-cli",
107
+ "scripts": {
108
+ "postpack": "rimraf oclif.manifest.json",
109
+ "prepack": "rimraf lib && tsc -b && oclif-dev manifest",
110
+ "test": "nyc --extension .ts mocha --timeout 20000 --forbid-only \"test/**/*.test.ts\"",
111
+ "test-with-coverage": "nyc --extension .ts mocha --reporter=doc --timeout 20000 --forbid-only \"test/**/*.test.ts\"",
112
+ "test-single": "nyc --extension .ts mocha --timeout 20000 --forbid-only",
113
+ "test-single-with-coverage": "nyc --extension .ts mocha --reporter=doc --timeout 20000 --forbid-only",
114
+ "lint": "tslint -p test -t stylish",
115
+ "preversion": "yarn test"
116
+ },
117
+ "types": "lib/index.d.ts"
118
+ }