diff --git a/.github/workflows/desktop.yml b/.github/workflows/desktop.yml index f90d5144..ae0a7280 100755 --- a/.github/workflows/desktop.yml +++ b/.github/workflows/desktop.yml @@ -117,6 +117,10 @@ jobs: # where the file is, the duplicate findings, the worklist suggestions - name: Test the rules of new items from local files run: node scripts/desktop-new-files.test.mjs + # *Local changes* over the whole working folder (#416): grouping by + # item and the actions per file and per selection + - name: Test the rules of the Local changes list + run: node scripts/desktop-local-changes.test.mjs # Update the BOM from the CAD file at check-in (#407): when the box is # offered, the result line - name: Test the check-in BOM rules diff --git a/CHANGELOG.md b/CHANGELOG.md index e6da7e95..f505b8ce 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,29 @@ see the notices in the README. ### Added +- **Desktop: one *Local changes* list for the whole working folder** (#416): + a worklist section next to *New on this computer* lists every file of the + working folder that is modified, outdated, in conflict, new (a companion + such as a STEP export) or missing, grouped by item – also a file changed + after clearing its read-only flag without a check-out, and files outdated + because somebody checked in a newer version, without opening their item. + Each row and each selection offers *Check out (keep my file)*, *Get latest*, + *Check in selected* (the *Check in all* flow), *Merge…* for a conflict and + *Folder*. The count joins the worklist badge on the rail. The scan + (`local_changes_scan`, `desktop/src/localchanges.rs`) compares + `state.json` with the disk first (no network; unchanged files are never + read, at most 512 MiB hashed per scan) and then the Workspace status of at + most 100 revisions (local changes first, then own check-outs, then a window + over the rest that moves on with every scan, so outdated files anywhere in + the folder are found over successive scans). The scan only compares: it + sets no read-only flags and writes no state. A check-in from the list takes + every changed file of the revision along (the check-in releases the + check-out; the dialog names the unticked ones and offers *Park* instead). + It runs when the worklist opens or is refreshed and when the window gets + the focus back (at most every 15 s), and at once after a check-out, + check-in, park, cancelled check-out or Get. The list rules are in + `desktop/ui/js/local-changes.js`, tested by + `scripts/desktop-local-changes.test.mjs`. - **Check-in: *Update the BOM from the CAD file*** (#407): a box in the web check-in form and the desktop app's *Check in…*, ticked by default every time, shown when the revision has an assembly whose references are read (an diff --git a/CLAUDE.md b/CLAUDE.md index a5c32464..5311c7b5 100755 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -221,6 +221,7 @@ desktop/ TeamCraft Desktop (Tauri 2, own Cargo project – never part list-thumbs.js = row pictures of Home and the search (lazy, IntersectionObserver, #420), crash.js = crash reports; desktop/src/workspace.rs + layout.rs = working folder, park, local changes; new-files.js + desktop/src/newfiles.rs = new items from local files, worklist *New on this computer* (#359); + local-changes.js + desktop/src/localchanges.rs = worklist *Local changes* over the whole working folder (#416); drop.js + drop-rules.js = files dropped from the file manager → *New* / *Add files…* (#418, dragDropEnabled); desktop/src/localserver.rs = *Try TeamCraft on this computer* (starts the bundled teamcraft-server local); desktop/src/policy.rs = managed deployment policies (registry / macOS profile / /etc/teamcraft, #378); diff --git a/README.md b/README.md index 441c49c8..b5b70975 100755 --- a/README.md +++ b/README.md @@ -326,7 +326,9 @@ end-to-end tests against a real PostgreSQL. or *Add files…*, new items straight from the files saved in the working folder (group and folder taken from where they are, duplicates refused, the worklist suggesting the parts and assemblies that - belong to no item yet), an Agent view, crash reports the user + belong to no item yet), a *Local changes* list of the whole working folder + (modified, outdated, conflicting and missing files with *Check out (keep my + file)*, *Get latest* and *Check in selected*), an Agent view, crash reports the user decides about, *Report…* on every error (a reviewed, redacted report with the action and its key inputs; nothing is sent without a click) and an update notice (never installs anything itself). The download *with local server* also runs a private test server with its own diff --git a/desktop/README.md b/desktop/README.md index 9525b2e6..0a422ef1 100755 --- a/desktop/README.md +++ b/desktop/README.md @@ -1,4 +1,4 @@ -A failed export never stops the check-in: the file goes without its STEP and the result says why. With exports the ticked files are uploaded first (parked), then exported, then checked in with the STEP files; *Cancel* during an export skips it and ends the CAD program the script started (`teamcraft-started-pid:` line, `taskkill`); rejected COM calls (`RPC_E_CALL_REJECTED`, `RPC_E_SERVERCALL_RETRYLATER`) are retried for a minute; the whole error output goes to `/export-logs/` (newest 20, 64 KiB each, local only) – #342 |# TeamCraft Desktop +# TeamCraft Desktop The rich client of TeamCraft for **Linux, macOS and Windows**: a navigation rail, a navigator tree of the project groups, object tabs with sub-tabs, a @@ -37,7 +37,7 @@ TeamCraft server – it is a client, not an offline copy. | Old workspaces | Folders of the older layout `///` (and `//`) are found after the sign-in; the app offers to move the files into the new layout – never overwriting a file, keeping files whose place is taken and listing them, writing every step to `.teamcraft/migration.log` | | Check in all | *Check in all* in the worklist (navigator and home page): the check-outs with local changes (modified, new, conflicting files) are listed first, with the offer to check them in with their files; then every check-out without local changes is checked in on the server (lock released, one revision at a time); check-outs with a conflict stay checked out. *Sign out* asks the same: *Check in and sign out*, *Park and sign out*, *Sign out anyway*. The list is the pure `layout::local_changes` | | Park | *Park…* (Workspace tab, *More ▾*, the check-in dialog): the ticked files go up as new versions through the upload endpoint (`POST …/files`) and the check-out **stays** – work in progress survives a lost laptop. After somebody else released your check-out, the Workspace tab shows *Released by X; your local changes are kept and need a new check-out* (`released` of the server's file status) | -| Native CAD previews | The preview image stored in Inventor and Solid Edge files in the Files tab, a picture of the 3D preview for NX and SOLIDWORKS files; on Windows *STEP* in the Workspace tab and *Create STEP exports … first* at check-in export with the installed Inventor or Solid Edge (COM automation through Windows PowerShell; uses your own licence); on every system SolidCraft designs (`.sc`) export through SolidCraft's `solidcraft-cli run --in … --out ….stp` (found through `SOLIDCRAFT_CLI`, `PATH` or the default install folders). A failed export never stops the check-in: the file goes without its STEP and the result says why | +| Native CAD previews | The preview image stored in Inventor and Solid Edge files in the Files tab, a picture of the 3D preview for NX and SOLIDWORKS files; on Windows *STEP* in the Workspace tab and *Create STEP exports … first* at check-in export with the installed Inventor or Solid Edge (COM automation through Windows PowerShell; uses your own licence); on every system SolidCraft designs (`.sc`) export through SolidCraft's `solidcraft-cli run --in … --out ….stp` (found through `SOLIDCRAFT_CLI`, `PATH` or the default install folders). A failed export never stops the check-in: the file goes without its STEP and the result says why. With exports the ticked files are uploaded first (parked), then exported, then checked in with the STEP files; *Cancel* during an export skips it and ends the CAD program the script started (`teamcraft-started-pid:` line, `taskkill`); rejected COM calls (`RPC_E_CALL_REJECTED`, `RPC_E_SERVERCALL_RETRYLATER`) are retried for a minute; the whole error output goes to `/export-logs/` (newest 20, 64 KiB each, local only) – #342 | | SolidCraft item data | *Item data* in the Workspace tab (SolidCraft designs of your check-out, not open in SolidCraft): `solidcraft-cli run