@orderful/droid 0.17.1 → 0.17.2
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/CHANGELOG.md +6 -0
- package/dist/bin/droid.js +7 -1
- package/dist/commands/tui.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/commands/tui.tsx +10 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @orderful/droid
|
|
2
2
|
|
|
3
|
+
## 0.17.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#92](https://github.com/Orderful/droid/pull/92) [`865ab78`](https://github.com/Orderful/droid/commit/865ab7894c49e168ea677d9906486ac1de29fcee) Thanks [@frytyler](https://github.com/frytyler)! - Fix auto-update for app not triggering when enabled
|
|
8
|
+
|
|
3
9
|
## 0.17.1
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/dist/bin/droid.js
CHANGED
|
@@ -1407,7 +1407,7 @@ async function updateCommand(tool, options) {
|
|
|
1407
1407
|
|
|
1408
1408
|
// src/commands/tui.tsx
|
|
1409
1409
|
import { render, Box as Box12, Text as Text13, useInput as useInput7, useApp as useApp2 } from "ink";
|
|
1410
|
-
import { useState as useState9 } from "react";
|
|
1410
|
+
import { useState as useState9, useEffect } from "react";
|
|
1411
1411
|
|
|
1412
1412
|
// src/commands/tui/constants.ts
|
|
1413
1413
|
var colors = {
|
|
@@ -2709,6 +2709,12 @@ function App() {
|
|
|
2709
2709
|
}
|
|
2710
2710
|
}
|
|
2711
2711
|
});
|
|
2712
|
+
useEffect(() => {
|
|
2713
|
+
const autoUpdateConfig = getAutoUpdateConfig();
|
|
2714
|
+
if (autoUpdateConfig.app && updateInfo.hasUpdate && view === "welcome" && !isUpdating) {
|
|
2715
|
+
handleUpdate();
|
|
2716
|
+
}
|
|
2717
|
+
}, [updateInfo.hasUpdate, view, isUpdating, handleUpdate]);
|
|
2712
2718
|
const proceedToNextView = () => {
|
|
2713
2719
|
if (!configExists()) {
|
|
2714
2720
|
setView("setup");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tui.d.ts","sourceRoot":"","sources":["../../src/commands/tui.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"tui.d.ts","sourceRoot":"","sources":["../../src/commands/tui.tsx"],"names":[],"mappings":"AAmdA,wBAAsB,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC,CAiBhD"}
|
package/package.json
CHANGED
package/src/commands/tui.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { render, Box, Text, useInput, useApp } from 'ink';
|
|
2
|
-
import { useState } from 'react';
|
|
2
|
+
import { useState, useEffect } from 'react';
|
|
3
3
|
import {
|
|
4
4
|
getBundledSkills,
|
|
5
5
|
installSkill,
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
updateSkill,
|
|
8
8
|
} from '../lib/skills';
|
|
9
9
|
import { getBundledTools, isToolInstalled, getToolUpdateStatus } from '../lib/tools';
|
|
10
|
-
import { configExists, loadConfig } from '../lib/config';
|
|
10
|
+
import { configExists, loadConfig, getAutoUpdateConfig } from '../lib/config';
|
|
11
11
|
import { Platform, type ConfigOption, type ToolManifest } from '../lib/types';
|
|
12
12
|
import { getVersion } from '../lib/version';
|
|
13
13
|
import { type Tab, type View } from './tui/types';
|
|
@@ -60,6 +60,14 @@ function App() {
|
|
|
60
60
|
},
|
|
61
61
|
});
|
|
62
62
|
|
|
63
|
+
// Auto-update app if enabled and update available
|
|
64
|
+
useEffect(() => {
|
|
65
|
+
const autoUpdateConfig = getAutoUpdateConfig();
|
|
66
|
+
if (autoUpdateConfig.app && updateInfo.hasUpdate && view === 'welcome' && !isUpdating) {
|
|
67
|
+
handleUpdate();
|
|
68
|
+
}
|
|
69
|
+
}, [updateInfo.hasUpdate, view, isUpdating, handleUpdate]);
|
|
70
|
+
|
|
63
71
|
const proceedToNextView = () => {
|
|
64
72
|
if (!configExists()) {
|
|
65
73
|
setView('setup');
|