autoforce 0.1.29 → 0.1.30

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/.autoforce.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.1.29",
2
+ "version": "0.1.30",
3
3
  "backlogColumn": "Todo",
4
4
  "gitServices": "github",
5
5
  "gitModel": "githubflow",
package/CHANGELOG.md CHANGED
@@ -1,15 +1,21 @@
1
1
  # Versiones
2
2
 
3
+ 0.1.3X
4
+ ## Version 0.1.3X Bugfixing
5
+ - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.30)
6
+ - Cambios:
7
+ * Bugfixing de finish
8
+
9
+
10
+
3
11
  0.1.27
4
12
  ## Version 0.1.27
5
- - Fecha:
6
13
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.27)
7
14
  - Cambios:
8
15
  * Bugfixing del template folder
9
16
 
10
17
  0.1.26
11
18
  ## Version 0.1.26
12
- - Fecha:
13
19
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.26)
14
20
  - Cambios:
15
21
  * Bugfixing de create-scracth para autoforce-test
@@ -17,14 +23,12 @@
17
23
 
18
24
  0.1.25
19
25
  ## Version 0.1.25
20
- - Fecha:
21
26
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.25)
22
27
  - Cambios:
23
28
  * Bugfixing de carpeta de subtask para seguir con la automatizacion de autoforce-test
24
29
 
25
30
  0.1.24
26
31
  ## Version 0.1.24
27
- - Fecha:
28
32
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.24)
29
33
  - Cambios:
30
34
  * Funcionalidada nueva de Search Issues
@@ -33,20 +37,17 @@
33
37
 
34
38
  0.1.23
35
39
  ## Version 0.1.23
36
- - Fecha:
37
40
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.23)
38
41
  - Cambios:
39
42
  * Bugfixing para la suit de test autoforce-test
40
43
 
41
44
  ## Version 0.1.22
42
- - Fecha:
43
45
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.22)
44
46
  - Cambios:
45
47
  * [publish] que cierre el milestone de la version
46
48
  - https://github.com/sebastianclaros/autoforce/issues/35
47
49
 
48
50
  ## Version 0.1.20
49
- - Fecha:
50
51
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.20)
51
52
  - Cambios:
52
53
  * Test con instalacion de paquete
@@ -55,7 +56,6 @@
55
56
  - https://github.com/sebastianclaros/autoforce/issues/51
56
57
 
57
58
  ## Version 0.1.18
58
- - Fecha:
59
59
  - Paquete: [Descargar](https://www.npmjs.com/package/autoforce/v/0.1.18ra la placa
60
60
 
61
61
  TIPO CASO: Tarea Programada SF Deploy 254 Core & Industry 4 h)
@@ -180,6 +180,7 @@ export async function executeFunction(step) {
180
180
  let returnValue = false;
181
181
  const functionName = step.function;
182
182
  if (typeof taskFunctions[functionName] === 'function') {
183
+ taskFunctions[functionName].apply(taskFunctions);
183
184
  if (step.arguments && typeof step.arguments === 'object') {
184
185
  let mergedArgs = context.mergeArgs(step.arguments);
185
186
  if (!Array.isArray(mergedArgs)) {
@@ -248,7 +249,7 @@ export const taskFunctions = {
248
249
  return false;
249
250
  }
250
251
  executeShell("sf project retrieve start");
251
- return await this.validateScratch();
252
+ return await taskFunctions.validateScratch();
252
253
  },
253
254
  async validateScratch() {
254
255
  const salida = executeShell("sf project retrieve preview");
@@ -264,8 +265,8 @@ export const taskFunctions = {
264
265
  }
265
266
  const message = await askForCommitMessage();
266
267
  executeShell(`git add --all`);
267
- executeShell(`git commit -m ${message}`);
268
- return await this.checkCommitPending();
268
+ executeShell(`git commit -m "${message}"`);
269
+ return await taskFunctions.checkCommitPending();
269
270
  },
270
271
  async publishBranch() {
271
272
  try {
@@ -0,0 +1,12 @@
1
+ {
2
+ "name": "validate-code",
3
+ "description": "Valida la calidad del codigo y que cumpla buenas practicas",
4
+ "errorMessage": "Fallo el script de calidad y validacion de codigo, lea atentamente los motivos",
5
+ "steps": [
6
+ {
7
+ "name": "Eslint",
8
+ "command": "npx eslint"
9
+ }
10
+ ]
11
+ }
12
+
@@ -3,10 +3,6 @@
3
3
  "guards": ["isGitApi"],
4
4
  "description": "Comando para teminar un requerimiento. Automatiza las acciones cuando se termino el desarrollo de un requerimiento",
5
5
  "steps": [
6
- {
7
- "criteria": { "field": "isDevelopment", "value": true },
8
- "subtask": "validate-scratch"
9
- },
10
6
  {
11
7
  "name": "chequea si hay cambios sin commit",
12
8
  "function": "checkCommitPending",
@@ -32,10 +28,6 @@
32
28
  "name": "crea el pull request",
33
29
  "subtask": "create-pull",
34
30
  "description": "Crea el pull request"
35
- },
36
- {
37
- "criteria": { "field": "isDevelopment", "value": true },
38
- "subtask": "drop-scratch"
39
31
  }
40
32
  ]
41
33
  }
@@ -7,31 +7,13 @@
7
7
  "criteria": { "field": "isDevelopment", "value": true },
8
8
  "subtask": "validate-scratch"
9
9
  },
10
- {
11
- "name": "chequea si hay cambios sin commit",
12
- "function": "checkCommitPending",
13
- "description": "Chequea si hay algo sin commitear:\n ${salida}",
14
- "errorMessage": "Tiene modificaciones pendientes",
15
- "onError": "commitChanges"
16
- },
17
- {
18
- "criteria": { "field": "isDevelopment", "value": true },
19
- "subtask": "update-documentation"
20
- },
21
10
  {
22
11
  "criteria": { "field": "isDevelopment", "value": true },
23
12
  "subtask": "validate-code"
24
13
  },
25
14
  {
26
- "name": "publica la branch",
27
- "subtask": "publish-branch",
28
- "description": "Publica la branch en Remote",
29
- "errorMessage": "No se pudo publicar la branch"
30
- },
31
- {
32
- "name": "crea el pull request",
33
- "subtask": "create-pull",
34
- "description": "Crea el pull request"
15
+ "criteria": { "field": "isDevelopment", "value": true },
16
+ "subtask": "update-documentation"
35
17
  },
36
18
  {
37
19
  "criteria": { "field": "isDevelopment", "value": true },
@@ -0,0 +1,25 @@
1
+ {
2
+ "name": "finish",
3
+ "guards": ["isGitApi"],
4
+ "description": "Comando para teminar un requerimiento. Automatiza las acciones cuando se termino el desarrollo de un requerimiento",
5
+ "steps": [
6
+ {
7
+ "name": "chequea si hay cambios sin commit",
8
+ "function": "checkCommitPending",
9
+ "description": "Chequea si hay algo sin commitear:\n ${salida}",
10
+ "errorMessage": "Tiene modificaciones pendientes",
11
+ "onError": "commitChanges"
12
+ },
13
+ {
14
+ "name": "publica la branch",
15
+ "subtask": "publish-branch",
16
+ "description": "Publica la branch en Remote",
17
+ "errorMessage": "No se pudo publicar la branch"
18
+ },
19
+ {
20
+ "name": "crea el pull request",
21
+ "subtask": "create-pull",
22
+ "description": "Crea el pull request"
23
+ }
24
+ ]
25
+ }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "autoforce",
3
3
  "homepage": "https://sebastianclaros.github.io/autoforce",
4
4
  "private": false,
5
- "version": "0.1.29",
5
+ "version": "0.1.30",
6
6
  "keywords": [
7
7
  "Salesforce",
8
8
  "Automation",
@@ -34,7 +34,7 @@
34
34
  "test": "vitest"
35
35
  },
36
36
  "devDependencies": {
37
- "@eslint/js": "^8.56.0",
37
+ "@eslint/js": "^9.22.0",
38
38
  "@octokit/graphql": "^8.1.1",
39
39
  "@types/graphql": "^14.5.0",
40
40
  "@types/jest": "^29.5.14",
@@ -42,9 +42,10 @@
42
42
  "@types/node": "^22.8.1",
43
43
  "@typescript-eslint/eslint-plugin": "^5.62.0",
44
44
  "@typescript-eslint/parser": "^5.62.0",
45
- "eslint": "^8.56.0",
45
+ "eslint": "^9.22.0",
46
46
  "eslint-plugin-import": "^2.25.4",
47
47
  "eslint-plugin-jest": "^27.6.0",
48
+ "globals": "^16.0.0",
48
49
  "husky": "^7.0.4",
49
50
  "jest": "29.4.3",
50
51
  "jsdom": "^26.0.0",
@@ -54,7 +55,7 @@
54
55
  "ts-jest-mock-import-meta": "^1.2.1",
55
56
  "ts-node": "^10.9.2",
56
57
  "typescript": "^5.7.3",
57
- "typescript-eslint": "^8.3.0",
58
+ "typescript-eslint": "^8.26.1",
58
59
  "vitest": "^3.0.5"
59
60
  },
60
61
  "dependencies": {