Find: a house program from at-update's records, then PATH, never beside the caller (AGT-87) #3
Loading…
Reference in a new issue
No description provided.
Delete branch "find-house-program"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Work package: AGT-87
A caller that finds strip-owner (or tmux-strip) not running started it from its own install folder, else PATH. pull-request now installs on its own, with no strip-owner.exe beside it, and strip-owner is moving to an app of its own, so the caller's folder is the wrong place to look; and a long-running process's PATH can predate the install that put a program on it.
Removes
besideOrOnPathand the look in the caller's own folder: no program is taken from beside the caller any more.Adds
Find(name): the program in the first app's current folder at-update has registered (%LOCALAPPDATA%\at-update\registered\<app>.json'spath, apps in name order, the order at-update gives AT_HOME_PATH), thenexec.LookPath; an error names both the records folder and PATH when neither has it. The records list no programs per app, so it checks each app's folder for the file: strip-owner is found in at-home-tools' folder today and in its own app's once it moves, with nothing hardcoded. A record that doesn't read is skipped.StartProgram(name, args...): Find, then start it detached.Startnow uses it for strip-owner.Spawn(path, args...): the detached start on its own, for a caller starting itself (os.Executable()).start_test.go): strip-owner in at-home-tools' record; in its own app's record; a record winning over a PATH from before the install; no record having it and PATH having it, with a broken record skipped; no records folder at all; found nowhere, with both places in the error.Leaves alone
StartBesidekeeps its signature as a deprecated alias ofStartProgram, so the strip-owner and tmux-strip moves (AHT-278, AHT-279), whose branches call it, build unchanged and get the new lookup.connect's retry and the Low-integrity rule: a Low process still never starts strip-owner.