@squiz/dxp-cli-next 2.6.0 → 2.7.0-develop.1

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.
@@ -0,0 +1,3 @@
1
+ import { Command } from 'commander';
2
+ declare const devModeCommand: Command;
3
+ export default devModeCommand;
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ const commander_1 = require("commander");
13
+ const component_cli_lib_1 = require("@squiz/component-cli-lib");
14
+ const devModeCommand = new commander_1.Command()
15
+ .name('dev')
16
+ .description('A local component runner for developing new components')
17
+ .addHelpText('after', `
18
+
19
+ The logs are currently \`bunyan\` formatted and should be piped into the bunyan cli:
20
+ $ dxp cmp dev <source> | npx bunyan
21
+ `)
22
+ .argument('<source>', 'folder containing the template files in development')
23
+ .addOption(new commander_1.Option('-p, --port <number>', 'Define port the webserver runs on')
24
+ .default(3000)
25
+ .argParser(parseInt))
26
+ .action((source, options) => __awaiter(void 0, void 0, void 0, function* () {
27
+ yield (0, component_cli_lib_1.startDevelopmentRender)(source, options);
28
+ }));
29
+ exports.default = devModeCommand;
package/lib/cmp/index.js CHANGED
@@ -5,6 +5,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const commander_1 = require("commander");
7
7
  const deploy_1 = __importDefault(require("./deploy"));
8
+ const dev_mode_1 = __importDefault(require("./dev-mode"));
8
9
  const cmpCommand = new commander_1.Command('cmp');
9
- cmpCommand.description('Component Service Commands').addCommand(deploy_1.default);
10
+ cmpCommand
11
+ .description('Component Service Commands')
12
+ .addCommand(deploy_1.default)
13
+ .addCommand(dev_mode_1.default);
10
14
  exports.default = cmpCommand;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squiz/dxp-cli-next",
3
- "version": "2.6.0",
3
+ "version": "2.7.0-develop.1",
4
4
  "repository": {
5
5
  "url": "https://gitlab.squiz.net/developer-experience/dxp-cli-next"
6
6
  },
@@ -40,38 +40,38 @@
40
40
  ],
41
41
  "dependencies": {
42
42
  "@squiz/deployment-service-lib": "1.1.5-alpha.77",
43
- "@squiz/component-cli-lib": "1.2.1-alpha.59",
44
- "cli-color": "^2.0.1",
45
- "commander": "^9.0.0",
46
- "update-notifier": "^5.1.0"
43
+ "@squiz/component-cli-lib": "1.2.1-alpha.60",
44
+ "cli-color": "2.0.2",
45
+ "commander": "9.3.0",
46
+ "update-notifier": "5.1.0"
47
47
  },
48
48
  "devDependencies": {
49
- "@semantic-release/git": "^10.0.1",
50
- "@semantic-release/gitlab": "^7.0.4",
51
- "@semantic-release/npm": "^9.0.0",
52
- "@types/cli-color": "^2.0.2",
53
- "@types/jest": "^27.4.0",
54
- "@types/node": "^17.0.14",
55
- "@types/update-notifier": "^5.1.0",
56
- "@typescript-eslint/eslint-plugin": "^5.10.2",
57
- "@typescript-eslint/parser": "^5.10.2",
58
- "chalk": "^4.1.2",
59
- "codecov": "^3.8.3",
60
- "commitizen": "^4.2.4",
61
- "cz-conventional-changelog": "^3.3.0",
62
- "eslint": "^8.8.0",
63
- "eslint-config-prettier": "^8.3.0",
64
- "eslint-plugin-node": "^11.1.0",
65
- "eslint-plugin-prettier": "^4.0.0",
66
- "execa": "^5.1.1",
67
- "husky": "^7.0.4",
68
- "jest": "^27.4.7",
69
- "lint-staged": "^12.3.3",
70
- "prettier": "^2.5.1",
71
- "semantic-release": "^19.0.2",
72
- "ts-jest": "^27.1.3",
73
- "ts-node": "^10.4.0",
74
- "typescript": "^4.5.5"
49
+ "@semantic-release/git": "10.0.1",
50
+ "@semantic-release/gitlab": "9.3.2",
51
+ "@semantic-release/npm": "9.0.1",
52
+ "@types/cli-color": "2.0.2",
53
+ "@types/jest": "27.5.2",
54
+ "@types/node": "17.0.45",
55
+ "@types/update-notifier": "5.1.0",
56
+ "@typescript-eslint/eslint-plugin": "5.29.0",
57
+ "@typescript-eslint/parser": "5.29.0",
58
+ "chalk": "4.1.2",
59
+ "codecov": "3.8.3",
60
+ "commitizen": "4.2.4",
61
+ "cz-conventional-changelog": "3.3.0",
62
+ "eslint": "8.18.0",
63
+ "eslint-config-prettier": "8.5.0",
64
+ "eslint-plugin-node": "11.1.0",
65
+ "eslint-plugin-prettier": "4.0.0",
66
+ "execa": "5.1.1",
67
+ "husky": "7.0.4",
68
+ "jest": "27.5.1",
69
+ "lint-staged": "12.5.0",
70
+ "prettier": "2.7.1",
71
+ "semantic-release": "19.0.3",
72
+ "ts-jest": "27.1.5",
73
+ "ts-node": "10.8.1",
74
+ "typescript": "4.7.4"
75
75
  },
76
76
  "config": {
77
77
  "commitizen": {