sftp-push-sync 2.1.5 → 2.3.0
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/README.md +3 -2
- package/package.json +1 -1
- package/src/core/SftpPushSyncApp.mjs +5 -1
package/README.md
CHANGED
|
@@ -157,7 +157,7 @@ There are 7 steps to follow:
|
|
|
157
157
|
|
|
158
158
|
- Phase 1: Scan local files
|
|
159
159
|
- Phase 2: Scan remote files
|
|
160
|
-
- Phase 3: Compare &
|
|
160
|
+
- Phase 3: Compare & Decide
|
|
161
161
|
- Phase 4: Removing orphaned remote files
|
|
162
162
|
- Phase 5: Preparing remote directories
|
|
163
163
|
- Phase 6: Apply changes
|
|
@@ -258,7 +258,8 @@ However, it should also manage directories:
|
|
|
258
258
|
|
|
259
259
|
You can safely delete the local cache at any time. The first analysis will then take longer, because remote hashes will be streamed again. After that, everything will run fast.
|
|
260
260
|
|
|
261
|
-
Note: The first run always takes a while, especially with lots of media – so be patient! Once the cache is full, it will be faster.
|
|
261
|
+
Note 1: The first run always takes a while, especially with lots of media – so be patient! Once the cache is full, it will be faster.
|
|
262
|
+
Note 2: Reliability and accuracy are more important to me than speed.
|
|
262
263
|
|
|
263
264
|
## Example Output
|
|
264
265
|
|
package/package.json
CHANGED
|
@@ -730,6 +730,10 @@ export class SftpPushSyncApp {
|
|
|
730
730
|
port: this.connection.port,
|
|
731
731
|
username: this.connection.user,
|
|
732
732
|
password: this.connection.password,
|
|
733
|
+
// Keep-Alive to prevent server disconnection during long operations
|
|
734
|
+
keepaliveInterval: 10000, // Send keepalive every 10 seconds
|
|
735
|
+
keepaliveCountMax: 10, // Allow up to 10 missed keepalives before disconnect
|
|
736
|
+
readyTimeout: 30000, // 30s timeout for initial connection
|
|
733
737
|
});
|
|
734
738
|
connected = true;
|
|
735
739
|
this.log(`${TAB_A}${pc.green("✔ Connected to SFTP.")}`);
|
|
@@ -838,7 +842,7 @@ export class SftpPushSyncApp {
|
|
|
838
842
|
this.log("");
|
|
839
843
|
|
|
840
844
|
// Phase 3 – Analyse Differences (delegiert an Helper)
|
|
841
|
-
this.log(pc.bold(pc.cyan("🔎 Phase 3: Compare &
|
|
845
|
+
this.log(pc.bold(pc.cyan("🔎 Phase 3: Compare & Decide …")));
|
|
842
846
|
|
|
843
847
|
const { getLocalHash, getRemoteHash, save: saveCache } = this.hashCache;
|
|
844
848
|
|