easy-soft-develop 2.2.15 → 2.2.19

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "easy-soft-develop",
3
- "version": "2.2.15",
3
+ "version": "2.2.19",
4
4
  "description": "",
5
5
  "homepage": "https://github.com/kityandhero/easy-soft-develop#readme",
6
6
  "bugs": {
@@ -89,8 +89,8 @@
89
89
  },
90
90
  "devDependencies": {
91
91
  "@changesets/cli": "^2.29.8",
92
- "@commitlint/cli": "^20.4.0",
93
- "@commitlint/config-conventional": "^20.4.0",
92
+ "@commitlint/cli": "^20.4.1",
93
+ "@commitlint/config-conventional": "^20.4.1",
94
94
  "@commitlint/config-pnpm-scopes": "^20.4.0",
95
95
  "commitizen": "^4.3.1",
96
96
  "conventional-changelog-conventionalcommits": "^9.1.0",
@@ -4,8 +4,8 @@ const {
4
4
 
5
5
  exports.run = async function (s, o) {
6
6
  const {
7
- _optionValues: { projectPath = '.', agent },
7
+ _optionValues: { projectPath = '.', targetPath = '', agent },
8
8
  } = o;
9
9
 
10
- await updateProjectFromRepository({ projectPath, agent });
10
+ await updateProjectFromRepository({ projectPath, targetPath, agent });
11
11
  };
@@ -175,9 +175,7 @@ async function handleTempPackagePath({ agent, packageUrl, repo }) {
175
175
  agentInfo = `download with agent "${agent}"`;
176
176
  }
177
177
 
178
- promptInfo(
179
- `try master management template ${repo} repository, ${agentInfo}.`,
180
- );
178
+ promptInfo(`try source template ${repo} repository, ${agentInfo}.`);
181
179
 
182
180
  if (agent) {
183
181
  promptSuccess(`agent: ${agent}`);
@@ -207,18 +205,21 @@ async function handleTempPackagePath({ agent, packageUrl, repo }) {
207
205
 
208
206
  zipPath = resolvePath(`./temp/zip/${zipFileName}.zip`);
209
207
 
210
- promptInfo(`master template zip file Path: "${zipPath}".`);
208
+ promptInfo(`source template zip file Path: "${zipPath}".`);
211
209
 
212
210
  return zipPath;
213
211
  }
214
212
 
215
- async function updateProjectFromRepository({ projectPath = '.', agent }) {
213
+ async function updateProjectFromRepository({
214
+ projectPath = '.',
215
+ targetPath = '',
216
+ agent,
217
+ }) {
216
218
  clearResource();
217
219
 
218
220
  const {
219
221
  repository = '',
220
222
  sourcePath = '',
221
- targetPath = '',
222
223
  syncConfigs = [],
223
224
  syncFolders = [],
224
225
  syncFiles = [],
@@ -226,7 +227,6 @@ async function updateProjectFromRepository({ projectPath = '.', agent }) {
226
227
  } = {
227
228
  repository: '',
228
229
  sourcePath: '',
229
- targetPath: '',
230
230
  syncConfigs: [],
231
231
  syncFolders: [],
232
232
  syncFiles: [],
@@ -242,9 +242,15 @@ async function updateProjectFromRepository({ projectPath = '.', agent }) {
242
242
  exit();
243
243
  }
244
244
 
245
+ if (checkStringIsEmpty(targetPath)) {
246
+ promptError('please input parameter targetPath');
247
+
248
+ exit();
249
+ }
250
+
245
251
  let zipPath = '';
246
252
 
247
- promptSuccess(`prepare to update from master template: `);
253
+ promptSuccess(`prepare to update from source template: `);
248
254
 
249
255
  promptLine();
250
256
 
@@ -1,7 +1,9 @@
1
1
  export function updateProjectFromRepository({
2
2
  projectPath,
3
+ targetPath,
3
4
  agent,
4
5
  }: {
5
6
  projectPath?: string | undefined;
7
+ targetPath?: string | undefined;
6
8
  agent: any;
7
9
  }): Promise<void>;