pinokiod 1.2.28 → 1.2.29

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.
@@ -9,8 +9,7 @@ class Script {
9
9
  "branch": <git branch>,
10
10
  "latest": true|false,
11
11
  "uri": <script uri>,
12
- "params": {
13
- }
12
+ "params": <script args>
14
13
  }
15
14
  }
16
15
 
@@ -43,12 +42,20 @@ class Script {
43
42
 
44
43
  // switch branch
45
44
  if (req.params.branch) {
45
+ await kernel.bin.sh({
46
+ message: `git pull`,
47
+ path: kernel.path("api", folderName)
48
+ }, ondata)
46
49
  await kernel.bin.sh({
47
50
  message: `git switch ${req.params.branch}`,
48
51
  path: kernel.path("api", folderName)
49
52
  }, ondata)
50
53
  }
51
54
  if (req.params.hash) {
55
+ await kernel.bin.sh({
56
+ message: `git pull`,
57
+ path: kernel.path("api", folderName)
58
+ }, ondata)
52
59
  await kernel.bin.sh({
53
60
  message: `git switch --detach ${req.params.hash}`,
54
61
  path: kernel.path("api", folderName)
package/kernel/index.js CHANGED
@@ -117,7 +117,7 @@ class Kernel {
117
117
  }
118
118
  }
119
119
  } catch (e) {
120
- console.log(e)
120
+ // console.log(e)
121
121
  }
122
122
  }
123
123
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pinokiod",
3
- "version": "1.2.28",
3
+ "version": "1.2.29",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {