From 70271deedef12c12e7b8f1165a1559693f37c443 Mon Sep 17 00:00:00 2001 From: OpenXER Maintainers <207556411+clachance14@users.noreply.github.com> Date: Wed, 25 Nov 2026 14:54:28 -0600 Subject: [PATCH] Initial public release of OpenXER 0.1.0 --- .gitattributes | 7 + .github/ISSUE_TEMPLATE/bug_report.yml | 42 + .github/ISSUE_TEMPLATE/config.yml | 5 + .github/ISSUE_TEMPLATE/feature_request.yml | 21 + .github/PULL_REQUEST_TEMPLATE.md | 15 + .github/workflows/ci.yml | 72 + .github/workflows/release.yml | 132 + .gitignore | 22 + AGENTS.md | 193 + CHANGELOG.md | 100 + CLAUDE.md | 1 + CODE_OF_CONDUCT.md | 13 + CONTRIBUTING.md | 76 + Cargo.lock | 4598 + Cargo.toml | 26 + DESIGN.md | 127 + LICENSE-APACHE | 176 + LICENSE-MIT | 27 + README.md | 321 + ROADMAP.md | 33 + SECURITY.md | 27 + THIRD_PARTY.md | 2394 + assets/icons/16/ACCUNT16.png | Bin 0 -> 304 bytes assets/icons/16/ACTCTP16.png | Bin 0 -> 287 bytes assets/icons/16/ACTCUR16.png | Bin 0 -> 407 bytes assets/icons/16/ACTINP16.png | Bin 0 -> 145 bytes assets/icons/16/ACTIPP16.png | Bin 0 -> 311 bytes assets/icons/16/ACTPRM16.png | Bin 0 -> 287 bytes assets/icons/16/ACTRJ16.png | Bin 0 -> 124 bytes assets/icons/16/ACTRJP16.png | Bin 0 -> 287 bytes assets/icons/16/ADD16.png | Bin 0 -> 300 bytes assets/icons/16/ALGNCT16.png | Bin 0 -> 192 bytes assets/icons/16/ALGNLT16.png | Bin 0 -> 186 bytes assets/icons/16/ALGNRT16.png | Bin 0 -> 173 bytes assets/icons/16/APPLY16.png | Bin 0 -> 305 bytes assets/icons/16/ARHORZ16.png | Bin 0 -> 203 bytes assets/icons/16/ARVERT16.png | Bin 0 -> 215 bytes assets/icons/16/ASSIGN16.png | Bin 0 -> 252 bytes assets/icons/16/ATV16.png | Bin 0 -> 124 bytes assets/icons/16/ATVCDE16.png | Bin 0 -> 350 bytes assets/icons/16/ATVCPT16.png | Bin 0 -> 124 bytes assets/icons/16/ATVDET16.png | Bin 0 -> 209 bytes assets/icons/16/ATVGRD16.png | Bin 0 -> 174 bytes assets/icons/16/ATVHST16.png | Bin 0 -> 178 bytes assets/icons/16/ATVLKC16.png | Bin 0 -> 124 bytes assets/icons/16/ATVLKR16.png | Bin 0 -> 233 bytes assets/icons/16/ATVMM.png | Bin 0 -> 510 bytes assets/icons/16/ATVNET16.png | Bin 0 -> 192 bytes assets/icons/16/ATVNWT16.png | Bin 0 -> 184 bytes assets/icons/16/ATVPRD16.png | Bin 0 -> 156 bytes assets/icons/16/ATVSPD16.png | Bin 0 -> 210 bytes assets/icons/16/ATVSUC16.png | Bin 0 -> 164 bytes assets/icons/16/BACK16.png | Bin 0 -> 414 bytes assets/icons/16/BACK3D16.png | Bin 0 -> 452 bytes assets/icons/16/BASLNE16.png | Bin 0 -> 164 bytes assets/icons/16/BLANK16.png | Bin 0 -> 76 bytes assets/icons/16/BRGRPH16.png | Bin 0 -> 214 bytes assets/icons/16/CANCEL16.png | Bin 0 -> 487 bytes assets/icons/16/CBRANCH.png | Bin 0 -> 175 bytes assets/icons/16/CDROM.png | Bin 0 -> 192 bytes assets/icons/16/CHKBX016.png | Bin 0 -> 170 bytes assets/icons/16/CHKBX116.png | Bin 0 -> 350 bytes assets/icons/16/CHKBX216.png | Bin 0 -> 354 bytes assets/icons/16/CHRTLY16.png | Bin 0 -> 144 bytes assets/icons/16/CHRTVW16.png | Bin 0 -> 182 bytes assets/icons/16/CLEAF.png | Bin 0 -> 263 bytes assets/icons/16/CLNDR16.png | Bin 0 -> 346 bytes assets/icons/16/CLOSE16.png | Bin 0 -> 329 bytes assets/icons/16/CLOSEDFOLDER.png | Bin 0 -> 176 bytes assets/icons/16/COLALL16.png | Bin 0 -> 103 bytes assets/icons/16/COLLAY16.png | Bin 0 -> 226 bytes assets/icons/16/COPY16.png | Bin 0 -> 374 bytes assets/icons/16/CTREE.png | Bin 0 -> 199 bytes assets/icons/16/CURRENTFOLDER.png | Bin 0 -> 285 bytes assets/icons/16/CUT16.png | Bin 0 -> 449 bytes assets/icons/16/CXEDIT_GLYPH_ERROR.png | Bin 0 -> 435 bytes assets/icons/16/CXEDIT_GLYPH_INFO.png | Bin 0 -> 430 bytes assets/icons/16/CXEDIT_GLYPH_WARNING.png | Bin 0 -> 334 bytes assets/icons/16/DATRNG16.png | Bin 0 -> 220 bytes assets/icons/16/DELETE16.png | Bin 0 -> 269 bytes assets/icons/16/DELIV16.png | Bin 0 -> 645 bytes assets/icons/16/DIALOG16.png | Bin 0 -> 290 bytes assets/icons/16/DIRCTY16.png | Bin 0 -> 364 bytes assets/icons/16/DLTARW16.png | Bin 0 -> 275 bytes assets/icons/16/DLVCUR16.png | Bin 0 -> 660 bytes assets/icons/16/DOCCUR16.png | Bin 0 -> 386 bytes assets/icons/16/DOCMNT16.png | Bin 0 -> 246 bytes assets/icons/16/DOCMNTMM.png | Bin 0 -> 741 bytes assets/icons/16/DRTARW16.png | Bin 0 -> 272 bytes assets/icons/16/DWNARW16.png | Bin 0 -> 217 bytes assets/icons/16/EDITRC16.png | Bin 0 -> 421 bytes assets/icons/16/EPS16.png | Bin 0 -> 583 bytes assets/icons/16/ERRORDG.png | Bin 0 -> 1354 bytes assets/icons/16/ESTMAT16.png | Bin 0 -> 309 bytes assets/icons/16/EXECUTABLE.png | Bin 0 -> 144 bytes assets/icons/16/EXPALL16.png | Bin 0 -> 117 bytes assets/icons/16/EXPENSMM.png | Bin 0 -> 774 bytes assets/icons/16/EXPNSE16.png | Bin 0 -> 215 bytes assets/icons/16/EXPORT16.png | Bin 0 -> 378 bytes assets/icons/16/FACTOR16.png | Bin 0 -> 279 bytes assets/icons/16/FACTVL16.png | Bin 0 -> 205 bytes assets/icons/16/FILDWN16.png | Bin 0 -> 146 bytes assets/icons/16/FILTER16.png | Bin 0 -> 402 bytes assets/icons/16/FIND16.png | Bin 0 -> 288 bytes assets/icons/16/FINISH16.png | Bin 0 -> 136 bytes assets/icons/16/FLOPPY.png | Bin 0 -> 196 bytes assets/icons/16/FTCLRS16.png | Bin 0 -> 461 bytes assets/icons/16/GANTT16.png | Bin 0 -> 213 bytes assets/icons/16/GLOBAL16.png | Bin 0 -> 591 bytes assets/icons/16/GLOBVW16.png | Bin 0 -> 699 bytes assets/icons/16/GRPSRT16.png | Bin 0 -> 171 bytes assets/icons/16/HARD.png | Bin 0 -> 163 bytes assets/icons/16/HDETHZ16.png | Bin 0 -> 347 bytes assets/icons/16/HDETVT16.png | Bin 0 -> 297 bytes assets/icons/16/HELP16.png | Bin 0 -> 502 bytes assets/icons/16/HELP3D16.png | Bin 0 -> 282 bytes assets/icons/16/HIDEDT16.png | Bin 0 -> 328 bytes assets/icons/16/HINT16.png | Bin 0 -> 282 bytes assets/icons/16/HINT3D16.png | Bin 0 -> 502 bytes assets/icons/16/HLPCNT16.png | Bin 0 -> 277 bytes assets/icons/16/HOME16.png | Bin 0 -> 338 bytes assets/icons/16/HSTGRM16.png | Bin 0 -> 179 bytes assets/icons/16/ID_1001.png | Bin 0 -> 260 bytes assets/icons/16/ID_1002.png | Bin 0 -> 507 bytes assets/icons/16/ID_1005.png | Bin 0 -> 172 bytes assets/icons/16/IMG_ICO_EPS.png | Bin 0 -> 464 bytes assets/icons/16/IMG_ICO_EPS_CHECKED.png | Bin 0 -> 623 bytes assets/icons/16/IMG_ICO_PROJ_CLOSED.png | Bin 0 -> 188 bytes .../icons/16/IMG_ICO_PROJ_CLOSED_CHECKED.png | Bin 0 -> 390 bytes .../16/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png | Bin 0 -> 566 bytes .../icons/16/IMG_ICO_PROJ_CLOSED_WHATIF.png | Bin 0 -> 378 bytes assets/icons/16/IMG_ICO_PROJ_OPEN.png | Bin 0 -> 324 bytes assets/icons/16/IMG_ICO_PROJ_OPEN_CHECKED.png | Bin 0 -> 514 bytes .../16/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png | Bin 0 -> 646 bytes assets/icons/16/IMG_ICO_PROJ_OPEN_WHATIF.png | Bin 0 -> 471 bytes assets/icons/16/IMPORT16.png | Bin 0 -> 439 bytes assets/icons/16/INFODG.png | Bin 0 -> 1283 bytes assets/icons/16/ISSUE16.png | Bin 0 -> 420 bytes assets/icons/16/ISSUESMM.png | Bin 0 -> 830 bytes assets/icons/16/JUMP16.png | Bin 0 -> 309 bytes assets/icons/16/KNOWNFILE.png | Bin 0 -> 253 bytes assets/icons/16/LEVELR16.png | Bin 0 -> 222 bytes assets/icons/16/LFTARW16.png | Bin 0 -> 214 bytes assets/icons/16/LOCK16.png | Bin 0 -> 365 bytes assets/icons/16/MAINICON.png | Bin 0 -> 637 bytes assets/icons/16/MEMO16.png | Bin 0 -> 356 bytes assets/icons/16/MEMOEM16.png | Bin 0 -> 334 bytes assets/icons/16/MEMOFL16.png | Bin 0 -> 357 bytes assets/icons/16/MSG_ERROR.png | Bin 0 -> 2228 bytes assets/icons/16/MSG_INFO.png | Bin 0 -> 2194 bytes assets/icons/16/MSG_WARNING.png | Bin 0 -> 1792 bytes assets/icons/16/MTHLNKMM.png | Bin 0 -> 543 bytes assets/icons/16/NETWORK.png | Bin 0 -> 199 bytes assets/icons/16/NEW16.png | Bin 0 -> 246 bytes assets/icons/16/NEXT16.png | Bin 0 -> 338 bytes assets/icons/16/NEXT3D16.png | Bin 0 -> 370 bytes assets/icons/16/NLRCUR16.png | Bin 0 -> 685 bytes assets/icons/16/NLRSRC16.png | Bin 0 -> 621 bytes assets/icons/16/NLRSU16.png | Bin 0 -> 749 bytes assets/icons/16/NLRSUC16.png | Bin 0 -> 759 bytes assets/icons/16/OBS16.png | Bin 0 -> 420 bytes assets/icons/16/OBSMM.png | Bin 0 -> 530 bytes assets/icons/16/OBSROT16.png | Bin 0 -> 411 bytes assets/icons/16/OK16.png | Bin 0 -> 499 bytes assets/icons/16/OPEN16.png | Bin 0 -> 424 bytes assets/icons/16/OPENFOLDER.png | Bin 0 -> 308 bytes assets/icons/16/OPTBAR16.png | Bin 0 -> 204 bytes assets/icons/16/OVRHD16.png | Bin 0 -> 162 bytes assets/icons/16/OXACPBACK16.png | Bin 0 -> 269 bytes assets/icons/16/OXACPFEWER16.png | Bin 0 -> 199 bytes assets/icons/16/OXACPFWD16.png | Bin 0 -> 252 bytes assets/icons/16/OXACPGROUP16.png | Bin 0 -> 129 bytes assets/icons/16/OXACPMORE16.png | Bin 0 -> 252 bytes assets/icons/16/OXACPRES16.png | Bin 0 -> 404 bytes assets/icons/16/OXACPSELECT16.png | Bin 0 -> 306 bytes assets/icons/16/OXACPSHOW16.png | Bin 0 -> 196 bytes assets/icons/16/OXBOLD16.png | Bin 0 -> 413 bytes assets/icons/16/OXBULLET16.png | Bin 0 -> 173 bytes assets/icons/16/OXCLRFMT16.png | Bin 0 -> 482 bytes assets/icons/16/OXITALIC16.png | Bin 0 -> 278 bytes assets/icons/16/OXLINENO16.png | Bin 0 -> 356 bytes assets/icons/16/OXLINK16.png | Bin 0 -> 312 bytes assets/icons/16/OXMATRSRC16.png | Bin 0 -> 151 bytes assets/icons/16/OXNUMBER16.png | Bin 0 -> 347 bytes assets/icons/16/OXONLHLP16.png | Bin 0 -> 636 bytes assets/icons/16/OXPRGLIN16.png | Bin 0 -> 452 bytes assets/icons/16/OXRPTEDT16.png | Bin 0 -> 444 bytes assets/icons/16/OXRPTWIZ16.png | Bin 0 -> 442 bytes assets/icons/16/OXRUNBAT16.png | Bin 0 -> 590 bytes assets/icons/16/OXSPOTLT16.png | Bin 0 -> 399 bytes assets/icons/16/OXTABHZ16.png | Bin 0 -> 131 bytes assets/icons/16/OXTABMG16.png | Bin 0 -> 271 bytes assets/icons/16/OXTABVT16.png | Bin 0 -> 136 bytes assets/icons/16/OXUNDERL16.png | Bin 0 -> 275 bytes assets/icons/16/OXUNLINK16.png | Bin 0 -> 373 bytes assets/icons/16/OXWHTNW16.png | Bin 0 -> 415 bytes assets/icons/16/PASTE16.png | Bin 0 -> 386 bytes assets/icons/16/PCDCUR16.png | Bin 0 -> 307 bytes assets/icons/16/PEGACT16.png | Bin 0 -> 470 bytes assets/icons/16/PEGTS16.png | Bin 0 -> 455 bytes assets/icons/16/PGSETP16.png | Bin 0 -> 168 bytes assets/icons/16/PJOCKO16.png | Bin 0 -> 514 bytes assets/icons/16/PJOWCO16.png | Bin 0 -> 633 bytes assets/icons/16/PJOWIF16.png | Bin 0 -> 464 bytes assets/icons/16/PRCDUR16.png | Bin 0 -> 184 bytes assets/icons/16/PREVIEWGLYPH.png | Bin 0 -> 501 bytes assets/icons/16/PRINT16.png | Bin 0 -> 264 bytes assets/icons/16/PRIVLG16.png | Bin 0 -> 243 bytes assets/icons/16/PRJCKO16.png | Bin 0 -> 397 bytes assets/icons/16/PRJOPN16.png | Bin 0 -> 324 bytes assets/icons/16/PRJWCO16.png | Bin 0 -> 571 bytes assets/icons/16/PRJWIF16.png | Bin 0 -> 381 bytes assets/icons/16/PROFLE16.png | Bin 0 -> 436 bytes assets/icons/16/PROJCD16.png | Bin 0 -> 331 bytes assets/icons/16/PROJCT16.png | Bin 0 -> 190 bytes assets/icons/16/PROJMM.png | Bin 0 -> 605 bytes assets/icons/16/PRTFGL16.png | Bin 0 -> 526 bytes assets/icons/16/PRTFLO16.png | Bin 0 -> 224 bytes assets/icons/16/PRTFOP16.png | Bin 0 -> 207 bytes assets/icons/16/PRTOGB16.png | Bin 0 -> 567 bytes assets/icons/16/PRVIEW16.png | Bin 0 -> 515 bytes assets/icons/16/QALITY16.png | Bin 0 -> 158 bytes assets/icons/16/QUESTNDG.png | Bin 0 -> 1730 bytes assets/icons/16/QULCUR16.png | Bin 0 -> 287 bytes assets/icons/16/RADBX016.png | Bin 0 -> 406 bytes assets/icons/16/RADBX116.png | Bin 0 -> 498 bytes assets/icons/16/RAM.png | Bin 0 -> 135 bytes assets/icons/16/REFRSH16.png | Bin 0 -> 491 bytes assets/icons/16/REMOVE16.png | Bin 0 -> 387 bytes assets/icons/16/REORGZ16.png | Bin 0 -> 325 bytes assets/icons/16/REPLAC16.png | Bin 0 -> 441 bytes assets/icons/16/REPORT16.png | Bin 0 -> 215 bytes assets/icons/16/REPRTSMM.png | Bin 0 -> 736 bytes assets/icons/16/RESHST16.png | Bin 0 -> 425 bytes assets/icons/16/RES_RL16.png | Bin 0 -> 798 bytes assets/icons/16/RGTARW16.png | Bin 0 -> 194 bytes assets/icons/16/RISK16.png | Bin 0 -> 283 bytes assets/icons/16/RISKSMM.png | Bin 0 -> 587 bytes assets/icons/16/RLATSK16.png | Bin 0 -> 361 bytes assets/icons/16/ROLCUR16.png | Bin 0 -> 647 bytes assets/icons/16/ROLE16.png | Bin 0 -> 577 bytes assets/icons/16/ROLEOP16.png | Bin 0 -> 406 bytes assets/icons/16/ROLESMM.png | Bin 0 -> 818 bytes assets/icons/16/RORGAL16.png | Bin 0 -> 290 bytes assets/icons/16/RPADDG16.png | Bin 0 -> 200 bytes assets/icons/16/RPADDI16.png | Bin 0 -> 345 bytes assets/icons/16/RPADDL16.png | Bin 0 -> 200 bytes assets/icons/16/RPADDR16.png | Bin 0 -> 167 bytes assets/icons/16/RPADDT16.png | Bin 0 -> 345 bytes assets/icons/16/RPEDIT16.png | Bin 0 -> 202 bytes assets/icons/16/RPEXP16.png | Bin 0 -> 312 bytes assets/icons/16/RPIMP16.png | Bin 0 -> 316 bytes assets/icons/16/RPPGF16.png | Bin 0 -> 229 bytes assets/icons/16/RPPGL16.png | Bin 0 -> 234 bytes assets/icons/16/RPPGN16.png | Bin 0 -> 218 bytes assets/icons/16/RPPGP16.png | Bin 0 -> 217 bytes assets/icons/16/RPTGLB16.png | Bin 0 -> 558 bytes assets/icons/16/RPTGRP16.png | Bin 0 -> 312 bytes assets/icons/16/RPTWZD16.png | Bin 0 -> 402 bytes assets/icons/16/RSATSK16.png | Bin 0 -> 361 bytes assets/icons/16/RSCNWK16.png | Bin 0 -> 470 bytes assets/icons/16/RSCSPD16.png | Bin 0 -> 418 bytes assets/icons/16/RSRC16.png | Bin 0 -> 387 bytes assets/icons/16/RSRCCD16.png | Bin 0 -> 451 bytes assets/icons/16/RSRCOP16.png | Bin 0 -> 388 bytes assets/icons/16/RSRCPLMM.png | Bin 0 -> 1455 bytes assets/icons/16/RSRCPR16.png | Bin 0 -> 463 bytes assets/icons/16/RSRCU16.png | Bin 0 -> 565 bytes assets/icons/16/RSRCUC16.png | Bin 0 -> 601 bytes assets/icons/16/RSRCUR16.png | Bin 0 -> 451 bytes assets/icons/16/RUN16.png | Bin 0 -> 374 bytes assets/icons/16/RUNBAT16.png | Bin 0 -> 315 bytes assets/icons/16/SAVE16.png | Bin 0 -> 211 bytes assets/icons/16/SAVEAS16.png | Bin 0 -> 296 bytes assets/icons/16/SCHDUL16.png | Bin 0 -> 645 bytes assets/icons/16/SEARCH16.png | Bin 0 -> 317 bytes assets/icons/16/SELBX016.png | Bin 0 -> 202 bytes assets/icons/16/SELBX116.png | Bin 0 -> 389 bytes assets/icons/16/SELECT16.png | Bin 0 -> 276 bytes assets/icons/16/SHOWRELBTN16.png | Bin 0 -> 195 bytes assets/icons/16/SHOWRESCURVES16.png | Bin 0 -> 398 bytes assets/icons/16/SPLCHK16.png | Bin 0 -> 391 bytes assets/icons/16/SPNDWN16.png | Bin 0 -> 107 bytes assets/icons/16/SPNUP16.png | Bin 0 -> 101 bytes assets/icons/16/STDCUR16.png | Bin 0 -> 560 bytes assets/icons/16/STEPD16.png | Bin 0 -> 430 bytes assets/icons/16/STEPND16.png | Bin 0 -> 222 bytes assets/icons/16/STNDRD16.png | Bin 0 -> 414 bytes assets/icons/16/SUBMIT16.png | Bin 0 -> 341 bytes assets/icons/16/THRHLDMM.png | Bin 0 -> 812 bytes assets/icons/16/THSHLD16.png | Bin 0 -> 205 bytes assets/icons/16/TMAPVL16.png | Bin 0 -> 638 bytes assets/icons/16/TMPLAT16.png | Bin 0 -> 160 bytes assets/icons/16/TMSHT16.png | Bin 0 -> 435 bytes assets/icons/16/TPLGIN16.png | Bin 0 -> 275 bytes assets/icons/16/TPOOL16.png | Bin 0 -> 212 bytes assets/icons/16/TRACK16.png | Bin 0 -> 353 bytes assets/icons/16/TRACKMM.png | Bin 0 -> 1901 bytes assets/icons/16/UNDO16.png | Bin 0 -> 277 bytes assets/icons/16/UNKNOWNFILE.png | Bin 0 -> 376 bytes assets/icons/16/UNLOCK16.png | Bin 0 -> 281 bytes assets/icons/16/UNSEL16.png | Bin 0 -> 398 bytes assets/icons/16/UPARW16.png | Bin 0 -> 113 bytes assets/icons/16/USER16.png | Bin 0 -> 390 bytes assets/icons/16/USRCUR16.png | Bin 0 -> 472 bytes assets/icons/16/VIEWS16.png | Bin 0 -> 519 bytes assets/icons/16/VMENU_ICO_ALIGN_CENTER.png | Bin 0 -> 192 bytes assets/icons/16/VMENU_ICO_ALIGN_LEFT.png | Bin 0 -> 183 bytes assets/icons/16/VMENU_ICO_ALIGN_RIGHT.png | Bin 0 -> 184 bytes assets/icons/16/VMENU_ICO_ARRANGE_HORZ.png | Bin 0 -> 200 bytes assets/icons/16/VMENU_ICO_ARRANGE_VERT.png | Bin 0 -> 187 bytes .../icons/16/VMENU_ICO_CHART_FONT_COLOR.png | Bin 0 -> 516 bytes assets/icons/16/VMENU_ICO_CHART_LAYOUT.png | Bin 0 -> 155 bytes assets/icons/16/VMENU_ICO_CHART_VIEW.png | Bin 0 -> 186 bytes assets/icons/16/VMENU_ICO_COLLAPSE_ALL.png | Bin 0 -> 121 bytes assets/icons/16/VMENU_ICO_COLLAPSE_TO.png | Bin 0 -> 117 bytes assets/icons/16/VMENU_ICO_COLUMNS.png | Bin 0 -> 196 bytes assets/icons/16/VMENU_ICO_COPY.png | Bin 0 -> 361 bytes assets/icons/16/VMENU_ICO_CUT.png | Bin 0 -> 473 bytes assets/icons/16/VMENU_ICO_DELETE.png | Bin 0 -> 331 bytes assets/icons/16/VMENU_ICO_EXPAND_ALL.png | Bin 0 -> 104 bytes assets/icons/16/VMENU_ICO_FILLDOWN.png | Bin 0 -> 205 bytes assets/icons/16/VMENU_ICO_FILTER.png | Bin 0 -> 379 bytes assets/icons/16/VMENU_ICO_FIND.png | Bin 0 -> 223 bytes assets/icons/16/VMENU_ICO_GRID_FONT_COLOR.png | Bin 0 -> 435 bytes assets/icons/16/VMENU_ICO_GROUPING.png | Bin 0 -> 167 bytes assets/icons/16/VMENU_ICO_INSERT.png | Bin 0 -> 326 bytes assets/icons/16/VMENU_ICO_NEW.png | Bin 0 -> 280 bytes assets/icons/16/VMENU_ICO_OPEN.png | Bin 0 -> 415 bytes assets/icons/16/VMENU_ICO_PASTE.png | Bin 0 -> 347 bytes assets/icons/16/VMENU_ICO_PRINT.png | Bin 0 -> 240 bytes assets/icons/16/VMENU_ICO_PRINT_PREVIEW.png | Bin 0 -> 500 bytes assets/icons/16/VMENU_ICO_SAVE.png | Bin 0 -> 209 bytes assets/icons/16/VMENU_ICO_SPELL_CHECK.png | Bin 0 -> 391 bytes assets/icons/16/VMENU_ICO_ZOOM_BEST_FIT.png | Bin 0 -> 513 bytes assets/icons/16/VMENU_ICO_ZOOM_IN.png | Bin 0 -> 421 bytes assets/icons/16/VMENU_ICO_ZOOM_OUT.png | Bin 0 -> 424 bytes assets/icons/16/WARNDG.png | Bin 0 -> 1356 bytes assets/icons/16/WBS16.png | Bin 0 -> 206 bytes assets/icons/16/WBSLKC16.png | Bin 0 -> 210 bytes assets/icons/16/WBSLKR16.png | Bin 0 -> 277 bytes assets/icons/16/WBSMM.png | Bin 0 -> 243 bytes assets/icons/16/WBSROT16.png | Bin 0 -> 226 bytes assets/icons/16/WIZARD16.png | Bin 0 -> 235 bytes assets/icons/16/ZOOMIN16.png | Bin 0 -> 422 bytes assets/icons/16/ZOOMOT16.png | Bin 0 -> 426 bytes assets/icons/16/ZOOMTF16.png | Bin 0 -> 515 bytes assets/icons/32/ACCUNT16.png | Bin 0 -> 443 bytes assets/icons/32/ACTCTP16.png | Bin 0 -> 512 bytes assets/icons/32/ACTCUR16.png | Bin 0 -> 723 bytes assets/icons/32/ACTINP16.png | Bin 0 -> 172 bytes assets/icons/32/ACTIPP16.png | Bin 0 -> 525 bytes assets/icons/32/ACTPRM16.png | Bin 0 -> 510 bytes assets/icons/32/ACTRJ16.png | Bin 0 -> 152 bytes assets/icons/32/ACTRJP16.png | Bin 0 -> 510 bytes assets/icons/32/ADD16.png | Bin 0 -> 408 bytes assets/icons/32/ALGNCT16.png | Bin 0 -> 275 bytes assets/icons/32/ALGNLT16.png | Bin 0 -> 267 bytes assets/icons/32/ALGNRT16.png | Bin 0 -> 270 bytes assets/icons/32/APPLY16.png | Bin 0 -> 376 bytes assets/icons/32/ARHORZ16.png | Bin 0 -> 311 bytes assets/icons/32/ARVERT16.png | Bin 0 -> 316 bytes assets/icons/32/ASSIGN16.png | Bin 0 -> 290 bytes assets/icons/32/ATV16.png | Bin 0 -> 152 bytes assets/icons/32/ATVCDE16.png | Bin 0 -> 588 bytes assets/icons/32/ATVCPT16.png | Bin 0 -> 152 bytes assets/icons/32/ATVDET16.png | Bin 0 -> 304 bytes assets/icons/32/ATVGRD16.png | Bin 0 -> 207 bytes assets/icons/32/ATVHST16.png | Bin 0 -> 220 bytes assets/icons/32/ATVLKC16.png | Bin 0 -> 152 bytes assets/icons/32/ATVLKR16.png | Bin 0 -> 333 bytes assets/icons/32/ATVMM.png | Bin 0 -> 793 bytes assets/icons/32/ATVNET16.png | Bin 0 -> 277 bytes assets/icons/32/ATVNWT16.png | Bin 0 -> 278 bytes assets/icons/32/ATVPRD16.png | Bin 0 -> 209 bytes assets/icons/32/ATVSPD16.png | Bin 0 -> 251 bytes assets/icons/32/ATVSUC16.png | Bin 0 -> 204 bytes assets/icons/32/BACK16.png | Bin 0 -> 787 bytes assets/icons/32/BACK3D16.png | Bin 0 -> 882 bytes assets/icons/32/BASLNE16.png | Bin 0 -> 202 bytes assets/icons/32/BLANK16.png | Bin 0 -> 83 bytes assets/icons/32/BRGRPH16.png | Bin 0 -> 258 bytes assets/icons/32/CANCEL16.png | Bin 0 -> 879 bytes assets/icons/32/CBRANCH.png | Bin 0 -> 241 bytes assets/icons/32/CDROM.png | Bin 0 -> 312 bytes assets/icons/32/CHKBX016.png | Bin 0 -> 261 bytes assets/icons/32/CHKBX116.png | Bin 0 -> 623 bytes assets/icons/32/CHKBX216.png | Bin 0 -> 610 bytes assets/icons/32/CHRTLY16.png | Bin 0 -> 233 bytes assets/icons/32/CHRTVW16.png | Bin 0 -> 272 bytes assets/icons/32/CLEAF.png | Bin 0 -> 356 bytes assets/icons/32/CLNDR16.png | Bin 0 -> 645 bytes assets/icons/32/CLOSE16.png | Bin 0 -> 525 bytes assets/icons/32/CLOSEDFOLDER.png | Bin 0 -> 239 bytes assets/icons/32/COLALL16.png | Bin 0 -> 126 bytes assets/icons/32/COLLAY16.png | Bin 0 -> 291 bytes assets/icons/32/COPY16.png | Bin 0 -> 564 bytes assets/icons/32/CTREE.png | Bin 0 -> 296 bytes assets/icons/32/CURRENTFOLDER.png | Bin 0 -> 421 bytes assets/icons/32/CUT16.png | Bin 0 -> 980 bytes assets/icons/32/CXEDIT_GLYPH_ERROR.png | Bin 0 -> 815 bytes assets/icons/32/CXEDIT_GLYPH_INFO.png | Bin 0 -> 777 bytes assets/icons/32/CXEDIT_GLYPH_WARNING.png | Bin 0 -> 675 bytes assets/icons/32/DATRNG16.png | Bin 0 -> 349 bytes assets/icons/32/DELETE16.png | Bin 0 -> 363 bytes assets/icons/32/DELIV16.png | Bin 0 -> 1324 bytes assets/icons/32/DIALOG16.png | Bin 0 -> 503 bytes assets/icons/32/DIRCTY16.png | Bin 0 -> 530 bytes assets/icons/32/DLTARW16.png | Bin 0 -> 497 bytes assets/icons/32/DLVCUR16.png | Bin 0 -> 1428 bytes assets/icons/32/DOCCUR16.png | Bin 0 -> 665 bytes assets/icons/32/DOCMNT16.png | Bin 0 -> 351 bytes assets/icons/32/DOCMNTMM.png | Bin 0 -> 1129 bytes assets/icons/32/DRTARW16.png | Bin 0 -> 465 bytes assets/icons/32/DWNARW16.png | Bin 0 -> 397 bytes assets/icons/32/EDITRC16.png | Bin 0 -> 932 bytes assets/icons/32/EPS16.png | Bin 0 -> 1011 bytes assets/icons/32/ERRORDG.png | Bin 0 -> 2929 bytes assets/icons/32/ESTMAT16.png | Bin 0 -> 495 bytes assets/icons/32/EXECUTABLE.png | Bin 0 -> 172 bytes assets/icons/32/EXPALL16.png | Bin 0 -> 162 bytes assets/icons/32/EXPENSMM.png | Bin 0 -> 1530 bytes assets/icons/32/EXPNSE16.png | Bin 0 -> 338 bytes assets/icons/32/EXPORT16.png | Bin 0 -> 462 bytes assets/icons/32/FACTOR16.png | Bin 0 -> 494 bytes assets/icons/32/FACTVL16.png | Bin 0 -> 286 bytes assets/icons/32/FILDWN16.png | Bin 0 -> 213 bytes assets/icons/32/FILTER16.png | Bin 0 -> 746 bytes assets/icons/32/FIND16.png | Bin 0 -> 471 bytes assets/icons/32/FINISH16.png | Bin 0 -> 182 bytes assets/icons/32/FLOPPY.png | Bin 0 -> 291 bytes assets/icons/32/FTCLRS16.png | Bin 0 -> 827 bytes assets/icons/32/GANTT16.png | Bin 0 -> 278 bytes assets/icons/32/GLOBAL16.png | Bin 0 -> 1168 bytes assets/icons/32/GLOBVW16.png | Bin 0 -> 1502 bytes assets/icons/32/GRPSRT16.png | Bin 0 -> 202 bytes assets/icons/32/HARD.png | Bin 0 -> 264 bytes assets/icons/32/HDETHZ16.png | Bin 0 -> 630 bytes assets/icons/32/HDETVT16.png | Bin 0 -> 565 bytes assets/icons/32/HELP16.png | Bin 0 -> 962 bytes assets/icons/32/HELP3D16.png | Bin 0 -> 401 bytes assets/icons/32/HIDEDT16.png | Bin 0 -> 600 bytes assets/icons/32/HINT16.png | Bin 0 -> 415 bytes assets/icons/32/HINT3D16.png | Bin 0 -> 962 bytes assets/icons/32/HLPCNT16.png | Bin 0 -> 407 bytes assets/icons/32/HOME16.png | Bin 0 -> 478 bytes assets/icons/32/HSTGRM16.png | Bin 0 -> 238 bytes assets/icons/32/ID_1001.png | Bin 0 -> 487 bytes assets/icons/32/ID_1002.png | Bin 0 -> 1027 bytes assets/icons/32/ID_1005.png | Bin 0 -> 336 bytes assets/icons/32/IMG_ICO_EPS.png | Bin 0 -> 899 bytes assets/icons/32/IMG_ICO_EPS_CHECKED.png | Bin 0 -> 1368 bytes assets/icons/32/IMG_ICO_PROJ_CLOSED.png | Bin 0 -> 313 bytes .../icons/32/IMG_ICO_PROJ_CLOSED_CHECKED.png | Bin 0 -> 827 bytes .../32/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png | Bin 0 -> 1123 bytes .../icons/32/IMG_ICO_PROJ_CLOSED_WHATIF.png | Bin 0 -> 618 bytes assets/icons/32/IMG_ICO_PROJ_OPEN.png | Bin 0 -> 502 bytes assets/icons/32/IMG_ICO_PROJ_OPEN_CHECKED.png | Bin 0 -> 1011 bytes .../32/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png | Bin 0 -> 1226 bytes assets/icons/32/IMG_ICO_PROJ_OPEN_WHATIF.png | Bin 0 -> 762 bytes assets/icons/32/IMPORT16.png | Bin 0 -> 745 bytes assets/icons/32/INFODG.png | Bin 0 -> 2760 bytes assets/icons/32/ISSUE16.png | Bin 0 -> 757 bytes assets/icons/32/ISSUESMM.png | Bin 0 -> 1427 bytes assets/icons/32/JUMP16.png | Bin 0 -> 486 bytes assets/icons/32/KNOWNFILE.png | Bin 0 -> 357 bytes assets/icons/32/LEVELR16.png | Bin 0 -> 317 bytes assets/icons/32/LFTARW16.png | Bin 0 -> 276 bytes assets/icons/32/LOCK16.png | Bin 0 -> 594 bytes assets/icons/32/MAINICON.png | Bin 0 -> 1101 bytes assets/icons/32/MEMO16.png | Bin 0 -> 566 bytes assets/icons/32/MEMOEM16.png | Bin 0 -> 524 bytes assets/icons/32/MEMOFL16.png | Bin 0 -> 577 bytes assets/icons/32/MSG_ERROR.png | Bin 0 -> 4466 bytes assets/icons/32/MSG_INFO.png | Bin 0 -> 4372 bytes assets/icons/32/MSG_WARNING.png | Bin 0 -> 3319 bytes assets/icons/32/MTHLNKMM.png | Bin 0 -> 794 bytes assets/icons/32/NETWORK.png | Bin 0 -> 294 bytes assets/icons/32/NEW16.png | Bin 0 -> 331 bytes assets/icons/32/NEXT16.png | Bin 0 -> 689 bytes assets/icons/32/NEXT3D16.png | Bin 0 -> 751 bytes assets/icons/32/NLRCUR16.png | Bin 0 -> 1498 bytes assets/icons/32/NLRSRC16.png | Bin 0 -> 1381 bytes assets/icons/32/NLRSU16.png | Bin 0 -> 1691 bytes assets/icons/32/NLRSUC16.png | Bin 0 -> 1730 bytes assets/icons/32/OBS16.png | Bin 0 -> 782 bytes assets/icons/32/OBSMM.png | Bin 0 -> 969 bytes assets/icons/32/OBSROT16.png | Bin 0 -> 782 bytes assets/icons/32/OK16.png | Bin 0 -> 1074 bytes assets/icons/32/OPEN16.png | Bin 0 -> 748 bytes assets/icons/32/OPENFOLDER.png | Bin 0 -> 430 bytes assets/icons/32/OPTBAR16.png | Bin 0 -> 421 bytes assets/icons/32/OVRHD16.png | Bin 0 -> 258 bytes assets/icons/32/OXACPBACK16.png | Bin 0 -> 459 bytes assets/icons/32/OXACPFEWER16.png | Bin 0 -> 295 bytes assets/icons/32/OXACPFWD16.png | Bin 0 -> 427 bytes assets/icons/32/OXACPGROUP16.png | Bin 0 -> 166 bytes assets/icons/32/OXACPMORE16.png | Bin 0 -> 360 bytes assets/icons/32/OXACPRES16.png | Bin 0 -> 680 bytes assets/icons/32/OXACPSELECT16.png | Bin 0 -> 497 bytes assets/icons/32/OXACPSHOW16.png | Bin 0 -> 280 bytes assets/icons/32/OXBOLD16.png | Bin 0 -> 629 bytes assets/icons/32/OXBULLET16.png | Bin 0 -> 327 bytes assets/icons/32/OXCLRFMT16.png | Bin 0 -> 845 bytes assets/icons/32/OXITALIC16.png | Bin 0 -> 400 bytes assets/icons/32/OXLINENO16.png | Bin 0 -> 508 bytes assets/icons/32/OXLINK16.png | Bin 0 -> 418 bytes assets/icons/32/OXMATRSRC16.png | Bin 0 -> 183 bytes assets/icons/32/OXNUMBER16.png | Bin 0 -> 595 bytes assets/icons/32/OXONLHLP16.png | Bin 0 -> 1360 bytes assets/icons/32/OXPRGLIN16.png | Bin 0 -> 741 bytes assets/icons/32/OXRPTEDT16.png | Bin 0 -> 720 bytes assets/icons/32/OXRPTWIZ16.png | Bin 0 -> 822 bytes assets/icons/32/OXRUNBAT16.png | Bin 0 -> 1107 bytes assets/icons/32/OXSPOTLT16.png | Bin 0 -> 616 bytes assets/icons/32/OXTABHZ16.png | Bin 0 -> 177 bytes assets/icons/32/OXTABMG16.png | Bin 0 -> 413 bytes assets/icons/32/OXTABVT16.png | Bin 0 -> 183 bytes assets/icons/32/OXUNDERL16.png | Bin 0 -> 420 bytes assets/icons/32/OXUNLINK16.png | Bin 0 -> 575 bytes assets/icons/32/OXWHTNW16.png | Bin 0 -> 867 bytes assets/icons/32/PASTE16.png | Bin 0 -> 576 bytes assets/icons/32/PCDCUR16.png | Bin 0 -> 543 bytes assets/icons/32/PEGACT16.png | Bin 0 -> 804 bytes assets/icons/32/PEGTS16.png | Bin 0 -> 811 bytes assets/icons/32/PGSETP16.png | Bin 0 -> 239 bytes assets/icons/32/PJOCKO16.png | Bin 0 -> 1016 bytes assets/icons/32/PJOWCO16.png | Bin 0 -> 1240 bytes assets/icons/32/PJOWIF16.png | Bin 0 -> 768 bytes assets/icons/32/PRCDUR16.png | Bin 0 -> 243 bytes assets/icons/32/PREVIEWGLYPH.png | Bin 0 -> 758 bytes assets/icons/32/PRINT16.png | Bin 0 -> 372 bytes assets/icons/32/PRIVLG16.png | Bin 0 -> 412 bytes assets/icons/32/PRJCKO16.png | Bin 0 -> 823 bytes assets/icons/32/PRJOPN16.png | Bin 0 -> 502 bytes assets/icons/32/PRJWCO16.png | Bin 0 -> 1118 bytes assets/icons/32/PRJWIF16.png | Bin 0 -> 609 bytes assets/icons/32/PROFLE16.png | Bin 0 -> 860 bytes assets/icons/32/PROJCD16.png | Bin 0 -> 496 bytes assets/icons/32/PROJCT16.png | Bin 0 -> 313 bytes assets/icons/32/PROJMM.png | Bin 0 -> 1222 bytes assets/icons/32/PRTFGL16.png | Bin 0 -> 1001 bytes assets/icons/32/PRTFLO16.png | Bin 0 -> 345 bytes assets/icons/32/PRTFOP16.png | Bin 0 -> 285 bytes assets/icons/32/PRTOGB16.png | Bin 0 -> 1063 bytes assets/icons/32/PRVIEW16.png | Bin 0 -> 830 bytes assets/icons/32/QALITY16.png | Bin 0 -> 180 bytes assets/icons/32/QUESTNDG.png | Bin 0 -> 3454 bytes assets/icons/32/QULCUR16.png | Bin 0 -> 480 bytes assets/icons/32/RADBX016.png | Bin 0 -> 784 bytes assets/icons/32/RADBX116.png | Bin 0 -> 1014 bytes assets/icons/32/RAM.png | Bin 0 -> 187 bytes assets/icons/32/REFRSH16.png | Bin 0 -> 875 bytes assets/icons/32/REMOVE16.png | Bin 0 -> 671 bytes assets/icons/32/REORGZ16.png | Bin 0 -> 503 bytes assets/icons/32/REPLAC16.png | Bin 0 -> 825 bytes assets/icons/32/REPORT16.png | Bin 0 -> 330 bytes assets/icons/32/REPRTSMM.png | Bin 0 -> 1187 bytes assets/icons/32/RESHST16.png | Bin 0 -> 786 bytes assets/icons/32/RES_RL16.png | Bin 0 -> 1793 bytes assets/icons/32/RGTARW16.png | Bin 0 -> 254 bytes assets/icons/32/RISK16.png | Bin 0 -> 402 bytes assets/icons/32/RISKSMM.png | Bin 0 -> 950 bytes assets/icons/32/RLATSK16.png | Bin 0 -> 712 bytes assets/icons/32/ROLCUR16.png | Bin 0 -> 1258 bytes assets/icons/32/ROLE16.png | Bin 0 -> 1130 bytes assets/icons/32/ROLEOP16.png | Bin 0 -> 806 bytes assets/icons/32/ROLESMM.png | Bin 0 -> 1386 bytes assets/icons/32/RORGAL16.png | Bin 0 -> 411 bytes assets/icons/32/RPADDG16.png | Bin 0 -> 293 bytes assets/icons/32/RPADDI16.png | Bin 0 -> 553 bytes assets/icons/32/RPADDL16.png | Bin 0 -> 310 bytes assets/icons/32/RPADDR16.png | Bin 0 -> 209 bytes assets/icons/32/RPADDT16.png | Bin 0 -> 675 bytes assets/icons/32/RPEDIT16.png | Bin 0 -> 353 bytes assets/icons/32/RPEXP16.png | Bin 0 -> 554 bytes assets/icons/32/RPIMP16.png | Bin 0 -> 647 bytes assets/icons/32/RPPGF16.png | Bin 0 -> 347 bytes assets/icons/32/RPPGL16.png | Bin 0 -> 344 bytes assets/icons/32/RPPGN16.png | Bin 0 -> 336 bytes assets/icons/32/RPPGP16.png | Bin 0 -> 337 bytes assets/icons/32/RPTGLB16.png | Bin 0 -> 1021 bytes assets/icons/32/RPTGRP16.png | Bin 0 -> 439 bytes assets/icons/32/RPTWZD16.png | Bin 0 -> 659 bytes assets/icons/32/RSATSK16.png | Bin 0 -> 688 bytes assets/icons/32/RSCNWK16.png | Bin 0 -> 779 bytes assets/icons/32/RSCSPD16.png | Bin 0 -> 783 bytes assets/icons/32/RSRC16.png | Bin 0 -> 707 bytes assets/icons/32/RSRCCD16.png | Bin 0 -> 817 bytes assets/icons/32/RSRCOP16.png | Bin 0 -> 787 bytes assets/icons/32/RSRCPLMM.png | Bin 0 -> 2949 bytes assets/icons/32/RSRCPR16.png | Bin 0 -> 811 bytes assets/icons/32/RSRCU16.png | Bin 0 -> 891 bytes assets/icons/32/RSRCUC16.png | Bin 0 -> 1045 bytes assets/icons/32/RSRCUR16.png | Bin 0 -> 811 bytes assets/icons/32/RUN16.png | Bin 0 -> 766 bytes assets/icons/32/RUNBAT16.png | Bin 0 -> 703 bytes assets/icons/32/SAVE16.png | Bin 0 -> 307 bytes assets/icons/32/SAVEAS16.png | Bin 0 -> 427 bytes assets/icons/32/SCHDUL16.png | Bin 0 -> 1280 bytes assets/icons/32/SEARCH16.png | Bin 0 -> 483 bytes assets/icons/32/SELBX016.png | Bin 0 -> 309 bytes assets/icons/32/SELBX116.png | Bin 0 -> 687 bytes assets/icons/32/SELECT16.png | Bin 0 -> 232 bytes assets/icons/32/SHOWRELBTN16.png | Bin 0 -> 255 bytes assets/icons/32/SHOWRESCURVES16.png | Bin 0 -> 740 bytes assets/icons/32/SPLCHK16.png | Bin 0 -> 595 bytes assets/icons/32/SPNDWN16.png | Bin 0 -> 133 bytes assets/icons/32/SPNUP16.png | Bin 0 -> 139 bytes assets/icons/32/STDCUR16.png | Bin 0 -> 1101 bytes assets/icons/32/STEPD16.png | Bin 0 -> 791 bytes assets/icons/32/STEPND16.png | Bin 0 -> 287 bytes assets/icons/32/STNDRD16.png | Bin 0 -> 806 bytes assets/icons/32/SUBMIT16.png | Bin 0 -> 536 bytes assets/icons/32/THRHLDMM.png | Bin 0 -> 1294 bytes assets/icons/32/THSHLD16.png | Bin 0 -> 313 bytes assets/icons/32/TMAPVL16.png | Bin 0 -> 1265 bytes assets/icons/32/TMPLAT16.png | Bin 0 -> 244 bytes assets/icons/32/TMSHT16.png | Bin 0 -> 852 bytes assets/icons/32/TPLGIN16.png | Bin 0 -> 449 bytes assets/icons/32/TPOOL16.png | Bin 0 -> 346 bytes assets/icons/32/TRACK16.png | Bin 0 -> 659 bytes assets/icons/32/TRACKMM.png | Bin 0 -> 3401 bytes assets/icons/32/UNDO16.png | Bin 0 -> 483 bytes assets/icons/32/UNKNOWNFILE.png | Bin 0 -> 648 bytes assets/icons/32/UNLOCK16.png | Bin 0 -> 493 bytes assets/icons/32/UNSEL16.png | Bin 0 -> 543 bytes assets/icons/32/UPARW16.png | Bin 0 -> 152 bytes assets/icons/32/USER16.png | Bin 0 -> 717 bytes assets/icons/32/USRCUR16.png | Bin 0 -> 860 bytes assets/icons/32/VIEWS16.png | Bin 0 -> 1001 bytes assets/icons/32/VMENU_ICO_ALIGN_CENTER.png | Bin 0 -> 279 bytes assets/icons/32/VMENU_ICO_ALIGN_LEFT.png | Bin 0 -> 276 bytes assets/icons/32/VMENU_ICO_ALIGN_RIGHT.png | Bin 0 -> 274 bytes assets/icons/32/VMENU_ICO_ARRANGE_HORZ.png | Bin 0 -> 292 bytes assets/icons/32/VMENU_ICO_ARRANGE_VERT.png | Bin 0 -> 273 bytes .../icons/32/VMENU_ICO_CHART_FONT_COLOR.png | Bin 0 -> 797 bytes assets/icons/32/VMENU_ICO_CHART_LAYOUT.png | Bin 0 -> 246 bytes assets/icons/32/VMENU_ICO_CHART_VIEW.png | Bin 0 -> 286 bytes assets/icons/32/VMENU_ICO_COLLAPSE_ALL.png | Bin 0 -> 162 bytes assets/icons/32/VMENU_ICO_COLLAPSE_TO.png | Bin 0 -> 147 bytes assets/icons/32/VMENU_ICO_COLUMNS.png | Bin 0 -> 285 bytes assets/icons/32/VMENU_ICO_COPY.png | Bin 0 -> 545 bytes assets/icons/32/VMENU_ICO_CUT.png | Bin 0 -> 915 bytes assets/icons/32/VMENU_ICO_DELETE.png | Bin 0 -> 471 bytes assets/icons/32/VMENU_ICO_EXPAND_ALL.png | Bin 0 -> 126 bytes assets/icons/32/VMENU_ICO_FILLDOWN.png | Bin 0 -> 342 bytes assets/icons/32/VMENU_ICO_FILTER.png | Bin 0 -> 682 bytes assets/icons/32/VMENU_ICO_FIND.png | Bin 0 -> 315 bytes assets/icons/32/VMENU_ICO_GRID_FONT_COLOR.png | Bin 0 -> 678 bytes assets/icons/32/VMENU_ICO_GROUPING.png | Bin 0 -> 258 bytes assets/icons/32/VMENU_ICO_INSERT.png | Bin 0 -> 436 bytes assets/icons/32/VMENU_ICO_NEW.png | Bin 0 -> 388 bytes assets/icons/32/VMENU_ICO_OPEN.png | Bin 0 -> 714 bytes assets/icons/32/VMENU_ICO_PASTE.png | Bin 0 -> 499 bytes assets/icons/32/VMENU_ICO_PRINT.png | Bin 0 -> 328 bytes assets/icons/32/VMENU_ICO_PRINT_PREVIEW.png | Bin 0 -> 845 bytes assets/icons/32/VMENU_ICO_SAVE.png | Bin 0 -> 311 bytes assets/icons/32/VMENU_ICO_SPELL_CHECK.png | Bin 0 -> 598 bytes assets/icons/32/VMENU_ICO_ZOOM_BEST_FIT.png | Bin 0 -> 1055 bytes assets/icons/32/VMENU_ICO_ZOOM_IN.png | Bin 0 -> 791 bytes assets/icons/32/VMENU_ICO_ZOOM_OUT.png | Bin 0 -> 799 bytes assets/icons/32/WARNDG.png | Bin 0 -> 2505 bytes assets/icons/32/WBS16.png | Bin 0 -> 314 bytes assets/icons/32/WBSLKC16.png | Bin 0 -> 310 bytes assets/icons/32/WBSLKR16.png | Bin 0 -> 412 bytes assets/icons/32/WBSMM.png | Bin 0 -> 338 bytes assets/icons/32/WBSROT16.png | Bin 0 -> 344 bytes assets/icons/32/WIZARD16.png | Bin 0 -> 413 bytes assets/icons/32/ZOOMIN16.png | Bin 0 -> 783 bytes assets/icons/32/ZOOMOT16.png | Bin 0 -> 790 bytes assets/icons/32/ZOOMTF16.png | Bin 0 -> 845 bytes assets/icons/openxer.ico | Bin 0 -> 12667 bytes assets/icons/openxer_256.png | Bin 0 -> 5092 bytes .../openxer_reports/activities-by-status.rpt | 898 + .../assignments-by-resource.rpt | 608 + assets/openxer_reports/baseline-variance.rpt | 480 + .../openxer_reports/critical-activities.rpt | 452 + .../critical-and-near-critical.rpt | 455 + .../lookahead-2-week-by-wbs.rpt | 513 + .../lookahead-3-week-by-wbs.rpt | 513 + assets/openxer_reports/milestones.rpt | 451 + .../open-ends-and-logic-gaps.rpt | 654 + .../predecessors-and-successors.rpt | 593 + .../openxer_reports/progress-this-period.rpt | 452 + .../resource-usage-by-week.rpt | 418 + assets/openxer_reports/wbs-summary.rpt | 452 + assets/playbooks/audit.md | 23 + assets/playbooks/build.md | 19 + assets/playbooks/critical-path.md | 19 + assets/playbooks/delay-recovery.md | 19 + assets/playbooks/earned-value.md | 19 + assets/playbooks/lookahead.md | 19 + assets/playbooks/narrative.md | 18 + assets/playbooks/resource-review.md | 19 + assets/playbooks/schedule-check.md | 25 + assets/playbooks/update.md | 15 + assets/playbooks/what-if.md | 21 + assets/sample-project.txt | 470 + assets/skills/activity-definition-review.md | 69 + assets/skills/add-scope.md | 73 + assets/skills/baseline-review.md | 76 + assets/skills/baseline-variance.md | 70 + assets/skills/build-schedule.md | 112 + assets/skills/calendar-duration-check.md | 74 + assets/skills/change-interview.md | 87 + assets/skills/compare-files.md | 65 + assets/skills/contingency-float.md | 73 + assets/skills/critical-path-explained.md | 77 + assets/skills/duration-review.md | 72 + assets/skills/export-pack.md | 80 + assets/skills/float-constraint-review.md | 81 + assets/skills/levels-of-detail.md | 73 + assets/skills/logic-health-check.md | 100 + assets/skills/look-ahead.md | 67 + assets/skills/milestone-status.md | 60 + assets/skills/near-critical-paths.md | 97 + assets/skills/one-page-schedule.md | 66 + assets/skills/progress-update.md | 82 + assets/skills/recovery-schedule.md | 85 + assets/skills/resource-load.md | 66 + assets/skills/resource-loading-review.md | 68 + assets/skills/risk-read.md | 71 + assets/skills/schedule-basis.md | 79 + assets/skills/schedule-maturity.md | 68 + assets/skills/schedule-review.md | 96 + assets/skills/sequence-review.md | 71 + assets/skills/time-impact.md | 83 + assets/skills/update-review.md | 84 + assets/skills/weather-nonwork.md | 77 + assets/skills/what-if.md | 78 + automation/COVERAGE.md | 135 + automation/Cargo.toml | 30 + automation/README.md | 670 + automation/build.rs | 39 + automation/src/agent_host/claude.rs | 296 + automation/src/agent_host/codex.rs | 326 + automation/src/agent_host/compat.rs | 223 + automation/src/agent_host/mod.rs | 1282 + automation/src/agent_host/process.rs | 330 + automation/src/analysis.rs | 1266 + automation/src/baseline_cmd.rs | 771 + automation/src/baseline_ops.rs | 774 + automation/src/baseline_store.rs | 333 + automation/src/baselines.rs | 193 + automation/src/chat_prompt.rs | 199 + automation/src/chat_tools.rs | 681 + automation/src/checks.rs | 174 + automation/src/cli.rs | 1449 + automation/src/connect.rs | 1786 + automation/src/connect/tests.rs | 1155 + automation/src/documents.rs | 527 + automation/src/edit.rs | 3545 + automation/src/eps.rs | 617 + automation/src/global_change.rs | 91 + automation/src/interchange.rs | 532 + automation/src/lib.rs | 1842 + automation/src/load.rs | 343 + automation/src/locate.rs | 537 + automation/src/main.rs | 87 + automation/src/mcp.rs | 995 + automation/src/pdf.rs | 186 + automation/src/playbooks.rs | 264 + automation/src/registers.rs | 147 + automation/src/reports.rs | 198 + automation/src/schedule_check.rs | 3 + automation/src/skills.rs | 732 + automation/src/skills_tests.rs | 386 + automation/src/storage.rs | 532 + automation/src/usage.rs | 233 + automation/src/user_prefs.rs | 227 + automation/src/workspace_cmd.rs | 396 + automation/src/workspace_db.rs | 953 + automation/src/workspace_db/migrate.rs | 311 + automation/src/workspace_db/tests.rs | 261 + automation/tests/agent_host.rs | 1839 + automation/tests/agent_live.rs | 398 + automation/tests/agent_shapes.rs | 79 + automation/tests/automation.rs | 523 + automation/tests/baseline.rs | 429 + automation/tests/baseline_update.rs | 192 + automation/tests/batch3.rs | 262 + automation/tests/chat_prompt.rs | 491 + automation/tests/chat_tools.rs | 854 + automation/tests/cli.rs | 371 + automation/tests/connect.rs | 322 + automation/tests/coverage.rs | 85 + automation/tests/curves.rs | 427 + automation/tests/dissolve.rs | 116 + automation/tests/documents.rs | 648 + automation/tests/edit.rs | 1067 + automation/tests/edit_contract.rs | 567 + automation/tests/eps.rs | 605 + automation/tests/financial_periods.rs | 135 + .../fixtures/agent/claude-two-turns.jsonl | 100 + .../fixtures/agent/codex-two-turns.jsonl | 22 + automation/tests/global_change.rs | 206 + automation/tests/interchange.rs | 766 + automation/tests/local_reference.rs | 209 + automation/tests/milestones.rs | 282 + automation/tests/new_activity.rs | 69 + automation/tests/pdf.rs | 122 + automation/tests/period_units.rs | 138 + automation/tests/project_numbers.rs | 158 + automation/tests/registers.rs | 365 + automation/tests/scurve.rs | 167 + automation/tests/skills.rs | 447 + automation/tests/tools.rs | 337 + automation/tests/workspace.rs | 391 + automation/tests/workspace_corpus.rs | 118 + chat/Cargo.toml | 40 + chat/examples/compat_chat.rs | 131 + chat/examples/live_chat.rs | 267 + chat/src/auth.rs | 1047 + chat/src/client.rs | 861 + chat/src/compat.rs | 1360 + chat/src/compat/tests.rs | 1088 + chat/src/conversation.rs | 371 + chat/src/http.rs | 1023 + chat/src/jwt.rs | 450 + chat/src/lib.rs | 96 + chat/src/sse.rs | 225 + chat/src/store.rs | 693 + chat/src/stream.rs | 331 + chat/src/testkit.rs | 829 + chat/src/tests/budgets.rs | 238 + chat/src/tests/mod.rs | 15 + chat/src/tests/signin.rs | 777 + chat/src/tests/turns.rs | 1046 + chat/src/tools.rs | 133 + chat/src/unix.rs | 239 + chat/src/util.rs | 346 + chat/src/win32.rs | 395 + chat/tests/compat_live.rs | 26 + chat/tests/live.rs | 26 + deny.toml | 37 + desktop/.gitignore | 2 + desktop/Cargo.toml | 41 + desktop/assets/spell/construction.txt | 56 + desktop/assets/spell/words.txt | 130788 +++++++++++++++ desktop/build.rs | 117 + desktop/build_release.py | 117 + desktop/help/activity-network-options.md | 30 + desktop/help/add-baseline.md | 31 + desktop/help/admin-preferences.md | 32 + desktop/help/ai-chat.md | 167 + desktop/help/apply-actuals.md | 40 + desktop/help/assign-baselines.md | 36 + desktop/help/assign-dialogs.md | 32 + desktop/help/assign-relationships.md | 30 + desktop/help/bar-chart-options.md | 35 + desktop/help/bars.md | 36 + desktop/help/batch-reports.md | 36 + desktop/help/calendar-editor.md | 32 + desktop/help/calendar-weekly-hours.md | 31 + desktop/help/calendars.md | 44 + desktop/help/categories-and-lists.md | 34 + desktop/help/chart-font-and-colors.md | 33 + desktop/help/check-schedule.md | 33 + desktop/help/codes.md | 32 + desktop/help/collapse-to.md | 25 + desktop/help/columns.md | 32 + desktop/help/contents.md | 138 + desktop/help/copy-options.md | 39 + desktop/help/cost-accounts.md | 35 + desktop/help/currencies.md | 30 + desktop/help/customize-activity-details.md | 39 + desktop/help/customize-toolbars.md | 34 + desktop/help/default-project.md | 31 + desktop/help/earned-hours.md | 36 + desktop/help/edit-relationship.md | 34 + desktop/help/export-report.md | 25 + desktop/help/export-wizard.md | 30 + desktop/help/external-applications.md | 36 + desktop/help/filter-editor.md | 35 + desktop/help/filters.md | 31 + desktop/help/financial-period-calendars.md | 32 + desktop/help/find-and-replace.md | 40 + desktop/help/funding-sources.md | 20 + desktop/help/getting-started.md | 60 + desktop/help/global-change-edit.md | 33 + desktop/help/global-change.md | 41 + desktop/help/group-and-sort.md | 37 + desktop/help/import-reports-database.md | 29 + desktop/help/import-reports.md | 27 + desktop/help/import-wizard.md | 39 + desktop/help/issue-navigator.md | 27 + desktop/help/keyboard-shortcuts.md | 46 + desktop/help/level-resources.md | 34 + desktop/help/maintain-baselines.md | 38 + desktop/help/merge-resources.md | 29 + desktop/help/monitor-thresholds.md | 29 + desktop/help/new-activity-wizard.md | 31 + desktop/help/new-layout.md | 30 + desktop/help/new-project.md | 32 + desktop/help/new-resource-wizard.md | 31 + desktop/help/notebooks.md | 38 + desktop/help/open-layout.md | 34 + desktop/help/open-project.md | 32 + desktop/help/overview.md | 33 + desktop/help/page-setup.md | 24 + desktop/help/print-preview.md | 34 + desktop/help/profile-options.md | 42 + desktop/help/project-checker-results.md | 34 + desktop/help/project-checker.md | 30 + desktop/help/project-folders.md | 34 + desktop/help/recalculate-assignment-costs.md | 35 + desktop/help/renumber-activity-ids.md | 46 + desktop/help/report-editor.md | 38 + desktop/help/report-groups.md | 30 + desktop/help/report-properties.md | 26 + desktop/help/resource-curves.md | 71 + desktop/help/resource-shifts.md | 31 + desktop/help/responsible-managers.md | 27 + desktop/help/revert-to-baseline.md | 17 + desktop/help/role-codes.md | 30 + desktop/help/roles.md | 25 + desktop/help/run-batch.md | 27 + desktop/help/run-report.md | 34 + desktop/help/s-curve.md | 41 + desktop/help/save-period-actuals.md | 31 + desktop/help/schedule-comparison-results.md | 32 + desktop/help/schedule-comparison.md | 31 + desktop/help/schedule-options.md | 35 + desktop/help/schedule.md | 36 + desktop/help/scheduling-basics.md | 64 + desktop/help/select-baseline-project.md | 29 + desktop/help/shared-dictionaries.md | 34 + desktop/help/skills-for-ai-agents.md | 83 + desktop/help/spell-check.md | 35 + desktop/help/spread-budget-hours.md | 34 + desktop/help/step-templates.md | 34 + desktop/help/table-font-and-row.md | 31 + desktop/help/text-attachment.md | 31 + desktop/help/timescale.md | 34 + desktop/help/trace-logic-options.md | 32 + desktop/help/update-baseline.md | 36 + desktop/help/update-progress.md | 44 + desktop/help/usage-views.md | 60 + desktop/help/user-defined-fields.md | 36 + desktop/help/user-preferences.md | 38 + desktop/help/view-activities.md | 39 + desktop/help/view-assignments.md | 31 + desktop/help/view-documents.md | 36 + desktop/help/view-expenses.md | 31 + desktop/help/view-issues.md | 34 + desktop/help/view-projects.md | 60 + desktop/help/view-report-tab.md | 30 + desktop/help/view-reports.md | 32 + desktop/help/view-resources.md | 31 + desktop/help/view-risks.md | 32 + desktop/help/view-thresholds.md | 31 + desktop/help/view-wbs.md | 48 + desktop/help/working-with-ai-agents.md | 101 + desktop/src/activities.rs | 599 + desktop/src/activities_tests.rs | 976 + desktop/src/activity_delete.rs | 128 + desktop/src/activity_wizard.rs | 1331 + desktop/src/admin_prefs.rs | 358 + desktop/src/agent_coverage.rs | 384 + desktop/src/ai_agents.rs | 932 + desktop/src/ai_agents/row.rs | 122 + desktop/src/ai_agents/skills_ui.rs | 855 + desktop/src/ai_agents/skills_ui_tests.rs | 303 + desktop/src/ai_agents/tests.rs | 853 + desktop/src/available_options.rs | 134 + desktop/src/available_options/tests.rs | 366 + desktop/src/baselines/columns.rs | 374 + desktop/src/baselines/data.rs | 150 + desktop/src/baselines/dialogs.rs | 1173 + desktop/src/baselines/mod.rs | 1254 + desktop/src/baselines/store.rs | 3 + desktop/src/baselines/tests.rs | 995 + desktop/src/baselines/tests_m4.rs | 850 + desktop/src/baselines/update_dialog.rs | 992 + desktop/src/busy.rs | 459 + desktop/src/calendars/editor.rs | 1094 + desktop/src/calendars/mod.rs | 850 + desktop/src/calendars/ops.rs | 3 + desktop/src/calendars/tests.rs | 458 + desktop/src/chat/backend.rs | 558 + desktop/src/chat/checks.rs | 513 + desktop/src/chat/endpoint_dialog.rs | 340 + desktop/src/chat/history.rs | 135 + desktop/src/chat/links.rs | 177 + desktop/src/chat/list.rs | 2038 + desktop/src/chat/live/endpoint.rs | 416 + desktop/src/chat/live/fakes.rs | 685 + desktop/src/chat/live/mod.rs | 1800 + desktop/src/chat/live/rows.rs | 305 + desktop/src/chat/live/tests.rs | 2906 + desktop/src/chat/live/work.rs | 113 + desktop/src/chat/mod.rs | 3363 + desktop/src/chat/model.rs | 657 + desktop/src/chat/prompts.rs | 287 + desktop/src/chat/renders.rs | 375 + desktop/src/chat/tests.rs | 1722 + desktop/src/chat/ui_actions.rs | 734 + desktop/src/chrome.rs | 2094 + desktop/src/close_guard.rs | 540 + desktop/src/compare/diff.rs | 858 + desktop/src/compare/mod.rs | 813 + desktop/src/compare/report.rs | 697 + desktop/src/compare/tests.rs | 569 + desktop/src/context_menu.rs | 581 + desktop/src/context_menu_tests.rs | 691 + desktop/src/crash.rs | 216 + desktop/src/critical_path.rs | 563 + desktop/src/critical_path/tests.rs | 240 + desktop/src/defaults.rs | 229 + desktop/src/defaults_tests.rs | 334 + desktop/src/details/assign_kit.rs | 305 + desktop/src/details/assignment_tests.rs | 671 + desktop/src/details/assignment_window.rs | 607 + desktop/src/details/assignments.rs | 1415 + desktop/src/details/bulk_assign.rs | 232 + desktop/src/details/codes_assign_tests.rs | 174 + desktop/src/details/form.rs | 1049 + desktop/src/details/grid_columns.rs | 786 + desktop/src/details/grid_columns/tests.rs | 146 + desktop/src/details/headless_tests.rs | 720 + desktop/src/details/mod.rs | 1620 + desktop/src/details/notes_pane.rs | 614 + desktop/src/details/owner_pickers.rs | 240 + desktop/src/details/record_tabs.rs | 1949 + desktop/src/details/removals.rs | 377 + desktop/src/details/review_renders.rs | 185 + desktop/src/details/schedule_tabs.rs | 2017 + desktop/src/details/setters.rs | 122 + desktop/src/details/split_tests.rs | 245 + desktop/src/details/status_layout_tests.rs | 273 + desktop/src/details/units_progress.rs | 28 + desktop/src/diag_log.rs | 132 + desktop/src/dialog_keys.rs | 320 + desktop/src/dialog_kit.rs | 3473 + desktop/src/dialog_renders.rs | 708 + desktop/src/dialog_sweep.rs | 1744 + desktop/src/dialogs.rs | 429 + desktop/src/dictionaries/accounts.rs | 466 + desktop/src/dictionaries/admin.rs | 337 + desktop/src/dictionaries/codes.rs | 670 + desktop/src/dictionaries/mod.rs | 764 + desktop/src/dictionaries/ops.rs | 1846 + desktop/src/dictionaries/steps.rs | 406 + desktop/src/dictionaries/steps/tests.rs | 117 + desktop/src/dictionaries/tests.rs | 1337 + desktop/src/dictionaries/udf.rs | 205 + desktop/src/dictionaries/widgets.rs | 71 + desktop/src/dockbars.rs | 942 + desktop/src/dockbars_tests.rs | 774 + desktop/src/dockbars_ui.rs | 929 + desktop/src/editing/dialogs.rs | 1737 + desktop/src/editing/gc.rs | 243 + desktop/src/editing/gc_report.rs | 553 + desktop/src/editing/links.rs | 130 + desktop/src/editing/mod.rs | 1039 + desktop/src/editing/move_across.rs | 286 + desktop/src/editing/ops.rs | 985 + desktop/src/editing/table_menu.rs | 399 + desktop/src/editing/table_menu_tests.rs | 463 + desktop/src/editing/tests.rs | 1554 + desktop/src/enterprise/dialogs.rs | 1079 + desktop/src/enterprise/lists.rs | 1175 + desktop/src/enterprise/mod.rs | 627 + desktop/src/enterprise/ops.rs | 1591 + desktop/src/enterprise/tests.rs | 1543 + desktop/src/enterprise/tree.rs | 4 + desktop/src/enterprise/ui.rs | 215 + desktop/src/enterprise/workspace.rs | 3 + desktop/src/estimation.rs | 360 + desktop/src/external_apps.rs | 602 + desktop/src/external_apps/tests.rs | 372 + desktop/src/first_run.rs | 111 + desktop/src/float_path_end_tests.rs | 153 + desktop/src/format.rs | 1576 + desktop/src/frame.rs | 498 + desktop/src/gantt/bars.rs | 636 + desktop/src/gantt/dialogs.rs | 2378 + desktop/src/gantt/edit_tests.rs | 1346 + desktop/src/gantt/mod.rs | 2429 + desktop/src/gantt/paint.rs | 329 + desktop/src/gantt/settings.rs | 1505 + desktop/src/gantt/tests.rs | 1025 + desktop/src/gantt/text_tests.rs | 270 + desktop/src/gantt_geometry.rs | 786 + desktop/src/grid/align_render.rs | 171 + desktop/src/grid/band.rs | 143 + desktop/src/grid/cell_combo.rs | 320 + desktop/src/grid/columns.rs | 1254 + desktop/src/grid/columns_ev.rs | 338 + desktop/src/grid/columns_ext.rs | 755 + desktop/src/grid/dialogs.rs | 2661 + desktop/src/grid/edit.rs | 557 + desktop/src/grid/filter_editor.rs | 540 + desktop/src/grid/filters.rs | 514 + desktop/src/grid/group.rs | 633 + desktop/src/grid/interval.rs | 140 + desktop/src/grid/layout.rs | 810 + desktop/src/grid/marks.rs | 290 + desktop/src/grid/marks_render.rs | 324 + desktop/src/grid/mod.rs | 1074 + desktop/src/grid/presets.rs | 91 + desktop/src/grid/relative.rs | 193 + desktop/src/grid/review_renders.rs | 221 + desktop/src/grid/sort_keys.rs | 111 + desktop/src/grid/starters.rs | 218 + desktop/src/grid/starters_tests.rs | 348 + desktop/src/grid/table.rs | 1363 + desktop/src/grid/tests.rs | 2077 + desktop/src/grid/tests/align_tests.rs | 156 + desktop/src/grid/tests/edit_tests.rs | 1729 + desktop/src/grid/tests/quotes_tests.rs | 91 + desktop/src/grid/tests_cache.rs | 448 + desktop/src/grid/tests_ev_techniques.rs | 208 + desktop/src/grid/tests_h3.rs | 1402 + desktop/src/h6_renders.rs | 125 + desktop/src/headless_render.rs | 1127 + desktop/src/headless_ui.rs | 1035 + desktop/src/help/mod.rs | 646 + desktop/src/help/tests.rs | 1231 + desktop/src/help/viewer.rs | 525 + desktop/src/history.rs | 491 + desktop/src/hscroll.rs | 799 + desktop/src/hscroll_tests.rs | 1258 + desktop/src/install_tests.rs | 177 + desktop/src/instance.rs | 93 + desktop/src/interchange/dictionary_tests.rs | 351 + desktop/src/interchange/mod.rs | 2833 + desktop/src/interchange/safety_tests.rs | 303 + desktop/src/interchange/sheet_setters.rs | 199 + desktop/src/interchange/sheet_tests.rs | 646 + desktop/src/interchange/templates.rs | 430 + desktop/src/interchange/tests.rs | 1011 + desktop/src/interchange/workspace.rs | 760 + desktop/src/kit_window.rs | 757 + desktop/src/l1_renders.rs | 163 + desktop/src/l2_renders.rs | 208 + desktop/src/layout_opts/checks.rs | 189 + desktop/src/layout_opts/dialogs.rs | 974 + desktop/src/layout_opts/mod.rs | 731 + desktop/src/layout_opts/tests.rs | 760 + desktop/src/loops/analysis.rs | 538 + desktop/src/loops/dialog.rs | 649 + desktop/src/loops/mod.rs | 57 + desktop/src/loops/tests.rs | 512 + desktop/src/m6_renders.rs | 190 + desktop/src/main.rs | 799 + desktop/src/markdown.rs | 940 + desktop/src/memo.rs | 136 + desktop/src/menu.rs | 1573 + desktop/src/menu_keys.rs | 557 + desktop/src/menu_keys_tests.rs | 574 + desktop/src/new_project.rs | 372 + desktop/src/new_project/tests.rs | 312 + desktop/src/new_project_wbs_tests.rs | 410 + desktop/src/open_set/compose.rs | 285 + desktop/src/open_set/dialogs.rs | 443 + desktop/src/open_set/mod.rs | 1340 + desktop/src/open_set/numbers.rs | 91 + desktop/src/open_set/recovery.rs | 1425 + desktop/src/open_set/schedule.rs | 191 + desktop/src/open_set/tests.rs | 883 + desktop/src/panes/actual_remaining_tests.rs | 224 + desktop/src/panes/boxes.rs | 396 + desktop/src/panes/ctx_tests.rs | 889 + desktop/src/panes/curve_spread_tests.rs | 410 + desktop/src/panes/histogram.rs | 433 + desktop/src/panes/mod.rs | 891 + desktop/src/panes/network.rs | 1796 + desktop/src/panes/profile_options.rs | 815 + desktop/src/panes/sheet_pane.rs | 225 + desktop/src/panes/stacked.rs | 218 + desktop/src/panes/stacked_tests.rs | 215 + desktop/src/panes/tests.rs | 2960 + desktop/src/panes/time_fields.rs | 465 + desktop/src/panes/trace.rs | 635 + desktop/src/panes/usage.rs | 4212 + desktop/src/panes/usage_cells.rs | 488 + desktop/src/panes/usage_fields.rs | 1046 + desktop/src/panes/usage_list.rs | 2039 + desktop/src/panes/usage_list_tests.rs | 1113 + desktop/src/panes/usage_menu.rs | 372 + desktop/src/panes/usage_totals_tests.rs | 495 + desktop/src/perf.rs | 1185 + desktop/src/polish_tests.rs | 303 + desktop/src/print/cli.rs | 209 + desktop/src/print/compose.rs | 1753 + desktop/src/print/dialog.rs | 1167 + desktop/src/print/mod.rs | 391 + desktop/src/print/ops.rs | 739 + desktop/src/print/other_views.rs | 269 + desktop/src/print/paginate.rs | 442 + desktop/src/print/pdf.rs | 309 + desktop/src/print/preview.rs | 538 + desktop/src/print/screen_tests.rs | 1074 + desktop/src/print/scroll_tests.rs | 1043 + desktop/src/print/setup.rs | 678 + desktop/src/print/speed_tests.rs | 351 + desktop/src/print/tests.rs | 1199 + desktop/src/print/ts_picker.rs | 473 + desktop/src/print/ts_picker_tests.rs | 549 + desktop/src/print/viewer.rs | 665 + desktop/src/print/viewer_ui.rs | 855 + desktop/src/progress_tools.rs | 2268 + desktop/src/progress_tools_tests.rs | 1508 + desktop/src/project_io.rs | 381 + desktop/src/qa_sweep.rs | 2621 + desktop/src/qa_workflows.rs | 3535 + desktop/src/qa_workflows/activity_wizard.rs | 538 + .../src/qa_workflows/assignments_window.rs | 417 + desktop/src/qa_workflows/bar_drag_hold.rs | 141 + desktop/src/qa_workflows/chat.rs | 250 + desktop/src/qa_workflows/confirm_defaults.rs | 233 + desktop/src/qa_workflows/context_menus.rs | 436 + desktop/src/qa_workflows/cut_paste.rs | 370 + desktop/src/qa_workflows/data_date_edit.rs | 191 + desktop/src/qa_workflows/delete_confirms.rs | 423 + desktop/src/qa_workflows/details_gaps.rs | 695 + desktop/src/qa_workflows/dialog_look.rs | 260 + desktop/src/qa_workflows/dissolve.rs | 171 + desktop/src/qa_workflows/eps_delete.rs | 252 + desktop/src/qa_workflows/global_change_cli.rs | 378 + .../src/qa_workflows/global_change_report.rs | 266 + .../src/qa_workflows/look_details_project.rs | 420 + .../src/qa_workflows/look_layouts_records.rs | 497 + .../qa_workflows/notebooks_project_codes.rs | 390 + desktop/src/qa_workflows/out_of_sequence.rs | 185 + desktop/src/qa_workflows/owner_ui_fixes_1.rs | 368 + desktop/src/qa_workflows/period_delete.rs | 186 + desktop/src/qa_workflows/polish_1.rs | 361 + desktop/src/qa_workflows/profiles.rs | 383 + desktop/src/qa_workflows/progress_tools.rs | 601 + desktop/src/qa_workflows/project_numbers.rs | 283 + .../src/qa_workflows/reference_defaults.rs | 205 + desktop/src/qa_workflows/resource_wizard.rs | 405 + .../src/qa_workflows/round2_corrections.rs | 262 + .../src/qa_workflows/round3_corrections.rs | 285 + desktop/src/qa_workflows/schedule_freeze.rs | 335 + .../qa_workflows/schedule_options_close.rs | 399 + desktop/src/qa_workflows/shared_controls.rs | 145 + desktop/src/qa_workflows/start_constraint.rs | 194 + desktop/src/qa_workflows/table_editing.rs | 736 + desktop/src/qa_workflows/udf_columns.rs | 625 + desktop/src/qa_workflows/usage_cells.rs | 379 + desktop/src/qa_workflows/usage_spreadsheet.rs | 251 + .../src/qa_workflows/wbs_copy_calendars.rs | 660 + .../src/qa_workflows/wbs_projects_tables.rs | 515 + desktop/src/qa_workflows/xml_interchange.rs | 107 + desktop/src/qa_workflows_update.rs | 323 + desktop/src/readme_hero.rs | 1113 + desktop/src/records.rs | 515 + desktop/src/relationships.rs | 3 + desktop/src/reports/batch_run.rs | 253 + desktop/src/reports/checker.rs | 1007 + desktop/src/reports/checker_tests.rs | 386 + desktop/src/reports/checker_ui.rs | 807 + desktop/src/reports/csv.rs | 202 + desktop/src/reports/doc.rs | 252 + desktop/src/reports/groups.rs | 579 + desktop/src/reports/groups_ui.rs | 839 + desktop/src/reports/html.rs | 168 + desktop/src/reports/injection_tests.rs | 116 + desktop/src/reports/mod.rs | 134 + desktop/src/reports/pdf.rs | 375 + desktop/src/reports/progress_tests.rs | 671 + desktop/src/reports/progress_ui.rs | 536 + desktop/src/reports/progress_view.rs | 730 + desktop/src/reports/report_tab.rs | 690 + desktop/src/reports/report_tab_tests.rs | 712 + desktop/src/reports/report_tab_ui.rs | 411 + desktop/src/reports/reports_view.rs | 926 + desktop/src/reports/reports_view_tests.rs | 1314 + desktop/src/reports/rpt/data.rs | 1265 + desktop/src/reports/rpt/edit.rs | 710 + desktop/src/reports/rpt/engine.rs | 1254 + desktop/src/reports/rpt/filter.rs | 352 + desktop/src/reports/rpt/library.rs | 84 + desktop/src/reports/rpt/library_gen.rs | 799 + desktop/src/reports/rpt/mod.rs | 34 + desktop/src/reports/rpt/model.rs | 629 + desktop/src/reports/rpt/page.rs | 356 + desktop/src/reports/rpt/run_tests.rs | 364 + desktop/src/reports/rpt/store.rs | 719 + desktop/src/reports/rpt/stream.rs | 747 + desktop/src/reports/rpt/tests.rs | 261 + desktop/src/reports/rpt/writers.rs | 586 + desktop/src/reports/rpt_editor.rs | 553 + desktop/src/reports/rpt_entries.rs | 371 + desktop/src/reports/rpt_io.rs | 529 + desktop/src/reports/rpt_props.rs | 1034 + desktop/src/reports/rpt_run.rs | 643 + desktop/src/reports/rpt_tests.rs | 738 + desktop/src/reports/test_support.rs | 77 + desktop/src/reports/wizard.rs | 825 + desktop/src/reports/wizard_tests.rs | 383 + desktop/src/reports/wizard_ui.rs | 842 + desktop/src/reports/xlsx.rs | 95 + desktop/src/resource_wizard.rs | 854 + desktop/src/sample_renders.rs | 131 + desktop/src/schedule_check.rs | 4 + desktop/src/schedule_dialogs.rs | 2794 + desktop/src/scheduling.rs | 584 + desktop/src/scheduling_guards.rs | 123 + desktop/src/session_history.rs | 172 + desktop/src/share_dictionaries.rs | 392 + desktop/src/share_dictionaries/tests.rs | 174 + desktop/src/shell_tests.rs | 680 + desktop/src/spell/dict.rs | 311 + desktop/src/spell/mod.rs | 548 + desktop/src/spell/tests.rs | 300 + desktop/src/splitter_tests.rs | 271 + desktop/src/start_hold.rs | 202 + desktop/src/startup_tests.rs | 556 + desktop/src/store.rs | 1523 + desktop/src/tab_strip.rs | 253 + desktop/src/test_corpus.rs | 18 + desktop/src/theme.rs | 217 + desktop/src/theme/legacy.rs | 269 + desktop/src/timeline.rs | 671 + desktop/src/timeline_tests.rs | 536 + desktop/src/timescale.rs | 1310 + desktop/src/toolbars.rs | 1097 + desktop/src/ui_batch1_renders.rs | 163 + desktop/src/ui_batch3_renders.rs | 139 + desktop/src/user_prefs.rs | 1376 + desktop/src/util.rs | 370 + desktop/src/view.rs | 175 + desktop/src/views/activity_views.rs | 302 + desktop/src/views/assignment_codes.rs | 258 + desktop/src/views/assignment_codes/tests.rs | 110 + desktop/src/views/assignment_columns.rs | 600 + desktop/src/views/assignment_layout_tests.rs | 198 + desktop/src/views/assignment_layouts.rs | 192 + desktop/src/views/assignments.rs | 2218 + desktop/src/views/budget.rs | 1052 + desktop/src/views/budget_tests.rs | 565 + desktop/src/views/chart.rs | 409 + desktop/src/views/columns_tests.rs | 199 + desktop/src/views/command_bar_tests.rs | 134 + desktop/src/views/docks.rs | 883 + desktop/src/views/documents.rs | 857 + desktop/src/views/eps_tracking_tests.rs | 463 + desktop/src/views/expenses.rs | 605 + desktop/src/views/funding.rs | 190 + desktop/src/views/funding_tests.rs | 169 + desktop/src/views/grid.rs | 1947 + desktop/src/views/headless.rs | 818 + desktop/src/views/issues.rs | 689 + desktop/src/views/mod.rs | 773 + desktop/src/views/monitor_ev_tests.rs | 209 + desktop/src/views/multiselect_tests.rs | 576 + desktop/src/views/project_ops.rs | 831 + desktop/src/views/project_ops/tests.rs | 446 + desktop/src/views/project_rollups.rs | 567 + desktop/src/views/projects.rs | 3140 + desktop/src/views/record_view.rs | 1253 + desktop/src/views/record_view_tests.rs | 1025 + desktop/src/views/resource_edit.rs | 643 + desktop/src/views/resource_merge.rs | 383 + desktop/src/views/resource_merge_tests.rs | 223 + desktop/src/views/resource_table_tests.rs | 671 + desktop/src/views/resource_tests.rs | 608 + desktop/src/views/resources.rs | 2988 + desktop/src/views/resources_bottom_tests.rs | 153 + desktop/src/views/risks.rs | 455 + desktop/src/views/sheet.rs | 947 + desktop/src/views/tab_group_tests.rs | 312 + desktop/src/views/tab_groups.rs | 382 + desktop/src/views/table_cells.rs | 499 + desktop/src/views/table_keys.rs | 325 + desktop/src/views/thresholds.rs | 645 + desktop/src/views/udf_columns.rs | 477 + desktop/src/views/view_menus_tests.rs | 1347 + desktop/src/views/wbs.rs | 2788 + desktop/src/views/wbs_columns.rs | 438 + desktop/src/views/wbs_copy.rs | 477 + desktop/src/window_place.rs | 376 + desktop/src/workspace_safety_tests.rs | 503 + desktop/src/workspace_sync.rs | 342 + desktop/src/workspace_sync_tests.rs | 264 + desktop/src/write_safety_tests.rs | 224 + docs/images/ai-chat.png | Bin 0 -> 233760 bytes docs/images/ai-skills.png | Bin 0 -> 218062 bytes docs/images/baseline.png | Bin 0 -> 229407 bytes docs/images/check-schedule.png | Bin 0 -> 188268 bytes docs/images/hero.png | Bin 0 -> 210838 bytes docs/images/leveled.png | Bin 0 -> 177951 bytes docs/images/print-preview.png | Bin 0 -> 176263 bytes docs/images/resource-usage.png | Bin 0 -> 177620 bytes docs/images/trace-logic.png | Bin 0 -> 185246 bytes docs/images/update-progress.png | Bin 0 -> 237987 bytes engine/Cargo.toml | 8 + engine/PARITY.md | 84 + engine/RULES.md | 772 + engine/src/bin/oxdiff.rs | 51 + engine/src/calendar.rs | 640 + engine/src/cpm.rs | 1199 + engine/src/features.rs | 1674 + engine/src/fixture.rs | 1074 + engine/src/lib.rs | 18 + engine/src/model.rs | 664 + engine/src/options.rs | 112 + engine/src/scheduler.rs | 1030 + engine/tests/activity_paths.rs | 127 + engine/tests/blackbox_rules.rs | 2254 + engine/tests/cal_fixtures.rs | 8 + engine/tests/completed_boundaries.rs | 229 + engine/tests/engine_diff.rs | 33 + engine/tests/float_path_cost.rs | 136 + engine/tests/fresh_schedule.rs | 69 + engine/tests/input_validation.rs | 476 + engine/tests/level_options.rs | 458 + engine/tests/loe_rules.rs | 214 + engine/tests/multi_project.rs | 264 + engine/tests/no_internal_refs.rs | 110 + engine/tests/origin_room.rs | 228 + engine/tests/parity_rules.rs | 407 + engine/tests/probe_rules.rs | 194 + engine/tests/relationship_candidates.rs | 86 + engine/tests/schedule_features.rs | 377 + engine/tests/shift_shapes.rs | 270 + engine/tests/started_mandatory.rs | 250 + interchange/Cargo.toml | 15 + interchange/src/baseline.rs | 840 + interchange/src/baseline_update.rs | 2472 + interchange/src/baseline_update/tests.rs | 657 + interchange/src/columns.rs | 911 + interchange/src/export_template.rs | 471 + interchange/src/field_edits.rs | 162 + interchange/src/lib.rs | 16 + interchange/src/project_xml.rs | 1798 + interchange/src/project_xml_specs.rs | 1093 + interchange/src/project_xml_tests.rs | 1072 + interchange/src/report_xlsx.rs | 278 + interchange/src/scurve_xlsx.rs | 858 + interchange/src/util.rs | 287 + interchange/src/xer_export.rs | 244 + interchange/src/xer_merge.rs | 2001 + interchange/src/xlsx_export.rs | 911 + interchange/src/xlsx_import.rs | 3164 + interchange/tests/scurve.rs | 189 + interchange/tests/template.rs | 214 + interchange/tests/xer.rs | 832 + interchange/tests/xlsx.rs | 1557 + tools/icons/README.md | 39 + tools/icons/build.py | 63 + tools/icons/iconlib.py | 380 + tools/icons/set_a.py | 785 + tools/icons/set_b.py | 815 + tools/icons/set_c.py | 854 + tools/icons/set_d.py | 269 + tools/icons/set_x.py | 275 + tools/installer/license.txt | 18 + tools/installer/openxer.installed | 4 + tools/installer/openxer.iss | 388 + tools/licenses/third_party.py | 315 + tools/spell/build_wordlist.py | 95 + tools/winres.rs | 162 + xer/Cargo.toml | 16 + xer/src/assignments.rs | 2353 + xer/src/assignments/progress.rs | 363 + xer/src/calendar_data.rs | 478 + xer/src/compare.rs | 174 + xer/src/critical.rs | 116 + xer/src/delete.rs | 180 + xer/src/edit/activity.rs | 1464 + xer/src/edit/calendars.rs | 580 + xer/src/edit/curves.rs | 499 + xer/src/edit/dissolve.rs | 356 + xer/src/edit/documents.rs | 800 + xer/src/edit/earned_value.rs | 248 + xer/src/edit/fields/catalog.rs | 561 + xer/src/edit/fields/criteria.rs | 217 + xer/src/edit/fields/index.rs | 512 + xer/src/edit/fields/mod.rs | 389 + xer/src/edit/fields/tests.rs | 131 + xer/src/edit/fields/write.rs | 415 + xer/src/edit/financial_periods.rs | 169 + xer/src/edit/funding.rs | 324 + xer/src/edit/global_change.rs | 570 + xer/src/edit/global_change/tests.rs | 147 + xer/src/edit/mod.rs | 31 + xer/src/edit/new_activity.rs | 325 + xer/src/edit/notebooks.rs | 187 + xer/src/edit/period_units.rs | 217 + xer/src/edit/progress.rs | 860 + xer/src/edit/project_codes.rs | 199 + xer/src/edit/project_dates.rs | 63 + xer/src/edit/project_records.rs | 1078 + xer/src/edit/records.rs | 662 + xer/src/edit/relationships.rs | 275 + xer/src/edit/resources.rs | 963 + xer/src/edit/rich_memo.rs | 646 + xer/src/edit/steps.rs | 554 + xer/src/edit/tables.rs | 924 + xer/src/edit/thresholds.rs | 753 + xer/src/edit/udf.rs | 433 + xer/src/edit/wbs.rs | 1187 + xer/src/enterprise.rs | 161 + xer/src/estimate.rs | 363 + xer/src/ev.rs | 967 + xer/src/lib.rs | 3770 + xer/src/limits.rs | 112 + xer/src/manual_units.rs | 304 + xer/src/periods.rs | 187 + xer/src/sample_project.rs | 1144 + xer/src/sample_project/tests.rs | 697 + xer/src/schedule_check.rs | 1057 + xer/src/scurve.rs | 1404 + xer/src/scurve_tests.rs | 320 + xer/src/spread.rs | 1002 + xer/src/tree.rs | 348 + xer/src/workspace/mod.rs | 395 + xer/src/workspace/new_project.rs | 155 + xer/src/workspace/numbering.rs | 108 + xer/src/workspace/numbering/tests.rs | 224 + xer/src/workspace/rollup.rs | 470 + xer/src/workspace/sample.rs | 229 + xer/src/workspace/tests.rs | 214 + xer/src/workspace/tree.rs | 723 + xer/src/workspace_scope.rs | 880 + xer/src/workspace_scope/delta.rs | 349 + xer/src/workspace_scope/merge.rs | 1414 + xer/src/workspace_scope/merge/tests.rs | 401 + xer/src/workspace_scope/migrate.rs | 352 + xer/src/workspace_scope/migrate/tests.rs | 162 + xer/src/workspace_scope/tests.rs | 496 + xer/tests/assignments.rs | 1462 + xer/tests/corpus_bench.rs | 55 + xer/tests/corpus_diff.rs | 90 + xer/tests/corpus_parity.rs | 404 + xer/tests/corpus_roundtrip.rs | 597 + xer/tests/curve_presets.rs | 135 + xer/tests/curve_spread.rs | 812 + xer/tests/delete.rs | 261 + xer/tests/edit.rs | 741 + xer/tests/estimate.rs | 208 + xer/tests/leveling_inputs.rs | 104 + xer/tests/loe_duration.rs | 57 + xer/tests/new_activity.rs | 239 + xer/tests/notebooks.rs | 167 + xer/tests/period_units.rs | 205 + xer/tests/quotes.rs | 185 + xer/tests/resource_merge.rs | 358 + xer/tests/resources.rs | 121 + xer/tests/robustness.rs | 1361 + xer/tests/undo_columns.rs | 355 + 1547 files changed, 579084 insertions(+) create mode 100644 .gitattributes create mode 100644 .github/ISSUE_TEMPLATE/bug_report.yml create mode 100644 .github/ISSUE_TEMPLATE/config.yml create mode 100644 .github/ISSUE_TEMPLATE/feature_request.yml create mode 100644 .github/PULL_REQUEST_TEMPLATE.md create mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/release.yml create mode 100644 .gitignore create mode 100644 AGENTS.md create mode 100644 CHANGELOG.md create mode 100644 CLAUDE.md create mode 100644 CODE_OF_CONDUCT.md create mode 100644 CONTRIBUTING.md create mode 100644 Cargo.lock create mode 100644 Cargo.toml create mode 100644 DESIGN.md create mode 100644 LICENSE-APACHE create mode 100644 LICENSE-MIT create mode 100644 README.md create mode 100644 ROADMAP.md create mode 100644 SECURITY.md create mode 100644 THIRD_PARTY.md create mode 100644 assets/icons/16/ACCUNT16.png create mode 100644 assets/icons/16/ACTCTP16.png create mode 100644 assets/icons/16/ACTCUR16.png create mode 100644 assets/icons/16/ACTINP16.png create mode 100644 assets/icons/16/ACTIPP16.png create mode 100644 assets/icons/16/ACTPRM16.png create mode 100644 assets/icons/16/ACTRJ16.png create mode 100644 assets/icons/16/ACTRJP16.png create mode 100644 assets/icons/16/ADD16.png create mode 100644 assets/icons/16/ALGNCT16.png create mode 100644 assets/icons/16/ALGNLT16.png create mode 100644 assets/icons/16/ALGNRT16.png create mode 100644 assets/icons/16/APPLY16.png create mode 100644 assets/icons/16/ARHORZ16.png create mode 100644 assets/icons/16/ARVERT16.png create mode 100644 assets/icons/16/ASSIGN16.png create mode 100644 assets/icons/16/ATV16.png create mode 100644 assets/icons/16/ATVCDE16.png create mode 100644 assets/icons/16/ATVCPT16.png create mode 100644 assets/icons/16/ATVDET16.png create mode 100644 assets/icons/16/ATVGRD16.png create mode 100644 assets/icons/16/ATVHST16.png create mode 100644 assets/icons/16/ATVLKC16.png create mode 100644 assets/icons/16/ATVLKR16.png create mode 100644 assets/icons/16/ATVMM.png create mode 100644 assets/icons/16/ATVNET16.png create mode 100644 assets/icons/16/ATVNWT16.png create mode 100644 assets/icons/16/ATVPRD16.png create mode 100644 assets/icons/16/ATVSPD16.png create mode 100644 assets/icons/16/ATVSUC16.png create mode 100644 assets/icons/16/BACK16.png create mode 100644 assets/icons/16/BACK3D16.png create mode 100644 assets/icons/16/BASLNE16.png create mode 100644 assets/icons/16/BLANK16.png create mode 100644 assets/icons/16/BRGRPH16.png create mode 100644 assets/icons/16/CANCEL16.png create mode 100644 assets/icons/16/CBRANCH.png create mode 100644 assets/icons/16/CDROM.png create mode 100644 assets/icons/16/CHKBX016.png create mode 100644 assets/icons/16/CHKBX116.png create mode 100644 assets/icons/16/CHKBX216.png create mode 100644 assets/icons/16/CHRTLY16.png create mode 100644 assets/icons/16/CHRTVW16.png create mode 100644 assets/icons/16/CLEAF.png create mode 100644 assets/icons/16/CLNDR16.png create mode 100644 assets/icons/16/CLOSE16.png create mode 100644 assets/icons/16/CLOSEDFOLDER.png create mode 100644 assets/icons/16/COLALL16.png create mode 100644 assets/icons/16/COLLAY16.png create mode 100644 assets/icons/16/COPY16.png create mode 100644 assets/icons/16/CTREE.png create mode 100644 assets/icons/16/CURRENTFOLDER.png create mode 100644 assets/icons/16/CUT16.png create mode 100644 assets/icons/16/CXEDIT_GLYPH_ERROR.png create mode 100644 assets/icons/16/CXEDIT_GLYPH_INFO.png create mode 100644 assets/icons/16/CXEDIT_GLYPH_WARNING.png create mode 100644 assets/icons/16/DATRNG16.png create mode 100644 assets/icons/16/DELETE16.png create mode 100644 assets/icons/16/DELIV16.png create mode 100644 assets/icons/16/DIALOG16.png create mode 100644 assets/icons/16/DIRCTY16.png create mode 100644 assets/icons/16/DLTARW16.png create mode 100644 assets/icons/16/DLVCUR16.png create mode 100644 assets/icons/16/DOCCUR16.png create mode 100644 assets/icons/16/DOCMNT16.png create mode 100644 assets/icons/16/DOCMNTMM.png create mode 100644 assets/icons/16/DRTARW16.png create mode 100644 assets/icons/16/DWNARW16.png create mode 100644 assets/icons/16/EDITRC16.png create mode 100644 assets/icons/16/EPS16.png create mode 100644 assets/icons/16/ERRORDG.png create mode 100644 assets/icons/16/ESTMAT16.png create mode 100644 assets/icons/16/EXECUTABLE.png create mode 100644 assets/icons/16/EXPALL16.png create mode 100644 assets/icons/16/EXPENSMM.png create mode 100644 assets/icons/16/EXPNSE16.png create mode 100644 assets/icons/16/EXPORT16.png create mode 100644 assets/icons/16/FACTOR16.png create mode 100644 assets/icons/16/FACTVL16.png create mode 100644 assets/icons/16/FILDWN16.png create mode 100644 assets/icons/16/FILTER16.png create mode 100644 assets/icons/16/FIND16.png create mode 100644 assets/icons/16/FINISH16.png create mode 100644 assets/icons/16/FLOPPY.png create mode 100644 assets/icons/16/FTCLRS16.png create mode 100644 assets/icons/16/GANTT16.png create mode 100644 assets/icons/16/GLOBAL16.png create mode 100644 assets/icons/16/GLOBVW16.png create mode 100644 assets/icons/16/GRPSRT16.png create mode 100644 assets/icons/16/HARD.png create mode 100644 assets/icons/16/HDETHZ16.png create mode 100644 assets/icons/16/HDETVT16.png create mode 100644 assets/icons/16/HELP16.png create mode 100644 assets/icons/16/HELP3D16.png create mode 100644 assets/icons/16/HIDEDT16.png create mode 100644 assets/icons/16/HINT16.png create mode 100644 assets/icons/16/HINT3D16.png create mode 100644 assets/icons/16/HLPCNT16.png create mode 100644 assets/icons/16/HOME16.png create mode 100644 assets/icons/16/HSTGRM16.png create mode 100644 assets/icons/16/ID_1001.png create mode 100644 assets/icons/16/ID_1002.png create mode 100644 assets/icons/16/ID_1005.png create mode 100644 assets/icons/16/IMG_ICO_EPS.png create mode 100644 assets/icons/16/IMG_ICO_EPS_CHECKED.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_CLOSED.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_CLOSED_CHECKED.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_CLOSED_WHATIF.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_OPEN.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_OPEN_CHECKED.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png create mode 100644 assets/icons/16/IMG_ICO_PROJ_OPEN_WHATIF.png create mode 100644 assets/icons/16/IMPORT16.png create mode 100644 assets/icons/16/INFODG.png create mode 100644 assets/icons/16/ISSUE16.png create mode 100644 assets/icons/16/ISSUESMM.png create mode 100644 assets/icons/16/JUMP16.png create mode 100644 assets/icons/16/KNOWNFILE.png create mode 100644 assets/icons/16/LEVELR16.png create mode 100644 assets/icons/16/LFTARW16.png create mode 100644 assets/icons/16/LOCK16.png create mode 100644 assets/icons/16/MAINICON.png create mode 100644 assets/icons/16/MEMO16.png create mode 100644 assets/icons/16/MEMOEM16.png create mode 100644 assets/icons/16/MEMOFL16.png create mode 100644 assets/icons/16/MSG_ERROR.png create mode 100644 assets/icons/16/MSG_INFO.png create mode 100644 assets/icons/16/MSG_WARNING.png create mode 100644 assets/icons/16/MTHLNKMM.png create mode 100644 assets/icons/16/NETWORK.png create mode 100644 assets/icons/16/NEW16.png create mode 100644 assets/icons/16/NEXT16.png create mode 100644 assets/icons/16/NEXT3D16.png create mode 100644 assets/icons/16/NLRCUR16.png create mode 100644 assets/icons/16/NLRSRC16.png create mode 100644 assets/icons/16/NLRSU16.png create mode 100644 assets/icons/16/NLRSUC16.png create mode 100644 assets/icons/16/OBS16.png create mode 100644 assets/icons/16/OBSMM.png create mode 100644 assets/icons/16/OBSROT16.png create mode 100644 assets/icons/16/OK16.png create mode 100644 assets/icons/16/OPEN16.png create mode 100644 assets/icons/16/OPENFOLDER.png create mode 100644 assets/icons/16/OPTBAR16.png create mode 100644 assets/icons/16/OVRHD16.png create mode 100644 assets/icons/16/OXACPBACK16.png create mode 100644 assets/icons/16/OXACPFEWER16.png create mode 100644 assets/icons/16/OXACPFWD16.png create mode 100644 assets/icons/16/OXACPGROUP16.png create mode 100644 assets/icons/16/OXACPMORE16.png create mode 100644 assets/icons/16/OXACPRES16.png create mode 100644 assets/icons/16/OXACPSELECT16.png create mode 100644 assets/icons/16/OXACPSHOW16.png create mode 100644 assets/icons/16/OXBOLD16.png create mode 100644 assets/icons/16/OXBULLET16.png create mode 100644 assets/icons/16/OXCLRFMT16.png create mode 100644 assets/icons/16/OXITALIC16.png create mode 100644 assets/icons/16/OXLINENO16.png create mode 100644 assets/icons/16/OXLINK16.png create mode 100644 assets/icons/16/OXMATRSRC16.png create mode 100644 assets/icons/16/OXNUMBER16.png create mode 100644 assets/icons/16/OXONLHLP16.png create mode 100644 assets/icons/16/OXPRGLIN16.png create mode 100644 assets/icons/16/OXRPTEDT16.png create mode 100644 assets/icons/16/OXRPTWIZ16.png create mode 100644 assets/icons/16/OXRUNBAT16.png create mode 100644 assets/icons/16/OXSPOTLT16.png create mode 100644 assets/icons/16/OXTABHZ16.png create mode 100644 assets/icons/16/OXTABMG16.png create mode 100644 assets/icons/16/OXTABVT16.png create mode 100644 assets/icons/16/OXUNDERL16.png create mode 100644 assets/icons/16/OXUNLINK16.png create mode 100644 assets/icons/16/OXWHTNW16.png create mode 100644 assets/icons/16/PASTE16.png create mode 100644 assets/icons/16/PCDCUR16.png create mode 100644 assets/icons/16/PEGACT16.png create mode 100644 assets/icons/16/PEGTS16.png create mode 100644 assets/icons/16/PGSETP16.png create mode 100644 assets/icons/16/PJOCKO16.png create mode 100644 assets/icons/16/PJOWCO16.png create mode 100644 assets/icons/16/PJOWIF16.png create mode 100644 assets/icons/16/PRCDUR16.png create mode 100644 assets/icons/16/PREVIEWGLYPH.png create mode 100644 assets/icons/16/PRINT16.png create mode 100644 assets/icons/16/PRIVLG16.png create mode 100644 assets/icons/16/PRJCKO16.png create mode 100644 assets/icons/16/PRJOPN16.png create mode 100644 assets/icons/16/PRJWCO16.png create mode 100644 assets/icons/16/PRJWIF16.png create mode 100644 assets/icons/16/PROFLE16.png create mode 100644 assets/icons/16/PROJCD16.png create mode 100644 assets/icons/16/PROJCT16.png create mode 100644 assets/icons/16/PROJMM.png create mode 100644 assets/icons/16/PRTFGL16.png create mode 100644 assets/icons/16/PRTFLO16.png create mode 100644 assets/icons/16/PRTFOP16.png create mode 100644 assets/icons/16/PRTOGB16.png create mode 100644 assets/icons/16/PRVIEW16.png create mode 100644 assets/icons/16/QALITY16.png create mode 100644 assets/icons/16/QUESTNDG.png create mode 100644 assets/icons/16/QULCUR16.png create mode 100644 assets/icons/16/RADBX016.png create mode 100644 assets/icons/16/RADBX116.png create mode 100644 assets/icons/16/RAM.png create mode 100644 assets/icons/16/REFRSH16.png create mode 100644 assets/icons/16/REMOVE16.png create mode 100644 assets/icons/16/REORGZ16.png create mode 100644 assets/icons/16/REPLAC16.png create mode 100644 assets/icons/16/REPORT16.png create mode 100644 assets/icons/16/REPRTSMM.png create mode 100644 assets/icons/16/RESHST16.png create mode 100644 assets/icons/16/RES_RL16.png create mode 100644 assets/icons/16/RGTARW16.png create mode 100644 assets/icons/16/RISK16.png create mode 100644 assets/icons/16/RISKSMM.png create mode 100644 assets/icons/16/RLATSK16.png create mode 100644 assets/icons/16/ROLCUR16.png create mode 100644 assets/icons/16/ROLE16.png create mode 100644 assets/icons/16/ROLEOP16.png create mode 100644 assets/icons/16/ROLESMM.png create mode 100644 assets/icons/16/RORGAL16.png create mode 100644 assets/icons/16/RPADDG16.png create mode 100644 assets/icons/16/RPADDI16.png create mode 100644 assets/icons/16/RPADDL16.png create mode 100644 assets/icons/16/RPADDR16.png create mode 100644 assets/icons/16/RPADDT16.png create mode 100644 assets/icons/16/RPEDIT16.png create mode 100644 assets/icons/16/RPEXP16.png create mode 100644 assets/icons/16/RPIMP16.png create mode 100644 assets/icons/16/RPPGF16.png create mode 100644 assets/icons/16/RPPGL16.png create mode 100644 assets/icons/16/RPPGN16.png create mode 100644 assets/icons/16/RPPGP16.png create mode 100644 assets/icons/16/RPTGLB16.png create mode 100644 assets/icons/16/RPTGRP16.png create mode 100644 assets/icons/16/RPTWZD16.png create mode 100644 assets/icons/16/RSATSK16.png create mode 100644 assets/icons/16/RSCNWK16.png create mode 100644 assets/icons/16/RSCSPD16.png create mode 100644 assets/icons/16/RSRC16.png create mode 100644 assets/icons/16/RSRCCD16.png create mode 100644 assets/icons/16/RSRCOP16.png create mode 100644 assets/icons/16/RSRCPLMM.png create mode 100644 assets/icons/16/RSRCPR16.png create mode 100644 assets/icons/16/RSRCU16.png create mode 100644 assets/icons/16/RSRCUC16.png create mode 100644 assets/icons/16/RSRCUR16.png create mode 100644 assets/icons/16/RUN16.png create mode 100644 assets/icons/16/RUNBAT16.png create mode 100644 assets/icons/16/SAVE16.png create mode 100644 assets/icons/16/SAVEAS16.png create mode 100644 assets/icons/16/SCHDUL16.png create mode 100644 assets/icons/16/SEARCH16.png create mode 100644 assets/icons/16/SELBX016.png create mode 100644 assets/icons/16/SELBX116.png create mode 100644 assets/icons/16/SELECT16.png create mode 100644 assets/icons/16/SHOWRELBTN16.png create mode 100644 assets/icons/16/SHOWRESCURVES16.png create mode 100644 assets/icons/16/SPLCHK16.png create mode 100644 assets/icons/16/SPNDWN16.png create mode 100644 assets/icons/16/SPNUP16.png create mode 100644 assets/icons/16/STDCUR16.png create mode 100644 assets/icons/16/STEPD16.png create mode 100644 assets/icons/16/STEPND16.png create mode 100644 assets/icons/16/STNDRD16.png create mode 100644 assets/icons/16/SUBMIT16.png create mode 100644 assets/icons/16/THRHLDMM.png create mode 100644 assets/icons/16/THSHLD16.png create mode 100644 assets/icons/16/TMAPVL16.png create mode 100644 assets/icons/16/TMPLAT16.png create mode 100644 assets/icons/16/TMSHT16.png create mode 100644 assets/icons/16/TPLGIN16.png create mode 100644 assets/icons/16/TPOOL16.png create mode 100644 assets/icons/16/TRACK16.png create mode 100644 assets/icons/16/TRACKMM.png create mode 100644 assets/icons/16/UNDO16.png create mode 100644 assets/icons/16/UNKNOWNFILE.png create mode 100644 assets/icons/16/UNLOCK16.png create mode 100644 assets/icons/16/UNSEL16.png create mode 100644 assets/icons/16/UPARW16.png create mode 100644 assets/icons/16/USER16.png create mode 100644 assets/icons/16/USRCUR16.png create mode 100644 assets/icons/16/VIEWS16.png create mode 100644 assets/icons/16/VMENU_ICO_ALIGN_CENTER.png create mode 100644 assets/icons/16/VMENU_ICO_ALIGN_LEFT.png create mode 100644 assets/icons/16/VMENU_ICO_ALIGN_RIGHT.png create mode 100644 assets/icons/16/VMENU_ICO_ARRANGE_HORZ.png create mode 100644 assets/icons/16/VMENU_ICO_ARRANGE_VERT.png create mode 100644 assets/icons/16/VMENU_ICO_CHART_FONT_COLOR.png create mode 100644 assets/icons/16/VMENU_ICO_CHART_LAYOUT.png create mode 100644 assets/icons/16/VMENU_ICO_CHART_VIEW.png create mode 100644 assets/icons/16/VMENU_ICO_COLLAPSE_ALL.png create mode 100644 assets/icons/16/VMENU_ICO_COLLAPSE_TO.png create mode 100644 assets/icons/16/VMENU_ICO_COLUMNS.png create mode 100644 assets/icons/16/VMENU_ICO_COPY.png create mode 100644 assets/icons/16/VMENU_ICO_CUT.png create mode 100644 assets/icons/16/VMENU_ICO_DELETE.png create mode 100644 assets/icons/16/VMENU_ICO_EXPAND_ALL.png create mode 100644 assets/icons/16/VMENU_ICO_FILLDOWN.png create mode 100644 assets/icons/16/VMENU_ICO_FILTER.png create mode 100644 assets/icons/16/VMENU_ICO_FIND.png create mode 100644 assets/icons/16/VMENU_ICO_GRID_FONT_COLOR.png create mode 100644 assets/icons/16/VMENU_ICO_GROUPING.png create mode 100644 assets/icons/16/VMENU_ICO_INSERT.png create mode 100644 assets/icons/16/VMENU_ICO_NEW.png create mode 100644 assets/icons/16/VMENU_ICO_OPEN.png create mode 100644 assets/icons/16/VMENU_ICO_PASTE.png create mode 100644 assets/icons/16/VMENU_ICO_PRINT.png create mode 100644 assets/icons/16/VMENU_ICO_PRINT_PREVIEW.png create mode 100644 assets/icons/16/VMENU_ICO_SAVE.png create mode 100644 assets/icons/16/VMENU_ICO_SPELL_CHECK.png create mode 100644 assets/icons/16/VMENU_ICO_ZOOM_BEST_FIT.png create mode 100644 assets/icons/16/VMENU_ICO_ZOOM_IN.png create mode 100644 assets/icons/16/VMENU_ICO_ZOOM_OUT.png create mode 100644 assets/icons/16/WARNDG.png create mode 100644 assets/icons/16/WBS16.png create mode 100644 assets/icons/16/WBSLKC16.png create mode 100644 assets/icons/16/WBSLKR16.png create mode 100644 assets/icons/16/WBSMM.png create mode 100644 assets/icons/16/WBSROT16.png create mode 100644 assets/icons/16/WIZARD16.png create mode 100644 assets/icons/16/ZOOMIN16.png create mode 100644 assets/icons/16/ZOOMOT16.png create mode 100644 assets/icons/16/ZOOMTF16.png create mode 100644 assets/icons/32/ACCUNT16.png create mode 100644 assets/icons/32/ACTCTP16.png create mode 100644 assets/icons/32/ACTCUR16.png create mode 100644 assets/icons/32/ACTINP16.png create mode 100644 assets/icons/32/ACTIPP16.png create mode 100644 assets/icons/32/ACTPRM16.png create mode 100644 assets/icons/32/ACTRJ16.png create mode 100644 assets/icons/32/ACTRJP16.png create mode 100644 assets/icons/32/ADD16.png create mode 100644 assets/icons/32/ALGNCT16.png create mode 100644 assets/icons/32/ALGNLT16.png create mode 100644 assets/icons/32/ALGNRT16.png create mode 100644 assets/icons/32/APPLY16.png create mode 100644 assets/icons/32/ARHORZ16.png create mode 100644 assets/icons/32/ARVERT16.png create mode 100644 assets/icons/32/ASSIGN16.png create mode 100644 assets/icons/32/ATV16.png create mode 100644 assets/icons/32/ATVCDE16.png create mode 100644 assets/icons/32/ATVCPT16.png create mode 100644 assets/icons/32/ATVDET16.png create mode 100644 assets/icons/32/ATVGRD16.png create mode 100644 assets/icons/32/ATVHST16.png create mode 100644 assets/icons/32/ATVLKC16.png create mode 100644 assets/icons/32/ATVLKR16.png create mode 100644 assets/icons/32/ATVMM.png create mode 100644 assets/icons/32/ATVNET16.png create mode 100644 assets/icons/32/ATVNWT16.png create mode 100644 assets/icons/32/ATVPRD16.png create mode 100644 assets/icons/32/ATVSPD16.png create mode 100644 assets/icons/32/ATVSUC16.png create mode 100644 assets/icons/32/BACK16.png create mode 100644 assets/icons/32/BACK3D16.png create mode 100644 assets/icons/32/BASLNE16.png create mode 100644 assets/icons/32/BLANK16.png create mode 100644 assets/icons/32/BRGRPH16.png create mode 100644 assets/icons/32/CANCEL16.png create mode 100644 assets/icons/32/CBRANCH.png create mode 100644 assets/icons/32/CDROM.png create mode 100644 assets/icons/32/CHKBX016.png create mode 100644 assets/icons/32/CHKBX116.png create mode 100644 assets/icons/32/CHKBX216.png create mode 100644 assets/icons/32/CHRTLY16.png create mode 100644 assets/icons/32/CHRTVW16.png create mode 100644 assets/icons/32/CLEAF.png create mode 100644 assets/icons/32/CLNDR16.png create mode 100644 assets/icons/32/CLOSE16.png create mode 100644 assets/icons/32/CLOSEDFOLDER.png create mode 100644 assets/icons/32/COLALL16.png create mode 100644 assets/icons/32/COLLAY16.png create mode 100644 assets/icons/32/COPY16.png create mode 100644 assets/icons/32/CTREE.png create mode 100644 assets/icons/32/CURRENTFOLDER.png create mode 100644 assets/icons/32/CUT16.png create mode 100644 assets/icons/32/CXEDIT_GLYPH_ERROR.png create mode 100644 assets/icons/32/CXEDIT_GLYPH_INFO.png create mode 100644 assets/icons/32/CXEDIT_GLYPH_WARNING.png create mode 100644 assets/icons/32/DATRNG16.png create mode 100644 assets/icons/32/DELETE16.png create mode 100644 assets/icons/32/DELIV16.png create mode 100644 assets/icons/32/DIALOG16.png create mode 100644 assets/icons/32/DIRCTY16.png create mode 100644 assets/icons/32/DLTARW16.png create mode 100644 assets/icons/32/DLVCUR16.png create mode 100644 assets/icons/32/DOCCUR16.png create mode 100644 assets/icons/32/DOCMNT16.png create mode 100644 assets/icons/32/DOCMNTMM.png create mode 100644 assets/icons/32/DRTARW16.png create mode 100644 assets/icons/32/DWNARW16.png create mode 100644 assets/icons/32/EDITRC16.png create mode 100644 assets/icons/32/EPS16.png create mode 100644 assets/icons/32/ERRORDG.png create mode 100644 assets/icons/32/ESTMAT16.png create mode 100644 assets/icons/32/EXECUTABLE.png create mode 100644 assets/icons/32/EXPALL16.png create mode 100644 assets/icons/32/EXPENSMM.png create mode 100644 assets/icons/32/EXPNSE16.png create mode 100644 assets/icons/32/EXPORT16.png create mode 100644 assets/icons/32/FACTOR16.png create mode 100644 assets/icons/32/FACTVL16.png create mode 100644 assets/icons/32/FILDWN16.png create mode 100644 assets/icons/32/FILTER16.png create mode 100644 assets/icons/32/FIND16.png create mode 100644 assets/icons/32/FINISH16.png create mode 100644 assets/icons/32/FLOPPY.png create mode 100644 assets/icons/32/FTCLRS16.png create mode 100644 assets/icons/32/GANTT16.png create mode 100644 assets/icons/32/GLOBAL16.png create mode 100644 assets/icons/32/GLOBVW16.png create mode 100644 assets/icons/32/GRPSRT16.png create mode 100644 assets/icons/32/HARD.png create mode 100644 assets/icons/32/HDETHZ16.png create mode 100644 assets/icons/32/HDETVT16.png create mode 100644 assets/icons/32/HELP16.png create mode 100644 assets/icons/32/HELP3D16.png create mode 100644 assets/icons/32/HIDEDT16.png create mode 100644 assets/icons/32/HINT16.png create mode 100644 assets/icons/32/HINT3D16.png create mode 100644 assets/icons/32/HLPCNT16.png create mode 100644 assets/icons/32/HOME16.png create mode 100644 assets/icons/32/HSTGRM16.png create mode 100644 assets/icons/32/ID_1001.png create mode 100644 assets/icons/32/ID_1002.png create mode 100644 assets/icons/32/ID_1005.png create mode 100644 assets/icons/32/IMG_ICO_EPS.png create mode 100644 assets/icons/32/IMG_ICO_EPS_CHECKED.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_CLOSED.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_CLOSED_CHECKED.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_CLOSED_WHATIF.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_OPEN.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_OPEN_CHECKED.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png create mode 100644 assets/icons/32/IMG_ICO_PROJ_OPEN_WHATIF.png create mode 100644 assets/icons/32/IMPORT16.png create mode 100644 assets/icons/32/INFODG.png create mode 100644 assets/icons/32/ISSUE16.png create mode 100644 assets/icons/32/ISSUESMM.png create mode 100644 assets/icons/32/JUMP16.png create mode 100644 assets/icons/32/KNOWNFILE.png create mode 100644 assets/icons/32/LEVELR16.png create mode 100644 assets/icons/32/LFTARW16.png create mode 100644 assets/icons/32/LOCK16.png create mode 100644 assets/icons/32/MAINICON.png create mode 100644 assets/icons/32/MEMO16.png create mode 100644 assets/icons/32/MEMOEM16.png create mode 100644 assets/icons/32/MEMOFL16.png create mode 100644 assets/icons/32/MSG_ERROR.png create mode 100644 assets/icons/32/MSG_INFO.png create mode 100644 assets/icons/32/MSG_WARNING.png create mode 100644 assets/icons/32/MTHLNKMM.png create mode 100644 assets/icons/32/NETWORK.png create mode 100644 assets/icons/32/NEW16.png create mode 100644 assets/icons/32/NEXT16.png create mode 100644 assets/icons/32/NEXT3D16.png create mode 100644 assets/icons/32/NLRCUR16.png create mode 100644 assets/icons/32/NLRSRC16.png create mode 100644 assets/icons/32/NLRSU16.png create mode 100644 assets/icons/32/NLRSUC16.png create mode 100644 assets/icons/32/OBS16.png create mode 100644 assets/icons/32/OBSMM.png create mode 100644 assets/icons/32/OBSROT16.png create mode 100644 assets/icons/32/OK16.png create mode 100644 assets/icons/32/OPEN16.png create mode 100644 assets/icons/32/OPENFOLDER.png create mode 100644 assets/icons/32/OPTBAR16.png create mode 100644 assets/icons/32/OVRHD16.png create mode 100644 assets/icons/32/OXACPBACK16.png create mode 100644 assets/icons/32/OXACPFEWER16.png create mode 100644 assets/icons/32/OXACPFWD16.png create mode 100644 assets/icons/32/OXACPGROUP16.png create mode 100644 assets/icons/32/OXACPMORE16.png create mode 100644 assets/icons/32/OXACPRES16.png create mode 100644 assets/icons/32/OXACPSELECT16.png create mode 100644 assets/icons/32/OXACPSHOW16.png create mode 100644 assets/icons/32/OXBOLD16.png create mode 100644 assets/icons/32/OXBULLET16.png create mode 100644 assets/icons/32/OXCLRFMT16.png create mode 100644 assets/icons/32/OXITALIC16.png create mode 100644 assets/icons/32/OXLINENO16.png create mode 100644 assets/icons/32/OXLINK16.png create mode 100644 assets/icons/32/OXMATRSRC16.png create mode 100644 assets/icons/32/OXNUMBER16.png create mode 100644 assets/icons/32/OXONLHLP16.png create mode 100644 assets/icons/32/OXPRGLIN16.png create mode 100644 assets/icons/32/OXRPTEDT16.png create mode 100644 assets/icons/32/OXRPTWIZ16.png create mode 100644 assets/icons/32/OXRUNBAT16.png create mode 100644 assets/icons/32/OXSPOTLT16.png create mode 100644 assets/icons/32/OXTABHZ16.png create mode 100644 assets/icons/32/OXTABMG16.png create mode 100644 assets/icons/32/OXTABVT16.png create mode 100644 assets/icons/32/OXUNDERL16.png create mode 100644 assets/icons/32/OXUNLINK16.png create mode 100644 assets/icons/32/OXWHTNW16.png create mode 100644 assets/icons/32/PASTE16.png create mode 100644 assets/icons/32/PCDCUR16.png create mode 100644 assets/icons/32/PEGACT16.png create mode 100644 assets/icons/32/PEGTS16.png create mode 100644 assets/icons/32/PGSETP16.png create mode 100644 assets/icons/32/PJOCKO16.png create mode 100644 assets/icons/32/PJOWCO16.png create mode 100644 assets/icons/32/PJOWIF16.png create mode 100644 assets/icons/32/PRCDUR16.png create mode 100644 assets/icons/32/PREVIEWGLYPH.png create mode 100644 assets/icons/32/PRINT16.png create mode 100644 assets/icons/32/PRIVLG16.png create mode 100644 assets/icons/32/PRJCKO16.png create mode 100644 assets/icons/32/PRJOPN16.png create mode 100644 assets/icons/32/PRJWCO16.png create mode 100644 assets/icons/32/PRJWIF16.png create mode 100644 assets/icons/32/PROFLE16.png create mode 100644 assets/icons/32/PROJCD16.png create mode 100644 assets/icons/32/PROJCT16.png create mode 100644 assets/icons/32/PROJMM.png create mode 100644 assets/icons/32/PRTFGL16.png create mode 100644 assets/icons/32/PRTFLO16.png create mode 100644 assets/icons/32/PRTFOP16.png create mode 100644 assets/icons/32/PRTOGB16.png create mode 100644 assets/icons/32/PRVIEW16.png create mode 100644 assets/icons/32/QALITY16.png create mode 100644 assets/icons/32/QUESTNDG.png create mode 100644 assets/icons/32/QULCUR16.png create mode 100644 assets/icons/32/RADBX016.png create mode 100644 assets/icons/32/RADBX116.png create mode 100644 assets/icons/32/RAM.png create mode 100644 assets/icons/32/REFRSH16.png create mode 100644 assets/icons/32/REMOVE16.png create mode 100644 assets/icons/32/REORGZ16.png create mode 100644 assets/icons/32/REPLAC16.png create mode 100644 assets/icons/32/REPORT16.png create mode 100644 assets/icons/32/REPRTSMM.png create mode 100644 assets/icons/32/RESHST16.png create mode 100644 assets/icons/32/RES_RL16.png create mode 100644 assets/icons/32/RGTARW16.png create mode 100644 assets/icons/32/RISK16.png create mode 100644 assets/icons/32/RISKSMM.png create mode 100644 assets/icons/32/RLATSK16.png create mode 100644 assets/icons/32/ROLCUR16.png create mode 100644 assets/icons/32/ROLE16.png create mode 100644 assets/icons/32/ROLEOP16.png create mode 100644 assets/icons/32/ROLESMM.png create mode 100644 assets/icons/32/RORGAL16.png create mode 100644 assets/icons/32/RPADDG16.png create mode 100644 assets/icons/32/RPADDI16.png create mode 100644 assets/icons/32/RPADDL16.png create mode 100644 assets/icons/32/RPADDR16.png create mode 100644 assets/icons/32/RPADDT16.png create mode 100644 assets/icons/32/RPEDIT16.png create mode 100644 assets/icons/32/RPEXP16.png create mode 100644 assets/icons/32/RPIMP16.png create mode 100644 assets/icons/32/RPPGF16.png create mode 100644 assets/icons/32/RPPGL16.png create mode 100644 assets/icons/32/RPPGN16.png create mode 100644 assets/icons/32/RPPGP16.png create mode 100644 assets/icons/32/RPTGLB16.png create mode 100644 assets/icons/32/RPTGRP16.png create mode 100644 assets/icons/32/RPTWZD16.png create mode 100644 assets/icons/32/RSATSK16.png create mode 100644 assets/icons/32/RSCNWK16.png create mode 100644 assets/icons/32/RSCSPD16.png create mode 100644 assets/icons/32/RSRC16.png create mode 100644 assets/icons/32/RSRCCD16.png create mode 100644 assets/icons/32/RSRCOP16.png create mode 100644 assets/icons/32/RSRCPLMM.png create mode 100644 assets/icons/32/RSRCPR16.png create mode 100644 assets/icons/32/RSRCU16.png create mode 100644 assets/icons/32/RSRCUC16.png create mode 100644 assets/icons/32/RSRCUR16.png create mode 100644 assets/icons/32/RUN16.png create mode 100644 assets/icons/32/RUNBAT16.png create mode 100644 assets/icons/32/SAVE16.png create mode 100644 assets/icons/32/SAVEAS16.png create mode 100644 assets/icons/32/SCHDUL16.png create mode 100644 assets/icons/32/SEARCH16.png create mode 100644 assets/icons/32/SELBX016.png create mode 100644 assets/icons/32/SELBX116.png create mode 100644 assets/icons/32/SELECT16.png create mode 100644 assets/icons/32/SHOWRELBTN16.png create mode 100644 assets/icons/32/SHOWRESCURVES16.png create mode 100644 assets/icons/32/SPLCHK16.png create mode 100644 assets/icons/32/SPNDWN16.png create mode 100644 assets/icons/32/SPNUP16.png create mode 100644 assets/icons/32/STDCUR16.png create mode 100644 assets/icons/32/STEPD16.png create mode 100644 assets/icons/32/STEPND16.png create mode 100644 assets/icons/32/STNDRD16.png create mode 100644 assets/icons/32/SUBMIT16.png create mode 100644 assets/icons/32/THRHLDMM.png create mode 100644 assets/icons/32/THSHLD16.png create mode 100644 assets/icons/32/TMAPVL16.png create mode 100644 assets/icons/32/TMPLAT16.png create mode 100644 assets/icons/32/TMSHT16.png create mode 100644 assets/icons/32/TPLGIN16.png create mode 100644 assets/icons/32/TPOOL16.png create mode 100644 assets/icons/32/TRACK16.png create mode 100644 assets/icons/32/TRACKMM.png create mode 100644 assets/icons/32/UNDO16.png create mode 100644 assets/icons/32/UNKNOWNFILE.png create mode 100644 assets/icons/32/UNLOCK16.png create mode 100644 assets/icons/32/UNSEL16.png create mode 100644 assets/icons/32/UPARW16.png create mode 100644 assets/icons/32/USER16.png create mode 100644 assets/icons/32/USRCUR16.png create mode 100644 assets/icons/32/VIEWS16.png create mode 100644 assets/icons/32/VMENU_ICO_ALIGN_CENTER.png create mode 100644 assets/icons/32/VMENU_ICO_ALIGN_LEFT.png create mode 100644 assets/icons/32/VMENU_ICO_ALIGN_RIGHT.png create mode 100644 assets/icons/32/VMENU_ICO_ARRANGE_HORZ.png create mode 100644 assets/icons/32/VMENU_ICO_ARRANGE_VERT.png create mode 100644 assets/icons/32/VMENU_ICO_CHART_FONT_COLOR.png create mode 100644 assets/icons/32/VMENU_ICO_CHART_LAYOUT.png create mode 100644 assets/icons/32/VMENU_ICO_CHART_VIEW.png create mode 100644 assets/icons/32/VMENU_ICO_COLLAPSE_ALL.png create mode 100644 assets/icons/32/VMENU_ICO_COLLAPSE_TO.png create mode 100644 assets/icons/32/VMENU_ICO_COLUMNS.png create mode 100644 assets/icons/32/VMENU_ICO_COPY.png create mode 100644 assets/icons/32/VMENU_ICO_CUT.png create mode 100644 assets/icons/32/VMENU_ICO_DELETE.png create mode 100644 assets/icons/32/VMENU_ICO_EXPAND_ALL.png create mode 100644 assets/icons/32/VMENU_ICO_FILLDOWN.png create mode 100644 assets/icons/32/VMENU_ICO_FILTER.png create mode 100644 assets/icons/32/VMENU_ICO_FIND.png create mode 100644 assets/icons/32/VMENU_ICO_GRID_FONT_COLOR.png create mode 100644 assets/icons/32/VMENU_ICO_GROUPING.png create mode 100644 assets/icons/32/VMENU_ICO_INSERT.png create mode 100644 assets/icons/32/VMENU_ICO_NEW.png create mode 100644 assets/icons/32/VMENU_ICO_OPEN.png create mode 100644 assets/icons/32/VMENU_ICO_PASTE.png create mode 100644 assets/icons/32/VMENU_ICO_PRINT.png create mode 100644 assets/icons/32/VMENU_ICO_PRINT_PREVIEW.png create mode 100644 assets/icons/32/VMENU_ICO_SAVE.png create mode 100644 assets/icons/32/VMENU_ICO_SPELL_CHECK.png create mode 100644 assets/icons/32/VMENU_ICO_ZOOM_BEST_FIT.png create mode 100644 assets/icons/32/VMENU_ICO_ZOOM_IN.png create mode 100644 assets/icons/32/VMENU_ICO_ZOOM_OUT.png create mode 100644 assets/icons/32/WARNDG.png create mode 100644 assets/icons/32/WBS16.png create mode 100644 assets/icons/32/WBSLKC16.png create mode 100644 assets/icons/32/WBSLKR16.png create mode 100644 assets/icons/32/WBSMM.png create mode 100644 assets/icons/32/WBSROT16.png create mode 100644 assets/icons/32/WIZARD16.png create mode 100644 assets/icons/32/ZOOMIN16.png create mode 100644 assets/icons/32/ZOOMOT16.png create mode 100644 assets/icons/32/ZOOMTF16.png create mode 100644 assets/icons/openxer.ico create mode 100644 assets/icons/openxer_256.png create mode 100644 assets/openxer_reports/activities-by-status.rpt create mode 100644 assets/openxer_reports/assignments-by-resource.rpt create mode 100644 assets/openxer_reports/baseline-variance.rpt create mode 100644 assets/openxer_reports/critical-activities.rpt create mode 100644 assets/openxer_reports/critical-and-near-critical.rpt create mode 100644 assets/openxer_reports/lookahead-2-week-by-wbs.rpt create mode 100644 assets/openxer_reports/lookahead-3-week-by-wbs.rpt create mode 100644 assets/openxer_reports/milestones.rpt create mode 100644 assets/openxer_reports/open-ends-and-logic-gaps.rpt create mode 100644 assets/openxer_reports/predecessors-and-successors.rpt create mode 100644 assets/openxer_reports/progress-this-period.rpt create mode 100644 assets/openxer_reports/resource-usage-by-week.rpt create mode 100644 assets/openxer_reports/wbs-summary.rpt create mode 100644 assets/playbooks/audit.md create mode 100644 assets/playbooks/build.md create mode 100644 assets/playbooks/critical-path.md create mode 100644 assets/playbooks/delay-recovery.md create mode 100644 assets/playbooks/earned-value.md create mode 100644 assets/playbooks/lookahead.md create mode 100644 assets/playbooks/narrative.md create mode 100644 assets/playbooks/resource-review.md create mode 100644 assets/playbooks/schedule-check.md create mode 100644 assets/playbooks/update.md create mode 100644 assets/playbooks/what-if.md create mode 100644 assets/sample-project.txt create mode 100644 assets/skills/activity-definition-review.md create mode 100644 assets/skills/add-scope.md create mode 100644 assets/skills/baseline-review.md create mode 100644 assets/skills/baseline-variance.md create mode 100644 assets/skills/build-schedule.md create mode 100644 assets/skills/calendar-duration-check.md create mode 100644 assets/skills/change-interview.md create mode 100644 assets/skills/compare-files.md create mode 100644 assets/skills/contingency-float.md create mode 100644 assets/skills/critical-path-explained.md create mode 100644 assets/skills/duration-review.md create mode 100644 assets/skills/export-pack.md create mode 100644 assets/skills/float-constraint-review.md create mode 100644 assets/skills/levels-of-detail.md create mode 100644 assets/skills/logic-health-check.md create mode 100644 assets/skills/look-ahead.md create mode 100644 assets/skills/milestone-status.md create mode 100644 assets/skills/near-critical-paths.md create mode 100644 assets/skills/one-page-schedule.md create mode 100644 assets/skills/progress-update.md create mode 100644 assets/skills/recovery-schedule.md create mode 100644 assets/skills/resource-load.md create mode 100644 assets/skills/resource-loading-review.md create mode 100644 assets/skills/risk-read.md create mode 100644 assets/skills/schedule-basis.md create mode 100644 assets/skills/schedule-maturity.md create mode 100644 assets/skills/schedule-review.md create mode 100644 assets/skills/sequence-review.md create mode 100644 assets/skills/time-impact.md create mode 100644 assets/skills/update-review.md create mode 100644 assets/skills/weather-nonwork.md create mode 100644 assets/skills/what-if.md create mode 100644 automation/COVERAGE.md create mode 100644 automation/Cargo.toml create mode 100644 automation/README.md create mode 100644 automation/build.rs create mode 100644 automation/src/agent_host/claude.rs create mode 100644 automation/src/agent_host/codex.rs create mode 100644 automation/src/agent_host/compat.rs create mode 100644 automation/src/agent_host/mod.rs create mode 100644 automation/src/agent_host/process.rs create mode 100644 automation/src/analysis.rs create mode 100644 automation/src/baseline_cmd.rs create mode 100644 automation/src/baseline_ops.rs create mode 100644 automation/src/baseline_store.rs create mode 100644 automation/src/baselines.rs create mode 100644 automation/src/chat_prompt.rs create mode 100644 automation/src/chat_tools.rs create mode 100644 automation/src/checks.rs create mode 100644 automation/src/cli.rs create mode 100644 automation/src/connect.rs create mode 100644 automation/src/connect/tests.rs create mode 100644 automation/src/documents.rs create mode 100644 automation/src/edit.rs create mode 100644 automation/src/eps.rs create mode 100644 automation/src/global_change.rs create mode 100644 automation/src/interchange.rs create mode 100644 automation/src/lib.rs create mode 100644 automation/src/load.rs create mode 100644 automation/src/locate.rs create mode 100644 automation/src/main.rs create mode 100644 automation/src/mcp.rs create mode 100644 automation/src/pdf.rs create mode 100644 automation/src/playbooks.rs create mode 100644 automation/src/registers.rs create mode 100644 automation/src/reports.rs create mode 100644 automation/src/schedule_check.rs create mode 100644 automation/src/skills.rs create mode 100644 automation/src/skills_tests.rs create mode 100644 automation/src/storage.rs create mode 100644 automation/src/usage.rs create mode 100644 automation/src/user_prefs.rs create mode 100644 automation/src/workspace_cmd.rs create mode 100644 automation/src/workspace_db.rs create mode 100644 automation/src/workspace_db/migrate.rs create mode 100644 automation/src/workspace_db/tests.rs create mode 100644 automation/tests/agent_host.rs create mode 100644 automation/tests/agent_live.rs create mode 100644 automation/tests/agent_shapes.rs create mode 100644 automation/tests/automation.rs create mode 100644 automation/tests/baseline.rs create mode 100644 automation/tests/baseline_update.rs create mode 100644 automation/tests/batch3.rs create mode 100644 automation/tests/chat_prompt.rs create mode 100644 automation/tests/chat_tools.rs create mode 100644 automation/tests/cli.rs create mode 100644 automation/tests/connect.rs create mode 100644 automation/tests/coverage.rs create mode 100644 automation/tests/curves.rs create mode 100644 automation/tests/dissolve.rs create mode 100644 automation/tests/documents.rs create mode 100644 automation/tests/edit.rs create mode 100644 automation/tests/edit_contract.rs create mode 100644 automation/tests/eps.rs create mode 100644 automation/tests/financial_periods.rs create mode 100644 automation/tests/fixtures/agent/claude-two-turns.jsonl create mode 100644 automation/tests/fixtures/agent/codex-two-turns.jsonl create mode 100644 automation/tests/global_change.rs create mode 100644 automation/tests/interchange.rs create mode 100644 automation/tests/local_reference.rs create mode 100644 automation/tests/milestones.rs create mode 100644 automation/tests/new_activity.rs create mode 100644 automation/tests/pdf.rs create mode 100644 automation/tests/period_units.rs create mode 100644 automation/tests/project_numbers.rs create mode 100644 automation/tests/registers.rs create mode 100644 automation/tests/scurve.rs create mode 100644 automation/tests/skills.rs create mode 100644 automation/tests/tools.rs create mode 100644 automation/tests/workspace.rs create mode 100644 automation/tests/workspace_corpus.rs create mode 100644 chat/Cargo.toml create mode 100644 chat/examples/compat_chat.rs create mode 100644 chat/examples/live_chat.rs create mode 100644 chat/src/auth.rs create mode 100644 chat/src/client.rs create mode 100644 chat/src/compat.rs create mode 100644 chat/src/compat/tests.rs create mode 100644 chat/src/conversation.rs create mode 100644 chat/src/http.rs create mode 100644 chat/src/jwt.rs create mode 100644 chat/src/lib.rs create mode 100644 chat/src/sse.rs create mode 100644 chat/src/store.rs create mode 100644 chat/src/stream.rs create mode 100644 chat/src/testkit.rs create mode 100644 chat/src/tests/budgets.rs create mode 100644 chat/src/tests/mod.rs create mode 100644 chat/src/tests/signin.rs create mode 100644 chat/src/tests/turns.rs create mode 100644 chat/src/tools.rs create mode 100644 chat/src/unix.rs create mode 100644 chat/src/util.rs create mode 100644 chat/src/win32.rs create mode 100644 chat/tests/compat_live.rs create mode 100644 chat/tests/live.rs create mode 100644 deny.toml create mode 100644 desktop/.gitignore create mode 100644 desktop/Cargo.toml create mode 100644 desktop/assets/spell/construction.txt create mode 100644 desktop/assets/spell/words.txt create mode 100644 desktop/build.rs create mode 100644 desktop/build_release.py create mode 100644 desktop/help/activity-network-options.md create mode 100644 desktop/help/add-baseline.md create mode 100644 desktop/help/admin-preferences.md create mode 100644 desktop/help/ai-chat.md create mode 100644 desktop/help/apply-actuals.md create mode 100644 desktop/help/assign-baselines.md create mode 100644 desktop/help/assign-dialogs.md create mode 100644 desktop/help/assign-relationships.md create mode 100644 desktop/help/bar-chart-options.md create mode 100644 desktop/help/bars.md create mode 100644 desktop/help/batch-reports.md create mode 100644 desktop/help/calendar-editor.md create mode 100644 desktop/help/calendar-weekly-hours.md create mode 100644 desktop/help/calendars.md create mode 100644 desktop/help/categories-and-lists.md create mode 100644 desktop/help/chart-font-and-colors.md create mode 100644 desktop/help/check-schedule.md create mode 100644 desktop/help/codes.md create mode 100644 desktop/help/collapse-to.md create mode 100644 desktop/help/columns.md create mode 100644 desktop/help/contents.md create mode 100644 desktop/help/copy-options.md create mode 100644 desktop/help/cost-accounts.md create mode 100644 desktop/help/currencies.md create mode 100644 desktop/help/customize-activity-details.md create mode 100644 desktop/help/customize-toolbars.md create mode 100644 desktop/help/default-project.md create mode 100644 desktop/help/earned-hours.md create mode 100644 desktop/help/edit-relationship.md create mode 100644 desktop/help/export-report.md create mode 100644 desktop/help/export-wizard.md create mode 100644 desktop/help/external-applications.md create mode 100644 desktop/help/filter-editor.md create mode 100644 desktop/help/filters.md create mode 100644 desktop/help/financial-period-calendars.md create mode 100644 desktop/help/find-and-replace.md create mode 100644 desktop/help/funding-sources.md create mode 100644 desktop/help/getting-started.md create mode 100644 desktop/help/global-change-edit.md create mode 100644 desktop/help/global-change.md create mode 100644 desktop/help/group-and-sort.md create mode 100644 desktop/help/import-reports-database.md create mode 100644 desktop/help/import-reports.md create mode 100644 desktop/help/import-wizard.md create mode 100644 desktop/help/issue-navigator.md create mode 100644 desktop/help/keyboard-shortcuts.md create mode 100644 desktop/help/level-resources.md create mode 100644 desktop/help/maintain-baselines.md create mode 100644 desktop/help/merge-resources.md create mode 100644 desktop/help/monitor-thresholds.md create mode 100644 desktop/help/new-activity-wizard.md create mode 100644 desktop/help/new-layout.md create mode 100644 desktop/help/new-project.md create mode 100644 desktop/help/new-resource-wizard.md create mode 100644 desktop/help/notebooks.md create mode 100644 desktop/help/open-layout.md create mode 100644 desktop/help/open-project.md create mode 100644 desktop/help/overview.md create mode 100644 desktop/help/page-setup.md create mode 100644 desktop/help/print-preview.md create mode 100644 desktop/help/profile-options.md create mode 100644 desktop/help/project-checker-results.md create mode 100644 desktop/help/project-checker.md create mode 100644 desktop/help/project-folders.md create mode 100644 desktop/help/recalculate-assignment-costs.md create mode 100644 desktop/help/renumber-activity-ids.md create mode 100644 desktop/help/report-editor.md create mode 100644 desktop/help/report-groups.md create mode 100644 desktop/help/report-properties.md create mode 100644 desktop/help/resource-curves.md create mode 100644 desktop/help/resource-shifts.md create mode 100644 desktop/help/responsible-managers.md create mode 100644 desktop/help/revert-to-baseline.md create mode 100644 desktop/help/role-codes.md create mode 100644 desktop/help/roles.md create mode 100644 desktop/help/run-batch.md create mode 100644 desktop/help/run-report.md create mode 100644 desktop/help/s-curve.md create mode 100644 desktop/help/save-period-actuals.md create mode 100644 desktop/help/schedule-comparison-results.md create mode 100644 desktop/help/schedule-comparison.md create mode 100644 desktop/help/schedule-options.md create mode 100644 desktop/help/schedule.md create mode 100644 desktop/help/scheduling-basics.md create mode 100644 desktop/help/select-baseline-project.md create mode 100644 desktop/help/shared-dictionaries.md create mode 100644 desktop/help/skills-for-ai-agents.md create mode 100644 desktop/help/spell-check.md create mode 100644 desktop/help/spread-budget-hours.md create mode 100644 desktop/help/step-templates.md create mode 100644 desktop/help/table-font-and-row.md create mode 100644 desktop/help/text-attachment.md create mode 100644 desktop/help/timescale.md create mode 100644 desktop/help/trace-logic-options.md create mode 100644 desktop/help/update-baseline.md create mode 100644 desktop/help/update-progress.md create mode 100644 desktop/help/usage-views.md create mode 100644 desktop/help/user-defined-fields.md create mode 100644 desktop/help/user-preferences.md create mode 100644 desktop/help/view-activities.md create mode 100644 desktop/help/view-assignments.md create mode 100644 desktop/help/view-documents.md create mode 100644 desktop/help/view-expenses.md create mode 100644 desktop/help/view-issues.md create mode 100644 desktop/help/view-projects.md create mode 100644 desktop/help/view-report-tab.md create mode 100644 desktop/help/view-reports.md create mode 100644 desktop/help/view-resources.md create mode 100644 desktop/help/view-risks.md create mode 100644 desktop/help/view-thresholds.md create mode 100644 desktop/help/view-wbs.md create mode 100644 desktop/help/working-with-ai-agents.md create mode 100644 desktop/src/activities.rs create mode 100644 desktop/src/activities_tests.rs create mode 100644 desktop/src/activity_delete.rs create mode 100644 desktop/src/activity_wizard.rs create mode 100644 desktop/src/admin_prefs.rs create mode 100644 desktop/src/agent_coverage.rs create mode 100644 desktop/src/ai_agents.rs create mode 100644 desktop/src/ai_agents/row.rs create mode 100644 desktop/src/ai_agents/skills_ui.rs create mode 100644 desktop/src/ai_agents/skills_ui_tests.rs create mode 100644 desktop/src/ai_agents/tests.rs create mode 100644 desktop/src/available_options.rs create mode 100644 desktop/src/available_options/tests.rs create mode 100644 desktop/src/baselines/columns.rs create mode 100644 desktop/src/baselines/data.rs create mode 100644 desktop/src/baselines/dialogs.rs create mode 100644 desktop/src/baselines/mod.rs create mode 100644 desktop/src/baselines/store.rs create mode 100644 desktop/src/baselines/tests.rs create mode 100644 desktop/src/baselines/tests_m4.rs create mode 100644 desktop/src/baselines/update_dialog.rs create mode 100644 desktop/src/busy.rs create mode 100644 desktop/src/calendars/editor.rs create mode 100644 desktop/src/calendars/mod.rs create mode 100644 desktop/src/calendars/ops.rs create mode 100644 desktop/src/calendars/tests.rs create mode 100644 desktop/src/chat/backend.rs create mode 100644 desktop/src/chat/checks.rs create mode 100644 desktop/src/chat/endpoint_dialog.rs create mode 100644 desktop/src/chat/history.rs create mode 100644 desktop/src/chat/links.rs create mode 100644 desktop/src/chat/list.rs create mode 100644 desktop/src/chat/live/endpoint.rs create mode 100644 desktop/src/chat/live/fakes.rs create mode 100644 desktop/src/chat/live/mod.rs create mode 100644 desktop/src/chat/live/rows.rs create mode 100644 desktop/src/chat/live/tests.rs create mode 100644 desktop/src/chat/live/work.rs create mode 100644 desktop/src/chat/mod.rs create mode 100644 desktop/src/chat/model.rs create mode 100644 desktop/src/chat/prompts.rs create mode 100644 desktop/src/chat/renders.rs create mode 100644 desktop/src/chat/tests.rs create mode 100644 desktop/src/chat/ui_actions.rs create mode 100644 desktop/src/chrome.rs create mode 100644 desktop/src/close_guard.rs create mode 100644 desktop/src/compare/diff.rs create mode 100644 desktop/src/compare/mod.rs create mode 100644 desktop/src/compare/report.rs create mode 100644 desktop/src/compare/tests.rs create mode 100644 desktop/src/context_menu.rs create mode 100644 desktop/src/context_menu_tests.rs create mode 100644 desktop/src/crash.rs create mode 100644 desktop/src/critical_path.rs create mode 100644 desktop/src/critical_path/tests.rs create mode 100644 desktop/src/defaults.rs create mode 100644 desktop/src/defaults_tests.rs create mode 100644 desktop/src/details/assign_kit.rs create mode 100644 desktop/src/details/assignment_tests.rs create mode 100644 desktop/src/details/assignment_window.rs create mode 100644 desktop/src/details/assignments.rs create mode 100644 desktop/src/details/bulk_assign.rs create mode 100644 desktop/src/details/codes_assign_tests.rs create mode 100644 desktop/src/details/form.rs create mode 100644 desktop/src/details/grid_columns.rs create mode 100644 desktop/src/details/grid_columns/tests.rs create mode 100644 desktop/src/details/headless_tests.rs create mode 100644 desktop/src/details/mod.rs create mode 100644 desktop/src/details/notes_pane.rs create mode 100644 desktop/src/details/owner_pickers.rs create mode 100644 desktop/src/details/record_tabs.rs create mode 100644 desktop/src/details/removals.rs create mode 100644 desktop/src/details/review_renders.rs create mode 100644 desktop/src/details/schedule_tabs.rs create mode 100644 desktop/src/details/setters.rs create mode 100644 desktop/src/details/split_tests.rs create mode 100644 desktop/src/details/status_layout_tests.rs create mode 100644 desktop/src/details/units_progress.rs create mode 100644 desktop/src/diag_log.rs create mode 100644 desktop/src/dialog_keys.rs create mode 100644 desktop/src/dialog_kit.rs create mode 100644 desktop/src/dialog_renders.rs create mode 100644 desktop/src/dialog_sweep.rs create mode 100644 desktop/src/dialogs.rs create mode 100644 desktop/src/dictionaries/accounts.rs create mode 100644 desktop/src/dictionaries/admin.rs create mode 100644 desktop/src/dictionaries/codes.rs create mode 100644 desktop/src/dictionaries/mod.rs create mode 100644 desktop/src/dictionaries/ops.rs create mode 100644 desktop/src/dictionaries/steps.rs create mode 100644 desktop/src/dictionaries/steps/tests.rs create mode 100644 desktop/src/dictionaries/tests.rs create mode 100644 desktop/src/dictionaries/udf.rs create mode 100644 desktop/src/dictionaries/widgets.rs create mode 100644 desktop/src/dockbars.rs create mode 100644 desktop/src/dockbars_tests.rs create mode 100644 desktop/src/dockbars_ui.rs create mode 100644 desktop/src/editing/dialogs.rs create mode 100644 desktop/src/editing/gc.rs create mode 100644 desktop/src/editing/gc_report.rs create mode 100644 desktop/src/editing/links.rs create mode 100644 desktop/src/editing/mod.rs create mode 100644 desktop/src/editing/move_across.rs create mode 100644 desktop/src/editing/ops.rs create mode 100644 desktop/src/editing/table_menu.rs create mode 100644 desktop/src/editing/table_menu_tests.rs create mode 100644 desktop/src/editing/tests.rs create mode 100644 desktop/src/enterprise/dialogs.rs create mode 100644 desktop/src/enterprise/lists.rs create mode 100644 desktop/src/enterprise/mod.rs create mode 100644 desktop/src/enterprise/ops.rs create mode 100644 desktop/src/enterprise/tests.rs create mode 100644 desktop/src/enterprise/tree.rs create mode 100644 desktop/src/enterprise/ui.rs create mode 100644 desktop/src/enterprise/workspace.rs create mode 100644 desktop/src/estimation.rs create mode 100644 desktop/src/external_apps.rs create mode 100644 desktop/src/external_apps/tests.rs create mode 100644 desktop/src/first_run.rs create mode 100644 desktop/src/float_path_end_tests.rs create mode 100644 desktop/src/format.rs create mode 100644 desktop/src/frame.rs create mode 100644 desktop/src/gantt/bars.rs create mode 100644 desktop/src/gantt/dialogs.rs create mode 100644 desktop/src/gantt/edit_tests.rs create mode 100644 desktop/src/gantt/mod.rs create mode 100644 desktop/src/gantt/paint.rs create mode 100644 desktop/src/gantt/settings.rs create mode 100644 desktop/src/gantt/tests.rs create mode 100644 desktop/src/gantt/text_tests.rs create mode 100644 desktop/src/gantt_geometry.rs create mode 100644 desktop/src/grid/align_render.rs create mode 100644 desktop/src/grid/band.rs create mode 100644 desktop/src/grid/cell_combo.rs create mode 100644 desktop/src/grid/columns.rs create mode 100644 desktop/src/grid/columns_ev.rs create mode 100644 desktop/src/grid/columns_ext.rs create mode 100644 desktop/src/grid/dialogs.rs create mode 100644 desktop/src/grid/edit.rs create mode 100644 desktop/src/grid/filter_editor.rs create mode 100644 desktop/src/grid/filters.rs create mode 100644 desktop/src/grid/group.rs create mode 100644 desktop/src/grid/interval.rs create mode 100644 desktop/src/grid/layout.rs create mode 100644 desktop/src/grid/marks.rs create mode 100644 desktop/src/grid/marks_render.rs create mode 100644 desktop/src/grid/mod.rs create mode 100644 desktop/src/grid/presets.rs create mode 100644 desktop/src/grid/relative.rs create mode 100644 desktop/src/grid/review_renders.rs create mode 100644 desktop/src/grid/sort_keys.rs create mode 100644 desktop/src/grid/starters.rs create mode 100644 desktop/src/grid/starters_tests.rs create mode 100644 desktop/src/grid/table.rs create mode 100644 desktop/src/grid/tests.rs create mode 100644 desktop/src/grid/tests/align_tests.rs create mode 100644 desktop/src/grid/tests/edit_tests.rs create mode 100644 desktop/src/grid/tests/quotes_tests.rs create mode 100644 desktop/src/grid/tests_cache.rs create mode 100644 desktop/src/grid/tests_ev_techniques.rs create mode 100644 desktop/src/grid/tests_h3.rs create mode 100644 desktop/src/h6_renders.rs create mode 100644 desktop/src/headless_render.rs create mode 100644 desktop/src/headless_ui.rs create mode 100644 desktop/src/help/mod.rs create mode 100644 desktop/src/help/tests.rs create mode 100644 desktop/src/help/viewer.rs create mode 100644 desktop/src/history.rs create mode 100644 desktop/src/hscroll.rs create mode 100644 desktop/src/hscroll_tests.rs create mode 100644 desktop/src/install_tests.rs create mode 100644 desktop/src/instance.rs create mode 100644 desktop/src/interchange/dictionary_tests.rs create mode 100644 desktop/src/interchange/mod.rs create mode 100644 desktop/src/interchange/safety_tests.rs create mode 100644 desktop/src/interchange/sheet_setters.rs create mode 100644 desktop/src/interchange/sheet_tests.rs create mode 100644 desktop/src/interchange/templates.rs create mode 100644 desktop/src/interchange/tests.rs create mode 100644 desktop/src/interchange/workspace.rs create mode 100644 desktop/src/kit_window.rs create mode 100644 desktop/src/l1_renders.rs create mode 100644 desktop/src/l2_renders.rs create mode 100644 desktop/src/layout_opts/checks.rs create mode 100644 desktop/src/layout_opts/dialogs.rs create mode 100644 desktop/src/layout_opts/mod.rs create mode 100644 desktop/src/layout_opts/tests.rs create mode 100644 desktop/src/loops/analysis.rs create mode 100644 desktop/src/loops/dialog.rs create mode 100644 desktop/src/loops/mod.rs create mode 100644 desktop/src/loops/tests.rs create mode 100644 desktop/src/m6_renders.rs create mode 100644 desktop/src/main.rs create mode 100644 desktop/src/markdown.rs create mode 100644 desktop/src/memo.rs create mode 100644 desktop/src/menu.rs create mode 100644 desktop/src/menu_keys.rs create mode 100644 desktop/src/menu_keys_tests.rs create mode 100644 desktop/src/new_project.rs create mode 100644 desktop/src/new_project/tests.rs create mode 100644 desktop/src/new_project_wbs_tests.rs create mode 100644 desktop/src/open_set/compose.rs create mode 100644 desktop/src/open_set/dialogs.rs create mode 100644 desktop/src/open_set/mod.rs create mode 100644 desktop/src/open_set/numbers.rs create mode 100644 desktop/src/open_set/recovery.rs create mode 100644 desktop/src/open_set/schedule.rs create mode 100644 desktop/src/open_set/tests.rs create mode 100644 desktop/src/panes/actual_remaining_tests.rs create mode 100644 desktop/src/panes/boxes.rs create mode 100644 desktop/src/panes/ctx_tests.rs create mode 100644 desktop/src/panes/curve_spread_tests.rs create mode 100644 desktop/src/panes/histogram.rs create mode 100644 desktop/src/panes/mod.rs create mode 100644 desktop/src/panes/network.rs create mode 100644 desktop/src/panes/profile_options.rs create mode 100644 desktop/src/panes/sheet_pane.rs create mode 100644 desktop/src/panes/stacked.rs create mode 100644 desktop/src/panes/stacked_tests.rs create mode 100644 desktop/src/panes/tests.rs create mode 100644 desktop/src/panes/time_fields.rs create mode 100644 desktop/src/panes/trace.rs create mode 100644 desktop/src/panes/usage.rs create mode 100644 desktop/src/panes/usage_cells.rs create mode 100644 desktop/src/panes/usage_fields.rs create mode 100644 desktop/src/panes/usage_list.rs create mode 100644 desktop/src/panes/usage_list_tests.rs create mode 100644 desktop/src/panes/usage_menu.rs create mode 100644 desktop/src/panes/usage_totals_tests.rs create mode 100644 desktop/src/perf.rs create mode 100644 desktop/src/polish_tests.rs create mode 100644 desktop/src/print/cli.rs create mode 100644 desktop/src/print/compose.rs create mode 100644 desktop/src/print/dialog.rs create mode 100644 desktop/src/print/mod.rs create mode 100644 desktop/src/print/ops.rs create mode 100644 desktop/src/print/other_views.rs create mode 100644 desktop/src/print/paginate.rs create mode 100644 desktop/src/print/pdf.rs create mode 100644 desktop/src/print/preview.rs create mode 100644 desktop/src/print/screen_tests.rs create mode 100644 desktop/src/print/scroll_tests.rs create mode 100644 desktop/src/print/setup.rs create mode 100644 desktop/src/print/speed_tests.rs create mode 100644 desktop/src/print/tests.rs create mode 100644 desktop/src/print/ts_picker.rs create mode 100644 desktop/src/print/ts_picker_tests.rs create mode 100644 desktop/src/print/viewer.rs create mode 100644 desktop/src/print/viewer_ui.rs create mode 100644 desktop/src/progress_tools.rs create mode 100644 desktop/src/progress_tools_tests.rs create mode 100644 desktop/src/project_io.rs create mode 100644 desktop/src/qa_sweep.rs create mode 100644 desktop/src/qa_workflows.rs create mode 100644 desktop/src/qa_workflows/activity_wizard.rs create mode 100644 desktop/src/qa_workflows/assignments_window.rs create mode 100644 desktop/src/qa_workflows/bar_drag_hold.rs create mode 100644 desktop/src/qa_workflows/chat.rs create mode 100644 desktop/src/qa_workflows/confirm_defaults.rs create mode 100644 desktop/src/qa_workflows/context_menus.rs create mode 100644 desktop/src/qa_workflows/cut_paste.rs create mode 100644 desktop/src/qa_workflows/data_date_edit.rs create mode 100644 desktop/src/qa_workflows/delete_confirms.rs create mode 100644 desktop/src/qa_workflows/details_gaps.rs create mode 100644 desktop/src/qa_workflows/dialog_look.rs create mode 100644 desktop/src/qa_workflows/dissolve.rs create mode 100644 desktop/src/qa_workflows/eps_delete.rs create mode 100644 desktop/src/qa_workflows/global_change_cli.rs create mode 100644 desktop/src/qa_workflows/global_change_report.rs create mode 100644 desktop/src/qa_workflows/look_details_project.rs create mode 100644 desktop/src/qa_workflows/look_layouts_records.rs create mode 100644 desktop/src/qa_workflows/notebooks_project_codes.rs create mode 100644 desktop/src/qa_workflows/out_of_sequence.rs create mode 100644 desktop/src/qa_workflows/owner_ui_fixes_1.rs create mode 100644 desktop/src/qa_workflows/period_delete.rs create mode 100644 desktop/src/qa_workflows/polish_1.rs create mode 100644 desktop/src/qa_workflows/profiles.rs create mode 100644 desktop/src/qa_workflows/progress_tools.rs create mode 100644 desktop/src/qa_workflows/project_numbers.rs create mode 100644 desktop/src/qa_workflows/reference_defaults.rs create mode 100644 desktop/src/qa_workflows/resource_wizard.rs create mode 100644 desktop/src/qa_workflows/round2_corrections.rs create mode 100644 desktop/src/qa_workflows/round3_corrections.rs create mode 100644 desktop/src/qa_workflows/schedule_freeze.rs create mode 100644 desktop/src/qa_workflows/schedule_options_close.rs create mode 100644 desktop/src/qa_workflows/shared_controls.rs create mode 100644 desktop/src/qa_workflows/start_constraint.rs create mode 100644 desktop/src/qa_workflows/table_editing.rs create mode 100644 desktop/src/qa_workflows/udf_columns.rs create mode 100644 desktop/src/qa_workflows/usage_cells.rs create mode 100644 desktop/src/qa_workflows/usage_spreadsheet.rs create mode 100644 desktop/src/qa_workflows/wbs_copy_calendars.rs create mode 100644 desktop/src/qa_workflows/wbs_projects_tables.rs create mode 100644 desktop/src/qa_workflows/xml_interchange.rs create mode 100644 desktop/src/qa_workflows_update.rs create mode 100644 desktop/src/readme_hero.rs create mode 100644 desktop/src/records.rs create mode 100644 desktop/src/relationships.rs create mode 100644 desktop/src/reports/batch_run.rs create mode 100644 desktop/src/reports/checker.rs create mode 100644 desktop/src/reports/checker_tests.rs create mode 100644 desktop/src/reports/checker_ui.rs create mode 100644 desktop/src/reports/csv.rs create mode 100644 desktop/src/reports/doc.rs create mode 100644 desktop/src/reports/groups.rs create mode 100644 desktop/src/reports/groups_ui.rs create mode 100644 desktop/src/reports/html.rs create mode 100644 desktop/src/reports/injection_tests.rs create mode 100644 desktop/src/reports/mod.rs create mode 100644 desktop/src/reports/pdf.rs create mode 100644 desktop/src/reports/progress_tests.rs create mode 100644 desktop/src/reports/progress_ui.rs create mode 100644 desktop/src/reports/progress_view.rs create mode 100644 desktop/src/reports/report_tab.rs create mode 100644 desktop/src/reports/report_tab_tests.rs create mode 100644 desktop/src/reports/report_tab_ui.rs create mode 100644 desktop/src/reports/reports_view.rs create mode 100644 desktop/src/reports/reports_view_tests.rs create mode 100644 desktop/src/reports/rpt/data.rs create mode 100644 desktop/src/reports/rpt/edit.rs create mode 100644 desktop/src/reports/rpt/engine.rs create mode 100644 desktop/src/reports/rpt/filter.rs create mode 100644 desktop/src/reports/rpt/library.rs create mode 100644 desktop/src/reports/rpt/library_gen.rs create mode 100644 desktop/src/reports/rpt/mod.rs create mode 100644 desktop/src/reports/rpt/model.rs create mode 100644 desktop/src/reports/rpt/page.rs create mode 100644 desktop/src/reports/rpt/run_tests.rs create mode 100644 desktop/src/reports/rpt/store.rs create mode 100644 desktop/src/reports/rpt/stream.rs create mode 100644 desktop/src/reports/rpt/tests.rs create mode 100644 desktop/src/reports/rpt/writers.rs create mode 100644 desktop/src/reports/rpt_editor.rs create mode 100644 desktop/src/reports/rpt_entries.rs create mode 100644 desktop/src/reports/rpt_io.rs create mode 100644 desktop/src/reports/rpt_props.rs create mode 100644 desktop/src/reports/rpt_run.rs create mode 100644 desktop/src/reports/rpt_tests.rs create mode 100644 desktop/src/reports/test_support.rs create mode 100644 desktop/src/reports/wizard.rs create mode 100644 desktop/src/reports/wizard_tests.rs create mode 100644 desktop/src/reports/wizard_ui.rs create mode 100644 desktop/src/reports/xlsx.rs create mode 100644 desktop/src/resource_wizard.rs create mode 100644 desktop/src/sample_renders.rs create mode 100644 desktop/src/schedule_check.rs create mode 100644 desktop/src/schedule_dialogs.rs create mode 100644 desktop/src/scheduling.rs create mode 100644 desktop/src/scheduling_guards.rs create mode 100644 desktop/src/session_history.rs create mode 100644 desktop/src/share_dictionaries.rs create mode 100644 desktop/src/share_dictionaries/tests.rs create mode 100644 desktop/src/shell_tests.rs create mode 100644 desktop/src/spell/dict.rs create mode 100644 desktop/src/spell/mod.rs create mode 100644 desktop/src/spell/tests.rs create mode 100644 desktop/src/splitter_tests.rs create mode 100644 desktop/src/start_hold.rs create mode 100644 desktop/src/startup_tests.rs create mode 100644 desktop/src/store.rs create mode 100644 desktop/src/tab_strip.rs create mode 100644 desktop/src/test_corpus.rs create mode 100644 desktop/src/theme.rs create mode 100644 desktop/src/theme/legacy.rs create mode 100644 desktop/src/timeline.rs create mode 100644 desktop/src/timeline_tests.rs create mode 100644 desktop/src/timescale.rs create mode 100644 desktop/src/toolbars.rs create mode 100644 desktop/src/ui_batch1_renders.rs create mode 100644 desktop/src/ui_batch3_renders.rs create mode 100644 desktop/src/user_prefs.rs create mode 100644 desktop/src/util.rs create mode 100644 desktop/src/view.rs create mode 100644 desktop/src/views/activity_views.rs create mode 100644 desktop/src/views/assignment_codes.rs create mode 100644 desktop/src/views/assignment_codes/tests.rs create mode 100644 desktop/src/views/assignment_columns.rs create mode 100644 desktop/src/views/assignment_layout_tests.rs create mode 100644 desktop/src/views/assignment_layouts.rs create mode 100644 desktop/src/views/assignments.rs create mode 100644 desktop/src/views/budget.rs create mode 100644 desktop/src/views/budget_tests.rs create mode 100644 desktop/src/views/chart.rs create mode 100644 desktop/src/views/columns_tests.rs create mode 100644 desktop/src/views/command_bar_tests.rs create mode 100644 desktop/src/views/docks.rs create mode 100644 desktop/src/views/documents.rs create mode 100644 desktop/src/views/eps_tracking_tests.rs create mode 100644 desktop/src/views/expenses.rs create mode 100644 desktop/src/views/funding.rs create mode 100644 desktop/src/views/funding_tests.rs create mode 100644 desktop/src/views/grid.rs create mode 100644 desktop/src/views/headless.rs create mode 100644 desktop/src/views/issues.rs create mode 100644 desktop/src/views/mod.rs create mode 100644 desktop/src/views/monitor_ev_tests.rs create mode 100644 desktop/src/views/multiselect_tests.rs create mode 100644 desktop/src/views/project_ops.rs create mode 100644 desktop/src/views/project_ops/tests.rs create mode 100644 desktop/src/views/project_rollups.rs create mode 100644 desktop/src/views/projects.rs create mode 100644 desktop/src/views/record_view.rs create mode 100644 desktop/src/views/record_view_tests.rs create mode 100644 desktop/src/views/resource_edit.rs create mode 100644 desktop/src/views/resource_merge.rs create mode 100644 desktop/src/views/resource_merge_tests.rs create mode 100644 desktop/src/views/resource_table_tests.rs create mode 100644 desktop/src/views/resource_tests.rs create mode 100644 desktop/src/views/resources.rs create mode 100644 desktop/src/views/resources_bottom_tests.rs create mode 100644 desktop/src/views/risks.rs create mode 100644 desktop/src/views/sheet.rs create mode 100644 desktop/src/views/tab_group_tests.rs create mode 100644 desktop/src/views/tab_groups.rs create mode 100644 desktop/src/views/table_cells.rs create mode 100644 desktop/src/views/table_keys.rs create mode 100644 desktop/src/views/thresholds.rs create mode 100644 desktop/src/views/udf_columns.rs create mode 100644 desktop/src/views/view_menus_tests.rs create mode 100644 desktop/src/views/wbs.rs create mode 100644 desktop/src/views/wbs_columns.rs create mode 100644 desktop/src/views/wbs_copy.rs create mode 100644 desktop/src/window_place.rs create mode 100644 desktop/src/workspace_safety_tests.rs create mode 100644 desktop/src/workspace_sync.rs create mode 100644 desktop/src/workspace_sync_tests.rs create mode 100644 desktop/src/write_safety_tests.rs create mode 100644 docs/images/ai-chat.png create mode 100644 docs/images/ai-skills.png create mode 100644 docs/images/baseline.png create mode 100644 docs/images/check-schedule.png create mode 100644 docs/images/hero.png create mode 100644 docs/images/leveled.png create mode 100644 docs/images/print-preview.png create mode 100644 docs/images/resource-usage.png create mode 100644 docs/images/trace-logic.png create mode 100644 docs/images/update-progress.png create mode 100644 engine/Cargo.toml create mode 100644 engine/PARITY.md create mode 100644 engine/RULES.md create mode 100644 engine/src/bin/oxdiff.rs create mode 100644 engine/src/calendar.rs create mode 100644 engine/src/cpm.rs create mode 100644 engine/src/features.rs create mode 100644 engine/src/fixture.rs create mode 100644 engine/src/lib.rs create mode 100644 engine/src/model.rs create mode 100644 engine/src/options.rs create mode 100644 engine/src/scheduler.rs create mode 100644 engine/tests/activity_paths.rs create mode 100644 engine/tests/blackbox_rules.rs create mode 100644 engine/tests/cal_fixtures.rs create mode 100644 engine/tests/completed_boundaries.rs create mode 100644 engine/tests/engine_diff.rs create mode 100644 engine/tests/float_path_cost.rs create mode 100644 engine/tests/fresh_schedule.rs create mode 100644 engine/tests/input_validation.rs create mode 100644 engine/tests/level_options.rs create mode 100644 engine/tests/loe_rules.rs create mode 100644 engine/tests/multi_project.rs create mode 100644 engine/tests/no_internal_refs.rs create mode 100644 engine/tests/origin_room.rs create mode 100644 engine/tests/parity_rules.rs create mode 100644 engine/tests/probe_rules.rs create mode 100644 engine/tests/relationship_candidates.rs create mode 100644 engine/tests/schedule_features.rs create mode 100644 engine/tests/shift_shapes.rs create mode 100644 engine/tests/started_mandatory.rs create mode 100644 interchange/Cargo.toml create mode 100644 interchange/src/baseline.rs create mode 100644 interchange/src/baseline_update.rs create mode 100644 interchange/src/baseline_update/tests.rs create mode 100644 interchange/src/columns.rs create mode 100644 interchange/src/export_template.rs create mode 100644 interchange/src/field_edits.rs create mode 100644 interchange/src/lib.rs create mode 100644 interchange/src/project_xml.rs create mode 100644 interchange/src/project_xml_specs.rs create mode 100644 interchange/src/project_xml_tests.rs create mode 100644 interchange/src/report_xlsx.rs create mode 100644 interchange/src/scurve_xlsx.rs create mode 100644 interchange/src/util.rs create mode 100644 interchange/src/xer_export.rs create mode 100644 interchange/src/xer_merge.rs create mode 100644 interchange/src/xlsx_export.rs create mode 100644 interchange/src/xlsx_import.rs create mode 100644 interchange/tests/scurve.rs create mode 100644 interchange/tests/template.rs create mode 100644 interchange/tests/xer.rs create mode 100644 interchange/tests/xlsx.rs create mode 100644 tools/icons/README.md create mode 100644 tools/icons/build.py create mode 100644 tools/icons/iconlib.py create mode 100644 tools/icons/set_a.py create mode 100644 tools/icons/set_b.py create mode 100644 tools/icons/set_c.py create mode 100644 tools/icons/set_d.py create mode 100644 tools/icons/set_x.py create mode 100644 tools/installer/license.txt create mode 100644 tools/installer/openxer.installed create mode 100644 tools/installer/openxer.iss create mode 100644 tools/licenses/third_party.py create mode 100644 tools/spell/build_wordlist.py create mode 100644 tools/winres.rs create mode 100644 xer/Cargo.toml create mode 100644 xer/src/assignments.rs create mode 100644 xer/src/assignments/progress.rs create mode 100644 xer/src/calendar_data.rs create mode 100644 xer/src/compare.rs create mode 100644 xer/src/critical.rs create mode 100644 xer/src/delete.rs create mode 100644 xer/src/edit/activity.rs create mode 100644 xer/src/edit/calendars.rs create mode 100644 xer/src/edit/curves.rs create mode 100644 xer/src/edit/dissolve.rs create mode 100644 xer/src/edit/documents.rs create mode 100644 xer/src/edit/earned_value.rs create mode 100644 xer/src/edit/fields/catalog.rs create mode 100644 xer/src/edit/fields/criteria.rs create mode 100644 xer/src/edit/fields/index.rs create mode 100644 xer/src/edit/fields/mod.rs create mode 100644 xer/src/edit/fields/tests.rs create mode 100644 xer/src/edit/fields/write.rs create mode 100644 xer/src/edit/financial_periods.rs create mode 100644 xer/src/edit/funding.rs create mode 100644 xer/src/edit/global_change.rs create mode 100644 xer/src/edit/global_change/tests.rs create mode 100644 xer/src/edit/mod.rs create mode 100644 xer/src/edit/new_activity.rs create mode 100644 xer/src/edit/notebooks.rs create mode 100644 xer/src/edit/period_units.rs create mode 100644 xer/src/edit/progress.rs create mode 100644 xer/src/edit/project_codes.rs create mode 100644 xer/src/edit/project_dates.rs create mode 100644 xer/src/edit/project_records.rs create mode 100644 xer/src/edit/records.rs create mode 100644 xer/src/edit/relationships.rs create mode 100644 xer/src/edit/resources.rs create mode 100644 xer/src/edit/rich_memo.rs create mode 100644 xer/src/edit/steps.rs create mode 100644 xer/src/edit/tables.rs create mode 100644 xer/src/edit/thresholds.rs create mode 100644 xer/src/edit/udf.rs create mode 100644 xer/src/edit/wbs.rs create mode 100644 xer/src/enterprise.rs create mode 100644 xer/src/estimate.rs create mode 100644 xer/src/ev.rs create mode 100644 xer/src/lib.rs create mode 100644 xer/src/limits.rs create mode 100644 xer/src/manual_units.rs create mode 100644 xer/src/periods.rs create mode 100644 xer/src/sample_project.rs create mode 100644 xer/src/sample_project/tests.rs create mode 100644 xer/src/schedule_check.rs create mode 100644 xer/src/scurve.rs create mode 100644 xer/src/scurve_tests.rs create mode 100644 xer/src/spread.rs create mode 100644 xer/src/tree.rs create mode 100644 xer/src/workspace/mod.rs create mode 100644 xer/src/workspace/new_project.rs create mode 100644 xer/src/workspace/numbering.rs create mode 100644 xer/src/workspace/numbering/tests.rs create mode 100644 xer/src/workspace/rollup.rs create mode 100644 xer/src/workspace/sample.rs create mode 100644 xer/src/workspace/tests.rs create mode 100644 xer/src/workspace/tree.rs create mode 100644 xer/src/workspace_scope.rs create mode 100644 xer/src/workspace_scope/delta.rs create mode 100644 xer/src/workspace_scope/merge.rs create mode 100644 xer/src/workspace_scope/merge/tests.rs create mode 100644 xer/src/workspace_scope/migrate.rs create mode 100644 xer/src/workspace_scope/migrate/tests.rs create mode 100644 xer/src/workspace_scope/tests.rs create mode 100644 xer/tests/assignments.rs create mode 100644 xer/tests/corpus_bench.rs create mode 100644 xer/tests/corpus_diff.rs create mode 100644 xer/tests/corpus_parity.rs create mode 100644 xer/tests/corpus_roundtrip.rs create mode 100644 xer/tests/curve_presets.rs create mode 100644 xer/tests/curve_spread.rs create mode 100644 xer/tests/delete.rs create mode 100644 xer/tests/edit.rs create mode 100644 xer/tests/estimate.rs create mode 100644 xer/tests/leveling_inputs.rs create mode 100644 xer/tests/loe_duration.rs create mode 100644 xer/tests/new_activity.rs create mode 100644 xer/tests/notebooks.rs create mode 100644 xer/tests/period_units.rs create mode 100644 xer/tests/quotes.rs create mode 100644 xer/tests/resource_merge.rs create mode 100644 xer/tests/resources.rs create mode 100644 xer/tests/robustness.rs create mode 100644 xer/tests/undo_columns.rs diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..177544a --- /dev/null +++ b/.gitattributes @@ -0,0 +1,7 @@ +# Keep LF in the repository whatever the editor or script writes. +* text=auto eol=lf +*.png binary +*.ico binary +*.xlsx binary +*.pdf binary +*.db binary diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000..0e16ccf --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,42 @@ +name: Bug report +description: Something works wrong, a date or float is off, or the app crashes. +labels: [bug] +body: + - type: markdown + attributes: + value: | + **Do not attach real project schedules, workspace databases or screenshots of real projects.** + They hold your clients' data. Describe the schedule shape instead, or build a small invented example. + - type: textarea + id: what + attributes: + label: What happened + description: What you did, what you expected, and what you got instead. + validations: + required: true + - type: textarea + id: shape + attributes: + label: Schedule shape + description: | + For scheduling results: activity and relationship types, lags, calendars, constraints, + progress, scheduling and leveling options involved, and the dates you expected (and why). + - type: input + id: version + attributes: + label: OpenXER version + placeholder: "openxer-cli --version, or Help > About in the app" + validations: + required: true + - type: input + id: os + attributes: + label: Windows version + placeholder: "Windows 11 23H2" + - type: checkboxes + id: privacy + attributes: + label: Privacy + options: + - label: This report contains no real client or project data. + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..a2c4eda --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Report a security problem + url: https://docs.github.com/code-security/security-advisories/guidance-on-reporting-and-writing-information-about-vulnerabilities/privately-reporting-a-security-vulnerability + about: Report privately through the repository's Security tab, not as a public issue. diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 0000000..ae65716 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,21 @@ +name: Feature request +description: Suggest something OpenXER should do. +labels: [enhancement] +body: + - type: textarea + id: problem + attributes: + label: The problem + description: What are you trying to do, and what gets in the way today? + validations: + required: true + - type: textarea + id: idea + attributes: + label: What you would like + description: How it should work, in the app, the CLI or the MCP server. + - type: textarea + id: workflow + attributes: + label: How schedulers do this today + description: The workflow or convention schedulers already know for this, if there is one. diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 0000000..c18dff6 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,15 @@ +## What this changes + + + +## Evidence and tests + + + +## Checklist + +- [ ] `cargo fmt --all --check`, clippy with `-D warnings` and the tests pass +- [ ] No real client or project data (schedules, databases, screenshots) anywhere in this change +- [ ] Original work only: nothing copied from other software, nothing decompiled +- [ ] No em dashes or en dashes +- [ ] New edits to project data are available in the app, `openxer-cli` and the MCP server diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..7a9980c --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,72 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + +permissions: + contents: read + +env: + CARGO_TERM_COLOR: always + CARGO_INCREMENTAL: 0 + +jobs: + build-and-test: + name: Build and test (Windows) + runs-on: windows-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable + with: + components: rustfmt, clippy + - uses: Swatinem/rust-cache@v2 + - name: Format + run: cargo fmt --all --check + - name: Clippy + run: cargo clippy --workspace --all-targets -- -D warnings + - name: Tests + # Tests that need private fixtures or corpus files skip themselves here. + run: cargo test --workspace --no-fail-fast -- --skip full_ui_sweep --skip dialog_formatting_sweep + - name: UI click-through sweeps + run: cargo test -p openxer-desktop -- full_ui_sweep dialog_formatting_sweep + - name: Release build + run: cargo build --release -p openxer-desktop -p openxer-automation + + build-and-test-linux: + name: Build and test (Linux) + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + # A C compiler for the bundled SQLite and OpenSSL headers for native-tls + # and openxer-chat on Linux. The window, OpenGL and portal libraries are + # loaded at run time. Liberation Sans stands in for Arial in text measurements. + - name: System packages + run: | + sudo apt-get update + sudo apt-get install -y --no-install-recommends build-essential pkg-config libssl-dev fonts-liberation + - uses: dtolnay/rust-toolchain@stable + with: + components: rustfmt, clippy + - uses: Swatinem/rust-cache@v2 + - name: Format + run: cargo fmt --all --check + - name: Clippy + run: cargo clippy --workspace --all-targets -- -D warnings + - name: Tests + # Tests that need private fixtures or corpus files skip themselves here. + run: cargo test --workspace --no-fail-fast -- --skip full_ui_sweep --skip dialog_formatting_sweep + - name: UI click-through sweeps + run: cargo test -p openxer-desktop -- full_ui_sweep dialog_formatting_sweep + - name: Release build + run: cargo build --release -p openxer-desktop -p openxer-automation + + licenses: + name: Dependency licenses and sources + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: EmbarkStudios/cargo-deny-action@v2 + with: + command: check licenses bans sources diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..20910d8 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,132 @@ +name: Release + +on: + push: + tags: + - 'v*' + workflow_dispatch: + +permissions: + contents: write + +env: + CARGO_TERM_COLOR: always + +jobs: + build-windows: + name: Build Windows installer and portable zip + runs-on: windows-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable + with: + targets: x86_64-pc-windows-msvc + - uses: Swatinem/rust-cache@v2 + - name: Ensure Inno Setup 6 is installed + shell: pwsh + run: | + $iscc = Get-Command ISCC -ErrorAction SilentlyContinue + if (-not $iscc -and -not (Test-Path 'C:\Program Files (x86)\Inno Setup 6\ISCC.exe')) { + choco install innosetup -y --no-progress + } + - name: Build packaged executables and Setup installer + shell: pwsh + run: | + $ver = (Select-String -Path Cargo.toml -Pattern '^version\s*=\s*"([^"]+)"').Matches[0].Groups[1].Value + echo "VERSION=$ver" >> $env:GITHUB_ENV + python desktop/build_release.py --output dist/OpenXER.exe --installer --installer-output release-assets + New-Item -ItemType Directory -Force -Path release-assets | Out-Null + Compress-Archive -Path dist/* -DestinationPath "release-assets/OpenXER-$ver-windows-x64.zip" -Force + Get-ChildItem release-assets + - uses: actions/upload-artifact@v4 + with: + name: release-windows + path: release-assets/* + + build-linux: + name: Build Linux AppImage and portable tarball + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + - name: System packages + run: | + sudo apt-get update + sudo apt-get install -y --no-install-recommends build-essential pkg-config libssl-dev desktop-file-utils file + - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 + - name: Build release binaries + run: cargo build --release -p openxer-desktop -p openxer-automation + - name: Package portable tarball and AppImage + run: | + set -euo pipefail + VER=$(sed -n 's/^version = "\([^"]*\)"/\1/p' Cargo.toml | head -n 1) + mkdir -p release-assets "stage/OpenXER-${VER}-linux-x86_64" + STAGE="stage/OpenXER-${VER}-linux-x86_64" + cp target/release/OpenXER "$STAGE/openxer" + cp target/release/openxer-cli "$STAGE/openxer-cli" + chmod +x "$STAGE/openxer" "$STAGE/openxer-cli" + cp automation/README.md "$STAGE/CLI-MCP.md" + cp LICENSE-MIT LICENSE-APACHE THIRD_PARTY.md "$STAGE/" + cat > "$STAGE/openxer.mcp.json" <<'EOF' + { + "mcpServers": { + "openxer": { + "command": "", + "args": ["mcp"] + } + } + } + EOF + tar -C stage -czf "release-assets/OpenXER-${VER}-linux-x86_64.tar.gz" "OpenXER-${VER}-linux-x86_64" + + # Build AppImage from the same executables and icon. + APPDIR="stage/OpenXER.AppDir" + mkdir -p "$APPDIR/usr/bin" "$APPDIR/usr/share/doc/openxer" + cp "$STAGE/openxer" "$APPDIR/usr/bin/openxer" + cp "$STAGE/openxer-cli" "$APPDIR/usr/bin/openxer-cli" + cp "$STAGE/CLI-MCP.md" "$STAGE/LICENSE-MIT" "$STAGE/LICENSE-APACHE" "$STAGE/THIRD_PARTY.md" "$APPDIR/usr/share/doc/openxer/" + cp assets/icons/openxer_256.png "$APPDIR/openxer.png" + cat > "$APPDIR/openxer.desktop" <<'EOF' + [Desktop Entry] + Type=Application + Name=OpenXER + Comment=Native desktop CPM scheduler for XER files + Exec=openxer %f + Icon=openxer + Categories=Office;ProjectManagement; + Terminal=false + EOF + cat > "$APPDIR/AppRun" <<'EOF' + #!/bin/sh + HERE="$(dirname "$(readlink -f "$0")")" + exec "$HERE/usr/bin/openxer" "$@" + EOF + chmod +x "$APPDIR/AppRun" + curl -fsSL -o stage/appimagetool "https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage" + chmod +x stage/appimagetool + ARCH=x86_64 stage/appimagetool --appimage-extract-and-run "$APPDIR" "release-assets/OpenXER-${VER}-x86_64.AppImage" + ls -lh release-assets + - uses: actions/upload-artifact@v4 + with: + name: release-linux + path: release-assets/* + + publish: + name: Publish GitHub Release + needs: [build-windows, build-linux] + if: startsWith(github.ref, 'refs/tags/v') + runs-on: ubuntu-latest + steps: + - uses: actions/download-artifact@v4 + with: + path: artifacts + merge-multiple: true + - name: Generate SHA256SUMS.txt + working-directory: artifacts + run: | + sha256sum * > SHA256SUMS.txt + cat SHA256SUMS.txt + - uses: softprops/action-gh-release@v2 + with: + generate_release_notes: true + files: artifacts/* diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1635e46 --- /dev/null +++ b/.gitignore @@ -0,0 +1,22 @@ +/target/ + +# Machine-specific settings: linker and SDK paths, and the [env] test inputs. +/.cargo/config.toml +/AGENTS.local.md + +# Build output and local application data. +/dist/ +/artifacts/ +/desktop/*.log +/desktop/verification/ +**/__pycache__/ +tools/icons/_review/ + +# Client data never belongs in the repo. Regression fixtures live outside it +# (OPENXER_FIXTURES); schedules and workspaces are never committed. +/engine/fixtures/ +*.xer +*.XER +**/openxer.db* +*.sqlite +*.sqlite3 diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..13ee766 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,193 @@ +# AGENTS.md + +Instructions for AI coding agents (and the humans who direct them) working on +OpenXER. Read the whole file before changing anything. If an `AGENTS.local.md` +exists next to this file, read it too: it holds the maintainer's machine +setup and is never committed. + +## What OpenXER is + +OpenXER is a desktop CPM scheduler for XER files, written in Rust. It opens, +schedules, levels, edits and saves XER schedules, and every edit is also +available to AI agents through `openxer-cli` and its MCP server. + +| Crate | What it is | Depends on | +|---|---|---| +| `engine` | CPM scheduling, calendars, resource leveling | nothing | +| `xer` | XER read/write and the shared edit layer | engine | +| `interchange` | XER export and merge, baselines, Excel (XLSX) import and export, export templates, report and S-curve workbooks | engine, xer | +| `desktop` | the app (egui/eframe) | engine, xer, interchange, automation (the AI Agents menu uses `connect`) | +| `automation` | `openxer-cli` and the MCP server | engine, xer, interchange | +| `chat` | `openxer-chat`: Sign in with ChatGPT, tokens in Windows Credential Manager, and a streaming Responses API client with the tool loop, for the Chat window; `compat`: an OpenAI-compatible endpoint with the user's API key or a model on this PC (kept out of `openxer-cli`; its live examples are `cargo run -p openxer-chat --example live_chat` and `--example compat_chat`) | nothing (engine and xer for its examples only) | + +Also tracked: `README.md`, `automation/README.md` (CLI and MCP reference), +`automation/COVERAGE.md` (which app command or field each CLI command and MCP +tool covers, and the gaps), +`THIRD_PARTY.md` (license notices), `assets/` (icons and starter report +definitions compiled into the app, `assets/sample-project.txt`, the +invented data table the first-run sample project is built from by +`xer/src/sample_project.rs`, `assets/playbooks/`, the scheduling +playbooks the chat tool `openxer_playbook` serves, and `assets/skills/`, +the built-in skills for AI agents compiled into `openxer-cli` and the app), `desktop/assets/spell/` (word lists), +`tools/icons/` (the icon generator), `tools/spell/` (the word list generator +`THIRD_PARTY.md` cites), `tools/licenses/third_party.py` (regenerates the +crate and SQLite notices in `THIRD_PARTY.md` for the Windows and Linux +executables together, the same output on either system; run it after a +dependency change), `tools/winres.rs` (the Windows icon, version and manifest resources +the `desktop` and `automation` build scripts embed), `docs/images/` (README screenshots, rendered from a +synthetic sample schedule by the ignored tests in +`desktop/src/readme_hero.rs`: `cargo test -p openxer-desktop --bin OpenXER readme -- --ignored`). +Screenshots in the repo are only ever rendered from that synthetic sample. + +For any UI work read `DESIGN.md` first: the one shared implementation of each +control, the standard measurements and the tests that guard them. + +For engine work read `engine/RULES.md` (each scheduling rule, with an ID that +code and tests cite, and the evidence for it) and `engine/PARITY.md` (how the +engine compares with the results stored in real schedule files). + +## Accuracy is the product + +People trust a scheduler only if its dates are right. Every engine rule is +backed by evidence: a real XER whose stored results it reproduces, or a +controlled test case. Never change scheduling behavior without that evidence, +a test that pins it, and the regression counts below staying exact. + +## Building and running + +- Rust stable with the MSVC target on Windows. `cargo build -p openxer-desktop` + builds the app; `cargo build -p openxer-automation` builds `openxer-cli`. +- Linux (CI runs Ubuntu 22.04): the same commands, with no extra flags or + features. Building needs only a C compiler (`build-essential`, for the + bundled SQLite); the X11, Wayland, OpenGL and file-dialog portal + libraries are loaded at run time, which a desktop session already has. + Install `fonts-liberation` so text measures close to Windows: the app + uses the real Arial, Segoe UI and Tahoma when installed (or under + `WINDIR`, such as `/mnt/c/Windows` in WSL), else Liberation Sans, else + DejaVu Sans. Run the tests as a normal user, not root. +- Release: `cargo build --release -p openxer-desktop -p openxer-automation`, or + `python desktop/build_release.py --output \OpenXER.exe` for the + packaged static-runtime build with `CLI-MCP.md`, the license files, + `THIRD_PARTY.md` and an `openxer.mcp.json` template (its command is a + placeholder, never a path from the build machine). `--package-only` + writes just those files, without building. `--installer` also builds + `target/installer/OpenXER--setup.exe` from those files with Inno + Setup 6 (`tools/installer/openxer.iss`; the version comes from Cargo); + `--sign-command ""` signs the executables and Setup. +- Workspace location (`Store::default_path_in`): `OPENXER_DATA_DIR` when + set; an installed copy (the `openxer.installed` marker Setup puts beside + the EXE) uses `%LOCALAPPDATA%\OpenXER`; a portable copy uses `openxer.db` + beside the EXE, or `%LOCALAPPDATA%\OpenXER` when that folder is not + writable. On other systems `$XDG_DATA_HOME/OpenXER` (else + `~/.local/share/OpenXER`) takes the place of `%LOCALAPPDATA%\OpenXER` + (`openxer_automation::locate::user_data_base`). Never write a test that + touches the real data folder: set `OPENXER_DATA_DIR` or pass `--database`. +- The app holds the mutex `OpenXER.App` while it runs; Setup's `AppMutex` + names it. Keep the two in step. +- Line endings are LF (`.gitattributes`). From Python on Windows write files + with `newline=''` or `'\n'`. +- Machine-specific linker paths go in `.cargo/config.toml`, which is ignored. + +## Tests and the gate + +``` +cargo fmt --all --check +cargo clippy -p --all-targets -- -D warnings +cargo test -p --no-fail-fast -- --skip full_ui_sweep --skip dialog_formatting_sweep +# if you changed menus, dialogs, toolbars, shortcuts or the dialog kit: +cargo test -p openxer-desktop -- full_ui_sweep dialog_formatting_sweep +``` + +Test the crates you changed and every crate that depends on them (table +above). Clippy must be clean with `-D warnings`. + +Some tests compare against real schedules that hold client data. Those inputs +never live in the repo. They are found through environment variables (set +them in the ignored `.cargo/config.toml` under `[env]`), and the tests skip +with a printed reason when the variable is not set: + +| Variable | What it points at | +|---|---| +| `OPENXER_FIXTURES` | engine regression fixtures (`oxdiff` and engine tests) | +| `OPENXER_CORPUS` | a folder of corpus XER files | +| `OPENXER_RPT_INPUTS`, `OPENXER_RPT_DB` | report definition import tests | + +Lists that must not be published are private fixtures in the +`OPENXER_FIXTURES` folder too: `corpus-names.txt` (corpus files whose names +identify a job, read through `openxer_engine::fixture::corpus_names`) and +`internal-refs.txt` (words the engine sources must not contain, read by +`engine/tests/no_internal_refs.rs`). Tests that need them skip with a +printed reason when they are absent. + +When the fixtures are available, any change under `engine/` or to how `xer` +derives durations must keep `oxdiff` exact +(`cargo build --release -p openxer-engine --bin oxdiff`, then with +`OPENXER_FIXTURES` set in the shell run `oxdiff cal`, `oxdiff forward`, +`oxdiff engine`, `oxdiff roundtrip`, `oxdiff engine regressions` and +`oxdiff engine features`): cal 77620, forward 19624, engine 86356, +roundtrip 17, regressions 129622, features 424. A different count fails. + +Useful desktop test filters: `headless_ui`, `headless_render` (renders go to +the ignored `artifacts/`), `qa_sweep`, and the ignored `perf_369`. + +## Rules that are never bent + +- **No client data in the repo, ever.** No XER files from real jobs, + workspace databases, screenshots or renders of real projects, or fixtures. + Test data that is committed must be synthetic. Issues and pull requests must + not attach real schedules either. +- **Original work only.** OpenXER may follow the functional conventions of + scheduling software users already know (layouts, control types, short + labels, menu and dialog structure). It never copies protected expression: + - no other product's name or logo in UI text, CLI or MCP output, docs or + packaging, beyond plain compatibility statements ("reads and writes XER + files"); + - no icons, bitmaps or artwork from other products, even recolored or + traced (icons are drawn for this project: `chrome::Icon`, `tools/icons/`); + - no code, help text, documentation prose, reports or data files from other + products, and never decompiled or disassembled material of any kind; + - our own names in code (`activity`, `link`, `calendar`), except where a + file format defines the name (XER table and field names stay as the + format spells them). +- **Default colors are OpenXER's own** (`desktop/src/theme.rs`). A color the + user chose is stored as chosen; defaults only fill in where nothing was + stored. Layouts are user-level, not per project. +- **Headless only.** Never open native windows or move the system cursor. + Drive and look at the UI through the test harnesses + (`desktop/src/headless_ui.rs`, `headless_render.rs`, the `qa_sweep.rs` + driver). Do not launch `OpenXER.exe` unless the maintainer asks. +- **No em dashes or en dashes** anywhere (code, comments, docs, UI text, + commit messages). Use a hyphen or rewrite the sentence. +- **Never stop or kill processes you did not start.** +- **Keep the repo lean.** Track only what building, running, testing and + developing OpenXER need. No plans, run logs, status files, prompts, research + notes or sample outputs. + +## How the app is built (conventions) + +- Every command that changes project data is one undo step and refreshes + caches (`edit_step` and `records_revision`). +- Every dialog closes on Escape; Cancel or Close leaves the project unchanged. + The QA sweep clicks every menu command and checks this. +- Data an XER carries must import, survive save and reload, and export. + Unknown tables pass through untouched. +- Edits from anywhere (table, Details, import, CLI, MCP) go through the shared + edit layer in `xer/src/edit/` and the desktop setters that delegate to it, + so the app, the CLI and MCP always behave the same. +- Every feature that changes project data gets a CLI command and an MCP tool + from the same command definition in `automation/`. +- A skill (`assets/skills/*.md`, `automation/src/skills.rs`) names only tools + that exist, and the agent never computes schedule numbers itself: a number + a skill needs comes from a read-only tool (add one first) or the step goes. + Built-in skills say nothing about where a method comes from. +- A control that already exists is reused, or extracted into a shared + function, never written a second time (the details tab strip is + `desktop/src/tab_strip.rs`). Where two views differ, the Activities page + is the reference. + +## Working on a change + +- One branch per change, off `main`, in its own worktree if several agents + work at once. Do not commit to `main` directly; open a pull request. +- Describe what you built and what is unverified in the commit message and the + pull request, with the gate results. diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..b6945d9 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,100 @@ +# Changelog + +All notable changes to OpenXER are recorded here. The format follows +[Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and versions follow +[Semantic Versioning](https://semver.org/). The newest release is at the top. + +## [Unreleased] + +The first public release. + +### Added +- A native Windows desktop scheduler for XER files: open, schedule, level, + update, check, compare, print, report and save schedules, with the + activity table beside the Gantt chart and Activity Details underneath. +- Open any XER file, pick the projects it holds, and open several projects + at once. Tables and fields OpenXER does not use are carried through + untouched when the project is exported again. +- Import into a new project, replace an existing one, or add activities into + a project you already have, with Undo Last Import. Export to XER, project + XML or Excel (the OpenXER layout or the XER table layout, with saved export + templates for the columns), and import from XER, project XML or Excel. The + XML form carries projects with their schedule options, WBS, activities, + relationships, calendars, resources with their codes, assignments, + activity codes, user defined fields, expenses, notebooks, the OBS and + currencies; other XER data stays in XER. XML files exported by the product + that defines the format open in OpenXER; XML files OpenXER writes follow + the structure of such an export but have not yet been opened in it. Reports, Schedule + Comparison and Project Checker results can also be saved as CSV files. +- A critical path engine with calendars, shifts and holidays, every + constraint type, relationship types and lags, Level of Effort and WBS + summary activities, retained logic, progress override and actual dates, + expected finish, longest path and multiple float paths. Each run writes a + schedule log, and automatic scheduling can follow every edit. +- Resource leveling with priorities, limits, calendars, leveling within + float and selected resources, and a leveling log of what moved. +- Progress: status, actual dates, remaining duration and percent complete in + the table or the Status tab, Update Progress, Apply Actuals, Progress + Spotlight, steps, suspend and resume, resource actuals and Save Period + Actuals. +- Check Schedule scores the schedule against common health targets (open + ends, lags, relationship types, constraints, float, long durations, + invalid progress dates, out-of-sequence progress and more) and filters the + table to what each check finds. +- Trace Logic, Activity Network, Activity Critical Path, driving + relationships and Schedule Comparison between two projects or a project + and its baseline. +- Table and Gantt layouts: columns for every schedule, resource, cost, + earned value, code and user defined field; grouping with band totals; + filters with nested conditions and dates relative to the data date; bars + you can drag; curtains, sight lines, a progress line and baseline bars; a + timescale from hours to years; and named layouts you can export and + import. +- Bottom views: usage profiles and spreadsheets, a second table and Gantt + chart, Trace Logic and the Activity Network, with tab groups and a second + Activities view. +- Resources, roles, rates, shifts and calendars, all editable, with Del. / + Merge for unused or duplicate resources. +- Resource curves: ten preset curves and the file's own. On Fixed Duration + activities an assignment's units and costs follow its curve over its own + dates in the usage views, time-phased reports and planned value; the + schedule and the stored units do not change. The exact per-period numbers + follow OpenXER's reading of the documented behavior. +- Usage profiles with stacked histograms by resource or role, actual and + remaining in one bar, cumulative curves and each resource's limit. +- Expenses, cost accounts, funding sources, currencies, issues, risks, + thresholds and Monitor Thresholds, including cost and earned value + thresholds. +- Baselines: any number of them, a project baseline and up to three user + baselines, baseline bars, variance columns and earned value against the + baseline you choose. +- Print and Print Preview of the layout on screen, page setup, and publish + to PDF. +- A Reports window with a starter set of scheduling reports, your own + report definitions in groups, and batch runs to PDF, HTML, text or print + preview. +- `openxer-cli` and a local MCP server over stdio. Every edit the app can + make is a command and a tool that goes through the same rules as the app: + single edits, `apply` batches that run all or nothing, dry runs that show + every changed field, and `meta` notes on each change. +- Agents can also read and edit documents and their files, expenses, + issues, risks, thresholds, earned value, steps, assignments, WBS, calendars + and resource curves. `automation/COVERAGE.md` maps every app command to + the CLI and MCP. +- The AI Agents menu connects an AI assistant on this PC to the MCP server, + checks the connection and shows what an agent can do. +- Skills for AI agents: a library of instructions for checking and building + schedules (logic health, critical and near-critical paths, update and + baseline reviews, look-aheads, milestones, resources, building a schedule + from a scope, progress updates, what-if and recovery options, time impact + of a change and more), served to every connected agent as tools and as + prompts. AI Agents > Skills lists them and lets you edit them or write + your own; `openxer-cli skills` does the same from the command line. +- Read-only analysis tools agents use for every number they report: Check + Schedule, float paths, comparison with a baseline or an earlier file, + look-ahead, milestones, schedule statistics, resource loading and a WBS + rollup. +- Built-in help: a topic for every dialog and main view, with contents, + search, Back and Forward, F1 for the dialog or view in front, and + Help > What's New... for these release notes. +- Dual license: MIT OR Apache-2.0. diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..43c994c --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1 @@ +@AGENTS.md diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..b6b96d8 --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,13 @@ +# Code of conduct + +OpenXER follows the [Contributor Covenant, version 2.1](https://www.contributor-covenant.org/version/2/1/code_of_conduct/). + +In short: be respectful and constructive, assume good intent, and keep +discussion about the work. Harassment, insults and personal attacks are not +accepted in issues, pull requests or any other project space. + +To report a problem, contact the maintainers privately through the +repository's Security tab (**Report a vulnerability** also reaches them +privately), or by a direct message to a maintainer. Reports are handled in +confidence, and the maintainers may remove comments or block participants +who break this code. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..2295f8b --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,76 @@ +# Contributing to OpenXER + +Thank you for helping. OpenXER is a scheduler, so the bar is accuracy: a +change that moves a date needs evidence and a test. + +## Before you start + +- Open an issue first for anything larger than a small fix, so the approach + can be agreed before you write it. +- If you use an AI coding agent, point it at [AGENTS.md](AGENTS.md). The rules + there apply to human contributors too. + +## Build and test + +```text +cargo build -p openxer-desktop -p openxer-automation +cargo fmt --all --check +cargo clippy --workspace --all-targets -- -D warnings +cargo test --workspace -- --skip full_ui_sweep --skip dialog_formatting_sweep +``` + +Run `cargo test -p openxer-desktop -- full_ui_sweep dialog_formatting_sweep` +as well when you change menus, dialogs, toolbars or shortcuts. + +Some tests compare against real schedules that only the maintainers hold. +They skip with a printed reason on your machine; that is expected. The +maintainers run them before merging. + +## What a good pull request has + +- One focused change, with a clear description of what it does and why. +- Tests for new behavior. Scheduling changes need a test that pins the exact + dates or float, and a short note of the evidence (for example: "an XER saved + by a scheduler with these options shows these dates"). +- `cargo fmt`, clippy with `-D warnings` and the tests passing. +- No unrelated reformatting or renames. + +## AI-assisted pull requests + +AI coding agents are welcome here (read [AGENTS.md](AGENTS.md) first). Every +pull request still needs a human author who ran the checks, verified the +behavior and can explain the change. + +## Contributing scheduling skills + +You do not need to write Rust to contribute. OpenXER's built-in skills in +`assets/skills/` are plain Markdown files that guide connected AI agents +through real scheduling reviews and workflows. Open a pull request to improve +an existing skill or propose a new one; keep every example invented and free +of real project data. + +## Hard rules + +- **No client or project data.** Never commit or attach real schedules, + workspace databases, or screenshots of real projects, in code, tests, + issues or pull requests. Build test data in code or use invented examples. +- **Original work only.** Do not contribute code, icons, artwork, help text or + data taken from other software, and never anything decompiled or + disassembled. Do not use other products' names or logos in the app or docs. +- **No em dashes or en dashes** in code, comments, docs or UI text. + +## Reporting bugs + +Use the bug report form. Describe the schedule shape that triggers the +problem (activity types, relationship types, calendars, options) rather than +attaching a real file. If a file is needed to reproduce it, make a small +invented one. + +Security problems: see [SECURITY.md](SECURITY.md); do not open a public issue. + +## License + +Unless you explicitly state otherwise, any contribution intentionally +submitted for inclusion in OpenXER by you, as defined in the Apache-2.0 +license, shall be dual licensed as MIT OR Apache-2.0, without any additional +terms or conditions. diff --git a/Cargo.lock b/Cargo.lock new file mode 100644 index 0000000..a2a62ab --- /dev/null +++ b/Cargo.lock @@ -0,0 +1,4598 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "ab_glyph" +version = "0.2.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "01c0457472c38ea5bd1c3b5ada5e368271cb550be7a4ca4a0b4634e9913f6cc2" +dependencies = [ + "ab_glyph_rasterizer", + "owned_ttf_parser", +] + +[[package]] +name = "ab_glyph_rasterizer" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "366ffbaa4442f4684d91e2cd7c5ea7c4ed8add41959a31447066e279e432b618" + +[[package]] +name = "adler2" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" + +[[package]] +name = "adobe-cmap-parser" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae8abfa9a4688de8fc9f42b3f013b6fffec18ed8a554f5f113577e0b9b3212a3" +dependencies = [ + "pom", +] + +[[package]] +name = "aes" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0" +dependencies = [ + "cfg-if", + "cipher", + "cpufeatures 0.2.17", +] + +[[package]] +name = "ahash" +version = "0.8.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a15f179cd60c4584b8a8c596927aadc462e27f2ca70c04e0071964a73ba7a75" +dependencies = [ + "cfg-if", + "getrandom 0.3.4", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "android-activity" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f2a1bb052857d5dd49572219344a7332b31b76405648eabac5bc68978251bcd" +dependencies = [ + "android-properties", + "bitflags 2.13.2", + "cc", + "jni", + "libc", + "log", + "ndk", + "ndk-context", + "ndk-sys", + "num_enum", + "thiserror 2.0.21", +] + +[[package]] +name = "android-properties" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc7eb209b1518d6bb87b283c20095f5228ecda460da70b44f0802523dea6da04" + +[[package]] +name = "android_system_properties" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc" +dependencies = [ + "libc", +] + +[[package]] +name = "arboard" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aeb9553e62312c8756a5979254fc6d7da8bbeb5986a1e17037fab932f7037917" +dependencies = [ + "clipboard-win", + "image", + "log", + "objc2 0.6.5", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation 0.3.2", + "parking_lot", + "percent-encoding", + "windows-sys 0.61.2", + "x11rb", +] + +[[package]] +name = "arrayvec" +version = "0.7.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3fb67a6e08acf24fdeccbac2cb6ac4305825bd1f117462e0e6f2f193345ad56" + +[[package]] +name = "as-raw-xcb-connection" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "175571dd1d178ced59193a6fc02dde1b972eb0bc56c892cde9beeceac5bf0f6b" + +[[package]] +name = "ashpd" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2f3f79755c74fd155000314eb349864caa787c6592eace6c6882dad873d9c39" +dependencies = [ + "async-fs", + "async-net", + "enumflags2", + "futures-channel", + "futures-util", + "rand 0.9.5", + "raw-window-handle", + "serde", + "serde_repr", + "url", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "zbus", +] + +[[package]] +name = "async-broadcast" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532" +dependencies = [ + "event-listener", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-channel" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2" +dependencies = [ + "concurrent-queue", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-executor" +version = "1.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f426a31126c735126297bc5ea7a521263c9faff4f63ca415267ee625651c4f37" +dependencies = [ + "async-task", + "concurrent-queue", + "fastrand", + "futures-lite", + "pin-project-lite", + "slab", +] + +[[package]] +name = "async-fs" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8034a681df4aed8b8edbd7fbe472401ecf009251c8b40556b304567052e294c5" +dependencies = [ + "async-lock", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-io" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc" +dependencies = [ + "autocfg", + "cfg-if", + "concurrent-queue", + "futures-io", + "futures-lite", + "parking", + "polling", + "rustix 1.1.6", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-lock" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0876700b0d007ad25d5508865a4259c3af9af6d296bf663a0d586d0bc3369f6f" +dependencies = [ + "event-listener", + "event-listener-strategy", + "pin-project-lite", +] + +[[package]] +name = "async-net" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b948000fad4873c1c9339d60f2623323a0cfd3816e5181033c6a5cb68b2accf7" +dependencies = [ + "async-io", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-process" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75" +dependencies = [ + "async-channel", + "async-io", + "async-lock", + "async-signal", + "async-task", + "blocking", + "cfg-if", + "event-listener", + "futures-lite", + "rustix 1.1.6", +] + +[[package]] +name = "async-recursion" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f8abc12baad266b1c8cec146854c195b5864b4221d4b2ca7296a7ae82d9e451" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "async-signal" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485" +dependencies = [ + "async-io", + "async-lock", + "atomic-waker", + "cfg-if", + "futures-core", + "futures-io", + "rustix 1.1.6", + "signal-hook-registry", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-task" +version = "4.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" + +[[package]] +name = "async-trait" +version = "0.1.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82f6aeea286b8eb4dd3431a1be1b59d290ace00f5bfd8e2a159bc2a05e2c1667" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "atoi_simd" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cdb3708a128e559a30fb830e8a77a5022ee6902806925c216658652b452a44" +dependencies = [ + "debug_unsafe", + "rustversion", +] + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" + +[[package]] +name = "bit-set" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3" +dependencies = [ + "bit-vec", +] + +[[package]] +name = "bit-vec" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ded4057c258ba199e2d26386d3af3780957ecaee6c4ef4041c6b4b8b97c0b06" + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-padding" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8894febbff9f758034a5b8e12d87918f56dfc64a8e1fe757d65e29041538d93" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block2" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c132eebf10f5cad5289222520a4a058514204aed6d791f1cf4fe8088b82d15f" +dependencies = [ + "objc2 0.5.3", +] + +[[package]] +name = "block2" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5" +dependencies = [ + "objc2 0.6.5", +] + +[[package]] +name = "blocking" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a70e4329df6cb94385eed412ec92375c3cdd8a6e502493d1229b6414e4036dfa" +dependencies = [ + "async-channel", + "async-task", + "futures-io", + "futures-lite", + "piper", +] + +[[package]] +name = "bumpalo" +version = "3.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649" + +[[package]] +name = "bytemuck" +version = "1.25.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95832e849adfb21180ccb6826a99da14e5d266ae5c2e668e1602cf234f153797" +dependencies = [ + "bytemuck_derive", +] + +[[package]] +name = "bytemuck_derive" +version = "1.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a1f896587b6f2c069c73d2f0913e2d590c3990285cd2f0b6aa02b786b4c679c" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "byteorder-lite" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495" + +[[package]] +name = "bytes" +version = "1.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04" + +[[package]] +name = "calamine" +version = "0.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f431b67cba6122a1f7d26b7adafc71bbdf07026095fe811f5efc025d8748e1d8" +dependencies = [ + "atoi_simd", + "byteorder", + "codepage", + "encoding_rs", + "fast-float2", + "log", + "quick-xml 0.42.0", + "serde", + "zip", +] + +[[package]] +name = "calloop" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b99da2f8558ca23c71f4fd15dc57c906239752dd27ff3c00a1d56b685b7cbfec" +dependencies = [ + "bitflags 2.13.2", + "log", + "polling", + "rustix 0.38.44", + "slab", + "thiserror 1.0.69", +] + +[[package]] +name = "calloop" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43b32313e937c8721c9d17ee9bf60699a6402b4b7c2cb6ac1bee0ffcaa4b4e5e" +dependencies = [ + "bitflags 2.13.2", + "polling", + "rustix 1.1.6", + "tracing", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a66a987056935f7efce4ab5668920b5d0dac4a7c99991a67395f13702ddd20" +dependencies = [ + "calloop 0.13.0", + "rustix 0.38.44", + "wayland-backend", + "wayland-client", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "138efcf0940a02ebf0cc8d1eff41a1682a46b431630f4c52450d6265876021fa" +dependencies = [ + "calloop 0.14.5", + "rustix 1.1.6", + "wayland-backend", + "wayland-client", +] + +[[package]] +name = "cbc" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26b52a9543ae338f279b96b0b9fed9c8093744685043739079ce85cd58f289a6" +dependencies = [ + "cipher", +] + +[[package]] +name = "cc" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "375989decec1a0fa424442bed520fa12ede43a48475ce8c7417d2c69b32b5f6b" +dependencies = [ + "find-msvc-tools", + "jobserver", + "libc", + "shlex", +] + +[[package]] +name = "cff-parser" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5810ca1a2b5870df2aab1c03e11c40c361ba51d6e3e361e56310f1cb3b4e087" + +[[package]] +name = "cfg-if" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e7648175b45a9a48536d676f68d918270699102aa8dab5496df06904c914600" + +[[package]] +name = "cfg_aliases" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f079e83a288787bcd14a6aea84cee5c87a67c5a3e660c30f557a3d24761b3527" + +[[package]] +name = "cgl" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ced0551234e87afee12411d535648dd89d2e7f34c78b753395567aff3d447ff" +dependencies = [ + "libc", +] + +[[package]] +name = "chacha20" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "65c35e4b699c7e15ccbe7ee35c005e4fc0a278d22238a2857e6ce2dadeda1b06" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.1", + "rand_core 0.10.1", +] + +[[package]] +name = "chrono" +version = "0.4.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327" +dependencies = [ + "iana-time-zone", + "js-sys", + "num-traits", + "wasm-bindgen", + "windows-link", +] + +[[package]] +name = "cipher" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" +dependencies = [ + "crypto-common", + "inout", +] + +[[package]] +name = "clipboard-win" +version = "5.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "052af7878466feccda12ba7a6a67d019d712f296809559b47c12c8cc196d3a9a" +dependencies = [ + "error-code", +] + +[[package]] +name = "codepage" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bdff162541cd8b79de82e2edcc7eff3a8c2a6dc3d75152636028f96d93de3b26" +dependencies = [ + "encoding_rs", +] + +[[package]] +name = "codespan-reporting" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe6d2e5af09e8c8ad56c969f2157a3d4238cebc7c55f0a517728c38f7b200f81" +dependencies = [ + "unicode-width", +] + +[[package]] +name = "combine" +version = "4.6.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4356eba6976435498d05a311ee9fc486da3bc81c200d3f0d7dd9703b41913f92" +dependencies = [ + "bytes", + "memchr", +] + +[[package]] +name = "concurrent-queue" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" + +[[package]] +name = "core-graphics" +version = "0.23.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c07782be35f9e1140080c6b96f0d44b739e2278479f64e02fdab4e32dfd8b081" +dependencies = [ + "bitflags 1.3.2", + "core-foundation 0.9.4", + "core-graphics-types", + "foreign-types 0.5.0", + "libc", +] + +[[package]] +name = "core-graphics-types" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45390e6114f68f718cc7a830514a96f903cccd70d02a8f6d9f643ac4ba45afaf" +dependencies = [ + "bitflags 1.3.2", + "core-foundation 0.9.4", + "libc", +] + +[[package]] +name = "core_detect" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f8f80099a98041a3d1622845c271458a2d73e688351bf3cb999266764b81d48" + +[[package]] +name = "cpufeatures" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" +dependencies = [ + "libc", +] + +[[package]] +name = "cpufeatures" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ca28b0ae3115b884660db4118d803791fd6756b6e88f39c0f3f7859060d7566" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f97d3416d5337d15c4b0d78c8c91df922ca143f57ec20e2d1c188333047ef04" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a31eee39dddec8330830986fcd7625edb5a24ec90ea038215273bbc3adb08ac6" + +[[package]] +name = "crunchy" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5" + +[[package]] +name = "crypto-common" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "cursor-icon" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f27ae1dd37df86211c42e150270f82743308803d90a6f6e6651cd730d5e1732f" + +[[package]] +name = "debug_unsafe" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7eed2c4702fa172d1ce21078faa7c5203e69f5394d48cc436d25928394a867a2" + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer", + "crypto-common", +] + +[[package]] +name = "dispatch" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" + +[[package]] +name = "dispatch2" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38" +dependencies = [ + "bitflags 2.13.2", + "block2 0.6.2", + "libc", + "objc2 0.6.5", +] + +[[package]] +name = "displaydoc" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "dlib" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab8ecd87370524b461f8557c119c405552c396ed91fc0a8eec68679eab26f94a" +dependencies = [ + "libloading", +] + +[[package]] +name = "document-features" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4b8a88685455ed29a21542a33abd9cb6510b6b129abadabdcef0f4c55bc8f61" +dependencies = [ + "litrs", +] + +[[package]] +name = "downcast-rs" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" + +[[package]] +name = "dpi" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8b14ccef22fc6f5a8f4d7d768562a182c04ce9a3b3157b91390b52ddfdf1a76" + +[[package]] +name = "ecb" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a8bfa975b1aec2145850fcaa1c6fe269a16578c44705a532ae3edc92b8881c7" +dependencies = [ + "cipher", +] + +[[package]] +name = "ecolor" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71ddb8ac7643d1dba1bb02110e804406dd459a838efcb14011ced10556711a8e" +dependencies = [ + "bytemuck", + "emath", +] + +[[package]] +name = "eframe" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "457481173e6db5ca9fa2be93a58df8f4c7be639587aeb4853b526c6cf87db4e6" +dependencies = [ + "ahash", + "bytemuck", + "document-features", + "egui", + "egui-wgpu", + "egui-winit", + "egui_glow", + "glow", + "glutin", + "glutin-winit", + "image", + "js-sys", + "log", + "objc2 0.5.3", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", + "parking_lot", + "percent-encoding", + "profiling", + "raw-window-handle", + "static_assertions", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "web-time", + "windows-sys 0.61.2", + "winit", +] + +[[package]] +name = "egui" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a9b567d356674e9a5121ed3fedfb0a7c31e059fe71f6972b691bcd0bfc284e3" +dependencies = [ + "ahash", + "bitflags 2.13.2", + "emath", + "epaint", + "log", + "nohash-hasher", + "profiling", + "smallvec", + "unicode-segmentation", +] + +[[package]] +name = "egui-wgpu" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e4d209971c84b2352a06174abdba701af1e552ce56b144d96f2bd50a3c91236" +dependencies = [ + "ahash", + "bytemuck", + "document-features", + "egui", + "epaint", + "log", + "profiling", + "thiserror 2.0.21", + "type-map", + "web-time", + "wgpu", + "winit", +] + +[[package]] +name = "egui-winit" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec6687e5bb551702f4ad10ac428bab12acf9d53047ebb1082d4a0ed8c6251a29" +dependencies = [ + "arboard", + "bytemuck", + "egui", + "log", + "objc2 0.5.3", + "objc2-foundation 0.2.2", + "objc2-ui-kit", + "profiling", + "raw-window-handle", + "smithay-clipboard", + "web-time", + "webbrowser", + "winit", +] + +[[package]] +name = "egui_extras" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d01d34e845f01c62e3fded726961092e70417d66570c499b9817ab24674ca4ed" +dependencies = [ + "ahash", + "chrono", + "egui", + "enum-map", + "log", + "mime_guess2", + "profiling", +] + +[[package]] +name = "egui_glow" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6420863ea1d90e750f75075231a260030ad8a9f30a7cef82cdc966492dc4c4eb" +dependencies = [ + "bytemuck", + "egui", + "glow", + "log", + "memoffset", + "profiling", + "wasm-bindgen", + "web-sys", + "winit", +] + +[[package]] +name = "emath" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "491bdf728bf25ddd9ad60d4cf1c48588fa82c013a2440b91aa7fc43e34a07c32" +dependencies = [ + "bytemuck", +] + +[[package]] +name = "encoding_rs" +version = "0.8.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "89253175e704ab869b04f9db224d38630e0211a53841a79181deae0889e169f5" +dependencies = [ + "cfg-if", + "core_detect", + "multiversion_no_op", + "rustversion", + "scopeguard", + "simdutf8", +] + +[[package]] +name = "endi" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099" + +[[package]] +name = "enum-map" +version = "2.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6866f3bfdf8207509a033af1a75a7b08abda06bbaaeae6669323fd5a097df2e9" +dependencies = [ + "enum-map-derive", +] + +[[package]] +name = "enum-map-derive" +version = "0.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f282cfdfe92516eb26c2af8589c274c7c17681f5ecc03c18255fe741c6aa64eb" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "enumflags2" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef" +dependencies = [ + "enumflags2_derive", + "serde", +] + +[[package]] +name = "enumflags2_derive" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "epaint" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "009d0dd3c2163823a0abdb899451ecbc78798dec545ee91b43aff1fa790bab62" +dependencies = [ + "ab_glyph", + "ahash", + "bytemuck", + "ecolor", + "emath", + "epaint_default_fonts", + "log", + "nohash-hasher", + "parking_lot", + "profiling", +] + +[[package]] +name = "epaint_default_fonts" +version = "0.33.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c4fbe202b6578d3d56428fa185cdf114a05e49da05f477b3c7f0fbb221f1862" + +[[package]] +name = "equivalent" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00d174d5400e5e8fd687ad1049e2f578285fa914201b1af7e8b112a4546bd826" + +[[package]] +name = "errno" +version = "0.3.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + +[[package]] +name = "error-code" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b5343afd4a8365a643ac588dab4cf234a190c7f6c88c9f6dd6ffe00837661b7" + +[[package]] +name = "euclid" +version = "0.20.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bb7ef65b3777a325d1eeefefab5b6d4959da54747e33bd6258e789640f307ad" +dependencies = [ + "num-traits", +] + +[[package]] +name = "event-listener" +version = "5.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a23add41df1562121a9393cb065eab5146a1242410f23a644851e90cfd669d2" +dependencies = [ + "parking", + "pin-project-lite", +] + +[[package]] +name = "event-listener-strategy" +version = "0.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93" +dependencies = [ + "event-listener", + "pin-project-lite", +] + +[[package]] +name = "fallible-iterator" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2acce4a10f12dc2fb14a218589d4f1f62ef011b2d0cc4b3cb1bba8e94da14649" + +[[package]] +name = "fallible-streaming-iterator" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7360491ce676a36bf9bb3c56c1aa791658183a54d2744120f27285738d90465a" + +[[package]] +name = "fast-float2" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6e8948ce679d00a02a94739ea185595dca7118ed04feb991127e443bd3d761f" + +[[package]] +name = "fastrand" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223" + +[[package]] +name = "fax" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a" + +[[package]] +name = "fdeflate" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c" +dependencies = [ + "simd-adler32", +] + +[[package]] +name = "find-msvc-tools" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c66915cc5391097de7a2b0b972e8505aa33c0df401fd3a6811dbdb32881ba48" + +[[package]] +name = "flate2" +version = "1.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e634e2e0ebac1ee034020da1ca582e17ffe4e0f5e985823721e168928136dcb" +dependencies = [ + "crc32fast", + "miniz_oxide 0.9.1", + "zlib-rs", +] + +[[package]] +name = "foldhash" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" + +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared 0.1.1", +] + +[[package]] +name = "foreign-types" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" +dependencies = [ + "foreign-types-macros", + "foreign-types-shared 0.3.1", +] + +[[package]] +name = "foreign-types-macros" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea5190182e6915eb873ddbc16e23b711b6eb1f9c00a0d0a3a91b5f6228475225" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "foreign-types-shared" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" + +[[package]] +name = "form_urlencoded" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1f9e3d69d39e4862ffed03ed071a76f9a13ba1d9109d355b0f0aa6b15e393c4" +dependencies = [ + "futures-core", +] + +[[package]] +name = "futures-core" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e" + +[[package]] +name = "futures-io" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53c0fa8157de1303bfffdaa1cc2a673bfffb60102f76b0ef4441659124373fed" + +[[package]] +name = "futures-lite" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad" +dependencies = [ + "fastrand", + "futures-core", + "futures-io", + "parking", + "pin-project-lite", +] + +[[package]] +name = "futures-macro" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb9654ba8355388abeb8dcb4fc62f511300867002afc858860463bdd9fe0c44" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "futures-task" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd" + +[[package]] +name = "futures-util" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc" +dependencies = [ + "futures-core", + "futures-io", + "futures-macro", + "futures-task", + "memchr", + "pin-project-lite", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "gethostname" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8" +dependencies = [ + "rustix 1.1.6", + "windows-link", +] + +[[package]] +name = "getrandom" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" +dependencies = [ + "cfg-if", + "libc", + "r-efi 5.3.0", + "wasip2", +] + +[[package]] +name = "getrandom" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" +dependencies = [ + "cfg-if", + "js-sys", + "libc", + "r-efi 6.0.0", + "rand_core 0.10.1", + "wasm-bindgen", +] + +[[package]] +name = "gl_generator" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a95dfc23a2b4a9a2f5ab41d194f8bfda3cabec42af4e39f08c339eb2a0c124d" +dependencies = [ + "khronos_api", + "log", + "xml-rs", +] + +[[package]] +name = "glow" +version = "0.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5e5ea60d70410161c8bf5da3fdfeaa1c72ed2c15f8bbb9d19fe3a4fad085f08" +dependencies = [ + "js-sys", + "slotmap", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "glutin" +version = "0.32.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "12124de845cacfebedff80e877bb37b5b75c34c5a4c89e47e1cdd67fb6041325" +dependencies = [ + "bitflags 2.13.2", + "cfg_aliases", + "cgl", + "dispatch2", + "glutin_egl_sys", + "glutin_glx_sys", + "glutin_wgl_sys", + "libloading", + "objc2 0.6.5", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "once_cell", + "raw-window-handle", + "wayland-sys", + "windows-sys 0.52.0", + "x11-dl", +] + +[[package]] +name = "glutin-winit" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85edca7075f8fc728f28cb8fbb111a96c3b89e930574369e3e9c27eb75d3788f" +dependencies = [ + "cfg_aliases", + "glutin", + "raw-window-handle", + "winit", +] + +[[package]] +name = "glutin_egl_sys" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c4680ba6195f424febdc3ba46e7a42a0e58743f2edb115297b86d7f8ecc02d2" +dependencies = [ + "gl_generator", + "windows-sys 0.52.0", +] + +[[package]] +name = "glutin_glx_sys" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7bb2938045a88b612499fbcba375a77198e01306f52272e692f8c1f3751185" +dependencies = [ + "gl_generator", + "x11-dl", +] + +[[package]] +name = "glutin_wgl_sys" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c4ee00b289aba7a9e5306d57c2d05499b2e5dc427f84ac708bd2c090212cf3e" +dependencies = [ + "gl_generator", +] + +[[package]] +name = "half" +version = "2.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ea2d84b969582b4b1864a92dc5d27cd2b77b622a8d79306834f1be5ba20d84b" +dependencies = [ + "cfg-if", + "crunchy", + "num-traits", + "zerocopy", +] + +[[package]] +name = "hashbrown" +version = "0.15.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" +dependencies = [ + "foldhash 0.1.5", +] + +[[package]] +name = "hashbrown" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" +dependencies = [ + "foldhash 0.2.0", +] + +[[package]] +name = "hashbrown" +version = "0.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" + +[[package]] +name = "hashlink" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7382cf6263419f2d8df38c55d7da83da5c18aef87fc7a7fc1fb1e344edfe14c1" +dependencies = [ + "hashbrown 0.15.5", +] + +[[package]] +name = "hermit-abi" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e17592d60ebacc7d5e169f4663c5f84f9161cc90328abcfe8456f41e4dfcb284" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hexf-parse" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfa686283ad6dd069f105e5ab091b04c62850d3e4cf5d67debad1933f55023df" + +[[package]] +name = "iana-time-zone" +version = "0.1.65" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "log", + "wasm-bindgen", + "windows-core", +] + +[[package]] +name = "iana-time-zone-haiku" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" +dependencies = [ + "cc", +] + +[[package]] +name = "icu_collections" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe090a42a0d3140fed8c63263ed1fecc02422cb2f4bfe55cd8de2de1b8e105dd" +dependencies = [ + "displaydoc", + "potential_utf", + "utf8_iter", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locale_core" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25d29b57c17c6528d0dc4c2141cfa2d08200465acb537a3909c8b9b8a4a984c0" +dependencies = [ + "displaydoc", + "litemap", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_normalizer" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "404a3b8c486f205c87fe7f23ab6894d84a4ad76d6e4671ae1981ba7def87c599" +dependencies = [ + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20f0088bfb7441f7a37fa0c9e20cb1e9cba1cac6b9ce8cd2a6dc44294f8e8cbc" + +[[package]] +name = "icu_properties" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ea83d991c56158f7cf898bf86436c1dfe7c07ee82fe88951f2695c9f37a379f" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_locale_core", + "icu_properties_data", + "icu_provider", + "zerotrie", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b98f29af82d02b163fe50161388350e743bb3107cc8e8c2f7314cb505faddfcf" + +[[package]] +name = "icu_provider" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413099315636c588ee8f011190b329b971a09a8fae9d157e01dcae8379468514" +dependencies = [ + "displaydoc", + "icu_locale_core", + "writeable", + "yoke", + "zerofrom", + "zerotrie", + "zerovec", +] + +[[package]] +name = "idna" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de" +dependencies = [ + "idna_adapter", + "smallvec", + "utf8_iter", +] + +[[package]] +name = "idna_adapter" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714" +dependencies = [ + "icu_normalizer", + "icu_properties", +] + +[[package]] +name = "image" +version = "0.25.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104" +dependencies = [ + "bytemuck", + "byteorder-lite", + "moxcms", + "num-traits", + "png", + "tiff", +] + +[[package]] +name = "indexmap" +version = "2.14.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc4e190f5d26ca7051642629da2c52fc03bde85a03197c99408dcd291734c855" +dependencies = [ + "equivalent", + "hashbrown 0.17.1", +] + +[[package]] +name = "inout" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "879f10e63c20629ecabbb64a8010319738c66a5cd0c29b02d63d272b03751d01" +dependencies = [ + "block-padding", + "generic-array", +] + +[[package]] +name = "itoa" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" + +[[package]] +name = "jni" +version = "0.22.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5efd9a482cf3a427f00d6b35f14332adc7902ce91efb778580e180ff90fa3498" +dependencies = [ + "cfg-if", + "combine", + "jni-macros", + "jni-sys 0.4.1", + "log", + "simd_cesu8", + "thiserror 2.0.21", + "walkdir", + "windows-link", +] + +[[package]] +name = "jni-macros" +version = "0.22.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a00109accc170f0bdb141fed3e393c565b6f5e072365c3bd58f5b062591560a3" +dependencies = [ + "proc-macro2", + "quote", + "rustc_version", + "simd_cesu8", + "syn 2.0.119", +] + +[[package]] +name = "jni-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" +dependencies = [ + "jni-sys 0.4.1", +] + +[[package]] +name = "jni-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" +dependencies = [ + "jni-sys-macros", +] + +[[package]] +name = "jni-sys-macros" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" +dependencies = [ + "quote", + "syn 2.0.119", +] + +[[package]] +name = "jobserver" +version = "0.1.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c00acbd29eabad4a2392fa0e921c874934dbbf4194312ad20f04a0ed67a3cb3" +dependencies = [ + "getrandom 0.4.3", + "libc", +] + +[[package]] +name = "js-sys" +version = "0.3.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8dc09d2154098bbf4ef54eab6b117a3c24cbbffe94046b16ee6d6d4510584d3a" +dependencies = [ + "cfg-if", + "futures-util", + "wasm-bindgen", +] + +[[package]] +name = "khronos_api" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc" + +[[package]] +name = "libc" +version = "0.2.191" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a" + +[[package]] +name = "libloading" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d7c4b02199fee7c5d21a5ae7d8cfa79a6ef5bb2fc834d6e9058e89c825efdc55" +dependencies = [ + "cfg-if", + "windows-link", +] + +[[package]] +name = "libm" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981" + +[[package]] +name = "libredox" +version = "0.1.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61ff90caf6077a803a240f62fdbe88645a890bbca49ef8174c3cb0404362171d" +dependencies = [ + "bitflags 2.13.2", + "libc", + "plain", + "redox_syscall 0.9.5", +] + +[[package]] +name = "libsqlite3-sys" +version = "0.35.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "133c182a6a2c87864fe97778797e46c7e999672690dc9fa3ee8e241aa4a9c13f" +dependencies = [ + "cc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "linux-raw-sys" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" + +[[package]] +name = "linux-raw-sys" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53" + +[[package]] +name = "litemap" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae" + +[[package]] +name = "litrs" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4744e383959f0db86ede514b809b1c53251889093803c05267acc7d4e7030d70" + +[[package]] +name = "lock_api" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965" +dependencies = [ + "scopeguard", +] + +[[package]] +name = "log" +version = "0.4.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d15f86d12da44cd8d4ec3c73984537eb7f4cadcb9776a575a0a8a05ca11005c" + +[[package]] +name = "lopdf" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25aab26d99567469098e64a02f42679f8965c6401263eefa31d8f2dcc37a221c" +dependencies = [ + "aes", + "bitflags 2.13.2", + "cbc", + "ecb", + "encoding_rs", + "flate2", + "getrandom 0.4.3", + "indexmap", + "itoa", + "log", + "md-5", + "nom", + "rand 0.10.3", + "rangemap", + "sha2", + "stringprep", + "thiserror 2.0.21", + "ttf-parser", + "weezl", +] + +[[package]] +name = "md-5" +version = "0.10.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" +dependencies = [ + "cfg-if", + "digest", +] + +[[package]] +name = "memchr" +version = "2.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" + +[[package]] +name = "memmap2" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b0ca1155a9ecc25aa12e8313a119f32edf0255fea2f44839c4ac0a12b2ac157" +dependencies = [ + "libc", +] + +[[package]] +name = "memoffset" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" +dependencies = [ + "autocfg", +] + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "mime_guess2" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1706dc14a2e140dec0a7a07109d9a3d5890b81e85bd6c60b906b249a77adf0ca" +dependencies = [ + "mime", + "phf", + "phf_shared", + "unicase", +] + +[[package]] +name = "miniz_oxide" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "miniz_oxide" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b63fbc4a50860e98e7b2aa7804ded1db5cbc3aff9193adaff57a6931bf7c4b4c" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "moxcms" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b" +dependencies = [ + "num-traits", + "pxfm", +] + +[[package]] +name = "multiversion_no_op" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "743fb55ba31b18fb1ecef6bdc9aa2743314978ac084044301a7eee33fb99a20d" + +[[package]] +name = "naga" +version = "27.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "066cf25f0e8b11ee0df221219010f213ad429855f57c494f995590c861a9a7d8" +dependencies = [ + "arrayvec", + "bit-set", + "bitflags 2.13.2", + "cfg-if", + "cfg_aliases", + "codespan-reporting", + "half", + "hashbrown 0.16.1", + "hexf-parse", + "indexmap", + "libm", + "log", + "num-traits", + "once_cell", + "rustc-hash 1.1.0", + "thiserror 2.0.21", + "unicode-ident", +] + +[[package]] +name = "native-tls" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "ndk" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" +dependencies = [ + "bitflags 2.13.2", + "jni-sys 0.3.1", + "log", + "ndk-sys", + "num_enum", + "raw-window-handle", + "thiserror 1.0.69", +] + +[[package]] +name = "ndk-context" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" + +[[package]] +name = "ndk-sys" +version = "0.6.0+11769913" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873" +dependencies = [ + "jni-sys 0.3.1", +] + +[[package]] +name = "nix" +version = "0.31.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf20d2fde8ff38632c426f1165ed7436270b44f199fc55284c38276f9db47c3d" +dependencies = [ + "bitflags 2.13.2", + "cfg-if", + "cfg_aliases", + "libc", +] + +[[package]] +name = "nohash-hasher" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451" + +[[package]] +name = "nom" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405" +dependencies = [ + "memchr", +] + +[[package]] +name = "num-bigint" +version = "0.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ce2d95d4b3734dc35aa2f45e1aa22cd416814592a4f9d9205e11affd5b8e10b" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-rational" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824" +dependencies = [ + "num-bigint", + "num-integer", + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", + "libm", +] + +[[package]] +name = "num_enum" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0bca838442ec211fa11de3a8b0e0e8f3a4522575b5c4c06ed722e005036f26" +dependencies = [ + "num_enum_derive", + "rustversion", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "680998035259dcfcafe653688bf2aa6d3e2dc05e98be6ab46afb089dc84f1df8" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "objc-sys" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdb91bdd390c7ce1a8607f35f3ca7151b65afc0ff5ff3b34fa350f7d7c7e4310" + +[[package]] +name = "objc2" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19d5490aaf8f1d7cf7688dfa9b0ce07900e168852c45cd2c03f534dfd27cfd0b" +dependencies = [ + "objc-sys", + "objc2-encode", +] + +[[package]] +name = "objc2" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08849bbd4767dfae9457696856ae1c84fe4e0281bbe4a7abff2d0e06fb7981f8" +dependencies = [ + "objc2-encode", +] + +[[package]] +name = "objc2-app-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4e89ad9e3d7d297152b17d39ed92cd50ca8063a89a9fa569046d41568891eff" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "libc", + "objc2 0.5.3", + "objc2-core-data", + "objc2-core-image", + "objc2-foundation 0.2.2", + "objc2-quartz-core", +] + +[[package]] +name = "objc2-app-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c" +dependencies = [ + "bitflags 2.13.2", + "block2 0.6.2", + "objc2 0.6.5", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation 0.3.2", +] + +[[package]] +name = "objc2-cloud-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74dd3b56391c7a0596a295029734d3c1c5e7e510a4cb30245f8221ccea96b009" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-core-location", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-contacts" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5ff520e9c33812fd374d8deecef01d4a840e7b41862d849513de77e44aa4889" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-core-data" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "617fbf49e071c178c0b24c080767db52958f716d9eabdf0890523aeae54773ef" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-core-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536" +dependencies = [ + "bitflags 2.13.2", + "dispatch2", + "objc2 0.6.5", +] + +[[package]] +name = "objc2-core-graphics" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807" +dependencies = [ + "bitflags 2.13.2", + "dispatch2", + "objc2 0.6.5", + "objc2-core-foundation", + "objc2-io-surface", +] + +[[package]] +name = "objc2-core-image" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55260963a527c99f1819c4f8e3b47fe04f9650694ef348ffd2227e8196d34c80" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", + "objc2-metal", +] + +[[package]] +name = "objc2-core-location" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "000cfee34e683244f284252ee206a27953279d370e309649dc3ee317b37e5781" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.3", + "objc2-contacts", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-encode" +version = "4.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33" + +[[package]] +name = "objc2-foundation" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ee638a5da3799329310ad4cfa62fbf045d5f56e3ef5ba4149e7452dcf89d5a8" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "dispatch", + "libc", + "objc2 0.5.3", +] + +[[package]] +name = "objc2-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272" +dependencies = [ + "bitflags 2.13.2", + "objc2 0.6.5", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-io-surface" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d" +dependencies = [ + "bitflags 2.13.2", + "objc2 0.6.5", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-link-presentation" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1a1ae721c5e35be65f01a03b6d2ac13a54cb4fa70d8a5da293d7b0020261398" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.3", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-metal" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd0cba1276f6023976a406a14ffa85e1fdd19df6b0f737b063b95f6c8c7aadd6" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-quartz-core" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e42bee7bff906b14b167da2bac5efe6b6a07e6f7c0a21a7308d40c960242dc7a" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", + "objc2-metal", +] + +[[package]] +name = "objc2-symbols" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a684efe3dec1b305badae1a28f6555f6ddd3bb2c2267896782858d5a78404dc" +dependencies = [ + "objc2 0.5.3", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-ui-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8bb46798b20cd6b91cbd113524c490f1686f4c4e8f49502431415f3512e2b6f" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-cloud-kit", + "objc2-core-data", + "objc2-core-image", + "objc2-core-location", + "objc2-foundation 0.2.2", + "objc2-link-presentation", + "objc2-quartz-core", + "objc2-symbols", + "objc2-uniform-type-identifiers", + "objc2-user-notifications", +] + +[[package]] +name = "objc2-uniform-type-identifiers" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44fa5f9748dbfe1ca6c0b79ad20725a11eca7c2218bceb4b005cb1be26273bfe" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.3", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-user-notifications" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76cfcbf642358e8689af64cee815d139339f3ed8ad05103ed5eaf73db8d84cb3" +dependencies = [ + "bitflags 2.13.2", + "block2 0.5.1", + "objc2 0.5.3", + "objc2-core-location", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "once_cell" +version = "1.21.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50" + +[[package]] +name = "openssl" +version = "0.10.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4de8111e94a56adca7ebfe6c365b6d42f99deb69b74b6becacd4204e2f193aa2" +dependencies = [ + "bitflags 2.13.2", + "cfg-if", + "foreign-types 0.3.2", + "libc", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "openssl-probe" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e036b411754132fd6b74e94b74e9a13c5cf606fa93d1885c35860d3060820b1" + +[[package]] +name = "openssl-sys" +version = "0.9.118" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19c413d6ec9ebaf5e1c829d355cb3e9f783778d700f135be0921d52fce3c60ae" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "openxer-automation" +version = "0.1.0" +dependencies = [ + "chrono", + "encoding_rs", + "openxer-engine", + "openxer-interchange", + "openxer-xer", + "pdf-extract", + "quick-xml 0.42.0", + "rusqlite", + "rust_xlsxwriter", + "serde", + "serde_json", + "tempfile", + "toml_edit", + "zip", +] + +[[package]] +name = "openxer-chat" +version = "0.1.0" +dependencies = [ + "native-tls", + "openssl", + "openxer-engine", + "openxer-xer", + "serde_json", + "windows-sys 0.61.2", +] + +[[package]] +name = "openxer-desktop" +version = "0.1.0" +dependencies = [ + "chrono", + "eframe", + "egui_extras", + "image", + "miniz_oxide 0.8.9", + "openxer-automation", + "openxer-chat", + "openxer-engine", + "openxer-interchange", + "openxer-xer", + "pdf-writer", + "rfd", + "rusqlite", + "serde", + "serde_json", +] + +[[package]] +name = "openxer-engine" +version = "0.1.0" + +[[package]] +name = "openxer-interchange" +version = "0.1.0" +dependencies = [ + "calamine", + "chrono", + "openxer-engine", + "openxer-xer", + "rust_xlsxwriter", + "serde", + "serde_json", +] + +[[package]] +name = "openxer-xer" +version = "0.1.0" +dependencies = [ + "chrono", + "encoding_rs", + "num-bigint", + "num-rational", + "num-traits", + "openxer-engine", + "serde", + "serde_json", +] + +[[package]] +name = "orbclient" +version = "0.3.55" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5df339f526ea9a60e371768d50efc2f2508c7203290731565d1f7a6f71d21747" +dependencies = [ + "libc", + "libredox", +] + +[[package]] +name = "ordered-stream" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50" +dependencies = [ + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "owned_ttf_parser" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36820e9051aca1014ddc75770aab4d68bc1e9e632f0f5627c4086bc216fb583b" +dependencies = [ + "ttf-parser", +] + +[[package]] +name = "parking" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" + +[[package]] +name = "parking_lot" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall 0.5.18", + "smallvec", + "windows-link", +] + +[[package]] +name = "pdf-extract" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5c4820f5811e424ce037d08493ac87752ecc54339e0f1e40c3d17da93278861" +dependencies = [ + "adobe-cmap-parser", + "cff-parser", + "encoding_rs", + "euclid", + "log", + "lopdf", + "postscript", + "type1-encoding-parser", + "unicode-normalization", +] + +[[package]] +name = "pdf-writer" +version = "0.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5e456864a7a304047bff84977dc6fb162bd956475d40ba50b2dcecaada7f753" +dependencies = [ + "bitflags 2.13.2", + "itoa", + "memchr", + "ryu", +] + +[[package]] +name = "percent-encoding" +version = "2.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" + +[[package]] +name = "phf" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd6780a80ae0c52cc120a26a1a42c1ae51b247a253e4e06113d23d2c2edd078" +dependencies = [ + "phf_macros", + "phf_shared", +] + +[[package]] +name = "phf_generator" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d" +dependencies = [ + "phf_shared", + "rand 0.8.8", +] + +[[package]] +name = "phf_macros" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f84ac04429c13a7ff43785d75ad27569f2951ce0ffd30a3321230db2fc727216" +dependencies = [ + "phf_generator", + "phf_shared", + "proc-macro2", + "quote", + "syn 2.0.119", + "unicase", +] + +[[package]] +name = "phf_shared" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67eabc2ef2a60eb7faa00097bd1ffdb5bd28e62bf39990626a582201b7a754e5" +dependencies = [ + "siphasher", + "unicase", +] + +[[package]] +name = "pin-project" +version = "1.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd" + +[[package]] +name = "piper" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1" +dependencies = [ + "atomic-waker", + "fastrand", + "futures-io", +] + +[[package]] +name = "pkg-config" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6b464fbc74e149a392436b17d523f769e057cb6877f6a5c4618bc6f11800548" + +[[package]] +name = "plain" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" + +[[package]] +name = "png" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" +dependencies = [ + "bitflags 2.13.2", + "crc32fast", + "fdeflate", + "flate2", + "miniz_oxide 0.8.9", +] + +[[package]] +name = "polling" +version = "3.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218" +dependencies = [ + "cfg-if", + "concurrent-queue", + "hermit-abi", + "pin-project-lite", + "rustix 1.1.6", + "windows-sys 0.61.2", +] + +[[package]] +name = "pollster" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f3a9f18d041e6d0e102a0a46750538147e5e8992d3b4873aaafee2520b00ce3" + +[[package]] +name = "pom" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60f6ce597ecdcc9a098e7fddacb1065093a3d66446fa16c675e7e71d1b5c28e6" + +[[package]] +name = "portable-atomic" +version = "1.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05c8b63e8d9609db387f0324918f81d68fe27748f084ef092fb35954d0539a85" + +[[package]] +name = "portable-atomic-util" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10ab3eb7f3becc3a1cbc4f2c6f20267996cfc1a6467a873763411b136a122715" +dependencies = [ + "portable-atomic", +] + +[[package]] +name = "postscript" +version = "0.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78451badbdaebaf17f053fd9152b3ffb33b516104eacb45e7864aaa9c712f306" + +[[package]] +name = "potential_utf" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661" +dependencies = [ + "zerovec", +] + +[[package]] +name = "ppv-lite86" +version = "0.2.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9" +dependencies = [ + "zerocopy", +] + +[[package]] +name = "proc-macro-crate" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" +dependencies = [ + "toml_edit", +] + +[[package]] +name = "proc-macro2" +version = "1.0.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "profiling" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5" + +[[package]] +name = "pxfm" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea" + +[[package]] +name = "quick-error" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" + +[[package]] +name = "quick-xml" +version = "0.41.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e660451e55124f798a69a5af3f49ccfbefbd41910eefd25caf2393e1f3473ec1" +dependencies = [ + "memchr", +] + +[[package]] +name = "quick-xml" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41b1177fdf999d2321d3fb46ff47159d9c1fb9ad66a4879f8c50a0b504615e9b" +dependencies = [ + "encoding_rs", + "memchr", +] + +[[package]] +name = "quote" +version = "1.0.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "r-efi" +version = "5.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" + +[[package]] +name = "r-efi" +version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" + +[[package]] +name = "rand" +version = "0.8.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e058c7de0b26af77780c769414d6257830bb240f3c38477dbc2c16e5f54d6d4c" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "rand" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b9ef1d0d795eb7d84685bca4f72f3649f064e6641543d3a8c415898726a57b41" +dependencies = [ + "rand_chacha", + "rand_core 0.9.5", +] + +[[package]] +name = "rand" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "65c9fb96cbc91e3478eaae79a69fcd3f1ae4ad052e471fe6732fff548984b4af" +dependencies = [ + "chacha20", + "getrandom 0.4.3", + "rand_core 0.10.1", +] + +[[package]] +name = "rand_chacha" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb" +dependencies = [ + "ppv-lite86", + "rand_core 0.9.5", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" + +[[package]] +name = "rand_core" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76afc826de14238e6e8c374ddcc1fa19e374fd8dd986b0d2af0d02377261d83c" +dependencies = [ + "getrandom 0.3.4", +] + +[[package]] +name = "rand_core" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69" + +[[package]] +name = "rangemap" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a611d15b50743feb4c76b7d03edcb0e64f399c26961e4efe6975bc398be6aa3d" + +[[package]] +name = "raw-window-handle" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" + +[[package]] +name = "redox_syscall" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.5.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" +dependencies = [ + "bitflags 2.13.2", +] + +[[package]] +name = "redox_syscall" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "580c875845b41ecb1564ad1ae4703044cef774145e3d7a94dc2b3fa7c97868fd" +dependencies = [ + "bitflags 2.13.2", +] + +[[package]] +name = "renderdoc-sys" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19b30a45b0cd0bcca8037f3d0dc3421eaf95327a17cad11964fb8179b4fc4832" + +[[package]] +name = "rfd" +version = "0.15.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef2bee61e6cffa4635c72d7d81a84294e28f0930db0ddcb0f66d10244674ebed" +dependencies = [ + "ashpd", + "block2 0.6.2", + "dispatch2", + "js-sys", + "log", + "objc2 0.6.5", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "pollster", + "raw-window-handle", + "urlencoding", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "windows-sys 0.59.0", +] + +[[package]] +name = "rusqlite" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "165ca6e57b20e1351573e3729b958bc62f0e48025386970b6e4d29e7a7e71f3f" +dependencies = [ + "bitflags 2.13.2", + "fallible-iterator", + "fallible-streaming-iterator", + "hashlink", + "libsqlite3-sys", + "smallvec", +] + +[[package]] +name = "rust_xlsxwriter" +version = "0.102.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ca3d0e879a578c1313c2800ab0c6c029d38eed18098675e50341a30d32372ed" +dependencies = [ + "zip", +] + +[[package]] +name = "rustc-hash" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" + +[[package]] +name = "rustc-hash" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d" + +[[package]] +name = "rustc_version" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" +dependencies = [ + "bitflags 2.13.2", + "errno", + "libc", + "linux-raw-sys 0.4.15", + "windows-sys 0.59.0", +] + +[[package]] +name = "rustix" +version = "1.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5e76742e5294153d4dde1207dbec5bdd81eef6fabdc0d2118babadabfd858aa" +dependencies = [ + "bitflags 2.13.2", + "errno", + "libc", + "linux-raw-sys 0.12.1", + "windows-sys 0.61.2", +] + +[[package]] +name = "rustversion" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" + +[[package]] +name = "ryu" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cb23c424d8ee841bb4d813677ca237e2a610067d594fec130f87d6093495ab5" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "scoped-tls" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d" +dependencies = [ + "bitflags 2.13.2", + "core-foundation 0.10.1", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" + +[[package]] +name = "serde" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba" +dependencies = [ + "serde_core", + "serde_derive", +] + +[[package]] +name = "serde_core" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "serde_json" +version = "1.0.154" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7e9cc8b1b85264074fbcc02a88680c4096b1e47df8f739dceb03bf482f04bd6" +dependencies = [ + "itoa", + "memchr", + "serde", + "serde_core", + "zmij", +] + +[[package]] +name = "serde_repr" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "sha2" +version = "0.10.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" +dependencies = [ + "cfg-if", + "cpufeatures 0.2.17", + "digest", +] + +[[package]] +name = "shlex" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" + +[[package]] +name = "signal-hook-registry" +version = "1.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b" +dependencies = [ + "errno", + "libc", +] + +[[package]] +name = "simd-adler32" +version = "0.3.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea" + +[[package]] +name = "simd_cesu8" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11031e251abf8611c80f460e19dbdeb54a66db918e49c65a7065b46ac7aec520" +dependencies = [ + "rustc_version", + "simdutf8", +] + +[[package]] +name = "simdutf8" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e" + +[[package]] +name = "siphasher" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33f4fe9184a62d842c9ef383018f3306d8ba224fd9d836f56d7288308847c256" + +[[package]] +name = "slab" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" + +[[package]] +name = "slotmap" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bdd58c3c93c3d278ca835519292445cb4b0d4dc59ccfdf7ceadaab3f8aeb4038" +dependencies = [ + "version_check", +] + +[[package]] +name = "smallvec" +version = "1.16.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d0d5d4b1981b8bbbb7aed204cae5726d683d5d6ac7e74ec54122ea28f315e7c8" + +[[package]] +name = "smithay-client-toolkit" +version = "0.19.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3457dea1f0eb631b4034d61d4d8c32074caa6cd1ab2d59f2327bd8461e2c0016" +dependencies = [ + "bitflags 2.13.2", + "calloop 0.13.0", + "calloop-wayland-source 0.3.0", + "cursor-icon", + "libc", + "log", + "memmap2", + "rustix 0.38.44", + "thiserror 1.0.69", + "wayland-backend", + "wayland-client", + "wayland-csd-frame", + "wayland-cursor", + "wayland-protocols", + "wayland-protocols-wlr", + "wayland-scanner", + "xkeysym", +] + +[[package]] +name = "smithay-client-toolkit" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0512da38f5e2b31201a93524adb8d3136276fa4fe4aafab4e1f727a82b534cc0" +dependencies = [ + "bitflags 2.13.2", + "calloop 0.14.5", + "calloop-wayland-source 0.4.1", + "cursor-icon", + "libc", + "log", + "memmap2", + "rustix 1.1.6", + "thiserror 2.0.21", + "wayland-backend", + "wayland-client", + "wayland-csd-frame", + "wayland-cursor", + "wayland-protocols", + "wayland-protocols-experimental", + "wayland-protocols-misc", + "wayland-protocols-wlr", + "wayland-scanner", + "xkeysym", +] + +[[package]] +name = "smithay-clipboard" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71704c03f739f7745053bde45fa203a46c58d25bc5c4efba1d9a60e9dba81226" +dependencies = [ + "libc", + "smithay-client-toolkit 0.20.0", + "wayland-backend", +] + +[[package]] +name = "smol_str" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd538fb6910ac1099850255cf94a94df6551fbdd602454387d0adb2d1ca6dead" +dependencies = [ + "serde", +] + +[[package]] +name = "stable_deref_trait" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" + +[[package]] +name = "static_assertions" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" + +[[package]] +name = "stringprep" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b4df3d392d81bd458a8a621b8bffbd2302a12ffe288a9d931670948749463b1" +dependencies = [ + "unicode-bidi", + "unicode-normalization", + "unicode-properties", +] + +[[package]] +name = "syn" +version = "2.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "3.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d78c8dee4c7bf0e14673097256fed6142ce9d3b85a408189d07482442145823b" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "synstructure" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "901704edd0dfe137f1987838ee4f259e4e063c31371bdb423f7ae38ec6f77f02" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "tempfile" +version = "3.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" +dependencies = [ + "fastrand", + "getrandom 0.4.3", + "once_cell", + "rustix 1.1.6", + "windows-sys 0.61.2", +] + +[[package]] +name = "thiserror" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" +dependencies = [ + "thiserror-impl 1.0.69", +] + +[[package]] +name = "thiserror" +version = "2.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09e52cb86a36cede5cb101bf8908837b3e4c6e5e59fe7fd85c23fb56200d189e" +dependencies = [ + "thiserror-impl 2.0.21", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe5197923287db20a58125f0bc85c062f7f2c892de97b18c356f9efb14b28524" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "tiff" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b63feaf3343d35b6ca4d50483f94843803b0f51634937cc2ec519fc32232bc52" +dependencies = [ + "fax", + "flate2", + "half", + "quick-error", + "weezl", + "zune-jpeg", +] + +[[package]] +name = "tinystr" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "abc840c238154d58f9e86b2792261edfde565a17696e1cda1a449de27979801a" +dependencies = [ + "displaydoc", + "zerovec", +] + +[[package]] +name = "tinyvec" +version = "1.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee" + +[[package]] +name = "tokio" +version = "1.54.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b52fd3255258d26fac7264ab5a76b53c13367136dc011d3d6ad4f8ed070396a3" +dependencies = [ + "pin-project-lite", +] + +[[package]] +name = "toml_datetime" +version = "1.1.2+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b86d767906c6c42421dcba507eb9d203e779497710a47782a224bb871653053" +dependencies = [ + "serde_core", +] + +[[package]] +name = "toml_edit" +version = "0.25.18+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ec6e78bd70db9420d8d212fa9dc97f116448a1ceff5d00eabb991d407e21396" +dependencies = [ + "indexmap", + "toml_datetime", + "toml_parser", + "toml_writer", + "winnow", +] + +[[package]] +name = "toml_parser" +version = "1.1.5+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baa693a8032d7e1cada7d0041e96126df243179ff061456783ac7f12bda4744c" +dependencies = [ + "winnow", +] + +[[package]] +name = "toml_writer" +version = "1.2.0+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "009dbb7700f11c55ef83aebbe4c0e9cf1f1ac0844bd8d6f00dc38f302026e13a" + +[[package]] +name = "tracing" +version = "0.1.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100" +dependencies = [ + "log", + "pin-project-lite", + "tracing-attributes", + "tracing-core", +] + +[[package]] +name = "tracing-attributes" +version = "0.1.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "tracing-core" +version = "0.1.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a" +dependencies = [ + "once_cell", +] + +[[package]] +name = "ttf-parser" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2df906b07856748fa3f6e0ad0cbaa047052d4a7dd609e231c4f72cee8c36f31" + +[[package]] +name = "type-map" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb30dbbd9036155e74adad6812e9898d03ec374946234fbcebd5dfc7b9187b90" +dependencies = [ + "rustc-hash 2.1.3", +] + +[[package]] +name = "type1-encoding-parser" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa10c302f5a53b7ad27fd42a3996e23d096ba39b5b8dd6d9e683a05b01bee749" +dependencies = [ + "pom", +] + +[[package]] +name = "typed-path" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ce898823d8cd0f028662d2f349694b1af0a5cc9be83f1d213a00d3147445e1e" + +[[package]] +name = "typenum" +version = "1.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" + +[[package]] +name = "uds_windows" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e" +dependencies = [ + "memoffset", + "tempfile", + "windows-sys 0.61.2", +] + +[[package]] +name = "unicase" +version = "2.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "357cc3acc6a036009fd6c973ed009037c732d60d0b4f6c673e9041497482a28f" + +[[package]] +name = "unicode-bidi" +version = "0.3.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c1cb5db39152898a79168971543b1cb5020dff7fe43c8dc468b0885f5e29df5" + +[[package]] +name = "unicode-ident" +version = "1.0.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2c754d6c33795a1c324727428e5a7dedb5b06195f9890bdbcba760d3e246563" + +[[package]] +name = "unicode-normalization" +version = "0.1.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75cd3fb03d5288b3ba9a1ee103ac7e9cbb59f0b03d64f8ddfcc04dd42758a85d" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-properties" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "993ad287eb20e8ba755312801cfe1413e0f25d604075863acaddca10b04c1833" + +[[package]] +name = "unicode-segmentation" +version = "1.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8" + +[[package]] +name = "unicode-width" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca718471876992059f251e33aafc334346ada08042b7661dd1fe313a9bced557" + +[[package]] +name = "url" +version = "2.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", + "serde", + "serde_derive", +] + +[[package]] +name = "urlencoding" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" + +[[package]] +name = "utf8_iter" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af3bd9d3e571c26fcce9d033b87ea5ab061b8d2ffe9b7a5675d810d68f03edf0" +dependencies = [ + "utf_types", +] + +[[package]] +name = "utf_types" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a3b425286980a367278453f3b6d28cdcb134b574e5a35824a6ff5eebad50bb6" + +[[package]] +name = "uuid" +version = "1.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a0e2d11620c50695fe12bbbfde96b3477fe606e7284c22d505c12ce51214514" +dependencies = [ + "js-sys", + "serde_core", + "wasm-bindgen", +] + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "wasip2" +version = "1.0.4+wasi-0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" +dependencies = [ + "wit-bindgen", +] + +[[package]] +name = "wasm-bindgen" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0181c14ddd6c7b8b0b0132a5f1ea2f32be0d893cd3ea97b6e3b28886b8a3d1c" +dependencies = [ + "cfg-if", + "rustversion", + "wasm-bindgen-macro", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.80" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e14e0327cb5368ad60ccb22d04a9827a693c95a926d8d125e9fa39e0baec501" +dependencies = [ + "js-sys", + "tokio", + "wasm-bindgen", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e931a02a39abdbf66966fc35902b5ed58344750a70885bed4ebb3d8eaf28ed9" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ca4b54280e455bd831e33a6b8e734baf432fe63fbc35c42ac14ce67a043a53a" +dependencies = [ + "bumpalo", + "proc-macro2", + "quote", + "syn 3.0.9", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b1f9c3798725016c6ee5f2f57869ec0831e8bbc0ab0310a86e787e97f41389e" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "wayland-backend" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38a91b4eaddff87b1cd1074985e3713da4af2c49742d1b356b2c01670a67a078" +dependencies = [ + "cc", + "downcast-rs", + "rustix 1.1.6", + "scoped-tls", + "smallvec", + "wayland-sys", +] + +[[package]] +name = "wayland-client" +version = "0.31.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3c36a0f861ad76d0901f2800b46321410d9f73f2ea88aac0650d86c32688073" +dependencies = [ + "bitflags 2.13.2", + "rustix 1.1.6", + "wayland-backend", + "wayland-scanner", +] + +[[package]] +name = "wayland-csd-frame" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "625c5029dbd43d25e6aa9615e88b829a5cad13b2819c4ae129fdbb7c31ab4c7e" +dependencies = [ + "bitflags 2.13.2", + "cursor-icon", + "wayland-backend", +] + +[[package]] +name = "wayland-cursor" +version = "0.31.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a52d18780be9b1314328a3de5f930b73d2200112e3849ca6cb11822793fb34d" +dependencies = [ + "rustix 1.1.6", + "wayland-client", + "xcursor", +] + +[[package]] +name = "wayland-protocols" +version = "0.32.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d0c813de3daa2ed6520af85a3bd49b0e722a3078506899aa9686fea58dc4b6" +dependencies = [ + "bitflags 2.13.2", + "wayland-backend", + "wayland-client", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-experimental" +version = "20250721.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40a1f863128dcaaec790d7b4b396cc9b9a7a079e878e18c47e6c2d2c5a8dcbb1" +dependencies = [ + "bitflags 2.13.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-misc" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e9567599ef23e09b8dad6e429e5738d4509dfc46b3b21f32841a304d16b29c8" +dependencies = [ + "bitflags 2.13.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-plasma" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b6d8cf1eb2c1c31ed1f5643c88a6e53538129d4af80030c8cabd1f9fa884d91" +dependencies = [ + "bitflags 2.13.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-wlr" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb04e52f7836d7c7976c78ca0250d61e33873c34156a2a1fc9474828ec268234" +dependencies = [ + "bitflags 2.13.2", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-scanner" +version = "0.31.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "338e30461b3a2b67d70eb30a6d89f8e0c93a833e07d2ae89085cd070c4a00ac0" +dependencies = [ + "proc-macro2", + "quick-xml 0.41.0", + "quote", +] + +[[package]] +name = "wayland-sys" +version = "0.31.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8eab23fefc9e41f8e841df4a9c707e8a8c4ed26e944ef69297184de2785e3be" +dependencies = [ + "dlib", + "log", + "once_cell", + "pkg-config", +] + +[[package]] +name = "web-sys" +version = "0.3.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d7d179596ff5ec0f6de4db64d54011bde6289cc49603d3a6e4ce3f329207ab88" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web-time" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "webbrowser" +version = "1.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe8d20d0214027baf11b8b0cc307c1da7657d8f4db9aa956f7de27a6fb1acbd5" +dependencies = [ + "jni", + "log", + "ndk-context", + "objc2 0.6.5", + "objc2-app-kit 0.3.2", + "objc2-foundation 0.3.2", + "url", + "web-sys", +] + +[[package]] +name = "weezl" +version = "0.1.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88" + +[[package]] +name = "wgpu" +version = "27.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfe68bac7cde125de7a731c3400723cadaaf1703795ad3f4805f187459cd7a77" +dependencies = [ + "arrayvec", + "bitflags 2.13.2", + "cfg-if", + "cfg_aliases", + "document-features", + "hashbrown 0.16.1", + "log", + "portable-atomic", + "profiling", + "raw-window-handle", + "smallvec", + "static_assertions", + "wgpu-core", + "wgpu-hal", + "wgpu-types", +] + +[[package]] +name = "wgpu-core" +version = "27.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27a75de515543b1897b26119f93731b385a19aea165a1ec5f0e3acecc229cae7" +dependencies = [ + "arrayvec", + "bit-set", + "bit-vec", + "bitflags 2.13.2", + "bytemuck", + "cfg_aliases", + "document-features", + "hashbrown 0.16.1", + "indexmap", + "log", + "naga", + "once_cell", + "parking_lot", + "portable-atomic", + "profiling", + "raw-window-handle", + "rustc-hash 1.1.0", + "smallvec", + "thiserror 2.0.21", + "wgpu-core-deps-windows-linux-android", + "wgpu-hal", + "wgpu-types", +] + +[[package]] +name = "wgpu-core-deps-windows-linux-android" +version = "27.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71197027d61a71748e4120f05a9242b2ad142e3c01f8c1b47707945a879a03c3" +dependencies = [ + "wgpu-hal", +] + +[[package]] +name = "wgpu-hal" +version = "27.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b21cb61c57ee198bc4aff71aeadff4cbb80b927beb912506af9c780d64313ce" +dependencies = [ + "bitflags 2.13.2", + "cfg-if", + "cfg_aliases", + "libloading", + "log", + "naga", + "portable-atomic", + "portable-atomic-util", + "raw-window-handle", + "renderdoc-sys", + "thiserror 2.0.21", + "wgpu-types", +] + +[[package]] +name = "wgpu-types" +version = "27.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afdcf84c395990db737f2dd91628706cb31e86d72e53482320d368e52b5da5eb" +dependencies = [ + "bitflags 2.13.2", + "bytemuck", + "js-sys", + "log", + "thiserror 2.0.21", + "web-sys", +] + +[[package]] +name = "winapi-util" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "windows-core" +version = "0.62.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" +dependencies = [ + "windows-implement", + "windows-interface", + "windows-link", + "windows-result", + "windows-strings", +] + +[[package]] +name = "windows-implement" +version = "0.60.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "windows-interface" +version = "0.59.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "windows-link" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" + +[[package]] +name = "windows-result" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-strings" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets", +] + +[[package]] +name = "windows-sys" +version = "0.61.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-targets" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" +dependencies = [ + "windows_aarch64_gnullvm", + "windows_aarch64_msvc", + "windows_i686_gnu", + "windows_i686_gnullvm", + "windows_i686_msvc", + "windows_x86_64_gnu", + "windows_x86_64_gnullvm", + "windows_x86_64_msvc", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" + +[[package]] +name = "winit" +version = "0.30.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a6755fa58a9f8350bd1e472d4c3fcc25f824ec358933bba33306d0b63df5978d" +dependencies = [ + "ahash", + "android-activity", + "atomic-waker", + "bitflags 2.13.2", + "block2 0.5.1", + "bytemuck", + "calloop 0.13.0", + "cfg_aliases", + "concurrent-queue", + "core-foundation 0.9.4", + "core-graphics", + "cursor-icon", + "dpi", + "js-sys", + "libc", + "memmap2", + "ndk", + "objc2 0.5.3", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", + "objc2-ui-kit", + "orbclient", + "percent-encoding", + "pin-project", + "raw-window-handle", + "redox_syscall 0.4.1", + "rustix 0.38.44", + "smithay-client-toolkit 0.19.2", + "smol_str", + "tracing", + "unicode-segmentation", + "wasm-bindgen", + "wasm-bindgen-futures", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-protocols-plasma", + "web-sys", + "web-time", + "windows-sys 0.52.0", + "x11-dl", + "x11rb", + "xkbcommon-dl", +] + +[[package]] +name = "winnow" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81" +dependencies = [ + "memchr", +] + +[[package]] +name = "wit-bindgen" +version = "0.57.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" + +[[package]] +name = "writeable" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc" + +[[package]] +name = "x11-dl" +version = "2.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f" +dependencies = [ + "libc", + "once_cell", + "pkg-config", +] + +[[package]] +name = "x11rb" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9993aa5be5a26815fe2c3eacfc1fde061fc1a1f094bf1ad2a18bf9c495dd7414" +dependencies = [ + "as-raw-xcb-connection", + "gethostname", + "libc", + "libloading", + "once_cell", + "rustix 1.1.6", + "x11rb-protocol", +] + +[[package]] +name = "x11rb-protocol" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea6fc2961e4ef194dcbfe56bb845534d0dc8098940c7e5c012a258bfec6701bd" + +[[package]] +name = "xcursor" +version = "0.3.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "163b33ed8786455e2fa5d72f554057ce3f3182425434f756cd39c99839d88e23" + +[[package]] +name = "xkbcommon-dl" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d039de8032a9a8856a6be89cea3e5d12fdd82306ab7c94d74e6deab2460651c5" +dependencies = [ + "bitflags 2.13.2", + "dlib", + "log", + "once_cell", + "xkeysym", +] + +[[package]] +name = "xkeysym" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b9cc00251562a284751c9973bace760d86c0276c471b4be569fe6b068ee97a56" + +[[package]] +name = "xml-rs" +version = "0.8.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e450f9b2ed1dff33c94c12589a87338689467b9c4f5d8a5710bd09a847d2c8a7" + +[[package]] +name = "yoke" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "417ef3fcf6c300b7dbd25c85531a746931c02ad536f3cf4786ed1e88223340b3" +dependencies = [ + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec8ebde2db3681e8c9980cc27822030e68752690ddfa9473e739aeb4dbde6d71" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", + "synstructure", +] + +[[package]] +name = "zbus" +version = "5.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5db4be7c075cb421e4b7ee645541604239bd243ba7c357511f4ff3a74b555907" +dependencies = [ + "async-broadcast", + "async-executor", + "async-io", + "async-lock", + "async-process", + "async-recursion", + "async-task", + "async-trait", + "blocking", + "enumflags2", + "event-listener", + "futures-core", + "futures-lite", + "hex", + "libc", + "ordered-stream", + "rustix 1.1.6", + "serde", + "serde_repr", + "tracing", + "uds_windows", + "uuid", + "windows-sys 0.61.2", + "winnow", + "zbus_macros", + "zbus_names", + "zvariant", +] + +[[package]] +name = "zbus_macros" +version = "5.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2990635d09ade6df1868f72f8cac69a876a90981e8bd3c40b1be413f8dc88f40" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 3.0.9", + "zbus_names", + "zvariant", + "zvariant_utils", +] + +[[package]] +name = "zbus_names" +version = "4.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "812a12be4ead7a59e18ea8f047d08add0066b73bc62fc1467066a2472ae088dd" +dependencies = [ + "serde", + "winnow", + "zvariant", +] + +[[package]] +name = "zcheapstr" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "939f186d9ecebe044315a5cb6d6f78568bbc21152adc954d5a0c2f58bdbc9920" +dependencies = [ + "serde", +] + +[[package]] +name = "zerocopy" +version = "0.8.63" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5fe1f8f1b06191a00962174c61aa5005e0bb391a6d80d07e24d115c01a92ed8" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.8.63" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "863ad3ac83293fb4d740aedbfdc9240dd8d1a50c1099acd76ce80ce7c7230c7f" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "zerofrom" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f75b4683f6c7f45248d4d64056a24298c6281e0993356d7d1b4a1a962ef10d4a" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", + "synstructure", +] + +[[package]] +name = "zerotrie" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", +] + +[[package]] +name = "zerovec" +version = "0.11.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f58a2799cfe9a1670c7ea8edbd52ef8edb93cb37a7f83bf31ba9e35d9dae6a40" +dependencies = [ + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.11.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3743ddbf47738d929cd1ae2e199d40d0162979dfe31aef8ae646d2bf00bf97a" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.9", +] + +[[package]] +name = "zip" +version = "9.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaeb7f16d2605b49aef586996ded29e65642fab7259a3077e537351df6d80426" +dependencies = [ + "crc32fast", + "flate2", + "getrandom 0.4.3", + "indexmap", + "libc", + "memchr", + "nix", + "typed-path", + "windows-sys 0.61.2", + "zopfli", +] + +[[package]] +name = "zlib-rs" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b268e58e7c693d7c271f93ffc4ba3b380412554231c85bf61ca7af91042a4112" + +[[package]] +name = "zmij" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b" + +[[package]] +name = "zopfli" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aaf7fc5d30c28483d93805c4a5e12b05bbb52407fa67c5f8bd552374cd01fb11" +dependencies = [ + "bumpalo", + "crc32fast", + "log", + "simd-adler32", +] + +[[package]] +name = "zune-core" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d56377fd46368984a170bc5aac5567e52ca5da874caa60bea39fcbca78fb658b" + +[[package]] +name = "zune-jpeg" +version = "0.5.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296" +dependencies = [ + "zune-core", +] + +[[package]] +name = "zvariant" +version = "5.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80bf6d6cd6a4b601acb64cfb8284cdc643fcfa75ef26ae3c46ec8aa4e8a1fbb7" +dependencies = [ + "endi", + "enumflags2", + "serde", + "url", + "winnow", + "zcheapstr", + "zvariant_derive", + "zvariant_utils", +] + +[[package]] +name = "zvariant_derive" +version = "5.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef2672456ba1cb54b5eaec136e63135b3c7495fb938e53b28a62e633496d486d" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 3.0.9", + "zvariant_utils", +] + +[[package]] +name = "zvariant_utils" +version = "4.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bad0294361a320b694a328460dc73add56c306150f5cb6bfafc44446120008a3" +dependencies = [ + "proc-macro2", + "quote", + "serde", + "syn 3.0.9", + "winnow", +] diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..8aad16e --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,26 @@ +[workspace] +members = ["engine", "xer", "interchange", "desktop", "automation", "chat"] +default-members = ["desktop"] +resolver = "2" + +[workspace.package] +version = "0.1.0" +edition = "2021" +license = "MIT OR Apache-2.0" +publish = false +description = "A fast, native desktop CPM scheduler for XER files, built to be driven by AI agents." +repository = "https://github.com/openxer/openxer" +homepage = "https://github.com/openxer/openxer" +readme = "README.md" +keywords = ["scheduling", "cpm", "xer", "gantt", "mcp"] +categories = ["gui", "command-line-utilities"] + +# Optimize dev/test builds enough that headless software-rendered UI tests run +# fast while keeping debug assertions, line numbers and low linker disk usage. +[profile.dev] +opt-level = 1 +debug = "line-tables-only" + +[profile.dev.package."*"] +opt-level = 2 +debug = 0 diff --git a/DESIGN.md b/DESIGN.md new file mode 100644 index 0000000..b8e31cc --- /dev/null +++ b/DESIGN.md @@ -0,0 +1,127 @@ +# DESIGN.md + +How OpenXER's screens are built. Read this before any UI work. The code is the +source of truth: where this file and the code disagree, fix this file in the +same change. + +## The one rule + +A control that already exists is reused. If the shared one lacks something, +extend it so every caller gains it. Never paint a control yourself and never +write a second copy. Every visual drift found so far came from a second copy. + +Where two screens differ and nothing below settles it, the Activities page is +the reference look. + +## Find the control first + +| You need | Call | Lives in | +|---|---|---| +| Dialog window | `kit::shell`, or the ready-made `kit::window`, `kit::modal`, `kit::modal_at`; flow layout: `chrome::dialog_window`, `chrome::plain_window` | `desktop/src/dialog_kit.rs`, `chrome.rs` | +| Window that rolls up to its title bar, resizes from its corner grip, or stays open beside the work (a tool window: it holds the keyboard only while active); its place kept between sessions | `kit::shell_with` with `kit::Extras { roll_up, min_client, tool }`; `kit::geometry`, `kit::set_geometry`; the grip: `kit::paint_size_grip` | `dialog_kit.rs` | +| Push button | `kit::button`, `kit::default_button` | `dialog_kit.rs` | +| Button column or row | `kit::button_column` with `kit::strip`, `kit::button_row`, entries from `Entry::ok/cancel/close/apply/help`; a default other than OK: `kit::mark_default`; a column in a declared observed order: `kit::observed_button_column`, a row: `kit::observed_button_row` | `dialog_kit.rs` | +| Text link (a web page, a setting) | `kit::link` | `dialog_kit.rs` | +| App setup row (name, state mark, detail, its action) | `ai_agents::row::paint` | `desktop/src/ai_agents/row.rs` | +| Message or confirm box | `kit::message_box`, `kit::message_box_with_lines` | `dialog_kit.rs` | +| Check box, radio | `Canvas::checkbox`, `kit::check_right`, `kit::radio`, `Canvas::radio` | `dialog_kit.rs` | +| Edit, read-only field | `Canvas::edit` (`Canvas::edit_masked` for a key, never drawn), `kit::commit_edit`, `kit::field`; several lines: `kit::text_area`, with a hint, a disabled state, scrolling or Enter left to the caller: `kit::text_area_with` | `dialog_kit.rs` | +| Combo, spin | `Canvas::combo`, `Canvas::spin`; drawn items: `kit::drawn_combo`; a number value: `kit::number_spin` | `dialog_kit.rs` | +| Color picker | `kit::swatch` (flow layout: `kit::color_button`) | `dialog_kit.rs` | +| Date field with calendar (the `...` inside the edit frame) | `views::sheet::date_field` (commits on Enter); over a dialog's draft text: `views::sheet::date_text_field` | `views/sheet.rs` | +| Section box, heading | `kit::section`, `kit::heading` | `dialog_kit.rs` | +| Wizard page (panel and title) and its bottom row (Cancel alone at the left, Prev / Next / Finish at the right) | `kit::wizard_page`, `kit::wizard_buttons`; a title alone: `kit::wizard_title` | `dialog_kit.rs` | +| List with scroll bar | `kit::list`, `kit::rows_in`, `kit::cell_text` | `dialog_kit.rs` | +| Tree list with icons, check cells and in-place editing | `enterprise::ui::grid` (built on `kit::list`) | `enterprise/ui.rs` | +| Kit controls inside a flow window | `kit::flow_canvas` (a Canvas over a block of the flow body) | `dialog_kit.rs` | +| Tabs inside a dialog | `kit::tabs` (horizontal, painted by `tab_strip::show`); tabs that share the panel's width with centred captions: `kit::tabs_spread`; `kit::vertical_tabs`, `kit::vertical_tabs_with_icons`, `kit::page` | `dialog_kit.rs` | +| Move arrows | four-arrow pad: `kit::move_pad`; a two-list picker's 33 x 33 arrow buttons (single or double): `kit::move_button` | `dialog_kit.rs` | +| Detail tabs under a view | `tab_strip::show` | `desktop/src/tab_strip.rs` | +| Table in a view or pane | `grid::Table` (`show`, or `show_with` and `Extras` for line numbers, a sort arrow, a kept scroll offset) | `views/grid.rs` | +| Grouping band look (level fill and text, caption font, totals in the row font) | `grid::band` (`fill`, `ink`, `caption`, `total_font`, `level_style`); view tables pick it by level through `views::grid::band_style` | `grid/band.rs` | +| The activity table and Gantt | the `grid/` and `gantt/` modules; do not build another | `grid/`, `gantt/` | +| Splitter | `activities::paint_splitter` | `activities.rs` | +| Histogram with cumulative curves and its legend (usage profiles, S-Curve report) | `histogram::paint_plot`, `histogram::paint_legend`; the timescale under it `usage::paint_tier` | `panes/histogram.rs` | +| Assign dialog (Assign Resources, Roles, Predecessors, Successors, Activity Codes, ...): window, button column, list with Ctrl and Shift multi-select | `assign_window`, `assign_list`, `assign_picked` | `details/assign_kit.rs` | +| Cell commands of a view table (focus cell, Fill Down, Find and Replace) | `note_view_cells`, `set_view_cell` | `views/table_cells.rs` | +| Controls inside a details pane | `details::form` (`command_button`, `combo`, `section`, `text`) | `details/form.rs` | +| Notebook tab (topic list, Add, Delete, notes pane) of Activity, WBS and Project Details; a captioned notes pane with its formatted text, Modify and the formatting toolbar | `notebook_pane`, `memo_section` | `details/notes_pane.rs` | +| Add button of a tab; Modify / Print / Copy under a notes pane; a number box (right-aligned) | `details::form::add_button`; `form::notes_buttons` (Canvas: `views::sheet::notes_buttons`); `views::sheet::number_field`, read-only `kit::number_field` | `details/form.rs`, `views/sheet.rs`, `dialog_kit.rs` | +| Icon | `chrome::Icon` with `chrome::paint_icon`; new icons are drawn by `tools/icons/` | `chrome.rs` | +| Picture as the mouse pointer | `chrome::paint_pointer_icon` | `chrome.rs` | +| Right-click or drop-down menu | `context_menu::Menu` with `chrome::popup_menu_style` | `context_menu.rs` | +| Colors | `chrome::pal`; chosen defaults in `theme.rs` | `chrome.rs`, `theme.rs` | +| Text in the light Markdown subset (help topics, agent replies): paragraphs, headings, lists, notes, tables, bold, italic, code, links; text still arriving | `markdown::blocks` with a `Dialect`, laid out by `markdown::layout`, links by `markdown::link_at` and `markdown::link_rects`; tables (columns fitted to the width, text wrapped in its cell) by `markdown::table_ui` | `desktop/src/markdown.rs` | +| Conversation (message list): user messages, agent replies with Activity ID links, tool rows, proposed changes, status lines, the empty state | `chat::list::show` over a `chat::model::Conversation`; IDs as links: `chat::links::link_ids` | `desktop/src/chat/` | + +The comment at the top of `dialog_kit.rs` is the detailed rulebook for dialogs. + +## Standard measurements + +- Dialog button: 108 x 25. Button strip at the right: 112 wide, first button + 6 down, 30 from one button to the next, 10 extra before a new group. +- Button order in a column: the committing button (OK, or the dialog's own + verb such as Schedule), Cancel, Apply, the dialog's other commands, Help + last. In a bottom row Help comes first, at the left, then the same order + (`kit::button_row` places it; callers list Help last as for a column). A + dialog that changes nothing has Close, not OK and Cancel. A dialog whose + own reference shot shows a different column or bottom row order may + declare that observed order (`kit::observed_button_column`, + `kit::observed_button_row`, entries listed in the order drawn); the sweep + then accepts exactly that order on that dialog. Today: the Calendar editor + (OK, Cancel, Help, then Work and the rest), Schedule (Cancel, Schedule, + View Log, Help, Options...) and the Calendars in Use row (Help, Cancel, + OK). +- One text size in dialogs and panes: `kit::body_font` (Arial 8 pt). Section + and heading bar captions are bold (`kit::heading_font`, and + `details::form::section` in the details panes). +- Dialog face `#F0F0F0`. Read-only fields `#F8F8F8`. Disabled text `#6D6D6D`, + plain. +- Table rows are 18 high. Row lines and the selection end at the last column. +- Buttons highlight on hover. The button Enter would press shows the default + frame. + +## Behaviour every screen keeps + +- Escape closes a dialog. Cancel or Close leaves the project unchanged. +- Enter presses the default button, and a value typed in an edit is + committed first (Escape drops it). A confirmation names its default + button (what Enter presses, framed as the default) in one table, + `kit_window::Question`. The default button follows the observed + reference behaviour, even when that is Yes on a destructive action; + where not observed, No. +- A command that changes project data is one undo step. +- A dialog is dragged by its title bar and stays on screen. +- Controls that cannot act are shown disabled or left out. No dead buttons, + with one exception: the "add" buttons of the details and record tabs + (Add, Assign, Add from Template, Add Resource, Add Role) stay enabled + when there is nothing to pick, as in the reference, and open their picker + empty (`details::form::add_button`). +- Words are plain and short. Captions that open another dialog end in "...". + +## Guards + +Drift fails a test, so run the sweeps after any UI change +(`cargo test -p openxer-desktop -- full_ui_sweep dialog_formatting_sweep`): + +- `dialog_sweep.rs` opens every dialog and checks that the shared shell drew + its frame, that standard buttons are 108 x 25, and the button order (a + column or row drawn in a declared observed order is checked against that order). Dialogs + still being moved onto the kit are named in `NOT_YET_CONVERTED`; that list + only ever shrinks. +- The same file's source check rejects a bare `egui::Area` or a private window + wrapper outside the kit, and `kit_controls_are_written_once` rejects a + second button column, move pad, tab list or message box. +- `panes::histogram::tests::one_histogram_painter` fails when a second + cumulative-curve painter appears outside `panes/histogram.rs`. +- `chat::tests::chat_controls_are_written_once` fails on a second roll-up or + size grip painter, Markdown reader or text builder, conversation model, + Activity ID linker, pinned message list or Markdown table layout or painter. +- `details::notes_pane::tests::the_notebook_tabs_share_one_pane` fails when + a Notebook tab draws its own topic pane. +- `views::headless::projects_details_tabs_show_dividers_and_switch` and + `usage_list_tests::row_lines_stop_at_the_last_column_like_the_activity_table` + pin the tab strip and the table against the Activities page. + +When you add a shared control, add its row to the table above and a guard +that would catch a second copy. diff --git a/LICENSE-APACHE b/LICENSE-APACHE new file mode 100644 index 0000000..1b5ec8b --- /dev/null +++ b/LICENSE-APACHE @@ -0,0 +1,176 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + +5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS diff --git a/LICENSE-MIT b/LICENSE-MIT new file mode 100644 index 0000000..ece6930 --- /dev/null +++ b/LICENSE-MIT @@ -0,0 +1,27 @@ +MIT License + +Copyright (c) 2026 The OpenXER Contributors + +Permission is hereby granted, free of charge, to any +person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the +Software without restriction, including without +limitation the rights to use, copy, modify, merge, +publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software +is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice +shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF +ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT +SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..1bf11f1 --- /dev/null +++ b/README.md @@ -0,0 +1,321 @@ +

OpenXER

+ +

+ A fast, native desktop scheduler for XER files, built to be driven by AI agents. Free, open source and local.
+ Open a schedule, run it, level it, update it, check it, report it and save it back out as XER.
+ Every edit you can make in the app, an agent can make through openxer-cli and MCP, under the same rules. +

+ +

+ Written in Rust + Windows and Linux + Works offline + AI Chat and 30 Skills + No account, no telemetry + License: MIT or Apache-2.0 +

+ +

+ + Download for Windows (.exe) + +   + + Download for Linux (AppImage) + +

+ +

+ + Windows 10/11 (64-bit) · Linux x86_64 (AppImage: chmod +x and run) · + All downloads (portable ZIP, Linux tarball, SHA256) + +

+ +

+ Why · + AI Chat & Skills · + XER · + Schedule · + Progress · + Table and Gantt · + Logic · + Resources · + Baselines · + Print · + Install · + Build +

+ +

OpenXER showing an activity table grouped by WBS, a Gantt chart with baseline bars and a progress line, and the Relationships tab of Activity Details
The Activities view on a sample construction schedule: table, Gantt chart and Activity Details.

+ +--- + +## Why OpenXER + +Construction runs on legacy scheduling software: expensive licenses, heavy installs, databases and servers to look after, slow screens and workflows that have not changed in decades. + +OpenXER keeps what schedulers already know. The activity table sits beside the Gantt chart with the details pane underneath. Layouts, filters, grouping, the dialogs and the terms are the ones you use every day, and XER goes in and comes out. There is nothing to relearn. + +It adds what the legacy tools lack: + +- **Built for AI agents.** Open the built-in **AI Chat (`F8`)** docked right beside the Gantt chart, choose from **30 prebuilt scheduling skills**, or connect external agents through `openxer-cli` and the built-in MCP server. Every edit runs through the exact same scheduling rules as the app. +- **Instant.** A single native program. It starts in a moment and stays responsive on large schedules. +- **Local.** Runs offline on one machine. No server, no database to install, no account, no telemetry. Your schedules stay in a workspace file on your disk, and the XER files you open are never modified. +- **Accurate.** A full critical path engine with calendars, constraints, lags, relationship types, Level of Effort activities, progress and resource leveling. Schedules calculate to the dates, float and leveled dates stored in the XER files it reads, verified against the update histories of real construction projects. +- **Free and open.** Open source under MIT or Apache-2.0. No license keys, no seat counts. +- **Modern.** A clean interface in its own colors, with the familiar layout intact. + +## Built for AI agents + +Legacy scheduling software was built for one person clicking through dialogs. OpenXER is built for that person **and** for the AI agent working beside them. The built-in Chat window, the 30 prebuilt scheduling skills, the command line and the MCP server all share the same edit layer as the app, so every answer comes from real schedule calculations and every approved edit lands exactly as if you had typed it. + +### Built-in AI Chat (`F8`) + +Press F8 (or **AI Agents > Chat**) to open AI Chat docked beside your activity table and Gantt chart. The assistant inspects the open project directly through OpenXER's native tools, links every Activity ID it mentions so clicking it jumps straight to that row, and previews edits as a field-by-field proposal you approve or reject in one click. + +

OpenXER with the Activity Table, Gantt chart and Relationships details on the left and the built-in AI Chat window docked on the right showing tool calls, clickable Activity IDs and a pending progress edit proposal
Built-in AI Chat docked beside the schedule: tool calls, clickable Activity IDs and a reviewable edit proposal before anything changes.

+ +**Bring your own AI** + +- **Sign in with ChatGPT:** use your own ChatGPT plan directly from the app. +- **Claude Code or Codex:** run through your existing local CLI agent with zero extra API keys. +- **OpenAI-compatible API:** point at any compatible endpoint with your own API key. +- **Local model on your PC:** point at Ollama, LM Studio or another local server so nothing leaves your machine. + +### 30 prebuilt scheduling skills + +OpenXER ships with **30 built-in scheduling skills** (`assets/skills/`) covering real project controls workflows, plus interactive playbooks in Chat. Connected agents discover and load the matching skill automatically, or you can open **AI Agents > Skills** to browse, edit, copy a ready-to-paste prompt, or author your own firm's standards in plain Markdown. + +

The AI Agents > Skills dialog listing OpenXER's 30 built-in scheduling skills with the Logic Health Check skill selected
AI Agents > Skills: browse, customize or add Markdown scheduling skills shared across the app, CLI and MCP server.

+ +| Workflow | Prebuilt skills included | +|---|---| +| **Build & Scope** | `build-schedule`, `add-scope`, `resource-load`, `change-interview`, `schedule-basis` | +| **Weekly Updates** | `progress-update`, `update-review`, `look-ahead`, `milestone-status`, `compare-files` | +| **Audits & Health** | `logic-health-check`, `schedule-review`, `baseline-review`, `baseline-variance`, `float-constraint-review`, `calendar-duration-check`, `duration-review`, `activity-definition-review`, `sequence-review`, `resource-loading-review`, `schedule-maturity`, `levels-of-detail` | +| **Delay, Risk & Recovery** | `critical-path-explained`, `near-critical-paths`, `recovery-schedule`, `time-impact`, `contingency-float`, `risk-read` | +| **Executive Outputs** | `one-page-schedule`, `export-pack` | + +Skills are plain Markdown files under [assets/skills/](assets/skills/): you do not need to write Rust to contribute. Fork the repo and open a pull request to improve a skill or share a new one with other schedulers. + +**What you can hand to an agent** + +- "Here is this morning's field report. Enter the progress, reschedule, and tell me what moved on the critical path." +- "Add the tie-in work from this RFI: four activities after the pipe rack, welded connections need an X-ray step." +- "The crew limit for pipefitters drops to 10 next week. Level the schedule and list every activity that slips more than two days." +- "Run a logic health check: open ends, lags over 5 days, constraints, out-of-sequence progress. Fix what is safe and list the rest." +- "Compare this update with last week's and write the change summary for the client." + +**Connect external AI clients (MCP)** + +In the app, open **AI Agents > Connect AI Agents...** and click **Connect** next to Claude Desktop, ChatGPT desktop and Codex (one setting serves both), or Claude Code. OpenXER writes the entry with the right path, backs the app's settings file up first, tests the connection and tells you what to do next: quit Claude Desktop from its tray icon and open it again, or restart ChatGPT desktop or Codex (in ChatGPT desktop use Work or Codex mode). Then ask: "Use OpenXER to inspect my schedule." The agent finds your workspace and its projects by itself. From a terminal, `openxer-cli connect all` does the same. + +`openxer-cli mcp` runs a local MCP server over stdio. Any other MCP client can point at it: + +```json +{ + "mcpServers": { + "openxer": { + "command": "C:\\Users\\you\\OpenXER\\openxer-cli.exe", + "args": ["mcp"] + } + } +} +``` + +For Claude Code: `claude mcp add --scope user openxer -- "C:\Users\you\OpenXER\openxer-cli.exe" mcp`. The release ships this block as `openxer.mcp.json`; replace its `` with the path where you put the file. + +**Or script it** + +```text +openxer-cli inspect --input week-14.xer +openxer-cli set-activity --input week-14.xer --activity PIP-3120 --field remaining_duration --value 16 --output week-14-updated.xer +openxer-cli schedule --input week-14-updated.xer --data-date "2026-04-06 08:00" --level true --output week-15.xer +openxer-cli apply --input week-14.xer --changes field-report.json --dry-run +``` + +A whole update is one changes file, applied in order and all or nothing: + +```json +{ + "format": "openxer-changes/1", + "operations": [ + {"op": "set_project", "field": "data_date", "value": "2026-04-06 08:00"}, + {"op": "set_activity", "activity": "PIP-3110", "field": "actual_finish", "value": "2026-04-03 15:00", + "meta": {"source": "field report, April 3"}}, + {"op": "set_activity", "activity": "PIP-3120", "field": "remaining_duration", "value": 16}, + {"op": "relationship", "action": "add", "predecessor": "PIP-3130", "successor": "PIP-3140", "kind": "FS", "lag_hours": 0}, + {"op": "schedule", "level_resources": true} + ] +} +``` + +**What you can count on** + +- **The same rules as the app.** Statuses, durations, units and assignments follow exactly as they would if you typed the edit. Things are named the way you see them: Activity ID, resource short name, calendar name, WBS path. +- **Safe by design.** The input file is never modified; every change writes a new output. A batch that fails anywhere writes nothing, and `--dry-run` shows every field that would change. +- **Traceable.** Each edit can carry a `meta` note, such as the report or email it came from. +- **Proven on real projects.** The edit commands were verified by replaying the full update history of real construction projects through the CLI, week after week, and matching the scheduler's own stored results field for field, including on resource-leveled schedules. +- **Local.** The server runs on your machine and sees only the files you point it at. OpenXER itself sends nothing anywhere, except Chat when you use it with ChatGPT or with an API key: then your questions and the schedule data its tools read go to that service. With Claude Code, Codex or a model on your own PC, Chat itself sends nothing off it. + +Tools: `openxer_inspect`, `openxer_load`, `openxer_schedule`, `openxer_apply`, `openxer_check_schedule`, `openxer_paths`, `openxer_compare`, `openxer_lookahead`, `openxer_milestones`, `openxer_schedule_stats`, `openxer_resource_loading`, `openxer_wbs_summary`, `openxer_skills`, `openxer_skill`, `openxer_set_activity`, `openxer_add_activity`, `openxer_delete_activity`, `openxer_assign`, `openxer_unassign`, `openxer_set_assignment`, `openxer_relationship`, `openxer_calendar_day`, `openxer_calendar_weekday`, `openxer_set_project`, `openxer_add_wbs`, `openxer_import`, `openxer_export` and `openxer_export_pdf`, among others. The full CLI, JSON, skills and MCP reference is in [automation/README.md](automation/README.md). + +## Open and save XER + +- Open any XER file and pick the projects you want when it holds several. Open several projects at once and see them side by side. +- Save to the local workspace, then export a clean XER whenever you need to send it on. Tables and fields OpenXER does not use are carried through untouched, so nothing in your file quietly disappears. +- Import into a new project, replace an existing one, or add activities into a project you already have. Undo Last Import takes it back. + +## Plan and schedule + +- Press F9 to schedule. Schedule Options cover the data date, retained logic, progress override and actual dates, out-of-sequence progress, longest path, float paths, open ends and more. Each run writes a schedule log. +- Calendars with work weeks, shifts and holidays, a Must Finish By date and every constraint type. +- Turn on automatic scheduling and the dates follow every edit as you type. +- Check Schedule scores the schedule against common health targets: open ends, lags, relationship types, constraints, large and negative float, long durations, invalid progress dates, late activities, out-of-sequence progress and more. Each check can filter the table to the activities it finds. + +

The Check Schedule Results window listing each check with its count, result and target
Check Schedule results on the sample schedule.

+ +## Update progress + +- Edit status, actual start and finish, remaining duration and percent complete right in the table or in the Status tab of the details pane. Both follow the same rules. +- Update Progress and Apply Actuals move a whole period at once, and Progress Spotlight highlights what should have moved since the last update. +- Steps, expected finish, suspend and resume, and resource actuals on each assignment. +- Save Period Actuals (store period performance) against financial periods. + +

The Update Progress dialog over an activity table with status, actual dates and percent complete, with Progress Spotlight highlighting the next week
Update Progress with Progress Spotlight on the week after the data date.

+ +## The activity table and Gantt chart + +- Columns for every schedule, resource, cost, earned value, code and user-defined field, with your own widths and titles. +- Group by WBS, activity codes or any field, with band totals, intervals by week or month and page breaks. +- Filters with nested All/Any conditions and dates relative to the data date, so a three-week lookahead is one filter that moves with every update. +- Drag bars to change dates, drag between bars to link them, click a relationship line to edit it. Curtains, text attachments, sight lines, a progress line and baseline bars. +- A timescale that zooms from hours to years, scroll bars on both sides and optional line numbers. +- Show Trace Logic, Activity Network, usage profiles and spreadsheets, or a second table and Gantt in the bottom pane. Split the window into tab groups and open a second Activities view with its own layout. +- Save it all as named layouts, and export or import layouts to share them. + +## Check the logic + +- Trace Logic draws the predecessors and successors of the selected activity as a network, critical path in red. +- Activity Critical Path shows the backward and forward driving paths through any activity. +- Driving relationships, free and total float, float paths and the longest path in the table. +- Schedule Comparison lists added, deleted and changed activities, relationships and fields between two projects, or between a project and its baseline. + +

Trace Logic in the bottom pane showing the predecessors and successors of an instrumentation activity, critical activities in red
Trace Logic for the instrument wiring activity.

+ +## Resources and leveling + +- Resources, roles, rates, shifts, curves and calendars, all editable. +- Assign resources and roles, set units, lag and overtime, and record actuals by assignment. +- Expenses, cost accounts, funding sources and currencies. +- Resource usage profiles and spreadsheets by day, week or month, in units or costs, with cumulative curves, against each resource's limit. +- Level Resources with priorities, limits and calendars, and a leveling log of what moved. + + + + + + +
Resource usage profile for the pipefitter crew with one week above its limit shown in red
Before: the pipefitters are overloaded the week of the data date.
The same resource usage profile after leveling, every week within the limit
After Level Resources: the work fits under the crew limit.
+ +## Baselines + +- Keep any number of baselines, assign a project baseline and up to three user baselines, and update them by the Update Baseline options (what to add, delete and carry for activities, assignments and the project), with a preview of every change first. +- Baseline bars on the Gantt chart, baseline dates and variance columns in the table, and earned value against the baseline you choose. + +

The activity table with baseline start, baseline finish, current dates and finish variance, and baseline bars under the current bars
Current dates against the project baseline, with finish variance.

+ +## Print and report + +- Print and Print Preview from the layout on screen, with page setup for paper, margins, headers, footers and legends. Publish straight to PDF. +- A Reports window with a starter set of scheduling reports: lookaheads by WBS, critical activities, open ends and logic gaps, progress this period, predecessors and successors, milestones, baseline variance and resource usage by week. Run them to PDF, HTML, text or print preview. +- Build your own reports, organize them in groups and run a batch in one go. Report definitions from other scheduling tools can be imported. + +

Print Preview of the Gantt layout with title block, activity table and bars
Print Preview of the layout on screen.

+ +## Install + +Download directly from the **[Latest Release](https://github.com/OpenXER/openxer/releases/latest)**: + +| Platform | Recommended download | Portable download | +|---|---|---| +| **Windows 10/11 (64-bit)** | [**OpenXER-0.1.0-setup.exe**](https://github.com/OpenXER/openxer/releases/latest/download/OpenXER-0.1.0-setup.exe) (installer, no admin needed) | [OpenXER-0.1.0-windows-x64.zip](https://github.com/OpenXER/openxer/releases/latest/download/OpenXER-0.1.0-windows-x64.zip) | +| **Linux (x86_64, X11/Wayland)** | [**OpenXER-0.1.0-x86_64.AppImage**](https://github.com/OpenXER/openxer/releases/latest/download/OpenXER-0.1.0-x86_64.AppImage) (single file, `chmod +x` and run) | [OpenXER-0.1.0-linux-x86_64.tar.gz](https://github.com/OpenXER/openxer/releases/latest/download/OpenXER-0.1.0-linux-x86_64.tar.gz) | + +Verify checksums with [SHA256SUMS.txt](https://github.com/OpenXER/openxer/releases/latest/download/SHA256SUMS.txt). + +### Windows installer + +Run `OpenXER--setup.exe`. It installs for your Windows account only and needs no administrator rights (the default folder is `%LOCALAPPDATA%\Programs\OpenXER`). Choose **Install for all users** on its first screen to put it in `Program Files` instead; that one asks for administrator rights. + +The wizard asks for the folder, the Start Menu folder, a desktop shortcut (off by default) and whether double-clicking an `.xer` file should open OpenXER (off by default, so a program that already opens `.xer` files keeps doing so; OpenXER is listed under **Open with** either way). The last page can start OpenXER. + +OpenXER is not code signed yet, so Windows warns you the first time: + +1. Your browser may say the file is not commonly downloaded. Choose **Keep** (in Edge: **...** then **Keep**, then **Show more** and **Keep anyway**). +2. When you run it, **Windows protected your PC** may appear. Click **More info**, check that the app is `OpenXER--setup.exe`, then **Run anyway**. +3. The default (just for you) install shows no administrator prompt. **Install for all users** shows the Windows administrator prompt, which names the publisher as **Unknown publisher**. + +Silent install for IT: `OpenXER--setup.exe /VERYSILENT /SUPPRESSMSGBOXES /LOG=` (add `/DIR=`, `/TASKS=desktopicon,associate`, or `/ALLUSERS`). A silent install stops with exit code 7 instead of closing a running OpenXER. + +### The portable zip + +Unpack it into a folder you own and run `OpenXER.exe`. Keep `openxer-cli.exe` next to it. `openxer.mcp.json` is an MCP client configuration to fill in with the full path of `openxer-cli.exe` (the installer fills it in for you). + +### Linux + +- **AppImage:** `chmod +x OpenXER--x86_64.AppImage && ./OpenXER--x86_64.AppImage` +- **Portable tarball:** unpack `OpenXER--linux-x86_64.tar.gz` and run `./openxer` (with `./openxer-cli` beside it for CLI and MCP). + +### Where your schedules live + +Your projects are kept in one workspace file, `openxer.db`, with a `backups` folder and any crash reports beside it: + +- **Windows installed:** `%LOCALAPPDATA%\OpenXER`, never the program folder, so upgrading or uninstalling never touches it. +- **Linux:** `${XDG_DATA_HOME:-~/.local/share}/openxer`. +- **Portable:** next to `OpenXER.exe`, or the user data folder above when that folder cannot be written. +- **Any platform:** the folder the `OPENXER_DATA_DIR` environment variable names, when it is set. `OpenXER --database ` opens any other workspace. + +The status bar shows the workspace in use. + +### Upgrade, move, uninstall + +- **Upgrade:** run the newer setup. It replaces the program in place and keeps your settings and workspace. Close OpenXER first, or Setup asks you to. +- **Move a workspace:** close OpenXER and copy `openxer.db` (and `backups` if you want them) to the other folder or PC, into the data folder above. +- **Uninstall:** **Settings > Apps > Installed apps > OpenXER > Uninstall**. It removes the program, its shortcuts and its file type entries. Your workspace and backups stay in `%LOCALAPPDATA%\OpenXER`; delete that folder yourself if you no longer need them. A portable copy is removed by deleting its folder (its workspace is in that folder). + +## Build from source + +- **Windows:** Rust stable with the MSVC target, the Visual Studio C++ Build Tools and the Windows SDK. SQLite is bundled. +- **Linux:** Rust stable, a C compiler (`build-essential`), `pkg-config`, `libssl-dev` (for OpenSSL TLS and `openxer-chat`), and `fonts-liberation` (for test text measurements). SQLite is bundled. + +```text +cargo build --release -p openxer-desktop -p openxer-automation +cargo run -p openxer-desktop +cargo run -p openxer-automation -- --help +cargo test --workspace +``` + +The release build writes `target/release/OpenXER.exe` and `openxer-cli.exe` on Windows (`OpenXER` and `openxer-cli` on Linux). `python desktop/build_release.py --output \OpenXER.exe` builds both on Windows with the static runtime and packages them with `CLI-MCP.md`, `LICENSE-MIT`, `LICENSE-APACHE`, `THIRD_PARTY.md` and an `openxer.mcp.json` template whose command is a placeholder for the installed path. Add `--installer` to also build `target/installer/OpenXER--setup.exe` with [Inno Setup 6](https://jrsoftware.org/isinfo.php) from `tools/installer/openxer.iss`, and `--sign-command ""` to sign the executables and Setup. + +Some tests compare against real schedules that cannot be published. They read their inputs from `OPENXER_FIXTURES`, `OPENXER_CORPUS`, `OPENXER_RPT_INPUTS` and `OPENXER_RPT_DB`, and skip with a printed reason when those are not set. The screenshots in this README are rendered headless from a synthetic schedule with `cargo test -p openxer-desktop --bin OpenXER readme -- --ignored`. + +## Contributing and roadmap + +See [CONTRIBUTING.md](CONTRIBUTING.md) and [ROADMAP.md](ROADMAP.md). AI coding agents should read [AGENTS.md](AGENTS.md) first. + +## About + +OpenXER is an independent project. It is not affiliated with, endorsed by or sponsored by any scheduling software vendor. XER is a schedule interchange file format; product and company names belong to their owners. + +## License + +Licensed under either of + +- Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE)) +- MIT license ([LICENSE-MIT](LICENSE-MIT)) + +at your option. + +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/ROADMAP.md b/ROADMAP.md new file mode 100644 index 0000000..29884db --- /dev/null +++ b/ROADMAP.md @@ -0,0 +1,33 @@ +# Roadmap + +OpenXER is developed in the open. Contributions, forks and pull requests are +welcome; open an issue or discussion before starting larger work so we can +align on the design. + +## Shipped in v0.1.0 + +- Native desktop CPM scheduler for Windows and Linux (`OpenXER` and `openxer-cli`) +- Full XER round-trip preservation, project XML import/export, Excel (XLSX) + import/export, S-curve and Earned Hours workbooks, and vector PDF printing +- Critical path scheduling, calendars, constraints, Level of Effort, progress + updates, baselines, schedule comparison, Check Schedule, resource usage and + resource leveling +- Built-in AI Chat (`F8`) with live tool calls, clickable Activity IDs, + reviewable edit proposals, and Bring Your Own AI (ChatGPT sign-in, Claude + Code, Codex, OpenAI-compatible API keys, or local models) +- Built-in MCP server (`openxer-cli mcp`) and 30 prebuilt Markdown scheduling + skills (`AI Agents > Skills`) + +## Next up + +- **macOS support:** native macOS builds, packaging and CI coverage +- **Code signing:** signed Windows installers (SignPath / Authenticode) so + first-run SmartScreen prompts go away +- **Linux package channels:** Flatpak / distribution packages alongside the + AppImage and portable tarball +- **Expanded synthetic benchmark suite:** larger public invented schedules for + external contributors testing engine, leveling and baseline PRs +- **Community scheduling skills:** more domain playbooks and skills under + `assets/skills/` (turnarounds, megaprojects, forensic delay, cost loading) +- **Additional CLI and MCP parity:** closing the remaining read and edit gaps + tracked in [automation/COVERAGE.md](automation/COVERAGE.md) diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 0000000..81578a6 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,27 @@ +# Security policy + +## Reporting a vulnerability + +Please do not open a public issue for a security problem. + +Report it privately through GitHub: open the repository's **Security** tab +and choose **Report a vulnerability**. Include what you found, how to +reproduce it, and which version you used. Do not include real project +schedules; describe or invent the input that triggers the problem. + +You will get an acknowledgement, and a fix or a plan, as soon as the +maintainers have reproduced the problem. + +## Scope + +OpenXER runs locally. Of most interest: + +- crafted XER, Excel or workspace files that crash the app, corrupt a + workspace, or run code; +- the CLI or MCP server writing outside the output path it was given, or + modifying an input file; +- anything that sends schedule data off the machine. + +## Supported versions + +Fixes go into the latest release. diff --git a/THIRD_PARTY.md b/THIRD_PARTY.md new file mode 100644 index 0000000..231111d --- /dev/null +++ b/THIRD_PARTY.md @@ -0,0 +1,2394 @@ +# Third-party material + +## English word list (Spell Check) + +`desktop/assets/spell/words.txt` is the built-in dictionary of Edit > Spell +Check. It is derived from SCOWL (Spell Checker Oriented Word Lists) by Kevin +Atkinson, http://wordlist.aspell.net/ (formerly wordlist.sourceforge.net), +through the Hunspell en_US dictionary built from SCOWL 2020.12.07 (size 60, +American spelling), as packaged by Debian (`hunspell-en-us` +1:2020.12.07-2). + +How it was made: `tools/spell/build_wordlist.py` expanded the Hunspell stems +with the affix rules of `en_US.aff`, dropped words with digits or symbols, +one-letter words and possessives, sorted the result and front coded it (130,788 +words, 591,000 bytes). Inputs and output, SHA-256: + +- `en_US.dic` 829a043cf078d1e80e886289a13823454977f442a239a859d2133ea61944aa60 +- `en_US.aff` 70fe5778717d097ce2f3326baaa5c1e4d2206d81a5a81d3ea8e11c4770806dd5 +- `words.txt` 8e62be146fb0b3d1f71ae32ed988920030a74a99e33d712553aa0eb96ab8b930 + +License: the SCOWL license is permissive (use, copy, modify, distribute and +sell, with the copyright and permission notices kept in the documentation). +Its notices, with those of the sources SCOWL credits, follow verbatim from +the package's copyright file. + +`desktop/assets/spell/construction.txt` (construction and project controls +words) was written for OpenXER and is not third-party material. + +```text +SCOWL (Spell Checker Oriented Word Lists) is a collection of +English word lists maintained by Kevin Atkinson + + +It was downloaded from: +http://prdownloads.sourceforge.net/wordlist/scowl-5.tar.gz + +SF project page: +http://wordlist.sourceforge.net/ + +Copyright: (extracted from the SCOWL README file): + +The collective work is Copyright 2000-2011 by Kevin Atkinson as well +as any of the copyrights mentioned below: + + Copyright 2000-2011 by Kevin Atkinson + + Permission to use, copy, modify, distribute and sell these word + lists, the associated scripts, the output created from the scripts, + and its documentation for any purpose is hereby granted without fee, + provided that the above copyright notice appears in all copies and + that both that copyright notice and this permission notice appear in + supporting documentation. Kevin Atkinson makes no representations + about the suitability of this array for any purpose. It is provided + "as is" without express or implied warranty. + +Alan Beale also deserves special credit as he has, +in addition to providing the 12Dicts package and being a major +contributor to the ENABLE word list, given me an incredible amount of +feedback and created a number of special lists (those found in the +Supplement) in order to help improve the overall quality of SCOWL. + +The 10 level includes the 1000 most common English words (according to +the Moby (TM) Words II [MWords] package), a subset of the 1000 most +common words on the Internet (again, according to Moby Words II), and +frequently class 16 from Brian Kelk's "UK English Wordlist +with Frequency Classification". + +The MWords package was explicitly placed in the public domain: + + The Moby lexicon project is complete and has + been place into the public domain. Use, sell, + rework, excerpt and use in any way on any platform. + + Placing this material on internal or public servers is + also encouraged. The compiler is not aware of any + export restrictions so freely distribute world-wide. + + You can verify the public domain status by contacting + + Grady Ward + 3449 Martha Ct. + Arcata, CA 95521-4884 + + grady@netcom.com + grady@northcoast.com + +The "UK English Wordlist With Frequency Classification" is also in the +Public Domain: + + Date: Sat, 08 Jul 2000 20:27:21 +0100 + From: Brian Kelk + + > I was wondering what the copyright status of your "UK English + > Wordlist With Frequency Classification" word list as it seems to + > be lacking any copyright notice. + + There were many many sources in total, but any text marked + "copyright" was avoided. Locally-written documentation was one + source. An earlier version of the list resided in a filespace called + PUBLIC on the University mainframe, because it was considered public + domain. + + Date: Tue, 11 Jul 2000 19:31:34 +0100 + + > So are you saying your word list is also in the public domain? + + That is the intention. + +The 20 level includes frequency classes 7-15 from Brian's word list. + +The 35 level includes frequency classes 2-6 and words appearing in at +least 11 of 12 dictionaries as indicated in the 12Dicts package. All +words from the 12Dicts package have had likely inflections added via +my inflection database. + +The 12Dicts package and Supplement is in the Public Domain. + +The WordNet database, which was used in the creation of the +Inflections database, is under the following copyright: + + This software and database is being provided to you, the LICENSEE, + by Princeton University under the following license. By obtaining, + using and/or copying this software and database, you agree that you + have read, understood, and will comply with these terms and + conditions.: + + Permission to use, copy, modify and distribute this software and + database and its documentation for any purpose and without fee or + royalty is hereby granted, provided that you agree to comply with + the following copyright notice and statements, including the + disclaimer, and that the same appear on ALL copies of the software, + database and documentation, including modifications that you make + for internal use or for distribution. + + WordNet 1.6 Copyright 1997 by Princeton University. All rights + reserved. + + THIS SOFTWARE AND DATABASE IS PROVIDED "AS IS" AND PRINCETON + UNIVERSITY MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR + IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PRINCETON + UNIVERSITY MAKES NO REPRESENTATIONS OR WARRANTIES OF MERCHANT- + ABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE + LICENSED SOFTWARE, DATABASE OR DOCUMENTATION WILL NOT INFRINGE ANY + THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS. + + The name of Princeton University or Princeton may not be used in + advertising or publicity pertaining to distribution of the software + and/or database. Title to copyright in this software, database and + any associated documentation shall at all times remain with + Princeton University and LICENSEE agrees to preserve same. + +The 40 level includes words from Alan's 3esl list found in version 4.0 +of his 12dicts package. Like his other stuff the 3esl list is also in the +public domain. + +The 50 level includes Brian's frequency class 1, words words appearing +in at least 5 of 12 of the dictionaries as indicated in the 12Dicts +package, and uppercase words in at least 4 of the previous 12 +dictionaries. A decent number of proper names is also included: The +top 1000 male, female, and Last names from the 1990 Census report; a +list of names sent to me by Alan Beale; and a few names that I added +myself. Finally a small list of abbreviations not commonly found in +other word lists is included. + +The name files form the Census report is a government document which I +don't think can be copyrighted. + +The file special-jargon.50 uses common.lst and word.lst from the +"Unofficial Jargon File Word Lists" which is derived from "The Jargon +File". All of which is in the Public Domain. This file also contain +a few extra UNIX terms which are found in the file "unix-terms" in the +special/ directory. + +The 55 level includes words from Alan's 2of4brif list found in version +4.0 of his 12dicts package. Like his other stuff the 2of4brif is also +in the public domain. + +The 60 level includes all words appearing in at least 2 of the 12 +dictionaries as indicated by the 12Dicts package. + +The 70 level includes Brian's frequency class 0 and the 74,550 common +dictionary words from the MWords package. The common dictionary words, +like those from the 12Dicts package, have had all likely inflections +added. The 70 level also included the 5desk list from version 4.0 of +the 12Dics package which is the public domain. + +The 80 level includes the ENABLE word list, all the lists in the +ENABLE supplement package (except for ABLE), the "UK Advanced Cryptics +Dictionary" (UKACD), the list of signature words in from YAWL package, +and the 10,196 places list from the MWords package. + +The ENABLE package, mainted by M\Cooper , +is in the Public Domain: + + The ENABLE master word list, WORD.LST, is herewith formally released + into the Public Domain. Anyone is free to use it or distribute it in + any manner they see fit. No fee or registration is required for its + use nor are "contributions" solicited (if you feel you absolutely + must contribute something for your own peace of mind, the authors of + the ENABLE list ask that you make a donation on their behalf to your + favorite charity). This word list is our gift to the Scrabble + community, as an alternate to "official" word lists. Game designers + may feel free to incorporate the WORD.LST into their games. Please + mention the source and credit us as originators of the list. Note + that if you, as a game designer, use the WORD.LST in your product, + you may still copyright and protect your product, but you may *not* + legally copyright or in any way restrict redistribution of the + WORD.LST portion of your product. This *may* under law restrict your + rights to restrict your users' rights, but that is only fair. + +UKACD, by J Ross Beresford , is under the +following copyright: + + Copyright (c) J Ross Beresford 1993-1999. All Rights Reserved. + + The following restriction is placed on the use of this publication: + if The UK Advanced Cryptics Dictionary is used in a software package + or redistributed in any form, the copyright notice must be + prominently displayed and the text of this document must be included + verbatim. + + There are no other restrictions: I would like to see the list + distributed as widely as possible. + +The 95 level includes the 354,984 single words, 256,772 compound +words, 4,946 female names and the 3,897 male names, and 21,986 names +from the MWords package, ABLE.LST from the ENABLE Supplement, and some +additional words found in my part-of-speech database that were not +found anywhere else. + +Accent information was taken from UKACD. + +My VARCON package was used to create the American, British, and +Canadian word list. + +Since the original word lists used used in the VARCON package came +from the Ispell distribution they are under the Ispell copyright: + + Copyright 1993, Geoff Kuenning, Granada Hills, CA + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + 3. All modifications to the source code must be clearly marked as + such. Binary redistributions based on modified source code + must be clearly marked as modified versions in the documentation + and/or other materials provided with the distribution. + (clause 4 removed with permission from Geoff Kuenning) + 5. The name of Geoff Kuenning may not be used to endorse or promote + products derived from this software without specific prior + written permission. + + THIS SOFTWARE IS PROVIDED BY GEOFF KUENNING AND CONTRIBUTORS ``AS + IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GEOFF + KUENNING OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. +``` + +## Fonts bundled by the user interface library + +The app draws text with the Windows system fonts it finds at run time (Arial, +Segoe UI and Tahoma, read from the system font folder; none of them is +shipped with OpenXER). As a fallback for missing faces and characters, the +executable embeds the default fonts of the egui user interface library, +from the `epaint_default_fonts` crate (version 0.33.3, license expression +`(MIT OR Apache-2.0) AND OFL-1.1 AND Ubuntu-font-1.0`). The crate's code is +MIT or Apache-2.0; the fonts it embeds are: + +| Font | File | License | +|---|---|---| +| Hack Regular | `Hack-Regular.ttf` | MIT (Hack), public domain (DejaVu changes) and the Bitstream Vera License | +| Noto Emoji Regular | `NotoEmoji-Regular.ttf` | SIL Open Font License 1.1 | +| Ubuntu Light | `Ubuntu-Light.ttf` | Ubuntu Font Licence 1.0 | +| emoji-icon-font | `emoji-icon-font.ttf` | MIT | + +The notices and license texts below are copied verbatim from the crate's +`fonts/` folder. + +### Hack Regular (`fonts/Hack-Regular.txt`) + +```text +The work in the Hack project is Copyright 2018 Source Foundry Authors and licensed under the MIT License + +The work in the DejaVu project was committed to the public domain. + +Bitstream Vera Sans Mono Copyright 2003 Bitstream Inc. and licensed under the Bitstream Vera License with Reserved Font Names "Bitstream" and "Vera" +MIT License + +Copyright (c) 2018 Source Foundry Authors + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +BITSTREAM VERA LICENSE + +Copyright (c) 2003 by Bitstream, Inc. All Rights Reserved. Bitstream Vera is a trademark of Bitstream, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy of the fonts accompanying this license ("Fonts") and associated documentation files (the "Font Software"), to reproduce and distribute the Font Software, including without limitation the rights to use, copy, merge, publish, distribute, and/or sell copies of the Font Software, and to permit persons to whom the Font Software is furnished to do so, subject to the following conditions: + +The above copyright and trademark notices and this permission notice shall be included in all copies of one or more of the Font Software typefaces. + +The Font Software may be modified, altered, or added to, and in particular the designs of glyphs or characters in the Fonts may be modified and additional glyphs or characters may be added to the Fonts, only if the fonts are renamed to names not containing either the words "Bitstream" or the word "Vera". + +This License becomes null and void to the extent applicable to Fonts or Font Software that has been modified and is distributed under the "Bitstream Vera" names. + +The Font Software may be sold as part of a larger software package but no copy of one or more of the Font Software typefaces may be sold by itself. + +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL BITSTREAM OR THE GNOME FOUNDATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. + +Except as contained in this notice, the names of Gnome, the Gnome Foundation, and Bitstream Inc., shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Font Software without prior written authorization from the Gnome Foundation or Bitstream Inc., respectively. For further information, contact: fonts at gnome dot org. +``` + +### Noto Emoji Regular: SIL Open Font License 1.1 (`fonts/OFL.txt`) + +```text +This Font Software is licensed under the SIL Open Font License, +Version 1.1. + +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font +creation efforts of academic and linguistic communities, and to +provide a free and open framework in which fonts may be shared and +improved in partnership with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply to +any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software +components as distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, +deleting, or substituting -- in part or in whole -- any of the +components of the Original Version, by changing formats or by porting +the Font Software to a new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, +modify, redistribute, and sell modified and unmodified copies of the +Font Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, in +Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the +corresponding Copyright Holder. This restriction only applies to the +primary font name as presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created using +the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. +``` + +### Ubuntu Light: Ubuntu Font Licence 1.0 (`fonts/UFL.txt`) + +```text +------------------------------- +UBUNTU FONT LICENCE Version 1.0 +------------------------------- + +PREAMBLE +This licence allows the licensed fonts to be used, studied, modified and +redistributed freely. The fonts, including any derivative works, can be +bundled, embedded, and redistributed provided the terms of this licence +are met. The fonts and derivatives, however, cannot be released under +any other licence. The requirement for fonts to remain under this +licence does not require any document created using the fonts or their +derivatives to be published under this licence, as long as the primary +purpose of the document is not to be a vehicle for the distribution of +the fonts. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this licence and clearly marked as such. This may +include source files, build scripts and documentation. + +"Original Version" refers to the collection of Font Software components +as received under this licence. + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to +a new environment. + +"Copyright Holder(s)" refers to all individuals and companies who have a +copyright ownership of the Font Software. + +"Substantially Changed" refers to Modified Versions which can be easily +identified as dissimilar to the Font Software by users of the Font +Software comparing the Original Version with the Modified Version. + +To "Propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification and with or without charging +a redistribution fee), making available to the public, and in some +countries other activities as well. + +PERMISSION & CONDITIONS +This licence does not grant any rights under trademark law and all such +rights are reserved. + +Permission is hereby granted, free of charge, to any person obtaining a +copy of the Font Software, to propagate the Font Software, subject to +the below conditions: + +1) Each copy of the Font Software must contain the above copyright +notice and this licence. These can be included either as stand-alone +text files, human-readable headers or in the appropriate machine- +readable metadata fields within text or binary files as long as those +fields can be easily viewed by the user. + +2) The font name complies with the following: +(a) The Original Version must retain its name, unmodified. +(b) Modified Versions which are Substantially Changed must be renamed to +avoid use of the name of the Original Version or similar names entirely. +(c) Modified Versions which are not Substantially Changed must be +renamed to both (i) retain the name of the Original Version and (ii) add +additional naming elements to distinguish the Modified Version from the +Original Version. The name of such Modified Versions must be the name of +the Original Version, with "derivative X" where X represents the name of +the new work, appended to that name. + +3) The name(s) of the Copyright Holder(s) and any contributor to the +Font Software shall not be used to promote, endorse or advertise any +Modified Version, except (i) as required by this licence, (ii) to +acknowledge the contribution(s) of the Copyright Holder(s) or (iii) with +their explicit written permission. + +4) The Font Software, modified or unmodified, in part or in whole, must +be distributed entirely under this licence, and must not be distributed +under any other licence. The requirement for fonts to remain under this +licence does not affect any document created using the Font Software, +except any version of the Font Software extracted from a document +created using the Font Software may only be distributed under this +licence. + +TERMINATION +This licence becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF +COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER +DEALINGS IN THE FONT SOFTWARE. +``` + +### emoji-icon-font (`fonts/emoji-icon-font-mit-license.txt`) + +```text +MIT License + +Copyright (c) 2014 John Slegers + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +``` + + + +## Rust crates + +OpenXER and openxer-cli (OpenXER.exe and openxer-cli.exe on Windows) are +built from the 298 crates below: the normal dependencies of +`openxer-desktop` and `openxer-automation` for `x86_64-pc-windows-msvc` +(Windows) and `x86_64-unknown-linux-gnu` (Linux), from `Cargo.lock`. A crate +that only one system's executables contain is marked with that system (10 +marked "Windows only", 101 marked "Linux only"); the rest are in both. Each +is listed under the license expression its `Cargo.toml` declares, with the +copyright lines of its license files. The full license texts follow the +list; files that are not a plain MIT or Apache-2.0 text, and every NOTICE +file, are reproduced per crate after that. En and em dashes in reproduced +texts are written as hyphens. +Regenerate this part with `python tools/licenses/third_party.py`. + +## SQLite + +OpenXER and openxer-cli include SQLite 3.50.2, compiled from the +amalgamation bundled in the `libsqlite3-sys` 0.35.0 crate +(listed below with its own license). SQLite is in the public domain; its +source carries this blessing in place of a license: + +```text +The author disclaims copyright to this source code. In place of +a legal notice, here is a blessing: + + May you do good and not evil. + May you find forgiveness for yourself and forgive others. + May you share freely, never taking more than you give. +``` + +### Crates by license + +#### MIT OR Apache-2.0 (136 crates) + +- `aes` 0.8.4: Copyright (c) 2018 Artyom Pavlov +- `ahash` 0.8.12: Copyright (c) 2018 Tom Kaitchuck +- `arboard` 3.7.0: Copyright (c) 2022 The Arboard contributors +- `as-raw-xcb-connection` 1.0.1 (Linux only): Copyright 2019 as-raw-xcb-connection Contributers +- `async-broadcast` 0.7.2 (Linux only): Copyright 2020 Yoshua Wuyts; Copyright (c) 2020 Yoshua Wuyts +- `async-recursion` 1.2.0 (Linux only): no copyright line in the package; authors: Robert Usher <266585+dcchut@users.noreply.github.com> +- `async-trait` 0.1.92 (Linux only): no copyright line in the package; authors: David Tolnay +- `atoi_simd` 0.18.1: Copyright 2022-NOW Dmitry Rodionov; Copyright (c) 2022 Dmitry Rodionov +- `bitflags` 2.13.2: Copyright (c) 2014 The Rust Project Developers +- `block-buffer` 0.10.4: Copyright (c) 2018-2019 The RustCrypto Project Developers +- `block-padding` 0.3.3: Copyright (c) 2018-2019 The RustCrypto Project Developers +- `bumpalo` 3.20.3: Copyright (c) 2019 Nick Fitzgerald +- `cbc` 0.1.2: Copyright (c) 2018-2022 RustCrypto Developers; Copyright (c) 2018 Artyom Pavlov +- `cff-parser` 0.2.0: Copyright (c) 2018 Yevhenii Reizner +- `cfg-if` 1.0.5: Copyright (c) 2014 Alex Crichton +- `chacha20` 0.10.2: Copyright (c) 2019-2026 The RustCrypto Project Developers +- `chrono` 0.4.45: Copyright (c) 2014, Kang Seonghoon. +- `cipher` 0.4.4: Copyright (c) 2016-2020 RustCrypto Developers +- `cpufeatures` 0.2.17: Copyright (c) 2020-2025 The RustCrypto Project Developers +- `cpufeatures` 0.3.1: Copyright (c) 2020-2026 The RustCrypto Project Developers +- `crc32fast` 1.5.4: Copyright (c) 2018 Sam Rijs, Alex Crichton and contributors +- `crossbeam-utils` 0.8.23 (Linux only): Copyright (c) 2019 The Crossbeam Project Developers +- `crypto-common` 0.1.7: Copyright (c) 2021 RustCrypto Developers +- `debug_unsafe` 0.1.4: Copyright 2025-NOW Dmitry Rodionov; Copyright (c) 2025 Dmitry Rodionov +- `digest` 0.10.7: Copyright (c) 2017 Artyom Pavlov +- `displaydoc` 0.2.7: no copyright line in the package; authors: Jane Lusby +- `document-features` 0.2.12: Copyright (c) 2020 Olivier Goffart +- `ecolor` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt , Andreas Reich +- `eframe` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `egui` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `egui-winit` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `egui_extras` 0.33.3: no copyright line in the package; authors: Dominik Rössler , Emil Ernerfeldt , René Rössler +- `egui_glow` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `emath` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `enum-map` 2.7.3: no copyright line in the package; authors: Kamila Borowska +- `enum-map-derive` 0.17.0: no copyright line in the package; authors: Kamila Borowska +- `enumflags2` 0.7.12 (Linux only): Copyright 2017-2023 Maik Klein, Maja Kądziołka; Copyright (c) 2017-2023 Maik Klein, Maja Kądziołka +- `enumflags2_derive` 0.7.12 (Linux only): Copyright (c) 2017 Maik Klein +- `epaint` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt +- `errno` 0.3.14 (Linux only): Copyright (c) 2014 Chris Wong +- `fast-float2` 0.2.4: Copyright 2021 Ivan Smirnov +- `fdeflate` 0.3.7: no copyright line in the package; authors: The image-rs Developers +- `flate2` 1.1.10: Copyright (c) 2014-2026 Alex Crichton +- `form_urlencoded` 1.2.2: Copyright (c) 2013-2016 The rust-url developers +- `futures-channel` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `futures-core` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `futures-io` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `futures-macro` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `futures-task` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `futures-util` 0.3.34 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `getrandom` 0.3.4 (Linux only): Copyright (c) 2018-2025 The rust-random Project Developers; Copyright (c) 2014 The Rust Project Developers +- `getrandom` 0.4.3: Copyright (c) 2018-2026 The rust-random Project Developers; Copyright (c) 2014 The Rust Project Developers +- `hashbrown` 0.15.5: Copyright (c) 2016 Amanieu d'Antras +- `hashbrown` 0.17.1: Copyright (c) 2016 Amanieu d'Antras +- `hashlink` 0.10.0: no copyright line in the package; authors: kyren +- `hex` 0.4.3 (Linux only): Copyright (c) 2013-2014 The Rust Project Developers.; Copyright (c) 2015-2020 The rust-hex Developers +- `iana-time-zone` 0.1.65 (Linux only): Copyright 2020 Andrew Straw; Copyright (c) 2020 Andrew D. Straw +- `idna` 1.1.0: Copyright (c) 2013-2025 The rust-url developers +- `image` 0.25.10: no copyright line in the package; authors: The image-rs Developers +- `inout` 0.1.4: Copyright (c) 2022 The RustCrypto Project Developers; Copyright (c) 2022 Artyom Pavlov +- `itoa` 1.0.18: no copyright line in the package; authors: David Tolnay +- `libc` 0.2.191 (Linux only): Copyright (c) The Rust Project Developers +- `litrs` 1.0.1: Copyright (c) 2020 Project Developers +- `lock_api` 0.4.14: Copyright (c) 2016 The Rust Project Developers +- `log` 0.4.35: Copyright (c) 2014 The Rust Project Developers +- `md-5` 0.10.6: Copyright (c) 2006-2009 Graydon Hoare; Copyright (c) 2009-2013 Mozilla Foundation; Copyright (c) 2016 Artyom Pavlov +- `memmap2` 0.9.12 (Linux only): Copyright (c) 2020 Yevhenii Reizner; Copyright (c) 2015 Dan Burkert +- `mime` 0.3.17: Copyright (c) 2014 Sean McArthur +- `native-tls` 0.2.18: Copyright (c) 2016 The rust-native-tls Developers +- `num-bigint` 0.4.8: Copyright (c) 2014 The Rust Project Developers +- `num-integer` 0.1.47: Copyright (c) 2014 The Rust Project Developers +- `num-rational` 0.4.2: Copyright (c) 2014 The Rust Project Developers +- `num-traits` 0.2.19: Copyright (c) 2014 The Rust Project Developers +- `once_cell` 1.21.4: no copyright line in the package; authors: Aleksey Kladov +- `openssl-probe` 0.2.2 (Linux only): Copyright (c) 2014 Alex Crichton +- `ordered-stream` 0.2.0 (Linux only): no copyright line in the package; authors: Daniel De Graaf , Zeeshan Ali Khan +- `parking_lot` 0.12.5: Copyright (c) 2016 The Rust Project Developers +- `parking_lot_core` 0.9.12: Copyright (c) 2016 The Rust Project Developers +- `pdf-writer` 0.15.0: no copyright line in the package; authors: Laurenz , Martin Haug +- `percent-encoding` 2.3.2: Copyright (c) 2013-2025 The rust-url developers +- `piper` 0.2.5 (Linux only): no copyright line in the package; authors: Stjepan Glavina , John Nunley +- `png` 0.18.1: Copyright (c) 2015 nwin +- `ppv-lite86` 0.2.21 (Linux only): Copyright 2019 The CryptoCorrosion Contributors; Copyright (c) 2019 The CryptoCorrosion Contributors +- `proc-macro-crate` 3.5.0 (Linux only): no copyright line in the package; authors: Bastian Köcher +- `proc-macro2` 1.0.107: no copyright line in the package; authors: David Tolnay , Alex Crichton +- `profiling` 1.0.18: no copyright line in the package; authors: Philip Degarmo +- `quote` 1.0.47: no copyright line in the package; authors: David Tolnay +- `rand` 0.10.3: Copyright 2018 Developers of the Rand project; Copyright (c) 2014 The Rust Project Developers +- `rand` 0.9.5 (Linux only): Copyright 2018 Developers of the Rand project; Copyright (c) 2014 The Rust Project Developers +- `rand_chacha` 0.9.0 (Linux only): Copyright 2018 Developers of the Rand project; Copyright (c) 2014 The Rust Project Developers +- `rand_core` 0.10.1: Copyright (c) 2018-2026 The Rand Project Developers +- `rand_core` 0.9.5 (Linux only): Copyright 2018 Developers of the Rand project; Copyright (c) 2014 The Rust Project Developers +- `rust_xlsxwriter` 0.102.0: Copyright 2022-2026 John McNamara +- `rustversion` 1.0.23: no copyright line in the package; authors: David Tolnay +- `scopeguard` 1.2.0: Copyright (c) 2016-2019 Ulrik Sverdrup "bluss" and scopeguard developers +- `serde` 1.0.229: no copyright line in the package; authors: Erick Tryzelaar , David Tolnay +- `serde_core` 1.0.229: no copyright line in the package; authors: Erick Tryzelaar , David Tolnay +- `serde_derive` 1.0.229: no copyright line in the package; authors: Erick Tryzelaar , David Tolnay +- `serde_json` 1.0.154: no copyright line in the package; authors: the serde_json developers +- `serde_repr` 0.1.21 (Linux only): no copyright line in the package; authors: David Tolnay +- `sha2` 0.10.9: Copyright (c) 2006-2009 Graydon Hoare; Copyright (c) 2009-2013 Mozilla Foundation; Copyright (c) 2016 Artyom Pavlov +- `signal-hook-registry` 1.4.8 (Linux only): Copyright (c) 2017 tokio-jsonrpc developers +- `simdutf8` 0.1.5: no copyright line in the package; authors: Hans Kratz +- `smallvec` 1.16.4: Copyright (c) 2018 The Servo Project Developers +- `smol_str` 0.2.2: no copyright line in the package; authors: Aleksey Kladov +- `stable_deref_trait` 1.2.1: Copyright (c) 2017 Robert Grosse +- `static_assertions` 1.1.0: Copyright (c) 2017 Nikolai Vazquez +- `syn` 2.0.119: no copyright line in the package; authors: David Tolnay +- `syn` 3.0.9: no copyright line in the package; authors: David Tolnay +- `tempfile` 3.27.0: Copyright (c) 2015 Steven Allen +- `thiserror` 1.0.69 (Linux only): no copyright line in the package; authors: David Tolnay +- `thiserror` 2.0.21: no copyright line in the package; authors: David Tolnay +- `thiserror-impl` 1.0.69 (Linux only): no copyright line in the package; authors: David Tolnay +- `thiserror-impl` 2.0.21: no copyright line in the package; authors: David Tolnay +- `toml_datetime` 1.1.2+spec-1.1.0: Copyright Individual contributors; Copyright (c) Individual contributors +- `toml_edit` 0.25.18+spec-1.1.0: Copyright Individual contributors; Copyright (c) Individual contributors +- `toml_parser` 1.1.5+spec-1.1.0: Copyright Individual contributors; Copyright (c) Individual contributors +- `toml_writer` 1.2.0+spec-1.1.0: Copyright Individual contributors; Copyright (c) Individual contributors +- `ttf-parser` 0.25.1: Copyright (c) 2018 Yevhenii Reizner +- `typed-path` 0.13.0: no copyright line in the package; authors: Chip Senkbeil +- `typenum` 1.20.1: Copyright 2014 Paho Lurie-Gregg; Copyright (c) 2014 Paho Lurie-Gregg +- `unicase` 2.10.0: Copyright (c) 2014-2026 Sean McArthur +- `unicode-bidi` 0.3.18: Copyright (c) 2015 The Rust Project Developers +- `unicode-segmentation` 1.13.3: Copyright (c) 2015 The Rust Project Developers +- `url` 2.5.8: Copyright (c) 2013-2025 The rust-url developers +- `web-time` 1.1.0: Copyright 2023 dAxpeDDa; Copyright (c) 2023 dAxpeDDa +- `webbrowser` 1.2.6: Copyright (c) 2015-2022 Amod Malviya +- `weezl` 0.1.12: Copyright (c) HeroicKatora 2020 +- `windows-link` 0.2.1 (Windows only): Copyright (c) Microsoft Corporation. +- `windows-sys` 0.52.0 (Windows only): Copyright (c) Microsoft Corporation. +- `windows-sys` 0.59.0 (Windows only): Copyright (c) Microsoft Corporation. +- `windows-sys` 0.61.2 (Windows only): Copyright (c) Microsoft Corporation. +- `windows-targets` 0.52.6 (Windows only): Copyright (c) Microsoft Corporation. +- `windows_x86_64_msvc` 0.52.6 (Windows only): Copyright (c) Microsoft Corporation. +- `x11rb` 0.13.2 (Linux only): Copyright 2019 x11rb Contributers +- `x11rb-protocol` 0.13.2 (Linux only): Copyright 2019 x11rb Contributers + +#### MIT (60 crates) + +- `adobe-cmap-parser` 0.4.1: no copyright line in the package; authors: Jeff Muizelaar +- `ashpd` 0.11.1 (Linux only): Copyright (c) 2020 Bilal Elmoussaoui +- `calamine` 0.38.0: Copyright (c) 2016 Johann Tuffe +- `calloop` 0.13.0 (Linux only): Copyright (c) 2018 Victor Berger +- `calloop` 0.14.5 (Linux only): Copyright (c) 2018 Victor Berger +- `calloop-wayland-source` 0.3.0 (Linux only): Copyright (c) 2023 Kirill Chibisov +- `calloop-wayland-source` 0.4.1 (Linux only): Copyright (c) 2023 Kirill Chibisov +- `dlib` 0.5.3 (Linux only): Copyright (c) 2015 Victor Berger +- `ecb` 0.1.2: Copyright (c) magic-akari +- `endi` 1.1.1 (Linux only): no copyright line in the package; authors: Zeeshan Ali Khan +- `generic-array` 0.14.7: Copyright (c) 2015 Bartłomiej Kamiński +- `glutin-winit` 0.5.0: Copyright © 2022 Kirill Chibisov +- `libsqlite3-sys` 0.35.0: Copyright (c) 2014 The rusqlite developers +- `lopdf` 0.42.0: Copyright (c) 2016 Junfeng Liu +- `memoffset` 0.9.1: Copyright (c) 2017 Gilad Naaman +- `mime_guess2` 2.3.1: Copyright (c) 2015 Austin Bonander +- `nom` 8.0.0: Copyright (c) 2014-2019 Geoffroy Couprie +- `openssl-sys` 0.9.118 (Linux only): Copyright (c) 2014 Alex Crichton +- `pdf-extract` 0.12.1: no copyright line in the package; authors: Jeff Muizelaar +- `pom` 1.1.0: Copyright (c) 2016 Junfeng Liu +- `quick-xml` 0.41.0 (Linux only): Copyright (c) 2016 Johann Tuffe +- `quick-xml` 0.42.0: Copyright (c) 2016 Johann Tuffe +- `rfd` 0.15.4: Copyright (c) 2022 Bartłomiej Maryńczak +- `rusqlite` 0.37.0: Copyright (c) 2014 The rusqlite developers +- `schannel` 0.1.30 (Windows only): Copyright (c) 2015 steffengy +- `simd-adler32` 0.3.10: Copyright (c) [2021] [Marvin Countryman] +- `slab` 0.4.12 (Linux only): Copyright (c) 2019 Carl Lerche +- `smithay-client-toolkit` 0.19.2 (Linux only): Copyright (c) 2018 Victor Berger +- `smithay-client-toolkit` 0.20.0 (Linux only): Copyright (c) 2018 Victor Berger +- `smithay-clipboard` 0.7.3 (Linux only): Copyright (c) 2018 Lucas Timmins & Victor Berger +- `synstructure` 0.14.0: Copyright 2016 Nika Layzell +- `tracing` 0.1.44: Copyright (c) 2019 Tokio Contributors +- `tracing-attributes` 0.1.31 (Linux only): Copyright (c) 2019 Tokio Contributors +- `tracing-core` 0.1.36: Copyright (c) 2019 Tokio Contributors +- `type1-encoding-parser` 0.1.1: no copyright line in the package; authors: Jeff Muizelaar +- `urlencoding` 2.1.3 (Linux only): © 2016 Bertram Truong; © 2021 Kornel Lesiński +- `wayland-backend` 0.3.17 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-client` 0.31.15 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-csd-frame` 0.3.0 (Linux only): Copyright (c) 2023 Kirill Chibisov +- `wayland-cursor` 0.31.14 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-protocols` 0.32.13 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-protocols-experimental` 20250721.0.1 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-protocols-misc` 0.3.12 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-protocols-plasma` 0.3.12 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-protocols-wlr` 0.3.12 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-scanner` 0.31.11 (Linux only): Copyright (c) 2015 Elinor Berger +- `wayland-sys` 0.31.11 (Linux only): Copyright (c) 2015 Elinor Berger +- `winnow` 1.0.4: no copyright line in the package; authors: the winnow developers +- `x11-dl` 2.21.0 (Linux only): no copyright line in the package; authors: daggerbot , Erle Pereira , AltF02 +- `xcursor` 0.3.11 (Linux only): Copyright (c) 2020 Samuele Esposito +- `xkbcommon-dl` 0.4.2 (Linux only): Copyright (c) 2023 Kirill Chibisov +- `zbus` 5.19.0 (Linux only): Copyright (c) 2024 Zeeshan Ali Khan & zbus contributors +- `zbus_macros` 5.19.0 (Linux only): Copyright (c) 2024 Zeeshan Ali Khan & zbus contributors +- `zbus_names` 4.3.5 (Linux only): Copyright (c) 2024 Zeeshan Ali Khan & zbus contributors +- `zcheapstr` 1.2.0 (Linux only): Copyright (c) 2026 Zeeshan Ali Khan & zcheapstr contributors +- `zip` 9.3.0: Copyright (c) 2014 Mathijs van de Nes +- `zmij` 1.0.23: no copyright line in the package; authors: David Tolnay +- `zvariant` 5.15.1 (Linux only): Copyright (c) 2024 Zeeshan Ali Khan & zbus contributors +- `zvariant_derive` 5.15.1 (Linux only): Copyright (c) 2024 Zeeshan Ali Khan & zbus contributors +- `zvariant_utils` 4.2.0 (Linux only): no copyright line in the package; authors: Zeeshan Ali Khan , turbocooler + +#### Apache-2.0 OR MIT (28 crates) + +- `async-channel` 2.5.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-executor` 1.14.1 (Linux only): no copyright line in the package; authors: Stjepan Glavina , John Nunley +- `async-fs` 2.2.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-io` 2.6.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-lock` 3.5.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-net` 2.0.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-process` 2.5.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `async-signal` 0.2.14 (Linux only): no copyright line in the package; authors: John Nunley +- `async-task` 4.7.1 (Linux only): no copyright line in the package; authors: Stjepan Glavina +- `atomic-waker` 1.1.2 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `blocking` 1.7.0 (Linux only): no copyright line in the package; authors: the blocking developers +- `codepage` 0.1.3: Copyright Mozilla Foundation +- `concurrent-queue` 2.5.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina , Taiki Endo , John Nunley +- `equivalent` 1.0.3: Copyright (c) 2016--2023 +- `event-listener` 5.4.2 (Linux only): no copyright line in the package; authors: Stjepan Glavina , John Nunley +- `event-listener-strategy` 0.5.4 (Linux only): no copyright line in the package; authors: John Nunley +- `fastrand` 2.5.0: no copyright line in the package; authors: Stjepan Glavina +- `futures-lite` 2.6.1 (Linux only): Copyright (c) 2016 Alex Crichton; Copyright (c) 2017 The Tokio Authors +- `idna_adapter` 1.2.2: Copyright (c) The rust-url developers +- `indexmap` 2.14.2: Copyright (c) 2016--2017 +- `multiversion_no_op` 1.0.0: Copyright Mozilla Foundation +- `nohash-hasher` 0.2.0: Copyright 2018 Parity Technologies (UK) Ltd. +- `parking` 2.2.1 (Linux only): Copyright 2014-2020 The Rust Project Developers +- `pin-project-lite` 0.2.17: no copyright line in the package; authors: the pin-project-lite developers +- `polling` 3.11.0 (Linux only): no copyright line in the package; authors: Stjepan Glavina , John Nunley +- `utf8_iter` 1.1.0: Copyright Mozilla Foundation +- `utf_types` 1.0.0: Copyright Mozilla Foundation +- `uuid` 1.29.0 (Linux only): Copyright (c) 2014 The Rust Project Developers; Copyright (c) 2018 Ashley Mannix, Christopher Armstrong, Dylan DPC, Hunar Roop Kahlon + +#### Unicode-3.0 (18 crates) + +- `icu_collections` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_locale_core` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_normalizer` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_normalizer_data` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_properties` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_properties_data` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `icu_provider` 2.4.0: Copyright © 2020-2024 Unicode, Inc. +- `litemap` 0.8.3: Copyright © 2020-2024 Unicode, Inc. +- `potential_utf` 0.1.6: Copyright © 2020-2024 Unicode, Inc. +- `tinystr` 0.8.5: Copyright © 2020-2024 Unicode, Inc. +- `writeable` 0.6.4: Copyright © 2020-2024 Unicode, Inc. +- `yoke` 0.8.4: Copyright © 2020-2024 Unicode, Inc. +- `yoke-derive` 0.8.4: Copyright © 2020-2024 Unicode, Inc. +- `zerofrom` 0.1.8: Copyright © 2020-2024 Unicode, Inc. +- `zerofrom-derive` 0.1.8: Copyright © 2020-2024 Unicode, Inc. +- `zerotrie` 0.2.5: Copyright © 2020-2024 Unicode, Inc. +- `zerovec` 0.11.9: Copyright © 2020-2024 Unicode, Inc. +- `zerovec-derive` 0.11.7: Copyright © 2020-2024 Unicode, Inc. + +#### Apache-2.0 (11 crates) + +- `ab_glyph` 0.2.32: no copyright line in the package; authors: Alex Butler +- `ab_glyph_rasterizer` 0.1.10: no copyright line in the package; authors: Alex Butler +- `gethostname` 1.1.0 (Linux only): no copyright line in the package; authors: Sebastian Wiesner +- `glutin` 0.32.3: Copyright 2022 Kirill Chibisov +- `glutin_egl_sys` 0.7.1: Copyright 2022 Kirill Chibisov +- `glutin_glx_sys` 0.6.1 (Linux only): Copyright 2022 Kirill Chibisov +- `glutin_wgl_sys` 0.6.1 (Windows only): Copyright 2022 Kirill Chibisov +- `openssl` 0.10.82 (Linux only): Copyright 2011-2017 Google Inc. +- `owned_ttf_parser` 0.25.1: no copyright line in the package; authors: Alex Butler +- `winit` 0.30.13: no copyright line in the package; authors: The winit contributors, Pierre Krieger +- `zopfli` 0.8.4: Copyright 2011 Google Inc. + +#### MIT/Apache-2.0 (10 crates) + +- `core_detect` 1.0.0: Copyright (c) 2017-2020 The Rust Project Developers +- `downcast-rs` 1.2.1 (Linux only): Copyright (c) 2020 Ashish Myles and contributors +- `fallible-iterator` 0.3.0: Copyright (c) 2015 The rust-openssl-verify Developers +- `fallible-streaming-iterator` 0.1.9: Copyright (c) 2016 The fallible-streaming-iterator Developers +- `foreign-types` 0.3.2 (Linux only): Copyright (c) 2017 The foreign-types Developers +- `foreign-types-shared` 0.1.1 (Linux only): Copyright (c) 2017 The foreign-types Developers +- `openssl-macros` 0.1.1 (Linux only): Copyright (c) 2022 Steven Fackler +- `rangemap` 1.8.0: Copyright 2019-2022 Jeff Parsons, and [contributors](https://github.com/jeffparsons/rangemap/contributors); Copyright 2019 Jeffrey Parsons +- `scoped-tls` 1.0.1 (Linux only): Copyright (c) 2014 Alex Crichton +- `stringprep` 0.1.5: Copyright (c) 2017 The rust-stringprep Developers + +#### Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT (4 crates) + +- `linux-raw-sys` 0.12.1 (Linux only): no copyright line in the package; authors: Dan Gohman +- `linux-raw-sys` 0.4.15 (Linux only): no copyright line in the package; authors: Dan Gohman +- `rustix` 0.38.44 (Linux only): no copyright line in the package; authors: Dan Gohman , Jakub Konka +- `rustix` 1.1.6 (Linux only): no copyright line in the package; authors: Dan Gohman , Jakub Konka + +#### MIT OR Apache-2.0 OR Zlib (4 crates) + +- `cursor-icon` 1.2.0: Copyright 2023 Kirill Chibisov; Copyright (c) 2023 Kirill Chibisov +- `glow` 0.16.0: no copyright line in the package; authors: Joshua Groves , Dzmitry Malyshau +- `raw-window-handle` 0.6.2: Copyright (c) 2019 Osspial; Copyright (c) 2020 Osspial +- `xkeysym` 0.2.1 (Linux only): Copyright 2022-2023 John Nunley; Copyright (c) 2022-2023 John Nunley + +#### (MIT OR Apache-2.0) AND Unicode-3.0 (3 crates) + +- `unicode-ident` 1.0.27: Copyright © 1991-2023 Unicode, Inc. +- `unicode-normalization` 0.1.26: Copyright (c) 2015 The Rust Project Developers; Copyright © 1991-2023 Unicode, Inc. +- `unicode-properties` 0.1.5: Copyright (c) 2015 The Rust Project Developers; Copyright © 1991-2026 Unicode, Inc. + +#### Unlicense OR MIT (3 crates) + +- `byteorder` 1.5.0: Copyright (c) 2015 Andrew Gallant +- `byteorder-lite` 0.1.0: Copyright (c) 2015 Andrew Gallant +- `memchr` 2.8.3: Copyright (c) 2015 Andrew Gallant + +#### Zlib OR Apache-2.0 OR MIT (3 crates) + +- `bytemuck` 1.25.2: Copyright (c) 2019 Daniel "Lokathor" Gee. +- `bytemuck_derive` 1.12.1: Copyright (c) 2019 Daniel "Lokathor" Gee. +- `tinyvec` 1.13.3: Copyright (c) 2019 Daniel "Lokathor" Gee. + +#### Apache-2.0/MIT (2 crates) + +- `pollster` 0.4.0 (Linux only): Copyright (c) 2020-2021 Joshua Barretto +- `postscript` 0.14.1: Copyright 2015-2022 The postscript Developers + +#### BSD-3-Clause OR Apache-2.0 (2 crates) + +- `moxcms` 0.8.1: Copyright 2024 Radzivon Bartoshyk; Copyright (c) Radzivon Bartoshyk. All rights reserved. +- `pxfm` 0.1.30: Copyright 2024 Radzivon Bartoshyk; Copyright (c) Radzivon Bartoshyk. All rights reserved. + +#### BSL-1.0 (2 crates) + +- `clipboard-win` 5.4.3 (Windows only): no copyright line in the package; authors: Douman +- `error-code` 3.4.0 (Windows only): no copyright line in the package; authors: Douman + +#### MIT OR Zlib OR Apache-2.0 (2 crates) + +- `miniz_oxide` 0.8.9: Copyright 2013-2014 RAD Game Tools and Valve Software; Copyright 2010-2014 Rich Geldreich and Tenacious Software LLC; Copyright (c) 2017 Frommi; Copyright (c) 2017-2024 oyvindln; Copyright (c) 2020 Frommi +- `miniz_oxide` 0.9.1: Copyright 2013-2014 RAD Game Tools and Valve Software; Copyright 2010-2014 Rich Geldreich and Tenacious Software LLC; Copyright (c) 2017 Frommi; Copyright (c) 2017-2024 oyvindln; Copyright (c) 2020 Frommi + +#### Zlib (2 crates) + +- `foldhash` 0.1.5: Copyright (c) 2024 Orson Peters +- `zlib-rs` 0.6.8: (C) 2024 Trifecta Tech Foundation + +#### (Apache-2.0 OR MIT) AND BSD-3-Clause (1 crate) + +- `encoding_rs` 0.8.44: Copyright Mozilla Foundation; Copyright © WHATWG (Apple, Google, Mozilla, Microsoft). + +#### (MIT OR Apache-2.0) AND OFL-1.1 AND Ubuntu-font-1.0 (1 crate) + +- `epaint_default_fonts` 0.33.3: no copyright line in the package; authors: Emil Ernerfeldt + +#### 0BSD OR MIT OR Apache-2.0 (1 crate) + +- `adler2` 2.0.1: Copyright (C) Jonas Schievink + +#### Apache-2.0 AND MIT (1 crate) + +- `dpi` 0.1.2: Copyright (c) 2018 Jorge Aparicio; Copyright © 2005-2020 Rich Felker, et al.; Copyright © 1993,2004 Sun Microsystems or; Copyright © 2003-2011 David Schultz or; Copyright © 2003-2009 Steven G. Kargl or; Copyright © 2003-2009 Bruce D. Evans or; Copyright © 2008 Stephen L. Moshier or; Copyright © 2017-2018 Arm Limited + +#### Apache-2.0 OR BSL-1.0 (1 crate) + +- `ryu` 1.0.23: no copyright line in the package; authors: David Tolnay + +#### BSD-2-Clause OR Apache-2.0 OR MIT (1 crate) + +- `zerocopy` 0.8.63: Copyright 2023 The Fuchsia Authors; Copyright 2019 The Fuchsia Authors. + +#### ISC (1 crate) + +- `libloading` 0.8.9: Copyright © 2015, Simonas Kazlauskas + +#### MIT / Apache-2.0 (1 crate) + +- `euclid` 0.20.14: Copyright (c) 2012-2013 Mozilla Foundation + +### License texts + +#### Apache-2.0 + +Each crate under this license is covered by this text with its own +copyright lines above. + +```text + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + +5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS + +APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + +Copyright [yyyy] [name of copyright owner] + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +``` + +#### MIT + +Each crate under this license is covered by this text with its own +copyright lines above. + +```text +Permission is hereby granted, free of charge, to any +person obtaining a copy of this software and associated +documentation files (the "Software"), to deal in the +Software without restriction, including without +limitation the rights to use, copy, modify, merge, +publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software +is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice +shall be included in all copies or substantial portions +of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF +ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED +TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A +PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT +SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. +``` + +#### Unicode-3.0 + +Each crate under this license is covered by this text with its own +copyright lines above. + +```text +UNICODE LICENSE V3 + +COPYRIGHT AND PERMISSION NOTICE + + +NOTICE TO USER: Carefully read the following legal agreement. BY +DOWNLOADING, INSTALLING, COPYING OR OTHERWISE USING DATA FILES, AND/OR +SOFTWARE, YOU UNEQUIVOCALLY ACCEPT, AND AGREE TO BE BOUND BY, ALL OF THE +TERMS AND CONDITIONS OF THIS AGREEMENT. IF YOU DO NOT AGREE, DO NOT +DOWNLOAD, INSTALL, COPY, DISTRIBUTE OR USE THE DATA FILES OR SOFTWARE. + +Permission is hereby granted, free of charge, to any person obtaining a +copy of data files and any associated documentation (the "Data Files") or +software and any associated documentation (the "Software") to deal in the +Data Files or Software without restriction, including without limitation +the rights to use, copy, modify, merge, publish, distribute, and/or sell +copies of the Data Files or Software, and to permit persons to whom the +Data Files or Software are furnished to do so, provided that either (a) +this copyright and permission notice appear with all copies of the Data +Files or Software, or (b) this copyright and permission notice appear in +associated Documentation. + +THE DATA FILES AND SOFTWARE ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY +KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF +THIRD PARTY RIGHTS. + +IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE +BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, +OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THE DATA +FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder shall +not be used in advertising or otherwise to promote the sale, use or other +dealings in these Data Files or Software without prior written +authorization of the copyright holder. + +SPDX-License-Identifier: Unicode-3.0 + +- + +Portions of ICU4X may have been adapted from ICU4C and/or ICU4J. +ICU 1.8.1 to ICU 57.1 © 1995-2016 International Business Machines Corporation and others. +``` + +### License and notice files reproduced per crate + +#### `adler2` 2.0.1: `LICENSE-0BSD` + +```text +Copyright (C) Jonas Schievink + +Permission to use, copy, modify, and/or distribute this software for +any purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN +AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT +OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +``` + +#### `bytemuck` 1.25.2: `LICENSE-ZLIB` + +```text +Copyright (c) 2019 Daniel "Lokathor" Gee. + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `bytemuck_derive` 1.12.1: `LICENSE-ZLIB` + +```text +Copyright (c) 2019 Daniel "Lokathor" Gee. + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `byteorder` 1.5.0: `COPYING` + +```text +This project is dual-licensed under the Unlicense and MIT licenses. + +You may use this code under the terms of either license. +``` + +#### `byteorder` 1.5.0: `UNLICENSE` + +```text +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to +``` + +#### `byteorder-lite` 0.1.0: `UNLICENSE` + +```text +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to +``` + +#### `chrono` 0.4.45: `LICENSE.txt` + +```text +Rust-chrono is dual-licensed under The MIT License [1] and +Apache 2.0 License [2]. Copyright (c) 2014--2026, Kang Seonghoon and +contributors. + +Nota Bene: This is same as the Rust Project's own license. + + +[1]: , which is reproduced below: + +~~~~ +The MIT License (MIT) + +Copyright (c) 2014, Kang Seonghoon. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. +~~~~ + + +[2]: , which is reproduced below: + +~~~~ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + +5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS + +APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + +Copyright [yyyy] [name of copyright owner] + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +~~~~ +``` + +#### `codepage` 0.1.3: `COPYRIGHT` + +```text +codepage is copyright 2018 Mozilla Foundation. + +Licensed under the Apache License, Version 2.0 + or the MIT +license , +at your option. All files in the project carrying such +notice may not be copied, modified, or distributed except +according to those terms. +``` + +#### `cursor-icon` 1.2.0: `LICENSE-ZLIB` + +```text +Copyright (c) 2023 Kirill Chibisov + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `encoding_rs` 0.8.44: `COPYRIGHT` + +```text +encoding_rs is copyright Mozilla Foundation. + +Licensed under the Apache License, Version 2.0 + or the MIT +license , +at your option. All files in the project carrying such +notice may not be copied, modified, or distributed except +according to those terms. + +This crate includes data derived from the data files supplied +with the WHATWG Encoding Standard, which, when incorporated into +source code, are licensed under the BSD 3-Clause License +. + +Test code within encoding_rs is dedicated to the Public Domain when so +designated (see the individual files for PD/CC0-dedicated sections). +``` + +#### `encoding_rs` 0.8.44: `LICENSE-WHATWG` + +```text +Copyright © WHATWG (Apple, Google, Mozilla, Microsoft). + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +#### `euclid` 0.20.14: `COPYRIGHT` + +```text +Licensed under the Apache License, Version 2.0 or the MIT license +, at your +option. All files in the project carrying such notice may not be +copied, modified, or distributed except according to those terms. +``` + +#### `foldhash` 0.1.5: `LICENSE` + +```text +Copyright (c) 2024 Orson Peters + +This software is provided 'as-is', without any express or implied warranty. In +no event will the authors be held liable for any damages arising from the use of +this software. + +Permission is granted to anyone to use this software for any purpose, including +commercial applications, and to alter it and redistribute it freely, subject to +the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim + that you wrote the original software. If you use this software in a product, + an acknowledgment in the product documentation would be appreciated but is + not required. + +2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `glow` 0.16.0: `LICENSE-ZLIB` + +```text +This software is provided 'as-is', without any express or implied +warranty. In no event will the authors be held liable for any damages +arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, +including commercial applications, and to alter it and redistribute it +freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. +2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. +3. This notice may not be removed or altered from any source distribution. +``` + +#### `libloading` 0.8.9: `LICENSE` + +```text +Copyright © 2015, Simonas Kazlauskas + +Permission to use, copy, modify, and/or distribute this software for any purpose with or without +fee is hereby granted, provided that the above copyright notice and this permission notice appear +in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS +SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE +AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, +NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +THIS SOFTWARE. +``` + +#### `linux-raw-sys` 0.12.1: `COPYRIGHT` + +```text +Short version for non-lawyers: + +`linux-raw-sys` is triple-licensed under Apache 2.0 with the LLVM Exception, +Apache 2.0, and MIT terms. + + +Longer version: + +Copyrights in the `linux-raw-sys` project are retained by their contributors. +No copyright assignment is required to contribute to the `linux-raw-sys` +project. + +Some files include code derived from Rust's `libstd`; see the comments in +the code for details. + +Except as otherwise noted (below and/or in individual files), `linux-raw-sys` +is licensed under: + + - the Apache License, Version 2.0, with the LLVM Exception + or + + - the Apache License, Version 2.0 + or + , + - or the MIT license + or + , + +at your option. +``` + +#### `linux-raw-sys` 0.4.15: `COPYRIGHT` + +```text +Short version for non-lawyers: + +`linux-raw-sys` is triple-licensed under Apache 2.0 with the LLVM Exception, +Apache 2.0, and MIT terms. + + +Longer version: + +Copyrights in the `linux-raw-sys` project are retained by their contributors. +No copyright assignment is required to contribute to the `linux-raw-sys` +project. + +Some files include code derived from Rust's `libstd`; see the comments in +the code for details. + +Except as otherwise noted (below and/or in individual files), `linux-raw-sys` +is licensed under: + + - the Apache License, Version 2.0, with the LLVM Exception + or + + - the Apache License, Version 2.0 + or + , + - or the MIT license + or + , + +at your option. +``` + +#### `memchr` 2.8.3: `COPYING` + +```text +This project is dual-licensed under the Unlicense and MIT licenses. + +You may use this code under the terms of either license. +``` + +#### `memchr` 2.8.3: `UNLICENSE` + +```text +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to +``` + +#### `miniz_oxide` 0.8.9: `LICENSE-ZLIB.md` + +```text +Copyright 2013-2014 RAD Game Tools and Valve Software +Copyright 2010-2014 Rich Geldreich and Tenacious Software LLC +Copyright (c) 2020 Frommi +Copyright (c) 2017-2024 oyvindln + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `miniz_oxide` 0.9.1: `LICENSE-ZLIB.md` + +```text +Copyright 2013-2014 RAD Game Tools and Valve Software +Copyright 2010-2014 Rich Geldreich and Tenacious Software LLC +Copyright (c) 2020 Frommi +Copyright (c) 2017-2024 oyvindln + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `moxcms` 0.8.1: `LICENSE.md` + +```text +Copyright (c) Radzivon Bartoshyk. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +#### `multiversion_no_op` 1.0.0: `COPYRIGHT` + +```text +Copyright Mozilla Foundation + +Licensed under the Apache License (Version 2.0), or the MIT license, +(the "Licenses") at your option. You may not use this file except in +compliance with one of the Licenses. You may obtain copies of the +Licenses at: + + https://www.apache.org/licenses/LICENSE-2.0 + https://opensource.org/licenses/MIT + +Unless required by applicable law or agreed to in writing, software +distributed under the Licenses is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the Licenses for the specific language governing permissions and +limitations under the Licenses. +``` + +#### `openssl` 0.10.82: `LICENSE` + +```text +Copyright 2011-2017 Google Inc. + 2013 Jack Lloyd + 2013-2014 Steven Fackler + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +``` + +#### `parking` 2.2.1: `LICENSE-THIRD-PARTY` + +```text +=============================================================================== + +Copyright 2014-2020 The Rust Project Developers + +Licensed under the Apache License, Version 2.0 or the MIT license +, at your +option. All files in the project carrying such notice may not be +copied, modified, or distributed except according to those terms. +``` + +#### `pxfm` 0.1.30: `LICENSE.md` + +```text +Copyright (c) Radzivon Bartoshyk. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +#### `rand` 0.10.3: `COPYRIGHT` + +```text +Copyrights in the Rand project are retained by their contributors. No +copyright assignment is required to contribute to the Rand project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), Rand is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. + +The Rand project includes code from the Rust project +published under these same licenses. +``` + +#### `rand` 0.9.5: `COPYRIGHT` + +```text +Copyrights in the Rand project are retained by their contributors. No +copyright assignment is required to contribute to the Rand project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), Rand is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. + +The Rand project includes code from the Rust project +published under these same licenses. +``` + +#### `rand_chacha` 0.9.0: `COPYRIGHT` + +```text +Copyrights in the Rand project are retained by their contributors. No +copyright assignment is required to contribute to the Rand project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), Rand is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. + +The Rand project includes code from the Rust project +published under these same licenses. +``` + +#### `rand_core` 0.10.1: `COPYRIGHT` + +```text +Copyrights in the Rand project are retained by their contributors. No +copyright assignment is required to contribute to the Rand project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), Rand is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. +``` + +#### `rand_core` 0.9.5: `COPYRIGHT` + +```text +Copyrights in the Rand project are retained by their contributors. No +copyright assignment is required to contribute to the Rand project. + +For full authorship information, see the version control history. + +Except as otherwise noted (below and/or in individual files), Rand is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. + +The Rand project includes code from the Rust project +published under these same licenses. +``` + +#### `raw-window-handle` 0.6.2: `LICENSE-ZLIB.md` + +```text +Copyright (c) 2020 Osspial + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `rustix` 0.38.44: `COPYRIGHT` + +```text +Short version for non-lawyers: + +`rustix` is triple-licensed under Apache 2.0 with the LLVM Exception, +Apache 2.0, and MIT terms. + + +Longer version: + +Copyrights in the `rustix` project are retained by their contributors. +No copyright assignment is required to contribute to the `rustix` +project. + +Some files include code derived from Rust's `libstd`; see the comments in +the code for details. + +Except as otherwise noted (below and/or in individual files), `rustix` +is licensed under: + + - the Apache License, Version 2.0, with the LLVM Exception + or + + - the Apache License, Version 2.0 + or + , + - or the MIT license + or + , + +at your option. +``` + +#### `rustix` 1.1.6: `COPYRIGHT` + +```text +Short version for non-lawyers: + +`rustix` is triple-licensed under Apache 2.0 with the LLVM Exception, +Apache 2.0, and MIT terms. + + +Longer version: + +Copyrights in the `rustix` project are retained by their contributors. +No copyright assignment is required to contribute to the `rustix` +project. + +Some files include code derived from Rust's `libstd`; see the comments in +the code for details. + +Except as otherwise noted (below and/or in individual files), `rustix` +is licensed under: + + - the Apache License, Version 2.0, with the LLVM Exception + or + + - the Apache License, Version 2.0 + or + , + - or the MIT license + or + , + +at your option. +``` + +#### `tinyvec` 1.13.3: `LICENSE-ZLIB.md` + +```text +Copyright (c) 2019 Daniel "Lokathor" Gee. + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `typenum` 1.20.1: `LICENSE` + +```text +MIT OR Apache-2.0 +``` + +#### `unicode-bidi` 0.3.18: `COPYRIGHT` + +```text +This project is copyright 2015, The Servo Project Developers (given in the +file AUTHORS). + +Licensed under the Apache License, Version 2.0 or the MIT license , at your option. All files in the project +carrying such notice may not be copied, modified, or distributed except +according to those terms. +``` + +#### `unicode-normalization` 0.1.26: `COPYRIGHT` + +```text +Licensed under the Apache License, Version 2.0 + or the MIT +license , +at your option. All files in the project carrying such +notice may not be copied, modified, or distributed except +according to those terms. +``` + +#### `unicode-properties` 0.1.5: `COPYRIGHT` + +```text +Licensed under the Apache License, Version 2.0 + or the MIT +license , +at your option. All files in the project carrying such +notice may not be copied, modified, or distributed except +according to those terms. +``` + +#### `unicode-segmentation` 1.13.3: `COPYRIGHT` + +```text +Licensed under the Apache License, Version 2.0 + or the MIT +license , +at your option. All files in the project carrying such +notice may not be copied, modified, or distributed except +according to those terms. +``` + +#### `utf8_iter` 1.1.0: `COPYRIGHT` + +```text +Copyright Mozilla Foundation + +Licensed under the Apache License (Version 2.0), or the MIT license, +(the "Licenses") at your option. You may not use this file except in +compliance with one of the Licenses. You may obtain copies of the +Licenses at: + + https://www.apache.org/licenses/LICENSE-2.0 + https://opensource.org/licenses/MIT + +Unless required by applicable law or agreed to in writing, software +distributed under the Licenses is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the Licenses for the specific language governing permissions and +limitations under the Licenses. + +-- + +Test code is dedicated to the Public Domain when so designated (see +the individual files for PD/CC0-dedicated sections). + +-- + +The implementation for Utf8CharIndices was adapted from the +CharIndices implementation of the Rust standard library at revision +ab32548539ec38a939c1b58599249f3b54130026 +(https://github.com/rust-lang/rust/blob/ab32548539ec38a939c1b58599249f3b54130026/library/core/src/str/iter.rs). + +Excerpt from https://github.com/rust-lang/rust/blob/ab32548539ec38a939c1b58599249f3b54130026/COPYRIGHT , +which refers to +https://github.com/rust-lang/rust/blob/ab32548539ec38a939c1b58599249f3b54130026/LICENSE-APACHE +and +https://github.com/rust-lang/rust/blob/ab32548539ec38a939c1b58599249f3b54130026/LICENSE-MIT +: + +For full authorship information, see the version control history or +https://thanks.rust-lang.org + +Except as otherwise noted (below and/or in individual files), Rust is +licensed under the Apache License, Version 2.0 or + or the MIT license + or , at your option. +``` + +#### `utf_types` 1.0.0: `COPYRIGHT` + +```text +Copyright Mozilla Foundation + +Licensed under the Apache License (Version 2.0), or the MIT license, +(the "Licenses") at your option. You may not use this file except in +compliance with one of the Licenses. You may obtain copies of the +Licenses at: + + https://www.apache.org/licenses/LICENSE-2.0 + https://opensource.org/licenses/MIT + +Unless required by applicable law or agreed to in writing, software +distributed under the Licenses is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the Licenses for the specific language governing permissions and +limitations under the Licenses. + +-- + +Test code is dedicated to the Public Domain when so designated (see +the individual files for PD/CC0-dedicated sections). +``` + +#### `xkeysym` 0.2.1: `LICENSE-ZLIB` + +```text +Copyright (c) 2022-2023 John Nunley + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + +#### `zerocopy` 0.8.63: `LICENSE-BSD` + +```text +Copyright 2019 The Fuchsia Authors. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +#### `zlib-rs` 0.6.8: `LICENSE` + +```text +(C) 2024 Trifecta Tech Foundation + +This software is provided 'as-is', without any express or implied +warranty. In no event will the authors be held liable for any damages +arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, +including commercial applications, and to alter it and redistribute it +freely, subject to the following restrictions: + +1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + +2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + +3. This notice may not be removed or altered from any source distribution. +``` + + diff --git a/assets/icons/16/ACCUNT16.png b/assets/icons/16/ACCUNT16.png new file mode 100644 index 0000000000000000000000000000000000000000..c7a24eeb0500c664c335bfc3fc0572715a9682a0 GIT binary patch literal 304 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`-#uL%Ln`JZ&xz8xbKt~*h_gWA zPy_Fu^dFz+KdjF#dw-iP=aP=X+0LVLb=Ks(iTL{e-`B~hb@`R1%*@PX%n}lk2WHjV zMm1e!Fxx4?HfJ5Pbi0>5+bq6b_+^FLhB&nV8<1rlz7cai0o|f) zG4Eg?YiDP0y557UDQQU!1`5)X4jt%Z5eqoM#j&e_k^8_?rX04-3yS{#|M~Z~Ik%$t zpMQU)*N7cv2)N@n*K)m-*r6SaDzXp4o%ImdKI;Vst0GIQF Aga7~l literal 0 HcmV?d00001 diff --git a/assets/icons/16/ACTCTP16.png b/assets/icons/16/ACTCTP16.png new file mode 100644 index 0000000000000000000000000000000000000000..66d3ac63f87f2473bcfb201ad5b155e5440ff15f GIT binary patch literal 287 zcmV+)0pR|LP){8?o}GH@5XxUh>T zL!>477^Eb$81CGAn{f8xlZdIs!ksLz=pYs_GBPsoaI-ORak6pz`1wbk=r90*44Z&|NjiFOXp5(KrsNMdBMy+qAZS0EdU2B3$iH4=Cc>C6X|$HuwE8WJcFVNS2UU! zXffh-%72Fct>AbDM-?O{PMx`cqDb1d5i_wt6Br}1!kCnT{{=Z|7%q^pZThWl<<7## z&Cc-n%@2tFe}5TXUflZ!YXU)c0m$Z$-~Tf#C{brPeDwpv!adIz-hP6Jv!JT{|L6Db z-z;V(23Y;O{mfg2R1aweGc|sO>ViA%?vd-oe9wClKqoHormwE~N% z0jdFnz_EmNVCN#hI?@aPfyx}G|FY~CFZ^RtL zfaCnMQjz(y%7kR#E_iWa7fy|j<{7}9EG@~$ASI#2aOd9JgtHf)L`*Ff?qq>Q2eE*W zk&%Iin~i~sla1rY&p+}+hXDwD`1qaS^tmStPoIB0z{L2!G^_jV8KMo4<+#MKe(Ti- z4FCQYX7|0_z(6X9Nh$dMf4@D3g+#{!2rxPx{6moe*Z{=_003lEPLuCp(4GJQ002ov JPDHLkV1mWZiHQIJ literal 0 HcmV?d00001 diff --git a/assets/icons/16/ACTPRM16.png b/assets/icons/16/ACTPRM16.png new file mode 100644 index 0000000000000000000000000000000000000000..3f223a89ce969aa1beddf2f7e04c927cb89b44fa GIT binary patch literal 287 zcmV+)0pR|LP){8?o}GH@3>I&g<5 zL!>477^Eb$81CGAn{f8xlZdIs!ksLz=pYs_GBPsoaI-ORak6pz`1wbk=r90*4IvRmuyxpbP0l+XkKqA@7V literal 0 HcmV?d00001 diff --git a/assets/icons/16/ACTRJP16.png b/assets/icons/16/ACTRJP16.png new file mode 100644 index 0000000000000000000000000000000000000000..08eaed57f8a0c1d5d9a938c7177385892f24347c GIT binary patch literal 287 zcmV+)0pR|LP){8?o}GH@4cc=U`Y zL!>477^Eb$81CGAn{f8xlZdIs!ksLz=pYs_GBPsoaI-ORak6pz`1wbk=r90*4e&`3{1EXF(!)T`K?RJ_0Si7& zvWfaw#n-%C1ETJOk^u`bHe=&II&g?!IAx#!W)r&2Fo4$ukLO93v(SONrDPQ*$svctyTVbe|DJuM+X|olVK${?g&l1ZSY-}4EPX6bq4w&|s8YW06yE!$fDJ311IKVcgjsx{=wmK?N&nJZ$GM<}zHSocqBMyoQQXdQw6xfd}5&5%xmUu+LOdqk1gGmgE zhHgCvexBc;zWRHw_QoWh1ZFRnfB!2tv-CLT1Ra^7@yXam;J@)3MpbW#*(w_u*%>x9 WMG3sWR=pHxKZB>MpUXO@geCwQpgwB= literal 0 HcmV?d00001 diff --git a/assets/icons/16/APPLY16.png b/assets/icons/16/APPLY16.png new file mode 100644 index 0000000000000000000000000000000000000000..99d18d936ebc4ea8b331cc3b1c2b5285a611a331 GIT binary patch literal 305 zcmV-10nYx3P);XT;Or%H zCNQ!f2TV*#!T*AsG`NCOXD%?9nHXT@Pna?bH4KmyA%m!xI51sMP=r+;1%O*EMBORaIm7_wOGA6BEK-CUgTb zlOq{cESkv>9}|fp?(XW$;OXhbkewP0R)f<31}La1FJdq>G=gjH?`}o083s_&H7H=L zEX+_8T)TFaK|@0mL-Vl{rx57?T>>4PICTb>Ln#LUZ5V8zZe73;00000NkvXXu0mjf Dl;LpM literal 0 HcmV?d00001 diff --git a/assets/icons/16/ARHORZ16.png b/assets/icons/16/ARHORZ16.png new file mode 100644 index 0000000000000000000000000000000000000000..2060c555133683887800ef9ebae2eeebf35bcc83 GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`lRRA*!| zz}|Q70gtZS6A35haL({lVC!aVIU?bBWJ}V-yF5J?Tt3fF^bdP49iDVl;sD!}jz9lD zr*TR&-&oRNDEK-(hG7!lKjSwuuLd%dOL-+FF8 z4-PdjRL_%HRh+88w80^B`l?wvI})N#o1`56z@(NWdg%;dYYroge2nus_R@n7`_xg$Gk1XCDI#<1ALCqYMn9@g|*j^PhbM Px|G4w)z4*}Q$iB}w=`0* literal 0 HcmV?d00001 diff --git a/assets/icons/16/ASSIGN16.png b/assets/icons/16/ASSIGN16.png new file mode 100644 index 0000000000000000000000000000000000000000..d3c909d92eb32b1c7fb4bcacfa5b415a0664798d GIT binary patch literal 252 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`hdo^!Ln`JZCoB*!IJQLOk9z3k zNtVJAi8*2dffFXPO}8n1#?(Bsld+2}Wg};B+QJith5;NA31$m!ckpfKY;^STI#{1# zkbBNZ#BP^F)eOTxRk1ZXXEu1HEp<8QEUn&g@G)yjsS#(@|A~fP3V!o<%Nz|TvEw;m zxuW5vJNr9>1rifx%5*N0Ja*ozlj(NPS%VoC+#Mahx-JuK${vY?&EB}Ph1D{067vB) z1(t-mW0Gt?4oqg9en8KKpL>Qypq@iHrx63gju}0P-gmw(0D6bP)78&qol`;+0KB?d A%m4rY literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATV16.png b/assets/icons/16/ATV16.png new file mode 100644 index 0000000000000000000000000000000000000000..51739f3982c588fd710ff20f4f0993285ee4da9a GIT binary patch literal 124 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`&YmugAr*6y6C_xB6r9u?-`iWx zny<6t$O)#$Tc%u{uw>`5)vP|753r=ojdJW$mY8wklIaSbghoR-*&WU+BNsO``YXJGgM6Jum#IPj9|O=@E!!yke+Oe+;xY~ko1qo}SA7dyFc zBg4I$7uUSxeiKPB3>g12sEA9+Gc2Fp#K6lh1jbJO@eE4p`XS<9MV1pZ;2#5n3J<>! zLt4cIxEK=?6N8$r83V)r|0)CxU}E^c=lGuW4FCT9gNuFs_>N)U<|QBgu`-1cG~fmI z+gOl)_ibDVHstT0KMcFp&1LxY>w9cY$Ll);0}%x3>ls);{ssA)g^iuz)}_;}S-r1o wKypMG05e45tMKCgjEn*=x!(AKq7Wnj0K9WzZ5uveYXATM07*qoM6N<$f&&bP0l+XkK(L^bx literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVDET16.png b/assets/icons/16/ATVDET16.png new file mode 100644 index 0000000000000000000000000000000000000000..4435060482dde3023132371c759e9e724367514e GIT binary patch literal 209 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Gdx`!Ln`JZCrD%*;80pL`Lncy zq~t0|35m##%isQ=|Noz7t@m@k9ENO$%)IOsDT&F+hXZ!yUFOSC+aP0IxM@~n?Qh0lc>19>JCI|ojgDZ`oO zH-EQ`_U{{=!B;*qDeH)>(K+LBiKB?oOUGcsOV(qI<&472tqp|-_Bs@%DY?r7-6J9s V)$yTLDjVnk22WQ%mvv4FO#r7cItu^* literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVHST16.png b/assets/icons/16/ATVHST16.png new file mode 100644 index 0000000000000000000000000000000000000000..68718293d89178f4dae7e3f3662e2ff4f0ea4f59 GIT binary patch literal 178 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`m7Xq+Ar*6y6BY;Rbx@~{a{K)TnaN_k2pGQ44mSa3q)5G# zNq<{;^aRu6ly`NWlb*d?_b6c&tJ;UpFPw^G4jyosw$3q?fxE|W{lcE0&2Eg$GZ`3k Xk8rc^a}x;$8pq)2>gTe~DWM4fBi<>i literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVLKR16.png b/assets/icons/16/ATVLKR16.png new file mode 100644 index 0000000000000000000000000000000000000000..39050e693421589fb2169d950625a8545223aa8b GIT binary patch literal 233 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`8$4YcLn`JZrzkMFs6RJ1Ffs}; zHZa(v;PU_f&;RomPL=q}W2pIa|Nj3!KFUir{7@(qTjZ0Fkn%7gJ$*+`E|>U4+bSuY zb4MK58Zz1#)QU`$cekX@>b_B5Bem(pBOxQAKqML@8f=LW zf}BKf@=T;5sK5q6;|d|;6vg-M-t*qibngpy@54RZ`#g6Xz%Wc>rrJUA^{t9FM6cs` zcucl)3L~eAyvYoAB(#4g4K3(EB(w*$Jf+fbI_&5+=}gw<-#rWi;H0rx>wt{TK0Ye# zQ?}Z;qbKAqZrTSW#R4-h0%8e~tn>3wf?qg-Q4meY$xW8zRCH3HW5c5_iDfpa@FSyv3FKm+O$A`w=2sEOYZKnp6n ztYGp2YV)kgzt~!>J@BqBqOZ4Ce_fWIZ7eUy&il3xP%3?ClMq_u66(KT4i5Co&YR8Z z_C3@kL~Kx8yY*}Df2{3oB7Am*_m5AUo<~usRGU zty0pN?9Z=2L=rMP=OGf5p;dqX%hEawhJh}81BB;q4~clU$^ZZW07*qoM6N<$g1lDg AZ2$lO literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVNET16.png b/assets/icons/16/ATVNET16.png new file mode 100644 index 0000000000000000000000000000000000000000..af01249d3028102f87ef81ef99c9fea396afa153 GIT binary patch literal 192 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`?Vc`v(SONrDPQ*$x`uUl^KxI2nBJlxyyH$&YI@9uh}KYEZoTD4mx%mv7maKRl@-=w zo_1#D0ggikW_qPM2LBgW{I)+V$20ZF3dM8UE>(>Y2TUHYZ4j6};e*rx2Opqb`X5N-^YhIv}7(8A5T-G@yGywpA-9h>Q literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVNWT16.png b/assets/icons/16/ATVNWT16.png new file mode 100644 index 0000000000000000000000000000000000000000..0026e523221d68a942d50f0c4011e14b0f7ad807 GIT binary patch literal 184 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`^`0({Ar*6y6BY;*pS?2Ko1D}YX6@O1TaS?83{1OT&bJ>dWV literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVPRD16.png b/assets/icons/16/ATVPRD16.png new file mode 100644 index 0000000000000000000000000000000000000000..98b8c6da5fd873e0b357ffe810f946b9ad7e6d7e GIT binary patch literal 156 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`$(}BbAr*6y6C^SYXe3|%GGC_G zpYN(+Q-+v8VCZDmNzb-T%PcVC?wGOtDIfFBhR&S1&BqwT1U^1Gq{lXk!Blqg|7Lxj zD;Hvpy7a9*(bh0odE>T)&C%iK9$f9e9FW8`JtLfvVb)iPn~ig0&H}At@O1TaS?83{ F1ORj*Iza#c literal 0 HcmV?d00001 diff --git a/assets/icons/16/ATVSPD16.png b/assets/icons/16/ATVSPD16.png new file mode 100644 index 0000000000000000000000000000000000000000..ea8f62a307925db6b927985d732b16f9695107c1 GIT binary patch literal 210 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Gd*1#Ln`JZCoB*!XzG|TrRo2Y zj3}dYrU-eC4F@E`5={k;Eso{kDay0Bc|2_E0*PZTou30^4lrzL6ftY#esbr*xwAff zEXg@Jch~}?xWmNKTrw@n9*KO5NSIKZe438R@%i^S zsN(f0Ns+B8jHWhh#)bhL5}sQn?`r$};Bg4|DYIDdkdxU>Kr#7xOE9C|hbIBD%G^D{ zp_5%FJ=-=dGhr61nnC_)*&>;P4uvL0fmsaPJs%$(((^hiwTgk^^gZbvk#3D*Kx-L1 MUHx3vIVCg!0A-yuM*si- literal 0 HcmV?d00001 diff --git a/assets/icons/16/BACK16.png b/assets/icons/16/BACK16.png new file mode 100644 index 0000000000000000000000000000000000000000..5d9c2e02c7159f521789f35c67339eda3d68acff GIT binary patch literal 414 zcmV;P0b%}$P)}YD6(W+P>N0 z?*ISo?EIn@e6pGh%&Z&?!~!Nb>pz18GaDxZ6EiE(n&AdKJy?6-C(~cuuWueseRJa& z!_QBzNq52PgNuUGi{pLsqjkC211t`UR1sXT)aA3IK0vcMSj_Vp}x|1lN(V`6O1S z{Q3RU^8MZOH$FbP!tnp^9|l5z30>gn!I~4yOn(i(zkS;I`udSSKR&!9%>V`l28M?R z8-F}GTwn3$?|0J=_b*=f@ZciD-`^++5WfL1@a$mY1!bncrr+PcsC;wd*pHtdUty>r uIy1@J*K2?h7y|>tfhULRDv8xc5C8zEt(>ki%WD$=0000s4xdvq8vCf77{HaZ62GLS zHeqRHm^-8BAqH^<$vFVdQ&MBb@02D+JD*ylh literal 0 HcmV?d00001 diff --git a/assets/icons/16/BRGRPH16.png b/assets/icons/16/BRGRPH16.png new file mode 100644 index 0000000000000000000000000000000000000000..99b5d98ae3a227a19dcceee92d71310a7c07765c GIT binary patch literal 214 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`b3I)gLn`JZCjdc*r{<6I4r&RF zhAD4md6+#pxzNgO2ctqj=w#O|&$dm=T%pI%SQ-7!U;FVdQ&MBb@08NKcrT_o{ literal 0 HcmV?d00001 diff --git a/assets/icons/16/CANCEL16.png b/assets/icons/16/CANCEL16.png new file mode 100644 index 0000000000000000000000000000000000000000..96ef5b26ab2d36324b159581e05775d776dc7bd4 GIT binary patch literal 487 zcmVX~-? z`B#8rS&7l$;|zq|2`aN>qSLoX{BYa0zOATz6xNGH>c%(ZUq89>qXwFl+mX*+ZRs)j^(VLIP d8iDP9jc*rx%=+#EysiKM002ovPDHLkV1kFj)?WYs literal 0 HcmV?d00001 diff --git a/assets/icons/16/CBRANCH.png b/assets/icons/16/CBRANCH.png new file mode 100644 index 0000000000000000000000000000000000000000..afc77df4a1da8c3c3c6f462448e7421cdd608535 GIT binary patch literal 175 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Wu7jMAr*6y6C^SYa43b9YyA2D z@2`18!_1izAO3Bhzs<6CeZN3519wNo-)G#;9sA`X9z0$y&$IjceJdX0IU3?V+JZm* z`#x{3x@XW7%fOT=D(rE|X7yqQpUnqY>TIK&`jjPRoVa9~#Zbzd&}b;8W9_^$l9`2p XGhe~s5QjuP&;<;hu6{1-oD!MFS$q5St4BXV8n;RGz zg%}$cY?`p_>;L)x|4T+mCIx+}|F16G@MTj&j$QRftDSNQjn>tNrbHGb>iU|pnWwWG zRA0Zx%yWI+{if5RPnIl{IC#WCG2vjU5l=%5Q!#HGvxEmjrFhnXEkeyQPva7pjy`{X rf4}D?lamWt7l!Yan;2p>$3d{q^W^`(e~xau z)QQ~;e7wA1etAhggRQkCR?S#l00JP}=FgtWaQ)^jhR`5?27G`8!TkT{$IqYew4kG{ w3C8H)$IqW&wHO9~l4oj8InhZOzZ!Z101{|`w;(MeQ~&?~07*qoM6N<$f|GHW^Z)<= literal 0 HcmV?d00001 diff --git a/assets/icons/16/CHKBX216.png b/assets/icons/16/CHKBX216.png new file mode 100644 index 0000000000000000000000000000000000000000..4891f88437603dcd20c8c961516f0348c83ffeb3 GIT binary patch literal 354 zcmV-o0iFJdP)?bz7?_!v2pjO?X+0;o%PP5(64|^7J{w z>2sGDM1%zyloaI{uHCo|_P3?EF#{VL8-`^p=mKJ*!eHB8zj+77AREn13>kQNxUqVV z30(kWi-nmH11l>ln6Im?!5}Usf>kqC7k~iBHXBP5hL4{RB~M5SBQ7c9S3^$#09OlJR#n4_L;wH)07*qoM6N<$f?v3e A&;S4c literal 0 HcmV?d00001 diff --git a/assets/icons/16/CHRTLY16.png b/assets/icons/16/CHRTLY16.png new file mode 100644 index 0000000000000000000000000000000000000000..0fda2d93598d91dbb1a9c753a7e0e35e1478545a GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`;hrvzAr*6y6BY;F4}J|FHMc;bJQc^)f|;Juca=Ud)iAD9qg2&>6%WF=39&OvcP5?Tm*#IGQ76 rSuGByeQ046Udk3QXQoCe12egTe~DWM4fL|-g& literal 0 HcmV?d00001 diff --git a/assets/icons/16/CHRTVW16.png b/assets/icons/16/CHRTVW16.png new file mode 100644 index 0000000000000000000000000000000000000000..362be5069573e16f62da7130dc00c4116afa5574 GIT binary patch literal 182 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`wVp1HAr*6y6BY;VJ{4tP*U-h5;NiG)x;;iTasUz-ap&HnRP;~zC1XOpW`i#ew%7NDv4(932+ fi?hc(AqEDIg{Dkr8)Q;|4q@bP0l+XkKBOO1Z literal 0 HcmV?d00001 diff --git a/assets/icons/16/CLEAF.png b/assets/icons/16/CLEAF.png new file mode 100644 index 0000000000000000000000000000000000000000..42a9707a0683f0f14ffa35d342c00e5b298184d0 GIT binary patch literal 263 zcmV+i0r>ujP)p9s**qdzv(gbc6h0FJr64Ay;6E}rbKx3ZKDw8gD0Ki6r3SEo zh_e^3qX>fdCI(uJL>pkNuZf}=nLoc?p5xn>FBJ@ojPZ;N3=01l7#=YE|G$unho>X4 z@!=1!0k{B2^Y^b`cdO}`+8A27F<1pJV>q@pO5yymUG=xGo^hUEFYk)e3m^cp8Kl|K zHwG>zAS}iJ<=fo4a=HS)7Z@4iK{jIpAn{vQ&&1>P0?5xG8PemS;iE7?>vfUkC~?AN^T&39eukKo{NLYy{P_Rr)2IK)0K^B0gXEd;n!v!w z^842>hOp=)hPKW=un33-@j>Dsc^3QzFfj1)@-o<3TQV$MvYg@6nX?SnZ`@*tkBJ0} zg8)lRO2L0@8kfwOzzAbkl^4M^Yig*0`7po&B5rU+U@>9>oCR_=Of!fE@nMEA5%R+4 z&z~6%A3Y9s_J-9kq}@asDjo8fWrXf bw*dnHaXf+VXi3*Q00000NkvXXu0mjf9w&-( literal 0 HcmV?d00001 diff --git a/assets/icons/16/CLOSEDFOLDER.png b/assets/icons/16/CLOSEDFOLDER.png new file mode 100644 index 0000000000000000000000000000000000000000..d5dedfc6e07def097fb8c0054508be0542f3ae10 GIT binary patch literal 176 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~q!3HGX7W?Z1sd7&j$B>FS$q5n}2RM|%$~FG{ z|M%BCqG9IDi4Xs_&);TQyS`r_nSr~b;_owV=Z^hy5f2_Om*?62{k|2C@f;0tA8o;( z{(YY}SKTvcie+HR6czTkWV3oPgU{vzEOoX~PJPM}GfrGG&0^qMaD$=3L@%POEok!z aW`-Lp6ddBj7On?6fx*+&&t;ucLK6U9i9dh< literal 0 HcmV?d00001 diff --git a/assets/icons/16/COLALL16.png b/assets/icons/16/COLALL16.png new file mode 100644 index 0000000000000000000000000000000000000000..ea0421e981ad6ce58340003583f4b479419f1d94 GIT binary patch literal 103 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`dY&$hAr*6y6C_xB4BF;6-mA~y zl8c?e65h;faPd&6GOvM9kb_3qjEsj`ZGvnJ78g0#Gv|t21nOk)boFyt=akR{0Lp|L A2><{9 literal 0 HcmV?d00001 diff --git a/assets/icons/16/COLLAY16.png b/assets/icons/16/COLLAY16.png new file mode 100644 index 0000000000000000000000000000000000000000..ca971255fd22e4addb1a37ab0d9ac238488a6c78 GIT binary patch literal 226 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`D?MEtLn`JZryO8hHnroAyZGr> zm4`d@jvZ=X|MJqOd2{!=l*G`(M;sIrIz2TH6lk&NB<^_lnfu)A($+@C*->HwffFXP ziCdIDV``q+$#{6Bs<%N8%gW}H%?DaEH?MfW%C=(d35L1-dVMD?gMtcARa( z)5ILLRTYW9?mX3KdQnqSm{PecP~V^-R$z8i$D$86I)iz_m}amYxYGC}kwLlo5W~is ak_>(t;V(MGjLPS^y z12Zu(F}S%p@USqmZ;wsOv%zZsHo(Eo&T!<|DG-zA|39X~@%i}z*wnFL)y=@bux!&) z1`c)v|K~4;%d!T!e;64U75@KYuzh?9;w=`Kg4onT3`6#=t4HR_fQXQ!i3~4af7&jq zm*)vGgaszMcy>REW_iPW1{o07*qoM6N<$f;cvrZvX%Q literal 0 HcmV?d00001 diff --git a/assets/icons/16/CTREE.png b/assets/icons/16/CTREE.png new file mode 100644 index 0000000000000000000000000000000000000000..8bccd95ebc54cda7f6e7a6c5d0668dc9f0cc4963 GIT binary patch literal 199 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`eV#6kAr*6yQxXyqCTz^Ub@sr4 z2ZtIMs^`h9Do#~kGH}eCzG{{Z8z-~5ftzuU2D8Mo+?~#AmdKI;Vst01RkB8vp5r0002wNklL>uyObiqP78v9Aub&L_`^p)3`GttqJhepR zGTeZNw=XkDi1RYoSjZ5i`SlwChJ#1%a=;C^ck?2HvVt%J4>uc823))OmEqrirj_t8 zczXW^gPe>2(awMP=shS7*T7vMD$L2i&JO3|1+QLzVfgy(7eh|Zn+tFkD9RHbcn==G jhqK{U9zFR0jOh*loUutFzdTY;00000NkvXXu0mjfTM~Pz literal 0 HcmV?d00001 diff --git a/assets/icons/16/CUT16.png b/assets/icons/16/CUT16.png new file mode 100644 index 0000000000000000000000000000000000000000..0555825a3bc2bbbdda81e76c83f6aead0dd4c258 GIT binary patch literal 449 zcmV;y0Y3hTP)g0 z6f7j7m>6v8kkLWP4eB7ddnGMBO1QHJedG7@zF*$^@dIKsI#C(xpJj{1Oq|#B55{uk z1!KC$#lIG^)6;_kfph8>%Jcs`aCK3u0=T>noUK2zfggA4gl?Y?Ki%*5GcMM6!OI7M zPGzhqqrjKYpoN+C`N>hL13kGpZyVGsKp#M--K;MmMg|G8HM9=#8H7nZ(OQzvBmu|q zZBX{|>y=FSU=1eum;~IM_X$K%fKSM8H&0%sKJX%6_5>XgoU%g8@0xBy#NzixeLqzN zK_38q{?@G3Tdl8Gq&5&@GtO&Ak@KZ-fV%)Hg02ZguO1pxWvEwf-jjemC*)GARlDv> zz~1tWh&h5C0B<7_=p%@;-wc_q33uWuR4n5Cub$)=ft55Ys?duT2=ClnX+)t`3GAg| rQG#ACKpl~92prfNiayU{?7#IB=2M?Zcm6Up00000NkvXXu0mjf)RW3I literal 0 HcmV?d00001 diff --git a/assets/icons/16/CXEDIT_GLYPH_ERROR.png b/assets/icons/16/CXEDIT_GLYPH_ERROR.png new file mode 100644 index 0000000000000000000000000000000000000000..c33f6ac4db6dfc6d25159ed217408e04c0dfb225 GIT binary patch literal 435 zcmV;k0ZjghP)gC`i!K&{#v8PHm!v z8QzIrntuq-=e_uuCk8>^>G9s@cklE2y(2J_<9J;4jO;C7BtZzF08U}#^TO50_K zyEutyyHUUYQkNxB5qMyXfipRflfHDjn}_e_ zJwc6mfqPvIhs5x98hn}t#>M#<)b{paXc*AQW#OrAnRV(cap* zBQE>Z=0_{V0U-%=#<*X0ix4&@dkW73b0Fy#<~#Q&?V`1ITYZg4>JkE1*_dN zzWQqiRWm<5KaHvDiXdJu&Pl2w_yCnrwcPEOT6B=kRL%Uam!A9@qIWnmw-!>oCz8xU1kIl1c(j{t~hGs%Su+W z8DbaV+1xrmHoh+eB;G5Cz<@!&r9tbpr0MP2nyRGF1{VEnC&?3+%55E%AP2AisuqJ%&KJ-fBB6oKuP=&znv5WzHA(!+r0xFB)%2aY;5{0JEa zpi_(v)A&!waFiA(=8Vz(1v6$syQ&srpkG+CBXVwm_e-a~P~3wHCZ|R$@cN-?!Hx1w ztJip&t0+4K=i}tPd9NTIVH)m_!-ElEn33C^*|2e++To+Kvn5t#ZTcW};hGWenrXk{ z7#O9KT{rOlVDR8QXQ0t(&X(-NU}+X`h#``(r@y;5?ZAKAjVoJK($y|qdCb7DGTgHD URw(~spmP~KUHx3vIVCg!02m=v6#xJL literal 0 HcmV?d00001 diff --git a/assets/icons/16/DELETE16.png b/assets/icons/16/DELETE16.png new file mode 100644 index 0000000000000000000000000000000000000000..82816b2100ce8c2fab8084ab036e9892925b8b27 GIT binary patch literal 269 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`S3F%DLn`JZCoB-#uzh=a;C1tG zg(ZAT*p`SLOK-}o`}ghjr~mc;Wx_8TUOTWIsIxP)2 zk{4@P&AhCAVncAe!_>s9Jy#igoE;c;r&UM7yVWC$IT486hAs9L>&QHV*#UqV8n{{eTdiF2RB7X`*5W8tF=3=4dlt*V)o RUjY5b;OXk;vd$@?2>_ESVpjkF literal 0 HcmV?d00001 diff --git a/assets/icons/16/DELIV16.png b/assets/icons/16/DELIV16.png new file mode 100644 index 0000000000000000000000000000000000000000..45c7c85262b440e2d74256a2bd3471e381902750 GIT binary patch literal 645 zcmV;00($+4P)0GmANVJE!%EArBCKf#fzVzHfe<-X>e3CWjDGV&6e5*+4 z#gbl>AW1EAYs#E5bt&13!gQwF61VR4p12nj%b`B>dpexo@AEmo^E(`ZZHC8F&hiWC ziwpw?WZGSK-`}R}lkLDwH%=5ord`Ioe2d9!#`M$_Vso?J`g{Ic%vSK7n@5cto7Kf} zoTboe#qeMNhiof)Iy4ujPz+`AEd$5GCnqee;L*4FZp+oE5XhN7)zL0=s_?Aj?>K z+@ne;r5JeIhi}p7_4;OC>ncOm!-k~ztkmhMF`4&)rX?&re1*A*ugKAISa22~xb(fT zuEl?Q{h`e2Lcf@5J!~&gVb!clI&l?q33A3e86--4U2nGV}NrUzr7*_B`qcfSF zTpeOlZRupG({(_BBV%ENM?%Wfd*b@6DzCR!$^`x`P(I5FeF}mjp!78*V0Et{h_FHq%$N&HU07*qoM6N<$f<2UYE&u=k literal 0 HcmV?d00001 diff --git a/assets/icons/16/DIRCTY16.png b/assets/icons/16/DIRCTY16.png new file mode 100644 index 0000000000000000000000000000000000000000..904800b88938c1968d97d6ccad86136d5294c54f GIT binary patch literal 364 zcmV-y0h9iTP)+`}f~+21W(}n8c6Y9~hX~I2j(j`p@tLj|*5p zn*TBU-|yk(C?O>!fg*YP?tO;U+s@=fsGvpw0000< KMNUMnLSTZo0i5Un literal 0 HcmV?d00001 diff --git a/assets/icons/16/DLTARW16.png b/assets/icons/16/DLTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..fc212222083cfc679bda452994ba23c9420f4b74 GIT binary patch literal 275 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`w>(`OLn`K+outTj$U(sMzt032 zhDHYgFQ@LC4NW55#}z(A#PlCj^f0hcVQOA1(X}w9fmtDOx`UJR?YGmc_SNRsrI~U6 z$$jOw{niHSIJxAx7dE&~zM9Ohq1|8TmC-HNpzAO-KH_EchNvV3)wP@&>g}5)+?$l$ zgl=TC^Y+|t(p?sm zl9FVE{r@#dCbQlNQkCqP{K(Q`O~=)M@I}eD=1a)&TYJ3HKD3p?`)KLiGuO>GI#n{Y X^CtY<GD3C8UyWPs>=3*ljyN+-;4&aWO!(^+hHyVeuESny=PNW**&5{N!*@jrMm#P;c(3xp=8`Ze|8N&!MQe7}50z0BJBYpV>_|CF8w@ zxZGc5I$FxIxj0!?j{QaxVjK@H8WA9ov44JmebIbQhejd;;!8i0lZzmP;KZrZu-WYp z1fi|{v413!LexiRr-Paja&Jv_ZA;Fp2?z_z0K-6c)rm!R6O-fPF1L5=(e9BM^CFig|devYS$RyTD*b&1^n!5b~CQ zsr#?dJUFt`!?nwOaQ%rxVHTZH)SSXlTBS7|&teE~cv5&Uf7lk~*}kYHr#0Os=_ol{PYZNf{8&w-`I1PNr#^I04dDA3 z3T-SEF61j6tgfyg8j1MU^GNH?$r4a*Q^vFQ5)98q@%;TStnq0-FgiT& zH4x~NM6p&ACrz36u3~6n4Xq9L0000v$T5Hoh|H|RrJrHbl1U8TzI^`j_wPSX zbVHb63|@XAoS2D;i9yM#iieerWBZgMQ5&oV-~+5|>anssGRL=Rd>$R)Q`7*$UFEZspFx$IZ_0_{|T9{(pa2US8Z= zO-W_7g;$g%}sW!1gn58B#r@8O+r98LAiFVR&%? z76$+SznIlgAc5U_1lWA?HG_|t2t!22CAb*afUMrPl6ZB30_@*kmgnz&GECg~2o?rl gad;Hr1NdSA0O=5ct4XY?JrvLx| literal 0 HcmV?d00001 diff --git a/assets/icons/16/DOCMNT16.png b/assets/icons/16/DOCMNT16.png new file mode 100644 index 0000000000000000000000000000000000000000..6c566f89f5357886724623c0479550e3b0e5f76b GIT binary patch literal 246 zcmV79% zhMzyaBfRtNGsu7s7zQL%oWX0*f({d~cVK`8n*ve*3pp;pYrq0pxnKbfgIVb20tOrw wP|*ed|G${kQ6NE_w*Oz4|FL}`$tGL?0M+wFu-G>OUjP6A07*qoM6N<$g3VlG`Tzg` literal 0 HcmV?d00001 diff --git a/assets/icons/16/DOCMNTMM.png b/assets/icons/16/DOCMNTMM.png new file mode 100644 index 0000000000000000000000000000000000000000..5fa4ccd68cd1a13b7eb37ff846b9527062f0ac2e GIT binary patch literal 741 zcmVkIC;DLdb_Q-e) z4i6rJx9{>otzI=9$|k_b)@|AcxCTwruX>Bc$fKL#`DSqNXd*gVgV-GFkX(hP0&=a20G;NC!n10ksXt~8ggU!@}KKfxO^ z#tsvz)jtrMOu^A3gTOFM^L+3U*9grl*aOMN!-lRK8J}qk$c!<1YC=1-nsD~?DJ;Kd zc_7lnnl;A5ZeC~1@=`+gGG+v=Cd|KF0G4H2+Hv40LnL0!PW{&ysc6zPT6}(cZ~uim zpAE0kYG^efaAvqW4B>(kEl+E5W6I@{V$sYz%K;A5Ojv8jWrkx6kq4N|+*LG24crsd z&V;Ttgp(bsfzuEr6I@e6aFdf6qXsd=VmO-(vC9P42BH_c46%xi3nYWNhS*KV1rpq# ziNuBZKVJwAH3XqTHXhz>ri&gA+xWNvX&+=A2!t&RBRC?EtM^y-$TzIazLPi^hCu^! zPm?&dfNiQF9b!zxA`@&6q*IJxEHYu^pRzC*1AqiZ^t8J(3+JvxO!jY|2?PRx0Pg1> X@*iMSDj4c`00000NkvXXu0mjffL&7F literal 0 HcmV?d00001 diff --git a/assets/icons/16/DRTARW16.png b/assets/icons/16/DRTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..76b5d709c3917b4fc8ad8be80449ac2de4a9e355 GIT binary patch literal 272 zcmV+r0q_2aP)*`{xWIpgel;DF7D94NI1K>V z_@7Z8WGgN?dwY8pJO(gMym|F>?EnA&|KO54c<|sK90o8}-nw$SfEYOzWGS$1j0}ah zubi2Jt__zQ3$g+xCWgqHm(Q-jrWuzU)BwgW3``83H!q*rgT={sEL^OiEHfb5<_Oy1NZLDYgJ;FXtQTvIKyr_$@%W0 RML@SQc)I$ztaD0e0ssjWQ(^!B literal 0 HcmV?d00001 diff --git a/assets/icons/16/EDITRC16.png b/assets/icons/16/EDITRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..6e12944763f8aa96f7c8c964812c1df5d15126d7 GIT binary patch literal 421 zcmV;W0b2fvP)V!UY~jQ=fb}amPEN=e!V;gGt2+Qc9u#U z%*>1ocm8~4*z@;AWoY-~GejBi?aS95GhX>jDaPX#>x1y3H!~g&P84ex0_vPo0|FMaU4}YMm!|8?d_c%Es>pn2V zIsat%_32Y-cJJFOIQ^=oWAY!JR?{&#uBvU^U}mN(gHt0uU~g|vR6YR!mjH$N$&~;U P00000NkvXXu0mjf1jxrf literal 0 HcmV?d00001 diff --git a/assets/icons/16/EPS16.png b/assets/icons/16/EPS16.png new file mode 100644 index 0000000000000000000000000000000000000000..53913ff73b00f442ec8ff51daa48230c360186cd GIT binary patch literal 583 zcmV-N0=WH&P)yuoR{v*Ym_4Oll!s&krWcFm@CpdIFflTzFn#^Mm?Q&c771%` z^YeGxc}6e@3v)9l$O#5aD-o?A%7FTM2A02!49o4kqB!^jMHs$+|IJ`yp~%3`$KE`x zM9hVt0pedpT6E1E45Ss*7&th&8Gil#%fQ0I#NcSF%)-jbxOi5XkPJ=(rWA?V2#QJ; zo7ww<`K)a048MN;0kZ}8IT@_XP2~2SQr;O`Nps?v%uvUxOoK_ zzW;z2q9`xKpsgWpA@)UN0)_!h-~LZFbMRFV7L!Kt5(^6p!{5LE;Cxd<83qY4p6sb5 z!ZC0IrWA{YNXe=s=$P1JgfhqlU%vi?^BEZ#860et8MrvurcWyt*I@w#3L^{KbbIe8 z1|}xVSOtZ{-@m_6#6EoZ&hYo|e+CA|{}N39|1k3W{`KR-!L7>}o<&& zGH9xaGMqT`h~eh#*Ju7QF#6{7ynX@p60&XB40`tH4#W4?=NUeH{Lb+F#m5zYxtUUP z8ee~bhY5z8(G23?SWWV?KWWL^cXMvcA z9p%GI#bOT7Q`TNeFK=#cJ@iIOg~F1eU>O`|8N*Wm7653D%eny8ImcZvtePfP%GK(f z|J_KbSj;Ki_L~g21jYzFyf|Oyz%5ftelbajvGEObZZPo6V60blETuISv&kf;H5DmU zg{D}q=$ah5VW8PHP;a-<>KaZ%ItTm8)DqXnF%-&3=^Qj=qwo#`N&u$i@!4bo^HXW$ zPo{*CAR;5R109w97V7QJ;Hf4D%I4|nXXWojRgBgMm4a%tzXaH_JeE(VaORO2VPq1K zk>CH>L#?F`9OWy9ntVNI>9C*;SygZwK#ulj5*ijC%^;gPfhe`D|BJN;4eWLL1+itA zxEQ2E@HKK{KL0%D?6#~*Pfn$=IG2IOj;81Ca*nn84g9&^l82g%@r&0hwI99i^Q5_1 zC@h%@ejpRX{q$@Gr)Q>c9NO61$8YrpI2XH3#l#EOJW7Unw~5X#RGrAgbEoD|NZUH7 zBUiPh{4%7)uFOHzN$}68)u+!z=7a zWFH@b2nyq7qW|oC-u2!=F3CD%@;E+I1C0)`i~i5%|v0s$u`K`@3j<$vowNI7#=hfm%R)@kCHsz*}fNv36kWaX#g<; z_{3&}b1^*?lcF#RVul+=BqpSYvDH23Gdml*Xdg7Q3oAdEC`~vR7i>mK#cWQNPHGGz z<3NpT!ojHZ*ky?*{T4LIJR>OFBqoL#E%uQ?<0PVnO>M&Snp!RD*P>^{)CXs1fNhYuZ{*r$^$xgI=O~RCrHLrbR3sb6x?px1vCi>ZGKJ~L$J&j&_|n*I z!tZ?M`~}x%4{}M?kwz%BPg!x=rd+I>Dj&R$#&_R_hV;9xwe~Cixbl|kfZAu`ToZkI>ovd#u<=_EJ=xyi9Z{AN-&pcbmlMyk=yCSbm~#l>r~qHYLZNJvHkJ zL-pA&w(^tTGk)H!_mkQjc(?RdRZOM^H8Nh3wBF3&`Cr&X` z)HE{KyLvP1*>?~{js=&d>o;#PY}>wzVbhlF3`&X$41PYI40Tmy3|w5CDC(H7Y0SSK4o`wt%&YU*1VE?m0Ikd_?J(AU+< zz|PJFS19M80;V4wxP#pQK3-l1TWd=Ujf4OTjKR#z%n%V4M6^Z>13*C5zL^0TJU&>< zKnO6Q3rHBafibawiD;FyGJpkL;KhYqSQVm29}G|@Gf@HnM5A^=P{~+z00000NkvXX Hu0mjfz(IWQ literal 0 HcmV?d00001 diff --git a/assets/icons/16/EXECUTABLE.png b/assets/icons/16/EXECUTABLE.png new file mode 100644 index 0000000000000000000000000000000000000000..2fdddbfb963a012377c0587a775da7cab5e85086 GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~q!3HGX7W?Z1sc=sh$B>FS$q5St42~@k`Lp~8 zgP1_!p<`V-XT{w63=IO4tnaY8?}<5aDaOfEyy3v)bbW~eMoCT1IYmA^SBe^W2&b1;r|X6e~s%deB2XnTVPkG%A{d9wcA{(L;+Ai3de6hu}dE zQN-XOen5J&mmUJ55tWF+Dhg%OLZF`PAs=Sty);@kw43a1o}2dlV9D;x+syK2XJ_Bc z0vry9!{KN{P#bXiTxeLXAO-=VCJQno!Gge}`;iGv=dUuXY6FNfe8)VZXz$ZxK+4UE ziD$_efK8hIV3ncj5E2<$ok5`IYK<-i+`ViYhFsD91ZWl+5(G=&!tMNoHis7lgaunmMq|?s zF$(*cfiXeA2p}-J2DvQDxRHC98H0&wdNPc<^NBOAUAk)R?C1mwilw6U`kk9209KAe zjLiuGGiMO0wpc}@c1(YP|ASJofYi&U`2P6=J>IfoCx#As(b3suh~6-VM56cT@4mge z>6Umt4kKoM&^yr{K58&g%1DuYNgr4pHD39Kz2+ zH`4DU6bfaW@D9>_A|pDzdNp_sQ9#xSZhw$2>=Mbp3p=;p`)3WIS8viBB9}>hiD4}Z z#AYL7$%^{GAwS((p*Lj?A(hu^v5#%F7bZu2GGs`k4XdMtTkVo5SSW*=q4Fw`rV+yi z6}73^A>;!E+7s9LkpoPNC6Ig^W!}PNVvED!aL`hI10?5@OVcNZ)&Kwi07*qoM6N<$ Ef_^-0;s5{u literal 0 HcmV?d00001 diff --git a/assets/icons/16/EXPNSE16.png b/assets/icons/16/EXPNSE16.png new file mode 100644 index 0000000000000000000000000000000000000000..3e1a02dbcb08eb88110ab9af28c6fa0c6544612c GIT binary patch literal 215 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`^E_P~Ln`JZr!+LZc=CtM&8;nq zjm=GrZO?=M^Z);sjGBIK?hS@V8xOQN&f0u=azsRAR83K*h8+ci@4`e0Qh~;!eoyyvfweDrsL4jn&Fh#usO?NwwFsn@p5l%kPqPh8i zg#7GPdI^r=8YeuJPaJ#Q#HoCX`~Uwx|NhQiFj+C{-~Yysl8HP;n~fQadxCF7^ec4& PUCQ9;>gTe~DWM4fU_e+s literal 0 HcmV?d00001 diff --git a/assets/icons/16/EXPORT16.png b/assets/icons/16/EXPORT16.png new file mode 100644 index 0000000000000000000000000000000000000000..02abc0b4c1dda0a34d04b2f5bf18576f86a7e750 GIT binary patch literal 378 zcmV-=0fqjFP)#B{i7;GR$XWWGJnD{QL+uHB9(4v;1Y;uffk}!OXz4y;)Y$hG+xop_)xagd{Zh zc^NFlgn4io!h}z=6c-0rOqiVwry)#)G{XQcLl|L=2m?0Pb|Np<1 z>EHhq#>P5#z=1er^0dcHj12wAn(+VwMn=Zw{^@gWpFe+H0cS!Y7O=n=r_Nl!s}Pqw z3yfiAVt^sJje&t-!=qg=zpc;I(BBURR+QFk#9pf{L*La7qM)COMive0cE$ Y0Gq{juqacr`~Uy|07*qoM6N<$g2W=L#sB~S literal 0 HcmV?d00001 diff --git a/assets/icons/16/FACTOR16.png b/assets/icons/16/FACTOR16.png new file mode 100644 index 0000000000000000000000000000000000000000..fd8505f3209262962a9c919f76f0c8836c54883f GIT binary patch literal 279 zcmV+y0qFjTP)7;T0(&1$!*+@1RJmi+0Rh02WIO{ dJemgw008FcK*vc5!H56=002ovPDHLkV1k*IatHtb literal 0 HcmV?d00001 diff --git a/assets/icons/16/FACTVL16.png b/assets/icons/16/FACTVL16.png new file mode 100644 index 0000000000000000000000000000000000000000..0b8c3c96d9b74e902cba25b1c10d317c8cbff33b GIT binary patch literal 205 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Q#@T9Ln`JZCoB*!XzG|T<tKBlqX)l-KKG`Xm!IpUpYZ8p*_`@z_QqSke%MX0%=H6{^#lSFtBjSVSp`2svGcsN^iAVhL*}~X=(P{R-xEXfkmVUk) zwlrOD@KJI7!O$h%akYhKf!>e(>SkLfJUQdCDfb2gL&X2^0P*YMtU&iMc)I$ztaD0e F0sy7&Qu+V@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/FILDWN16.png b/assets/icons/16/FILDWN16.png new file mode 100644 index 0000000000000000000000000000000000000000..4056f26d0f15b5ec258247cdcc4c645ab65218b3 GIT binary patch literal 146 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`k)AG&Ar*6y6Bd{UTsHjKek;tk3O|YdkbEll5~rC t)T6+*v9aTg(2RvDtV%w@dg8o13=9>`n&Q)YJU})wc)I$ztaD0e0syODGO+*v literal 0 HcmV?d00001 diff --git a/assets/icons/16/FILTER16.png b/assets/icons/16/FILTER16.png new file mode 100644 index 0000000000000000000000000000000000000000..da3f64d4a7f1f8902c47a505a2515cdf54010b26 GIT binary patch literal 402 zcmV;D0d4+?P){Q2`caMRYEf4+SA zidFN&M^6}Dy?&Ltbne6hFfk@%1&e1-*z^6{_uTcHw=?|y{ToH|^A|4}o;-clxn$17 z1<2w|=(a4LGhxQtw{Iuz+ItW#_T=d^h6j%xZCE;YLIt{dCTvbsmKG?vedivWfA#uJ zhW{)KrP$OmVH0d@Z2W^R#{Bo+AEFH)1u)UnfN$TvQ)EEvyoJkt96WrS;qTwSq#Lkg w&V-u(KNuCyU$`{!>zA)@*#9#lG6OXM0J3PP*BKcZG(hbC{~2!FzIsLzSs^ZYCb&sZNpvjEWvk z#n|LoU<~_!3$2=p{ePZ{708Re`r0b3lz1?5H@Ke*o5Sn zV2rCLcYx`C|Nb&uJGC3b09^85FZ}=i|Ig{Yt61(`J;m_%&o71#Z=Qk0V2bd`!(7k` m5_tRK0kUK(k^>0IlMeu!Wqwj11}h@~0000VA7t-pC)tGuFLLH_EdD!Bjv literal 0 HcmV?d00001 diff --git a/assets/icons/16/FLOPPY.png b/assets/icons/16/FLOPPY.png new file mode 100644 index 0000000000000000000000000000000000000000..57c3c868a03c0a8f45dc5a273c5cb7ebe0c6e0a4 GIT binary patch literal 196 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~o!3HGD9`RZNscugf$B>FS$q5St4BXV8n;RGz zg%}$cY?`p_>;L)x|4T+mCIx+}|F16G@MTj&j$QRftDSNQ2VcHfF~dUS-zL@W4XctH z4b^;RwqDmO`PnqbB!ro30aJna9E+wK}393iNxQZf7a{kYg^dcSb`472U5Eme#S_23f!{{17$ z5EdpTMiy2URuMivUK9zCH$2^(K+KTax9@^|iQ5ZlMH>GY{_l6Pvysr%(L_>R4EzFEHEX<6dn$Iw7xFOEK#x2aSv`mLVQivTzdu(bU z0~3t1a9Ym`=HLGDt5c^E?Pl9QUZz~WkfPvN1rhNg?RVCRB?5zJ7 zI9Yx%q z@<0QdUi9okH+Q-FAHI3z)1m*i8&|geFrGY(w`pz^$2I4bPZJmzME58^-c^6D3+PS; MPgg&ebxsLQ0NW{1*8l(j literal 0 HcmV?d00001 diff --git a/assets/icons/16/GLOBAL16.png b/assets/icons/16/GLOBAL16.png new file mode 100644 index 0000000000000000000000000000000000000000..4abf0c801ce793773776b31166263649f53cf183 GIT binary patch literal 591 zcmV-V07f<59pl6RB{6TW` zB$gf6G4HoAXdQ6r@t1cMkyjaT?)`etmZ)DQ3%w`%5 z?>FA}+%qPqo3!P`LKbJsj$6#SW*f$~Fp#Jr3yg2H7 z_ady|2BStj#{|g~TMEE!#Nm%KfH-7t75v9TNOyUD9sVX1(<3LPd!WPf!#hk)hO-b> zr>qBt$Oz!#GhLL3BceB6UcrTyxWIjnQMxoR3;Ie0cRkbYx)Cu(@;AO z3ha#<`|CCahu=9jMbS{RR1Q-nnI?{^)9UQaQKkE7v?>EAX5s@u-d5MC)|5#Wh1a?S zuW<#PFY8cu6*KDA{}@|&Ig*G4R+Au;O$*Xi{)vvWchbt^7(XU5Sl$X=U}{t>?3_AcHXb zp|Cc?#a%Zk(;X2;H7@5Yr0)#t;bw zF(33VD2yEmdaw1+lnz#Xtg>QFar^jNJPLQ9th5A+Q+;Yov->X0&M(N=m1CleweBdc zx2Oc%vpqi#q3A4b_B7&CXcBkc-$R|J77lwJSZpTM$M79Ob{CAEHW;iLo2=0DDggz? zxMzb#kAbOCoNm8@3q>bkGjGM<&W>nY;gfb_hsnzJps|qsrm9Z zH-gWT$u)P7<2f^+*Cq-ni>k7PbUR`n?}N#45Um7Dl?y_40ALi+;c`s(PYsHz36h#^ zZE}XS(6rsPawtSV#Mca#2qXNm50(>IP^QbVFhTiR+fr*>fL^49a_ZP!w4edS>Sm*pZqx-Yw>jtC8Wb_Eik2JSh)l>9-nAe-;&Z~T-tw#AJRGk z4qI`3KA6xXXbmMgDHBxGsi!P|egPpmF-yRX`bYaaRf`)DtRiwjp(Ve6CPj|FGyi-& h>mTZ!{9D~W;TIGv_*=3E>wW+L002ovPDHLkV1n!pICua6 literal 0 HcmV?d00001 diff --git a/assets/icons/16/GRPSRT16.png b/assets/icons/16/GRPSRT16.png new file mode 100644 index 0000000000000000000000000000000000000000..f188db0fbcc866c5186b7f7292a8e086616c6adc GIT binary patch literal 171 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`MV>B>Ar*6y6BY;pzREvu6{1-oD!M<^T;{# literal 0 HcmV?d00001 diff --git a/assets/icons/16/HARD.png b/assets/icons/16/HARD.png new file mode 100644 index 0000000000000000000000000000000000000000..a7105cb932c2f897ac5165bf7b8e064728d20f15 GIT binary patch literal 163 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~o!3HGD9`RZNsVq+y$B>FS$q5St4BXV8n;RGz zg%}$cY?`p_>;L)x|4T+mCIx+}|F16G@MTj&j$QRftDSNQjn==f%;Z+dG&MG4xUBPn zX$jLb#&SmCo`cgw*^ez@5(}vL_wVoQ*2G&%lT3gt={aH=ejW_}7~{W93v>Msw3Wfr L)z4*}Q$iB}ZD%_N literal 0 HcmV?d00001 diff --git a/assets/icons/16/HDETHZ16.png b/assets/icons/16/HDETHZ16.png new file mode 100644 index 0000000000000000000000000000000000000000..f2930532021704f493cfcaf8ad7e20d5826efbf5 GIT binary patch literal 347 zcmV-h0i^zkP)>ZFuGuu{l90)oQbY1_zVDPF33s4Dl=iqEU>{W3`BraOYBhiW-*80Y^JHj z!VUHHgbhlFG67?Bz{JSNSTFufWb>4IQ66GkgJA#z0|SGesiOze*Z=#cl!!{;Qn+B* z88Ai%EFi+d$)ACTPr&5FzDN_r1M=%g3RKvSZAYnA*bi{0%8-6HKcfR&@{E*5BLhvr^m1{9X~p6?_|!1rl9*B=D#7sY z|6x`(mg6&vgf&PqU`o9x4-ImV&G7dgbJpWl(_Ja*1#(?^I1{S8T|2ONKIqK+` z*fS`q>oZt72S_k6{NE2Un4kd?UxgPdYZ^INIQhfHw2f^U3@ltUn7;ns4zd7QJtHz_ vYO!zwBO_xyF8_kS|Ns9pvwPppfC&HqKO9CmuqJEr00000NkvXXu0mjfh-Y?v literal 0 HcmV?d00001 diff --git a/assets/icons/16/HELP16.png b/assets/icons/16/HELP16.png new file mode 100644 index 0000000000000000000000000000000000000000..4b76f23ba387b0cfad0591b1efe3597cba48dbbf GIT binary patch literal 502 zcmV*xw|uayty;U?Ioi4G_x~1zxQM284Yc;w;2gJn!BJuC1~z}Wpq!Z z)^|!}|6a`xO73h6&Q_!0ei0n(uCG__exhjATvw`nF7>U}Kw1+X8dsbhC*s4#r_Xcf z8jL{;e60WTp2~R4A0hq2LdLWTOsb{zotw)>fW6H~NOAYu!u+HWn@Pfx4^TA|%D(xN zMfAdRs`c+&zJk@c1@S1m9=H@p)U&e`s6R%g#2^ckvKT~?s^W7FgopMbU<)B2YGvr*C?QK z5JRk>s|pTu0m_EwE4N+tXAzTwO0btQb%I;P$Rw5OFT7R65G%-G#bVX99Vw`{R&~lu zhe!;ujPBA^YCnBpwQb?KjaJcKVj4c+Qs2s$)?#R=$Dn(DsRA+*xse!}|8M1qurU=6 sBM|tv9ov?jt=tUqj>qH=^xEhA8{2>TJ2f&={Qv*}07*qoM6N<$g1wyV_W%F@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/HELP3D16.png b/assets/icons/16/HELP3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..0b9bfbd10cb2e7d2eb6c8ffa748448347113fa07 GIT binary patch literal 282 zcmV+#0pwod;v&@b?H|IkQ zU?5uaf@NpGbV8H~SRV_z0=oqbST!C>z%I^0tU?%o+6)Iw3={$uV!eRNg)D>=5CTk4 z`pJt|pGndPRsRI)0;a?ryKgLJU}Thl1rjW}2qh#27?@ft+;D86-v8$Z9RAO*k^DWS zSTuwbFED_>$4@^PcI>(N=j-=BkvYAu*AQa>N+8~U@b1q)21cSaqZq*QpJBycrhi9r gdfx3JRx?!q0B|@__V)->tpET307*qoM6N<$f*UJvO#lD@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/HIDEDT16.png b/assets/icons/16/HIDEDT16.png new file mode 100644 index 0000000000000000000000000000000000000000..8f46dca18cae72fec0a6eecbedec0040ac3d287a GIT binary patch literal 328 zcmV-O0k{5%P)Xg&PEHsAWOdDdD|lXRm5IJ)5yWh!3Ra-)w72g zE}hzc<3BgU8f0-MWKLrv!=HcLjJ|iSpS$w#_GJcMejzY^^WrhXl{1H4{9|Br%xQf6 z1z8UxHfK&L5tU$OWIXK>5HG{Y&C9TT<;*Yte*Q2`?|XX#T`eOnzs@WY)?i>`J zIJLwMMba$h5DFicJQK2DLX-&@;{w>^nHVSpEXbS%%g*3cj7=VH0J@*i0WNupqmev) aNB{t z&Szj?kY!?EU?52|2td_?UCe?kVYi?Guf{_OnDQ)y6c7STBjgOY_~{43jy*U3eEt3>GNyk-u?Nh($07*qoM6N<$f^8UlAOHXW literal 0 HcmV?d00001 diff --git a/assets/icons/16/HINT3D16.png b/assets/icons/16/HINT3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..4b76f23ba387b0cfad0591b1efe3597cba48dbbf GIT binary patch literal 502 zcmV*xw|uayty;U?Ioi4G_x~1zxQM284Yc;w;2gJn!BJuC1~z}Wpq!Z z)^|!}|6a`xO73h6&Q_!0ei0n(uCG__exhjATvw`nF7>U}Kw1+X8dsbhC*s4#r_Xcf z8jL{;e60WTp2~R4A0hq2LdLWTOsb{zotw)>fW6H~NOAYu!u+HWn@Pfx4^TA|%D(xN zMfAdRs`c+&zJk@c1@S1m9=H@p)U&e`s6R%g#2^ckvKT~?s^W7FgopMbU<)B2YGvr*C?QK z5JRk>s|pTu0m_EwE4N+tXAzTwO0btQb%I;P$Rw5OFT7R65G%-G#bVX99Vw`{R&~lu zhe!;ujPBA^YCnBpwQb?KjaJcKVj4c+Qs2s$)?#R=$Dn(DsRA+*xse!}|8M1qurU=6 sBM|tv9ov?jt=tUqj>qH=^xEhA8{2>TJ2f&={Qv*}07*qoM6N<$g1wyV_W%F@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/HLPCNT16.png b/assets/icons/16/HLPCNT16.png new file mode 100644 index 0000000000000000000000000000000000000000..6023db2afed5e2b825b150f211adb23ca45bb72f GIT binary patch literal 277 zcmV+w0qXvVP)1oU>ea4WMZHYu;7zKb}q7O7#I$a z=7K5|%?xz(0t{fYnPe|ip@lw42DBkXBMii(UtP)lI||>viy{VZx(X?lV^-LT_BI7nL|LFfsI>$K~UM4hk=o4`wI>U{9cep(+mSJLv~2}GoTy7 zNJuj>`1SPz!kLLiEV;XlJ_6p5IWg8wgGy~B$^YLNA?;Iie&ssx5t4~~J^ zVhUCaHem~}s$;=r07!E}lnI!U?9l9Dn5k$_?YQ1SwD0BQ5=W#DId4rYJ+Bgt^} ki!)r^k~tHw<{`2G0N~|`s<;=RIRF3v07*qoM6N<$f+}N`p#T5? literal 0 HcmV?d00001 diff --git a/assets/icons/16/HSTGRM16.png b/assets/icons/16/HSTGRM16.png new file mode 100644 index 0000000000000000000000000000000000000000..5b6ae8f2ba608dfedcdb424dd2b4db8e405b7a23 GIT binary patch literal 179 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Rh}-6Ar*6y6C^SYa401Oas5-~ z)|+X}sN=_z&}6vmMux$ZSZk+E+%qIJSaf!%bbJ*PHd0si<#U}Rk#BfVLi$Y01}z73 zk@egc81m=X literal 0 HcmV?d00001 diff --git a/assets/icons/16/ID_1001.png b/assets/icons/16/ID_1001.png new file mode 100644 index 0000000000000000000000000000000000000000..d9f5865df4b079c6a028cd0dbfb3c3383b505ca6 GIT binary patch literal 260 zcmV+f0sH=mP)UF)9*mIzNDW9WNDqk50(FLtqy#U9ZTFx5 z#p()>T9{Xv7$^ixL*D=ve3FWi%nWR-jN}`zzEhAgFBrtV0b_y&{AXae^8CeTg0{f` zNG&)?!(G70RD1N~18_1$1{W5IfHA6OP*Q#X)&tfGlOQ)UQ49c107>Hv)_8*e0000< KMNUMnLSTaaA7+FA literal 0 HcmV?d00001 diff --git a/assets/icons/16/ID_1002.png b/assets/icons/16/ID_1002.png new file mode 100644 index 0000000000000000000000000000000000000000..82344411690843b068e1ecc61407e063c1cf629e GIT binary patch literal 507 zcmVn)q?%Ji#?Gf<+78s&Jc8RBc&$_PE>Ai{YVAk;;&;<>z567Y@OM4{B=u+Lb^C0g9C~yXH4B=Y#Bme=ilydWcpuV|NK+sqN`6Cck7t-B> zQTPgL<`e9fhW2P6?x#F$rL%~xreJ0dH6Uuu0?N{{F;R!i?Iv)`4YVieAQoM})q~UV z&8vRiAHkmz>0e1KbpmMcs>shG*j-1|d=K)T<1qzor9BCNKwG?L9S07gp9=$qfeu0k z-Tg7`NdSgaRX!5l^Dt5SHOR~9`0jWLz4Ox!dlJA=z1-vr<0Bac;jY5{Rrt+3F20G7 xYvYrCc*;W7c+b36-i&_pznpTc|NWVstl!)V*#XY`8+QNz002ovPDHLkV1i)?>CpfH literal 0 HcmV?d00001 diff --git a/assets/icons/16/ID_1005.png b/assets/icons/16/ID_1005.png new file mode 100644 index 0000000000000000000000000000000000000000..5ae2857b5dd15001df5a340e8f35ab4f5f959ced GIT binary patch literal 172 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`#hxyXAr*6y6BY;<9FoYgN@L{V zsh=$=AyN7v`)7S?W8=0WbcEP)ZHMBJaZEXcLC^QBd z4cSyy)Sy&+`K0ClFYcF2OiDY`<=uDAJMX=78LHq7Zv-S^E<#`&41Q}-AO(h)$)w%K z_*$}ZKl>`w@VZhI(xz-vBF(-wC>;XaVTbwJhhjlTLCZqVq+xvIcQ`Xw)A4A&ETD$h z6+_4;&R#9#9=!vz6-%myg7=G+@@c{}pgmmS?fLOcX2t}GNYtQ{9d2*PJ@WERCdhd( zTkhMgB%`%^0JN7l)|wjL2ncRV%nu&J$1hPYZnZ8PT+al#APlLaJEM{jmSTfk29`5G!a| zKU}{%s42`4<1&+W^-OvRosBynE~COX7TuonA4Ymy_l?*;UEa!0SdU2A-cL;rQNmoE z{Z`^?qA88sQxf`(gQ7eIL~9R|)1!j2@%6ob4pSu>9p_JhH?j;$<2yzG0000nlCQPB^BmaPJzz(k6LRFolt5(Y&? zb(>JpMO|za(Orf&gCd=a(l%jEKH9hK`%avVnOigRxjLNlKF|A{_lKYccK>jjz|;^J z0wC~|E*at=h^j=G{2m*cW{f>uxO*qC`0!pYsSsWME4m^RMnsJ+yvbpK&c;CXTBw;8 z6lDo=HVrA2!1&<44|@vpoyn`0K`oXXsgM;WzA`pvedb;BAev%XRnZ~;={%Yn4ai6Z zbhI?!QoD@Vvmr1=!M3ppP#(uK8_af}xij&H%pvB`A-%uf?(&ln+T!mORj|?_gap#Q7JZayIRO>E90O3KK-BNQ6l#l{gLO z#vO1j;Ri=oWc-L{D(p5TH)8+wncL~Tr6N+IUU(8exI=HY`%KPO5J9X@G9<9_V;a(| z{+&paULbj9ozn2vNHL9&DZ@qBeG;nO8#yJ21XY&EqfNvo>0iZ z!0?8Ffx+e5)hmnd=cF_I|NECgapF`|r7i_@% literal 0 HcmV?d00001 diff --git a/assets/icons/16/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png b/assets/icons/16/IMG_ICO_PROJ_CLOSED_CHECKED_WHATIF.png new file mode 100644 index 0000000000000000000000000000000000000000..0da0a4be43efa8413b1a92528c718a057a5213da GIT binary patch literal 566 zcmV-60?GY}P)j9ozn2vNHL9&DZ@qBeG;nO8#yJ21XY&EqfNvo>0iZ z!0?8Ffx+e5)hmnd=cF_I|NECgapF`|r7(H-=E*Xe&%510rP*|I}4X%V_{-oWBLa(;QyafXD(nj%qoT9=#g0r){1-# z(wq>3KL7Z`aQN0+hD-bwf54jl|7U1DcH$&PN`wJEAzOyOcMdW*Nj+d-XJKMEbn6XR z^BXSNR+P+y4@_|pwP9mo+Rn_($npKp-^iTZuh)Pi03n_GteRWZ*Z=?k07*qoM6N<$ Ef_I-8EC2ui literal 0 HcmV?d00001 diff --git a/assets/icons/16/IMG_ICO_PROJ_CLOSED_WHATIF.png b/assets/icons/16/IMG_ICO_PROJ_CLOSED_WHATIF.png new file mode 100644 index 0000000000000000000000000000000000000000..54d46df7de222a57cd529d881818363c057c5275 GIT binary patch literal 378 zcmV-=0fqjFP)fCbGwmx7!$6p;y2X1Ne_L3DC{10y3tH3I`9 znt}Mh|3Cl#Gql2-{`)@}0Hluv>JXN*7q1g3wa)fd-KZShOm&LSv|A>BDi5P!-;w2 z415CC_zn2^_9+#3T$qOq?2=!14&pc9@6YcHjK9A#aIo@#`M>TV0+5Y`iGhvj zAIyONe@>mbfZZ^w6o#WmW-(YR@-awrLJa!+;}65(TW=XI@mu@>YXYUHV<%4HOo@C# zwhVvo9At2kdceTW!o+as)*GfCbGwmx7!$6p;y2X1NgMg6QP@21Z84dLms8 za@n8%{~215o&Wnki2$UB1<5fi)8{TH-T_cOObiqPmY9@+{|pQa4?vu==Pwe}z{j9ozn2vNHL9&DZ@qBeG;nO8#yJ21XY&EqfNvo>0iZ z!0?8Ffx+e5)hmnd=cF_I|NECgapF`|r7*Uf%LE-Jiy2@eeQCM zK-1AuV=(OKW_VCq$iOZm%OG4)%dm9KR))`CzJm3z5DN7x*KRQ|X{$3BZP>=}>)(Hd zT}MtsHAAh9Nh$cxz`*c;fq_ARot>SKc?_&9EDUO@DhwPP>)EyiSznpFe*weER&E;m41kU_R47W~L1f9zOo_ z`}c363}9zxV=&OuVR-WNDa3%~v-;lr{rl&@-Fpv-_JX0lF4z@d13(1G8@KP?BiaC% zD;OC5{{iQP$h0C6=D&ZhGcYoW5N!%bI|IW9Qq*Gw0R8pmUJD8s_W%F@07*qoM6N<$ Eg2%1lFR8R!5$o?&Q zl9Iq^7}_5TR8pi8)>t!4=hj$8+nTu5Ht)Ur#l6yWO$$75`0+dE_xYaRIX`~DGK>)N zWa{p%m`lIIupIbe?0FAy@2(`?y4obQFljP3^#YXfFXUDGJ-ZD+1c33^M^F1?<0%k9 zK*{x+xkpWAD|zqo=J( z9@xJJ^++Jr{gjdGbd@s${otcf=uF2DSho?)r&|&WuP;`~vy^|5c=pvuRYmu=T1kfI zrJTqx^9@kU?fV^hLo4612^E*G!ry8GTT~3~nX`D%*^PMOr^GP-o4Ut426}55wmW+e z9e3g7(n>n$cNEI;nepp_;kmH3LQ{ZZ=DM|Z%87V z)zzRgGTP}61bL3*^5Aqdl!e!>Qf1@X0tNIX8f**qgYIx#iwFYWH{lE92?*&VC@u-5 zTqf;jeIt^KreJ6&=nQCaBewB*!j~tYUb6wEC$3;PkU%ss3tCkmc|65qU@QXnie0?) z7aAfCbGwmx7!$6p;y2X1NgMg6QP@21Z84dLms8 za@n8%{~215o&Wnki2$UB1<5fi)8{TH-T_cOOeCp)b%%lB2+R`O0AsnaX50CFKY$^$4(2-$h z;9%uqIC^9j#1N1H|Nk?teD?f>%h`+9v1Jh_@8HEgnq6`e`p#>1Z4U@r!@Cn&6 zF#Tg@+VJ4v<3GQD|Hjb#^X*f(W@$lAxVSJ68-ukXAA|1egA7c|XZ5}L`}fa*yZ0Vq z81VP!cLv7a-x)YqnZf*D_s)Vb2(Ym*F|aZHV*tkj$Q!rs-or3}OG<@7DXEj;#KSKP zZ@>IvVB+Kf^z6!O1>vccK6Q N002ovPDHLkV1iO?-ueIl literal 0 HcmV?d00001 diff --git a/assets/icons/16/IMPORT16.png b/assets/icons/16/IMPORT16.png new file mode 100644 index 0000000000000000000000000000000000000000..20f67b24671049a751e2911a2cfca20b17449374 GIT binary patch literal 439 zcmV;o0Z9IdP)L6Ypn^{c16~7&0ZapK01J#E9k1KKz{rr#$iVOc zn?jic-TN>$<9~+6#|tkn0J9mOz`ov|VP_519V;>NCTK zdv9+r|7Wy(xbPy_B1U9e00q&mYT&3$NV3 z8U_y+UVFj7$l&|t+KVs0zy5-Y|NZrs;q~Qbe;EJ$4Mo-rcR_S=egh*TLp1{fBiPMv z|G#Cp!FruR%t)GniJ6h%<%MSq3g6@zq!^{4+W!Cf|DU0C>D-A8U=1M6+386vtgNhX zlh>Wu$guMA1_l;(76vCp8-@(06u8{)-@jR=&YV}xz`y`80Aw>v^Mon0;0lHQ2{Qcr z^poNHyT1$*u0g~La?%(eY9X#=L60tw0#X1p5dZ)A{rfl3njmWbgX0$L0#JZJ`~-0p hVE_q4lAMYQ0046~hSykKiuM2i002ovPDHLkV1ina&7c4P literal 0 HcmV?d00001 diff --git a/assets/icons/16/INFODG.png b/assets/icons/16/INFODG.png new file mode 100644 index 0000000000000000000000000000000000000000..503897f599dc189dd8cee8981c9e5d0161a585c9 GIT binary patch literal 1283 zcmV+e1^oJnP) zKY$boWq}3VAW#b|Qcwy?+qh{{<>4lNB%ZnGyYq<0kKh@*VKhfdeCLimI!E{3?|$F8 z1B3+hG9Nyk$({ocw=OGd`P@d}g`_gsDPf2iNw`9i(f}qvh`7EaQ3J3lN!}-kJBBcp z3;Eo=|6Ry?M##h~p82J_;#R4SF5jj&wLF?;BG?9cB zOF)apK|(VL8#?sE3iN6ThovI)gL0#w3P>(S$hhW5kS8ITOg8es5T62+1>uz4&&2y* zJ&)Mn86~6>u#oERGnBWVC}9pH_5hi?ER37^e6H4WAv_AY)V={QWB0`e&tTx}>qG+%MlW&jVhhFf71S#GW{1Rv zA@tc!0>Xa^xtLjaR~mB3o=W}0DI~`xow?s@NJB^Q@e0aY1*-#lBxv?g{@PEzg`_gq zr-Whrs6-GUnR)|>(Mvc9lr|rtSol*#0TyEj@m?YS`904<)S57~yJ|WSVQBnK#D~s$ zCNwl)ZY4YW9j{vlm7S;9S^M1_OMQ1W%}I4~FHq#$Xoaa3GFI03YC zC*HCB;)g%B@z;7YVeaF5elcKiVvc6A+IDKuRsPQ@M>lDQZb;1ETETZeZ=zh))gQOH zkMH?K)Wyr>>M*w(NTRmr| zf+G@FB&15iJ59xp1Bcq#w?`1s%t5c|5=*~4$CIsUSI^Zfeq07HX8<=`LZp;wo@m{s zd1 zZH^K(yU?niTC3_yRewp{NkTv3s5rZX5RuyVT^>_FacFV0IlF{NY24vY-e?+Kz#u`d z<7abr3DJbMY`3esn+PhZb=>MXJ3=^%G!12-ylr_(0Yus2#$4^px5YjpZ`*S)h->B0 z#mnT{QV3i7$`uEc7aKI}Tb!69b8Ra`#blC;+-5_Wz1X1O;KkOF$xU*x(Wq-mQTTkq zwDzG4^?LDfokI_qYh|0ZOd9!+ zh3!dhvn$SZvR8cleZfVX+uY|BrOk&&&OBSDCbyF}vAaQ~TN67}#|oi3=n2))Tc{30 tLv=hIsuu=A_X755$Di4*}S6VR}^ zDQr_L!LMl)%I{>$ABmg6z#_n-AQBAhAZ?l@$!l%$VF=!i#ZK@FFYl*fOz3+ayW?=y z=UJZdc~+cuUNnOGx_ry$vsEQT5HjZ7#Zr0HVNXN?V^~;Q#k6M_5&t-xnzogh)aSbM zc^?DOsS%eN&dqL45q8cHbUV=z6dT-tF=3IM(^n{tF)^?Kv)I9Py@|GEeR3_)!ELi8 zEbzj>25HkQHAN?VeE)=t>I=@EYbZWEiZ)Tws8p`H^KCs|0c=$6G8tVzx~$b>>Pz4S zqhj_HE5`t^lt`Tu!3&1qFBeJfPQ#_~kaED=6qd{JMq1;iVu?Wle~)*MErm9Qn4IGP O0000P)j6L62iUo7TCzB2O;&r9@3_? zO4`G)9uj9C|3F{7AsHubAW1f<_ho|8x0R4kp;1K z)diM45{j_v(37)(TX=IZixf$`mem&41Dh<`h(I-!8J zS+AhS)4p)nXi$V8w(*t$fI0!h7^9|n_tZDpof51d`r`8R4*e-fJ`9eG#Gz2K3i8!f z|6NLl(YG7b!nq{L>rN*4kFZISLcmg*#>-1f8I}yvfw8KR9jyt#9zk-Q(RmkytkkfX;pY`Fx*Hf9oQA^5DoEYp;)+-&R)5QN zB6^gbehl3o?!6BTLw<;m0`ORyJk>uj;Y*+hkUfW7op4;^8G;1p7}))JcW4}W;)2EW z)aUaFqDY3^OPj2PVS~T*5@Qr3kP(ax&3A?dkVkwHi;)jx6U6R!nu#z2kQu<_CwIsz zm#?FQEP~kmw@gV&%>oc!woU7+q8)PhIf`V>A-3_>LvMSNfDynM0CV~>tux#dF1n>d z$w@t3H{`&wo@t%o+d;(^VMV!Qag3`u$Wi&ZV%N3$s%Tx<9n4f4i28Q#I-=kFvqs3G zd+I=S$VHF$z}KqeD9B-FVZLX(YoGf9qk{#1{h^|wqJrbWU!t)v+4n8UfdBvi07*qo IM6N<$g4C##?*IS* literal 0 HcmV?d00001 diff --git a/assets/icons/16/JUMP16.png b/assets/icons/16/JUMP16.png new file mode 100644 index 0000000000000000000000000000000000000000..b12de1c12bb886eebaad9ae29f536bddae60faf2 GIT binary patch literal 309 zcmV-50m}Y~P)7W`2T>BU$6ni3&a2!y*wQz z#{cITnHYQ@o}at}Zh*9HV*?`tV>JUK1Kdjt{~7-LXZYXx^l&}cCK!-2$Z>geVagsD zpAl@bZPRaYePBOye6C`G8Uxmx5r0002QNkl?!=mPSF`3(5L!}AmI z8}JZK0U^LL>H-F;M&pav)ItfObp2=e!o|$|1;hpbP0K@C%N?;u00000NkvXXu0mjf DFScoq literal 0 HcmV?d00001 diff --git a/assets/icons/16/LEVELR16.png b/assets/icons/16/LEVELR16.png new file mode 100644 index 0000000000000000000000000000000000000000..e00fe4254576468032d1bfaf674f3293fa82a4b4 GIT binary patch literal 222 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`OFdm2Ln`JZCoB*!XzG|TrRo2P zChuoH4Bf)a5eYq;vfU4qOrOTftl75dfP}kLnS;dYD2W2euImgr46_%iNH*|osO)Av zX4!UBEGOwjgW&X*u5~k6FaNK9D{$|B=k|4T?l$nK z8Mgn%GbJQcmdKI;Vst0P9*%V*mgE literal 0 HcmV?d00001 diff --git a/assets/icons/16/LFTARW16.png b/assets/icons/16/LFTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..82bc13f4d40c81e8d3ea38c495a95e3ca171d2b6 GIT binary patch literal 214 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`b3I)gLn`JZCrDU2#NNK)=zDyL zTF3^|F?592mh1|DwcwB!C9#ZEc@I+Ta-I))UWPG0!l%- zfR(0$7lGCP?r=%rs4PHx_r&MWpdbMd}=KArZ=bH~tp_z2_ejR~eE2mW)U0+tpuYpdhrb1Kz5 z6acU|KYAqn8xCWP)mryAyHkvPJ7A0r?3s zxFUamDbyf}VzI%Ccka%UH=8|U+}qpD?RtJNFuU{iec!zw+&o~)pu-Q1MqBR~bpxO# z19L<;Sp*3)eh{z?aHp=!BhOn2{t|Gu(Vhv7^OVBDJPr1NFtA@10wTcC;7S$jRJx7| zuf6kDJ`DxfU(U`O>i6cU-$R+;6Q^W#>l9v)NGN$JVW(hFI=MhNgeyulU!IC0S-T0h zR?RFxjXIFLisLNgV!QkCn_WRT{+mn@*jV@S71lAKi*_ja|MJx@Pk_7N!#%$Ts8RnD zyO@c$hTw12;BUGk{i)mnQpt~c=g2$qMCXe=50@n0?|769!vEPaOlrM4VkdEa|WxQXA3C86eN)g z~N|Ifhi zfRTYggyCwzdPa>&3Lx>RB_j9n=>5XQ&27sFGaxdvj$!$J5r#;|H((kBKx|xK(~?OH z-@biTgnNOPUkHUpXQKlqCMF2YKp|kkCz()j2CMjj4in-GSb(IEC>LW=hQ6|z|;9&G0tP#eJ^CHm&auOg-|FJ4;o_2%bBk_=eAe)FHN z-@d~&g8(Ec7YjdUU}TiQr}@~27>550457%HsR97Fh;T29XEHbd0000E% literal 0 HcmV?d00001 diff --git a/assets/icons/16/MEMOEM16.png b/assets/icons/16/MEMOEM16.png new file mode 100644 index 0000000000000000000000000000000000000000..0d6ec5b68980d05ae6b4b42f29f96d35ec4d095c GIT binary patch literal 334 zcmV-U0kQsxP)AfP{3nIcoC^R}79WXI5L1+dF0n^|zfP;gb;my1E455J@U^X#;1)1YyXTh*}`+hi^ zWCP@7r5F;UgRm-WY@fjJ;p1mG|K0l!e>fPJzYrY;ckVr8@bhtJu(dX4`1tA5pTGb9 zMb4Vl_lBfE{QKuG!_GYi{`~s=CvxeW32Q)NBpI-J{pLSkzkP>m1_4-7e$K$aAVJ80 g{|pSF$eO7F0K+O~>giYNga7~l07*qoM6N<$f@@urYXATM literal 0 HcmV?d00001 diff --git a/assets/icons/16/MEMOFL16.png b/assets/icons/16/MEMOFL16.png new file mode 100644 index 0000000000000000000000000000000000000000..eaeac5da085019018432fef1707f71ad73660a38 GIT binary patch literal 357 zcmV-r0h<1aP)~N|Ifhi zfRTYggyCwzdPa>&3Lx>RB_j9n=>5XQ&27sFGaxdvj$!$J5r#;|H((kBKx|xK(~?OH z-@biTgnNOPUkHUpXQKlqCMF2YKp|kkCz()j2CMjj4in-GSb(IEC>LW=hQ6|z|;9&G0tP#eJ^CHm&auOg-|KWUO7bwf|Fns*{8_xg!+2)TC*Y+<&hXKg2 zr1(gN_wPS2Y}vm1&#ymxk?DQU-;fjwfB*bt*tzGxpI^WKL@u2(VGV{C2)SVO`ptj7 ze)|sB3<8j(TrB*Yfss)HpJB&7#4!A4UhhS*?DpSY8+JO19KcY8TQ}g|<*I$Pb33&_W7!q0oo=DK80uLZQV!%f^0g z3C@G_R7xJ4G=0!R9ujD2ObZFr1=BWdTAW6zR$e)hV@q0TSJKX$az=Z1@2+-tW_D+# zE%65n^SAfT`R4wdbI*5y$M}4M_N$`w`1pjyJk5%yz({~FS-Htn0(cQjOG>$OC5LWj za=DfNYXZ{AWWuuW9D|-A;0%C7xDq(ap!bN~cb#o#HnY5(?|A~!GqA0Xlivl?^B|lB zU`J9gbCHSORtm3O{_nltq1OmVi{bxC{Rl2!1ksn8JvV4u7>U`4D+>d*RjJ%%M$vIm za2%}flu&e>7Pavm0GTV<+-y$}aP>s$EW5Z4;8gv+0n0*iupdYJ<4DB&5K}5pnOlyF zm8~s&THHczvxsfiZSWL-pom|*w6JvhKnO@5Jvyx7_H_dNxTZh?#s>y4H8SKG-6
jbE`U5geA$!h<+f=Y!4?6r$PR)L*{evT*tfM=%`g zPG1j;2V2{CfB6AQZiR$A5q~F0cObt9uBB4buEHO6pYJu}Tad8iFnu$#xR`DAKjk;o zxiZ?9jhANMi^dC%#QX5=qer}Psf=S5@lA2k+9p87?dy7~lY*ts_oDG8311(3!n|}^ z-A!IaHPLSzBUhv6R zZ@?Zqg5*m-iG&0xL&}merR*Ri*hKj1;ZfrXoxM6fE+M%;0cjaDTwK)W;@$@F@J!=1 zIwe6HuMviXCBp{tkCdw;09wemogOgv!^6S6$ zeJ&^oe#UD^ol>_SriQCC0>J0${Q_m4$Qqt@cV)#UXgt62o14hJ@{5j12x`34C3OZt zYH$En)jLYqpQO$-C4fNBR9<$VA7Rib3EePW&j_af;xa$mlmOmcz4g#el-Di^-7>zB zEyOfq-m}ehdw?rT*NJ$0VXl5bKZDHs-85ccPKRKAO2z@bgl6mOmc`R3uRV$v6;tgm zakN81w~QAYirLf+Et^6qh8<)OG4Df zx3Wp$a}HHGB1utKmz<+S(0N`Xs!-ZQjZKEF%6MW?A4;O~pp5Sp2}L8nNQCTO0u(Lj zL&?$}r19M#!L*53E$tydv8v?N)^~Oe-1sO-kmkQ(q|r*2Gq;C;(x7wO>;jUaZWm#E z`zWGFKdjc~5c8S&+(&x|$oyM0Ib7)*lAmt}VFR0}Lg`jmDc0B`0*hwRAibxLMVt^8 z?M8LoCc(6Y!MB>P2Qa-`dC5Z26DI^kry*^(NDy_2*_svMou&jhquaA0Nb>&ZxSld2 z2%?JTyFo&Bv#=Wldf;q*!c>_jnSU(jiRf*8F0vFq^i3Scu@_#7%)Jdtg48K>`(bXq zY6BDA^mm07Uekx7$q`vfD{N;Mu#mn8Zs9wG_3iygkh-K!sk;@V8?PDf@3M8nmw?Nj z4$qUKc@RyGA6EbH`=%tc8`v}>K^rf1`oVm6BFtv8*}Fl5p^QEdL6T^4+99FSsIH!b zFvid4H?g{1{raS;Hu(~8#gmut2l`wDNkIZ6lZ2>3T1`S2<7MRkaCNP6PQ-6qn!i^w z|5xsz39cPK_6?WS`+D8*i^D_s+L)PeYz`Tm{Q75Dgeg;$BKHfGR-1R2zS2x7qM8*V z3QQ3p>T^+Ji6AKmqBcHEng3eLo5qXd^Yd0R8P%#VQDBM)QJ;$%OSCw>ihG+y{PU67 z^f8;x=3Z^}AJyunteuMjQ@Wy@ixf?oS1*zv#{c=jXVnYLcS|aE!S8>{?*WmYiUQLU zAxhNf_8tk^cw?Mia%_ArGe7^x@4pnZl6tM6BpO7JWa@Da0@CNrW*ldSMD%@zvwW)668=!DITGq|!u_6E>sV zF2u?C@X=cBJ_6>uyUo73*wH<^5(Z~yD;x}AZ{nSqj><20000iLtCeJ}WLZ}1*s^0`i&klBDo9-@xLmh2q=AH{5JRDPXdX%)+B8pr20K|c zcA;-2xFrb``cO)orVlEl&_EutB+x)?YMM5!Q%SL;m8ICSENR!4R@ytKoV&VrXQlns z{#dK{gN6CKvpZ*J&N*|=cY%BOVuKp>MSV`>0K3+ZBJO9Pmk5XaJ_gcYOffK{l)CC7 zeQ`P#oo#9X>~kW$mbRV%@grb50YYy@6ENZ+evdW1vtqf!H)7G`mKT8IMC?&mk1^vJ zVw?oQuEo5}SSI4P6{*)JVlTdnttJ4+iP&S>dP)PQi7-%ToE2(^-PQqRhhVj|0hIZA zW(~cXg1eeRdO7Kpi{LT{(Rl2o;VmJ62b{AfwdV6646g5!MYitTgVxR-gu*=_tGo@N z(-vx;@GFOv{zWVnO*c#c`<=)TY3r?=?M{UDUHcH;dl**h4%7qb zr38{QqgY`KI}cT~c%t)uU0F7|`-c$f?7`i{(yeJMPW~ILb*6!lhQg_GtpruD?cebKdDYU2 zo`J8!ZtcKUz{>4;+#0K`(B1#Fsu%y=p&tD9r-PmlLbgJCtA*nab>nx>eFZ~@ zJFA*I)X|Nd2Olz=V5xT^q6uWmoT}2`5@*--${EcZ zn2OfU>_g2Cb1h8dAyeg6UM=?>+zU!PyWD}R~5 z&BfKaM3QE&{5^;;4=A_O*8{dc$bvPrcBA&ZsCq13Anxur2eX>lM0eQ6&tJV#^Y66V z!Wl=7*$Y{Y!gKOG%@`a3t+_w@K>e<|{d?Ls)mIgWU>oLK!3x%@{DP#bf<`-cdu|6P zJL_VzHr9$Yn7KMHX|c^g@t?g#$2>kd>Hh_F0$mu7oyoEPC9lIo>RFF(36mDkxzG*Ov|n# z4|{Z!tpr*8{P;fur-vCMwsMb+$D&35F;!|}p`Qu^Q_hk%v35N+R<%2!o{JZTn62E$ zOD$edcJy;SS5ShCLP#?CICleb=FM$i2}iJUs;u+!6VUjB$rBa<2q#C5Mx#xgX!{(6 z$Cx2Srz+tKQ>9;g&^ddYHNOSI{V-B#!pUh=Mp>L3vGeA81Z!vhaWmLa4rnt!U@ejQ zhVbyrcH!g*Eu~((0`cv|y)`{N0fC1V>8Hy%^XoyI{V_tO5)z{D@YcT@B(yqtVM53W z)gBGm>T;zOKV(C!(o@X*LMc;M3{=&x%b3Z*H6Gr{4U;S7krVt^W`Znj5s1qzH&6*; zNF>J#X52|4>~djaF`lgWUBNL-xl=ZNj zZHeA8$0UYV>1!~RfY2ahUaG{PcCCJk&}*isC08fuD#_TmNMD_<(3IW7Jz&%LKlN6V U>!I#-nE(I)07*qoM6N<$f<*31g8%>k literal 0 HcmV?d00001 diff --git a/assets/icons/16/MSG_WARNING.png b/assets/icons/16/MSG_WARNING.png new file mode 100644 index 0000000000000000000000000000000000000000..ec009fc8c6328e5ebf23da58326181134bf023ea GIT binary patch literal 1792 zcmV+b2mknqP)ul1mI|sPN#9a*7%z$R!+}yrg z-3QCXMV(G)Eps()fZ4-Cvn76i%ia&~&#sFI5Iy2P)x(pFzM`UubrAt)4^|p|TCE$5 zS=Hklc*wz84!n2gW?n~tSF1gwJbXz>5vq(O@;C$Z0^^f;9RaR!(aOMQ=wZp;G}H(~ zSuwsje=T$XM*z?a?0^5(<-Cjl4RAtv_=<8p9PJ_+>y5Bl%0mY*Xc-G+H421mUC1>d z+BxSD=o#p(17o289O|o&9LK?S5+LQB1B3uSNpG0`uC6LYOH*~^H_=pv#`>xlK+4*E zAq#RH7PkU;PO&!)H7q%1WUwAWI3fs;2$b^10fG=+-EFm%u$sejUZrw_4jb&I=>ITj zl7K1W_l68>>WG=%JVk)4q5kN6U#$L~I%qV?EirotnAWfZoK9#N51v$Pd#ef6RiW?x zaw^dmp{Fy-M*^f{E~jW%vkowOYF<{5m)>k&ckPP*)7fExUKfsh#;nXEjju@uxSXPa z0ZzrWGctsn5Om$r&VZK`d$89AjV3ndI`{p2j2#Rv z9V3kl#C$S$O}}Q|yy_hwsF1g^LJxauP15J8wN{|cS`i(Pq{&t70M{bqCFoHSo@6yV z5QELzrjM9*VzoLzP$92HG{~uLsv>Y|YmP<{=SV9e3%NkvMAhFLMPvqai*w@cRpkKZ zBIKpi)|^IyC4eH3QY3I`GF`m{A>GJJDeX|d4e3^2SFH?GvKX`a=Ddeig#*qyoAher zZEdNMSO0WNr_-WyqeV5sk5Yv>=MM0CJQE7?(mc(?+gH@nSu2B8SVmt_@$sBGz$GIu zJE+**4vU=9W=aH91XhYT_~_}Qmgbx}fQ6D2ISgrjb~!SZv_(W53=HbsSxsR z%LMW!s=>axNG|~#{Zr%S-5GU&Q%2tC+oztMtyYz;W?9C{5*fS{F$5FdZX+aeu*GYl z-d=}dZyIbwu0?Bsx|fjXb{iqy17*)j{DfjtZ|`w6{>RB!zI4Gf8IxO%2)xvY%ziBftROr z?zR?Mn8UpV25nGSd837p2=Y=@MypM&gz&|;^O*N9ebCtl627{)v^S7wqNGljsY1OH zA`9^%FQuUBx?Hll=aG{7End~zDx;gOXeKarA}I$ifyVcLsLUE@km9_Y}R4evD67Ww&*a>o}O}lO?4@n8>9D2 z73)X!612+=Qr(?_cPsYrVEPgsqSiA3^!1))pF4w4397qg2Uqt2Z=Mo8K(DEbE-Er>dI(EdjUrEcXR4Jr|ml+{C! z-a04~8x^^^v%55|-{?FSVa6H1kJp`j_hkWvLZOfb4O7O(<`(OAI|E~ZKmdAMU#*r) z*BCQ?H-(#_)QD4RwHnS&PX@+xy@l-2@fC$XsAU1Mc#@e5H}lm9s`s~JZ^S7^Ul54s z-noKc3{*!fuF=<1$N<#-93ORepw42MmW6|1UhrzQ37eW zg2+Z+dpie^g2YUeAOJ!D9yP|YobTj77^wsaWfDV;Ml)ajePeAmE-HDeJ!0{s62uMR z^m4>%t`CO!_2|IZOQH6&rVkbb@D7O~CrDpo&;ML=35g*mh{o8i)g05boZT89d-y#pgqk#Df3;002ovPDHLkV1jLS>3;wK literal 0 HcmV?d00001 diff --git a/assets/icons/16/NETWORK.png b/assets/icons/16/NETWORK.png new file mode 100644 index 0000000000000000000000000000000000000000..fdf4a5eaa60173ed36bdeda1c364a8cd00391da5 GIT binary patch literal 199 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~o!3HGD9`RZNsXk8^$B>FS$vuAO@)J^0R-`2) zq$DbE{`vp;zrC|Iw?}cbvnsc=w6y1~`oF)923@@nca~+-%#gDR3>OcdXnOc&(kiv4 zS=F~*J;)Jr;&NbH^m!tqFmr1I=gedwqt=H9bQKMJdE{4ftMJ_Mc$6&h;n5+zNk4QJ yurPK72W*)WIk{P>v;Y6=>-q&rNlQ#rnHZE#I6jR!syG?wG6qjqKbLh*2~7aGu}b>@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/NEW16.png b/assets/icons/16/NEW16.png new file mode 100644 index 0000000000000000000000000000000000000000..61670a24443acd41641244928321da53e6642ea8 GIT binary patch literal 246 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`dp%toLn`JZr!+Lpn9}s0hlht> zVgoa)+p_v?-RZtoO?n4AavbX2b;ItSojY05uI9&&r}mHI{Y#u@Ot4fs

2jEG*nS zdo?pZxAE_9H@4VF&tZGO95hLYr?GCHM4N%30Hei?o04H`?;hEZ{JllY+TbJ1%{l|BzeU__MfxG=po2Nqc16k@G;0FnGH9xvXUtP)iV+&aZFtc(n2&-8zuhwfB_>T1HYUO1COMN4f8+d z!!q{uDhwnU00lhaN(}r8x*81sSq@9vw^)#D04!V>nVESQ8U72vBa4AZ@csRBhK~=g zy!g+^82I#H?Fo_$`10Z|!!@Hi5y0ssFq k-1+xtk^lez literal 0 HcmV?d00001 diff --git a/assets/icons/16/NEXT3D16.png b/assets/icons/16/NEXT3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..fe9cf27a289722326d6fb46a7d19b720b6c3e42d GIT binary patch literal 370 zcmV-&0ge8NP)8~+gP0uZ?W{0qa0o1Ym16Cxv+rN#D38W)K$kYWG`Jbw9= zVgH3U3|?UYHac4Bhh+>4RTxMy00dsX`_6FW%3B5j1q}@*hJT0UjdCprh5-ASx2ga`?u54z|g3F)Sb zEFq-CA|XRVEhV${Wz*?=w_Z12r`yhZ;(bM#H21){IKSuoe$VfDoZ)B>5@me-7EA(orkIsq+gk8?8>vNFe`2=UTA9K?K``r= zwBAo1FVo1Ou#9+u^|f`0XaC!RuW9aXDj*+qHUYkWc?b+|Z@aS)! z$(X$tfP0feQw6w=`Oj=*=hCi;re5qeW8Xp`F!Xld)sbW(iHNlP zRK<&rUcW{_IzUq1b0j%<=Qe?>Z;qAb=#`%8xmhU*vNjn!*bfXtC0877qSoAO{1MkS z_zI(o69XMv0ws;!N`+*-Csv1fGEuT&FAuE%9;%g>V;qmJRN&o|gzne#2t@!Dr<%n^ zubXi?D3o~2If5f?uWGy;4dFs_F%Fg6(9!L~!uaM#;`ENiRqo70R^!EoB?Q9jIDg|4 zz6Vw{OcNmBg280nnW+v;VH){%@9gFbG<<6YvG6?NE8!jZyi*;R+H=qN_AUGaIYav~ T8a*^=00000NkvXXu0mjfu6IJ) literal 0 HcmV?d00001 diff --git a/assets/icons/16/NLRSRC16.png b/assets/icons/16/NLRSRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..168a30f8b59aa2732a26d67ff846d62381b099ad GIT binary patch literal 621 zcmV-z0+RiSP)yZH zA`<8#kVt)0j5SnS(&o`goF+3Son&TY0&1FvIdB*EeBb%qd+xaeJ>rot=!AlEU?8&w ziEElBF0T~E{^(3E0Hqjj?KaDdQc;t^pr6}HiQMD6o+ls(vXp+aCjdY?FzE~RpR`X6 zdK~Z#xsc75Z>P2kD3#T5=6_eG6yvFdr56YK9Vkk_upax4(ClfP;W@nfuqPTIn^ZRd zTh@6($l}DfmoZQN{3VA{`3T9aJUF)vfr()c1tZfHpy+3vm74GB#;1KzI;Bg$)!}n!ndouAp&FeIEORm&pI7q4^z~i>9W;2=f=$qH`^;#Vz>G1iz2k``eF>^9^ zA_sD_pR@w_urOt%_4(<6-D`D_>Slgqtp>!>(a2_}$0p62k+3kX6HDC6d7aJqs+5x{ zL!H}+Mv`3tr@{hH3?|Nv27Fe|d(2doa*%#}%o?OVw-=41o3(%cz+fJ_{O8+>%`kJO zW_nt+zW@S*W9@yN+H8cWnV#1Cu_;uF`%vX#M}VeQJCc6`=&;vDqTf{+00000NkvXX Hu0mjfa)v79 literal 0 HcmV?d00001 diff --git a/assets/icons/16/NLRSU16.png b/assets/icons/16/NLRSU16.png new file mode 100644 index 0000000000000000000000000000000000000000..f070caef05445ba6432dc0b1690b67bcb280173b GIT binary patch literal 749 zcmVmus13mXL82nHE+SN9QG z)=$7z_{SREVMqEFyAB zCPh)?`v-&7SwDLm0TZPkl?8dWXe{ArXfSH#yu9YweeH7)G{~9s)f|H1{x(&djoZS- z`7Wn(JpR}0udg%MONx~iowg8$lSNqD2;cH91hE}X)R1iQ;JwxwhT@Z^q(mDE27NLb zYgfpZhw|jI-mZ2t8xnTlo?U~z@ie$11xDVxc?x1>_RFW!w=K3t?S-C8s5F~RVDNwt z(py`jXQj&S*>!A(cj1}afJR+_`r1-01G@T;09X$40c;5ZgwQ5LS`dsS4LwscE4;83 zgT1i~Mgs?%)rbHe#n1VT6oAqF7G4arj5DIGMOy%V(HRHk?2C5YuaCymNC~O zv19~=#48aHv&BBBwLZuYyf4S9`x-CiGXV4%Dp)p1<5DH9JJ>gQ!KQCL?m=1 fftbkNRxbVk%2W{t*Z7^t00000NkvXXu0mjf8yjH_ literal 0 HcmV?d00001 diff --git a/assets/icons/16/NLRSUC16.png b/assets/icons/16/NLRSUC16.png new file mode 100644 index 0000000000000000000000000000000000000000..20a2e3078f3d0a16f6a6a55d0ff123140fd8e7cf GIT binary patch literal 759 zcmVOYKJ#^7`sZBXxT=F*&u0(&FRb)JpWco#YvaRTdu~jo!8t73(h5T}F=4Xn+h& zgphi(DV<7_C#Tln^KW5#)(Nd95e4RBIvLo?UISoB;9c-~Jn*>JA+kgvxUH|VPb~8u zZxE%$S;)|HD6(e2#Ro9+-5CMU8<)`4T#+F7LhWFr7Jz}{G!UaAD4ek7k(hRA6N&6z z-^7S*vA3~}zZx?!$9yLD(W{M@3`Bb}ozR9#JucSNLKH>3fAbon_US&2n!jQ>osJRP zf*e^phrDLdN$S#SZAPJ<8vxm=E04+r8~0!#m#nPQ7{m6w;B ztk!}ZL~Vv^eg;E>9}wA=WCEGzTkaE(CXl~!!w_L$t&{;4vpGMGySyS+B2}1L_<^l$ zF@{Oxyt6fwOH$$|zY`A@73td7!KPS8yL}8wr4me@j8AhMWJzfNOnZA0P;Zdo`Mo?0 zPkPWjunfVsgHuA#F*f!^8>L)Um^*h}bHa=SZTf++erFSKqc#&|Mh%*}9atR)=0n-2m zMh2F7Tka6yR_rch!KMDpBnw8urs6RG2I}kWS$IGGY++zvFlS)+x3y%#sUBo`CPD`A ze*DodEh|@U@8aqpA|}z@Q(#ttYQTSnKmY&z#bX4ckG`=ngSdnwgN~j7NQ*a$7ydK+ zZ+&@jFTQ9zar4?$1$9krhTAu9fcPg-jAtMKrexXk{9yYzn}LDBf`Q@xme2egg^i5| z{}5%sG#4=ohW`xn|1tLuID$f8Zh5pUf?_H_tR!d!YVRCoEY*?-hF2{b?@yR&flD-SflX= z%MSw)9(JsnK>#EUk_V~7nGP5U1TRb;XG(ni`6t7=Gf(iD@rQwl@eKgiLvL%b?p`kd O0000s7P=VZ3=>aA<65YREy_gQ!(R z%0z0bLGgM|Jk!Eoi*;`vyPxfz;cy<``#tB~17I*127|zy^g(zQq$@_!s(OVxvv-<% z2gV?GF_0$i1Hq6_2m!@H{$Xayv$B=URe>osa7MaffrXGSyt>vr)@rrI^7G>c09*i5 zEMN>tt19Z^>nubaP`cQ1I%q0*p-se&Y zB1-LMUlPC&whlqW_~x?Twyn-PB_!FGw#;JhY(S!<%GU1>yOGZw25x- z6N~|-WsMj{kpKGII}R=7{Op+RGeNr`QReyEpssD~Q!Q{5#PZ~CZ)4NU^J^7E^)@!m zJiq>Ti0W;uWS(F5UzX}^EHTfo-65*Cv0mo+wayU#dNP54alkIo2?PP9N;ijzQQr3Y z71yubAoc0*ROwuAoP4pGwj5=Z{2X%-C{I@pD~+3 z{h9@FtSuY8VJAlLJt>Dr2-*8qYsCbE`un0xX{XONtv#RzkNWzZ6xVMs7!1Il53<{S U5A6A?c>n+a07*qoM6N<$f{l9kumAu6 literal 0 HcmV?d00001 diff --git a/assets/icons/16/OBSROT16.png b/assets/icons/16/OBSROT16.png new file mode 100644 index 0000000000000000000000000000000000000000..d3864a20c38134944bbcfdbab25fbcdcf2d1d2da GIT binary patch literal 411 zcmV;M0c8G(P)tbb$^ZSI2mn%t&1e>o&1WxOC&sZ@ zUC4qVy6Ma+WX zKg0b0jQ=^{8vZl>U|?iO%-Zwn1YQGXx=CvM`~Pphg|d(YKNlNZ{NuM@3@7fsd%?uW zWAqX#BzQ!$5?G9jj&# z0EvU-LF#a(14aVD3zNs05?_D*$*}Is6MSa;VPIl>0{|Z)k)j1UN=ED&CmqKXCg(jT%xWEGdJ68Nn_c=h7&wuKw^xqmjxWEGMRg<@1XV;C{`~mUESsP!z|6&(FQP30 z4(fL|Uo-st^u6)v!pkd=UC0PyNGIsd;gc3f7E~35*mmUwgOHji11!WpJ$Sp~@q){d z=wZYJW2ndrWqf}6anF~h9~l^#nHa?Mr5KPy{0G1?ef9axzu&(-AJ0Ps8bJd<02C|t p9=*3<`p00T($$bC-002ovPDHLkV1iBc@;Cqh literal 0 HcmV?d00001 diff --git a/assets/icons/16/OPEN16.png b/assets/icons/16/OPEN16.png new file mode 100644 index 0000000000000000000000000000000000000000..db975e302cd60346cdb914bd9d8ae830cab1955d GIT binary patch literal 424 zcmV;Z0ayNsP)pMmkfe@3RpJC{$LfT>}^rCCkS)PwQg-@}Xy3@`ru zX9@*j5E~>0GMJzX)O1Xa|7T!4dHc%g0+^V(zPZBxKY!0NFfv>K@mc<{q~dgeq%gPb zug_c+$YM7yo_xT-z_5~mfx&@+;s1+k*G}AF0ZFXxQ277-`){x!W@bi)_aA=R=JXvr z!oa}r2i;&!mfscM|FT%K{9`JFhr#PNUl=@G)WO)ySdM{->HlF|F1vW~;)kEie{8Q^ zJN*J42GdGJ{xgsWvU=Wt^|HVO(kdnpt$9`lJX{%Y1|qS51;+UG^E<4q=rw=kHD+)6h>PZvSeDgLt!{uww?=&_t{DB*A_3R-AZ&zgo9&R?g zn*aX&&v57d8-{-jjEyK>kdfqK;N@W_Z2O(p44^cV)AI(B8etN5?!5tHx&r{a!-ROP S`E85<0000}HR literal 0 HcmV?d00001 diff --git a/assets/icons/16/OPENFOLDER.png b/assets/icons/16/OPENFOLDER.png new file mode 100644 index 0000000000000000000000000000000000000000..7ee4fef5b1bd579a62e1f7e2183eb7cf3bb1c263 GIT binary patch literal 308 zcmV-40n7f0P)5r0002{NklMPkybH*WX-cW3cxfI1BHMEMEw2phhc6{2?H;`5J{S+mWW&i z8}RDc0|pUcZUzS%8KO0R`6|k=WA_aaumR5=-C>Xv=VRdEW+U2w7cW0EFfuY60EfZz zM|T(`#Cb__{)<626jc=c5;$#@^G;%oI4? zz`DWU0fYB5pB0_Hx)c8W|G&Ry(-sFMz0$=EjYSL$i(8C%)=WFM8|XX+Pgg&ebxsLQ E0C&t(MgRZ+ literal 0 HcmV?d00001 diff --git a/assets/icons/16/OVRHD16.png b/assets/icons/16/OVRHD16.png new file mode 100644 index 0000000000000000000000000000000000000000..bc87c10cfdeeeda62f7a37efd6fcc8d241a02b57 GIT binary patch literal 162 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`nVv3=Ar*6y6C_wgnB4>f=gzr* z;KYf5vj+~GaGJC2fBnDz=^3$B8!5=rfn8qKlxR~hB!4g zE=J)q{`>2jV_ifVR{Z_Xek6@C`~Ue1R;ABuCNWRcQSWDB<6&U%v<$lTMJPWRXeooI LtDnm{r-UW|CVM)? literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPBACK16.png b/assets/icons/16/OXACPBACK16.png new file mode 100644 index 0000000000000000000000000000000000000000..8376703e347e2526c9e3bc7eafbdc44859f4b80e GIT binary patch literal 269 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`S3F%DLn`JZCnzv_ER*ccNX`7H z&~0dT(&O*(Wjo%TGqC`|Ns04d*&nm{?C8-A>OTHF27t&K+3^o4~5wEx#A<^6uzHpE;pBykbE^$Lb5hd zFCjsoqVekbEGxD5SHGSW?cihT^i~Kn zw=ycpTsYjZfKi%*MeC#kuls@~2H{kGjf99Q!Uzopr06a5cIRF3v literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPFEWER16.png b/assets/icons/16/OXACPFEWER16.png new file mode 100644 index 0000000000000000000000000000000000000000..8526f16b7596c14cdd35fc63ebc26600a8295029 GIT binary patch literal 199 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`eV#6kAr*6y6BY; z`x8lJL$(bK9SoM5A_sZ<=N-JcL&w1|fq4>}z>XsayAQc^{)K#(SGZ{LK9$5=E2_$pxb69F2%VWd9aMjgx`zh<&?|?32@O1TaS?83{1OO8|MKu5b literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPFWD16.png b/assets/icons/16/OXACPFWD16.png new file mode 100644 index 0000000000000000000000000000000000000000..9e91991cea4a681e01ea64019a055c0b0536c003 GIT binary patch literal 252 zcmVnkAh8JlFJ{$o>E_v9HPHcfvS|6gWcU}#j97o2dg@!%g8kYIqE6pH2zkDj6M z|1$o+k7j=N-G}e&?d$CWS+Hri#KDWg|No!S5#i?l+Zh=cdYS(VwSZi}fDNeWn7mil zH%IX+Ht&D{69b9h;lhg#kok=03P6Dh@`CP<&nS|}fr<=RunE?Qfx-Y04(MS-(0~mD z0+nQ-h9^*&C^H&MAd(uWEX3G?FHngx0ADN&JOBWw7DjKH!A6|`0000knv^biFhm?Ue&<(q{Q&U bO9lq1r(*3}@-}w^&1CR&^>bP0l+XkKMtLRx literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPMORE16.png b/assets/icons/16/OXACPMORE16.png new file mode 100644 index 0000000000000000000000000000000000000000..08672bfb72172f9c615985a5e0f54248c4eb4f9b GIT binary patch literal 252 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`hdo^!Ln`JZrzi-WProFl7`y;T9b-Z3U6rYB1RMDi-W@GL+3;*rh^DTfC_ z?D}D|H|}gmdKI;Vst0F(1x ACjbBd literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPRES16.png b/assets/icons/16/OXACPRES16.png new file mode 100644 index 0000000000000000000000000000000000000000..6012fe34df841466a4d6092bb041d143968abe57 GIT binary patch literal 404 zcmV;F0c-w=P)mQ1|2+BQl@q4@9w28IARDHP2c9zDY_@c+O6ci+5v#qj6PZw99SjCWw-EZ8($;^0N$ zOWN0qOt`@0EXDod$KU@1>uV=aY zpLsX8n1Ta4pD0-V=cm^UUtc{qpv?H!73>0h;O<}M5H>y`2VN;PxELFcAj9u(pB(Of zdKZFW04Pu|{rJqF`{VO{Mj0uFTW|L>9Od?7`10Z|YMA`}&A`aWz=72Tbz-0}fP}+6 zMka>O&-OE%`DWaRu8xK2-wup0z!t5bKwWd^Cf4vG3V;GtUEf>*n;a7Zg@BQe0&t*m y@PYyrMKLU;vJhhna-f0$a>66Z0BlKn@Bjdy#eUV2HxL^D0000_Xwo z$7@M2Ffa-HV_@|7&%l_>z`$@oOH}m7K?Vi}7Hk?=zu!dR|7B!Z&cMK+!NBleiafzEr%v0Tbi@!yq>E|9_?r7hbsmQ_I9a z1bDXa;)VbJ|GP5(XVgX3jMW7)c1{05Uii(ah9ZqCP+71E3R~u)@X^DFpaCxk1S-iu zO~>TDy1uyrHaRBBjK&d-qy#DpF}C0fRH6*P7YhRq0Qrzt$FXK&`v3p{07*qoM6N<$ Eg6pP+x&QzG literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXACPSHOW16.png b/assets/icons/16/OXACPSHOW16.png new file mode 100644 index 0000000000000000000000000000000000000000..ae4d4e68eb56699601b7fd0d919556bc72d02e99 GIT binary patch literal 196 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`-JULvAr*6y6BY; z`x8lJL$(bK9SoM5A_sZ<=Lx=L63da&EBs&-z;dO;=ichqv$X{lPwO;VEg@mRKDt0a5rESJSK@46i7nCgg{n)rGDZ(pN t@z^vg!+=9hDtb>^+@~-uQOW(q%<$D#SwH>106WlG44$rjF6*2UngEq-LPY=o literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXBOLD16.png b/assets/icons/16/OXBOLD16.png new file mode 100644 index 0000000000000000000000000000000000000000..6666e2fbd109d6a0a81279ad4601be1ea43394b7 GIT binary patch literal 413 zcmV;O0b>4%P)G3TLkDPGo;SC`WU$VDT8($F?}c&EyEuoeAt)&D6s6G!oO#V6ZWxL%T zMX6u{pfL{va!MTn9p%fF!e-Lg(~`=t=-?2uSu4I`jB6kqDmC6ezD%7!AcFP#_Jm~Y zY@T51#x)jE2rSEz?6}AJP9moF1;G|FvvaP3vbW*5LGBK_GW`ueMA-00000NkvXX Hu0mjfzGJb% literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXBULLET16.png b/assets/icons/16/OXBULLET16.png new file mode 100644 index 0000000000000000000000000000000000000000..400ad928d122fa638189ea301c00b22f1f7bd19a GIT binary patch literal 173 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`C7v#hAr*6y6BdX~*uGv|VC(wl zilOqt9TPU^m;F3_;@h0L6Tfcksa?&d$+n@Pz>% literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXCLRFMT16.png b/assets/icons/16/OXCLRFMT16.png new file mode 100644 index 0000000000000000000000000000000000000000..de4ee2357ff2f2f02f6b517a047c0e4938543014 GIT binary patch literal 482 zcmV<80UiE{P)RoQCQ{%gJ(|;(nD`}AP^o+ zxG)iUd4JggT}m>5lyJJbJ|dW=YL-Ttvi(*$Ar_|}IKP=!$6hvz_t-d)|uNdZvCgl0yG;Ra~xyH3xQ^L34;wkb)LPO6Q2ti@t+ zCEzr%Y7%#pIgH&x@?NVxKwud!b>=jBDp8r0WGPbhls)|ND;Jg=U)57~Oe?9Fl$i^$ YXHFc9;!Tv}cK`qY07*qoM6N<$g2D6DSpWb4 literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXITALIC16.png b/assets/icons/16/OXITALIC16.png new file mode 100644 index 0000000000000000000000000000000000000000..9bc3e78d6d8904479c0ca9f45a5107c88de11cc0 GIT binary patch literal 278 zcmV+x0qOpUP)1+mi3Qt%ayh=Q*ac3SuY{V@s=6zpPQK(4T}OKGWKvT_zSCKpbpS=bxC z+2t1aQMw5kL+Ff{-OMBnV!i4ucpO z`yc6=j((-v1mWB-z25iTwZI?6bq~5H&&`D~M%~8K%T7|}+-K_oQnQRV_*}HAcx!+g z+L{_*_#oM)2r@L znTy_B!H<+yAyJcXU&U3*Dy;5iV@2LueWEh|hrR(OL%y*$f6Ze60000Xnsf6w{hk4Uj`t@bs&-Cv2W<^Z%hm)hZ8cVHBE0EVL%ZA0!O zqI?w0lrR@moVN=nVK|y}X-SmX~8$3C`f`wYZQNZcI)ZzAYQ4Grrge}dVDNnf9j1W6SICS4rhu)b_B5 zBem(<9;b_kn|uR5rT>ZRDQ+8%D!_h_$Lk0$ehm!x4C)@7;+Qi`L>gTe~DWM4fp#(OQ literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXNUMBER16.png b/assets/icons/16/OXNUMBER16.png new file mode 100644 index 0000000000000000000000000000000000000000..8cc95e01f00b9c51d70aadc72f65910fa589bbcb GIT binary patch literal 347 zcmV-h0i^zkP)j)$9qT1+4i1%(zpAinjjkK%tNy z!}ZNA{p+}Qcpzhd5t-6o7MeRy=_5M8Q!*PTkyCp=qEJj4*S^itr=|cC!J`#7*AX{? z5WGX^S6bRL tHD+~~?OZl?@Cu;{8dc9cP-0al2xw(1da!QJU56jd3oBuShc!wtH z>uY_9#2S1($I)Q5Xnbs0#^l5kn9aKpkFQS3&j)*o4TQp%t=2kUQ%j>(SSThGV#<+* zv?T@y+x&F~Rezrl{X|P!U;vB_;eWvSpgirrPOmx$EVAFW z52w$Z#GTvsapB^riY_wAMZ}->!m(3EKCd9F>N~f2q|wW_*53(LP=ZU#aw?hpf?D$) z&@q9mzW_w)Z Wt>g(uc_Xd>0000CYSS?mpLk&@IgG22S1P%2MM6^T@G&;361QiHDL3tvP zNn|1s6n2AyMnXnZWOo-QDR*{v5q*b;hu<6D--qWRFi~>I%RwT$qG)OFi^T-J8p^2o zo@K4FMAiU=pRCr5Q5{hZ*T|||od`(Rn3M#})1%12R*7dK%cY*O=<>zcJ5dSR#5Zt> z5W-EvAZ;9+-|=kX@P`8$2FX3*#?(U;`*|6+!~xS4^mM|qbbayV03aO{Lk2v2Jo~2s zif&kM!$*0Cw_>eO8YF^`Bxs<}CKy9R zSO_a-Vq#)&b9LZhVP@YRo0eyT(*Rt6gPon>$gxu(CeQzWOo!w1^97LQSr`a_+VWh6 zZ{NSez4P(YdyoMiuo^IZ?sA+4WhO_0y~Fb73(ItOafKH@UOs6&$nb{+T@fK5^X`ht z|G)p2i?NE9GBCXEA;|@tzdtdEeS11v)xd<|_JuRuQ(Z(Eh<3q;$9EVM?`>wV3l8T| z(9&h#+?7R+Gh<--8d{PE3ekPH6&XJkku=mMB#b0=50=4}gR z{Q3IzQ)JHW*K6>*;O`#>hSenuPGPZFHG`Dkb;0Xf7a8^*lz?mAx^O1Lrysu)3!s`o z0G1b?GcYhnpgUjk^DPFQ-?tff1Oyr0ynM-UozL*gH(n*hS+n}ypcsG)OmP!cVfx4D m@Q?BTnb*HwUjZc?bVUF!v$J!FzTDyf00009nYiy literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXRPTWIZ16.png b/assets/icons/16/OXRPTWIZ16.png new file mode 100644 index 0000000000000000000000000000000000000000..cf13438a171e4767f04dc8783c63ab6f20e3d067 GIT binary patch literal 442 zcmV;r0Y(0aP)xs<}CKy9R zSO_a-Vq#)&b9LZhVP@YRo0eyT(*Rt6gPon>$gxu(CJ*1YH;1P=i@6}nvoH_Lz`$UL)qv@9m*X@jCCZP1_3a%7W^NXPDQ==FIlErp!7v~*ITEJ< z*S0KT5S3+P;1T3uxOMVP3IhW}1z{Kb_{_j?^B@Dm;|mNzd|w$X0%RH3xmg%KzWPx< z&4nTQ|9^&!cwO-E*?opn^UpFodGeEiN06O?je~`Om5rH!M~IE#?K38kzrX&;6AXjQ z>X{6GfBj@Qzj89ext+7Yns1+bJD1@%LqX2L*IyW535gK+{_*Yq+1}Fs7Y57xpW-TN zKyoZ(g1jfH%JB8cwL3X`USGg!0KQlNf%`(n4E%3j6f!Wpf{VcncoCagD1lcu2>fUG k!X@c-f`Q=%L8U|k0M#_7bL??hM*si-07*qoM6N<$g2PJ4UH||9 literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXRUNBAT16.png b/assets/icons/16/OXRUNBAT16.png new file mode 100644 index 0000000000000000000000000000000000000000..6b389e96cc5d7638d7c0a12062742ead5559f350 GIT binary patch literal 590 zcmV-U0%e zbrmc|U<5HM!U&4~FVeAaV7jy8(Rt3!kDSR)+c~x#_%7b>eV^xh-tYZBf-*3^>l%PX zSm7a*+7k=2Nppgj1wvy13wtDZ9~_qxG@_g}i%{lb*MUaMq9_VyPM_LK+Z+k+m7$Xs z2h3mV9-UCapVc)4hKCS|Jpsq_5Jd@vLIJiq%{enM!Ra-0sW>zi@a$%NoDJiu&kJ|+ zA!9GcXBz-;6)m{_VZFEK1j3P7tYve?Ue!A&M~%aQFoQ-F1ct8_ zNpHR_;O?VIT)OAS3YW!(wAoP_H(gGcdN^wl*>dH;KA*<^RwwecGNcv}d@7r8_je7Z zqo1aYDa0OxEM)!Ui>x0_$6L_b-i`V6dnl>`MU=6;kdjrEbXIi`|M?8{txgadg$teM z;XlS;bbb<_SAJmM;Rc#pTxBW*1_$~o1YQQ`K-bufxUIe!;d6Iz>s1I(GYJqv+Nw_B zNK-o`K{Dd>dImRN+{WCmBqTwErr~?ZLB@Oe#?DJAg8%{R6o)+r>+tw%9B+SrfTR?P zqQWvS&~QX6KGSY+_jmayyKPGEnXa`LPu9sqRr^wrkMaKs6h#J(c4)H9=soY)mZM8E cUov`f8v$+F&~!oq`Tzg`07*qoM6N<$f;y!MH2?qr literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXSPOTLT16.png b/assets/icons/16/OXSPOTLT16.png new file mode 100644 index 0000000000000000000000000000000000000000..d05e63a7eae971efeb986110fc0f8cbd3951a332 GIT binary patch literal 399 zcmV;A0dW3_P)>yM6$TuD3C8%(#263KY-M4_0K@+om>m8y z{@pyKUX%xy0W5F>{xdizNi#DXJ8=pwsjb4tpe|{qaP#u11_lO(5^M%Af}LM3uE5E` zeLp6*2}8k;?_U{K&1(De?fW;=oSxSguzKO|-+vC0aw=Gz$id0YVBzG?!pQJ{dVM{@ z#V7_aG5)ug!eIaisOg$9NXw~MNPH2^z-qw%{|q=?00TDeVGK;H%+0gPgk(?*m|iZf zz|GC4ARsJ;*8q^bfrX2}pMOmK$l@#@|Fg2OF`PZJgMkqE`{xe>6BAR&loC;ooSxTU z4UAJNL{&^J+;20G0OVA(8AK&y8CXPO7{Sr_=gpG;3PJa9YIv|t39C5B047pw#%c%y t0b7VR039flbm7(bpr;H>Q|twb0RXXeUwhK2fp`D_002ovPDHLkV1hNSuT}s6 literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXTABHZ16.png b/assets/icons/16/OXTABHZ16.png new file mode 100644 index 0000000000000000000000000000000000000000..8a245a56abbd1b7e2f78b1f9ce96e5b22ab4a5a8 GIT binary patch literal 131 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`UY;(FAr*6y6BY;*Op<*Wcd4yj(_@xwWA)h&f^d=d2c=g94K`W*_2MuHODiVxtrT zQ>bZVMQ&d9OgCr!28U&<4VdjNTx&`@u*=t4B5&{Bvjxxp%CfP&bmy_JpKiQi^QMQU zEO`!MCKEl5zcw>4Fq&rkPx!flo3WR~iDR$T42+CIjExMg7}ZQv_AgTe~DWM4fm%n4w literal 0 HcmV?d00001 diff --git a/assets/icons/16/OXTABVT16.png b/assets/icons/16/OXTABVT16.png new file mode 100644 index 0000000000000000000000000000000000000000..547549401fa1dc8552e181a1f57ab00cecea2bb7 GIT binary patch literal 136 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`{+=$5Ar*6y6BY;7 zh>c~)@ecoatjAWYI(cY9PWH@W4j%J5Q_LS1IWAjmASNx46Z6Su%C3gYD-3Oc%n|~c jf!Fp)u6J_!l)}u=Un>|madEvW&}arvS3j3^P6rxL09;nkr6D$_@D6uiXH|upr&JToZ&x% z2Frg&O<01Fx3}kDd;9e|i2X~LTl3+;gFkQ@psr(T^6&q@KP)3kv$ybH3j>ob$miB}V4Av|rQ1#fIorlK^Y$t3Ay-+q<4{ z39x@w?b%>9%ZyFT)U=>3AX2$0eAz~N;sMn+POw#-7J!zo?zbB}7SBB)<M+y1=Abt1m-Q?Do{;+E0DL5R~Qb08g3jjVyrbTsLy%fgW_z_D#PtX>X*6i@|X zKt3rKt)~Bz5CC1sUDsT1n<~1blQpk^!F$LgKu9&RKnzVC!B9Y%djY9E1NI@KG&j3q zpff{FmWx!7LAH859@9q!j#TU|@KFtdalw3kLN!M-}*3{xS%0voYw(@G~$oF*00u z^nu~yw_gmOfBgBtf~=vxqgDak_E|Lr4E#^_F=$BgGH|jngT+AXQ}^Ee`N#0T6U6`# zVId6XzvfqEP}kOCIJ0{ygOipRSnSOG_Y5C@{7%f-^Lh!vFyLTkXSj6oD1!huE5pOL z-x%(^`~qhG|NkEx226wus4dTB&=F!}c=6!}!>(6645yy|+4B7TcaTPBkUR^zhUs&c zW18~(34>EXKf{cDw;1kxc$;f}Z^cpu2F7v}H8Cj#{|SMD@}~ds>G>!D%|et57#J8b zlOwT;vkrP002ov JPDHLkV1lgtz}Nr) literal 0 HcmV?d00001 diff --git a/assets/icons/16/PASTE16.png b/assets/icons/16/PASTE16.png new file mode 100644 index 0000000000000000000000000000000000000000..452af8eea19c1bbc75e0f2df21351dcadbbba1bd GIT binary patch literal 386 zcmV-|0e$|7P)F(+iA@V9g)^QjFE9AbCbc3@Hk(1|1Fn|H!UlRi@yfMYXKm?GsZERp5yu7%#nuRF;GBU7y{QjR|L5VuU;j14Q7Vde* z@b(i#oCVpxFu=*dfz>P9&%9+w^^j&TQ{!i-UU-M$#RUe^(!u7FuNj`d`^gZ|af#vX z^KW1=unQ(knT1~`D8T;xWdUiPxbYDz48Y<qo literal 0 HcmV?d00001 diff --git a/assets/icons/16/PEGACT16.png b/assets/icons/16/PEGACT16.png new file mode 100644 index 0000000000000000000000000000000000000000..36c715d59f032284c5c11be01b262043a6c77863 GIT binary patch literal 470 zcmV;{0V)28P) zze_?<6vxkf-Aqj}3DNL@Wep(>1wuAR{SP&?Nvl*#OY~EVnrew?2?FQVmV%0MX=pGA zDUeXmdM0UNn%4E*xRvR%mt=jXbI&=S@4fd6@J}JL)9XQiW&r`Ni=;p(&=tfxmtJS) z-SxqrT3y~EnBBay7y1hijK!t;e8Yi$%h@N-XsO0>3!CmiOm^Zs%baNHE8pww|3pA^L~ML@79u19>AS2YbRE}MxU?AKdcyBZYb z#}!`)q;4KUm=b5i7ZhX-3~rmIDTn>~E<>-D*L{0xCYpv+C=n>Ai8HYkeERxssZeC` zc(YL}3p24ko3lMhUgeT1v8quPF6m=Vm6BfNq44+&>2UH#12(VL8=6IyBWH^15&!@I M07*qoM6N<$f*UN(umAu6 literal 0 HcmV?d00001 diff --git a/assets/icons/16/PEGTS16.png b/assets/icons/16/PEGTS16.png new file mode 100644 index 0000000000000000000000000000000000000000..81d7cf4ac348a3d9be38c30eddb26359acd4fb08 GIT binary patch literal 455 zcmV;&0XY7NP)2sIE#g3ggg~b3YfRT|A9#GNA`3^^qpR!>5&+vzl zf#Co_FHE1i988C1W%028VqGsM#qFZ2#>epQ9|Oa=s~;F*QVNzROY4mJ6 zC8Ro2h5OeJOn;#4e45>I{0px6u%`nX{z{JGJkQl7M zz|YH;5}%&0fX54r7P@NuSPf@oVPw!y;$=8_>AeLL+zT+wzyS6FBNM})fB!HODaacj z43cB||Njrpq|C^~U@9iaak{-&8|-Xk@a@N6hLVm;e}4XBltq<612HKDi>(ZWV-kbq z8CY2$jsEfQ2ja$%VQ5e(U;4 zwG|%glCsnTnlT~wkh<9iy@W%e9WQDG=DyVOsZsD#Hj)i6R}B&sm_3(KXY=0)(UaQV Q0j*~6boFyt=akR{01dZ0;s5{u literal 0 HcmV?d00001 diff --git a/assets/icons/16/PJOCKO16.png b/assets/icons/16/PJOCKO16.png new file mode 100644 index 0000000000000000000000000000000000000000..2c0954fb7056d765c0b900a4850ff5291db09b06 GIT binary patch literal 514 zcmV+d0{#7oP)j9ozn2vNHL9&DZ@qBeJB7UDIv`1_l>2J$oJ>tSw|< zV0Z(P`*!up;`=%24FCWBWl)?r6;-8-UDN+*yWXJS2;0p6k6Rmm|NsC0^pB@ce_!); z2iyK`(}w^5|No!B0@EyQ+t>i2+ghf<4a|zLU}%th!SH_TX%<#dQIk)H4l?|C`<6j8 zCZ6G(h!#VdOWPNO?Y2!ITQIqLZQCu@Jj|}W(kJmwL2I-{bph) zU-kf^8D_7HUDJPt{|pZp7#S3p**FQA$H2tG${--G$H2_a#qi?7E(VYb_Bgv*xh$x4 zW*`=*1dE{`{>WF zU%!bmfSrSl!PHcj;mgZ=5CfhcY<%qk({2Q@7h}ELRV*+`4iNe>>dEZUmS1PH#`U+CS$1&^Y?=NXFw$h+edGd zzSNuS)HxF?$!=pW4PUb5D5bNRm6hB=SEu5hm~c}{=~eDGS!c9a<#WX0EC}{>?}fE7 zisa-hr_yR$zCH6njK`rpegbdmn{iqgSueU9?XpW*WI{nYZ!syZa)yQmXkHW*Oy+O} z1qNK}*;i#lJ8En|@8v594Gp47--McTRvdJ^M;c)+(`uOuzu}qTp#^`a)B*7As)Vk7oim5>sgR$jgsFpB7C3XaHTDxvI~v-FV?ep)(-~t zmB!FSB1*d*=2ld31l}hvF_sqKmketq%k;0fE@<1;ggj0WbcEP)`~w7|QNJ7rS9vKzDD&^YI2g_aDMlmbI<(({u?Bnn60u4fRr`IeYZF6C}hBAacN|< zKcg`_y&x5pz+{=4B!o<$Sg2qs)R`1FTjWpmk4R|vv@Cq{;8D>5zBTkO^No>H)V!Z$ z^mwyXR-xi1K|*Ky1;yp$88*5Kkuq$V#_>?vm^1+3wmVv-nC)xq3P-Wfkzh$x5XP%{R zQ({w@{%1P|0k%2=dWB8Upl9k)Val%0cb#hxi-2QMh&nDwua31!K;S7vE{^0asBoTp z{kaBJ4PaeMIJk)*{1yY%8?<`;VDMao;f&gu_7aWl6BS&X^Marv-!atEpcdC*YeorA z;odpKN>qYZse8%zOuu1Xs%#S|-R3wVMw!wx;0moJ2EG6&BD#n_sP`8D0000U zffETEE6VJ`#IR%c zeh`=E|39X~@%i}zL>pjfrpF*A#LHl7VaU+cT)`kDD8Rt*g8^;;3$o(rbC;uNzJB#0 z!`_3386?!y7}jjq#Bl8RNd{&%ZWJ{v$ehgNNH}}%zJm-?rcGhEdiE&8^t+E4-amcH zu(Yt4K~YhKK}1B5fuIXcoH!1)8KfBm1f`|H{BIvVF)-jVAQQ<2YKl?}d8Jign?agE z^ov`!802IXaC-q6I6K)hINRHToei=Xr1{UUUkr~QJz#kE;gtj|GyMMji{ZoD_v_Vkj5Xj2V^RwK69ewvyZ_(V!r{M~j>&&D9pmR9 zLx@U=FrcKUz+h@-$-uPqf9B0AXJ^22<8uZE r22j8d2LBnpa4|C}&YIQt2E+#d9&xj@mwuCN00000NkvXXu0mjfHq+&? literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRINT16.png b/assets/icons/16/PRINT16.png new file mode 100644 index 0000000000000000000000000000000000000000..2743edcf351306937f0d0ad3c84cbade7c7ab843 GIT binary patch literal 264 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`=RI8eg`PD!LTF`vYjie0lr2O$y!*nCUVc8d@9MKNPds=Gd6+jWEtjw;dnDp#xrvdX@n^49z}J=vpw}2Y MUHx3vIVCg!03T;<*#H0l literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRIVLG16.png b/assets/icons/16/PRIVLG16.png new file mode 100644 index 0000000000000000000000000000000000000000..73140d2fc7a8aab6760f7938c2606d882680c7d6 GIT binary patch literal 243 zcmVj9ozn2vNHL9&DZ@qBeJB7UDIv`1_l>2J$oJ>tSw|< zV0Z(P`*!up;`=%24FCWBWl)?r6;-8-UDN+*yWXJS2;0p6k6Rmm|NsC0^pB@ce_!); z2iyK`(}w^5|Nox=c7e2QV*?`tV>JUK0}HZ&SrHZtK?kNY{Ce`3K`bGO;nSgm3_tGO zWe|;tXSizM&X88Sx)oxxZ4<}_tl-Ck`~R;v+ktHb;RmG!|Ns5@1C|5nV*#7M$iOmv z_gk!irXwrLVA#>k@SwDifn7$HLAa`gVd?Qt44=RM1M6cU6zW$V|6pK}(`GQ*xQpQz zBP+wM>)#=op@4;f2yp4q4~9#RK&&4aa!d>q0;ZvF01KG>&+up7mODfRC<^$`@CU5v rKg0jl7w30jq(nlRLHbCx6deEns57|*G+?RK00000NkvXXu0mjf*Lb^R literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRJOPN16.png b/assets/icons/16/PRJOPN16.png new file mode 100644 index 0000000000000000000000000000000000000000..0f109703b16eef00186191cdfde67e05a366b247 GIT binary patch literal 324 zcmV-K0lWT*P)Vu*ldo{b%^k@BqYleeEzo4NNSo z3u4^P)9;|%$(T%tgmT@sF(CY!?ppye;-Q^Y$m0ANS;4wn5dLVb5YsT9sW ze3HAS9xP28ECWf?y(QkL_`nx35?dUQ31kT2w+D8dpj

k*vlx`q8OUdXE}FxMs`IFS??&|JBHW%i z#7{J2eTE|BTa)2i3PE_)1C1g9?N0$yJ@>?70uWQ-E;LrAVW}<$o9YJE7mGYW><@hI zdVi)i{Rs0@-7t&x0s(t#S=e~8EL*P7YhkGd5cs60K43KCSEAR$mcr7(693qf&>%04(m#At>9fQ~k3c7IZ zOcGyv!07xGT)Ez9-cfTdtawPY&Fp;F;@o5HzhsRNbn26T=?mh$K z<`M>$jrj}=PtK8Oz`Oelj4Kit%*6jOSSxTbu&m2~8^S`0X7$hlh}ee73`f^xFvv2w z6ENVzBe-U1K~A`^Fb^ApwE_dfuUlIP81U;G1M{En3>>Un5bnLRa49wxCI$}Xe^3Md zGyIvi(Aik?Zd#p zz*vtg&qBxmVP2ju?>_(f@cQLTfgeA@c!Dg?NQ@V{3M^ch{xh`yXJq*C|36c1 z*~DWPh&Dh?$E4*y14A^LtxIoRIa5Q>0976191&sB$-cgR3`|Ur;QIIPAH(L&n;71_ zeVu#z%GoJ64N%cFv*6+6I2;ob%fiLQjUxB$+gFAqOBVn6^8JS`1Eqj*N{Ofh)BpdA z85kK{;G+K-_WWaHjLqqJ{eqAIEKH357aJSMxaeq#GcYnTGW`GlpW({&mo8^7K3UAb zz~D;I1=C7I{>MiegEhk)@c%!kFA7oK3m e0xnyT4FLd;50Y{ikwHoT0000>a# literal 0 HcmV?d00001 diff --git a/assets/icons/16/PROJCD16.png b/assets/icons/16/PROJCD16.png new file mode 100644 index 0000000000000000000000000000000000000000..6a3c35c2c3547517be898331581f9865f0aa70ad GIT binary patch literal 331 zcmV-R0kr;!P)Gyv!07xGT)Ez9-cfTdtawPY&FfmXFSnx?^xrs1RWB>?ED-rqs zpMl{4QmFs<_m43(r|aYiWmR@002ovPDHLkV1mJdlA{0s literal 0 HcmV?d00001 diff --git a/assets/icons/16/PROJCT16.png b/assets/icons/16/PROJCT16.png new file mode 100644 index 0000000000000000000000000000000000000000..5225efbca1ba14940263bc2108555f9c894c4a73 GIT binary patch literal 190 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`t)4E9Ar*6y6C^SYbex&EG5glp z0|y>7ElWE;*|~Jx4xR+Z$GbzWrYz*xvel3Dy;Y?0eY1gK0LKhB-h>4=7(7h=rT;L_KP~%6SdiyW p`VZ!7EM9^7=iV#Xs|GPK{MsLJd+zB?ia-Z3c)I$ztaD0e0szohN@4&2 literal 0 HcmV?d00001 diff --git a/assets/icons/16/PROJMM.png b/assets/icons/16/PROJMM.png new file mode 100644 index 0000000000000000000000000000000000000000..1cbaf2eccc697a5b14e7a14e09321ea27f620188 GIT binary patch literal 605 zcmV-j0;2tiP)W0GJqtIG9o-YQxCPxSW-Rb^X*L;Q)pq4u*7uOe+=fVP|97 z?%}K<;p3sn!^Oq6dRnPS3d0Zvj0{5*Oeqmf;O1bN?e46`BEZiH7W?+?7sJkdw-`Qt z{85|L`=*6q2!bIQAyZ03D+Kx2+g%;i7e;suf9xu#q*}1v60~q z!w>>PuE?5NDi*-O#?z>tfOS6r{Q{QUWM=8@y~ z8Gilxiy{B_?>~lPCm%3;{q}3aKW@f33_}bI$s!8`rWOk~2=H^(d$_1GaB{GM#s2*H z$FO_~SIzm8TO0j4N2OINz78WLsFW-I_=JdXv0+tvB0|#c53Y)~F6#Qox24Kil>exU= z_uDfJ!vqYA2pLXbG(tvtr9KqP`XzHF4Ee?n-6JGsh?$EEj22mg4A3MidId!M|M>9( zn9a({%JA&PGuvC2&K?U|`7}xD)pbpWrMZJ9Le5^iK58x*V6>Gr$iQfX3^Fhp rA%hHzwz3!oS1W52jDk_XfCm5o*Qnq1^3l=@00000NkvXXu0mjfn41-h literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRTFGL16.png b/assets/icons/16/PRTFGL16.png new file mode 100644 index 0000000000000000000000000000000000000000..9dd1ebe6af026eaafb8718cceb2a24664287f8e8 GIT binary patch literal 526 zcmV+p0`dKcP)0C(G8UvlR|gTq z$u`A7r4&mWt0^H$(kA%x|C9UD{3M2I$Q}Os|J-{H_uYFwp&`PN_!G+(^9nRcz#wA^ zI3lPmm$28q?=B(6U%07~f3O1X&qw@($zEKN0v2yUB5q^tLA*t_Poi4@tUXRJy ziI>>;__fZrEqRgNjsd6&5O8Fc3a{Ms5a!`qh{p#2Hd#TEaJ96oF@k(Ex1jV871S2* zS*x2~SZAYXCsOOH`V{OiHVN;!lMrlAb{Lza6A{4=b{0D=d! QZvX%Q07*qoM6N<$f<1%oBme*a literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRTFLO16.png b/assets/icons/16/PRTFLO16.png new file mode 100644 index 0000000000000000000000000000000000000000..3060ed0ac1f8b80424327d6d451a2046c733977a GIT binary patch literal 224 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`%ROBjLn`JZCoB*!XyVAceT>bG z?N}C&5NopfXZ+{q`49WQzI^zLO<+1}5?Aup9s7*EH_f*?yhpeE!|VUwr$2pqbnjIj z9v%*62?@yviJ3Dxi;X;Fm6^SLybjh2%r_kXnG%GGZ##Wi_KE{TkLVO{1K@Jfm8z?H@fmE#UP3a8|+urNG7 X6Yz@qLn`JZCrD%*;802m;`%pv zaplQ5oIN@Q=N{esE5Vf%%*}afEJ}9@uB3#b8-@Oc z)-DnWMeL&Ks#@qGC5F<(8Z(4s+L?Lf&NPz`EyfFv_qcP+ z48u-R;2Ri{HsgtWYBtkc&*~2?I;Wa~zm^pB@!5+#P5gOkGQ%slDQgOKX#Oo$(3+3Dvst5VB#H>jo;q-wz z`$PQ`p&P#%U<#=Qrsxg1TtfH2D5#b&PEL!?M}(|w^hQQ-X6$|YNMPW0M<`VBfbakAQ0A|=eOfBP1|?wJYcx<{IK}OE4=^k z>0fioNCH0n5%eF3aaxt^3!u1B^okbVEjgz-7G}cEJs$js{pHJ0x(!;vuv{-V)PDjO z-1qc@yUxA#<*P?9{i@*RO7~F9cY$4V8*(xU?YX7fKNL8_HFU>dGC9mB7hT7pGX)gY zY#3mrB$pUZki-60L1ljzgyq@PY=-RFuAr{sGzEkqY_pZCv8x9ypwl9`9fHIxKUvxP znJ(RYDf%L}J0jT2tRVOKxr6oA2w-(DvvR8=24J=RItIp?+y#s$-Vgu)002ovPDHLk FV1l@&2wDID literal 0 HcmV?d00001 diff --git a/assets/icons/16/PRVIEW16.png b/assets/icons/16/PRVIEW16.png new file mode 100644 index 0000000000000000000000000000000000000000..4c01bfb7bb25ced83a3474dd3fc590f2c069fbb3 GIT binary patch literal 515 zcmV+e0{s1nP)U9QY7G|t2WWncx_wU~^Y}~kk;ll@ri@CXZ82I=Ec~DGDZ}62zY*c_`xltz{KNBys4x&07iZYfKM`y*Nb}z5Ga3FfFnsy` z_lpE9Dj7jxuy}Sq))0R4<}E{ESvA9{(`UhaR#sMq-(VO0f5E`O;CSoG*&BFMqKJqv z!{T`}7)~7C&2Z+}J_cJ`2L>i)<}VBkj35{6SJN@pAefXvKu|z{ftQz;frFEiL0nuc z6ygGiAs{b2XJB9eaR`I|3}3jInG_EkI|zz}{R|9@M*v%V#d+%VUdphv^K?^*VwLN%{ssv!pfI7&7mQC2n^}ehsvc!PC{xWt~$( F698X*FeU&1 literal 0 HcmV?d00001 diff --git a/assets/icons/16/QUESTNDG.png b/assets/icons/16/QUESTNDG.png new file mode 100644 index 0000000000000000000000000000000000000000..ae266e8e78c8ccf444112fadac16137fa94ba6db GIT binary patch literal 1730 zcmV;z20i(SP)k{Dk!QBz~;Lj?jchy{^CFHqWUp)IZ3+jiUT%rXC&ncbP)g`K@roBfjAojJ2R z`+fVL^Pm5GXMrpMTgaPNdzx1P$k$JUciO!77QK)PPjjQBO4~WZR>s*n0Ciw+Sl+}D z0?^GFzri@ptCHF}*ye5j--T3rnpcHX=`DcmU<`Gs+=Fv;1N@9bQct84F_y9bE*%DE zI~fai9RWGli5yoU|n>UnkAru9L z%clWsH`?--m7!qeBSJ_zAR*I3w-6j3HaEA*Oxa~OI?Vn+mRrC;SqP5&0u)v@Aa`jo zGKsm#F--V65DHFf4IKAWNolf^5E2Sm<2n2kS9y!km7K*DC|unT?)#YrR~1YQbYNy| zP;bB#lUP%K+ktZ_3#srNX_Qp;tPsH%3M(FktF#LL1p*^|m>9e%vH*!uC28AW+y3^X zg@`es%72RP#2AXIHzL1ir7aRqHWZ<0a|t%oEWzp(T2dRhAH-k1Q)sy~iVGcnTlWe2 zhv2_+)ev(}mXyaIG-lWXvlEwFjDcNPxz1K3)~v|Kp|E>lunttex!i&Wlw^iy+Wv=(CByBw29LPOwC9jDAmS?Iho(vV$hOqT0rUUqaFN z`N$^7k~O%!Lo@i~yFUEUt+(mL}iD#!EtFDHx&!GF75Oqx{AI3%Uk z92HAMr~ou-Cz`SCpsXkloxT9(LaL?9>^Xj2WT&}#RXpgJ+US}Y^aGGcJ1EdO5l5|9 zjlf!FgYBSaDmm4 zm%&S`%>>sEV6U%s$iW3@RkQ zdhap3ytORm+6!As@yv$hN#B!MIp)WiM=}c{N!7493T9lnHHqu}`f4yuIP}+`xj@SV z%8T=G^o=^?I^q`CIMq6c&wm;aSu0s^D@Vaye2b`AH1kYYHkkmG9q~lan0WidO?>u4 ze@Y@O963Tpy=CrN-2m2+@3c^$nV&=q`{&ZSj}qZXoTDd1CYE6qk150G=$}qogqfqk zIch>w&l|>BvoGo2TmgH82Yo++?_(tG|Y-0`Z7m3a5f;os+iIRZp0&#oWE}Y3~;dY&RVjyEmuo@6y`**qim? zH9D=~_kP(WUQ_jj$9gVlLcmY@erw)iz8*7U(f)*H?L!#Ksm%2B>mS=45fK))yFR7J zaPotF9r_8T1ji`E2+?Lr?xkb$k;qU^7HcbAs40tGoKYKHOBNFYCWju}8_zb4TL{r6 z3)z!&Os+WDmj4$5BYhEPo-9+18*B+7ZdC|whOX{dWU1j0=3aKy9oM+ zG)JC5CN@)cJ!lszerc+AF;$Y9#CYLcxZ-vrL&f0Ulh%PP2K&h_+l69aq|fZc)3!p> z!*;J0bfbp`_S)6jnCKh`*b>1PVxuRkw%)R8Gc>EVr?cu016lVMj;#Ar&0_kS6S4*W Y0(up6;+cYPUH||907*qoM6N<$g2o~&ng9R* literal 0 HcmV?d00001 diff --git a/assets/icons/16/QULCUR16.png b/assets/icons/16/QULCUR16.png new file mode 100644 index 0000000000000000000000000000000000000000..612ff4e63ffd690567199331ee59a2b1fd3c1461 GIT binary patch literal 287 zcmV+)0pR|LP)lAkFGl?ks%V z>P(YHYwDE+z^VfBEV)!|AgZ81CPHbb*z{b*y zK}JfPftQyXEcf~ISB59gUNY?5bAaLeg)0}B|L|MFT*3r1;2-OU43Nz>R%Q&EYKjc} zd^`+HjErCmVr!}^F=Qk~G4KoU8GzKn^fAF0{}~vfLC%(u6lY*!f(yd|$RI8*P6k&; z8?ago0~i<>3_yP7gE|`*P?VPitHovjS%3+NeE}5OpFV%ZtKt5`$6&P>1~4)(ECof? zljkoP{{R1vRr9xR-x+rAKLS>ZVF1%_ff=B9-nsh#!}sq$uxjp|Jcr@qhffzkYLP5v zfCE@U0!0-lw4nh8b~eankY=0-32q39NqOJ_07~cmMzZ07*qoM6N<$f_fjQ A#sB~S literal 0 HcmV?d00001 diff --git a/assets/icons/16/RADBX116.png b/assets/icons/16/RADBX116.png new file mode 100644 index 0000000000000000000000000000000000000000..733f001f4f7a2fdca10467ff44baa0f3e8740809 GIT binary patch literal 498 zcmVMjvztgYh`8~hqd7t+I{u`Q~0ZAIlR`gL1fDR2H(%2h7 z00g;&*&hfDKmTeV^$ipyUz8<5C=qL_L|6(7Sp53t7Q1@{vV2Z-Jl7JK9F3$INYYSt zlDpq_*Skb_tqXRW1tyb`cCG&j1LHq8KlNZ*`mG9oay@olk6@)ffSVaA2hVy4YxkOH5@Wr*pK3ED55&}~1& z;^^&c0;l^-84Wz7wg$%KvkRtGbDT;vKyY`DR6B$ch?Nd3&iN3W4}<6Rtk`bL$K&G@ zR@SzdHqAhrF#BcsTv}dP7lmRQD$1-F8Ej2WL5s&Grg0yAAUehD|I!#KsE0(qif;R3 oVQg&LnHB$bNGX#)p7Q_W9p!JPzE*D|5C8xG07*qoM6N<$f}Ky|N&o-= literal 0 HcmV?d00001 diff --git a/assets/icons/16/RAM.png b/assets/icons/16/RAM.png new file mode 100644 index 0000000000000000000000000000000000000000..aa4ac785fbbe438912b67929b873eb3ed4c52fee GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^0zk~o!3HGD9`RZNDL+pa$B>FS$q5St3{I)Mc$=1x zP@ow6Urua7nkBpFrV@Lrg5#_y3=(@@R=R9)n43=twhad)PW)3k&076s j-$d8oIeaIsv@L5u=N{E6E=Q;g-7f4A8bTwZ7Y$mViv-}BO(?> zh>?^iBArn4l2Oy>Q@_Q%=bn4+cfNDZ1!{mew6xnkygXX&j;n)G8nc)P}qf)uynY zr7xeLYgt8Nkl3y3JlNkfr5b>;$tnTY{T{)8#B;A|!a3IPku26TWfhD{9^ z#H1AbM+ej9EW^u34mT#Mcwze7OOm z5___I3B$Wf#~H4?|HL4otp=8RbM+j9n;;*9i;-@D%el)Fzy@Fg504*bINIFIpex7+ z#+O&E0E>gzAn@}0&;Dj<=?gf$up3I4KzzjJ1FsS?}upy zX+jPI5dYq%uZ}nk0D%iurW2SL{^!GN1c|Be^5laI`NzOG(cswW0(|(0vj){Rnz%<|nuwWB3$veLKHzP;t#fgTXXe1&bVF1Pu zmj6F2jPsAjGJIW$KOvdqo%oMw07xyP%>RE3yFW8Y|KR=e^l)@a0S~r>#Byem1x5ma z8v2Ei@qebk&nH_LI2Z(=Qui?}!U9b4jvr@cWQaUD(Gr}PU;tYfVAIcFU%ww`9zh2H XSwLfRTG;u700000NkvXXu0mjf%+-Oy literal 0 HcmV?d00001 diff --git a/assets/icons/16/REPLAC16.png b/assets/icons/16/REPLAC16.png new file mode 100644 index 0000000000000000000000000000000000000000..504ab65216373c9b5718dea3842712b24e3bfdd0 GIT binary patch literal 441 zcmV;q0Y?6bP)@eBKWV;Dx;FDWq0^LvJxHM<>>LXALoAVdk6|M;@k zTRla%T`87_rqCl*;#=S2DnMy?{wjb+{0B&UggLIndBvwQap&$I_Kvbc-btTIRW%}U zEmKTrX|q4B{o}0jZQI-ru_t;`%cPJ$x64e5$ULFxrz@JC`4y?mgu?^Un|q|RV+=@` zwuzwuoM+ jU^f~;FNkpz#>MypdM39fc%&UX00000NkvXXu0mjfdOg3T literal 0 HcmV?d00001 diff --git a/assets/icons/16/REPORT16.png b/assets/icons/16/REPORT16.png new file mode 100644 index 0000000000000000000000000000000000000000..93a9441679d5ab33a7192948d3012c7e83e526f0 GIT binary patch literal 215 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`^E_P~Ln`JZCoB*!XzFt*@vo>Fz91#&2*?H;T@9+83RvJGKH8wDC;9H2Z(uNgN+UQoSS>MNNSXLnX$c2q~`=SMgHYSf68uqvFrA@YbxXR%&_ zM1{D4;8HIBhFuT-%LjaFSz>VL!T0y~6Ko5Z9VD42ZSy?slVU9`$-r<|H>i4hV_GH9 Or3{{~elF{r5}E*bO;j2H literal 0 HcmV?d00001 diff --git a/assets/icons/16/REPRTSMM.png b/assets/icons/16/REPRTSMM.png new file mode 100644 index 0000000000000000000000000000000000000000..fc7efae4c13fc486d67145272524370ecc20a4b8 GIT binary patch literal 736 zcmV<60w4W}P)o;B$RSrPK$)jN=baDsK4b}$?} zaf*Rv;6K9?Mka>D#j_{uVHltY>F=nent9EglNmmI`1s{N<6lpFk-|cWC5vbGGtdfL zzj;Tdt$XTx1_lP%fyxQ3-BU?6@6FqH47KHX3~DNhDB?^^Obl+W4m^AJAK4z8mWMM^ zD2fnT0!?)lQ2v#nhh6<0wF=bC2|bf$F_h$`p+pJ?J3GUXW8e~n=l?&Z!}0m~f(s{3 z{4iu9WGLqZds|C}2~+1W6l5pC4d3f<6M#=*L5n&+) zY5`(%LPW3^N%m4Lhg8*M5v{hZWg6M`sA?NG;F4oxV9aL!!{V>5Yg~Bq^4T>EGz7%v zge5CCF|f0AvR!01-Np;faQ>(0;ba-hv3Tz16GF&6_7caLxyJ#$)qqR3|NH7ChC){=kffD zH0g&7L=GVp&?Seol+_Tewx+9vru`6F)gjaZbcv8zr&bJ_en=*ba>$U1kVgmZ44Qt( zU9^{ zkn1<^fald2hG|ZqNrc3v7BbL!kplzuz>C<_LJ0<105WpIC>RB!U=%P6eE2X851~ z|3BjoCdR*=MH5b+A=(8!dFD3UoZQ^XC;`_&L@PZ9vym7mNS@{x4J$dUoZ{f5xBp-b-F#WMXt+U^uvkpaC-W zO%aT&9Lw2x1Q{MNNP&|bhcE-fuP^UGa*ee)Bnfv9C)&-4F3!)ifA0}gb}U}v*)Gl1kkYTzz7hLnK5GBAiRvvEkU z@d)Dd9!L(P25Y8~x35=VVCA_ls%4AQ01$Y6?J({@{QK)W!;1^M@EXAIpWzDt&S7|K Tshd2a00000NkvXXu0mjfO;N;M literal 0 HcmV?d00001 diff --git a/assets/icons/16/RES_RL16.png b/assets/icons/16/RES_RL16.png new file mode 100644 index 0000000000000000000000000000000000000000..542ad00eebdf1bf16a3d3c720075466201388c57 GIT binary patch literal 798 zcmV+(1L6FMP)Ls#2l#28c z^wL9Aq@dwTLC_4%*~~1jf17FZZcXo|cmM8(wf%`$%aP zfudugLipk=?8quRsh)q|F39!H=G61K*}58L*G||MSMhDiF>s}WdmPT7 ztgMZimK1{urMetMG!}$>87Q`>1i^Iqj>{fC!Hh&b zQzxaB(^-X^(&m?@jQBmeN_gJ(VEJrh4JAQh;`M6R&`2Ln^RGd6ps{r0t~5IEIar*cE*V{-fsk8 zr$CbLe7qC#h>#Gsp*g*Gus)amrO_qlz~x@Y2g@u;3dKz^` zQ9;@c7Nk=}rVPC79mg6kAj6P|6P39bu`a?ku>?p8Q?wIfslVr(3`xiwwf*AUs~adO zX2N3GY=!gU`;vf$WMc1c%F^lq1po=`bW0SU@KkCx+#iMFn&ooju1RZ0DHB4 c#UmI00(3|&=Z4S_{Qv*}07*qoM6N<$g0%d32mk;8 literal 0 HcmV?d00001 diff --git a/assets/icons/16/RGTARW16.png b/assets/icons/16/RGTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..ecb876139ec91bac6db13a231611950a7e9b828e GIT binary patch literal 194 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`ot`d^Ar*6y6C~;!LXTUx$6mK+ ziTLUxq4ZzU<=_AGn6=B2H$|Pj5z$h@ETHh@zyGnkxvgQP=G_KXgb zhQ^5x?a%M8@8SCP?VHYtM>;OA><=C|Frni2tC`Z?%OUnlyG|(%-5!2?YTgAP zU)GTD${?AcC6j)fyC82^eU4Y|B~g<8?1A^npctnK;{6hcrNnl$9e zFJNi&8ACJ2*gt)SnjmiKU1M&^cpwmj(J0+UgD%XG?*-2J6Esz2qP5nHv=mPLhWKvf z^0AO$H%jRsrmfYjTWstbeW=xwl|!kP-TKs3aXnJgLiKXP%~l-8My1~itN z(A7|YBrfLslxpZ-!#`l6uL%Cf8`YVi*-hP&z)GVPO&X$RG?}u#OZ2I3Jfcr^d@K*X$5EAT4nEi|)W_|I7V|3Bjo z24=?ElD^|NU~)`^Z0OH7S72sl+ihlT>tkeQ7Q*Y07A#9?V&2qkD%Q0W~ew;X4Gc8DcuFms+_&w)&{^tNYjQie#meBz> zlZMXUVS_c4>;w+9<{xu9_PjfH)h>0AHA>jwL(`=~Wu&-dQAHrbeTd#ZY<+1$i* zT~!pt*Xkc`-^yH)IXJH#_5wJ#TOb80W9lkH6u{I%-(;8LOh-EbX#>F@(-~9-=A#+d zoGo@{?aN8kOaQC^;-MH%yEt5S@*>UNWyaTKInC=D{W0;XjXD}DuNW=H&VmX%3?{>- z@x(kUX3}%g*eXMxw+wHlqUe7ag7h=33t+6rcIaQ2$KTrX4-zid6yn~sa+KQnjDSD@ zky?yfd6kN%!(l8&*3fWw5;Kd5l$P=!HW&Fn$qmyr%3=SL`HTlCoifHcqO;N#Jo9nG h_|5~FU-0`CegR*i@_^#cUnl?o002ovPDHLkV1kA6FUSA@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/ROLE16.png b/assets/icons/16/ROLE16.png new file mode 100644 index 0000000000000000000000000000000000000000..e182fd3b7bda02113a901062d1c4123da5955ab5 GIT binary patch literal 577 zcmV-H0>1r;P)1o$4@guq_$jO8GA3uEHxq0nM zNN=&|m*ro@9Hc%mGbns|%kcEY#|2qEZ}x!HFd-Z8|3AaScW>W7+5Z_nynn~=pON9g zu^;?@9{*teleOg?!@?sko^by9T?o^|f@}cCFODe>?%s8O|MsoJ-@ktuzI^_?;tM~= znzfC0{*?4vow#uOUAHpp_lb$!A3wld&42{t5_Mhv|6`C*V`nw~^Y8!9d%yo&VPs-> z@@W2Luye5iMi@gTUN3@$lXW?}04IuqpC7(6{Q3Sn^2x$WD{vYho2X~Qz|6E;!bp~b zm5UWc!S8Rs8D5-w{Da}|Ki9|eFC9TQfJrM$i|0QB!)h@dNes;(01^Yqfz*K1Vi@rC zE2{_#JF5h`(~$v44x|R87Q+CXx`+heX#DfzH^ZX?cL=Hd!o|+|1zi*XrZ>X9Egez+ P00000NkvXXu0mjfmB}4P literal 0 HcmV?d00001 diff --git a/assets/icons/16/ROLEOP16.png b/assets/icons/16/ROLEOP16.png new file mode 100644 index 0000000000000000000000000000000000000000..2542eb2f58457be0988eda283e5e5c04c4206c08 GIT binary patch literal 406 zcmV;H0crk;P)ax&1WxO$LB~E z0tR3L69X+q1|k6qAqDmI_AI;~f3`3%Fqkti{M%YG;ZzT@JQE=Uct8H=mzI?)w|8-M z5D}B;?kO-UA;|y+21Xx!V`Bz!2}uSWJp+&yZxRh)IC1mZRfaF0KQr9Ec>}~hi7d$i zitFFMf3vW%vSQWE@ryn6?yXx4cW>RYU|{&aOI_0{JunE(BAe7Nw+ z4Xg&p$LkCHVf=quR7*mION<9Y{@bfB46m=fxWn?F(G+VS{$XG+;N<7Tsu=`8;vjjD zI^3~9C@n(eai+u{AHFj@I&cS%3IG2vGBdsb0Co$B^dAP}N&o-=07*qoM6N<$f}aMk ABme*a literal 0 HcmV?d00001 diff --git a/assets/icons/16/ROLESMM.png b/assets/icons/16/ROLESMM.png new file mode 100644 index 0000000000000000000000000000000000000000..43183292df53fbde08984d2169a8f757ea282073 GIT binary patch literal 818 zcmV-21I_%2P)F|9LIleX4gZkc`-%X#f8Qo$;wE|kR%A~u%UEqK}0dUvNLw+0&$0*Xd3JXl#y&fsro-xoIIO4E&&SmH888tWm<+oR?H*4h z8&3s;?4lgt+1+axo2l=EF*Ryx7!0vw?J_~^a^1Q%zgyEKFK*pH1c1tt9{Bk3MvmKc z)#uhU@FH%x1gI=SKz%Tpf;UGu0865^G%mP@n74(9wn(#b(Q_ znw09WuoyRVsV;{c)oz7Ia^_rJgRjYDV^@RF!J1k{mNR`dO@~-~#n9y~3@er_rO{cD zRai=_<#~}J%Bd!2R%Kx^VdxS9N_p+!tlGELWn&kJ;;wUL)mGwhr5M6sh=)2yVK77> zz)u*Ak`KhiQ5cp6@^tQV!S48zxq{uq`{xC_uim^ZsxYhwgtDF0&Ov5O4NU~fc2>Wg z2&|URWjm{#LpILm0#dfK+9oqbS`1;BzwJdFnT*7SxBE^;VwBYkUBHpRL}VC9#tlqF zD68djlk?L%ZgPG)zl$(38x9WxkhD7+4pUYuhA=E;>_Qb5><(2H>^jfgEZFt-4&=BE zJ#EU7zSgzou}gS%{4%yY>cm67)9C7I8~_e5{nH8WoP^^SH5)os$SQ1V8{Ewd(?7rS z&Xr!@5_@^n$~0K8M<>oOnHRtjB^3xk(xC$m w+J3^gs*a}q_5Ue({CpF07*qoM6N<$f@Y3_q5uE@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/RORGAL16.png b/assets/icons/16/RORGAL16.png new file mode 100644 index 0000000000000000000000000000000000000000..1b85cadaf6a842c55b2c169c34fe6c51c625f3c0 GIT binary patch literal 290 zcmV+-0p0$IP)bEX^vk&V$({5T>k%Ow1KH%Wc+`Gg#kbC_`=M2*fi^;=jmzY zFa9$yZ8p@C;($q>zx?b63)Ci@fRT~G;6Ka%{r2_ybs4{gav11J!R0Poe#XIaW|9RX z9xpKbXZZhw;orZ&gN=@V!b?Oj)Un{R{r`W43rv5RJWo%vd;u|x;Rnc8xI6>H54;92 zGBUj2V)*t2&Szklc;WK1a%4Uek%1@ywJ{$Q1~3fbv!MH#9n7m;7?8e4}ts=f=QDQu&z0-|Wyq?vx_kq&$ z1x(W_N*?er_w@41SQapyOFOts;j9kRdPYR8yYczO0oe+ZrX;3F y#&sD-xUQ7={F}_=@JiFKbBcOu3ZLaoNrnr*LXK^F|1JgSGzL#sKbLh*2~7a`vPxM1 literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPADDI16.png b/assets/icons/16/RPADDI16.png new file mode 100644 index 0000000000000000000000000000000000000000..9fdb207d3c564c43f0819470712306791c5db168 GIT binary patch literal 345 zcmV-f0jB}na1${{|yFL-5dr!PBG$K00OT+-DB8!X(Ge7pC1^$|N6wR`|=d9OaA}=$8h%k zdWI8sR)E=9UGVtrWrm}-mN5MJ`x7n+GlYwcpW*G7$6&EXLOlQ6yT4~u48;QiO9VA_7ZzX03?zs{8rZ2$!1F#KR(Kp608Uk-@| rKmgbP!D4Aeax`-&e0V~Zt;hfX`wDXgxqfHk00000NkvXXu0mjfOp2P< literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPADDL16.png b/assets/icons/16/RPADDL16.png new file mode 100644 index 0000000000000000000000000000000000000000..5d6f2a9ecaf42bb57333c33d4ec4f5ca97f0eb9d GIT binary patch literal 200 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`{hlt4Ar*6y6C^%02)eAuk~TLm zFbFX=GTJ1t_~rlq|LY|rB%<=;ZMiS8n?3k`ef|A^!rTs7j#Um-GY_0gNJ)A4=#k2; zn+jVEt{W+OuXsI6$TgY4RCeViB^s@7r zN~YOad(XKB36ACyb(rH~ZX9(GU9c?q(|i$zpz|&(mon!wC>yoUdBel-YN}(XOmD(F Ppv?@Pu6{1-oD!M<2DCa) literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPADDT16.png b/assets/icons/16/RPADDT16.png new file mode 100644 index 0000000000000000000000000000000000000000..e43c2d141c6d187d761d9eb0762050204f263861 GIT binary patch literal 345 zcmV-f0jB(_7pVc^NrXa8^AzVn|D0O z!E}0>j#5-{h>y%N#$&%`sqAbBRCCNXXJ&5Z-YAu`MMq-V^m8nmua^2A)GL@+9H4mX zm@>QHf)6t#G+1bP0l+XkKMY%)E literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPEXP16.png b/assets/icons/16/RPEXP16.png new file mode 100644 index 0000000000000000000000000000000000000000..c323737ce34dc5b3c2cb496778d8fff32c6a36e4 GIT binary patch literal 312 zcmV-80muG{P)aTXAa*|G5+5JmOutF33~q{y3+oC`SBIZ2gy&{_2xf10EvO*n6NqP(wCbI z{>`xruRp#e=mjQhf&xmy46nIAF?ckDG5q8FPg)qj0FM+O!>8Zx8GdT~0rRKteoI;` ze1H3m;m@m|4D5Gt+JW1EFV8+PFh2gpu%U7x1Jfr&7C5%51&omaR^vs#@-ZxLn8hH< zFO1iA5MV@)-#^0t7+5|qF);kaRBUEp1Ex=%I0DuEe-A+$2mt`zQ*>@Xt|@H*0000< KMNUMnLSTZ9yn|-| literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPIMP16.png b/assets/icons/16/RPIMP16.png new file mode 100644 index 0000000000000000000000000000000000000000..fbb9e5ab10a9c116f8871b56da3113f9efa73293 GIT binary patch literal 316 zcmV-C0mJ@@P)D4wqy}O%~3INSjAaDgt5LR1G#{SY@KvB;2+n22AKrC<763d z{KgrEU)p~`Obe0?*mh7$Q%EO zGN60i6owi57cqz%$}ljqF@wdVtrSqyJUVa(w-=tje+kye#Eg;n7>IH~Uve`8-*P^N zB`4M}i0DXy4SRX+3B%uC;J}1|FL=YCA+nS~Qc#ScbMq7iQC&%fpPzm(F#l&%gvtM9 zXZ^we%1ng7x?@}Z%cmOsM-M;{ASxXMT6#0ETw`GP&%p2kU5=5`>XLn`JZCoB*!XzFt*@v$%^cbzb3N(-B^FW=&c`LPkQ9RZA<+@#e1^ z4(wQdE=J)lPYScqWM$7w6>pAc8k}v>(a4{{f9yrljT;6BTF#3(&H5;%;NOzgq^H1U z@NiN^MV(TZ*+n*iY!2bDKoy4*0vT36{y#r{e!k9+IbA$;fBtY@V>V})Vi;6>%JZDh dk(H_p40T(qUpjS}Yyi5O!PC{xWt~$(696UUTK50| literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPPGL16.png b/assets/icons/16/RPPGL16.png new file mode 100644 index 0000000000000000000000000000000000000000..c80a3b0fa7f86a94cfeae150636aac4345d7c3d1 GIT binary patch literal 234 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`8$DedLn`JZCoB*!XzFt*@v$%^cbzb3N(-B^FW=&c`LPkQ9RZA<+@#e1^ z4(wQdE=J)lPYScqWM$7w6>pAc8k}v>Q_P>yKb80K;%>u4W7+wNFB&+fvutcLFbv?B zQQ&D~V=t&ZTZ36nXr<(8Mt;u=JWLl#KKwu5Ki@vm;>OL7T5Xa)9zXZrAh&~YLC?fl i!G1+)N`AVG3=GSXt^db|^Q;Ftp25@A&t;ucLK6TD=2@fw literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPPGN16.png b/assets/icons/16/RPPGN16.png new file mode 100644 index 0000000000000000000000000000000000000000..3b5f581909c45235ee1f5a83af2f5477980264d9 GIT binary patch literal 218 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`3q4&NLn`JZCoB*!XzFt*@v$%^cbzb3N(-B^FW=&c`LPkQ9RZA<+@#e1^ z4(wQdE=J)lPYScqWM$7w6>pAc8k}wMZrqb-7szJ#aI(rV0W~Ks4#`6;zRbJSYT678 z12|?}V3nIUpX1nzq?Fwc6y?r(u>JY}`SElAMW)VI{{3f83Z65wBet*@v$%^cbzb3N(-B^FW=&c`LPkQ9RZA<+@#e1^ z4(wQdE=J)lPYScqWM$7w6>pAc8k}|MNvb?tGpERBN`_iSgAL=^3f>9smw6r~8&Bw5 zAo^t2gNHvmC2C3xoAfF=T$%Zp|NZ~@@w58HHis+!{xc^9&zac~+|SOykWphMUUGIz QEzqqDp00i_>zopr0Bnd@JOBUy literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPTGLB16.png b/assets/icons/16/RPTGLB16.png new file mode 100644 index 0000000000000000000000000000000000000000..e58e767b2cd42d0e47cdcea33f10186d033d4e58 GIT binary patch literal 558 zcmV+}0@3}6P) zO-LJI5PdtlHg4G1x=E|SzZ5M*!PA_)EuM;cDCns{P_TFtgb+jorH4XW2o!qi zp%)K@9_rCF$)P`rJy=Rj(SztEh=pLVns3Xju9##aKG@}Bc=KkydGkpqLVYOO0zrKy z;FEw1NGxr~XVNGG$v*f)QJ-uoF-=nkZvD*SK&dFiNx`C>j2D2~l8yu$we z-%lf>&mIvk3H$sl`MaRH4WCyp`P{0?Gto>z3Cl)a681U1{1rl+Sa=a4QxkYTHx0e| z8Waxja`;10Bb8i<{aE`sXifVZVsGDSgbVmYJOfzu5eVxQMm*9)v-aygs{*f@PS wuP@Vqqkt1G>fr1(I$=0GxeK7SEWt$fKgD>dRA)gOr2qf`07*qoM6N<$g8cyW6aWAK literal 0 HcmV?d00001 diff --git a/assets/icons/16/RPTGRP16.png b/assets/icons/16/RPTGRP16.png new file mode 100644 index 0000000000000000000000000000000000000000..62480bb7ed9339f1f89d11adcc341dce50d4f5bb GIT binary patch literal 312 zcmV-80muG{P)4XI;{vtNDPy(95c>fG!wrU* zl!E(EJqnCW|7;h}nskJqO))72|6jj(i-Pk?8~(?o7JiOR%d-KgVZ!St1_lNZVIdUE z#Kgql=IX%1!py!MWC#L~NR+6lC`E@$xc!{`{F?`rPFhYBG}} z!QNrPrMax6SYzq(6%4tVDGbJj`Z&Xg1*hg^E53aA{EY{s8J7!C4A4T;eEigLPct*y z!^nzpx;()YO7^rXJ+EmjP3$-LmBt)-_NpY w{k92v5A0ikt~n;9;5h>Wg9J|N|1*3609oV1g?0?1;{X5v07*qoM6N<$f=o)b@c;k- literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSATSK16.png b/assets/icons/16/RSATSK16.png new file mode 100644 index 0000000000000000000000000000000000000000..772377c906c33aa0e6ffa18d36db519bfa0fa32c GIT binary patch literal 361 zcmV-v0ha!WP)rf(nCRr5eDeg73}9qrv{%#6Vi1>*WKdF71@lq7 z@aVuDyas@refh$92SpVXhFjOKG5r6>xE5|W0}(*dzFs6uu>vyKRDNJy>GPU z;laiiL>VAs-|WH2$h4V>g^dO7qQAcx{{8ur`s8rk9J~g|+P9c6Ff#5JQZeOW<>G^j z|NZry;qC2He;EG!48$9V|Ns44FQBN8q8S93**F=5l#E#ZGcqm59}A2OGVHt}SfyAv zc^Q~k*m>ao!Uev(xQp9`fB!(D5vPLx{~JF)#~sCt3=CfYQW{;???|*500000NkvXX Hu0mjfgvF)4 literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSCNWK16.png b/assets/icons/16/RSCNWK16.png new file mode 100644 index 0000000000000000000000000000000000000000..78d7f983333765876a4641b4700bc87d4f4056a9 GIT binary patch literal 470 zcmV;{0V)28P)Uvc z$bW3&AkCbH+Zn!}_hbOMgb9}cSv_wUG3fsce?T^aG=pdmpM@Bw!wdoWdCAIi_`{&D zz|`a~19LSa1H%tSMuytr{u6ib8P15z>Cd+p_|Nj^zNv+!!0%tb7|xwKdFQhLhh}5r z!9TbRU_$2nVfbMnEG!}*uc*YJqOQTf#lxc_@ZpCHJ{Pbcb3_Cj>dCb$mt{aM z`1a-NnUaYo9}w*Yd;5A85s5oCDgv+a8U8c=xb#+`_u3oDD-RDg{vc?8y?s5)-T%zH znOQj;7#I=e{{8v=#!sfdrmqh+e!**itX=bRc0ut70eL+X1)rbaX88K@{t;!yzm5kF zHvYjHh%&ZKDXiQA5dw0$7&h=qsxoj0O4!`}$JBt$1z-dIGyIof;}v2+b~-X(=M@3D zRT`TdJQjX^dC&0W#a*lh{Q3SFt2n{{CZ+>FKfh%FVVr=8c?ULe0EqORj^8{ty8r+H M07*qoM6N<$f;$`U0-j{!t>!r4I?9?{r`UqYfC4cn1bpBIX6_yz`&5190@l7q*+>4w%*>w z)j>o|baGF=c><~d1OUipH4QBWaS2HVB~?{0pP(0}&s`2@gPeW&!g&Wp6%~eC*RL`B z|Hrr%)c`q&v*F;;F0dD}Qlh}zzKiZF!c3wry;{??8qx0JT4Gp27k|6#xJL M07*qoM6N<$g0L;WYXATM literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRC16.png b/assets/icons/16/RSRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..bcf52334f3219d38084050000a636ba14293e263 GIT binary patch literal 387 zcmV-}0et?6P)Nkl^C$uVfpjt55xI0r@s98 z{oAm(|HK`1wMgi|NnmoHnmLH1pohMc=+z^8z}of z!-x0p82&RdJiw-w1)CtpFODe>?%s8O|MsoJ-@ktuzI^_?;tM~=8lny8y6R%_|KIIglEVS_}ieGBAiRvvEkEI~^H-CPU&nuj hFI-FvUnsR04glhwcA&OdV2%I)002ovPDHLkV1hL`x+DMq literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRCCD16.png b/assets/icons/16/RSRCCD16.png new file mode 100644 index 0000000000000000000000000000000000000000..398ad0b6d7b744b42830a048236d6bd29bfe0476 GIT binary patch literal 451 zcmV;!0X+VRP)6L#VmNo|I8}x?CtAWL?rIms0h5uXZX+f zJy#NU74 zZ-5v)+-z_I)@;1Q;ApEXvH$R$&2R(m{byOsAt>%3Adj#K1U^5%t%2_EgeVh+SFgV? zFflRmfCEv+wkd^`TOdL}P8TDPcqLUa#6Eod&aiv`?Js}+FouF%@Sowo3>&Wy0|O&Q zvH*kc41x>`mYsp~|NsC0gOQ0bGNsg(-Ucs~57VPs^q|NoC+ZRw;FQ($sT#25h5EG;WrZ|~yjAR;C@ zxhLN|fg}SM85!->G_)ARB_tV?R8_%zk_`C&k74cQ3+EZ`-MP(h^V(I0|Nj`*k`xAg z7u{EcshkqI_2jbs#~++)x88R!ph2up;^Yh*@KahY4e7MPB6@xQ;mGrYZh>JP)8pMiMeS;n^M zv7m~P3_Gs~hTNa;pBdiXKKTWIATlyw)eQDKCocmN3p)?NK>YIJE>5}sfB)c*h5!Hm iH-3J82af|8z5oC?sfzpUk+Qe|0000o%ATSro7;yK+*g9B0ZtpSg?N<5F03+=>x+iJ!-uFB= z@6COB&U4P&0uz|P1ST+nJHh8~XBTX%F%^#WbHo#bu`2AWu@nnXj|xfR(K<&~=~z8S zyn)54kket20F)13N(Q~|-O~9sqfRH_z~NTqs!w?jfIK|Due!E-Bu*%Zu`0y4`f84p zwo%GT)vl)(n2?$}NsB8N6^d=1-j6AkyS%t04{QSP0TK|g6NCvFQ}Z%0^Wm&p#z+|Z zY^xTZJlzGkb1>sx>(#EGyM!~oL#xf%YRA?iu2}HKjUZs$l%&_)mX<^u#!dHHj$U5b zk|kz}8(c1Wk(OBS#)YYqfltzlFIc6tNKThg48!biVJP|vf^k+PZskH65}TNkqL1YDQ`UirX<&LY^to#z`IHnrh)ef49Txj&>(a8);BxiQhvHcA z;(y6fU=&0qisDV$^T2<{0EjCvCUO=U)$`?-Y%JJ(T(EQCGrDGgJ-=je%ekgao@nyM zg&@_n-OWyiWqG5!wSH;&%*ZSWcs>cw3?4wBeM^LY?OG6x?pDRGsLR*Y_8uEeO-0o; z8nX**ObB}xS3?-=^i%oEpfs&&Q zbdceXh(Vy3ax`{V;818M6uG3BLy0;s-UM0k@*6f4++9&tYNq9iKtf1aCRim4%%*UT z#)#9Y%-YfBpJQhXMahQYL!*!ky>&H2=|zBrx0y6XoICyPgoA(7`Nu(pzRd)RDHm;C z+_m4U)@-l~`lO#L%N80RESMS*gv20t+ApHFFKpyzJ?(He?nYtqUM!lIgZwF(T3!<) z`*|%6o_9j&*`vkh&iA3|mo`~ZS;gHLecn?a@{XV0XR+qR#SGcGeM@uD@1I-0x1ooO zn;>`fqP;`L+3UohG2*1Nzg8xT{z08^-D9Y}NXXTpNK71^pfhr&#;zec28fE%E7rX3 ze(ss2^KUlw5s;~W|3m%ZUE4P=pz{V3LhfZx7n#Y>X_*pDW#Fn0q05Ife*b_EyZ5y8 za8K$I}1+ literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRCPR16.png b/assets/icons/16/RSRCPR16.png new file mode 100644 index 0000000000000000000000000000000000000000..e13d550044d8935ba5f082811f41f17e495693a1 GIT binary patch literal 463 zcmV;=0WkiFP)fsxUj zg&YGeU48NA-~ay;xwyG&NY-p&uK#~Zk*E!f&xlP?UxBH~Uk2uCMh1o-jEoGm#r-Gl zz~t0)O#a`xat5xC30-r4zP$hgGuv(pYnuQgQ?rQw|Nd{UueZnPRVH+SKMX$%goQ-} z^^4)#m#=3^CZ2qN z%LR<+0`~UxEFuzjY*YkZ&-dH;wq<6p;v2OIxj4MZ8+ zrW96gfd~OPT?}XPN~$t&2uj%8{m0aRE(bT@Kf`|+HeMkHWTztoc3u&Xd!^CEQDWiO zm-h@`UfjiMz@P7*v5F%MU}8G(^YdE<5XK3Zn0KIy0RV$ti#KUHhl&6I002ovPDHLk FV1kx>)|UVP literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRCU16.png b/assets/icons/16/RSRCU16.png new file mode 100644 index 0000000000000000000000000000000000000000..56a663790f04c4759db475554c40b8ec93223f29 GIT binary patch literal 565 zcmV-50?Pe~P)C%~HX(Gv3)^>{weBhAtzVA6dp7%Wg{!^qo@$hEuTnmxg z1TYD~om+Ei^}v9+qRhFB{W&*2!EIR<-oKfzu5=b)1VcU5=QY%}T>~ zB1zeNp>QQAT3?@IY?OzX$zXY*B2>!dB7m7afDpah2o0=+g`HR4tg%9(;?&iKj zbm0i;bQ+X)JPM+z34HkY49klZ{QT9d#$)#VeF2^{O@pewMj*oAH$+(WB#gE1sMR;n ziVofrQtH7m0FXw;@(z#>k|e^I?D=9Wb%yQfO9o8)&pMiVP2D7|%X&#M0tcTK z-@O9hEni12DUV}`6q`t&@@TuRymno89IM}+0=VkMolWl?0=bb8NB3Oz)PGn4jrL57 z^4+7M0KW|y2`LZ|vU{!LS8i9m{35L6Su}bn{2BZOnwzRaZPPE(00000NkvXXu0mjf DvM~#g literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRCUC16.png b/assets/icons/16/RSRCUC16.png new file mode 100644 index 0000000000000000000000000000000000000000..74de944057fa3a66b90e73fc1783bfb075cb328c GIT binary patch literal 601 zcmV-f0;c_mP)90_M^;lib4R~8$GK^?HRy#GzW3pK9^UtPzYqA&AnnDSiNH`D z`yvF83BmQNu|#Ii03q@XOJz3!rgcyt51P#u?y&O+ zTplla4F(stD)ay9fNdQtoGwu;tcV{L-t%e))pBJv98Z4U^9X_8J zi9`tT(*_=0yPLSTtAHQ~Y+kB7HyDgTh9U4-WrT)p81VYAkV-)+tXvAmlao7+keA92 zJRWZ_6gsbg>r0Q}_8!9_s}M@KJ$VVa&QrFj@@X*gXj z1jk|>tM2N6qQN^HjxDkp8+t#)Dv+J~s@3+9=nVoA0ogVk6bc2sr2(QSB9VBl;WA7} ze$oMq8Gw1yC=&4upJn^>J;)X1CcjZ}INlHR`NNjz7t^JkanC0ZM6f nE#LhCRku~c)R`ZqI=Ao}NUP2tZDUTu00000NkvXXu0mjf78Dm6 literal 0 HcmV?d00001 diff --git a/assets/icons/16/RSRCUR16.png b/assets/icons/16/RSRCUR16.png new file mode 100644 index 0000000000000000000000000000000000000000..8244ee61ff10607940414ef4104ea6b63f0a5bd6 GIT binary patch literal 451 zcmV;!0X+VRP)e4WJySCA;AD7-L^j>=-dFA23#vcR?u(z*g zx%;1aH!~}T0|O&O>fxSJtO1SH3-|uBEangtcMy=*gNr@f!@wYI+t|R!z*x<|h@}2M z!=L{Q|6Ab#GPX@AtlR<-0&==ooXJ?NZspFx$IZ_0_zlD-|Ns4Ed3kYfH9QvnGyIof z;}v3nIUUUemXF{6Gfc`K ziAjX<|8D`97z;K7&OW_@!vFv8Kg0VwZy3Hj`?!bs|DV`L3$MMv>jGr(=f@w0m*<}{ ze17_&QCVKl^C6OEoGyTY?{B{`yuJS7&A;FOVxKO&yyGbYCSbuL#=!8Of#Jjbw+x>i zy+8Ax<$vJQg_oaTRfo$9uP#1i`1J7oL}htF%cpa2YsLzs6ZCG&#Opdsr#$e@QJuDlqmw~PTmpFz262@{Y93tG)WfJt}%g5Vu5E92Q zfQf~PK~z_gfnPx=;V;wsO?0v+}ZSmPyd9!D#@@>A1vM*jQNpGcbU?!h%iFuP;9t-duV917s;S@jpL) z=RRFI$$~3q;4Wf-f&UC31q^R*yxjAfnc491 zJg6dE;^+pvJpY8@^OKLA%JPDq&u5)|Lr5G2NGIssmQK_SAy#~F0RVk-eL{A9!6g6y N002ovPDHLkV1g%Ji!J~F literal 0 HcmV?d00001 diff --git a/assets/icons/16/SAVE16.png b/assets/icons/16/SAVE16.png new file mode 100644 index 0000000000000000000000000000000000000000..0c4ed2d67f5de4fd3183311ff37231585c51cbce GIT binary patch literal 211 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`vpiiKLn`JZCoB*!XyTCEee5U? zPmke}%)k4eoLu-T!XWtAx|jPs-+lalglR(51i1-uVlB}J`VuXwKU&3A_kJ~fm=(zD z5az&?;3%$eiuDJN!LlQ)%YLd$da(Mayk4-4QRfAd@uVLgvQEtS-dQ5f@?35FLJcgJ8c0PGhqb@t+QtkTB%ns7BN_-p|yBmh|ON#b<@k^wJbQwt@~ z6`AIr#A7r7fR}DxSp9i=YNg)V81vcnFqK8fY~s){WWhj?Bb_4gMhb9cFgEeeZi8?>*o@L9CB# zH0n^*hCVRb#Rz;NfMEf|oYl1LX>Tl6{G&i_e0(=E=@VnG*Qd7zV7fhmryDug7E_Q` zvI~Tor#!>M>%RzOqjw#ux|!4iAs_JvpxP*c#{x*cNUC2v!&- zuws6~true`kP?{5n(G7z!-BMt6Ak0Z-1_TOswTjBjuXe*Fxs??#Np;*y#qpK<;4_6 zu3X00jhmukwer{Rl_^xQFW7>Y!991vQyr&k0-ENU=5xLtxgdfInt^+>adBIdITXbP z-;tI^m&^GmJlQ!S1iZ1{B3}|dXM5r?Xl@NB&vXEWA-*|h1*H@=MUg?w{c@G$82_nGomerq7nKQ~Nk-|&GUOHGS`2`RvyzkOPG>+%__anFLx5&im~ zp_KJM1MB5o3||=-7`kp=#j6>`fZwnGGCZ65k%9FegunXqE{5m78SrXGNl2`s%nW>1 z91xd;@Gu0F@G}t7jNt{5U~UF(JvIhTRaOQQLORi100SV+qyUm~BQ^j4$7hkOpPt=$ P00000NkvXXu0mjfoyUX+ literal 0 HcmV?d00001 diff --git a/assets/icons/16/SELBX016.png b/assets/icons/16/SELBX016.png new file mode 100644 index 0000000000000000000000000000000000000000..163c2aba0d06be3f9bf37079974bce3aa3a69e9e GIT binary patch literal 202 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`6FprVLn`JZCoB*!XzFt*@vo>Fz91#&2*?H;T@9+83RvJGKH8wDC;9m*Zj^#rvoNg42KU$A868RkUQ@p_2ECi zMx|4bMB)daIUD45FfQm}^t`fKM6YVYJN)gK*uq7y85}Sb4q9e0QDwK APyhe` literal 0 HcmV?d00001 diff --git a/assets/icons/16/SELBX116.png b/assets/icons/16/SELBX116.png new file mode 100644 index 0000000000000000000000000000000000000000..4e0580fdcd7305dd4a5fff09f7b99bb753b80660 GIT binary patch literal 389 zcmV;00eb$4P)I7UH!1|MUMpL+jGH6C1!9K$^4DlUP_;S&7pA`}c2_sWazQ zGcYhf3;@{-(tPU71)>ZvGcf?`0kK)oB{P#Fu{-+jUxweWUNOwwb^t}3i6|=>7#Lnm znaFTAJ&}R$_QTzscK6ZrRUQPzXlh#ItpAR1}Jgg`M`(Gk6hk?)59>X#gbOClnWdUOo(>G4WWv$Am7xCMn4v-`>N(#K{HL%&lj@AYD;|RWr^o;L_Fs z`@1PLn`JZCoB*!IJQLOkGkvO zNtVJA6MyO`EK*SK)i^7>?93s7~ zo=8d-FwA7x``;kilEp&u2CK!vH}mE98UOk5LH3=Ln3JD7`x}q8MxF$a#SbR4++<+d zv8UlWLqLe5)9j0m4uL1+(il8GxBq_6XJqil9w-xGLq8- zf63>@1_nAeO4HqxHnJH6zG7My$Sk2@*1+05gG@B6zc>%jm2 z^$SiOYWrxvm^aT_Qu0RK|FmdKI;Vst0F*sRJ^%m! literal 0 HcmV?d00001 diff --git a/assets/icons/16/SHOWRESCURVES16.png b/assets/icons/16/SHOWRESCURVES16.png new file mode 100644 index 0000000000000000000000000000000000000000..66500291f8bba65e355faf726fdb1376e433e618 GIT binary patch literal 398 zcmV;90df9`P)i zVwHpFVPwJ3`TX5ahV5tGfHgjQ_me?cl8a&Co@Wg8(Mk-GLhKj@u^@AP{rSgGKJPYz zt&Si=QII@?rYtvD{Op}i42839F$7tQF@)KQqZq)1%$dIR34^gJA495#G+gud^PUV^ zpTilf-+D7VeEFRrWAb&dD=`c>d*>6wshgh|a(rdMnm~AZsVI_DzcZAEC@@4iNHFBh zxXJMM-+zPwpTGZQXjy)rp($3GftiVs0Uxl}6=V?RWd(;5+p>#|R>{w6b`< zurY7{|DR#)qkVb5r;{`Q z(q$4c6b+G+g5bgtgaRY-2bGzm2AO;@?|yM_&N#~G%(r;=zQg&>_nmVYwrk*y^92YV z>=f}fh3OMKn!yW78>h{;678l?>6ZJSn_hA^%{M(now9;f%wKU zZeQZ)yix|?^rSeMim6YvVLG>XVdT`gi#S_fg%8t<_%a#5{HxV}1@zBznb zjcZH`95u`nAUHW_++{py22l{e=68tZRAAE9&5y?yQ#mPI3pkKh?BI6oQpoIPQZ_D! y%zGBMYYEVaskGO_!Nl6^d%X0IL7nPf;r{?upTNa48+A4S00003IXi^ literal 0 HcmV?d00001 diff --git a/assets/icons/16/STEPD16.png b/assets/icons/16/STEPD16.png new file mode 100644 index 0000000000000000000000000000000000000000..2eac140bea126cd4a64e22bfd4fea14f51a9de10 GIT binary patch literal 430 zcmV;f0a5;mP)JVjQ5q%G#gF-<;Ub+-W=Q;%4s#DalFAx%4tS~R4 z8P%x{zT~c}lpw~w#BO9(D(k5q%)>Lo@SmCI1^90WqlsQ$;2H$j+L#KI3|I2{1F8lu z4S3EfP9!SdaE#R#)@4ZmM zW%LGf?mjR~4y@gda3llk=oaWU+mB+DHt+G_E`+>T4bn7?vUrC`$Pf1fhgc#F!m)}D zo9j=vl(y8~?-z<9VDzsTur!*=^3_ zkDu=>VPr1*pTw-QXDJ VwQF{YIRYKb;OXk;vd$@?2>{gxQRDys literal 0 HcmV?d00001 diff --git a/assets/icons/16/STNDRD16.png b/assets/icons/16/STNDRD16.png new file mode 100644 index 0000000000000000000000000000000000000000..124e53004fe6288991b80b9b8f3492d56522b5f9 GIT binary patch literal 414 zcmV;P0b%}$P)tkSIVj`&b-@kthbGnK^mc^o|CPp*5 zIu>jS5-QH%HDE!934Q|>ASoaOSg;As+JM_DX#xKT8<2*kh$t8Q`_II%X!|FIOLu-U z*ywXI1laN5bPcivEHK8l2hI#PZ!$1&@XIl5JoSX(!Smk?1>u4OUBd(-)a>g;uDsJ@ z(6g{%$cVKA)3Y~zB+3g+AmS$j!yiV5zYPEXL2Uc~?=J&88zbI?1OtpPhJkzj@{bG( z5$t@T4BtPzV6YO|&tNNklK7F1kn3?|SK0aJu!uao>&6C6RH9wjD>i%b7_(8}303aZDs|}Sfx&QzG07*qo IM6N<$f=w{GW&i*H literal 0 HcmV?d00001 diff --git a/assets/icons/16/SUBMIT16.png b/assets/icons/16/SUBMIT16.png new file mode 100644 index 0000000000000000000000000000000000000000..8f9b9bf489c6df6e73b2507ca228842f4746c9f5 GIT binary patch literal 341 zcmV-b0jmCqP)p8CF_OHHl@i5>+W;cK zv=R|ef-8K<{bovIBf}q2!^0;ZuKfSUn3>b}`Upv000AdE z6^5tJKk1x2^XTxjQjsP9{xg=691GHtd<_0xS`6YMJTXiR|4)NmaBNiziX!y51_3Jp z2>s#XcZTDq9x}Xq{pAS5f96cAA&U)w0#QptoZ-f;moNVQ`(K*f^L7bHoak6!_|Nd< n+VvM}fByN?P&o192beejFNklmo^MtqhK~zd?*XUcvyQ`HD$iS&=h4N?J&>#bhPq#H_xnk-!NY0#1raMH7=gn`<5r zrsRYSOb-w{-q4&(qqwW>B!P*i!0)8!Op+b**-VD2P$z2OD*1!_Ve796c3Gj}2~qrOH_r-JZq z5c)h(n4%@5oFm?vI1Y(;IR?Mkv$mG=?9j#~XU7YETbpI_lu`=mdhEz&6e>Bb0q>8w83Vg&53T#>}bYwWdRF zR5n(_@m>fbdq+ztd1mzRS?(%W2nepZ*lg||f~t!3`kqFkqFxEXEq_+X<935)_%Kh8 zsAMvv#cZ+wB5;5iD^!*Dv&9~89MBt7EOnBe^w~BYg4omk4I!FK# zs@=<0x9*r?@%jqa96vYqW+PRjHy|dKtOM51n%yPB8PB(o{EI?UF1yu|8U+Vd` zTo_goWg!Ay$1V)@av_TF?%I0!OxG=FHV@*-S_m#Qv9>1ssZ88^80f6G|Adu`$1X9M z<-^C%p=8Teq|yq0{7may*Gy(vctnAcussIh6hKKL))DD^xx_V%+N$hzdLW0@j0%-V z*TkCewDfoM0qi1ymWh}z);TnA9QWD+#Ud9mqnN}YR`rB z0?t|ZOJV_;)wC|`so9S18;6jwaXgrt!4pLk)Hn#pf{{NO7#S_xkc*?rtfYc(Up>v2 z9NATkuDuSOFPgXgv64R)7zqkC<#x&My{?LX9^<&Ra$;^rm4g#*MmvZ5^l)pVhieFd zA*o8)2KGN6(sb*=W@y?Q#!yN`J7Fi*Ar*6y6C^SYa401OeJVFL zFxaKg^8bCLQTifnL$(bLXA3uOGHB+Ovo1W<>LM=kNB!W{8S8pHHGlYPHAJ3bGJgN& z=<6lcO^uC>ojS3L*#fRJh;e+aKi{Icxx=s4z;;TMpDY8zp&#D+Ki-~Z4YZQM)78&q Iol`;+0PGz()c^nh literal 0 HcmV?d00001 diff --git a/assets/icons/16/TMSHT16.png b/assets/icons/16/TMSHT16.png new file mode 100644 index 0000000000000000000000000000000000000000..33bf951807ea8a0d89dc5ccb36a1c068de7e3e08 GIT binary patch literal 435 zcmV;k0ZjghP)(@YE$0wzigU;&elc40_> zoQzNG*a>6<z|Nftu-S>6_UN6AFv=Wikd;%gN1{N+151#*F5as)&aQ*B7kEtb$ zz1cl)N|*@Q%qJ)k5}a7dprLQU(7WIkgM^X^LtsJ?11BeU@w5^#7yMrM&kzl=nU#$l zMVOmcfI-vHn&JHMUD0^G0P-`xpa@);i<6aM{>rlqA>KL+VDbM93V6K$3b41Yp2GRF zx&j%bCHNRN?6}4N6~6&?!Ld~>*nRN#|I7==_j)L*>w}#wF3Q7@7;X&KylL^IKTM4O z=VHV)I+$7_(gO-GEkkPtK0y(%<{KAI{Q3R+XK7Z?n+XIB00B^FGcf*(2KgD}Y>>?v d-EYr;Bmo4Eg<5J?%3A;c002ovPDHLkV1k05wxR$4 literal 0 HcmV?d00001 diff --git a/assets/icons/16/TPLGIN16.png b/assets/icons/16/TPLGIN16.png new file mode 100644 index 0000000000000000000000000000000000000000..81ceddd66b964897d7b3029c1ee91d8dd01785fe GIT binary patch literal 275 zcmV+u0qp*XP)Mz`*Fj00#f}ESWRWm4O7n0@7?{VFu$cEg!bqhs~sAxp?b81EoVFN%>#K?$-zmbBAY8MqK~^002ovPDHLkV1nJ=Zo2>g literal 0 HcmV?d00001 diff --git a/assets/icons/16/TPOOL16.png b/assets/icons/16/TPOOL16.png new file mode 100644 index 0000000000000000000000000000000000000000..7cc360d0eab9e39f55c7fa62c2984f334134df31 GIT binary patch literal 212 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`vproLLn`JZ_jsPXfA+wE7l#aC!nvL}}2`YWF zYB>X&q!a^(q7nm}j4Z+#3`BtcfB!OkIeDDn^NHhNzI;ay1D~xuVFUht`ONTc!#c3- z41fQE#YDm);hJ$8@axGFhPP{1F}&Nnk%3)ChCwnrpMl@Sjp12eH-kh@K8jivWX`v% zR~TL|S;+AD=wSw43rhz1j&24X6EnEHbZG^KWh^kKJ}Am(_ zSiNPvFc?f9jbDo}fSHGvLD1KqLEhSifkj9dU$9_z0SE~B`ZM6O2^U~O=9uQ61Y=SF z6ETYL8BCM`1YGd{&ySx!N!AF_^ZyScrP&z(g3Doeiq;j900000NkvXXu0mjf;+U4( literal 0 HcmV?d00001 diff --git a/assets/icons/16/TRACKMM.png b/assets/icons/16/TRACKMM.png new file mode 100644 index 0000000000000000000000000000000000000000..cedb19a3b818508dafb2939f0cf63999ffe47e27 GIT binary patch literal 1901 zcmV-z2a@=SP)$vuE$@1s0aw0}Eb25D{CQP>Tk zU!hFoBQ9s6>QU|X=yc^OA;0<;UA;e_3V%wFBp@$amPqYqKOC*otunsCr4*vr)b}n^ zEJpP_nS^TKQMYUFnD$MUd(I2Ota`O)Y}wknD?b??f*=e!5s7Ea$FW`|NYs5i=(so- z4K+`NXHE%XP^+a}Y8)E!j#d)LQx~sFWQT6GCdd0UsH?6U*yOy8#YzE8-UvF~o}Iyb z>t5qIM5n?vX9U@!)0HcQbR(Z6G)9{GL!6@b8qMY)_l!r2lIAt&v+`7Tg@5_2suKc| zkEWmmMbxGWzww9nPNKuJ2%fau zhu)D}xge2R&YH&6i#;w>{p0U=&d~>1npAq-;p#o8Sf3YPyk*+oHERXopjxmzk=|?j zCnl~6s!O}0AWgQrP%agAkNBeX89K_er4DhD#K*@PQFH5>sYEGXutgF@$EBS(uU?4{ z<2rmE3I=VcX?O!q2`CK3S)3oR*L!@yU-fIWBN|}#3Bs&4HjFJ>KQh$LB>#%%i(XN+ z``4Cf{|Z(JQ6tYSN#xv? z4lbE7L5w-tZMj`B!_uq_SOP&Dl?6~3j;}EG_Xiad+ulFW_ZED+`n9#NpvrX>Ycizh z^HT>tGgI5OipXf&97hDX0$zKGQpJo!qG(9hqUC!(Lf^kHVW#nwY*`|ecB~-Nh9v64 zAM!N!0QXx5N6Wl;1VlVGDIP`5 zwsGE$>+qZ74sUJWzwoT{B%ac!Hw*>Cc#|A~sdh19G!HNjPI|mfRRP}4+6YPafx1kg zaCeDPuKDQ@=P9rV(G*$-?5BrA(b`Wn%-sxN_6fq>T*Z0$;6&V6`|w>~2h?%_ z+MS+zmVm$R)S8SFxtthDVwcrcZ_w+HouR$X4NejSpTu9)aWr2sujigm-1@%Of*ACA zA>yGDk|oMN`Sb=B-MI<9(+(BIgCa}4UrzHu5d=IDF<6$xGMYqGnZ4B+3U6K98Nom- zgl;(xy}TGone2@*mb~)%Bi^%{(L5`49LLHu3L_+e`Vkp2J+>uAo6XK(`t#RlHoKUr zQVf>oBTfQ67sf?bzMg`NH9j}&OXjL$1k&|*qK^YI)R1_c5hsTl5X1U7%b+v)MP zwFn9;0t>6a5+uZT&R}i$_C*Orm8k@@kdcT`LGloY#^B5ly*C^V+^Ki;q5 z#CXCmDM9MGx=crxeG`^&1QuQ0y3HY30rOBlG3WFaFq%`YzO!c_U6;l+Q(|65oX|Fu3m*!Td&02v}|{`>1Y z!}oX37{0!`|Aq1Y|G-BFYxiJy0U!AP_YVV)gffGmvI)_Vo%NaTXBqR zC4{{2gj+&UhF4ORfm=+G=ktp@)eH;_sbB-p4S}*zfT(>v55tT5*Et0wWH^PS7`{Be z>x1EiCx_}7vD(hS!0`HD;}-@-1{oGkUIu11PEhDcU>E=b*lfoKm`G7PI1OMSRRgX- bCK~_%Zuw8+Y-Gd-00000NkvXXu0mjfuvv9E literal 0 HcmV?d00001 diff --git a/assets/icons/16/UNKNOWNFILE.png b/assets/icons/16/UNKNOWNFILE.png new file mode 100644 index 0000000000000000000000000000000000000000..4f83244c0606f6c31fa2bd8899145263f5c947b2 GIT binary patch literal 376 zcmV-;0f+vHP)5r0003$Nkl~bumovlkd?f~URwl4_K7M)+GT;MF13)0&MT)`G zM1Xykuf<)`xfp8L%*50Rr4C43YK{VD_)y|G+dm3rcts4g(lCa`gj) zrYtvur6%0l#2c`1&ohShRreVj^aL50naFU#gO@)Tj8*s;lH8iF WQ)cVher*N-0000h0RI_c(kdnp)IY1EAO^#L`uchnhObi@emz>k zKn!3(7r6WM<8N^RRIvri&cN9TQ6|(4L?(0rY*7lc72S5)xBv$J|NoEG73lKVqmhwe f$-?DliAo0m{%uUcN>;XK00000NkvXXu0mjfEUI(R literal 0 HcmV?d00001 diff --git a/assets/icons/16/UNSEL16.png b/assets/icons/16/UNSEL16.png new file mode 100644 index 0000000000000000000000000000000000000000..e049cad6fa7330e0dd5f3b584a835374e1a1137b GIT binary patch literal 398 zcmV;90df9`P)p6{a?;?Er_NkpFf%bg(SR&AVahBNIVJ`Q0Sn9qbQ{qDHZd@W zNh$b`45rOlhQdb|Lk}}1s(4}g+~p{O=zLsa1iioj1?TPc1(5Y1^O*=a@uIa!0n=}m z>z6EzH9-6;_NEd{zgdr8uri$h;xmF=U}a&3RkP*dPC<}nMg~TS{|x_MFflSj{`=23 zosoe-^C$uVfpjt55xI0r@s98 z{oAm(|HK`1wMgi|NnmoHnmLH1pohMc=+z^8z}of z!-x0p82&RdJiw-w1)CtpFODe>?%s8O|MsoJ-@ktuzI^_?;tM~=8mz8mzyeftOs}a`~UO78^$XP4F8|pzIYBEmV!Z07*qoM6N<$g76Z!RR910 literal 0 HcmV?d00001 diff --git a/assets/icons/16/USRCUR16.png b/assets/icons/16/USRCUR16.png new file mode 100644 index 0000000000000000000000000000000000000000..587a59206ae4d75b1d01999036f9b29c2b93b511 GIT binary patch literal 472 zcmV;}0Vn>6P)NklakW-C+ICZF=q6!7q5d@ciwU#p>!B4xXOgC;sP`bZeBfmfPsMlgzEnXmzTu>b(21fSv*m(Y6v O0000(aRs8^9VsnhSE$iPQ`REEA^8tY%N>-B`%*@Z(ds7z;krVc_G>&kRk6 zCocfC#HcS&jMqB zY|b%>W0-hqKA0b%=FTwd{Bnj3w{|il>xVN$YWrdJ77H>bOw$KUgA7@IWfOxaw=l!r z=w*yg^=|1j{BKTY_{Z>*k%f86&5I`=U^M_{2oD=K!<|p*fB*VP;=T8vv8ory3X>X^;Q_002ov JPDHLkV1g$Z?;`*J literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_ALIGN_CENTER.png b/assets/icons/16/VMENU_ICO_ALIGN_CENTER.png new file mode 100644 index 0000000000000000000000000000000000000000..3f38738e304f913f3a4641f48d3ae82221e49f23 GIT binary patch literal 192 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`?Vc`z4Q?yE747(J@~-O<;Ic74XP3`ogA|* rgjfD^W7oMM#Iw%DW$O{wPzHwGl^!!Dg;y^II*Gy4)z4*}Q$iB}fCfy@ literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_ALIGN_LEFT.png b/assets/icons/16/VMENU_ICO_ALIGN_LEFT.png new file mode 100644 index 0000000000000000000000000000000000000000..34118621fba13ad8480763da50dba6260250d549 GIT binary patch literal 183 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`b)GJcAr*6y6BY;QL*#(VDmEVRKmX4cFrR$JoicmLvgA+m zWoms=ZhPo5OK5&Pv{pO)!LN-{4W|QA3f*!zIl~_vQajhAtN73>=Ejkk9$(F^4$PWR hpsKe@)oK+JLs-4X47PP0CP0@kc)I$ztaD0e0sv=vL^J>Z literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_ALIGN_RIGHT.png b/assets/icons/16/VMENU_ICO_ALIGN_RIGHT.png new file mode 100644 index 0000000000000000000000000000000000000000..28511e8bd51c67ce27f13544d348d53f2fe04d44 GIT binary patch literal 184 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`^`0({Ar*6y6BY;DdAw^ob`BE^ao zFK7H|-#GJxS!)#AhJ<3VNC)0-#vMGaV(CYwS#0Qh=;P57A;fNG81u+Sz4Q?yE747(J@~-O<;Ic74XP3`ogA|* zgjfD^W7oMM#Iw%DW$Tev9*N~=Bi)L=C^9qTEb%T-$T~U~=rjgTS3j3^P6-5O|IZgZ{&v-P7LN;)m;mFYn#7455eF3B@!n8KVieZwD%|zpe|?*@hgrPBZ4*=3 z$^VzUN=#bNCf>ogBdM!Z<8B3zyi}0jD88fgDUY(AzCe$rsZmm6>I-%y<&9hu_cCxD ji4H#}F)2yVkAZ=;!}RFCpIw4L*D!dx`njxgN@xNAZX-jq literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_CHART_FONT_COLOR.png b/assets/icons/16/VMENU_ICO_CHART_FONT_COLOR.png new file mode 100644 index 0000000000000000000000000000000000000000..9503c2632d253fad5d603211a8dc46cffa286cac GIT binary patch literal 516 zcmV+f0{i`mP)FMbQ z`yE+xYrG2FMO<8*V6VWu!-VWykRfu4$_!H$?Lg7Y%mjBR24F!K;N|6GXsJyD`#H*0 z8Lwun27rK$wkE^j1)>bI_AtOf5*q_U+o?Q;>7_nkerES;+y*c}K|+)X8vhsr1A_^} zf@NpmVt5TeR)`DWGyvvALI5L#Vp0m8GcYhn5T*M+!xsP#;G?~{1B0jl0000sv*%tKr%z7_NeKZ zvM^s%c*h$dtY;d+=^{44IKeED@qxpk#ciJ)SQxhKH(2iw#<~Y+8-u5-pUXO@geCx* CwJ}5h literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_CHART_VIEW.png b/assets/icons/16/VMENU_ICO_CHART_VIEW.png new file mode 100644 index 0000000000000000000000000000000000000000..c9c43345a07b6011e07acd1a138eb9632e38668e GIT binary patch literal 186 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jh-%!Ar*6y6BY;4?T0Xl}k)78&qol`;+0GTaA`~Uy| literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_COLLAPSE_ALL.png b/assets/icons/16/VMENU_ICO_COLLAPSE_ALL.png new file mode 100644 index 0000000000000000000000000000000000000000..2442e86a3d23eca95fae11163f9cfa6b6e803069 GIT binary patch literal 121 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`4xTQKAr*6y6BejVFh22{|Im^b ziHoiTxy?9xLq$Gz#u1NVah@6p9z%t8)t(s|rc)+H%r0CitmYN#Ahf_!B7lcM{Xpy4voF2=S4*;iSe@dw`*kk(s%9 z<36=67AyJb62eRM5*GRCyqNLFozEr70jTWoTJ7`$zYek~G|!mABw}Y~IALC(z5~P2 txP~Pz$NpC*WX{ew@S~pJ^Hm`u!x`i5DG8Qd5kO}#c)I$ztaD0e0s#L$Mpgg- literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_COPY.png b/assets/icons/16/VMENU_ICO_COPY.png new file mode 100644 index 0000000000000000000000000000000000000000..aeb7f6ad155686046be3276b23163689327c58af GIT binary patch literal 361 zcmV-v0ha!WP)MG&1~zxE`>$YB@L5(5 z5;iQjTmS+xQbHJF%*;#-d8v*(GZq}$E~}U42{&Nz?0&eSC37a=^fNaXJHz7DCqRDT zVPs-BjMoL&z?yma44*!K2eU(xCW5{2A~v;90+$AP!+fmb56@2odj}@~#{vOh<<;;X z?gd-`p9?^MpaC$2xB$s6KsS&PmquBGyyuJz3^)T93cdgUsEe<~DVE{U00000NkvXX Hu0mjfT$YU% literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_CUT.png b/assets/icons/16/VMENU_ICO_CUT.png new file mode 100644 index 0000000000000000000000000000000000000000..7ec0c351614aa3a09ff97c9d3cc308666f95bfdf GIT binary patch literal 473 zcmV;~0Ve*5P)3{P+=MQLBqf8i9VCMyRY4LVo$Zi6z(PxIQApw>^hS^n8i|>@2zGQxhmdp= zI=F;R0Si)-Nfb1SMQE{ugF=Q-@A*Etfzu zuN3p)%*^}XjVl(5KE-+~nX=M-10qiY4FJEiAImrH`1kodfgby8S?`@Ew_0W@n*i|! zM2#3WpV@x;sepX7{AsOk1Bcq@)jEI%6o1ry6bSeec@`+c1s^;xfJH563dmOA*QHX) z#zQev)|Q#JPVbsgUJJ=|HopDidt88^naRHKnj_EM)7B;tj+o^Hgrx5>I992Yy7y{e zrm_hEVk~;;@1x5V=L*?>G26Gn@L06KLOB54Q0U2*?agnNm>&n?1=$d~s{@>5Y$e{6`f#D15KNiDl*G}94yWrx*iyuImAeupj zFziQm3A$!RrvIKG&2SgM094a{WS6k~WBP!u`PQYgM__sw;kt1c^8Y{M2V9!58h~jC z0|PG2D6xPHK+Xo)4C6C0{Qtu6kKqji7QloqfF5AD0v4+QT3A9GU+kb5poK*<$j{L9 zfYT5r5CKX^_@WA%A?o_(3UC8J35k)BaVNgeMlN7fCc|D%sor^FQf{`4|p(w+k+KkaU6eE7fn zKMzlQ#DAkHlNO2dg>3azx>Dk!ec}=i^S5u`KHOktFx#*0tY;P70(2jPr>mdKI;Vst E0A&kOh5!Hn literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_FILTER.png b/assets/icons/16/VMENU_ICO_FILTER.png new file mode 100644 index 0000000000000000000000000000000000000000..d3d1257535dad299446f8198f8670fc2895e2e01 GIT binary patch literal 379 zcmV->0fhdEP)6rZg&%p42EX@r6Kd>F}!{Mt`npgB*p}jym{s9jHgeZmv;B|G5q-P6GQXA zfBzV^ZQIK5^x2cCw=bWmfQd69E4qF4OwYZ04<>eYcY|$12HUr9W4M3+-Wn-ko&scX zCUl!_T{&HF^X9DuGiJ?(iyb|BgyHs`n|maMxg!rAJopE%0U#hL%$<7t_z4CWxPSjH z0}BglCc0*v1{_3F$jHdZ@b}+;49z$VAO$cDeFIou~@8002ovPDHLkV1nKyu2}#8 literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_FIND.png b/assets/icons/16/VMENU_ICO_FIND.png new file mode 100644 index 0000000000000000000000000000000000000000..850c2387a3f093f4dfa33fabf779ef1d64534832 GIT binary patch literal 223 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`%RF5iLn`JZCoB*!I3$r}b?m&P zgoLWXp8xuJv6kAMYXqj-2v3R>x^eTz)0rAynS_s2E)#trbRy};lbH&4{(qg3rriB- zT6*IriwjH7>f~6Q(aHID_{VZT8OQKLj(ZIx0+=HTJRAPhygnsa;1qn>@TdO;R@PeU z0}|o~RL{FC>NaFJ(|LcR%hUeo@N)%1liGJRY@FEm@IQaco&WMYJv>uAz6nfN4s@o% WLmR6bB99G#Oa@O^KbLh*2~7Y?L|SM7 literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_GRID_FONT_COLOR.png b/assets/icons/16/VMENU_ICO_GRID_FONT_COLOR.png new file mode 100644 index 0000000000000000000000000000000000000000..529e08c35c6cce0ad232b0c0250fc78cfc361fd0 GIT binary patch literal 435 zcmV;k0ZjghP)*-rh5=#>VPXEw$il+K%)>9hk0Gh9rp5sBPS323hXW!E7*>+2<(4)}zog>5R)tW(fx0BI$ixOIv(^ PHZyp-`njxgN@xNA{vAH+ literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_INSERT.png b/assets/icons/16/VMENU_ICO_INSERT.png new file mode 100644 index 0000000000000000000000000000000000000000..188e04081d0daaae53ec47926ea6c44019efa086 GIT binary patch literal 326 zcmV-M0lEH(P)EJiwtyfr072?X62^kKi?6-_A`~ZHbCYVR-fC&6j`w|9WCG1mOZ4 zz|qb3|AeV?{_B}oe^%2owqZa5ObkQh4CL9xI>y37;pfB zE`ZsDZZj4G{=ZPyHI+b?EJiwtyfr072?X62^k9<4l@t@0R2V5Tuvcmm4Hz{BcE%*DmU(Ad<%Fm3t_h`>L_!}|L60vKMv1(q+G&G6~-7cl!B z0|SGEcnZVIH*Y}(d?3mIUS3`>Mh+7gU}B&UFpV0(K(PTx(fI#`x~{1NF`E7}FnnQT e{|`wRlmY-!CO&WnfEO+R0000_rCy4fRTX&ps%kl@cl2#{{IY& z0*nm*zi=}DvBl{HY~bR>iy!_oGEHP;U{GLSWSk4)v#jn=`2YR;Z@406W=4khAAZ{A z^u0cU&5+xdPcKl@F;S5e;+}E~6b7%~d|?Rj*Mlqg_~{43?)|q8{LZkTzmkEMUx;XpQ%giHzv6yl z2sYsI>4OZ)ioy(rdeTH`zImIS;qtZTcN!ZR{(ud*diD^5x2rM(4>ub@&42&?XSj3! z4Z}YM#zwdoWF)y5czM`~v;EF%22i@m>3MSjZor*;Z@_p!002c^gh1ubWR?H`002ov JPDHLkV1mAV#d!b# literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_PASTE.png b/assets/icons/16/VMENU_ICO_PASTE.png new file mode 100644 index 0000000000000000000000000000000000000000..b68dee14bb8f523a5b670c5548556244f7f6a3f5 GIT binary patch literal 347 zcmV-h0i^zkP)?yEV4AKkYT=-(aP>_>`qF}<5Squg|Ct%zq zB@<4>BFnRYG>1mVGB7eSGTdEs53B(h@N%&*gvG=${Qv)-VfE6*Ad4^zU;t?bfyy`~ zTrP#HK?h6>6apqn4Pe10C})zzNRa^`AZL*G|3Ab32MlO{k%3X+|33!X$CoA@!D|2r z9NXHUz<>rqk|r{|eEn&=tX`fc$Pg9=JU~WD2t$mSnTa7U)sbh$f5U|++6Go zi&vij`Gtp(iQzC_7hnTx=H)Yd`urX49Tq|w}(qL$mpm?;wlTG(ZKdV?k#=jpQ zC$}~?&sEe?>(lT(JxwR+$H&L&7HSd~7Yl}KwJ=6xwYVyK?P7b%Jc04@bG_rMER8LN oau|y04j42@=r2gu=we`4Hm#iH!LymGfnH$nboFyt=akR{0L-afO8@`> literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_PRINT_PREVIEW.png b/assets/icons/16/VMENU_ICO_PRINT_PREVIEW.png new file mode 100644 index 0000000000000000000000000000000000000000..06b7f3ae13ccc03da318cfced1792b093ef9ba3b GIT binary patch literal 500 zcmV!FgiXBFY)-BikZQ35Xd?xqrQFzE-i0hr_hsRJNe$olXbaJG<1Z z9#nGD)g?CktZOR)yj$z=ntaR0d5+5zkSGaQ-Sn0P%}lv~VHl`-2auB}idqwA6^v%9 zrBtu>F9$5gw?*aDer+bpPW`mRVM6|DW;{{TJqT$a1W5sEWKGbGYE!qtZQQ(yy}*U0o#E zu%@BnK$D)s9Bzq>Crp)xYuJJqg-=?o$YtQ(bzm2(WQ8e<>KTQ*tbvAw2|lk4e)u<; zwL}$2G#IfRpa1y6nHEX5)6;aCHe3FaX_h#6Vn>UNcrpV+g10}Hs(|Kopc@%HUHx3v IIVCg!0R7rd<^TWy literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_SPELL_CHECK.png b/assets/icons/16/VMENU_ICO_SPELL_CHECK.png new file mode 100644 index 0000000000000000000000000000000000000000..9d1881a338d9a837b6db2c9cd014ca0be6cf7bca GIT binary patch literal 391 zcmV;20eJq2P)lT)YSprDviX@%le!9^UzL2wp=KeLd@(H|oIjDoYc2rfc!(Lz&n z$mHxO)*+!wl9LNYl91Ly{NV2W+_wIn4phziAsa(i6+oHG~_hrQ)9USR@`65Wj z36{Pkj?8kiP|DE)8-zHjKuF;mo~S~eT${Fxn%%#&6zaMuyPd)XfKAR}D`VZ+fe9+x z&qXhwTO!PW#oWlbJTHB~z zrmLe!QMKj{2*;tpgF`@C1)<2n-z8sKX`NN9to9N^Oppj3-~o)Sw~y41Uh_$O<*uUc94MpRrGCl(f^Rl5ifrlfrQ84j002ovPDHLkV1i@>u^#{c literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_ZOOM_BEST_FIT.png b/assets/icons/16/VMENU_ICO_ZOOM_BEST_FIT.png new file mode 100644 index 0000000000000000000000000000000000000000..5f0d6e90f0f7ee67aaec37958da5810eb082107a GIT binary patch literal 513 zcmV+c0{;DpP)oCc`qnprUZ`+L~V#)>66DvsgygHK>_RRunVrOOsE96ECB&wnOn zTXaJh;m&^h^}4OKrHZX%2t((}4Ge5jk_`X9i!%Ir{F4xDa@^j z>>VZ$0rE4*5g?m8=AL8_aAacOHa)?>W4D=s-+>b>29g7*fvROdG2s8-ehm( zG-3lF=YnhmX##0xVr6GwVq}sa+6Cw?0crmJ@24jKe_iNy)~f+D00000NkvXXu0mjf D*A(hL literal 0 HcmV?d00001 diff --git a/assets/icons/16/VMENU_ICO_ZOOM_IN.png b/assets/icons/16/VMENU_ICO_ZOOM_IN.png new file mode 100644 index 0000000000000000000000000000000000000000..adc7f0c03b81f94b3ebe45679ad0f00843dad231 GIT binary patch literal 421 zcmV;W0b2fvP)oK8{EHM3CFHvXNQp8Nmqz5D-R0K^7~f#g7Huxhrqw`Wn)F}V#= z_~*|butqf<6EFq=kQhh~qz0rGSuYca0Qni@h^q1;24-ev3=2SFAUTj4s9HE+0TG}8 z6BQLyK0La-M*08m$b$zP{}7dwLC*fmsJd7{PB(-@Kpe#o z3oK8{EHM3CFHvXNQp8Nmqz5D-R0K^7~f#g7Huxhrqw`Wn)F}V#= z_~*}`|L6cD29g7*0jb3>KuyooLrup7#b$H>k^`v$sYTYy0wO>GCMqhzprok4pss6* z)s;6dpJo7s%j?%~K!LjhCeFk_Az*<;6)3dt-G2bK2^#>(fz*K1B8xMD2v9tOqN=U4 zkKym%zZjZ9Vj#JHOzdBN3Thp|FyP?9gMUEreCWurKk3Zo;j900$0SIC9|7L!@3Rd_e?J5UprKi~OU(KR)!0y>3E&t=HbfL3z?j-_EXP z=FK-d@9hk5h(jDqB%*p`@sjTqyW3H0Z$MC-2=Q194qMxSjaZs#9Rp!p00VkjpE$5Y zND*_>2V7z9}Zb@yK8Z!-F9xLXMdyt2yWFXj7?og*Pr7_YiP}<6xi} zCql>JZE@k5aI1Vyp!XBAx+K}qM6wQNQ~*AXpC4|olyhcORpGhZq!cLD&_ohZJxGFP zIPN^zf>y7)^33hl(AVQH-4G^NC>xfDA}B6LTnLgOAVNKptmvM!f~fxh6b?{|g0V4-9PP^=!- zMX9xd#EgDU055Pn)ZYe&qg3UCM@76my^6@&_vOVgm&wixA(vwr1D%<4YHDAJ#A0wL zqA0U*thq^kGd0 zH0{%UA;Kf5peU_~&wCUd?JZT;!Gg)cS;j|8mjj)9P9)=SOtUrTcywg5_?ZO@CkrSG zDHRK`Jte|c1VUWqxIN@S&|jMCR=~np`L+n>ty&jLLyJrvk4A`GkNPKUBcdp!`O8*(Cu3+8y{B|3tPFudRo2Bck?WWIoC(f| zwBl^Z>kT3QV~pu4y0hu@WL=4{6%kZe;Fv8qTXDP4(cU5j)@a(SbumT6pK5*2up+$N zvK6-zqfZ3Zlhw4@x)9-cDgddtY`xin+l`>VSqd$KfD2N9YbBCNrDhE)!pp5$V;F8z z5%4~#o?|XEi{bKKSV?$y7s(xa#Ur7BlAL0;+~Y6xVlVN-&0p}-&-Xbkc|aZh@anzW zmNFuU*jju3yGKa#!P z+FY48*;G1uP)IP?x~RbXhK!UBFMVGdDt=%<$h-2nH|;oFJ;WjYZ}=Ctm{)stN?#NJ O0000XElN6iqY}G8CIZ@AZ_nrOl=uzGT)*U?2s5`fbOtd; zY~ZY`shIij_wVN#Nk(P9{|!U`#W!7Ln2=V(*e$a|r$Y20SHzM7sZBH8^b#0^>&O4GCxdw6h5Jl{n;_`4i8?P$O>{agzUZJkWs*p00i_>zopr E0IBXz*Z=?k literal 0 HcmV?d00001 diff --git a/assets/icons/16/WBSLKC16.png b/assets/icons/16/WBSLKC16.png new file mode 100644 index 0000000000000000000000000000000000000000..c2f26e9d2f051318f8ddf4257b0c1ffbb1523651 GIT binary patch literal 210 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Gd*1#Ln`JZ&v~Y_Yer+EVH>0V zkNqmy=U+$U80jdS_2iAU*t+k&O=sfYo9YVO1(FPm^4olp4zNi`N`7EcW8-2JUdpy1 zLD;7FzwF_~+wTV)S+=v|@9~hI^_*eM4zoV8>J&XNGMvDf(0H1~xHski(>ZFuGuu{lAB0nv3XS1_s6$Y|>eKUNM3+FP`0xReNk|p$iL0b5cVWRs~sm z65#C1)~0Z_?$Oh5HVcgLVap^!zQNE80!&2dLeh-v5|Rwih1!g62n)KxGxy&yJbL>L zN#y??P+*}b(z0P-NG*iK0s|TVX@&)AQUk+(bouw2Co!x)`ve+8SX@9TP#MA6(8A#T zX5wN18(?8z_`hWR*(Wh%8<4fR*Ubuo-O*N8T8v l=9I2w#lHGTgJNZRI7`)$RBlA<~Hu+Ag+ItnJ(z2FbbyY$Elwc ze8IMWS(sVZjm?XPfl+ezv7-wVk`8eH(?6KW;87gvE9Q5za(2G)o*g@^+4>m+TBF}R zFpz)bt;WX1$gL5l?lbeL(>6wL507m(7>>pr$Y#)3QrPr=0!yd5*gt(nSK+$f|MeLe YLKnxUt@&rU3g~DCPgg&ebxsLQ00Ih4=Kufz literal 0 HcmV?d00001 diff --git a/assets/icons/16/WIZARD16.png b/assets/icons/16/WIZARD16.png new file mode 100644 index 0000000000000000000000000000000000000000..69314a0d39b85306e1f03b85cc4abbf2a7b6d1c2 GIT binary patch literal 235 zcmVpY%Zf6jM!|(r-p%MUeMCA=aHAU=fEb%NLaI}gp{20 z`ENhIzd3ebr!KlY6G6=iGW!Jt1tfla|BlrKOoTL-l@x1mbMt)p^8ITfA=jd4cJT_l zzH8r+|M4j~pVjn?Z5XJj`5Ug-(jwAktOjTiX)_2gxGqiUI73A002ovPDHLkV1imGWt9K` literal 0 HcmV?d00001 diff --git a/assets/icons/16/ZOOMIN16.png b/assets/icons/16/ZOOMIN16.png new file mode 100644 index 0000000000000000000000000000000000000000..be000fa6003d62cc303df80fc699eb88c15ceacb GIT binary patch literal 422 zcmV;X0a^ZuP)oK8{EHM3CFHvXNQp8Nmqz5D-R0K^7~f#g7Huxhrqw`Wn)F}V#= z_~*|butqf<6EFq=kQhh~qz0rGSuYca0Qni@h^q1;24-ev3=2SFAUTj4s9HE+0TG}8 z6BQLn)pB%0h>ym`#y=n%L7G6Cnb_DE7@3$Qh<5>+OF)`g*#3C}0D`>U9iNty QbpQYW07*qoM6N<$g5guPdH?_b literal 0 HcmV?d00001 diff --git a/assets/icons/16/ZOOMOT16.png b/assets/icons/16/ZOOMOT16.png new file mode 100644 index 0000000000000000000000000000000000000000..1c515408c8bf734957b254c37616b33915d8700b GIT binary patch literal 426 zcmV;b0agBqP)oK8{EHM3CFHvXNQp8Nmqz5D-R0K^7~f#g7Huxhrqw`Wn)F}V#= z_~*}`|L6cD29g7*0jb3>KuyooLrup7#b$H>k^`v$sYTYy0wO>GCMqhzprok4pss6* z)s;6dpJo7s%j?%~K!LjhCeFk_Az*<;6)3dt-G2bK2^#>(fz*K1B8xMD2v9tOqN=U4 zkKym%zZjZ9VqiH|)-OK=wGLnyaPZ*4KcIL%bmZ8d^z1^gZOAr*#10=j!SK_@hUcR) z*J6hHdKQur(qC5AFTZSTdDx9j7=FEe&G6~^l{Ft^#UdFR8~+fMltIo0+03V@6T&7c ziedHq)$07*qoM6N<$f@opC;Q#;t literal 0 HcmV?d00001 diff --git a/assets/icons/16/ZOOMTF16.png b/assets/icons/16/ZOOMTF16.png new file mode 100644 index 0000000000000000000000000000000000000000..c1a10cb78af88d464d7946e0d4d5353f795964e5 GIT binary patch literal 515 zcmV+e0{s1nP)xhYUNXEl06s=F}Gq>Dh%~Ijmk#(=+v8`1gN%fyV=e zw2BER3TAZ_FfeFLf^cr+VHm&yB0vEqDk{Rj!0-TDI5A`e7lLg=wizUL_}B@CpEfo;AC-B4fPuH)k`5-G6$gxai literal 0 HcmV?d00001 diff --git a/assets/icons/32/ACCUNT16.png b/assets/icons/32/ACCUNT16.png new file mode 100644 index 0000000000000000000000000000000000000000..3466e3e84c51254a739657b0dd905f68aac41943 GIT binary patch literal 443 zcmV;s0Yv_ZP)eLz`&5sz`!8DKpyzOz`!u`CHI?}#zuxeq-bPNKnY-C z7+}CcZ66J}5MUbd4q(A0@$cV%hPAt%G3-D2is9S$zeE@XNjotq4F7Sd_zx;E|1-=~ zk>RgtY;634*8w2Qw;p)TKuy31Dkm5j%I`e+$N(#_Sa2!cfATe$UOc;>s*Z?FEo5M1 zM3k6JxD3=9mNu#liPV1cyZ-c+EsWY9}ATs|1`iI9a@g`}ndVnd9HVW@nQ|i@-NM?N?7y|$QGt6XUWGG*=elyh^fNVCw5KxifulfI!HOUAn|Dp{{06M`oO@z(D;(;%@mqC;Q#;s47cvS zVYqPl8N>JQzd`&T42+CZfBpX5QaJJB2bvT_F!1E*M~2hqA2WRX^aIRiWca`0A1hOB zPRDDMT91VmmV-*dJqO|3BMeMTrI}r?PGD2Z!azgt?>}Q`PVehA_|&k_!s25eVi*=j zpJ!!sJotx@S|$b>0b(qtsRM`wOrs897)n~+;9dNfb@0KLO>Lex8um^$%Q(SL-!T*Shm3HC&#ICec0XRag;qd7e)B~P3W-( z?D%rUlRHiRm#^Ci17*m~-Gd#t+I*-79M%|oqfhkTF~F_+0(i48RF&f4v(FeA`-V(* z*+Qto-SPQB%`7NWObW@&L#($zHSiG6>$XH5yzdJnC z&?3%XxC}y86q7SE%w%oN6uT%XCSS{P>dnkL?E

    }V&blL5InQrC(Bi7gZQJU5_x zCX7$Mt{SMjJIKdWZjgfX5>kCEQwo`YN(VSKz_T@~MQKKzD;ZdF5F%LlJqiU9A*OOn z8!E%+@7ENqzpuyA9cVp%H4OsycF$3`nzmK-$t|YwBRavPQEprp=(MxsM?70_vTKK_ zX{kU0x8*LVbq9=?o>wr`~|$_JGi#sC{Epftn=O)Xo^hSCu8`2(T(?g^KhLV^GQ002ovPDHLk FV1nx^N5}vG literal 0 HcmV?d00001 diff --git a/assets/icons/32/ACTINP16.png b/assets/icons/32/ACTINP16.png new file mode 100644 index 0000000000000000000000000000000000000000..810138062cef8b2b37f8248ae516184d3cca4db9 GIT binary patch literal 172 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=k0IPZ!6KiaE&%60D08M0!dNa3r6& zVfuIZ@}vHIR~z4^B}pV4XwnM^o$NY^F<1BUfs)fayo;_}Pr2jp(Abb?o4}0iPx&I* z&RT74@|eojtj#jRP4g17{p2%#l_1ere0WFx#DN_iIxKz5G$A%qPGgIJ9glm Q6VQ4FPgg&ebxsLQ07ghZV*mgE literal 0 HcmV?d00001 diff --git a/assets/icons/32/ACTIPP16.png b/assets/icons/32/ACTIPP16.png new file mode 100644 index 0000000000000000000000000000000000000000..ff34b09c43e7e285d200ce8bea868c2ffa193192 GIT binary patch literal 525 zcmV+o0`mQdP)6{BGS>H&o4k12mEJX zWYAC(V+iuqWzf}j51WuhS5X#ko5<-nN zvXpGure;Vq%l~Pn#@2-5%_#FZ{l2eXeZT$Q2Kf2!kobx$?oGq9kxlYeQ}`I>F7(Yh zp+>q+y~lNmzcPX0m2sa0p!h2j_$iAOlkZOV|C@jtb!8ndh!}I#l<>T&F4G!(H35l} zRfASJI@F>{^lE@5b2;*J6QBrW0Eb$#+jk93%8uUJ@CdI2;2=m(jYernCNeW(!B~I- zK#N=^I~Zt;(zLa`Zas4sCv%6t9z-q=Ku&fX(o&*e+&IV4u}Mh??^iuU)($p6Thn8j z_R1{?4Uwa;APFVK8HiDZIsd?9Ldn!nQ{)W$_&bRtNWl;q5(wblr8yz-zkUrpVYNE2 zvv-N@-77d8l5@!np#3WNc0gzV&N=pvZn3^~fyYOiQ$K-_L95NCukW*%g*-%V&dx1Z zHJ-w9_vF$9d|Z;zR!zsvyVK4@m^)v>+4&c_07|vho!85rdKm;FaZ;w~zM1%}hlwy= zG^;UMZj_OtdHYwr6oUAUxzGULh57@)9{|4P87)7E1T4Si!vFvP07*qoM6N<$f|2y; A4gdfE literal 0 HcmV?d00001 diff --git a/assets/icons/32/ACTRJ16.png b/assets/icons/32/ACTRJ16.png new file mode 100644 index 0000000000000000000000000000000000000000..4fc65a85eaa7e1f1121cd137afdf60a1bb38b249 GIT binary patch literal 152 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJcuyC{kcv6U2@p+eEHE*|9OpX(~=|-4m9aaxE|yl%&mUaWZ{RI5^T{NHnU9I*YPDRTAjO??*P*b z2{s9XUaN-04O5w=_3ODE`U>eoD^D#=Fz~|0du;TUpOF%4v5^2`{MXGjG6O6OcGr zAJ?l46D{gwp9Wa9RG=_F35s9_aA+lmV{g1!)iYQZsq{$z4uZ_|7?hP}BReY&j0GtG zw8&+$!_lT_T}Q|3)-z8re`@;mAaZ#S@^TZ9kroZ()&-7F%ql|oi25O_ZmbddngR2? zPi{eYm>fl#6qJ@^AyysX`U6u5C36$aQ48$j?b_5f(9YCrhm}ubuQXIiTZHrf}-2_jNAn^P5Zx|Egi09}zkBM3q z%gaiG=`UZtGJN{<8IHey|AC?|K0O~?U{O5;3bKPG^TtF;fVW2XQb5KFyKRR#+uX-kip&A0R1mYYWta-Tx!uZ2*UnW71;mLwa zj6*vFaK$;PX@ZGifC1BpcK{2e2B633$SDUN&%a1=T>z>rnVJ79E}S{>!Qc;p*wjL@ z48#@ZxY`O#7$S@eTNr2s7#S`oNC-TknfVMu5dZ+zxrcrWVltor0000~$nY z;@|(-=MS7vXbwGC-=@yfwyZ)O%vYhZrzJ!DW$(9@qPyd}&zh)wKNtR)w&DtcU zu#=IptOcefT#T=n)U;-sziL?coI%X!iw)z_qKvHL%iF>f4@}|E%PC;oAQP;_yw}0U z>tMZr+@{Qi%p=wfg40=4KX&o!%rtH+%$UmTeIcetdr3!VJKqcmHVFfvoR7OYs? z*O}nWzPQynwp6Dj$|@qtA|&+q5rYF@6IxGH{o`DF#ZYj~bHi8VS*xX4m1P+ij1%(% UG)&X?0e#8f>FVdQ&MBb@0BJB~wEzGB literal 0 HcmV?d00001 diff --git a/assets/icons/32/ALGNLT16.png b/assets/icons/32/ALGNLT16.png new file mode 100644 index 0000000000000000000000000000000000000000..b58879e24e6c2c695cd73393f6c59aae1b057a00 GIT binary patch literal 267 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJOP(%{Ar*6y6C_?X2p*deru6L4 zhyV9$*xcA8*J%AWwnnR&n><22)%sV9ii=fGbGq*yI%wjA855-lmCs3{z|K1HNqh{~72z N22WQ%mvv4FO#uE&V=Djv literal 0 HcmV?d00001 diff --git a/assets/icons/32/ALGNRT16.png b/assets/icons/32/ALGNRT16.png new file mode 100644 index 0000000000000000000000000000000000000000..b58fda8a58e1cf86bc96194ad2a79294b45b8391 GIT binary patch literal 270 zcmV+p0rCEcP) zC1-UMfYmTD3@~6CbpXRicK{=;44zgZ@)(vA@PH>Y3<0J@aAAWBfaRDH8R!LKQVRZq z@SsZrOe5X_EVv}F#n;FR0T@^^X9C``0v1xlsvC46z(}wK18uov^}O0c3w2BcTQJa; z3$4_#5Ng4|S}wFw$HXwefN8`#fCY&Ssybz$afA+@&`KQ>!TKAc-ln#?Q83a00QRG5 UZu#Y@M*si-07*qoM6N<$f~n7BtN;K2 literal 0 HcmV?d00001 diff --git a/assets/icons/32/APPLY16.png b/assets/icons/32/APPLY16.png new file mode 100644 index 0000000000000000000000000000000000000000..be0f6b2cddba5b42e239ebef8bcb8ead35875e31 GIT binary patch literal 376 zcmV-;0f+vHP)@kZf(t~&#G&vD3W`Y5&%`j;Lm)Fb607+1xy$jYhsmSsKX&5O;0ghz5$^yNLJDAU zdGO!?hV$po5j0R;*A&iHRaIm7_wOGA6B85VAz*Lsz+h--M67bK<({5icr6D3l5zov z-PYO1uy6_X8~_9EuFeeVnz~@ish$g}%8MA{V=p3s#Y&pC|_q0w6~a%4!rj;22t}9d;$*C;$M5 W2w*(`4sPE70000 zxiI|yhuPQwmwZf#Sv{}z&_W#(LI#Ush!bVNax_xMf+Pi2oK`UbMg6Rf0=OJ4)G;v( zFkl+-4q!oIgQ{2=XdIz~C$v(>gb-uGUeANYm=bBHZWN4k006Mvc3&$=0qp<)002ov JPDHLkV1l-ocuD{O literal 0 HcmV?d00001 diff --git a/assets/icons/32/ARVERT16.png b/assets/icons/32/ARVERT16.png new file mode 100644 index 0000000000000000000000000000000000000000..ec0ece155f15c4b23da6bdc602726f2b9555e656 GIT binary patch literal 316 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=hEVFfx0(IEGZrNls~CvizMkz5f5d z^XUmG6A}-w{WG>nOiJ>pDcMlQ&n(I)+|ziyNB}6sxO$;cg5x#@m(Z&ziJ>>H8S$=b zQ&ThuXvjQ}BUgGLp^$-l&e!=5IW?v>2V3hg1Uau3NC291B%5)I!lG@=5`~^emWcde zzv%tU=fFxf=^0^4&klX~FMm&HYU4yr!`08P%1JF{w3*h-5b^GQ%^4F1TZU~mYm=D5 zPDaYI7MLm+bQCc*ZgH@QaGI2*)^<>i$=l-$YnZCi|MqZ>35*V{GkHw5J`M(1suZ!P z>FR}Zj7u2R*j6=PoHW7YfRo3;6S|z!CqytEI*{Rc!r+S6p+E+P7nNZ~+y5Qx2ZjoR Mr>mdKI;Vst0NP}DWB>pF literal 0 HcmV?d00001 diff --git a/assets/icons/32/ASSIGN16.png b/assets/icons/32/ASSIGN16.png new file mode 100644 index 0000000000000000000000000000000000000000..f96f3214b832a37143981b43590c54c01ae79a6e GIT binary patch literal 290 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJm!2+;Ar*6y6C_?X7^*FOU~j7v zWt7gOY*wh&#>l2);O6Kj6~?;!TnxkIG&Qyg-a||C4o!)y_-bg#V~`;AkuSlq-#MmX zg3ZcTZ1Ef^YVJv)2DR^s_Izr&B5PfkRnX3Gxucvxd5zwNO$N%I$zfh1*EZFjXl3Bu zxl=(~m1}j?OcvWcTVGFRoi4$i&f(MkOGI2jrJwJKOh~|we!e>gSM_x!u2{|}$yC_K zcj2nBAt<8 literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATV16.png b/assets/icons/32/ATV16.png new file mode 100644 index 0000000000000000000000000000000000000000..372e85d0396c0c05e0b6e5a4de5e53bce6fecd27 GIT binary patch literal 152 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJcuyC{kcv6U2@u}c@Z!QQvJIJ5A_A^Y{xdK)qKf|4WjEu24J+EI- zH3ViBNs7QNVPH_eg&7zbT$mXC@1Ig4DuLoK1`5HnGBFE=fB%jPiAplKhooXv^XJ!3 zhTR($FnoCX62!gnkAcw<77|R9I^h351{Dx3ASA}X%P)i#3yMlI_(tV02ndUVlxiS{ z1QW#$`2SY}MDq!Xg88#L3cwg0aB}lvbp#Wo4q#?tQieDHo)mBb3`a2j-%fTp00aO3 z{|85bps*O2pH?w}pd+N@R3Pc$KLZCf$^ozgSlKy=Qhev?8HQ`;kAj^3)-rreyK*B2;u0LT}htOW|v&C90Xbj0spKN)te zn+vA@|7Vz))AM=(NStB^fbugaUlVe~{w+%wKD~bfVxD=$^CpL?bwLgRM_f3um*K&! z%b=qA4GYu1z{W;~KU8%9K1V!#aEsy0p{<}4|A&!*DKf3=-4g~Rz{o&l04ZGl?+4{` zP=5dQ<2%E*ub)6R)n;|SX+c-dNNoq8I|5?K|1Ft4Z+)?;rAd1LDLT&lXJEL(@%v9K aF2w+;F4__fH2_xt0000bP0l+XkK?uar& literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVDET16.png b/assets/icons/32/ATVDET16.png new file mode 100644 index 0000000000000000000000000000000000000000..c59568b181a7cf953139fa508be8ebba88c81663 GIT binary patch literal 304 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJ@18D>Ar*6y6C_xbWepBVeEs@W zr+i*bPGUleM|w(vz=GD)|B@1R27l6LtW-K2fBD9ZAM7f}m?pDCo;z_O;GBaq!#4?K z=bv-cAVKOQUxMQH7G=|S?Qt9|fhXIY%~`HZj5s|} zdXf(hGf#wsTa{FTln>tz2BmlR>OG84PdLMNo0aK<$%p^;hkXJTm;8FuYEsOwDON&p z0nojl|JysO?|A8>-3|0a!yAU1uG-da2QM%)7&zHameV>T2MhuRPgg&ebxsLQ02_{Q AM*si- literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVGRD16.png b/assets/icons/32/ATVGRD16.png new file mode 100644 index 0000000000000000000000000000000000000000..d422f244b2578c0d0a1030297fa9e714b351d1d6 GIT binary patch literal 207 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJX`U{QAr*6y6C_?X2p;S3)coP^ z-#z`zOonZjRJYnyn_Sc;W_VS3b()!#Qx1GNAQnMmrE?+fraZ0$hQq-iB z0jP?*aoe;^fi|I9nFB`*BAgy@MtQ0(UednRMS7oN1GkM;L3?6E`vDCG2Kx=lUhfn4 RqywGH;OXk;vd$@?2>|s)P^ka_ literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVLKC16.png b/assets/icons/32/ATVLKC16.png new file mode 100644 index 0000000000000000000000000000000000000000..67a071428607bcfae77e17117fd7fb813ae9a015 GIT binary patch literal 152 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJcuyC{kcv6U2@ zo_u7WngbXa8PY*?RY^93rn(AVwbyUnVQA}_3f99!Ee9|_gPoA&Xlewg76Rztvb8Bz zaowY*QTR*@0}NQ`Wf8j1M@|UnLVXTP6N4`eOmh+YPl*9pdtNbO6G!(cJ<`AjSRq3Q zAgTEPPXkE}U1ZsswI=~g|NqZ06I2v~N;qNxNDtLQ093L3|Ig3~u4o8Z%)sygq!y%y z5tasmOk~KiSfb+`)-*sYU}6~R<-m&yBfPn2-I*tNa|;v000X8`2QZ9u2e6>0))5y1 fqhJ(_f>8hfgvU~l*XecP00000NkvXXu0mjfvB7@j literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVMM.png b/assets/icons/32/ATVMM.png new file mode 100644 index 0000000000000000000000000000000000000000..ac3d969dbd1e680c8fd5e672ec0efc48334e7fb9 GIT binary patch literal 793 zcmV+!1LpjRP)~AB}xbDpi&U6ATAE2)e@vl?F;QGLxN%$ z4XKpzrs>qV8hdkzJG~NlaHm~#^ltcbdby)^yW3rX1Jg6J(i7{I_a8r1rGCmy5o!Fh zodkieRg{;>iKatK8-}sR-cEtQ_bSTEGOIy*8wCO=xHbm)mrz|qysWRY!R;;}k4O-} zO9_&3DSTSIKU)=5jK!N}{CCJzDgyhraO;ve49#9A*2#`yH zxc!Qs`0&Ej^8<@W5Wq{HVvP;9i4L=Qp$8HKP@q5n1quZ4(io)Jgqmx`PsZ*KyWNGN zLV^GaB#1-N3t`b&_(s(2E)*pa1W;fumP6e`55*5!E@uCY&Ml#8Ie+H3=!myiSYcu^ znbSTKlS$dQp;B~Hv~#iGj`nNW&18sNza`13AEGM~1S@2l0;Z|=FqQ&wX!IrDaP%X+ z%OChpBuJjGEc4sEdLcmo1rh`~c|Pz;<`)*yx6F1hxK{Sr@?}{IhAbIMO#dE`CIU016}s@_Oaji>7C0Gplpv14p?TmGGjJVw$00000;%mPE XGZvob@++rf00000NkvXXu0mjfF(F<7 literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVNET16.png b/assets/icons/32/ATVNET16.png new file mode 100644 index 0000000000000000000000000000000000000000..6ecf3804d6ff089fedb08e54be46941ee06bac8d GIT binary patch literal 277 zcmV+w0qXvVP)|1&&cU}Q?n>Up&XpMj*B!-SB*qY2_v8L%3HfHZSh zkfgwx5~577>RYhv3|tKXK$1C33sWO7xdUH=m}W?@Nf-zPIpmy}Ag$!X!^|Vm8QP((qT$Q!!{f}m;^mA#>ZZqeUI`=| zQ8iraa;Ej+|NTFCdU%XPZhn~mkds+CI4SJ>YFm}I1NNtM*%>!T{(ts(Qrf}AqB)gL zQ#f6}=|_~YcGoj%)KJJ_s-{ YWdAc0ntyXoHqfICp00i_>zopr0Fw=6nE(I) literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVPRD16.png b/assets/icons/32/ATVPRD16.png new file mode 100644 index 0000000000000000000000000000000000000000..cd8af6f7e818fd273fd0cfabd5a929177ecdb09d GIT binary patch literal 209 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJ8J;eVAr*6y6C_xbWerZ%^+UxLJgEr*U69BAl_6MM+Tsn*8G*7GE5 z$rhd+rB8VtU*Kaba^`wgERm2Tp|e$yxtDR*`NV_+&I}A+R?3%3d8Z@;-N@kS>gTe~ HDWM4f=WRzQ literal 0 HcmV?d00001 diff --git a/assets/icons/32/ATVSPD16.png b/assets/icons/32/ATVSPD16.png new file mode 100644 index 0000000000000000000000000000000000000000..f05e41ac1e33e0bf4922ad94998fe479d74c75a7 GIT binary patch literal 251 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJL!K^#2MFxzQQiY|S#mZ4a}=#n(*Q+{UY-7`&OCm+K`oJZsW17hI#a z%q$^EqC~NQEk)?dzy1vZ6)k&t@->~a)dM)Pc15*$#WJvN_FJ2Y z(Z(Ghz3M50a*ty2b(gT4{(2QfEBXopS{S%@IfVL(`Re9m&ulxCo+Oc@Xpnzec9&H{ z=eljZRt(%gQ(p2VIEq&kCSE_m)fi~N<;KWRa6tC4BG;F*K<6=dy85}Sb4q9e0AKw^ A3;+NC literal 0 HcmV?d00001 diff --git a/assets/icons/32/BACK16.png b/assets/icons/32/BACK16.png new file mode 100644 index 0000000000000000000000000000000000000000..067b871dafc965c556df9b98ee7de711e6dcf468 GIT binary patch literal 787 zcmV+u1MK{XP)z z$xjqP7{%XLUBfmED1t$T0TGvROCZsNgW7P{1Bu?@tj3e^0(55JV4?{zG4a3w{s0di z`~&DA5@Jk@F(!n78Ke=H85U({x;|55@FL3$^pF_esjI8H-tT)|U8x5CcTuh;4w_aq zvFs&4PQ^M~4-_DDHQJ_tULqXQZG+spNjnnXYOM6qxYo3eyKM9`(41*y(hFnLwB)!F zcU(o?AQT(E0tA9*@bmK+-1U{*0@RvTc!G_7A~flCVObSQf?<#$(*V0k?z8HSl%fYj zC@}I0Q5rgryg*r2^T@rJhs>T!6H4_Fp#elFIub&l>J&&ASvzoHg80k0&tx_QjB$_*Be6r)X7o##J{lA3dn z`F_ugw*?4ZiQc5&RhR2k9jH2uqVkaE##;hZUyJhQb$&?&N~*)q-*+x0w(HQw!tmwP z{4aoda(!UF&y3aO#3v+1hq3nK`@sR&b|mEtS&yY~8vzWu8>^W6_!bM3@1ar~xd+(P zq#YS`VqGm@z6-|U%G?YRqpz?!{}or zII+$f#ApX2q1QxmbQmkiX?P)#>At^qfl20vGB3JX&oFgyNc*8_)V09rG4B;mxY zTOhQ8;jAytroWV>Z*hSCY#~`m?ByZH?s{Pe_aeXptlad;CprEaskNnp0nnPXBlAwo zYGz z%TE+p6vn@Es~WncyMb;RTKWMDqc(#Wh#ECMO7}AhlbJoNXC~v$jZkS|VWNqd#KeUQ z`~zILFs`j8K4MIaF(!n70V#YoNRL1ZRNXVFnqXL>O-~Z5R|rsNa{Xs_)IjRwV6OzO5TVW)D`dA#8`-JN=Bi!_w`h8+&B_P^r%O$y zdLgW7x;i1nAGV|+5Q2)&k5FPCKE4`*;jN!@nJl>bEj=B}`ls0^5Qp)Q@=mrsXMNCXf6vHg#Um&QezXrAG{iusXUEy@RrtC0ksS^|0&}m!pH4rjR z>R@9VYT`ejqqQD~GEr3dMA_mc8Hj0mu!_Y+V*cIf8ooftO&yIzal9*rcr>sj;gSrb zwZWgIgp)c+LLeCb5y7TbbhX!`XKw_G*nS^VH@mr8(;E~Pmn5UtNnKS_k8t`Y#G4{G zai9^AaP_u@zi1$FV(?e`FLeV61)=7>2sNg0FcU>*Tb;B0o}z9XBu@?U`gL_UhHx^2 zV&lLtvX(ijUsi?P1K_T`_6Z+eJV9al8KkvVc?0WA8`&{4H*f~be}b`C{O}t2 zv3vNm@D^SpzV^@@)vvO!I{>;ZtyL^cJ#{PMRAxsEILsPZ)6Dh%LX18z@+<$m$K2R` z6z9tSFgHV#I&o%n;D+s1gKtXPLSg1P<|iJ1^T6Sm0f*N{HgD$i-#|DEhPk>pkNntu zEWMio_;U*>3$c}#Ok?1dBJ3`JZ?Lr8lh545BUmd-J7d6M+Q=@LIlYgG&VVtswp4Jd zvG``PtZE2slUbwx?ut_l=D#7?atzFkKg8N{p``Z-9+J?8kCK!l>xUK>=CA%22rmuH z8W$ca!tP<_tW%9rwt`S0nl-(fSh-FNwO!bUoi<-7EqvGf3mSki>mZJ;=Kufz07*qo IM6N<$g4K?jHvj+t literal 0 HcmV?d00001 diff --git a/assets/icons/32/BASLNE16.png b/assets/icons/32/BASLNE16.png new file mode 100644 index 0000000000000000000000000000000000000000..78c73dcb4356f0b471561040b5bd26d65f655354 GIT binary patch literal 202 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJiJmTwAr*6yQxpV!v;}|m``fL4 z&a15X%+Qd>AVD!a*=Y(VSN*|F#wjxoA2B%4ka>lXXEC3|OTGk^kWIY51riz!FKMYQ z@Hq2I}7Mm8VidyG9BVjMK|R`Rm>N+rmAe9EA_QYt~QZMCb(lUpr5 zi}?~HN)IqFFAHQh;JLc*A(PSXrWXkZoEaG2IH|7I&5!Z~I*!59)z4*}Q$iB}MM*;m literal 0 HcmV?d00001 diff --git a/assets/icons/32/BLANK16.png b/assets/icons/32/BLANK16.png new file mode 100644 index 0000000000000000000000000000000000000000..6e3cb09bcf701bc53ecc7886c19b82d386469aa6 GIT binary patch literal 83 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=fdzDNh&2kcv5P4>B?Wc})uc*XMaS bfSB*u1QZw;C7n&)0XYnwu6{1-oD!MbLH-ShsTlKuCVxXX)fCQ5*2uRosy9?&QFOWiOwIeY^3lmMWF|mY1|AB>6N@XF5 z#b$%yBS2Vi3yMu3vDpF?5-?;x=9*bq^FDVU53Tf6@6F7+=giETbMFBEIw;6TdxjA? zE}iy=1b3--mM9+T(ZXalTls4O@+;B;!7>#h{1F1dUUogn>`CGU?-i31N;s^uPv0*@pDw4I}Ch z5IRpRX4KDlQ1Ti9Nk@$G*;$w8F>Hp5ko$qCKd{stf4Zj0*k#F?g(ZeUMdvT@(b z2NrBGdX={a-SbdMdu&f=1hQ}l^NXrv09Y#-7jO4N{$*@r0^ldM=E8yAvgj#bIJJ~+xY;6>AH*se!sogRJ;=G;}SlsREwMPbyrEXOc|np- zCi|ur*614DLZ&~zvOCkh>N~!g%ro6q`1>`^AfuHtJnVwr^JQ4r^002ovPDHLk FV1jzokfQ(q literal 0 HcmV?d00001 diff --git a/assets/icons/32/CBRANCH.png b/assets/icons/32/CBRANCH.png new file mode 100644 index 0000000000000000000000000000000000000000..78f1a4bc2b21cc3f73913c2ce25f32d1ede1f7dc GIT binary patch literal 241 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJ9iA?ZAr*6y6C_xbWepBV{7%pO zTmR>aa+qt)o;N)HaW&Jg%A0oxga6;o#w8IQ10dq){&fbhOlo5*t!cz(k7TE7xukB}P#iC?F7L=m3-^ z(9^|`iUJmTS(JC728FN0AU8NdfN8`#fQ4QbO)_Xf;ZHa+3myU=K#V6(pVP}N$aZ~T z`Tw6`Ca6KOX8mTmIRFMgb~AyRMgRXZbb^~n^s<b#5K7nf{J38fAVR_G zVYkI*or?(E?hdERbYnK{6%X;~x29Yr;02PRgQ30qxWQ+oc-|z@+_^q$2nAKslh&s3P%C=Ou4q8=RV z)Uq7SEQ}~+Vi;h+L<>V_&0Waw=FQuIalrIh^B8(3OkoI%PGq=!=PrF6aNy7phRM@r zf!R-=J!c4uPGUHI;uL)xaQn_(hQiWnhQELR!o}Fx*%+jyq-gJe_a8nmWaXDKeEaqd zF2>Bv%rL39gF#MChI$V8{P{D67|6#(rPU0N9z8}8ud6C!Ff%nKXeJXW@$2O7&v5qq zMHKO-wr+-FXz?5x?9UJp7DSY}OvEVKv}HR(R$d9ir_Y}mGO`O9?%jU?7GJ$?Bg2YS zYf;pKeBD@ENtES8IpEQwCkz!ejqt<;azsi-9>caByBO-5+ELU>OGz?J>gxc-Rjwd6lflKwo@C2OasVh^J6h@)jExLX#JxS;7&6n6$g-Ry2Y>(<7bm!Iv9-1Y zJIK$+lcA-dhJg~mLaGK45n+ZoGbS-m3oud5Bq}=K1FRWEEr4Ve*lfH}@c%!#sw%Pvd2j_XiK6`V7a(;$r}KH<;7!TA_?AODCqTXD=UMzNpEpRIxK>0P}0 zkl^pd;&03^F5|~;=4=e?=km~3*Fh<*#%ziWn%Z{y21=z8qIwMF^51HV5Q4~97@DTa zGhi6PCC0&Ktgmh$UnmOkaA?rfQC6(f_xX#L$n5@uJsv!xXP#CTS;` z!m=KNVHkMzI)+@nz~kFrlK8y6BjjFpIdSi9(3H3-1BF5nD{Gt8&BaVCMOTpg`VDIv zZ-rb{Z9`-<%CoLHQ5TK%E5r3K>;Mj;D|G$x4#vXwSU7HYUScjFRJI?I|;-owcT w<34T$(tgi0D4qG=O3M;PmT_|KCYpeVf1^dT*!d9FM*si-07*qoM6N<$f|E`f8vp;IZQ zrX8^g4I)g;%ro3%4;WmMJL4}oDTB@u z4_$M&(~Kntju;$(N%t5W+afga_=&frQqAg-w)rWJJWB);yjaR-XYd{z*!-Ar*6y6C_?XOq|e^shXt6 z^Z)yUA+Juz< zYxU#WN}XfE$vK=o&iiB(PN_d>lMz15!0fgu+Ac#^uIQ`r#Jisk zW_+Bme17YlY5dc~_#=PKlwgxE=(TD{TmrP}(6sZyUNBVwtL7)RFfr_y8pt*2yzNV% P7a2TV{an^LB{Ts53Ce7T literal 0 HcmV?d00001 diff --git a/assets/icons/32/CLEAF.png b/assets/icons/32/CLEAF.png new file mode 100644 index 0000000000000000000000000000000000000000..d20e8b768e734fc08e0e68f2762be98230200663 GIT binary patch literal 356 zcmV-q0h|7bP)b_5f(9YCrhm}ubuQXIiTZHrf}-2_jNAn^P5Zx|Egi09}zkBM3q z%gaiG=`UZtGJN{<8IHey|AC?|K0O~?U{O5;3bKYPzsnB1{kmqQZSkZ7LTTZRMOG_sUgP1Fu;I?kb==P5IbVa zfmjNCPOLdh7$S@eTNr2s7#S`oNC-TknfVMu5dZ+)$8|_q^JJ$00000B1e*dZu7Mg-~7rEYsr@!+4(A=1Ni>t+TK9y~;W zpdNN%5+X{dkfoqbv2;jMsBFISeZ#D?%g(erv!!AmSl;Zs@8`YGd++<>4fWp|VEh9- zd@x4U-YaY{jNsuz&!@jK!I9jd*nWi#hT8T5jNl=EbF!+z%h&I8+jX)%QGX^kxVd*g z{TG1kF2Jbt<|qXHr#m~U=Jc(<16>K@JPc>pyrh`>Kx_kK`ER)ZCf6gH$lfhJj}(vw z&Y)>g6OR+vhCZP1DUk(&rNI67hg)6#O_}UyvCuF9&XC!ol=lpvmge1iaN_I*v>iT% z?rV>AfBwmJeE#?zZ(ht|WqHY_ChwIqWM0nRE9O!Qa7Ii^t@@K6J$?q=7q4Q+&Ru0T z`^Q?#z@PLm?>`wlv~!^`gXK*lC+fg`^<3(nyl27bOnC zHKM*){sfO{Lei^bI7u?KM#8V3KXg`HA0r{8urT1REHCK{S1ZI;IKq`NQaK?TlmYnr z;=(-Uo<7p6i-Potjo1pu=c24^HMAH7p(YL&Dn@#8&r_vhL}>+R5v6kMC#NXLwpW(p fhF-6dTu9acrKb1qNsvPd00000NkvXXu0mjfW5qMD literal 0 HcmV?d00001 diff --git a/assets/icons/32/CLOSE16.png b/assets/icons/32/CLOSE16.png new file mode 100644 index 0000000000000000000000000000000000000000..664da53d6f6298256d68042cdd8da10b56c225b1 GIT binary patch literal 525 zcmV+o0`mQdP)joN><6@aOXQ?YnZ!_%NkG9KC>`$HlXG%=r*{Mtk;!EAVyUtVfw%yoez*ouhJlM% zXUC4NYJlQGAf>`J4GW}-r3#b{2!S}i)0=DP?T-24zJC_6e{^O(LsKxyGZTDsS-6=v5n21ET|@nFS$q5py%CZKBBz~u7 z{;mJ>MLEp1X3rZQ|G1iIXI@tRZA#;t5vKHMe#0&4{}K|iE8lX6l{5;}+lu^~Z(lF@ zO@80$4<9e{^QyJ|KR;2{m-j%6-hsns+nQK^SW4Q&T#?LRmGJCfTGg~>o_SA%bHlv` z)>wtLNld=FbFKz997<1;$Wi?8`l8S-tA@^X+j^}SxD%2j5)PQWVrUCw=P^i-DrGqA nQO>}<>p)X#x?31W4-4^>bP0l+XkKSPxia literal 0 HcmV?d00001 diff --git a/assets/icons/32/COLALL16.png b/assets/icons/32/COLALL16.png new file mode 100644 index 0000000000000000000000000000000000000000..4dcbf605763cec63ce2930dc96bf1422e4764e81 GIT binary patch literal 126 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=fdzS5Ftmkcv5PuNsO1C0qj)IwXD4 zBqq;1sI=?#k;H@tcPBoayI+xMfmJR4+WyC!Z%p^MwR;+A+cPkjNOk<$G{Nt X(vE}Q?nvJipn(jYu6{1-oD!M<$Kfb9 literal 0 HcmV?d00001 diff --git a/assets/icons/32/COLLAY16.png b/assets/icons/32/COLLAY16.png new file mode 100644 index 0000000000000000000000000000000000000000..7ad28f338a9ae4cae909a428d236e597f91920f9 GIT binary patch literal 291 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJSDr48Ar*6yQxpV!v;}|q_v~6T z&%EczisU4Tgac0Nj@ix4j5yl8E@fg0pYUM@=4FEK8K%vc!n7#Jlu3tivUyEi;?%jN ztWLt&dcubjPO`FEW=4q4u_|WtnLSg&;fJ?^q65c)GtSrfnT3~~k&;n7VDd=z08{dT zM_l3xD*hg}dVhU*npIhhCM$2$nqgON+4bkkC7VS&ZL8fc^D`g!n}b6OGfzZ9&&3#n zB#>b}&zjCmoW%_kxpBp54_BhzHX(&`2_>HseqCe)x!EnqlxO!nLk7OIl*j`P0$xC0 OGkCiCxvX(B*Ps3IStSybI)D)t0{tDeL}_U5 zoXqg<{RbHL1~VIrBPAih0%M2>3lXJ(i3t*D++17?U%!3RfQAIwj$mRS6Zm?&F$f6? zfS4MTLpSA<#ePBADi2$1eZ#7sFv$gWNwbJ|hDo*g=e}eEbSdDAQjf*}x_T1b=wj&7|dN?l0OM26=tKY$X32GkLb z$RWYPKqiopBCgzEW`+c^06!PQhmYSd9KnLFVe#yKyavh}=9A^%iad9Q$#eEIJbnHF z#Su&lbON9dXs+;Mkd_ocjt&X3(*UWUx@`jkGZPcTkDrio1LTPRzgeD>od$>nTI$ja zPoBMFc>C@vR(Td$r-9jhDPRZS${j2WbO6|L3@mrBP?`ov4UvcEC!+9~7zP-yP?`qN zeMBl?Vi+tT5KCtMr#uZXGHhWOK)^_<204Sg|I~4I{QEXx<15eL2RvzcAdJGKm!L9DuEL#r(z0Tn2>gTe~DWM4f9#3rV literal 0 HcmV?d00001 diff --git a/assets/icons/32/CURRENTFOLDER.png b/assets/icons/32/CURRENTFOLDER.png new file mode 100644 index 0000000000000000000000000000000000000000..d7f414218e1852dfb851ee0681d94e02527e023a GIT binary patch literal 421 zcmV;W0b2fvP)qUx+3aPc0F-&&a@V0jmREJh=yF zfByK6CJta^U{GNA&me=<0rziS1k(y~f(#~xvQ)SH+KrbC*KWQ9C4d819dPdk!~seQ z!r)Sn+Tg{j&oJgn7Hq-)_45Y?Ru*OkX-R&nTmJdWPlk8zzcDcUXZXYXk97kRuHcuG z6<}ayrb>N-YW@Rgnqp!&kly$F4HK^5mzNb}pappF_&tod652y8M9cOZ+(x P00000NkvXXu0mjf6&JRa literal 0 HcmV?d00001 diff --git a/assets/icons/32/CUT16.png b/assets/icons/32/CUT16.png new file mode 100644 index 0000000000000000000000000000000000000000..8917c2d154333e623ba5638e150d552fd40e3c91 GIT binary patch literal 980 zcmV;_11tQAP)NW{9&>rY=;inT4;v|3UMQe;8>Pp*##HU#)DllNcq##J>}jf5$8pYB}Fcjev9t8I_KQ) zo_o%@_W}PE3?wF|Vx!5ocGDXkO}Vkr^t-M4Rl6y8p6A5eVe%)KC2+$21*|`Q_2si@5kwmpa?>d-`Z`Gmf;+uVHPP4CSH8Pd z&H@|{wA7JO;l|ZHAz%=5)0Y7G*b3lRpsYjirICcVy1JMLVw<>R#@yyJp=4bfQ+^mVj=D!kwp1;edO!aM_lSi~os9msK1Jeb41qUgR?eEm1J?YevABU*jNrNYj-pDm?TlR`;CY@S#AG1JMz2%-EUXjs0V!Awf!oSs zq)xaw2IJ{*P@g0@B?6zoH7foo!op6MjeWA!cpQ{h0HzvtHF0KtFV3$uvvHbD4!Ow> zwCKyW)!J;g)5BV%OmKR~-DtQP@;>pjouYp{=1xpEBhF`bK9(Mbud|KCO}3NLV=~;z zKzX0$V6m9p=!TsN6Hq=(*y}rxqpM4~bg7U}h~RXcanx7xQP=Dcf>5S{0dgyg`5zkd zt4q0y(&+UflijjY&pLu{2R3|9R|4xfL(=b-oeED-<63>>4jxXOYB;&Ob>CdKwzLGy zbj=P;E}N?IZ<;d;jIc?;wugso^hW%V@SDF=I~68SEY7bHGHtT9&hX%NCr~)r?1Q6I zJBBBo>?qxDvsPr%oG+m=k0Ot+{ISc|PN#PG-{K#%hQFyw^s|}(0000qj z5e`9=G231>P0)-c?9|R+uU0oL0R>AAJHOj0Z(4KrPchH*N88Bz@8lppdk;E+Y~= z<>)}C67e?jiI;C6lYizbLTh9rA4i13ar?#)paqMnqKvx&oWlZTi}yg~krBXf7?80m zA`Us($cKDgTPQ@kh)9+>Z}Xfh&rvFRp@05l-!tb#ba&va3C>|#U2=ULB%={HsyC>1 zUdwic@@AIu{4zR;1d$VLE(AMna;yBATSVPN2tnk8bFPas_?M8VanVE7Wa9o8Aey~ZFR}Mx`}8F0}!#~W|07^xKlgJQK|-!>z-M`P1gst$Q7eC;r~D1R9Bc5i zS}XC%-5F=%xoJwng8DhNT&;#!{y)tlAC7ER=e4wsKjf;9q5Gdwf zPjt|YX2~Wmm-oAm%(1ZnDJ(A|z#=s+>Mi~wvrZ|g3B(uH7cRf^C08|WI&Md{FsY4kA&BzI+^l8S~h;bwU z!+#XI+XtDe zI-Mr(@U`I9NFRzNfvMTF{kz9xC53$EeX7jGxv%kPf%^EilhUUtEcI4CG17<2XWMb* zd>3vEJCE@M`qAcXKV?XMyVhqLgv`k>9Vo@To~#`!wo1}@5M%HK2Oz=5LuSNIX`OCD ziZNPwqXV6qO(R>V!YWHVe70P7obK|{E{sZkZ4|%*+ko=i@E=1X6-xq-U#{A1Ayvb% zl-8xf_aWPWDpV*8>TYktm#$yz#?5QJcKiO^M?8A5Qhyh2ADBY8b_RB=YDH8}UYF+B zc9Pc8M)?`ol|}zboWND9$Yx2DEMk>CFW;i#0XCux~5(=?yAYKGDzRT}NDp%*ddS+H+6fWPrd$Y&q!4X>x1rb8-vU8ApSf zNmXi3h>8R*V#|Ipr?6Ct`Gm&B)t!?&8j!loh^N&?E*mFs8U8NlZvSS5{_)AA1ErW# zSe*U{G>icuw<`H47>1x&m~E9m6_H{p!4!*8wm5x@|C@dR3z0*K>5lV000000NkvXX Hu0mjf;EQvM literal 0 HcmV?d00001 diff --git a/assets/icons/32/CXEDIT_GLYPH_WARNING.png b/assets/icons/32/CXEDIT_GLYPH_WARNING.png new file mode 100644 index 0000000000000000000000000000000000000000..f0a41459ddad03dc110fe48e8e9513709cff8207 GIT binary patch literal 675 zcmV;U0$lxxP)eDBIFs0}aLmo}jP>GAHp=XcJ%=lp^HNz1ct zPkBDj-^v-GmCf6dbd#AzzLhg%cVlr*4-(irfk-kKPTyGiw9(cIL|~yW;&l$k{E`TB z!R|R*fV;P}ArP*Pjr1TH4?sLM9M<5s~3Q81Xr z2pcZAlntB&jP;A>6H>QVwFFvSt3ncha}y5B+RknrD-T|xZm`k)M%YjR(f7hYe|OX1 zUn>kNk9PMUwYs&6pB5r8)?gvReoG({rp88oTf%-lc~Qgqn>rqE)bQ$k69Tu8L=cKY z%#`N*84G}$*HFw4SEsdnuCr+c7tS~^ol$XWP)0NHf#ib;G8Y@(pp^AZgK(dB4lng6 zGE5WCo_~PB=*rB}$9u#rA@EIm4Unb9jwbeYv*Yt{dt?3!{QxJ@pV^~j?HvFB002ov JPDHLkV1jyHGq(T$ literal 0 HcmV?d00001 diff --git a/assets/icons/32/DATRNG16.png b/assets/icons/32/DATRNG16.png new file mode 100644 index 0000000000000000000000000000000000000000..ecd9b2bb1cd3f8b2f018ac8255ed1dca4e7bf36d GIT binary patch literal 349 zcmV-j0iyniP)!0r0c|bQz>a{KJLu8?(};Hf3oZ#sQ9g#}uRnp~kWv6Li{udKtMtRG zkrc~8W|3SDaI!EkOs{ogpbq$fvtD3g7+}DHE`Te)!hC=(PpbGJ4uSs+PeASU*i_UO v3rzsXF7yy!WMW7}mY}8OV7o>E0|Wp7oo8bnP{1^R00000NkvXXu0mjfQof2F literal 0 HcmV?d00001 diff --git a/assets/icons/32/DELETE16.png b/assets/icons/32/DELETE16.png new file mode 100644 index 0000000000000000000000000000000000000000..2661f7a3bf70fb1e43e0727bf1871eba80f5a0f4 GIT binary patch literal 363 zcmV-x0hIoUP)%p=sk$M6Mg=i%- zR}ZnUR0-{^L#!i3!ZL4MTc-q23u)kDfp&>ttoVt6R3Lsk^zbABnM4{qS>O|el)>-k zLHe?dd~lrvY;c|r`ej=r@NSW@zB^!n*LxNTSm9O)jDY5J literal 0 HcmV?d00001 diff --git a/assets/icons/32/DELIV16.png b/assets/icons/32/DELIV16.png new file mode 100644 index 0000000000000000000000000000000000000000..9d8d376f26015f76d754c3c258ce5789c29aa77c GIT binary patch literal 1324 zcmV+{1=IS8P)OIGo%s_3eQ_T)c ze+QrtKneF5jYeohh=jvB@MLwp=ba@naKydsxPW|Wn9OE4cI?E;+*~S>hP?eRh7!8~O#;C1fu&xF8% z4aG0Ww$WsgPu|nz!QbQK7`roy%a?vf{^|lbPDJI4W}xmsxtoAbHkE9~hT`HlK-1*6 zsu~jWRD%klcs~T9iGDmOT;QwqMMWsuxJmX|vU3oeoRE9IwcH_}oZ&BSF2z7!Uwk2< z?TI6B#BJY8pd$<~*;1D1*Q3A(&UbeV_LsL~^OiCU4-85(ETM?H$Bw`iXIb9Ba^b#C zqB_4|jrvmQ)*0jLo?nk~-(3v#_oJ($U4CYYu1w^Z8XwER6=zvqEJ95Mcc{>?b`^?W z*$E*Yev|Ev?a0krh5j4YG4At05dxO%Yy|v%5QKl_U6=p_d9GL}T*Q+MpeR^YwF`!l zHEGv|LigpX7zp@#RWdmaHnjK`bOxH7PF0I&XA^Lirs1EH&4~OlH0N5*fI6I1ts)sd zZv#DB!p~h^r{>Y@c%?BBjYe^y`8*~9fm;m!@M!nw>^Vw0_|Xp>h0v&JYOQUB;mz$b z^z$*n@YeH<@Qsa)LJ_+k1y5^0UZXMX=NzjwZ`bZUux#5P_dT5nB7(QQO@~+1eA(HX ziXrBLi>T6MHfI&Sx~Ec}VqFYkAcI*`(HOGS3~9{#wi7**Be*p(6odv>%`tBx>CD@} z*Y7(mq0CUH$(*&ZV)q_o=U5+_lWgLm?;Z-R*|2cB6~MLC8JIHB>s2SZPR#{>qydKC z&zwGEPz^g?t8~F?v!z_Do9Mk4z))}sJDyoCP3R(^S3sN|H)MTW(bAI0|H)F48z*X= zCLLbpaL8g}E^!XvGqEDegitJowy|*pBS{=Wz9zJvQo(0LKvpyU=^r4lH+cf@Jzuk& zVpD1G^aZqj+X~VMri=_3iDjx9B!yfh?LBjz0Y(2|^TPr`m3o_>-jJDz;N&EFydHFQ z&d%v^-RS)j-Tpy{9M#9|cqDwmh?XACN^DpZp?w0vlB$&A%Z2lM!Lw@8*B9TZFII>fELplY8pH>GJ>k=Sty((w;;nv zQ9itSDK%SqDaF?+7a1L`E&TqUJk;QE>vIkd4~KvUmCk}9u#fXJQC~P5mZ6<3y_Dh_ zul3wHL?e+?6ISE93x%aLz#KGcG6aK$A0{;Tz=S&Wn%O>pr0000A9Way~aPN3K!>t1q4FCTAqQ3*4UYgJF=I(Ze4^NIU zJUG=$Uk7}6dK~NkRyKA9Ze9VfLtfrmM;{0L`1FY3?%@V7+u1LU!7VtMftiJs;nA7N z44+?Kpu9aWVahC=ikTVzFzE4aXW(S|&R}fg!62ui4Hma`4`n#8bs58@UF8fHKYKF# z`o~3^5K!Yf!obP&5o|HY0dR3$GX`yATLxCf?+hB;2N{?c|B~J>AOxls3pX$_GS&+S zi!%hq7lGp+8T|YAk73)2X$;RE-2s`pAglXLBGp1*TB(Q+$a0XSZb8WymV*sqVq$Ri zj|V48hW`u+(~CuOsN#T`MZy{k|Nk$CB{~6NF`Q~Sxq0D<@;}4>{^`ZS4iq_HO1&u0 zUna)&3=E7s$cYXg5S5SxCrSoJ2A2N}49jPg3CWO@3mA}H_x1m082jvz9bilnU}Ti| t{f}`q0|SF4PCH05k#xYw$iRV50RZLgcoUYPEu#Pc002ovPDHLkV1n;~)t&$V literal 0 HcmV?d00001 diff --git a/assets/icons/32/DIRCTY16.png b/assets/icons/32/DIRCTY16.png new file mode 100644 index 0000000000000000000000000000000000000000..aeb53868681cd4843548a162500cc07180ff9b94 GIT binary patch literal 530 zcmV+t0`2{YP)Skw(&r5>O=SdKMw{{enxP~Z6nYg^r6q!vBqm4 zZi)k=UXKTnsR?*I#vgu$&FvjjtA-J71MxTFvFJ2{!N9l3gxD`3No^<<7FZSkDG)PI zRRyZ5Ix4Ok5EW?vK(2IG##Uw*wc4Yz2GZ-xMNyH$-7+DVK_WTd-)c0E0EDb=a&j3! z{&3OWOPGGiga+-@$_CZChH9#pvW;csML9f4}NXR7VqIfu+ zTFKce!qv4D5A9W)O}H{}`=Id9ps|OjL!5yt1LrrsztaoIzc(Q963w%>i>_zj83Vbt U{uj$ZOaK4?07*qoM6N<$f?Q1#=eD2^p&K~R317>gGGocD`k2vshZ-zUan nTN?Uk5M1PIcaYpr_z!&oHXhX-m9fdj00000NkvXXu0mjfyQAF9 literal 0 HcmV?d00001 diff --git a/assets/icons/32/DLVCUR16.png b/assets/icons/32/DLVCUR16.png new file mode 100644 index 0000000000000000000000000000000000000000..9671b24fdf45dd4db98f91821cac55d252a3abbc GIT binary patch literal 1428 zcmV;F1#9|=P)V6n@^@TPzF&Q7bAFr3G2kXaY=hXvHw2QGU3%A4|4G6BCmqn@$n4Y)NCXCG#VS z%aZA@Z9f*5=#Lq*VPqR0;sjw)CkiNF2Qr{iDcaiGulp|NEiIIfYh&3-dVBNU^WNuq z&pCb0DZ>nz)oL-MjCkJ%8ahjAS{h6_xd;Y>=zP!tx64()0=f$THca;p zDIRc7g0~7Fa0u{%qV=$KccH(p59>EtU`R})5Eq|1P*ggj1gutztRyHG^s>G#)q66FM8``2EVSBJ`AV3Ok+rpGV#B`+NlO z^P$Sdov-{WXtfk(1pT~*f#sR|)Ro2+W@L?mhfc>(T(TK|*4JUkZb!%cdr|v2xIydv za%|wp6JQ)jt?q<>aVGR@mPY&xhD2=MvK4~^{TOyQ1gXb8J#aj+2f*>A7KWttFyKQ0 z<2+hiR2A;;YvI3bo8-SBVXXB#n|?wJ#->_4 z`SIFfNT@O{SeR@neOu&|fC!L)qmLlrwcVRAn9gvc;TpIa{ItBX>8n`4rzCLl;JQ4h zYV$nfg5-^xOCif+bvmAeUGXAGr$e${79{SPCH$L;Gl$PK9*7lu5`hpnubG{ino+uK zdldLY5-)sy)DI4!*f>{^pgLh3S5(gGn8a$I%84x{b=s{siU74$DWGcxkh%EvB}hz4 z5-LZ^Mk$zz#MQ_BD7W>-)zYQNO+a^o!0EoPw?|0pjcfHne1QaKWuu(_T;NBuw>yxFsc&>mW|SgdlFDt*Dh_A!PuEl|$k zWZ>salKQzI;1Ht}GZXlh?PZaWXPa|Sb@`HzSW-C>8j40k?H^EHcv`%6&z|s02^@?a zi6tK)g6v3_Dup7z7|-XNiJm?_-};0E(OgJaNMh6Gq@%X_Dn>?}?Od;xeb&-FZq#D? z=$dXWL_+c$O#(jGFrIc&xv_ns1~`YP*0KIQX5lsZzFt>@XCosvE~_Pz=Dg9c6L`LP zHg>!@e_8?&f(&UP0u0ybn+lIwXxQ9tSEQ$t#17f*1CZD@ts#@_eyHRfX?*5DgW~asoQI=90|hwW!&F`t3wYQr-+U6eU!9$Tvmd=7KDmpN zCP#p5G^`trA1Er7#1P2?G)f&heX|j-V68S6y82(hv@itd3#jmTRjgW?44Ykv_{kGD zR#Z0r27o?s+oi@QIJh$lZM|;nJ#!yEzdCdO3u3XV<{@$Ny1$2~1Sk7n2{_#W)ZQJ& zwR_HKeWV#f<8X#WX1x7S-H!)-?x?kh4~H|Z|ArG7oFjP+DcqP1+}7SRV-cXn0?v<7 iqj{OH@ZtOz?fDOnrhWXO@|TMM0000vPJh;{@EwH zYlfd+UNHRm`4L5adbv0_o6;-<+=7xBK7V{iD0k4#0l0DyEO(IXfP{)O43vNc9VSGn zV`3O!z(T1HCC;+ioXL<*^xGO+Oo z;??u(%X@}*cTR)#FfmXIK!Y7*xv>f#gO8agPNi@MGBOCzq#U^R_$xzyni@l-g9O9u z?N1mETz*gAT=4zpUxw{x-ZH33b1`(Ms4>jR*8+zMHo!u?G=K^=pL)#@WGx0}>nrgx z%*fSbID6+4L*KfG47Z+sqkTDW<-r$*yU!68{rdBd;rq{j47v(D3~a1SxIRZWA(5&9?sxA7F(HGFZ6#Im4}|Us1&1YW_2Ppkkx+|4dNv3Mt_b z;Kc>}dZ-oxpo)dz|Nl->Chn-a5<6ws8vyyMWy4@+7~3 z36qX+TIvWkPg;FP{{*XVPALO&<-$4Qp!ec+n)>pUZAi+9sq_!7SsavjaieSXHamnw z@T{sO4jc|g@_m)dMYD5rjX%Htc+q;ii%m$_Hpl`0c~idL*zf?&M*beb=1H?uND9~# z-cknS^W;?W{f)~#RI{Sm@cNzIy~)qnzjr4+ef~1tCTyC7ZG%+T)S7w(TUJ?1@#s{e zg`31%$PaR<^j*41XHU216%xVas-!);n(6+-M_rlA$ zHw(v25zHeb>l@Z4+iYfLHtXfB$4+{OZeNpjmox&B^5#i9X$~j-j7R_ZcvZDKy-`d# z{VMcv3UMyaVN;|v?`TSH3Zsw&+7D$t-OIRlOB&k;WYwCr6bVn!_qmCzm!}83gpH!i zrU)8@BwPEXn@Bd>2c&6tTQVR9_imZKQB>O$!O%E$oH|ciHgD4XJb&8(;>7j=$#sue z<`K;7jiTzNh{a-5QBgrw!9E~&E(A>ddPlpjvfe1NG#6=8`1ZB134cC#oaiy%D1z81 zv6&G4h=p@*lm#KFBgMEY6P`v#chLFGu9F|O6FUxjZ#^&PN^nY-|)LZ#ip2^j!-oE?Y~W-GWHE3dxMM& z_UK-&vr$Ayq(2h8RDmLI3TzOYG1@4DXV#edtmIPgD6}b*YY^ERL_Dil?}?N7Zj?d| z-W?%M{7c*vnb+sGIV=|tRUStHYbvw*1~F9j@T>N4cD^Z5%@vR@|xg>gC)8)W`D1IsrE04MAkBwyGl zJak%YQz+jc*eDjJ$=?*pHwZQgFHVbX3gsIFz)Y5F5W8%YgGV}L-vm&xK{#y`an2oD vKEAkfZjJcdeg!uL000000000004e7e?Hof+0Dv@M00000NkvXXu0mjfm=OS> literal 0 HcmV?d00001 diff --git a/assets/icons/32/DRTARW16.png b/assets/icons/32/DRTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..abc00379153dcbbcbbfdc86921e6d305750e80e0 GIT binary patch literal 465 zcmV;?0WSWDP)5n!wST&{7-IUJ2uNT}h0*r-=||4s@CLak2%KirIrY12+cMP> zVTtu2^Bai{<%7U`=_Q~+4z`_3e-hsiVKH7dtI*BbgJ12ZA|0#Q<+T~XZ4aQdRy5E= zhw}BnyC0+#I);t%?UUMufmaRr2MONN3D+*5P)|vMx5Mpvz|1WoF4juEtLrOtg<*-3 z?~h~3AsAM5*yIO6XT-jxv8>7Fy=uvYQT;`#{;LAWL1;AcW7^~&8b{+jvh r>e0ed?i`auN|~5w0fWI{z=(VSE%I-3tR(@!00000NkvXXu0mjf=T)+j literal 0 HcmV?d00001 diff --git a/assets/icons/32/EDITRC16.png b/assets/icons/32/EDITRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..b5e0ca385ba422e0bb29b959ffb0fa4d4fa45c89 GIT binary patch literal 932 zcmV;V16%xwP)jI7aB@o&SiB_=b=F1$5?3vM*i?q;BHv7~9XL?pOK zBI4iTVzSJ{n_YNmrfy7)f;LkBwmD!5h0=8}+d}O*=QT%yavUhdQ@n7`)pwpJ@B2L8 z-#G{PAFmT4^{X51?Ot0vnd5V1-e2#lVvP3W@yxaU2H)lhp3Q}Mq<*Cb5V{zHG{I@W z-XhDqFLNH?`!9+LEAm}eED$~aRjEDaTj0xc9-Z1;2dl_wfWx&eKLJ~&(>0A+bG8Ks zYh^Dn^~#E}MOLriK>BvdXigMPTj#II$qF0~EVU9-e{ebN)>ZE=fn|jR+XoIX%eb8e zLWttuE(@L?%SnJ#BH5fT3f>PlmVmMGMHUz3gH=fQo6_jf5~n|D>fQgCH`}~*mwO8% zZRduyOCj0wpYTM4U#|8bsw4(D<<(5^+)VQ$yPd@#?P!Uo0Lwj2gVuF(0E0sb5aZR` zzlp?54-g1IR8)R^p50QY&wetZLkWbg_k)0aJDQ_sCTpTu0pz5sj&p4KXk!UP@#(xC zW>oxqp<6%o9Z`F%;n_NFhWVjg1?3?6%C~X}3Y<2BcJXpA63MZICbF%;AQaOB90<51 zmDs7pMe{{(nQYL0zZ*k$ZyXx<=l;f_Kc=b|Up4?wQJd8wdMeg0dvfJ;Ja~}C<<5Ix zpp*XQ*mu*`<0a5q=dJ>w>b-Ry*lc-*D|fd2E*>gsk2Rxw_S^|zmT0S&Jq&7FS*aUu z6*~-CXQ&VHcuHZMZ>?z=88$sYAOMk6_0&R#O)B@jY0&y2{~~;AKpzHoG(|7Hs2872 z06AIswIJ~F%J-K;5T5RPI<27nQnx-lHz>s#XVQyjYksiKy$OWcHNIjv7QA85^!q+K zni&?kRz1~~GbKRiFZ-u*QGxh&soTKcyc0!VWJG_})@*Bv-=AqeG1~xVZ#ai<4G3_` z8LWF}{N%^~Nue`zA4E93vpM=>HvKqefx) z7BJ3a{i~wmA?}+qR5eR z{uv&+X#>m{3}Zw%CUCUezTOemsbCl84waRarvF8~Qal0#$~^$-`i%bo0000s28#4SK`69}C|Q3{87e*q z{seJJQu|P`kUaFE1%2=#fBJy&z0{syKFWydy}|P56sM+ z?=pAJ{qA?p+yVY$u(dvD7|^0w-K2KFG;3e@^!BZ_jKkMTAUdnRnQPDcwX^?f21XP0 zamQglfk7)6>D}WWrr%$80!bqh;#u)CfNe`U1S~M#cl@L2iFI89HY+}$mxpWW(AwT1 zV|BGvG!;$28UOtCx=rgwU^t=oGlmnKbMzc|4n%?w+pMEyQ!S-aw;X<+3bgD5PQBKo z!x5*c{ZRY~G_}M~Q5leZ3kw#yceSB9yn$}x4YPW(>;!CXo(5x$_0eW@_B<_PRl#a` zotw9yX&k-XTj1AxU<}8SgOTUUMqoIhzX;%BxC7#;|wK76bx*2(bR)g#ON|35+J{QeW(LDyXEGLuTeLOnm?Q-AoBgELi3M z#bpMV5c28FjjQ;2EQxDZCRa>AB}2j=Q#1Hx;y3wnA#mzODBbt!;wDz3)AeBHP$U~U z%Hh17x-uC{jU{nUOAI^r>{lv5CBt8SP053{Yy#rt6CYrXEZq3In%fSy9FU#2jxCQV5xBVh>8+0{9rc+b6@a2&F`W@J}EnjTkem9Bq zj4ZfIK1Uon_DSZ_s&~c43W)r9dj{hp?;#Yd#Iw(IEGxDOH;uK8Fmc=$5O22gSB&@Ri7Z@HyQiZDVD7LZ?C`Duup2b%7pHnO$BF@mg h&k@_bitT@kzX5lBh1F1VtUv$&002ovPDHLkV1ic^;hO*e literal 0 HcmV?d00001 diff --git a/assets/icons/32/ERRORDG.png b/assets/icons/32/ERRORDG.png new file mode 100644 index 0000000000000000000000000000000000000000..13f9deb596c3f06b1cfea60e948621fb82e8607a GIT binary patch literal 2929 zcmV-%3y$=OP) zPiP$19ml_Kc2=vkR&H@h<0w{Lc5 z=l`zu3%a}=?d*I%ym`Mj?>D~(wAEHyZ8ePqnoy(1p<{B-Ak1{PPSm^kGed}Zq>3vT zelk6F8wQ$8i3T#-*VnCQ(?=`|hX9NS!a)cO1E_#dL-Qa^lE4E16PkwmM!tA&Y;JA^ z302~NT;9L;m_^!20qX=H4g=5wK7|3$I6=Fm3G3#ihckDOASD9GmHqvPP0~&a(3^l5 zjP~p_O%Q)g3G0K44`;`*Re_8S4Rxl>!fB8=0|D*{@ry7HK{w1)#|L9mQ)^oS2!qfJ zOXtm0*T9w zfaub7^kmZ5+0lXRY2E%~7;eN+o)-=KZ>dngv-Ki!MgxHtVHScenXk1lo)v-veVU0a7qv~X(d@#FhV z1LXa|y*~iqHxQ!J>6pQ7S-iG$yFErENjby7XG_m9y_$DEh-eK0=iZy1`9q?C@W8Eo zzVEsa_`cII+!IE6c3@XW2a>GCLID%cmhGP7BqIFLdiC+yAP0OA-Ja zM15_?OE|E-D;cv<7vekDf1l^@+47fmDD806Kh1UHyFraBfp{}IG_*5i7XJ?5nCkN# z9cjG2dl$OX$+|tc)k@L8Cku;McJ3{A%vAc@V^dR0h#N>5#$Bhud#HOGMt1Fh7E$CB zmMkJnEG}beW!34B2WBdL)Grj_|2CEWhpK0=|0BD0Vz_%7T1k^DtC(0^a*D+6nCr!F z`MG^*zGmL`m{ARb$BVD`_Ou)f7GD!z8(*VB$Ji5ly(VfP98IYPaQ>l3`*zzi?N(KP zw$r{wH5Bni$(sm)@H|5m+HSzuok?~`8-(~8ouIHc_FOEAG33g=eTOVTcjZYRj~U#R zTe)Yb#LvY3HUF%7Od(p+NF2S`;EY~tbP%`rafo6D&I9;XgTdl!=4-E#5S{E5dxo%p z@Pk5Cc*~(}D-Pgp#n;XrD0HywS@5^4(j#=@`9{^G@A#hHrk`g7F;BVuWL`OWv~OK5 zAKkm^Asoh))-x)_0~*i3{leJs%@gSQTHU3R(3BY(M$dQN^z|L=0ehhus7p|C3; z_DY{(afzQz`F$M1F!qoA9K+Xs9SanOap1StG4Rt1=>6U)U*E-EuqV|Lhe{sSmvEPi zQ2c_&FZrqM@%}zvQ~eDXqP!|-<@1<)=f}u>8p=|GBMiM~_lvffUtPoeUw9eEn>g6I zJv*m*N<3?((qE~!MqjswXqItShQZ=T=t07;&y~$a)>Bk4SbKl+j<22~%HAl{U-lB7 zfpG5-MCax9!LF>Y^$Zn^D4}E=U<3t)yjEJD}_K}IM-H{s^c{~#8_AW73!zjgaO4X3>KLtigQmrotM30&)j%h7f31b zxl#^~2V99mSq^DAw2cx<#wU!2qwiw*qg(JQm1in%YXad{0^}@o&L|w%rn)C47fL2( z7%cXTy{nWMEP3n_h($Olw{co$5E+G0LCGWl28%so@7#Fo2t+`fklTWMv>rB;OhRDP z@=oQk63FOR?dSJZQ2-}E2dS{2WD*9WhIfa{Ue^YqucVL2uaR{%@CrbjP%;UG!D8>& zLrHqs>)JrdFIZNnC&aYRprB+D3Zs^XDz8;z$cWq!c4m4IP!1#*Mhy=~>H-mpC0c%K zDQx+Lq9+)JlZPs=RXt?b&6gz&N|IsJ@Nl>$kn%EP)l2zd4Crw}p@?DB@UT~2+O6y% zT&_a?B9BjYlM01mfKk&+$@5AeX1Xdaj_Q5CD402POOr9A7&RgX4=3sZ;Zmw{+cOUdZf+ISN?$Ifyf3#> zd8qQb3W(8NLla?XnP6zSVI!l1G@3eA?igfAc^qI5|WL2!{_1Oz3HRGpjz#V-sNd!mj+ z>5`khNJImBe|#cW1maRe-`LaVt0EA;x4!?q_p$u(hq2{N@jQb=TaKpuz~F+*A3vE> zRKceE<|{L=yD3TDE@0M-1^O)M@eVX$Y7Yy{I#q8x8#!X>p; zj|aHo^H$a5%Bs_2r3Yot5DE}3p{-dsW$&LMiOX*X`G~$*#MjK%UL`IQ%NxHmSa!VO zR8qSRt-!hJ^8@1xi&${6bx^BlVZC5qvvO5J;9R3Mdp+m&^3F26nTg!a(Z$`lg)ISP zVZC5qt7=~n_Qvb(JD!uRd1o2k%)|*wE8o6m^J|VU*pres-qhZ%B4OKAv^R8Vr43y+ z)ZX$4$=UK~L+wq$=9051*oNBM=J{89W64(DSaP%4Td#UkdvoI47TKJ5v)bEtyH|UI z`>nXa{bq47dd)D-3efpRz{p}K97@aOD)`l74pDu*K0%lzh^v;aUw5hKp~t1f0g=OIJ)1sKuHHE!2nQkTvUpWx zq#QI4!XycM*?EHB=`-@hdtrvHEe*s;c3C{G#Ac?u<$6rCVw%Te7 bTT}lBE9_~p+w3?400000NkvXXu0mjfh=h{o literal 0 HcmV?d00001 diff --git a/assets/icons/32/ESTMAT16.png b/assets/icons/32/ESTMAT16.png new file mode 100644 index 0000000000000000000000000000000000000000..65443881500292c4d2be0347614f36a00350043f GIT binary patch literal 495 zcmVbt-03HI=2A@BFW>~#$BSTSHHC}Zr)U@>P-@gp|4<2FIv}HTPfkTHG ze*XLg7Eeo#XV6erqn!gTUb+IdbnA{?4Da86fQwsMm@)YIcrwVz%Hq_^LawDxpFIa# zx_;vphKG+H!^Krql);vQu!Oi6L33D0wfOqYTMQE?PX`Az42XybGkANrF$4zqFlgck zYKk3j{pKx(Dbr>%?Adn!%x7n3V{mtM2Ky8g)Cws^4AVOn;?)0m{zdW}a2?HJkZ(bW zDl{m7fs2cifl|Ois>KnZ!C>Fx0&)&2DEvnU?vU<)<0norB&24OWHGsb1)HFmsWF4G zkpY9ds}s#E#_IrPW@d(E3uiOX12ECWmci@*7F-gt_RV-TK0a7G%tHVMBn;dbkim-! zyBMemn5b&nr~}9VObjF40W5?RkeccV)qaC61Q=nAnB;=Tbm^FYz<-7(OXg0HMF{~= lcL^jx56i)JjRFP;005vMiWPDn{c!*Q002ovPDHLkV1lR1&l~^% literal 0 HcmV?d00001 diff --git a/assets/icons/32/EXECUTABLE.png b/assets/icons/32/EXECUTABLE.png new file mode 100644 index 0000000000000000000000000000000000000000..78b4f0896bb292fc7adaaa1893df648a15369ca1 GIT binary patch literal 172 zcmeAS@N?(olHy`uVBq!ia0vp^3P3E!!3HFKxnwkfRI#UvV@SoE+2F&Io7`+g4Lwti zT;O3`CitE~EbHjg51ftaDbJW<8Ui|u40#L^q(1T`Buc#82{xhd$aiixMux0CIwqGB+MC<-s42^uibDJFo4iM&jBm@y{2ATJP2 zbR-fdi4d~~@j*t2nCXLm_>-V6Dl#a4=7tl-{&vW^V}7SxXybFYt$fqgi4syP_TlA{}=GK1tj=~ls$ zjYCMCq;BzbbwviTY<;sftDjfuy~6x8kTAPs#*X;n8nG^w`fou)yjk7q2)y9OeS0}7i}cCNBeU)~MU$)10%M$mlhTb%y=1Ufs~%xjaTlwsDr^HI6zQH&cOaCQ7> zv4K$9TEi#t)&6=6MEVk5zjU$HJbpgXgvVD^qdYX%mGQ1>AUodQ^`F-^y}tg&^Y4E= zW*+e#esGa_SayH17v0@G31!w*uf@a?@6P(V)%nxE;b6lq3=IvTysQ-W-!~O^O^HoR z|JBipUw*xa*0wGj`0PVGwR$~f%$nz__)KvOLMiohUB=-r>dlvP;rwzef9xKV1t-Gi zD=-gvF0aXZQbx*3j9cREU>D2n^ENrY)@>v|9Nv$s0};#)-GK)x%M#xE_|v0i`|=Bm z&3j#41850fGBHm)`-&^#?O+C>qFRg_a&&XrRspi-jTF%~q!rM}omoifJWJ|}5SSRBbJn|&$Ukic)uPELK@7)(!EQ z;yegZ5*&k2QbolR&9=Y)TG}yIS&4Nz-Y#~rhT%L&qDfPNrmOPzvX(boCg_(^B{@lR4&GmZ@x6M(+lQLOF0)28MtQ3 zTCu|EcsrOuD5;Xt$>vh>Xmkiik6%bxUdl*WiIG^Rj02XjLb-lDhqvucfk`MQ+ zO+Br4V-3FvvJ#V5*9eL9^~BXR*BM0XM%lUtP) zVMHklA0Bi;clgcRV4LsG?uZU{^m%>~2V0W5?R zjOKy~qq$%J9Pk0wouU>%G7D@rGGIg(h)yo(pmygJ2LAtN=v+E?0{*@ss0$5J2<}o- k%VGwG4En{+yDRo literal 0 HcmV?d00001 diff --git a/assets/icons/32/EXPORT16.png b/assets/icons/32/EXPORT16.png new file mode 100644 index 0000000000000000000000000000000000000000..87ed1a3552eafb3386418b8756fe2828da18802b GIT binary patch literal 462 zcmV;<0WtoGP)*g%DD{AFf!B-Ig2lv>Wg z%*?>c$^sJBVE+4if4#iC1Wg@Kk7l`zm@tElmm?1?aAvFODHo>|l&j{8LO)^sd$<>Ptm>32aFb&EmIC1fo z4AZ|qAxsPm!3>P>>J|lT^Krpy;F$~8(4*$U|NsBjGX49%!q`~n4o(N0K(_S%9~<&p z3K+nEk&)5hKQm+VnG4r29K!-rHD&U&#~`{OCyi=0V{^>Jsk03j7#Nz*pTDkXXsG#M zz|#QJh<5-By1=P37br52RQ*g0gDnKiOhAd0FxUpA(JLWB`j4GBHONDNSm3o~4+Av- z6T@H&feBM)(bWM=41*;EinG%d>1pwY4=|O40Ch^CD$VZH0000007*qoM6N<$ Ef@2WOrT_o{ literal 0 HcmV?d00001 diff --git a/assets/icons/32/FACTOR16.png b/assets/icons/32/FACTOR16.png new file mode 100644 index 0000000000000000000000000000000000000000..bb38789d6d964369888fa514a72cc432edb56bd1 GIT binary patch literal 494 zcmVY5Qg8`93g^&g@r=!15Br!h1y;dJAZ_SoeCC;h1h8$=pPU?tz`-;v9Pc)DjL5~ zBPeoUnt(;rpyWn28t@{TO|nKId8?h<*?FJaWp;sD7wIn8Zq0{Xmm?qqe@tXJLXa(V z11OnG5rQ(;&<&6`pPd`?d|unQ_Qc7f&0Ma)A4}9cfbm;}3(x%D?trLy0Mc13WDfLY znuZQp1k@HV9IZP*S)TMi9s=%5TFG3Ht!)Rodk2H$W^V|TZZKZE;_>){$~vJ7Krl}e zk!8wb|3>giR0a!iU3v$&ip%tdirnjV}{!zPo5yk z`g;$6stD-(95Z7-aTbeK55VW^`W&}42b@H??kEG`GQNB3i7PPA130q3Kl;3wWUf{T kdA%wY&Rxa20qUyj4Mm}fyn_51lmGw#07*qoM6N<$f+SSg8~^|S literal 0 HcmV?d00001 diff --git a/assets/icons/32/FACTVL16.png b/assets/icons/32/FACTVL16.png new file mode 100644 index 0000000000000000000000000000000000000000..138d20521bbd1ce63af32c52bf47936d98836913 GIT binary patch literal 286 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJr=Bj3Ar*6y6C_?X2p;S3)h+n> zzdzBAS-F|VH}}u^4=ocr6$?MU;jDIuQQKi*tHaLd#wNKTHsC;$4&x%R^Y50g{JU{w zYr$>@2012X)`$X6pZU9GeA3n27j>MzWj;CO;N#}46;EeMuw`=yFol{%YW%5;ez)L5 ze9Vob4m=4-5(x)P9?2eXTIcq~LVlAXjFa^F=Lhb_<1DAXDT*`sDBok$S(4STRoH{| z#oMlh(o8cgYMk_dn%5{!@JyZ0*C_Dg{0EjRaqQb~XYx9fEo^5{7Is$J#G}Q{E&aB+b9l7jJ`i;*o9;t*EZ816+`6SA3VVqhUBb!gbwfZ*Ol-W*= zabgn9cPy5O81S|%UCige=EI|Wmr=*ySca!XKm+GFDP2x>4uhc63N>rzO%!BW(spF6 zcDe+6I7h&4l_R1;2J`u6O`6c!=*I9YIKpGW@0tr!S{5gWFfcrLZ5E;1Hzfq3`Ot$36~OgwPF2*wx>a?q1E4@MIcIrKmR2aOspDpwN|-GetGEr~>-H8x!g zi5fMO-#}1;VhAQxftEtC$ge11x}~LTyJNm8iGq~=P&mMI*qxd0o9}&Rb|zV1yTj;F za;Z%G>H9WO*lD+ziVQ2p^ES)C@`??=d#nJ^yTMq_(Iba(;&@?3L;iC^ z+O6%cG5u`@8;Po_@C$2eG7SU6QsZw!?7^5aHe01wi!9&d#Bs zxsA3BsSu6o=y$mh4u^eGmceMV$%_dYcv@8zkg|52gTT0NbPR90x|0?cLcrx7L~tP# zkT^eMt16%VUmjnp08P-DAQOR)pZf8+&y|$8XUGe`>W=`-Xsf>GUMrW!EA+%-b~2_H z10vGV`4*#J#}YC?d9!nKU|`o2YejRsT)tj0yQR_r#%|I%a5S~W?s7aPCZ{ktHBGy4 z-)=EISg$@u0w^`6av_A3PV|fVCIo|_RXG%!`TiredI2=&=Vq5BQkx?|@^iDV0;0|D zSJBwgzAE0)`3~NZFC^Z#l(l4(WjV5;24q=|NE(dP9-o+86{j&ed_QJ0Q=+6g|Bo5dfntd5Hu$B=bSpyttpgc0aRIH{#=%NS$PB1w0_Ggc$ cQxn^cUw6zqz9+%5Qvd(}07*qoM6N<$f>NhZF#rGn literal 0 HcmV?d00001 diff --git a/assets/icons/32/FIND16.png b/assets/icons/32/FIND16.png new file mode 100644 index 0000000000000000000000000000000000000000..89324c8e8215af491c626fc80cd75e5f12afffc6 GIT binary patch literal 471 zcmV;|0Vw{7P);+-u6{1-oD!M<2?{^z literal 0 HcmV?d00001 diff --git a/assets/icons/32/FLOPPY.png b/assets/icons/32/FLOPPY.png new file mode 100644 index 0000000000000000000000000000000000000000..26f722b0fd88002775d8478c43c5c012ae292d23 GIT binary patch literal 291 zcmV+;0o?wHP)y zT}V@57{~wb*>?O$-I7uBD>AcIDrz;&W`#wXNmSHDqHEN&qOZA>ZVc8%-3i$T72%DD zAz|&p!U!pdc2R-_ec(k_pl(hwm1^qd&WSUfIp;n*^nt&dm*;uUbN>JLJnk+qfRw`f^1AzSLRJVW@7Vv3;c$+BK=vIQTZ2;u4 zizUw7*WnS~O_2GLWfi)O1T435S$w<x&R;wG*+a|(o928d9xJ`2jc9FGFNO^_M!3T+)gs=3t`Y*8X3eT~;5 zK24A*@hX-ZMIsS)6>UfI@@0Mt`7%Mx4rq}G5^+pGg^`gFIIwRwrca36VViuaK2akJ z$-o3{iw4WK{;*nc=dJ-J^FU}O?33*w_kdon7xwgzUI%bYC=j5ia2rxnlKtMmZnwkG z){cIY1q99~85k`32!+EQ$FNMJy+8=jbIrJQa~?7?()^0|SR63Zxk#8WB8(Xh&IIN` zRZ(@E1$&J{D9l{sR`GsvmkagoSe5e;5G$1b?@?XXRnT`?zKUGf?-iOm`Je~X3Yfe!g;5}ZGnJZ}#uv@hIZ zxwR#51GC?jOP5GdeYz47vl_D*N-`i(8V+xGGay8e)Lp7|j$j2!OH*u002ovPDHLk FV1i&VfcgLc literal 0 HcmV?d00001 diff --git a/assets/icons/32/GANTT16.png b/assets/icons/32/GANTT16.png new file mode 100644 index 0000000000000000000000000000000000000000..0d1801cc6a980e766b20fd36a16e749ed527a91f GIT binary patch literal 278 zcmV+x0qOpUP)OXbn0+=>4F(6BR!jxHXyFdUQ0s{q@M!W-9&;^Y3HSuboRDRHf0Mm$f01GY& z>xIE28FVy$?a&MXrV;M|7HY@o@CgB2z%>6P12N$AMDw8$0!$;`0W73yAU1A?ZwL?q zm#s~)it8RdJvc*vX~a8#1Xc*n}odDfH$;e9bMm2mgWy=hREVP)z8t zQ0PU+v?Mg8xb!2m&`a7h)Qw`dD5{J6p^wOxc6X+{v(kEP$sdvu(g#*MyYue*JeqlD z_F3QsgB>(5si%4j%X5)&T!zFb16~3{Om#}+C9nvFds5(z*JIsXnxENxCIXUrDq;#g z&A_G{!u_BG$vKUS*`@iJ^^OH3#%@e7hMNuIcszzvr%z(w&|&=WdkI|gsW@TQU{))r zl~+++Uxu+!+7cphE&JW|bXx*+J*E9A`K_bRl5movmGbeY7&~`qQk$jfO{XIRnGWk9di9;}D757VD z;NjD+VM)Ud4DMe*foKBW-hQlRet|Hm6B)^u0es+&;qHrseq%y{O=(`uAupQ$;CB8) z{8qlbMcxLqKnR1wZ-Q|TC^vDm6p++Y5hiex+Ly-19P+PLKEk?@ZJT(fi2lSW)g}(& zY7$@yK26nrBAHNgPQ(7~+9%ks3V0Tv>F|Z3G;cA*g-|NGK%mls9>9wu-d!OHj$^Yil i4BLe~mygpIj{g8Q9Y(?w0>jn-0000evx!G*Ss+G&IWN{5jiVC49D%v}o_^#;)zTS5Ls;crehPf6knP~iMH)hO8xC3bY z<1*I1wGp>&-R9%;icJtF7R1b*pc*IZ@Dp`$uYKEac#aUAdQj{LN1n>L zSMkAZ?!%|MK7=TWT<7aN7@uAuAbn~+EG6?HrKK}fwTX&HthV~JI0D`5v=eZTEbYmh zGweM5IqFaC!f$9pZOt=Wrw(3&=IxElG0fQuG3N}3X#i4M2C|E)A|zBQd>lsr8m$hC zOBdH9b^eX>7>-|aKomsG%PGau+OfInfNLyzxd&qI&oGpJ!O0l%S}sDb;l^+em#_47;getYaQT(;I#fl8K}Z@@bzcc9NZfX()g5Ksf$@#^x>sb@FiUXY%b1wk@0 zago*5FgJ<-=?F{h?N0t}o%j%pq5-b{Ke7DaoA`Uk4U3$G`i1KulF;F6?}#jeXy&yj zC5XubdD3()tD0IjMnDiEg@WC4hS`=vytm*DE_;JMzVBNXu1B_<6{7D!4lV z;~u`9*UcCC)@)+lDzrR&qD8Mka0#x;nD+8iI zF9QTQaizHU(aN2K;$0@QBE#MRO!-Ur$1trTa@vV#Li*$DAtX5c-qs%xaE?Yr zlm^B1A~eOopXsm&0*{>f zvbin2M`&g~k`my?3E9HF*?X?|B2Rc6*tVF<*YJ$Qa8M`)5A-6?Rte2xQI9n9#;>izcKZzzq{^1M6fI z-w66T&!)_TG`Sq|tQB#38W_Sz%WkONel~RIHt*h+hcU%gpTRmA)=aSXJR_$7<|$U* z@g#!3>nQxLLveadva}9Pd}2X#OGYqGur?~x$&j^d%$`*Csu?r0A<3DM@)~YReI5Hi zJfZi5fdUSLMwYd;opndsCAdehPDXDg7Nwp^VH$3M80cn$W=TtbzOBt3w|@lpiCkO# zTtO4+*pr&hn9)>G*c2?tDGF|F5(dRffC@Bw5e$Zi0K20ZES=JV+Q O0000JP)*FfuVDE}lJM4~WY|t^>%j90V8{WWai%fQ4KKz$`Dw zNh3+ygekM&dO?8f5TF)dp_W0Xme}EyH;XxhRh)@oxP$-kYgaBIL8?RPX6%>+Qzn^5{8F~@&EoQ#iAh$^b7$eCME`J*I)*2 zUIB(v2R5@XG5lXWtwf|StLM!GVhqBS&j|r0bO8ekX9g$V7_fsF7#RAem537M0CE8n zHbE6_69&()3*$lsb z{RDB>aB_3UW;H(iK^F(yy?&ly|K`OE|Ni|0l?fAHa=$KVY<%;F7M5c;;L@r63@7$& z1hfA${4dS!dDBDd_5cfvaeVK3hRdf9f@}u)Ha5HW?Ft4u02UYnY&paKFN_QfzL~vm z574bWzyJgP|G!{hU~$dteR+j}j(~-c;s2I@42%k_%>O;px?Vn^r{!P=WcIwJN&Y6< z0Sr_IWVZ)~d2SXz~O-)8&5m-1FmJ?jPW;i(*sph%m7Q zg14f{0>{LdU`xWK2ws`3WWwX~(-qC%(7&W17#2&p+_As&ItJ8Ffcj`2?Aiqb?Vg13b3g;qJUUsX1p1m zgu_*bs%m>0LIM$CCb{TbE(<_Xb45sy+;{X0jG?an`TyDz)q}o~DM&B~tmv9Lexm@o zrnUgacMz07&mesM?C+M8=cx~&!Pvh^h4`v#YTu0jeEd*b&%)dT$mW05g_dAA=h$a2 zS`qAhD-XBAFjJov9c|YF_`Kk83d7g~k-MSsB|5_I3eAV+KnP9k-SUdDnI?YdOR6v5 zcqL!a;PaDA`|#j54%Ze60%VEE&4x$;Xw5am^8dhJl6Qb&Kz)O7sh%jIpz&IF29lG;<*TBq1Q5<;ITTxlcc^??-R)hzE9D)!- zTb31i@_hAQ!43@eR|gmqFBGxIt;1jMMy<~Um#Yj8yG@QWHcUjLn^;(kV*1YtmRI5# zM}%OHd!GIsIg|szAh>Vc8)6LI^n9-N4BD<-fY;}P=DY~4tOm?h0hBmWFC+{Ia}~+W zFcND&u(Y&}iSKimUsy{yA~3XA9_bqxfOVh)!60}|%=;2Rz{X2(y{!&S&3=?rUWKOD z?;A8>MPbgr&OA>}MeucE7N(V;$C0oz@+j8{o@<0=4u*ikVME8AMtIM+fLFBxi~}Np zWPAomV-8|#8Nymm&4QPMm3jb?+-9rsk{4AT9b+FRVHjq>x9$xCk)AyxFxX!m(3p5d zGr!-_jOzL}l(^eu9}y>3zCk1m92Qg)Z^wSgNF)V&m|YW0-3<3uRK{(#Nh-KoH~eUB zy#`)&Tb7cwG>&9!N{(ylySXpf@6hL6+bJENzD&!))J?OoE4?~2H6YG;ACXhRQO>!i zUAAYF9|e>SvP~SswJid}!3KLg7MrEc2lrY~)6@w~Z;)ZPA|H31dG1UP>L)BM$MNRf z&r}qg&N|wxWCUo3BXU~ja;Z_Zi-gR1F+l}M9KGm&<dq(k*-#wBN&hkhYOi0oErV4#RQ_!yfnm-pg0t#mTn)XpM`Mr*d55? zkeod2&L{+Wre{~sdiiW#h6>F&ab!4=jsR&m$_brXv|Sz-$To2h7jb4BkOESOA-X3e zlkY0XzVboFwh%)~v}&qTx2zC(Mly@iMIql$kZ9Qhse=S0 z4I~+*)a_Bp$rjlp+qnu^%YA{=D+x%$Fs0W=Ne8`4Hpmv)OxrG8mREW7ysN!nS$--$ kOisPx# literal 0 HcmV?d00001 diff --git a/assets/icons/32/HELP3D16.png b/assets/icons/32/HELP3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..b4c10aa371f6402c8dbe266793aaad6ee327197a GIT binary patch literal 401 zcmV;C0dD?@P)Ms=p%Fhit|Ao0!$;`0W8$c1*E1SCWhgj3kU%wh5-glsP#0YwxTsa*zx}hk^>lb zfJjhPNlQn-s$-a)jD#8_=p`9??M7*XgbBt6H;-6YEEyOW)=}MYr?dBbjCay00000NkvXXu0mjfVnJjB)^qSA{8385}wkcb_&IV|C&Lo7iDp*eKel1)S- zv4V&~WF?CH2m%ulDvH=bYDL*u`_e7c?S17LD6p8%$O-IsnRn*-_&qbj@D9O&%N;Sr zM+HnHAOuV$jAFB0T=UpuThIZlJ8(dA6h|W4Rk{2aL|b<3+=V@d4ttV5pB%-rC!?%i zj1Z1GI^aUOqqt#vQq#Ne2Q@(H;KsU@OAkxeY zCq@R5dogL7JNqt&hlAIwwIphHlY1I~Nf?Fuic~AFM}`J4GyVFvoR8)#hHrI4O3Bal ztZtZnUV007gb zpEDQ#>HthSRUH*2l?AZRx&XYApo6+$&cP>yfMiZ@jeQp@SwK}vO*HDAW-e&2|AY!1 zZ%;NTiCz$D*VU|$CxKQGikuCte|NiY}VEFIBz`)2u8>{|*VPIg~!N|;9n%VjC0o(!8L6-mdbDV*Z zQGzxWqr2n(3q}?eOPC{Az&>YWl#rDcV6ZZmXW-;urHQ@YfBa@RcJd*^pp#7N2o|G&U$D_R4D9S}RA4q)5?Vt}ej zS~>z&9YX-bP7q)LwNU>5`C|jBr&q4~fT1xV$^?bKVA&aJG)PKeTqaP<1k^%dU|?8- z95mDiV6)dCw}wCf+$KZ^(@I4CBm4f(pMMOy_upc8`T7gk2h9H&9Mk*W-k?h^_(Ma> z2|9q*mJ@UUtt}_$09sp4&;hiz9H#>q8UAl!VEBKB)|L+n001?uxp=Qyo+tnS002ov JPDHLkV1hbbt_%PG literal 0 HcmV?d00001 diff --git a/assets/icons/32/HINT3D16.png b/assets/icons/32/HINT3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..196c2a5482a99a3dad7e3dc4b4273f098d0b7c3b GIT binary patch literal 962 zcmV;z13mnSP)&Kz)O7sh%jIpz&IF29lG;<*TBq1Q5<;ITTxlcc^??-R)hzE9D)!- zTb31i@_hAQ!43@eR|gmqFBGxIt;1jMMy<~Um#Yj8yG@QWHcUjLn^;(kV*1YtmRI5# zM}%OHd!GIsIg|szAh>Vc8)6LI^n9-N4BD<-fY;}P=DY~4tOm?h0hBmWFC+{Ia}~+W zFcND&u(Y&}iSKimUsy{yA~3XA9_bqxfOVh)!60}|%=;2Rz{X2(y{!&S&3=?rUWKOD z?;A8>MPbgr&OA>}MeucE7N(V;$C0oz@+j8{o@<0=4u*ikVME8AMtIM+fLFBxi~}Np zWPAomV-8|#8Nymm&4QPMm3jb?+-9rsk{4AT9b+FRVHjq>x9$xCk)AyxFxX!m(3p5d zGr!-_jOzL}l(^eu9}y>3zCk1m92Qg)Z^wSgNF)V&m|YW0-3<3uRK{(#Nh-KoH~eUB zy#`)&Tb7cwG>&9!N{(ylySXpf@6hL6+bJENzD&!))J?OoE4?~2H6YG;ACXhRQO>!i zUAAYF9|e>SvP~SswJid}!3KLg7MrEc2lrY~)6@w~Z;)ZPA|H31dG1UP>L)BM$MNRf z&r}qg&N|wxWCUo3BXU~ja;Z_Zi-gR1F+l}M9KGm&<dq(k*-#wBN&hkhYOi0oErV4#RQ_!yfnm-pg0t#mTn)XpM`Mr*d55? zkeod2&L{+Wre{~sdiiW#h6>F&ab!4=jsR&m$_brXv|Sz-$To2h7jb4BkOESOA-X3e zlkY0XzVboFwh%)~v}&qTx2zC(Mly@iMIql$kZ9Qhse=S0 z4I~+*)a_Bp$rjlp+qnu^%YA{=D+x%$Fs0W=Ne8`4Hpmv)OxrG8mREW7ysN!nS$--$ kOisPx# literal 0 HcmV?d00001 diff --git a/assets/icons/32/HLPCNT16.png b/assets/icons/32/HLPCNT16.png new file mode 100644 index 0000000000000000000000000000000000000000..b19181a0b8bec263ead2c7c9ed791495fac92a55 GIT binary patch literal 407 zcmV;I0cie-P)ch4>tZmmS90w3AMbOfx18dWG35_ z7a(>8UI#Eje2xLkR2;~*{qy$^4A-AtfSHZr048j%WuP+P!8s=0s>UBFEx<3F|AgdlM04x}U$v*&oi$i$Gic=m)nAU^#= zfRRDw|38NL0~-a53^Mo}@PXR)ftuwYz{AHyI2Zi?|9>X7jtMLdDFMdLS`63UUqKOL zLRSRpKK=jyzmt&#BYlz$IJnsv>;p|0Tq7(9hrmHd->o7hr2rfXi)Z&U&=N2)4BC?L zKf@DHYK=`Tq`s{nv!MWI2!IL;WQEkU9Beie000y;Vg1;9{V)Ik002ovPDHLkV1lTq Bq~`zt literal 0 HcmV?d00001 diff --git a/assets/icons/32/HOME16.png b/assets/icons/32/HOME16.png new file mode 100644 index 0000000000000000000000000000000000000000..689e815be65ba2220e120f068d61682b8eff0779 GIT binary patch literal 478 zcmV<40U`d0P)$uGcTO|>`SBGcB${NT{v+$H zd-9Btq7V?pVmS*tHvxM2Y2aL$EmFJ2Mw`93V=-a$JtsEak^Qj3bz+ zVL3KOd|(w|AjT0))UuphM=(;;a%AxD&o6lH5cvIp;WHbrB(`#bi58Y)3kh7ggNYWF zV{-(qEXqVH%ZYUa6D=(##u1FPwj5W&gcaM2GImWUWi|{rsJ)}A<8d0qP95Ov^bre}pQq=^eaoNMfFu;I?R1L2l9%DGWt%BkEXVgNClUIVl z*sFsOV07*qoM6N<$f}p{~x&QzG literal 0 HcmV?d00001 diff --git a/assets/icons/32/HSTGRM16.png b/assets/icons/32/HSTGRM16.png new file mode 100644 index 0000000000000000000000000000000000000000..59ec5946913046062b3e4c9311f402a56be8b710 GIT binary patch literal 238 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJt)4E9Ar*6y6C_xbWepBV7;3Wq z|EL*bl+F~RYsx5mn1NZWq*2pMD&g0~HI@mxyid0+<4ahy^5tSa1$ABlrYq-keR!Hp zS&S|{Ik4rD;G0iZPJsk;SFm4F&;N2^rAT~iN=&(M^iqJR%L!Rpb4UE&3 zv<+-uU*R%XTf#CaJE5U7v4QdO3T6p6S%XWm2b%OYEPpRCBP_|`?D{Q1$B!5sXbAK@ j&XPaVH{0NWA_K#Ox#~~e#YV0JdVs;x)z4*}Q$iB}dC5|L literal 0 HcmV?d00001 diff --git a/assets/icons/32/ID_1001.png b/assets/icons/32/ID_1001.png new file mode 100644 index 0000000000000000000000000000000000000000..2124c1fc1d5b599f9114f749291667060108e04a GIT binary patch literal 487 zcmVE&znkUT9!g-9D`5zBG^~aRV6|@yt{R3v=U$hJ#QPE~TjJ z1}e2@6mK3;Dr=uJ!jWn=!J4OC=k;3}`BHoui}Mp`C$6p^aGAfOQd5k;ti2rEeu37U z#A)Py#LsfCSl+0ajp|k)PU0pFOA9UojI$*5H0^$Hl6k>fU6_q(Kd`xNEtdfph*1{} zkNF}aVXyi-INX+&+kkb{6vgvowgnD%)3N60GWfs%1_rteJ}>}D3y3f|hMV0^n002ovPDHLkV1kmQ*Iobs literal 0 HcmV?d00001 diff --git a/assets/icons/32/ID_1002.png b/assets/icons/32/ID_1002.png new file mode 100644 index 0000000000000000000000000000000000000000..ff44a0fcdef43ab6e6f30ce1a80d449e25b33c19 GIT binary patch literal 1027 zcmV+e1pNDnP)-J4UM?8LPblHYC|)cO84C`ptf19ecmh4T=o%C*gK%0mDC~f+q?CGL2=R0+cmMgnCLo)gH&>-`R|0cHnCb;oDJ%=% z;YATV%H+;PBPG*a;{ZU_bvF<-$6P@FD0{ zoCpympP#DF+;k@;M!#K)CD-Z`+ko)m+k}DC_!T&3CU}}AV`}V90Mjz{ zn2gOF%+&)w^nOh z!1J&G-d+K{$!PlhNf=|l#De?Fcc99r!-Pf^H2em_&4ZjgC{YLx8vF~En*mrrohu}u zzPH1)o!aU9PoSzJpi{fy+51j}Tnn&wU{3tp_Kxu8W!lq6T#f5!BGimUn5T}&_9i1h zYVSfUf%4q8067-BY}){^h0qt}Y#9f{fs;O#r6MDvI(l?nXn5n1URRAn?Y zKpjlP0x2)mS%Fc365AoJumHjm|M}%o3#!23>w9{+sWQJ4qflNFCn_c2SBfDnuI5Wf zO1)4-H`r3GWI8mEU5|f}H~Tn;mjYRPv28rQ`Zj2CMeYCzp`D8Tye&bcMOZ(j1cJ?P zn%E7lkN}QRoMhO;+0Rc@hsn0HFK<{gx~=mv{KtuYavE zTRCC{Tol100E?`Y!$iNuz7XWUJ0@xddn=obn6_BwXcol>65}QNH-`!K^L|T=EWteg zlRhpyyMbbUzaGtkFOTO#>K4g3Oz3PNjJ`zB&@1e3{EE_>bjL_Wy@XP>QTB7T)L!Zz xhti&6x$Q!jmhShT#PSc~!{qb;@5JmqVQMjbY5g-k8h+7~b4v-sg9Bz;UL`b5XN1$-&0`a4@VrxW5 zGi_rGLRnB0CZGp|4t-N0sem|0&B38q$*^aZV$obJ>(ZYl1g%J~Qepy%ZVy%evmsU{9Eu)xC zp_EOnM}jh-9vQ-!T!=*rH3ty1BE4{oX%NC7f;SLE^U)5-Lq!Nr5@<|=JSjNK{cyey z?0DWTuHfg=0#;IsIvr4$gRrkv$_7<<^FG@#UV+fn&{ja;d;(^B9x#eKjGXi-l;^MR zmPC~ES)>=w5D7!rBMY(Ur>%3u_BY=!ZwjuWYxFbB&U8g{9lbY!YLZQU1WpdY z(|UwowTsu**{u{n$clKNblSW4f%dQol1^0vGBY5VuRcc@XblZ+2EiWMYkL5;E;xjx z$A^~Vry*M6RTthg@O`ae66rO0ZT49ATDyhcMfVYcYTa=mzJaxibXsy7|rP=jsx`(`RpW z5Zu@XtjJxFv5hhAaNJ~!MlakFd$PCGy&a@GTqQM~eSRQ@`FB@#UKGj_1Pb$*+pF7R zZwaM$H5g`7?U5gp6nezQmMWwP*G1^iyIeKZwFbbQP(lB9PPqivrI3^$aL?_qOZkeQ zp{_MRhzkWZ$76;Gx5eI)84d#DOft=fd-h!ef0Z$ZVxq;cXPDs_qnKpe5___@{1A)g zx-Ueh02*hEg5RYYAT`C_dN*WxWq{NS=aRH1wlHCEIC>vM6L-Q-)^@A z5)q>_fVtWE%NiQ$CEF1RK-{WG#lbZ)dcDDgj8V*Vdy-g1L+><{@dL>hLntgSX)=be zhqvN6Rl{;-xYp1aO}BedxtK!c+Z(K=&0VpaYCf2BhH3_ueH~2xi=!E~=${=&Su~m`OZ;N$6h%i6QRk?zu<>Og zq6r~WlSNE0WIBVyU`Pce0nHYF5F>1EvSrQIvX2(Fe%yP^x!A5_-BuawNt&E<`kwnd z=brbx_c??Vk>{#0E2>lm#$Dj#B)|beuKp*7j{_Yb-U^L8VM%T3^SFbF^Eu~c0OtS{ zUD{qn!BDT3|ia2Lmz^R-F##F>|ju8-VB+}};JnoB}a~VK0fR&et5D$Q2$w8VW2a0(%Bqbe8Ht4ZhGy*kz72#k%LIFR* z0sntW5C!<&iznVSrz!Gl!QalJqv{QCRgKYnPZO;gnsfvNCy0=qV?#!MF63DuFryDh z8vq&o(E9I!cDZESd^L0xSNb|})!&8k#};8{)oO$~JJ9yh3s8fBcw9#5edD*l?y6a! zYSKv%tcKYm$a%mEC3_f}jG z?R9%V6vnZJbudK!fhcSxu9~;lpemJ#3MYz;l$MTE!POu_7puXe{rbLVEOaJ~lQXm6 z*!2;ZQ9-DEI|h0$Tw4IaD7a<4wuAHvmkg%TA5s!z-@Q*SG>OM8mhpoH%*G=B;|Q6NvhbjhiF5WpMqg21zj`eeiJ0s+0uC zIV+(QZbb1{-yrbIDH!i4*7shlI@DI3d=iI4j(t*@tYA8b`j3Na!!X!hM&^n~M3U&M zj&vW=+etyljTfSckZKN$f4BrWceVbT>`gLZCPYJvhB4#d@QE!DX`8Ethm&qYsyT2& zAapPe-YVL{Ow2R{w=6sy7}g6XlQBpCLQN|N{?{AR$ip%vwMlq5VWWhTnJEZP!7ZQn zxPt``x*GvnFKiSnGn50w8wI!Sh=h9;22yyqnS#!V1Y2%f=B@+Lme-vPuqb0J{jEUP zt9yL&L?iAAC8liy(AwPoFalw5hqyIRHRc7_^RYf9vE!#=zED^*V$zKM2dNPnL=cU~}cnYgSZ6>z;R7ydBIelKLxb(xtWq9H#9d(I#-py=chQwFCW literal 0 HcmV?d00001 diff --git a/assets/icons/32/IMG_ICO_PROJ_CLOSED.png b/assets/icons/32/IMG_ICO_PROJ_CLOSED.png new file mode 100644 index 0000000000000000000000000000000000000000..6f6989be05faf96aedbfcd723aa5b549ee8a7cbd GIT binary patch literal 313 zcmV-90mlA`P))EGL2o4Wt_+c!&6SI|D@M z@Hh`gIx?W?^irp|n=7^LIap7B!DhGDnm}l^nE)>ks2E`azyzomVFKXa1IWjTXuYkh z1Bq7i#VM~(N+IAY*>V+Wv$Hen0ACQ5!Z5usmMsPncCoW;*Y9%%3%);s%eV$900000 LNkvXXu0mjf?ht?E literal 0 HcmV?d00001 diff --git a/assets/icons/32/IMG_ICO_PROJ_CLOSED_CHECKED.png b/assets/icons/32/IMG_ICO_PROJ_CLOSED_CHECKED.png new file mode 100644 index 0000000000000000000000000000000000000000..d5dbdc9ca7b01ddf48d7a420ed4be1e7f90647d4 GIT binary patch literal 827 zcmV-B1H}A^P)`DShx;F7^wz+Ah=j@GlxZ@^HCglw34~O%f=Y7xnd*0`H&cgx1BtnRa z5YkHsnY9!bW&7+*nBW|MHUPWFTU%hOD5ch$_6U_BTn^L#IN|Qirm0?V*s30L_t?x z1({kSa7%4WZ-)HbCHXZs>Ja0Z;lCR4+jW&!^^8nbPY9U?U;>~StSH6gr|$V}Wio6i zDZ?7Ajy_%p8i7#7PfcK-xd-l#AN1DZi_}C9)eInIthou}ZBGN%Cls7P^!6Qe*uXGM znN$NNlZorIIxmC45eCqN0#A*L!Oquh;D|@Et;;-s_`H0$I^JNwc-p_>v3Ad1Bo-Rc z`=t-%)wPw{c%@NF0fjRR&W3vO^t4nQ%iWKWThSP8Zj$VyO%DK3guS&T0Iu4Wj)a0j z43CWA`ke*{qHwCu>J+31WM&(_)0{QdS7W)d6dB=s^)l!@&A0yUL$C^kWXsAqNpBAS z8VD)uiz(?+36z_+EIP-jHPDq;2f+QA+(JwD=iX((qZEZ?~i1#o$!I`@k|Z;c~-b8-kW! zkK{*B;CkDR$c@R~+`HV9_+}dp`Ywk*q%pe#9?=6nF%IgCU9=N=Pi-9>@s3yA0jhDw zg!humBOnMOJf8Xf5Ech~nwgnJsA93oV*fjU{|>CO*ni#uZlR&Gt7p|B;0P;uj>-8( zgrJuGl6AcA3>%#?r3mPGbrB)BLc$OU%AhRDTxr(duV46StE|PNLU~Y zR2%|Prz7LT%re80B?g@dZYqulqG2c%sO{vXWqlj%+TI>>?$*1uv`twl|K#Mf&pExn z|9#GLPtOHbNraGmLdX~)BxF5Yw=WuJRte4n=mYTd!kN>sH#gGgCr%;Xv|0w*0KDP5 zG>EC1*Fi)vI&?PY1_&Xq0_eCtJq1hUD-eBNc`Wb#9jTXKuhCRaBKQIfbmt+I{VxXgQ2_aelKM_J+x(VM3 z;1m%>e)?T=9Gq3HfxhV|I89-gPj_M3nW`$&^4r?GP!tL3CQVfX`j!t3499g7LIMEl z0Tffo`tdl!Fh}GXsIRZ*Cv5Hyz+gWE6lMb7URs1*KlFho5jj>|@glSb zs^Go&Bc{!7#a2A-d~Odm)S59iK7ppz&XzK5o>^W33TGI+o#~zL+_4?6Rlb0^V`|Lz z_Q>)1o-YAWg!9blIC%a8JF&i|7PE5>eEjKggvIci6E=5P&OpUJ(^a}=C%Rj)Tv_YP zaG(D!nZ3gpBn&fz~$Wn{`04!5>uzC5=w|oSlq(p{q zsC`G;?I<`IoGSG`unc*;K3MHDDATRO=96E;dtm^|dp1jJ@AX~7zxLUbzh$vPayVU> zoVG(01Zc{i0$Wmyjwegev->UtJb`&s>>ZFguDyLxdEz3 z(2vn$)o@!zpcFW$l>+>8)|4h#tT24M`yjlNqZ0hlEyYqxXM)WoT&?7x6xg&T*j&O( z8;7Kp%!EP=tc-z33V5OtO>CR#mrSs$0Z(Q^74k?X*lY|~PBvr=Pi2D5#(?PeNxi_a zQp;34$3Vf~n9pWo;O>e;P?cN z1%sD{m*?VPBk+AYyq;Of1WhkZGZnXXoz#n0uOx;4q1_di0T*sZN;U9A6;M#RBok|m zT~bSgLs=lf{X&6D&Hy3kq(`!gKM&rP4~6CtZ1eX60gs%C;6Fpj@4VF6;SQVi$~($oaXFfluv=y_=U1!T?`rV)a~0U4&(OGkfufH9DGs02Jzw=)G`)HM|D-w>r&55fg7>Kaya53JuSFVe0MJSg+( z)-qH@LQGYlecN`0;6a*SyVNhr3xWq}9#dtg3ipKIL7ERdEsAo2h%{>50We(5?Xp9R z?B)do55wFEBC1ye1n&f3gK&D|h)CjbrYSd5CqMYStgVu;8m>v<;t7w zYdYSnen(9=PR;Kb~{1dtqZG96KK79N)iYrOrRTkCCR{=rsQp_Z& zZ%B-d!!M5Jp9XK8N}vosQe(jABoH5HNun<~C(3RPH7?9GC0@1?Fip(TlkDC5f-jCp z&sB_Qd7xIYlBjPMolk!5I+>q%qKl7Gy4Q5IsJp4l34$8V9{Ud^Zaqqwuj6_sd#8Vp z*V$_TmkENpUBnLTN?f{`THIM_Uf*>9JH($)j^;G;8|8T~wDEQJzW@LL07*qoM6N<$ Eg2MU}I{*Lx literal 0 HcmV?d00001 diff --git a/assets/icons/32/IMG_ICO_PROJ_OPEN.png b/assets/icons/32/IMG_ICO_PROJ_OPEN.png new file mode 100644 index 0000000000000000000000000000000000000000..a9fea904c00d080c7ea32ddaec8801f50619ade1 GIT binary patch literal 502 zcmV z#iB#3gB9Xr3zCy7Rg$I+BFQP(2f4fO9p8JrcjN-}@ZUk*3W-#Dftxr2L3QoGp%cSW zv5-Iii2&BM?{~-r2x@ch523g<7E^k4*|kA_Xa8%jrw;tu8OUa{%ANkYMTCrBq#Q87 zu{WxQHXRZ8O)fyd00@~o{ndE}h_E8&Vqx1)4M?Qcn_R3zZNOLNHZG-GW%uw{iUKBu zr6<4z%3?CjTk8jF;o|ZNULg?Z!}wSnM9!;6v8+d|g+`;{nE=u2x%PsgNVt;#egIH1 zKB{4EW(xDOlkfwnwGBkVgANxM5uJ#I{#ZqSFbKa;uh*L{v_sLNp;ARRYHx4#uwH!v zW8R-j{qdtT1kOba5HZMffr&vz4DBx11jvfP>ViXnCLso^3l0G}Nilr7(1Kz69}qEcj^y>t sEyN=MhV82(V&K3TWPxBvF7=F&}RfLul$H!Q?j)oM%uj$58HM(Sr#4On#ll}1rIyHr8#I3Ti)y$35%xEA8 z`|x8jH>YI8XbcM`nq?|c6o(r3Lq!dZKrSUp(K6Uw3TU{5zZW$U1f49D7xZx$uCU{$HJn8Nr44ARsLkePtBha2ku zA!!l((^Y)F8^hdw|&h+d{IpR3VltDc+m2@ zs=uY;bEGa@%s&q@#&&AkiDTC!x!7o zbM?C<+Ff zkE_T{Z`)z1sKmYdK77CLAVNy$(=K@^q*0*6;e5!wJKRu*>7sY53qxm5Cv4|_+YTIp zkenQgtt#Ej3;$$$APrB6dG75nzOi7^Hqo30YjvH9Jf2HTH0j<0d>=g-8R>Je;)7!3 z*6fO0H1WqRy5na{63$(?j2pMQG~)$4Cwzks@yD4qFrx|9+V3zcD=S8xQ@JH_+i~K_ z$Tg%R>TWJ=WP#0M?+Y$=q;Fw zmm^FRS#^8IHH5>Ia2zXfIHRpm^CDMNQc}`0CzEP2A`lEl65>cnNk(BoJ{TK6bQdpm zXcVxb* z7(2p0_ssZh)A74p2ge>B5nh?4SK2| z@RuGoOjJRYfL=DltDs3BPX`;~RnR2h*2#vb3S;oAen#8|A~>$!yaoQ~0Ke+i;WiL( h3VMOTuN&7(i^m68pI@?!Rrvq_002ovPDHLkV1k6A*8Tth literal 0 HcmV?d00001 diff --git a/assets/icons/32/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png b/assets/icons/32/IMG_ICO_PROJ_OPEN_CHECKED_WHATIF.png new file mode 100644 index 0000000000000000000000000000000000000000..7f7017bbf924d1deea3a3c4cc9b58771caa01234 GIT binary patch literal 1226 zcmV;*1U37KP)jX{reRB*L$hd1Nc^J-^DBT7iB^=!bdE43ED#1N zih|SW$cWJ_7^Wu6+!le&eZ?iB3_|521;!|&P-a`&+hfixE$!ONO2>GTlY9EU=bY!c z@B5z9bAe?7r8J6C+D$2S4(;EY=e3h%A{PL(0oZw?^%#b$E1C7P2}P7)xdhY!cys2` z1q>9w0V;}K*YUe9fKvJzfCk6l0E`8%K%BAqeAJg&ANX99}-s zRCkhvnh@ghBhLo#t2kv5jD`7NBD_%Q)*!9%YjCpbhC|LkpkrexrO5!!QA%H$BTonL z0~JMK@cq&Na!zv(^i>DJ$HcmXg%)NHLs7wk{B`w>hs3 z0K|?|SK{WMm*^Rc~fx3ORgxnXATv!C_ z*$xbrzT;oO!Iy&S$lAC9sbA4~}q$5hDQbjB#R;xm4|1S_GhdhQANx?dJH&KA0%Q<0R0LedF#{GVO!P~ zY~PxRNWsGX^Lx)@bkIY-?fwKwKzq-)tO$+}@;&RAhDQ*k)!sRI*Lfd#v|4~#!Ois* zfLDZl{!SpQONlvSG+E3xn|+mOWE32?_?_vVwV|hJH>~}C1&}9Idj18+_GCyl|41lf zvM|f5!IhVnyFk#&2KM$EmyG;Y+!~3E*G@ty+C2x6Hx0)A0l3}nB_|IhLgSp4L~zW( z(f~?X8o<&JE{sPj!X}p!!7*c`X%KBQ(vwv>YvDrR36z3oJm)n=l7{k>s2XKw&`0cNr o7!3&RUHLZj7cplFNzOd~1NF{8;cgW1=>Px#07*qoM6N<$f<%i;82|tP literal 0 HcmV?d00001 diff --git a/assets/icons/32/IMG_ICO_PROJ_OPEN_WHATIF.png b/assets/icons/32/IMG_ICO_PROJ_OPEN_WHATIF.png new file mode 100644 index 0000000000000000000000000000000000000000..78b83cb30b54a2fc6ff8c8a416176e9dabe177ad GIT binary patch literal 762 zcmVQAX2L>bgAf~c2RX9f`5R}E`-J+bP+ceMGOT+aAOw*u~A$U zeCz~qBgG1$s8A3LVnbsqq)AIFq)8-`M>BG6k~WV{NXDct>IXOXa?hFj`?%)}Oo0E| z>0)|;0lVXjmcnB&*h-$D!N)i*PP)dXj2Pg$=avH}G1x?|LCK{KrpYmUspJ7;;}aXX zRlR|K)&owbQ=ap!-C_(QwSsCu5E>qI*cxvXm7vye5(ApRFf!*`EA9ctFhujD>s~EA zV8DJwu=p0SrkauqSh8N^{-dYc;(%`pWoH^l#(-yz^iadPX{>+Hp=H(!nfW07n9XLx zY)MO^(?11kB#_={Xa!CU1D5)YoDUyAi&@TjPJpwD#bSoxN0z5yRaan9Bq$O`IJ6AB z880%CF`zvJ*x=!gcJ%g~K;OyZFselKH(p)8fWXf*ytlJO7N zy1KuIyFYEf>n$=Y3eT(+AZsG0C*=11jc>ia;A%9g?(z8p;Jos_OvR&^bzMbx{%an* z_0EilFJC(<_Hu8+)YyZ#WC0%?9ZiDa1toes-m1Y1Rd^HKOH(kdtLfJ;TL$m^0#d0| z)!|#2uqHyn1g8L%0h&f-0F|L!d7s=a8?I-9)27iftVbharcS3(u4IY9B&YLvcGE~1 z4)x!Jb?*U$)r4p;HIe_^>fQ5VCZ;C(4BySFy3+K~hbE5qs#GT$rh<3S5)64@B%KC*p*hxD+U3 zs{lmfYgXIqKPtm@tL-^}DJ7P`<~J`;^fdqkmNyU&$M|%nt+i?Buk?Yov&MS>ecBD} zz`yJ(Xct-yVA~hw(q1u3)1Fv!Q7eZ7!dnhRdpoMRr(reA_r#)&Q& z!Vxi(@ei)u#dT9p!L#ml58l0>PHPQk-2hUN7Zc~`KG%giS8r*8TsWQaH#&QYisx_} z%6=1$y_(QnKPfcB8}k6M1dOZ+J9ZUg_I%q%L-%X*D7_$D)Dkj*I6A~j+W)TxQYnK{ z5ghpUfbcIl5KNa!t?(PSrp1xT0V0g^Cc*2p*5F!sH_$FOnu+j2YnQbW27+9JYt>2v b2M)ggE;SdbUA-S<00000NkvXXu0mjfk#A8f literal 0 HcmV?d00001 diff --git a/assets/icons/32/INFODG.png b/assets/icons/32/INFODG.png new file mode 100644 index 0000000000000000000000000000000000000000..15c7208ba400a617fab8906cdefb551e57fbf5ba GIT binary patch literal 2760 zcmV;(3ODtMP) zU1%KF0fo<h2lKe6^c!% zU;0vtZQ7IuQVId54<)n@HuYkM7^;FCx2Yg8m9b*WwQR|<^|RK_+;Z-&Ks$41cXnrY zcBH)@=wL869H3hwwQ2ch0=Y>Wc-#++XEH-M ztS}O7$maB5cL!4YT-P0dz#b{ZZUOW|pvZ(kBqk*=CWIV?#5K#ZM&^;bdM`8d7zrhD zhU`e6JRn{7n}GNRfV~h%)$|J_c-IUA@}jV;zun55xPkmi-|NM7}HiQ-TC(=4A zAif_|hIc|w-{;ZNxfV%gaqb~z#{Z-4oFF9Rn@l;{2naB3EqTyl^u!G~IARlo_u5K~Ux0v9S+5eY+uqg_VqyE@s9@ zF@JwNpa4c~%Xu!UDWV3CslRIP3?Woq(YZ0+uBm!6cYj>fEdedDD_P-uE6U@`ic*0W z>Wl-r`eOZO23DOJgxADt3wT#LKuxF(;x>e>DP0Aw%-HoM^`^aAY3tdnt}(!rLj`T( zGlcIMx~A=t8LeIG5GPyKwW_~3;WY-CLT#u~EOp5C^r->ix*zyn`h-xoa$I-Du5F!o z_0Tqa?b-F{Xv>Q-pLKBQ`V`)}a0fT;gzrR*0{g_K{yXBUQ~2^IE$g}4nd2jMGelM5 zuKf>Pi>hbGGqKef-#yripT4*gwx$31jw|u2cW>gI%Xj0e=x=@G|3G3iYdK%8q>``b zk;RTeof&M}#%0Fg{af&}m-++EApDGFST+uL?bN`Bz;2~k1y~hzp=)|=`O?Stj5ye_ zsa@R}VPRRG69?3QT6m#m)UKw6uo+hv&nW&f%T{mTalQ0?=c~PFO@;q1mgPBdKn;`@ zx=LQUXTmmxLtPz5`gDU!?3;?SJLD^$>xt!@YM~a?M8iNq!{~-^3>?5oU9YX`D2$O^ z+d5-8CkoUgU~K1PLCa`{xSWun83SjxNZh@)jw@q1ClZA&BmZ%1Ra!fD)W{39EO(cbG=%e}e0PTsYNW3bT>1BOEa%h$rIGguBCu6yTJYrT zMI81X>D=%XlE9_wQ@H+%YpPEx{p<$x_vY)#vAYY%Tz{bYuo`)1cr|-CJFV09C%W#gL}qjq65 z4z5FlS}aq2F1=|uh`g|W=+~12e9d=-|_ucpJ;>>&F@%Lo~ zKn>?TYg3fgz=hIvh`=82p(M@2J^FkfUOluu&uL~)|yIP_=f+uaw#bs z-rrl7vh_xIx(E;2+7Giny)n+iQTS`7s@d53n3 z3}IYFsDEUr3Z0f-&5I0Sc8K=`Ed|TG)qG_y+E|4c zLlTBDB*}&_{L5Q_*&&A7pwrT;d66MZV)LHBAQwYz&}r$_yvPv7;(1SqlB#1UuccS> zB16;ycnRNQ%a{@!t%eel-p~PEZ||7*P;Ozi20y8}$>}uIXsu~w$x-hS=1m!*q1Vu_ zwXV1KnlAUl5Dl${8m)bXFiO>Xj7e;UXy`Q5Y3(zl8@a26DAl6KB2%$f54H0}3rgga z*5wTOh$}_~b8U-ZES{k{wAu*_E3HFyok)36w;tP29a`-)8V4G}#An|>Re_P_t-VsH z8MO6mednw^yF`9+`XaX>f6a7QJSEZOaWg))u2w4dDpTYPeMBf9U}#iF4jV%(bl~uDe-r zvUB+i;1HUIHiWwbKn2q;|A$iL+8RouH1fs(N=ztCt2Kl>0|>~|x|W0K-wKA>=vt)I zvfOS9WyjPl%RTG6OMp^Akj;&hd2M{hF`=|9Ls>%#j-Jr9AQ&=iD2AE@v_wyY*^4C9 ztP}2^!7UrS$C>!dkYPg}YC%mjj1)9PO$^~MBlpkHbqg@@nIXf?j+Aa*3r+VDwF{dM zA9`LEH#6b>8Q$ZJ-)7=-Ts*EITBDM(QK1I9C~|66$wn|0O_bwiCJc7;9%uYEgCOJJ z{QGz7QZ@>_c5MW?#HiA&0xB|u>6)%(z03$y?`LdT#L-26=Dl&eb>Vi|XbqNO*?Plk z*0rjr5w)r`cD$+tG8Gam@Y|#WDL0BIv(uQm@lXA*gv1Z4+3=;RxxM@%Zf4^94X&ep zAb)5xn;{|JtakUEswZ1>XBqF3-sPsO<`Kp$)2xH;4B$dRo2oF|RU~Y?3bUchYTD3c z3A5!9lC$N}5@u7dq2z1|wuIR>FFIyp$<@5EIUY)p|BtSG6IfT5L>WWB8XhZ;II=jH_TmLR>8)gTY`xbMk+=f>vycHea{^ O0000va!C$4ymEhZ(-dA5a+2#1?>DWi~%Wy!#jxw^W2oF047HO8vO|jj{H&K?pGnh&}=V zB%s+DjCGt`5O5|&lbdr#=Xf_X7>irpf4X18iI$e2tTAQ)4Dh=lB|?VI6tH`kfko6$ zkk8Hb@RZY=ikmO+i=jf${Swe?j2Qw30#YJ+B81NRx_kyZL|ES2$D5t6upHcw%k61k zeZ(D(EL)TC&yND3zZ3yCAOA|C9Ac%&?JH!1IBLEe1Alev0 z&?xM*rkVgwhl1`THK*(lB+i7JaUl9Q=InMCA0AB~tKZX5uR=kDixu&JzAvLZh62XV zs`VRij@0TJi@`*9You%fkWytckz3G;Bd=@dR@nqBDVKQM&16)z7sEH(M%s2*+&15> zC(9;aW-Hu+(^_qXpPlPYu-tAtKZDlV79X`3+21o)}dG*ybz zw(Y7}Y&??Y9Y-wIR=zVw_R(Z8*A?THvH) zS)FrBx6Jj8qS@}7fNhES+?5$A))ASjA6H7~h>nHywn;gGn}wnktSksDM%o&c*M#@G nw{u~zl4+X0?)56F_-FA0ki`pm!p2`X00000NkvXXu0mjfA5U!F literal 0 HcmV?d00001 diff --git a/assets/icons/32/ISSUESMM.png b/assets/icons/32/ISSUESMM.png new file mode 100644 index 0000000000000000000000000000000000000000..839906ce71804d73fda49ac5855564d3d14d324b GIT binary patch literal 1427 zcmV;E1#J3>P)jt`yx15 zOQG&VN4xjpz^o43pdTdcrQJ{*7GYmxiyN+38QF`YYwo>|oYah@Z`w7vIrrY@2R9Ap zoF=yoPtG}co*RHM#u#IaF~%5Uj4{`#YiuQXKvoPjR93YI%fdhoGIdFh5 zHU|z6#^#{U)yY^kw3n0wG{a~Tpv@2{mu>o^#d`kJ&*8@4_lrW&=r|O?GYGR)dr3*5 z&zu+%f_6b*)xU4jy79+l{C#2ovQLhIA~-;ptuu$uoH!1M@(27nDwZ$BTg8tg4tZa; z$v!zoj)ej^K$vYb%VP1iBE@`emE!OC6hQ93ae2n-)Qu-2ObBzOpu{m&nFgu->H-C=bnRP%) zUt(;oc{UGH)w`}7!q)|$2nsQLwEA3q_zGNzgg7XOR{a{gfrkS5)Ak_-5oBL->_VO^ zxj%Zpantn8&OCTBKq~jutRxF31+W;35r*a3*TmBF-9B?-%gwk^9vK}=Y{-*)4moqk z;J6t#WO$snH2-cWz;jEiihZ>!goQx?puY^N{qS0~Fm-o6102v6w zW7qKA<*SK9-cJUH9HUA$-BSTl-CJ9zS;jFyD3hsO2m&ggiJvz&w0^N=OS=+@wf_=| zMn_FwUL}!e1K~#!LN2FdsR{0XZ5?Ev90NtTb~>M``kUIt6Ss|H0^-TE4x&yIRtFRj zD2>f?{~_d3{u9%G{hhjow&nwScAbFYLX)$D{GWFuuTHJ1cp=gEVb9m&cI++wFHZzW z^$*p0JZj3|khMQ|5vXq{7;c3-ltR$)`o`9N3+BfMd%9e?(YKrCiQxEs*$r1yxU zc_r7j!DR?|7x0bLHEjQ&y}jKNZ-Ck4`T&VvTDlX2jZ>OW`R~)}BWogZSLiwdD1gwq ze!Fu0jCoY*|V3RkQeu^f5{?kN9y{3K({nOwJkl7VYn0lF%9^1|DFydGSF_JyRC%8vT$4g zcavr`S>jWBdh5|sa47-w`{H`r-n~1Oo*kV?cUK9CF^H)pBt-SY!LahlvwL(2B%1d- zAUWt%nwv{V1X0^iFx(H9di=2m*Q%a5@4kmC4^^VMqJ%^wf+M|z1oYMEU|5+Fl57Zt zLaxl?s6=yomi+e2B_wCIhCj;PnK8F;Y=C&JgoNdWV*|vCB_zy#j{Fp>vTws@09w*p z>4KlEHzRL<%b8>5-5I2+cYTupc1&r$;wODgBsdVu(P=T4a#Vm+_SI}8p~){=NI|1S zSQ`l*;UpPTZ;4gax52h*UIL0l$~h-XNX~2xU$E;On725pnm4_^%KarIEcYC>#PU!H z2~&g<1LQA&wz;{4gt_T@5Hd4*JxJM4#fd%5#pf@V&GxMynapz}zg6QvPlqj6(AoWb zEXM(IHaL*c>p`AqY|YB!GUk;f7Gt*I0AVZ}ORVHtI$N^+_)d8~-mBym&mfF3#u#Ia hF~%5Uj4=i$`v-fX@hU~%e6Iii002ovPDHLkV1hUks+j-) literal 0 HcmV?d00001 diff --git a/assets/icons/32/JUMP16.png b/assets/icons/32/JUMP16.png new file mode 100644 index 0000000000000000000000000000000000000000..fac02adbaed7647dff81ed0f3e6223530c623f1a GIT binary patch literal 486 zcmV@P)`Tw%L< zfqo_0<(_tmz+We7QAvUSy7yIFuo-_Seg8HbrG_Y>*;r7%$((#QrGYQ#jLz;= zK=Am2(-<1@nmYY>tKhYCCEHqgzSuDrTOjIE(N=C1yg}1OwYolvmllEz_Vg=Y3ZJ(LV_=lwB`+Gwuu{XE c(rkL<3+KF`VuBH2cK`qY07*qoM6N<$f;|)0+W-In literal 0 HcmV?d00001 diff --git a/assets/icons/32/KNOWNFILE.png b/assets/icons/32/KNOWNFILE.png new file mode 100644 index 0000000000000000000000000000000000000000..bcb6a148cd85ddb92f0595211295987e7d6050a7 GIT binary patch literal 357 zcmV-r0h<1aP)5ljp;0>0jE3_^keASTQa z5_EL{7Z)c(NT4r4N3hV!0jt(-0!PR1-@jo(AV)k$Pj^hzwpdVEWwUL|L4f90{fivXdCzynRO~cM$IYasaj*1j`*HJ0KJ4Gg<*A znwmc903rYjAqDb=`3#hRhvz2_@ep`Ozz389CWZk9EQAz{rh$i}X~1wa4NRn|1DI%P z`ltgaNdvK|g~aHm7+{6~Bf}P&*~Z9lK|w;`39=XftKDP@v8b=<00000NkvXXu0mjf DQqqcJ literal 0 HcmV?d00001 diff --git a/assets/icons/32/LEVELR16.png b/assets/icons/32/LEVELR16.png new file mode 100644 index 0000000000000000000000000000000000000000..a9fd971a50987a9a65b624f4f81ba2a734090f9e GIT binary patch literal 317 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=hEVFtT{MIEGZrNluV>*&ukV!&CD| zzyHHYmckFRR&vgeV3XLefO|@;b4jnikQt|rKN?x8XY^$t}1z#!gG2@SLJaY8U@@MSK>{Uria=SI!PQ8M< zKBD!iK{*$sM1*f(6*W$WM}D;&72hl%YLBZI>C=xGVA5+8xV!rl>~aCn1=`V7ZtLwy(6ZRpTNRvQ|!%xFVFAfyciiJ@&M$i%)IUKB+^`*9@_ ah{YH12WTZSG}gG5E6=UDCbuM?$r!h}z5&2; zx7)$QMWvxL#xd7F09qT*w0rKQ%Q5OrD{#jWJpkOX=<2}yJha%q=tn>vD&EI#8>#@v zo(_~#=`;+_3dHKkX9G+Q+iTYLz9h{hSgst&xy1nU1FN5A8s2lNJrD^rv%*`uDf0Zs zrl(V-%E%wop!X3*hr;L&xAkkG2Jlklj4|>456XW{>wbH`hOKl2dLO#;8s@*%n#rY3 zej50Cc<#pvz5ry|uaBX70HZ@;JRWRy@5NIcFQ4n(1LzMEw$hK9_bcxnA|$$e6zh&Q z_)XpsKv2>;nS8hr?HEAZ@ZrF(-&F)9hnMB8sz6qLIEtn3fdO3c_O8I`Ksf~<<3`(o gq*uoF?g>u)2k}6wDiCvUTmS$707*qoM6N<$f@{ATcK`qY literal 0 HcmV?d00001 diff --git a/assets/icons/32/MAINICON.png b/assets/icons/32/MAINICON.png new file mode 100644 index 0000000000000000000000000000000000000000..bd72fb39de2b641aac7091c958d99e162a3e2b29 GIT binary patch literal 1101 zcmV-T1hV^yP)3KG0`cjH27zP=2`D0n4W>aDY;kAq=Ak#-t@h3~_L`m3-mZVrN_)FIv-kh+?93bO zJYa=vLrb}6W8Y97mJbo37eYHg$Rmje#zAsV1fyU(GI4!){G$xm*f*3X;qM`I2n2&> zLQn$9h>#ulkP)=diLSmg`^y%;5@DUzMsH_<(k!T40&E$HgmaLb0Za?zlNKjW1TS-p z!%wacUS6^Rn|2SM5TbML0u^1D2CPL>!3=5ZfEYCbAd!>*-yHg3Q3JaA&g{2>OYUT0 z1~mHy&5X3Hg0!`}eI|Te-x6qUXO|n(W}gP}^(N@+04{fj`veYOs2!dYugyLs;uY26 zG^sZ2)Whcx?(uEzKke;#`bG1-^NYa@+p*q_4#MTF)mFg41(w}VM{kSi6R%hcr%i`* z)mnk8J4D>;c1p8IEfsBnR)kxC$PRZ>$N3Pa&knjR4FuXMT5AochPO!#a^j$>EfmU| zsC6(i_I%ZkojsqUbyZs||Eu_>fV;Qv;Kn~!VH@24n5YHz?CnR-m%%F(3u8l0q82C?3f|sTt-Jmym&!I-o#5Tucl`Vl&vnPv0&e_$ zRcBP*0-?kkV6DZqzpl6~4KOl}LBcus?Rn&KjLGLOvuVIHPr@5!05QYHlYS|?wZ1yFJ618TMez&J#}mC^6G$RI=W|&a{ln|apMwvY_Qi9GRb&DD=7TNEuOQj|K@PM}niZGGDr(9VL~;jHnIcZa~%Gm&S-*>E2J3~DKH_NGNan+ zGsw8UfacU_f>B_?>Q49mG##2WwYoD9ubSq|9HWKGXF6@JN~RMhvywWy0y54!e-hs5 Ter9XD00000NkvXXu0mjfRcH!Q literal 0 HcmV?d00001 diff --git a/assets/icons/32/MEMO16.png b/assets/icons/32/MEMO16.png new file mode 100644 index 0000000000000000000000000000000000000000..d002b5d6e992375c0f7e86b91630ea366e0a0f23 GIT binary patch literal 566 zcmV-60?GY}P)0=&;odU_hI`Kt?qp?w$hn!*I1TV|GcW`@ z{$o&(ghU4jgV-Q3kQ`ld0UtL5gPZw3k_=q3@e#v?8y|7XfBo#pz{&WQL6h$=VF!={ z_8fmjKm{kmcLtdUFF0O40r9Br02oM$kA$;-|Ng_Ub^C6HckjXNfEUb6OrDL641Z|q z06tz`sO7&IcI@7cY`NpYS$#L?QV{+A{hML^=Isp6p1r_oIZYivjO8?S05O)+)B(g; z4gwhc0!qQL4>2$%LCZk^9s-OE|Fm??nhV<%3b@L>QZPNt<77SEXw2x7BfkyjwVCnQb~{AXZLh)>T~SU7Xy z0}KcBchrLE)f;wV<)f=36*PBFW_b7h1Dwx-u0TXs2rr+II3d8q#6(;oq!(bKn@yt* zzyX*T1{g4nI)GuYI)Is(8BG89@e@pECPy+PMhBtD(bNHQGLm5W(6Q5CM}RPhjVwnE zz=BJ{(#(+I$+H&>cke$2V;Ep%WdY04JOudpco;$hJQ)<_WxzoW!XP$C3?xVM5C8#? zMIJ7;45WZX%hoZRzjPI+{ClLD5Crf#fE=)U|6yX3Jy4JkctR5gz(7)bB%J;G_aBC> z+jqm-0WX-Dm^>RB8~@PM0erl?P|JTa?AW~>*>cB)v-)n(r6BtK`!~b-&D$BCJ$r%G za+*4T7|Utu0AehssRM|y90aiS3#bJMS`Gq;5MX53LQUI=v3wMOLI401Te^GVhq#{r O00001r;P)0=&;odU_hI`Kt?qp?w$hn!*I1TV|GcW`@ z{$o&(ghU4jgV-Q3kQ`ld0UtL5gPZw3ta7;0fQzLV!-X3kahmz{vm*m1<68zzzQcqa zKn~b*{1pKeoDAO?WFEZWc=-gxqk1_23z?+&NVwSV-+vgkZr{!D?mf62@Pe6%$+NMM z;SWU)AO!e$d7+m7X4tWNJF?}D3upD+pi5ow`}c2#^_#adJbU&6tK}d-vyzY)%Rzu< zX@D5ZL4al~O zyt6aA@9e%~&riyS?Cg$b=J%WTectDN{s1vz#E20iMvT1(fjxxmRLu%-!O8bluw0@nk`03s9cRPO@F6X+cf-WDXz zSwfu6&Clntix7DMWG6;%HEeMY1a23E!w_O9$ZYS`Q+-&hYB84zMx;Qe0P&nPRXCyZsGy|)vXhfTMy>Lg5aJO4 zBZxF8Ph@<KbgQlB7weS0zIaQF4I8LFpx3~B*b6d zdeyd3B|^orQMN4S-&)PWTD6ANS`|bJrU!^;bQ6LW0?6Kpgn1$T5J=2GG-uTHCQOWU zbz!7Cg`rdm`;rM|*GB-ZRH|66R8T5cP}$Mu@);IBo^$l#)EdM_wDw7b$?5V;xJ7p+}PC0K(GQJDo zke~1KbUoVBjj4ftjC7@-D+s{F%`z^mu4A#h737zvESO)&<@4`gw+kRQk$y~&_-8+F zJrh6C+lvnj_P2eAZxt)mD$cL0qPXGP-dh9k@bP@%MeIfaWDg$fH@cJG6@&-;d_U9M zgPVp1B1gQN5Y8=M@jW6C@Ev=q@MycH1kt_?8vBQShWw#a5+5EObPT-RgoVvAe!YCf zu@`*cq-7>QlbfAgh`a!1CenwA#7m8Q_6bAa(BObG&v$%j5)y18XIl8}>RMyJ0?|8G z0-p+dl@RK)p2>_JAs9@4zt{KnccpO4fuYC`_kMA?QpGQqma$rGI2tTi!v0ilZs81~ zCV;2L#~*~Ce{E#!{nfsH+%&Xr*S_^K)QIrrr4?uC*Z^xn(7ngziYE~QM5oASm+Z$z zhVj1cF6?FeVSNL?y0ikzdrk;V1R|ti|A$`W4z8rOT2>$T?CNmPI~(F`ORm8FQ&dR_yu7R@Y2`=cNrJPz78D(kee8Pj6B@C ztY#keWAcNEfQ@7}mSy0enWr*oUv70Tw8YEP6Qj4`1uCzc>hRj@HGi`8~^;` zl6-YQxNIe?kLG4Cat=dNFk0EqxBs-In~<&ZS;aB=&4WFo&eSP;O$CNb%Y31QKheAZ zIGDq0-scOC*ZHl3r_hfKdxl5emCK|bZR-@^gmDStC0|13-u>XvzGkl}h6~OtEhE3a z2?^FL)B12TQ$gSnfR`V(pl`{@XX}-H`>G*K6T|m$B9Pt~zVCkLT2n!CTq9qrY7y|tz*$X6 z9xkuMX098%CsYA&+&&;?WXE|wU-g!5o&3SO|Hk?M$lrZdOA(}xKJHu_gReCV5wJaQ zLw}$2I9Yf$sDmhw061ww=I!H19uDRRll(e#6G8ea^6Lmo1Z-PLqoD<+&EJiEJ`@4) z+b`gRaJz!TxI`Ps*G&Xz7xKdt0Z#><2DXhSf{X%2ptoPZbv=^l>rooR*NA*wM3D9% zKTHu!^!3PH#R4}583hc#PM_^W&7FTw05=WpYdiU!7D3tv`C*En!6@(*r2^m-ZCREs z$L;sYmnWf;-zgEK1CSq<2slAzL>5gYFg=sW98o3!CqLiqa{+u{aKO(gLLhKez=N_ZT~&#i%m48s zl>Uu_h@qtj(hA9E@V)Xqs{p6arA&7k1@O6+1i;m}WJ^Cz(N>A#bN`~H2+|>t&-bbd zh7gVjBslc+yBT9aK8sO4+t`KnL(o+BgI_&m2 zmtt!t+9iT?gvqb328LzJauSE7zmuhTv46(x7}w!zH^LS{I^yKlA@|GBH2ZYij=1g{ zn~>M#dNLBI@e%jO+sP8AEc%Tq21oM{u9@B>;jw?KYe69HX)Vr%ob>I{A#@ zr2D=A!zMB9CIE>Kkv`=1u?}(ms;7h9LO!Ej3)u~1lk2GN`fWji+pO#W7hcu@x{08q z0r_=E^9cn_23Q4<>oy`+-PQ%Vh@hkq`3zZ9wjlSONfH6Lf4N7p>$F!zP|}S21|0bl zKz8z=w8%r3CdHX`5J5>p@;x~sa^=-UE{4?4D>E?mng~jolFvvQGH;-8<#h+6+*DC^ za-CDX+a-dM#^f_n9;39|=)Qx|YddOQ4c+Vege`)S=Hxf#Xy@pz?<=jD2ucwkzZvX0 z0mRtj0#LoNqe~iE+XNsCgF9Eag4?R?Me?I00&agNMb}PlcL<qe3z3S6%lxG zl>5J()kO_IDygHQsQ}tVeiTID!I3Mkh98yG(V&|3o*-X$5qLDTECn$FU8_x%gY?AP z#pLTO0uPSf4I+TN+lSmsR~K}ed|gGbCK;tk!l|nO2;AS+<>dZ4UhNt3briu`Rno?m z=z`nFlJF6{?e_6%wd!=o>?Cv}Undc8(}|kx&X5q|y#I(GQ=D`AoZSH2G`UjN?P99!e9p?gTfBo9#I@<+KGLGWm%^YqB3sGpLeqY zTt|T1{5*fvwQFUm?AgvFlH?aPNl0xKC7A$(I4f&KE8Pna0;k;nNRY1Bt)pE@8^wr= zfcp?~_c1pRa9Z{|sQ_$<*JX}|cG&^#&e$nNSOlf=mb4wMfbm*z0T}jAWXFn|(z4~s z(5ZB-Vnjty+?2MduUY%HUJWdO?cQ{*-lM{X^p7b)r*rj+5fcG<3*cn#t;Mw_OT^HR z-9BHbRIwhCSFqFMM^OYk{8uD<00g*l=t}^GDPEQxn`_+kII`qNO$2lDP9m^jNI7gM zfZ7d(*JR5-!P_uN?{afz0iAQ9kbkZnL5z`C*Dc zRr{N{jSZ>$mxTC!%Q1lo7|+X&U07X*3S9orSFrN4pK2YwTU00lzE{3y6}WIk!U0j) zuG!yfSpZMu^Xx-*bqXz(w>nD!eL{G9B-`IS|uK&v8XSKNNF1rewuztOWdZ9~dgU;$WDg%bd|1{4%G%1TCo zRz%S5q>W+|B2Y~}zx})%m*CWs^YgBwc2fdyj6q?1Lw5Y!@)f8;P!V)0W2YEE1ggnr zlkcs|UeBDKQJxrL8;NhrmV|5zEGSwL1Q9`})3u5|M4*~{#_w0xu`1n9!)3W)qC^C`k?$sgu*he_&!d4f z3}Jsc=sBB8_&AiV~5+UsOq#47KZP;-*NJ&CV$Ja@!t#Y z$v1rn&u8Zg54R;d*fQ}YC(g_TY@ED#X$7jm4^(&Z8GMbZ$*1l1@iOvxV6<(Lj?Bsh zz_9`(#4*`%-YDXKG1TDgl~re@B?XBu`tkZHtq)*N6}}0O)YODobCwHU$XeJ|r$ z04I*m&!0e(Xj%a59I{}3L6&uD5#jXWva@R#qdBla{mZ3gk8e=EX3-bXsR|+6d(97f zWfQ-#xa1fxF@j;OTEnTuOVX`g4%ZL@pKW&NS5_kCc)su=0pF1wXQS{JrAtoOatwdq z7v^;7l4m+T5gj`=S3C(FY6RI+g-6*5Av?abRlytYEyW`6N&d7dcD--vuRyldrJ;Pt)?O1(AN$@C%95)ouDKe`B9z*%GZX2g=*uCrN;R~63MyO9cJ2rN+Y2Xzvo1or| z@|FX8XG$n;mhrz!m;IF8J8zlRy{d=(s}cHZw`~~yJGV0TybuB0(BFp-4(;2uqd~>C zosF{mhM(kGI%S!uPpdTe+|ZUM&CQEVQ@jM=u14SGuH-C&iN0_fRJVJs|NYuJesg)% zSG83V^rBs^J)B#VCv~bq+g`Qook$oL#=b6qqkg`>zboYkLEa5BI>Y^2m#;Kf+y5Cg z_VB54^7uj9$J(bd=?6e~0YbR8ro9#;-CZ~|I1o7@6t{QrJVLjx0p;1Zufn|>1Ra@d zvy<u5S_zxAq&q!$UB#N zfg4*7ccmO#VJMZva4O~W(p7 ze{5V;cE`Wxz8QP`+s^MFcI@DQg5oT&%2HM&9cc4MB0!sMS*a~cMOC2|0cG2*RzeW0 zNszYNvdymeCzX&;#nNRdfB z{YEO8IEo5@g8sB?t)9}LXNk~-%Hkk2e%xu<`+__w1X2L)@$TlVR^K7evmh)%CBsND z_=gdt_x2_e;|LfO#Eu8(g+hmUQVNmkI#{tfM5=0`s$#GrRUj)06^VkBb<6wN&O*yy zcEb6yC&yuDMv)!Afo$f6Grku(JplZJpa~%m0*J@EBd4|X6a%{{PovJNszFtK3##fD zAzIsrNUXkiUyvEu@iZnzhcJ=8hKckb^kgRATb+W!i+#yg_8|aJFpN9>Isuzrjm(MnC}8;+miSWgZ{zSQ%{7NmX)Yq ze#e{-@r9Bd8$tTgX=j@71tSf{)2W_U-obnnz|wekeT>yx4BFx6{W8QitXNlZ9q%TD z;R~PTFe30jb&`H=uBHT^b zZ!&QSl`ep``0mZD`Q6!k_OdRoU(t!WrR~npKObS%&a`mj%Gp`{3bI^`DEqNeuM$f7 zOSi^%Z^KmQdoIeObxmkqv$5ibd%sMM4rA!t5y#2oiR>*X`?2%M#359g09MC$Jx&@w zoz2**TfWwr>*woJZ-TXr;nZF5a~O^UXkPwwnN37~RyzOo`{>i7z(8!Fq?UnnAg z;nXp()@2a^m1x+1->dT@u{t!bz1Q*8hX9kKLm2%0u(x}ek=9CWxsZJMa9{;+)8PBS zYt9$+!%xr#tB>5TZ$F9s*2_0xw+0acYgD7G~%WG79(> zfRn3dNY@ezHHa~M#qjD~2#9BJCK4%aaupL{T`r@5^6T_*5;YB<7!<4j%N*%V7krPS zXA8eaDQH-Em$6L~zFSlQNQ$;8OIOqwB*SkeAAB-U_&p94eveWxod;>M1)RW~q6vV^ zProE>1eKm&590XwSpqLT_^)4G!|98@!nn(Vth$Ua-1{t70f^U66y???=~_X3`lm^} zeFkHBZ0rn-OyckN<-Nx;XQM#0rop|DdE4rEcWdDzfE>$WKyvkhjy%DCwfAIBA{ZE% z#9zLC90S9X2s*|-AVf%}?m`40#-E(YW6IJEbfV@A4xbsppY1v3YdZMf&xY`)uN}qN z%l@-`%ZaSOB$CJ-dSbTgJs0k+@m)K>c+ah^VbxuzTb9@ULs{9pp&8pZEpfbrE58T` z8FKJP(?LX(*W|6wD*CUeH(_z5OkB~tl-n&!5rRUezoxk}+tYw8! z0JgRtl|eACDZn|0&k*Jnl*1W9;5gxo{Xz7I*R{$k+{@(mmk8gGVBygx53G!LFUeT| zTHD60#p=dj1bc-17C9%$gk@V>a~1%RdeHS|RW*TM`!7VI_07)Fcy5q_YhQZX0L+`+ zUapj--$H{(AzJIcA;-XG<8{U~FSdT;*4DJ9%Q>a1(vT?Mhc>ogaieL?JjKB91P&Y- ztOzI2myyFKTwV$Ms5E~6-bLvClRHr3Gs^dcZ>&M$U(Vn^ z4_`wi5v?`EKRWT7(e-Z2LH8*@bC>b>)ncB&IR~^YiDB21oxVF?koU?pa&09Mt!?n| z=xf(Lbrk>+Hn_bWsjjTf7q)+G392HwN55A^lyhw*p(52zLXI1n+#hP!Uxua3iVIe( z@~r=ri>k_UZMl%cvE3ko>#mXeqaihRT#!?@LxN4jkUPL2*FH5Y9Nh&VN3Mqi8)F|C z9%^MMt>%gq2}YJoh#6BKG2GqyZX;DQ%p}VHwD-1q^4caT8K@q@=AI z%sA~oAcS$!_2xyWq8(D&q7zb!$PHpT;adQfqN83_v_pbPcFd!1Ec>W$0obsO$%Ilu zJtUY+j9xbusqO^)j{tqiL`v$@xPC~wvO=X75)*0nQZqz2Y$`?Tks3w^bNP^v@*;D; zR3CG1HEC8kSFHCK|OQMI&8RJ8j-5VI$M%W+b zEC8oAoxvlRxo-Hdkn+Hc%+OW$HbT#_WFnncJOC5_-0k(rv60X#7_i~ryb0vqhrR@0 zkup}K8XLUm`wNDYma##P0@OU0zk&iQ}UryGU4jh_a%U- zwIlz`mCrrW;q?k0uM5J8oRI zi4WP`DKs*G>{#U;tTw z6g@FSDZSUYLpU;k%&@@|6;gCY2U1?qS%-6}DDGPTa>N*cjmjGCI|*j(_jVz9qO+4o zU-Veo6A~p$4U^T2IG=p^(41rk zTVy{ko+h_8F;0e4$Md;uhzVv~?>*v`_SLUR8%O4%3qWE82)xtOE*nM8W>Ekb%jmLP zTTIfI&p0bB6RhxzAFp3g&j;vK`bQ=gu`rxEW{y#tL;mOZP+6`m=DhE1T+_b3sc9K= zDgbAvknAT-S*NTu20uUS>>8H4c;tV4ntS!n4-WM^*On78sAcFk!bsVaeWsAlD7f5r zYkb!qf$>vQdn8teMeDxid3sf;u@vDCA6({C3zK8xy%-ptbUOcEKPqq7n`B{KJ9Wqj z!gYm_B}EUPPwwm~iynmg`s3Lb{QS?YR*>E?LU{dT%mO)RN{!7l6%4 zm|+;c2f}*qZ$hYD+=hl#ch1|bVowiEgcg9ISebpnWv!Vnb#N*wO(^|a-q8I$UKU&v> zhLv|!e5u;Z&=n_u)7J@Wj4Xq97R$*KC;?2+{UX$_=&U#)WNz-_ zd4z7?3L`~|{x0+=2RvK-k%;2pVMD+Xh%c{!>Zmm*rVYuh<3O|qioWR86HHzbBn!nn%u z)CWoc)2xZ_-fC;!Lj+^xaxbK?b+oqGu@$7kxm40FRt$nYG3KPd$r*{#@lND({%0ff zNc3(#0i5$%0MjdlGuryL23{hbA_|V!an>8~d;%ZR8razn}!*B82beJ0b*#gOaNkw2lw70A|t}-@OftXTiJ; zgo-F#%8YTz&zBT!zgfEFBJcv3W_7%~m9%;apeJT^E0+ld4uSb?t@KaIZQRW}0o=aH zq#gz65fC0I+ZSPElEa~ z*sbzn5CCW}I#Bgz{<*t(uirfDXY9XubWuA!g16n3ma&PDkO^kb{aesEm1;t&kOCsa zovxK+{JsySKEqIK?8&Q=#FR~iO*$%p5yt6zSn(`i9WrCV8jEzeh73}U$~J!Rt=5%KSu5E(Y{<)9`m2)Ei81* zsdhVL5t&M==vEHV-X@T^H0Nw@D2~Pnm6In=kELGyy8dM8Oe3?eUY!{d#uJeQ3Xfq^}Tu^Bgz^xUZ_eghb{zFPat<$GGplsdB$$^V>4 z30K?Y;TjSWGotU`2c#mhV6am!)JNM-A-80_WqBE>U^UF0emZjD5gy)v6izDWSOt6f zD4;d_Zv-n;e5u>UE$&YMxm4ffH%d8{e)7%Wy>Yh@N&7EV(TD}*DNnC-eROpuHp>=P0WpQ*k6cDo~S z67N)5lXk7d-Lv2o#ooHC#=#2cMembV>dMF{jZ&eWh=#hdIX}HrJEPB)H{w}0NDE>; zpq(|fl8bD*j~{qlq(AB8QjVbAFJRM3w7 zUZ-O)qLIVW3F8tK+%Fa_Vdh0>|4WbwV}hIRL-bRrtkQAB5SI>LZqee`>V3 z0ZFE&NdDV4LBMD^XF4%^c2HosJQ%sK_es(as*y?$dAUMrX6 z!w^bTZbyVflN=P$L+xO4&#Rkn@v2@zclX4*{P{|~Bf??^oWii9aFJJv6KAj`?aY2l zh0S=rJg$S8m6RN<;MC(!u(}mb6FLz;&&U3`=5uGZuTPhNNj47xSx~$r@s#f+FKMT1 zUjm(@*ty+6-#^B1)0A(}qsSO=od+l>+j+ckC)SD9yioeq#ok=Dr+p!XnxCCa{p}Cm zaH&C)4I$qT2EuRXx+Aur_n5KtrL#B|MgZrPV7CDg!I{r5*pzru>wi)TRhcv+lBzDt ztO)YbmM&_1C>A$lnO+{;D7Js8Yi*9Zxn!5H^bh3p`*n0!57b_bdG5?RJb?MFP`00+ zTf3jSYRD+*>G)OTmYXy znDeI&#t{GCytD3d-ve3=|HdFzTM?J=0|5c=LUE)5(){2Sm=;` zMo@WATjj$m4P;XF6gmV6)+DXyv^}_BO3}*YTjD34t|)oTSyJdltL$$K>nEGpBdX9{ zsi>TXgv6PNGv+u$_T`wzmn_-c`sqQ=Hzlm5uZWfNjo~@s2_|9tcT<-3%bN0Xs_>nJ zN~6T&&9q@~T{Fo21hyiRzRK=g+!L?Tf3m%;F*U0pNb*<#-eXP<;8?f|st+I3>)?>l z$?86Z(T_Q%5j<0pfK#7%!4nxRK{JK!GWJP?J(8=WK;J~$bC)F4fr<}dXDijMg*05V za5|TTx(tKGMRpw;sR7}v!lWSVgrKFxS>%W(SW|L8jA0qA7D^^kH7W!Q-*@RV;WL`7c5kJdqSppfMCz! z7xa8j>}(O~_8WUfnCH%eTj|~qE00jqB}%IuhenFf;=kLx#ImI~xCst%KZUsDzVjIN z_#lG>Cto>k6)TRFzN&nKXg{Z>$;)z@TiF6&0)+9`C{aq3CAY26ni&a1ccC$5TZmv3 z+f;>co^_zX`*6cMQ@Ryw8yape^#Qf1K`~=I|6MHSu{BG63G+NJPNoNnJS;t8lKGW6qtj<}5pS(e5Dr_2zZovzX(QrPx zLn9c5M8kXyeiev3KT}NDtL7i9veX3!5;YzEAo@Ndpv29Oz_FKyjCkthdH4S=!jMsU zM1LEZ>7vxW9hy#dFDdpxng%YaJavz#4qq$>?I~(qdXdp_Y=E!Nk$3xGapXunSTo{W zE`?bHFv1^>ZE=MU~}#;>mrw?B4~aShHd{+@XMJidf`P@y=uRJYIqWH9GV22pAG)q-l8o zMB|2&4a2>^7F{bTOc5IZ+&<+aq*ulgH%z#Sil+Mg-cvK*uyC;$+-O$?4HtwK6(hM<(&kN#Q%%q z=EgJPePv(XA54lNiyjs*7_Xhx{u<{tlH$}Lo$EiY7-iosQ*I9I+d7D~=bQ|>ufsG+ zT&wywRqNAW?D?(EmlrY;&I0ExB1BR*SO3Od&f!*F&dO5 z;!|#`4IJ6&S*=(HSTJWpM{>^@Olr#f!mf{1f64i-%XoJRr9PFdT|nK5@t*~$Aq9l6 z8DN!)>YU!yHS6J({Rg6UmxM*j*0{L+1uz-|Hr`SkF(LrlZ&@94I!Jx1*DMNS#;5C)@ueSVAw#)1=P(% z1j^!TMagHfnjo}QMx5GFfZEZ;oxxkrk;Hty>R42ph*hWaw}B zQAvYqmB{9jFK20&=9riw(8ks!s&4~T{DphZ%~4=Hw&Ma zkz)n;e&`;aujO*VhhP>SiBG!5x4VFRQ}$mne;gMG`k@t4)2c{`uyfpkv=|H^ueGdl zS^eWDY6ZW^2}t{(i4Kl5>gMVNcL+KoH?R2S?FV3r+Q4`HzKMp?8FY zgac2MPnUy?g*yx5n*5ISqwE3|wLOvW^qMFSz5kum9UDn{NI(^er>+<;in2ZDb4D)d wix2^Z3RF~ND*yk_WCRievRY#19RiqiF!G*02fxFE|ofBme*a literal 0 HcmV?d00001 diff --git a/assets/icons/32/MTHLNKMM.png b/assets/icons/32/MTHLNKMM.png new file mode 100644 index 0000000000000000000000000000000000000000..7e3e52f69c41d7ff0d1458680d8e781ecf1b9232 GIT binary patch literal 794 zcmV+#1LgdQP)NMsSCh)9wm7c3%JY7xobAY#r^)WT9F;9nq7!PZm6Dvhma(n*LR z=Xst{tn^HT*c=#0Kpi2+iCFC3&5zsJ-S4MLxZTVn%X@EUZ+1ig000000D#b`v;%-& z*Kgj^>(%wHj*X&7HfoI{jmGLX?}23m36gVTlheAF=XPfd}k&;lc{OVk<=g*!d9@}cQ`#*oIza~L! z5+tc2CHbdf?f=dN@xygNb1n4i-t#S1$KjC?>%r&m-2Pj!fDomAixs-iD_pnN>%-es z3CVcrOeX%n18D~U zcWiQ+1hGJZcrsd^>S_AWtki=3M!Be%g8(t;Af6pRcPjSt&&!|s77Kbuf+RRLS2DVX z*Oue_7IoTWT)0JoB+yDdPGcM}s4Z(myYkmW*AVECI`Zwd<&RIg=yTG=S@e~V)K?gxD_Z%2^ zw5I?a1c*Tg2}~%ffZ21PjSd3Dpo0X8Rls2&K|HPIHD$XB_{ubPym02?E3*K>#0f5ZgD-fGnVc05N!Cf*{`|cZGM-0RR910FZq6 Y1MK4FZY}0VumAu607*qoM6N<$f+UJ+kpKVy literal 0 HcmV?d00001 diff --git a/assets/icons/32/NETWORK.png b/assets/icons/32/NETWORK.png new file mode 100644 index 0000000000000000000000000000000000000000..b4a6068227659cc233e51818fb6fdcbcbec636a2 GIT binary patch literal 294 zcmV+>0oneEP)Wim zqMo+8AsPaNd;kj}Lh`r(6T<)lrV;M|7F-f0Ayc3%Ar$_ZH91s~A2cDrL`Z>zfg2dp zN}h>fu$KcbF6^SIJQKrU4S_Rgsg>ID$RY3n)<~ciK(gxt%m4ojGeJ!;%~j06UUbQ`@UHy8r+H07*qoM6N<$g2hU11^@s6 literal 0 HcmV?d00001 diff --git a/assets/icons/32/NEW16.png b/assets/icons/32/NEW16.png new file mode 100644 index 0000000000000000000000000000000000000000..5c0c9b2885dcbb4f9e0a011a29cb3860bf61e258 GIT binary patch literal 331 zcmV-R0kr;!P)GaHK|v5sKG<$(T*TwI(CA%VU`JA#SY4j|PLOtf$SDUM*Fw#BQ~Zh|LB5cvK3H;f5##B=nV$3!iQ zqYfBgz%=RrhEWF$Fkl*W0K=#Q1{g4ncn7fHl88+$q>BSELx7QC3(ag}WVoOp dA@BrQ3;^i8VyFmZv{?WE002ovPDHLkV1mu2f^z@> literal 0 HcmV?d00001 diff --git a/assets/icons/32/NEXT16.png b/assets/icons/32/NEXT16.png new file mode 100644 index 0000000000000000000000000000000000000000..de3575f2762c709ee274e0cfd304e3b5a4bf3261 GIT binary patch literal 689 zcmV;i0#5yjP)ILn>6nn5YRxS;|{Imq|$}@NJPk| zMjT(jWaKRP4xhrFj-KKT;at4w2}iC$l|V6spiMu9)`J65f(e4B zde|C=GJ$gT?hnEnJX!1t2)V6~SkHI5rWAiEZf_TS{X?LxX4#snF`-Q=6_BCK1*(+} zE(AKDQeZ2W#@eT86!JOwImM_GRwj^7uOJnh2H)P4XMfR8obx;VL$F4}bKe$_`7&R8 z7eZLcsChr}oAs<=WFfGgoWsx6B|xA+fa{5<`Rq?+tRZafAiX$?&Gl6Y&k9OL6ZYMy zN@`iXa9-F#DmH`djf{jZYSg(9x2?HK>sdYULOzSN*i32I1g16WjK*zixtcv#t?QyAq;RDcxJ=a@$b6kgZe^i7>Ec!* zYCcNVLatRHSAu6jF}7rz6Lqj_6M(?7p!8DGzVp6bc$EU=wGbl6ij#hCu@Uh9ksbI2 Xs3F}WdY~b{00000NkvXXu0mjf7Y8|} literal 0 HcmV?d00001 diff --git a/assets/icons/32/NEXT3D16.png b/assets/icons/32/NEXT3D16.png new file mode 100644 index 0000000000000000000000000000000000000000..3ad121a77dba2e620009cda74ed122645f8af838 GIT binary patch literal 751 zcmVvS3Y!{H+n-Qc&xRp^4fk^cbBw`Vgt(0_mP&0e*sfQAJtB1VgYe7LT zL6%WS7nKz(G}$fLq5|C=Q!{aQb=Gy)**!6{O%zzU?(FnXKR9p(&Nu%bGv68J0RKA7 zN*5X}4OA|mjLzj~@v0@j###_z=zxCP`AvUKfC2Iu8n&6XpWUs70Ex9Ab-f9DOD#Es zkSF&esBzod?rJK~*mPW(a(+R$^As?PPiI`1XR%2gZvxr3Z zfDnjg42;Y`3`bBm~j->xpW~lw$tl5CW4Qq`62zPxFrUn|~@Js$_>n_}F;s24Iz*j*PDNe(TI+y?e002ovPDHLkV1i_VPG$fA literal 0 HcmV?d00001 diff --git a/assets/icons/32/NLRCUR16.png b/assets/icons/32/NLRCUR16.png new file mode 100644 index 0000000000000000000000000000000000000000..2b86f75e58e4269dd6d118a63651360a2fecf686 GIT binary patch literal 1498 zcmV<01tt24P)F7=F&_EiKS0&{k?-)&c@f=P*ddGPN3E6XzCP{IO*}<}$NQJJ6)NEt21*Z)B;7ciyuS$^?Xu0>E<(xtV3zb%$!e-psoCssfs(KAd@j=I`C zNLZeUMGIz+qw_dey(&k{Wm(0kGj*e+6Jz z4dLdxh7MGmZ@}Qtu%PL6+TaE%vs%2Cbx!9)!)Y`MP_W!l_pT|8IE?0&`(kc;Dj8|BX99#+DPcdR`pm;+rIw9RD*#HX0p{&{Foe@*>+#FQMkops zB<}V{q0x}gSiEu`Ru|>KkQh{$f+a<*z?K7D)$xf23uA0E1A5xpJ-E}>D`@=8sPddoUyV`~9e_x`C<-x8e2q#hMCogO5`V!UNk2izwI%fBfsbPEYROKL&X5QxgovmYOQY7I{r$eHB{!;)7_3`nr*)yOh z3huNtV>n=dF2RVJ+BRXe$&`TS3v9ymJT97B-69LJ>?V<_cU`?uWR>@fvMDQI^aR#| zpfJ&3KvBud(CLB!l$|>tKUY?uy(0j3&jU~>=;-W6?X`BSSel7HuC$`5#VvSwN?K>l z2zr1pUInA514LcLhpe33kZ=xz(TF+r3^5NVDL?Rr!{=NHZgoqmNI&lPlYxLDtQXq> zS05E2MU>B=X9SR>aJJF49Y?OeKFThB_jMo|&`3l^$X|TqXU1QBh*JDi{ugU%?-G~nD$Tu@p zyPbgL6F_Fb@A`ngY-{;N?ZNJ_~nK%5~t;(h^dFYY(i@WSMoQ~{gAX_Xm0 zLO`sMHgjG2WTjAG`5qA@*1Q*ypEU!sQ*=0UrF+u%I4 zJ{);B8*i+z;;Tv*e!Ct_!-*h0x?poS^;|fBJZ-!Y#x&7^Cxz=$_}ZXfLFM0Wy!OH@ z9Nd(Rf1CSptipwV8XrVXLx;mDDNOnnz*0${h~&(Cah{Q$$#8m%`=8A);`j&i#gm@*+M=fT5OPXiI@&l*7OL=FJ9}N zQ22NSMnPi!SPFy3CyNZY{9o`sFf|2Y1ryy*6q&L3rs^JUwfn}cg?Jb|F@Km$puq`% z>=G4j3_8LZ@c4Ja6!3O5i6>g{#?quxMB9x12X0gv;*+QBH~;_u07*qoM6N<$g1nm8 A1^@s6 literal 0 HcmV?d00001 diff --git a/assets/icons/32/NLRSRC16.png b/assets/icons/32/NLRSRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..85f09c64dc3d07adab0eb7dde4ff2d68e8d49187 GIT binary patch literal 1381 zcmV-r1)BPaP)gCT|{m~j3iJxQq3!OLmToV*J?D)1XS?MhE!!=GFF8B2GynXT zZ~lK~7#;z>*^`kuYBF7AfJ+Vt_HpIm;0O1U}2vN+Lcnu7#m4`xa zkno%t5Wp&G7cI;}TAD)L3ILg&#o2J!&2Z0mOiCJ!oQWd<)w?OIP}d`yBud%-I1&Ynp-MCt4FzU(-*@4%F>)9^i~UFEo7>Wzxdj%&ED-p)p*( z8ib;76fd0zyDd$QU+D;9WHd(6xAa***;bU6c;IlDrSX%e z+c2T&QZ_x^gqOBFCAX!sdjP*(=%jt?HNf8q+Jir&!~lmVPSCsI*?c&&ty6OpdBQkh zY-|FZT?1IYY(Day%tG#h33l8cIdi5f{}Zn zC~T@Ne{KmjmleToGfxJS0xA#oH>KO`IYNkC0tj6X45H`yO*uzSfy`WMh zFjZNy>(jpOq#3BL_Nsg+dK^HBB|RN^o_y%Kj-IYgOvLOkTOGLAd|gKEbXxJux;#le z9MFp0DbWte}Z&fAAWJDH+*0HYiVU%&g4VEatE8InZpyHA%2#*Q;K`OLbFZg94x z>a#!FlGT-x1BBZ5*SLgX+RGr;FhCQ)AC{P8)r_a?fY)2Cb_n$-ASzUg4cUe3z}5JxW;z&J3Kp^cA_+J*wA zz3TJT&~tc3@cRw63;q=u=O#0DMdwGM+yw&dOxaQ0>>Cv;4CVE zYPMlE(4r#$6|fv>HGraNW3bShwiMd#ZYl1)``#Nfv$XUC$`QU~^5*^X&;S4PU-KTp zBfz0ektUBu(@20APM~CG;cnXpqwxw4L*bWO&09;im}^S6#jIrS9!V-<$|EO)hZu;u zX{^2EL6w(ojVS}Leh}#>fC7OK(@U#zP;ufCe14gob+JlmmO$w1Ah=k#%f5~=Kd=WV zkjtJ)Q=$+SCbH=o0H&1WXc!Gz#K#$LajKO9p?d+$2F2RaEipVK(gPbn$q_vpiV(oQ2P2S;dd#10oKL>4ANPR)asxf0$CN z4p9h*KzHpbns>kz8UA*0ah1Gpi+P7Y$n#WIa#Ll|oLKl0wT`o`>63P$^1mO4inEPbnO)QVl8)7M? z8z^A!=;MZ(I2QBa zV5Q1MNMgo@PrI*-8UluQKR;V5QJM!r_fyczZ1k^%M?}CfH5=)cENH^Qpr{6Db&0r8 z(}5%3*Wmc6da&GJV0qElY{x(UUWdmM7${XmR{5PVA_P{eRl06>@1+Dw2h%g+iS%ra zI7M$TpkUbwu<~SZIh{CptO9{R0O3*x1cc(6oD_vc3)1l0xmGl{IyjAmA%5Zn9s&xS z-&kUwKf(jo9i9>ptS3P7;1OpMrm%H(>VD-62BQ&4DXDxOP@=zM7Y>_ubvt<;v|j0D zugvd90|6xz|In#x`(;S|lgw$ei$LinjYfl2t6qf3bi1>Oy=MVe10-o=%JkC|Rd=y) zPtVEHt!9_cFB^V6-2jzW5&62X#8$+wYL$LW365+mag+=(z%p&t8cMN85Ckk=z5+=} zNkf##N+JTT2DG)dAT>P$goGj|%QCLEw}p%(*q@~fa=3376BMw}9gAKs=Tpg|YnCnq4oV&Uz%zOD`qyNz+wIwQ4n*d4)M z%HE4hrb;j!g5)avtcM#m7D(o_*=3+upO-fiR_mfM8CB0U_}eQ$W$zHW(+5=7sr%1V z|G5G80SOfRyD2vIb{&rfK{pxU8LvUM*Fg2M`&_`a8w!3o*MguDl5u|q+y!p0g31dv zxP7794Pf~Z$`QBQ4VQirR1&r{Vd1K8B%*F^t19NL{Gk{SkX3wp>KeLxL-jop0wD1| zA5VZ+6e?!LTDL!Kt15Qgs{tf4XZ9fgYe%k#@EPYrm7<}EFv6ISbw@$Y&dUgTooxEM zNR-8GRmGupcozs`*ag3SCRZ+n>k*YU3t@(+I}XOfcmXU>sC3wB-F{Esn`AU%!ouRO z2*?|PMhkQL9EjT69~^gr;`hMObOCD64+?s)vwHiR<2E3{`q3If@dFV=m@WB`wER@} z4B797qy9Xos(=!_+*$P@`%f502vo{Dkv{f`aVuwFd)VH=vc_jXKW??#`@%T(3V6&A l9=8EwmWr#ZnU6<}{{b@!eGTZt39x;H literal 0 HcmV?d00001 diff --git a/assets/icons/32/NLRSUC16.png b/assets/icons/32/NLRSUC16.png new file mode 100644 index 0000000000000000000000000000000000000000..16be46ca34509933f49fab7e2faa8ba2573026b1 GIT binary patch literal 1730 zcmV;z20i(SP)na6Io?G|XNzhw5!oA=H4ee<2O z1pfoR-xz7_(&_FKAcikcvU~kL$Bt06!ha#~>#fmS4{wPsJG?Ds348C7q)kkCq$OM< zAnL}!_LAWWKfE>O2!ORgOD6%$69};`Uz&~l!aMMIWp>v2Dy3rtLf-?yt@V4HD;e>y zEkJ=B_DmWTg|IM@O;-T0rX<^7Ht7)`XMRGd772tN1TYm8?;qY0!(Ac`TLDT=5JG3N z`LadhQCZ!Jh;SWJlcV|f+=&U?0@-XqKeEqv76%Jn&Ej)eR`KiU0E=UTTHw(7Jd-!f zdz?}%(^d$GK=?v|>WHk4edVt#8#MZ$f_sWO#Bwh-8b72?%G1jf;c9XapgMQK+Q}psq)cJveoy z9Oo`na^`-E^oJ;tz;pg98CWnc3nrsJv;ssFn%L9ra)DBfDMOFX2d~G&%qNrX#M2Q* zQ!J%)9R-|q4IOw;*Ussf&zaf%U{*>^(K4d5(~E+lyC^EY50~4E!DC?4%rXEu35iL_ zo|FSsQBZch6wa0wra&bKzGImIm0U6C?FT`TGkr=T#%0Cv{oS4(R8_a}6SH)DQXg=> z#E#nfc2+!O7KkdPg(0&*rNT-=)Z&J^T5CgHZ9fx{bO2v)-37p_#3Rbofy}hn00|2? z=JWnwsmfVMV#c~Jn`=V4fZ>w^mu^Uu=7P|p6!b0|{%_$C5y%=h9_d+QpbHCwqMD#L zB%-ve4kvyo!PVS%4jlS-onLT>B->g?8F}h`SAIC2$$+0K=W&IQWWOAoQ8{+t6{Hh}BrUc}RI;(mq6%bo8`b~p9#*amfsAveP7r`_X9mD=-6r{m1R$jFV*Ndh=;|;xMPz78~c0QgLtg*1#KGbIP YFYJVghS5mFvH$=807*qoM6N<$f)STD<^TWy literal 0 HcmV?d00001 diff --git a/assets/icons/32/OBS16.png b/assets/icons/32/OBS16.png new file mode 100644 index 0000000000000000000000000000000000000000..151c34f466c7a05a75bc327f3b8dec6785f6ddc7 GIT binary patch literal 782 zcmV+p1M&QcP)Hw7=i?eB*c(>smERf zU!oVK8XEn5kX|a#%F;58nmKZAclV1kHOk!F?zTqsgUffmd(ZEj-~I0QopXWz9prL( z1zNV5g*a`g~nlA{?2MgQ$a$I#ynQIwp0Arxz0v08ld~2OyC17D6A~aH#bw_RNyL=bj2pKnkPS%4GUQ|l&#pPsv0wk;6^MtPHfNm#u^$i` z5ymd`J$dw31oX656-t`v7Jx&11o#pH=xucls$ol0OTRCWF##TrOO_UvhX6QLs})7X zC5S{Kn0oUX;ZVpORF>K8M8@`j-5+Y?WxFS-?$Kk-DTT4Fjmj-J)R6_W1uF&)@su{~l&@%o?`VH~FT5 zh6Q+BkPDQ2uKRAgs-U*q0ab}#&w^ncqp#+%7>tS-{1l!$+2w;~s1g<^`PVtQs+dq+ zwr$ho4E9;^HSyHF8UslS@YXxr08Ys!ioSV{CGlRyzRY1R$5@Spqy&(T-8`1&+hJFe zZ=}p&?ys>Vga7}Av7Rd-%aF1yKsG{p@!?zaN(ZvC0spF literal 0 HcmV?d00001 diff --git a/assets/icons/32/OBSMM.png b/assets/icons/32/OBSMM.png new file mode 100644 index 0000000000000000000000000000000000000000..a77cc2719d0bdb53d61d7c78e66079ea417fcd39 GIT binary patch literal 969 zcmeAS@N?(olHy`uVBq!ia0vp^CxFEaktG3V`_``#jfBJ3ZE z%f-7lL>+x~_I}bY0WsHC&cF4)T$;U?^_zf(#>-}fCjIEPzZIDaxBp`PC47fN>ks=K zncA=Jflm8Ub{9W7_vV?tM4IaRxyGOWHt1MSTW?$9+!XPxq~^oIq&ioxRKEC!v5&6&Jt;o_-t8{l z2?}AleZ2f3D>kjU^wK9k-hOLoiO^_DGOe#I@w&;Ua8m2k z+zV45XT{sc?yhUrOWQmpH*4AKX6Gxn?ycLuU+VJHFUq$I)g*bexY^OF|^DxGSZv(4G3b?v8bXJQ1ag(h!c zH(WDICb(3kecILHJv$Rbz9}sGIkoxSm$*gKKBqhR{`~jayjG)j_1U?0Zv_(NwK^)} zo^s5VaX)q~xb%U&LlXmwL(`1y!PPljuMb4z>&5I{gJ+f*4ym{UD4l zo%fnO-sg7zSnOZY)B$2B0~v4;DC5iQ60o)}opwjNob#iP$mc#1Qkg#c?3$e`E7eR_ zh3s(4I^0B#`|<1eKSA&NGC^6Z=AHSLzhqWa@m}5QB`#H; zFL73V7P`3Y>W}L!>+9bLw|G?U&7HkFKhQZjc!gy3Zu^(*n`35Ye`o7_e|B{WP=)`- zRjIab&RUw7JyAZWIr;AF@Xq-EGt@a696baY7=SoJmE*TE(wg`rSHioZn{Q2akL1d*?gnd*{tPXMmj! zayp&zj6ZlCgl+<3#6a9ImTJUE>k7cbtOJXyjrz+`Y}U zITHYi9p}YXvmYjt>DO(u#e#j6Rk|G|tu2v&02}_f`SkJ&sJzPZ-(Pd{o)Dz_{0p)W z7~x^$9et3N073Kuzy<#1Rkmsnt+xqH)8PL!tJ?;mxTitl(J2IO=%X|Z7=+2o1^l+S zh>6FKFhA$l6Z^);u(G_&E>poG)0237LKZN5>1c}}8YM!>mPa2UQOCf|XK!;VfH8cz zzC^^7K7yzxKoh`IHLQ9P^#Ddj0z4CsMPitEw}j=8F2egYvUt|zgO*k&EK^Evb8=NNpt*YY zw#ganv+ir)tz#nwQWoH8w>kivmkp%9d7&x!S;oH1VJ^qmh=r5{Pz(oowUt_6QBxnJ z%wg{Dv80rvFgb(6yOk>;&yeyhKu(7={pGuUWdnJsfPe@I!Z>e!0G{jQ*uyOPwRa7Fsm;Lb3!OX0itpWsyW5mX^fnqI)&j8}41>5>2Mg z1^Q+}A`d*c2NOrKgoni~4AiPasg$)Vr7c)W|J{4cSN^OQ+QF7$V#4p~-tTwr`JMB9 z=R4;DM>xWN0Qa!(^uWk~t{TS=TioUMoh70lBWt;dfzdZwcJu5o#XbI>ZiVqXl3r(Y z_PHU+JVe9>r-#1_9r_Nmz1L?eF+Ry9ZghCtAjy)*w;K%8r-SFt9BKdqBLh0AP#kAK zr}bnj8jSiKjsY#{aB9-!_r1OKUVpg!-Y>z}`z^<Xs**^dAaTZ zxc$D1#Bi<2VS@EktA;CP@_2M_396#TBx3#H;LJi@kDz1NdxjW&E}IOnblEkWQcw_| zjY3tF5@Q$=;$ofGwc-imlH8!Pd)vUI3fBZA=AuyYB{0H;#nJn>w<%r^ar+0Sj0)ou zk|ed*cPjodR(^{kzm@|7eYzN&9joN{lN@&p`(Aekd=s_0n1JBqtTYaw+x(&(vgvWf z3#|Q}!g_2?6y41iJeJG5zvs0a_m7^tZ1Pwp33zipoVs4iZhj&42?INO%ws`Qt4YIc ztYoqJS5iEN3XRIp)Rn2y?(bQ(jPf4yRnGZ`;(a9)-^_sM%2IIl<4Rjs!22%1t~c6@ zu=O}Kev0b_Jh~eZ6`z14^+#^pdr&O_zWXdUoTiCwaRF{D2K@1mB z@s=(J#u9ICk8! zXI-2-5rwweZ2BMp@M?<^na=}sJ2js`b~&Tr43@?{;>BzciCkL4ns5$vFbu0Zc4K>ZA0l^6e(A~y_)<2v*J1ls+* sFL6+SIGO-9)!EVVZM6Y&g#Q)(1+jOvK%`v3QUCw|07*qoM6N<$f|8mD-T(jq literal 0 HcmV?d00001 diff --git a/assets/icons/32/OPEN16.png b/assets/icons/32/OPEN16.png new file mode 100644 index 0000000000000000000000000000000000000000..59b2f494f5029c499a6eeef91e3ea7cdf8ed5210 GIT binary patch literal 748 zcmV?wQ* zA)<$%-b4}_xuL^3)F$RKw`l%d(Xj1)aW`+e>!wWa@WFm?x##=NcfQ~6JLlYUF0j`@ zJ56A*HeDge*NDijn5*s}GrJk0H#j=@wjctk>dsmW!q5XiA>It`q@27l85j!cCZO7O zt`YJOkCXrVfCW!~o;j#HiL&R|~x>$&W+9w$P zasQwv?-?MlgHzmyu9!`CH;XmMhD8>MN`QSmp35lWa>#UX zy1zfZS!^KS4ifRh4Mh++)%`#yFdPnt6rTGz1dvU!8Thht$aGp2PikOacO8HIwv;tV zS!oewBC(1)oj;V_oHs1>=k0>!k7-M^O!z;&QTs@3JZ(3p7brKzWKi>VMO0fGT`X|; z^N6Qqywq9+>uoH_--y#6z$pGcC1iGNDGnz4j0=o=J>$uhNq##7ykF%dy0=o>c=LJYxty$^*gSrxS zwVS617;fu~w&WBL4y|47v88!k1rSgPW}|9L*@C8Cl&Oj@`NJ11)6=e0iVMGam zfdVWrMq0%Lx>z`?qX31^#4x~sX~a8#1y>yL@(a<_;;AJf_Zb-&E}%Hz!`oMI_UDi9 zXzBn)1_lKN1_lKb2Rwgt2TV&#@iSPO%G1p9=Py1n96k8}gS z^!X=*@t^S^6SfeL5a(r}C3x}bGt_>@15C*A|LyB11~xVp1|b1Xnpytm&p(E@Z@+@s zTwI(82hhv+FJFIQ`1k)mIQ|nGAAVp$kADd<8VCQ&&+zyMQA`6F|0oU^i1Gyhlo`&`up@DXKce#gef#y<=s02T%^fRZ$S?A@myWuCowX#*9y z!TkHbFR7M;09hdb0`c+r0)JQ;b~7+A2(U0SxPo#Exn_-mQ7{Td!N>*xk8g*m+C|om P00000NkvXXu0mjfLprks literal 0 HcmV?d00001 diff --git a/assets/icons/32/OVRHD16.png b/assets/icons/32/OVRHD16.png new file mode 100644 index 0000000000000000000000000000000000000000..e56ba46046d6396f0c28cd3a8bf876d3a6058df3 GIT binary patch literal 258 zcmV+d0sa1oP)>25?Gl8HfQf|60}VXNG>Hr6+>Q54S7bR6atIO*M#!tW<>g`& zfCw4S+s#@s1E#Zi=L!L$K~1FXFX&z7v2r|}-!|~25*OZM6`o5eG0?DsT~ZE3QIy}~4$E*e)}h+jUH||907*qo IM6N<$g0CZNod5s; literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXACPBACK16.png b/assets/icons/32/OXACPBACK16.png new file mode 100644 index 0000000000000000000000000000000000000000..5d5cce57cf112596a8083ad0ddfc4dae38ec3221 GIT binary patch literal 459 zcmV;+0W|)JP)TzRy9G9YOYurr6o9IDVFRuN}3jV zDBg@L_?u8BzM~0Wp_;oLIsw0#r>I`hGEPwr$V>8cTv}xzDfHg+-%e> z7dc5vPafE6$URf(2GWvA`Dab2I~B?%rE~*!^i7JIyG99$@RF1rlzE_&loM$}rmB$F zq$Jr7%O<4`MR-k0T~z~KlagV~=&A}$?7v{jly8&sdrrKSvm*ci002ovPDHLkV1f`* B%_aZ< literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXACPFEWER16.png b/assets/icons/32/OXACPFEWER16.png new file mode 100644 index 0000000000000000000000000000000000000000..dbbe063c648985e60645ce4d8fc6cf331bfb0065 GIT binary patch literal 295 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJcb+beAr*6y6C_?XZ1i+{Wv?mq zYMxE6kI)FVxwcD zjx@*YZutYBEOi9k>MPp9g;%Poa&P2HwhJ)-I{8flgOT^Cg~38XOjD*!F*)DneL_c5 za^+J7Q(57Hyu_5WFqNfCQWi~PKB22Q6X;5Vz|#sv-d=8Ay34jKNl9EFq_BNS%0jsG khJe!x6r;s^ngSUZbShnV7H{hG0{Wc6)78&qol`;+0CJFLi2wiq literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXACPFWD16.png b/assets/icons/32/OXACPFWD16.png new file mode 100644 index 0000000000000000000000000000000000000000..b4ff8ad837e73ac32c65c4ef26a616eb1fef6143 GIT binary patch literal 427 zcmV;c0aX5pP)YU6vn@k-qFFi38ITGnmP!M^$qN<&^n4Z2nr5j(aBeEDuIp;K7iohqTpbSh&r{U z366b%dL&9fG^Y1YY*qS$47vB_obM*z{Q~@VoQk_$tQN(0^K|IsS*759CnQAy4Dbyz z)&tMK{5&s^5q7z-lspsdkLHQ^!mhZ-f@!biHM(B}lqT}24Nlu(>O2vjr%NP3z($XF z*;gyEOkr_SAzO%nCIL##BLeUCD1O~ZSQs*v>_VO0 zOV&*%Hfe0am2Q~&kZMv2*@dfJvtw#3pk$bozt)68cA;rf8Vl%0Y*KX8gc33$O3Al^ zx!lxaVBv=;% zrLVK<7#z!}PFTQjx#6Y_*Mf$LjUEnJzZ-6RV*(ksOz?d}AOpjOi(<1AWEpIM7BhId L`njxgN@xNA=(RaM literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXACPMORE16.png b/assets/icons/32/OXACPMORE16.png new file mode 100644 index 0000000000000000000000000000000000000000..2e5364adf3e6738db433a9eed4067231061f5813 GIT binary patch literal 360 zcmV-u0hj)XP)1{>g$%jL3W@h5-gFO)^q=U5pOuo;*YG0WKitpn}4Gbl?tFbxaHc3|L@{ z068hV3O77@Mpm2?QqRONSVCX}4j&Q=(BqugG{Hiw1xo~=QS^i|hoS=(VpFx603^4l z>zgawym;~fwH&}itit~c3{TobfkA;`AVQ!CT2d~7@}u59zRxIw zRA%gXgQ9+xiwFZLbpZ>pE{*v>-PBLA0|H1aDRIR)I$&ZLV8BAGLSjow^f;!P187xJ zGBQvJsOgx1a|R9{WC8%momiPZB1TgH0000y!ALDOh8#*;=GiQ7wWJ#bbp{sVsW;0;M_yw%vmqt_lxy!7J1 zcqxg8HdIYbH5H>)N|6f@qH!s*JIzq2P?lv`hxF24LUwoNnRlMqdFNdSdc>o<;X%gq zsLp5w`?P2Grjj`$9qGm7Q@4i4K=tPUaqwpb6eMV)=JD;zApl;7(}{58Dy}Fa^{%jyUasFn2YjZ1XVY0r z20R`|E?+E_N~-Gk@;QZ)s@A(!jr0_PxjB(2F@}fy{>{QXKD=M5wiBJjOy9t)#T9lU zpiD-l-|F&(qv@6Xa(Rfi6*pY-AM?J!fHD?YOT=C`>WS4PobhaJQEGXyZ4#bPCP#?Q zUV;2uSQ88tM#<=UA~v^e02VoY{$kZAk))HKmKIv}GpNLeG+j!9!0kMA98#aFsbAap z1NG+*ZsNB@wM*X<6Dz#k*r}m;tP+4{cnd)#?$vaOuiWiC>_>m#oN*8;LCt5}TpLv4 z+(b@D5^6fV0|I~F!6WGRpKYt-eO$w})iLPe6tr7?t@9YaI6Pi}nCvPcTbhP3a;J&w zNjg(|zLsD6M*Ph+WA0Z9sRL(V2idCdMxpaDEvA>Nzn&O~npDcKk_)MBW@V^=k(XT= zFk@VMhg0bn)<0Ga$X11-Dy3}$Rx2ek-5DhiM5jvG4l2q3uatJiQS35QR3OtzX+G}% z*shedB)ne8ng-o@Ol1hdN~JVH7G=Qhe@cp7Miv#wZl$E64D7K7Y_bU~|Hq*bMkSa4 O0000EI7@sSgFZ--r*0 zq26e^%0MrHjQY=l(<9o}>0^GLu-c$n-!qLX#4DMd{2bA6_M~!3A&hC;@ykMaWK}?W zN6*J?p^A!@tMijYe!My4S5qX8326J$fH8R=iER`W4vR4Gt!XY=0U^u052wyxSrfGJaQdph%;u*D5SH1wX z3{IJ$>~Ddz6-c^tO4kD1I%P2kl5l!W6nm2t?MJ*hLXfsq@e+4rQ2E_+W?-~k6U a1_q{s1}DCKV08p~mBG{1&t;ucLK6V=1!t51 literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXBOLD16.png b/assets/icons/32/OXBOLD16.png new file mode 100644 index 0000000000000000000000000000000000000000..6f9e6cfc1c82a26dcd7712667b5a69658f1a88ac GIT binary patch literal 629 zcmV-*0*d{KP)!lC`z4hSHB1NJ9fHw~!_z#HQdk_zzpwJ%n z=%Iy(XcIKVfH65Fpy(lmBB`{tnI}^{bi2E0RyWy${*LqBy!mGK+cyLJ>rhZYKRdGs zDQ8{D#7#)N^sgkk_4n(gumZHe$gjn392{b%K9U)F-g0&ly9@0~Wphvg0?{&eym##F zMBcXI5&!}+lI1Jiv~I>CKtV(r829!3^pirNp#7N#2wkvew8hMie6q7dbj_#8)z6*p zj{!KL1+e4|B9G%*javDxUw&@VazI!jAm!eNwE77Uh=@k5^fbXVA9kKVgplCv*aYat z^lVS^!?5$TFv-jq&zZKXIVp%a%gnd--S2@uL?(a;XTbiu^f9dZiHbkQk}D(c1HXB9 zI-R`OUR&FaOTg5Zjjd(Fu*c&PpqSegT+Nx*B}Cx?1b0H^fee7_o^fD|8OsyrE|~So z>(*ZjXasaZMRwADE=Vo`|o;sx;jAKzFy3xTfaw4K{(&w3|L-rD27#YYIhv;d z8M~&_3=9k=Ow23{|Ns97JA#3Mam|xMwV||f024BYneneL0|Uc>e}DhLE&s{*Cy{~P zK+?WmMBct$fbJHLNWh3LFj^8aj+TV~MoU75(UNdv0Y-Fz(UOpHv?TmDS`sphmV^xS Z1OT{f{oyxOyEy;=002ovPDHLkV1mhFisS$Q literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXCLRFMT16.png b/assets/icons/32/OXCLRFMT16.png new file mode 100644 index 0000000000000000000000000000000000000000..d196ba8f845dcac86b355d2a67541d3e2b580e1c GIT binary patch literal 845 zcmV-T1G4;yP)^grH5Ez#zdO zXwyQN2ByZ0VaiN2T3F-BqOviiTJ$-LJxbvl>Z8|XU-ktOA|98*5_kZ65{>MKK zD)j-6x22cBPWN%=lTav>+%JGuN^-ro`8ETO8H9z^L@j`O`vnlCBul0{)-_4oI<4!~ zhXzpZ^|cV;tldCxRjhMdB9#bHy{GyF!RL z$ueT)Xi_^fJw5*IKq`==^)6c+h;P<7Ue0`;7zbbrCPlJuFXBZ3fH=Lx&%cL48zv0V zQ>&4Io&y1>JKuT=z!f{0`I&t!#IVf>)Os5I9c2d~aH_P7pR-@0Z>-zdPw(d#2-|fJ`et!7jPo#Hnc@#*IflpSzG?OuyhN3ZOpQdck(dtvIS}jsh^(MBoTqmn&s# zvb{O&nar5deQvQ;8Tok0_b@fC9O3aANo*fJ`65sS^z9x?3|=BeXJaHflP$iz#X-W( zpd@Ih>D`9`D#dzL;UHkh3AoaF%7(}mH**;A3f3+v0qV~A0)qHeF@A5rYQGbUgAUZF zAVif|Q;D|knYfkXaPtk8&$em+6CxEB1wLh2j77D|f zjYW9h0i0BK0_eN47DcQP3{S5dLPG*5J*Xx88z;T0BHgg$Nb&Jv{aad;?#?2k;FPDp=@Aa`30*P*2`^QBQ>m zO-7<55m9h6F;(by+6g=JeLK7Ru>qD?FsO_oPJ8DNaol+en1|!rtCL?B;Iuq3nLi!{ zUve@2`xZ2P-(Go~J_E3mSO~}Wcfrw5^I0pP@igtEsRBVQB;a=;lKig<&wMv;zV; z$OAerQiF?bbo6~Odi|A~eVgTbsa0Zrex1=!6# zi23zX321z>U#n(*{jyvvz<$*oAf^4P1h^&GuS&qY1pC#Vfv(nmRUMEL?6+_SoK3F> uf!cnJ-h@s`uix*$STLxnACM*fEM5Vc%V<<>0g4F#0000YY;r%Jzyfk2CwPAyqWZfq^OJZ{+eg4in*l49t-K z`GOw-s`txVM+k3Yj7p?$fwfo7gK*@u&8hfj{Ptk2*)Q)V(XRmz)_txkelgSXml?JHewWWd_5W(m~(eFv0uxUm7)uzX!} ya`vmN#f=RFRaV5SitGO`5ba&js&)BDL!n-j+LL8^ZN&6N8$L z$^ZWh3=dEw7#S|yzI-MSpI)kl03!o~0t)`m5TLGau0V4Kd=v6xU}R=iM8*sZ3{QyB z%R*QQap2~~lMj&jsyZfrh{>052fVnji&}0W2@HHLAh!gg7NDx-YC6Um{~4Jq7#J8B z82|sD&%nUI@c%zUDFYMZ8^-_tPTab3_6E8hswF}O1_lOB=07jK|6y%rU}TVii7_%V zbpQYV{|zVeA60C6sG0^YUcC5$k?DUSx;P^PL*d1X7e8RrLzDPd(=l1iz`zg!vEl!o zTbIwe;!;bST)_T6li@$Z2L=X)A1r@aGihQ6A)u;jnxL+0Tr(h+!+^cLJ;6jyavGpk z3kn7Xz9b}9Be^Xo7=X2;hHeN@(t<(;10DjS4j?-XP^$$s;2|&y0DD+jqqt~kI{*Lx M07*qoM6N<$g3F4ii~s-t literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXMATRSRC16.png b/assets/icons/32/OXMATRSRC16.png new file mode 100644 index 0000000000000000000000000000000000000000..8b66a95578507bb6d892f9ccd236098b368e577c GIT binary patch literal 183 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJI!_nJkcv6U2@p$E&c*Nj9Lu*8p-5@6JqqD9O|_W!l%n>bxp}5!WWKp5K|cq2&NO*XgRFuf~Qv1_@H742M0+ g86J1&bGkD!==4g7DFnS$1G4e-7=3SMAStf6BEo@z-4sGfEe2V%W6KC_9{q`+8@6CKO-#5SogNsCx4Z9ZRYKRT&s4Vht zF%6hSB8XGubz^S>z~`6-)M+0rOd3;ssR6=Pu|-ccpu@ylggNVvJ9l^GJi-T09`TQR z;G$Mw^#T_Jb(*4sBJ!Bpdctybi7S##9{JRgsSo5u6uyL7dnOyB`YoG~6hBOM$8= zavL=TPW1Cyd}^x$!J!MiG2BS#qFqeXED-s-9uRE>jB%T%kyxauvqLoUhyrdq|Be)+*vIxdb`3HyyE)wfo`%eM6 z(=?)fS>#7C4VXnjAf3k5s`u(PfTLFLgobXLkY{xY$cLA=^2dk>E+eySXg+y;+-%7A z)!RWIk&j`|i9QUmhn6lYf<{eDoQWDIBKku^j4_*m zWNOgqj6t3HV_p`e1}{O`$RLPpfdNH|g?5Fuz@$Cq{d!K*mKM&!)HgYO;rpKVd7tn0 zp6>wvvvG1jnU;n!KET(2<1B)JT#iFJwF?659EWod1Z#i~wEt;s?76H0OqQlfK@ge% z?2yUV!ExNdG3&w3RS7U#8kBy4e*@s^!`qYAX>sFC+mWB2!~P!}9LD$G{esyUPZWdD zs^9`oj#wM#FIj-W(x6={C{6&VT(c$-8m$^GryD7{WYpGGL!(hg;JscS-fR0TgzgrtJ{8bKXW3;*mpytjhM#%F#ZmYg|Npdo3qdvkAmSQNDIEafl zWef1LX%8mffB&r*9=5U36qn>9Bf}7vg!%|WSc;)oNrcF`vH+8%sgl;5rv3Iic0;97 zqW8=I>$~>4Ez5C4U?_%SiG#R^GswMy03o>BaeZYu3fLuYHGC-6Sy^BXo?3ArX=rC8!3PU04G#1`NW_-n`) zmuy5rf`WC}CmhUY8PjA7kg!rLaS>;Dj+g?#aTapf*~Uk z5nF(OTynIAl1arSDM=$+fP@V%Od(D&M{EIHu(pRM6N`zsljWI&m0}|}#T+p!q49>7 z1pEhP`{4yH-V)gV_3UwSB(Pt4r2^@9-F*vk^USQNwdEM5r(CFi^gda2fNXmD0*<%6 ziHgjAl$vG$?@+LPJ_QbM>SF#jL)qiaj-D7ZAXv$rKW__l=u(nJQkT3D1{RPs{yH8i z{t%_Qo=|c!z0!pO{aGUq;q>9BQV+e`U{*#5Q1FU&@_oI3U~$pUI?~13KW>|pl^op< zVvYS{C=@)33er%us}P$jHlcj`ChXl)#M-Ej+>`%9X{VYe(gHL zIL+oP=7)wxR~9h%8sO@NRX-2wtOvRyxCm9^| zSl^eJvx~W_vh~d8W+`yw*<|)Sy-$PYC)VMfohqo69Fo*r1eRV>tG<%qo8T7CcJAX*ybT&S{q~XBXUa`0}gY;r9m+0Jk~z!d!w; zZ5IR_Cc={)=U9SRdq7G~7{XEv#jaWanOdtkK*!hPU0|c5DV}!v*lw4M+Nh5(gcW13 z>LrkjYCDxzs&LEUXylaqfyNQ`*>>3kNG9$H`lh6l6D$${ePDD1z_mudj{gDFZ6a~h SgxCcD0000@`CMF@pnre|-``HyyBndH)8;KUR$W0It(n4B@fk7?$ zb5-Ob5*tNFnh_Txg-{AjB)KT9nen|7_tFe5a(?c-rVlRM^SI}Hhx5++&V7Ue5NT;T zN8kauXV7_1aPoe>F@!GpYro$`%$+C@E?vj+#Bvu12jrd^A%l%koj9c9G~Mj02k0FL zrC|I5cwgh#RJ5Q3Y7X7tTpSEAZds$K=OtzL8+-7Cwy%4BVdOeF+5_!8mnM%=Ii6E3 z9PI(qdu-jq6^U;+JM%*AlfsR`-2qgVR{iyCEc_~`1Vrw+0&Y90mW06;%B-I#6s~+S zj{$fpcHo5l0fKE@irz)QIE*EfXeS`@br=v02veonmvbD~tO?bax*#2=sNYwSNYW&L zZPI3--xCaV=)@8_PW5l576s@yGk!>$fD4h9rjDXjAcg6c{bv9SDua2Ig>lgHc48dG zm<1Az!O#N+ZYzVx1-72e_?t{PS%I1?3Mm_~#~O#1zox~h+h~QAC3H$51qy^Dx@q|E zh02sIRWe{tJ3kH03<@dHx8lXs**hq);%Ku!B2w3m=*Bu^(-{GWusOb%R!IpruR2?S zSO$e`<@AKCM4El42zaPIK>#+W z*BhMd$|r{SpXAyJI7P0NfRp4Bl#lY|(s0@CfZ7#kEwJ13)&X;k^2xhk_e@Wke7Nce zhPIr9sc{F?s({;0syko`yS~52)|CY~0m`)pnmLBcRv4R*NDrY$Vy9YbC*MEofiW_1 z(RCD~qFUMVb)2?m(QA#MjX$9p%g_PoIH^yOs86;>>RD0$jy+>jk2kov0l-Tg|F!rH XmNW;;Y8Eli00000NkvXXu0mjfoh45) literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXRPTEDT16.png b/assets/icons/32/OXRPTEDT16.png new file mode 100644 index 0000000000000000000000000000000000000000..e223d098e4f7db9f6ab3d0b18bc64a3fb7146f6e GIT binary patch literal 720 zcmV;>0x$iEP)y zOK1~O6o&tqOhS@2OPgYbYTQnf~#&61Q$ZIpr{}y ziWKTAx(Rg=q7WnkJbsuaSFcFio4sOeR6_hvb~OGtBqT$+>3&{O@84 z$%%7LaXk%4yvH8$rP6TL$F5t8N*Iu<1(k*ykZOV{HE{dJbxG8Tn|HAKdrKtw=dL542hb5cflrr%A zB{XWa-j;Tr53YDf=c_#}FRZZJZO0twh??xg2P{`S#5S_v@X zE5$27;BT&tfLRG_f)lm08DTKBL$Mxk6jiDKkN7`r3D2g}c>m-+qTvuZB(H0`VsoHY z_)>`e<6Bg*D%ylxEl<`cI60`h2kLuRDqM{uheW{e{=?9q~!BC_`M$y4F?em zhmef_qHw=u5NWMp5%_}Y1{l1Ch@qP401UsEX`KJ;-LNjG4Vd5F4_?zYx6fh>SGory z1z0NAkLDb>dZ;9{%)ZptGIwz|U2%6^cekCG+kVKZ)a-{Z^@lU}+%vWjw8R4-T76)7Zkt>P5(#kW{8?F9jTbIsa>^bx1Q!`d zTa_vcfMFOqs+3ANU9NRMJ-(-hj-UQ(2nKOd`R+2LYBiD@gwQQ3fKn--a!DI2_Ie=Za0YP`o`u6ug2^)jjG?2tdt=!xSJ= zb+zY0zKfr&1kjWafTea$x_d0-6H(kN8{o?I+lWSnBm3#7njC^B5EFr&^;^@`C%dhV zgzbX)vJAY0XWEJ+p23Q=WDpPq;YkJLRKO5;l4vyC^MH=Ig&L@}Jo-B=OD+S0ILc`= zsUg^xg%Ao`Yn~K4!HE=uZa64(GeXN3QU$$=n!*Xz^6@YQP3Pi=O zV;yGOV%IZBkZh{Fd9%gKFDW5CAZc2W30}yC#y#FEc!XBj0I^C0!C+sB+gW1AO3rZW;z6MvW(jX#t{OpJj9vW3kUheYs_=#2i5M7vCF z!q5pgvIc`nm;p3s_(SxEc)>7>mj+Rs>tJHHu3fv8w&xu4erMgQsC83-x*laK$3v zalfkTpk2NFmu?@9)hE0 z1(|E~q=Pq_fFxDm@yFV9lMsuke&fATkEf=luJuC2Gf95~?nSr>tU!H=K^Pj_yD=h*w${nPdvrUeus_k;30YB4ciT!-)Jmu{+Yn8}a;}eF zieT#e6=p&Z)&>U8UMQ;!Dd!Y+dt(iAPPlK?-ROIu2iMtZm#we7-VR&6otcp3SI8(? z1EF{br~PNZ3p@*ZChm3Ji9;K9W8lXRG3@^$>)DEC2VxTulE=oD?w0K(M_?=xV58L` zEz3EfLbT$!d%Cdi;WyD(t@R9oU=d-dvQqA?;h1TiSV-N4;5ils&O=js0o>|bjf0PR z;Pnk-$ae&?B15#9adjpR9!gXBZ$#YNv|gPD+%IPlXaIP}YL7WM__vq>ak2{NN1 zsz#O(*z)8~-6ZOGCxXhqtjW~e;#|1@-S`OlzTJzj-WflMc002ovPDHLkV1nQ47Zv~j literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXSPOTLT16.png b/assets/icons/32/OXSPOTLT16.png new file mode 100644 index 0000000000000000000000000000000000000000..180ea010beffe46b08a7e864b924f6499450db70 GIT binary patch literal 616 zcmV-u0+;=XP)ix z3>Qx9VPW|DcY1w2gK1+U!yl47z<>t+|A&M?thXrG0(_RIgeou?+jubW@(VFAFftm5 zeHAWXpd=B_1jRoS<8^ipPKNk`cA^b=eD4Os_Ej@L&i}&5%%Ypw`SJl-A@Bzp|B`Yl z45R>AB@G5;O(T$hco_cvnM{gaCKL`MgFT3rBGCaLVC53X01CPP42(WgibX@na=`!p zdkX=ueDCZzyk%0SBo z;vMjZ%=kwK_MYJ+l?_bPh<{`tC@Kjq8yFZFU}XafQ4aV|LHwfwQpyGZg~BE8um&A1cK^Ib{PAHRGS0vVjpqOe+z249YqTGz9+{7#?Kzyir6K zXMxgZXzc(IacPA=ZzlYQTPza8h*BB-d9wsANe=*X01LW=LeM?341BOoi7b6g3h?63}i@i<&0000}I3%(7Eu(})E`N^&`-TPFJ=@q{@XmOV_jm>K1qSY22RgF( a85ln76rR3s-%TKkfx*+&&t;ucLK6T3g+Cbp literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXTABMG16.png b/assets/icons/32/OXTABMG16.png new file mode 100644 index 0000000000000000000000000000000000000000..dba2b57436415042e0114779a80c89df1998e17e GIT binary patch literal 413 zcmV;O0b>4%P)&x0(3)@|BBmOdti0R~K?4qzDR4qzcx zp-IRTqSVRQH4#;wJULXyIJ80l2C8bZD6+7vWf}^fiD7^N(};Hf3#l41U4<#Ku&rgV zhrl|tTJ7c6R}9a;JZE4Ky}`i1{+{96&te8Hb}rgE00yqTxz4cd_I8F}e}6#)co`TN zehO37au8s_*OHNm*IU5A$Pf<~_%6yoZNP*}LOxzcgMpF39Yyd5og5$^ucPsok!e2z z1A_zu1H%i3{|pPk&Bq_Yw0D4fyq3gYMyB;J%bEZGb9}P!QUb$k69$HVEVOliJlJv; zkk2(37#O~QEPuH0$_=pOXL+hyj^Thm3@iyS%NZFNJmHqp5HKNgo-Vx9!SJ7<6J+`0 z`In9`&;hWZ3p`nPse&FB<8%NaAZy>uKuy3zRntZR1L*(&_Mljge;>M)00000NkvXX Hu0mjfzC5j& literal 0 HcmV?d00001 diff --git a/assets/icons/32/OXTABVT16.png b/assets/icons/32/OXTABVT16.png new file mode 100644 index 0000000000000000000000000000000000000000..87ebe3f96dae67af8c075e9ca14ea9cf58e15b4e GIT binary patch literal 183 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJI!_nJkcv6U2@)?G1dmPFnElJY zkI|p+s$tNg`JIUkjNH2%LVd*orEW(pOB7WPwHH3jz`RWGJ%d4W`qNDT$ zJe7V$4!Z01SINLAeFEx4F$IKYme82SP-O!wx#p{ZSs-RIMH}!yz-NRu0BzvE7@%P{ zXKyW0U?K(tq3Wy|$i`OFnPGy))dVb_h?lRyj3X`3q#AGfMq?t0ytNl%|v%9 z!`mqTE|Ks;{`0$G6Vs0ObQFVfKCh~)(a@m8;`SL&a?r=a3H{02Q1b%-IBRSL$cTaf O0000J%=P)6kizRC#Gjf4vJj>gb;G zMl|dv7esa!6sO~>!qUp8sfmbtP{~N>!syz z!kvR0-H}<;7T+}B>nEtS0RSi^lOxT(aQVr}Au|-JyyaJxGI~b5DZ-6?Ii(`R zSCTCfJ5=B1c=)|}T&e_!5bNei7*(${k5WP2T$yVUrUhG?LZN1iVMb)&`84y%){!r3 z5&>aaI8Gq-MuQf)dX4OhM8Y*|nSwg$P?W7hfk`Vnh^YF41$;_UaMhBPuHd;+k;GCC zWMM$1F+&B*)+~9v_3an}AweQ*5y3i$QBOz+bvAamr(y>!ZGh=1@H10#^?*gI^1^ z;i;voBEpW%M&#+$^7XJYfbJm|q87O%=pJ_Avoj!>J`mMf+s5xo z7fEZw%x$}|Vb8(&B3zC+pUBwdQ?ukr6>$I2V+_1}CflYAm3;ODBbfAum-slMvc>mt zze-$S&X>;tuLmmMXp}5ni4S95w7;|C`FlJ1M%=Pb0t4H5+foqiPat+@S}hvtPGG`0 ziIJ`jyts4^N?w82!&9((rop7J6AAsJUf%8r$zx$*M(yVV<Ax9{fX;19(6FY++zvC}(7#96&u#&inBvh+9FF0~i<>(m{lyt2=|JxHw$! z{^ENKAHV*A#5E4U&&|RR783{Ozkd0WVgK%(Ff%KNO#=cT0@-p92zHbJTY%4UkQ!uw zWClDc$<75TGF%Mhu}TcI0!%bBdDH<^D+zIcsu{Pyv>-1lR{5{r48e3v3Z#5sW@C|D zIIZUe)kEO@=igZIuYc@d3tMpt*B0!@Kt%Kuis&BOH-K zf{B4bAR;V;7c((Itl;M2LUx1%-4mg&w;O|ypa6y=nCRsIE-p@nkU(DyN3hV#0jt(- z0!PR1-@jo(AV)l>xdY^7r5WD5eaG9r`9!IEczz32au+S?F;0hroB=!ebgL0rkU?!+34Qk+40HsH0!D@{6x+_oZ~*`XAF$S>>1781 O00005PmF0{GPa|IhG&k>USL zWu|{MRC55xat21ma$@2G;y}joyZ@LNSg4o38Ph?ekcue-8;>AfmA}5cXLxt#G*}M{ z)$%tq*g=*XtMD;M3b8Y6IrSQ=Qn&*d83b5pk-x7!{>spwrp6HIAi*$u`xAx(m)}#K z3;1|>;dMA6@crjshV5tGGN?&&F?6S>G0e%=0*4AVz(Q*MO)S`a>NP`(4)i??3-B=qm6qu(2YnWnrKp*m&YK zLs6hS!}Z5s8B!)*WBB#^AAL*0?Wf;>eSYxLd#sj&06YXHOqoS>2YmSY2b=>AU;Thn z4HMOD`_J$JR>&ZOg}a|K+;M(TBx(BpzmsYq0IFC(27)RY h!uB$J0I3D(0RSLIr1cZj2oC@N002ovPDHLkV1lP7_gw%0 literal 0 HcmV?d00001 diff --git a/assets/icons/32/PEGACT16.png b/assets/icons/32/PEGACT16.png new file mode 100644 index 0000000000000000000000000000000000000000..d4d29bf83ec176bb9a1fdde0c55632bf6fb070aa GIT binary patch literal 804 zcmV+<1Ka$GP)_bq9g%LkF!%nP`LXg_N zBnZ*kpYh|D-5cUTVS}M9419WEUzhoqdD+4LM+f}DokIIjVzv{(L&Wcjsy{jq3j6)gh{rv`AXY>T7aZ9bC-bW-lN!$;=C1>xZ)q^4(}&G7+D24_hFgYB=Eh;prx z0|CsHazL!$AVzM|{)L!}&2mpLB5ZeVwQ#!~=i{jAy0SJ#odW(E@SZB+~^Qkp`jIm{<_ z$~6hyql3VAd+R!j|Jgu7o~@9Hs?`>S*o<8W+h%-$WidJK#&E{~^ch{2Eoby8lV%3txP-qy zO-NKx6vzMf&2vUwI0}YkgV+}imLWk=wy;gnvKC63Ffa~MBczx?P*6i3D;GwlNfrzU zMzwGkl#4csMvzwMC?SIkl?0|4rsI3>#(CqDnd$kQc~&O=Hh12==YE}g&i@Rs*g;G{di?^{8BzODQhrt6V&a9`JbJg&a3S~paa}v-++)Le0@fK}(;q;Lf9uuW zcs1hf`uaDF2l7tnTP%6ze07E4LTwMbbnW{3UvCr-BnV?nSJ5=Qo=W`H1FS@q`@%j5 z!WjTZ0pwF32LcSd*J44Zzx__ouojdYK7>T@dMaZ)P*Ky6Eh@@g4$$T+z$MPn9=0uB ze%jjlfv~`VR z;?o?x%b-QFAMyKr^E7Tc3&`!-<`><2Vm6Ow+m=*ZIp>5UCkKXPV!0$ pr-=+W3vkH2VVl$)|3Bcr;TJ?Y7aqQJOg{hs002ovPDHLkV1g`Ee+mEq literal 0 HcmV?d00001 diff --git a/assets/icons/32/PGSETP16.png b/assets/icons/32/PGSETP16.png new file mode 100644 index 0000000000000000000000000000000000000000..24e690c732dcc338b17499a85428e1c94f42b93d GIT binary patch literal 239 zcmV6j2q!Q_BjSI#gFsx-htNWsm^r&0LRcfSSG znXbZk^`Wa%*EPkej)`HghX6VtKh%YXQl>JCG4V{SIwpnz1}qFCy&Pa7Rm1R012H6)gy?|Wl5yykgwrW( p4-C4Jkda}ew+Tl9$za&^jsdr^Zi`ylKO+DD002ovPDHLkV1jOET!#Pv literal 0 HcmV?d00001 diff --git a/assets/icons/32/PJOCKO16.png b/assets/icons/32/PJOCKO16.png new file mode 100644 index 0000000000000000000000000000000000000000..437a13043217ea97b9215601b196be76bda37367 GIT binary patch literal 1016 zcmVfQnwP2k!6JLh9^@#1d!Bj9r3s`(8&dNN2!c8kzx3g22}JTm`qe z)r_$~6uASyb*bGix;L%|7ZFB+DGj#cry<138y7hTgNg4YqDcT6h-me{pt18iUwN9}= zC3hQ==Fa28vy8D4RS($hg`zts>;q%lKSu7bB_aE-3rIkut1)5aDoom#jgH@bh1ak2l>?^vMeo62eBmlUyzu2a(f;$Dm~mcj+o^L9^!mtJ zntd-nL4I`)Fc{-z4kz2QABoeZ4;mB47-16TS0vC$2DUCUYYG-RzJ+tSLdO?_Wl=fw zV<#(I;1G07xX1@SZ!?mT5;0tmdb?#8{tMBHz+E@#-gb9?81M7GM8&PoKA9@;yd0fx zo~c|AT&_IM7y98VAY@u(JrV2xHKw5*aaB`KU4h|Ai4#uK=3GT m9bN_kZfGU|@N3BRmEs>VN2d;PX*tRO00004qVq1CfQP$)cHvNSMy?hhZB5Mk^2HO(=c$9&>JKX=yK(3Vf5B-kx*r`FwkR z-+S&Yuu7toswkz`D5Z8oNny6TovadE0MHCz>qJu{1}n>0>&bD2YX52(cppHn@%PK< z&wCTp>2!BpSaAcC(!Btxt@?iS?s*MP-^4?AICD@p8EK?Ne84zd|Ct!f%$g75y zq952&6G9wb@Js;TJEy0F-hI2lOt_`gBqHV1XW-=K4GPXgpkZSvrSSmTDW$K>!P5ZL zQ>RnVAJ+N6x$p>RD^7rqj&TT!P0T(H6~3`3|DEF>BT+DGZtl-%)mD9wLU{fYN~r}v zF@Tt%$}-Gey)r*7&tqe0Io2d;+1Dc36$n;$(Fv5>eunY4j+B9tBdm%2s5$^?V|BHd zXg=>VenZ~dho3sj4tOUXw>hh67af?(lKXQbm~@eYhu6O7i?dfG>8YXGMc z<4uh|aMgVeU_)L$`UfYl_ecY5cJZxV$~pX2K(o1I5(F`SwG<&(847inzVxGPKdX1j zr=Noh5BIbsW*lR8(3F1$2x5XJyC*wZipaa~3D_q@$3R>0o)6rcCCE*Be{M%m@YIAz zoX$;0QsoJ0qw&7o+=*9eG$=oJ6JNKD_+8K8f2wYW(_kks-{n`}D&h?{kXEIX1XuwQcE5hzbm1=*vdm0rD^Q*EV2AIybkHBno zB5y|$Vl%hEZk|Q;lk25EWoiw~f*OHDG>?{0>5Rf27T@Lf`=kBPrKFD_UC;sU$nw3$PKD`CeYW6e;LA%rP-D0mLA3}Bo7u%8LZ00liw zK(f=)Z^sjv4@38YkB=pZE&I2JUc~U9F8Jm<<0J#EH%4Vma6I9@VkZXuAfloomjT}4 zfk%Z22vcx#=L$qyT_(aElb-8{YwzcWL9q6vtY@H2)`UPe0rh);fj@lU>&skE!G8{J zg2gUMD=}lSOPQ!KZh?_TfNNY#)+v4LG(JYq4~*lrs}7a58ZA0PI}$zh)n8i;L%Mx^tmj|Z-a#Nco>>+E0000y^HK7 zws~8sq*RYU@T9zh!jKSjX3*dK#tDG1n@G!?MeyiahcZ*$n7hWN3n_1Kv-MuQHlt7A zpJl-7y=wML(F!8pYMCm9ae}&EA!O5%C0K2977+>o^7TuxTn4CtKfn2#SCau-y)D{H zEcIu)H4>rFb{Fiq*tsSQVohAuC4fsta5hk@TTU!wTSuP#*Ok6f_-c)yj5{MM$FX@9 zqBtSiP%4A^`|k}Nyxx8T)22IK^P{^%_vQkMWjwDxv(t{vkGtAYDuT&GGN{rH!sLGk?j(5*Dh?Fu^*wd>7s$2-a|5{9udclQ(Kwrkp7i;m8s59G;Pho2t&M!l6 z&j6&988=@JqKHBoLhwX6V(*|Z8V*M=7#vO?;H58Zb2|vZgN~PBWDIAq@8x z-R#VtMvpE4I9`Sn5bkpibh9%blkV}P)bKJ$rRuvs1;A}3%BKUUGebZmq#-zHvjbiB z=1QN2<4HeC`B3UpMmqsVR^%Rs2E@I(1P9K>oL_+5w*QQr>TY$(W-&`|0aP*s yr=89D1!xH4U_-~qm&E#v11yG^8(P+!XZ`{kK4@@VOZgQ50000TvR==%YTOfbKv#cQB_Jar<-42KsG zkG@?5D53AFTG$I{`@Y`pm=y)I2#lGRWzv1|>U%O3aCian>RT;9PJOEd;M8}rfOX%= t0K1mgez002ovPDHLkV1gVZWhMXs literal 0 HcmV?d00001 diff --git a/assets/icons/32/PREVIEWGLYPH.png b/assets/icons/32/PREVIEWGLYPH.png new file mode 100644 index 0000000000000000000000000000000000000000..7afd4710d69357d14aefc8f7e4da9a8988d06c4a GIT binary patch literal 758 zcmV*=adKnn8IDlMmgPD!RkyJ-8qC23!qn0FFn>!~n zynFwFY)7!53y25{k>mg-CMGb=&Bev=_1ia%zrX(MkIyP0+7V0)R06)o~3}k@6fB&Lbu4rPypkQPOWxVGx&)!f6&00~r7m=P;jR13IoQaJe_H zUsFE~T)Tb~OoM_Q=5urak^@D>w{Kq<=voqz3RuWV1ABIF2d8vUf&;}lHUN?X0WK~c z>W6@z55!VX5Q7pNIsl1*wNP;23 zL@Nit9HFJDh1U^G3^WD`N-7KzlG2z?VECV`rDdT)my%FUUXg*5lWPsaa)vLAO#eNv zT|04yZbh+ykzpw)0m3Z5b?NL8kT_lI0#NGz_m9O8W;qC86hyJ9g*0`<-D@ZAAoCF+ oz{s$LX0|diTu_h@c!Et108PU$QM@d?TmS$707*qoM6N<$f)}4oasU7T literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRINT16.png b/assets/icons/32/PRINT16.png new file mode 100644 index 0000000000000000000000000000000000000000..c875432e51bc0086064ca27daaed72b16ef26cf6 GIT binary patch literal 372 zcmV-)0gL{LP)2zyml}#3@~6JR^j5={UjM2n_5VeIwpnz227(4U>NBRV1zO3 z?d@5fz5Ck2_>Uo-fssLgCbs=&`0$^JVWyN2cg?|r2mgSC;Movt`G1CT!bKAWfRRA} zWXH32UqQSI6bCT=XGjOpH!q*2p$ixo)OAf^c2%IK0onvRb|8SWBs_cZI#q4TyHEqB zCmFO1@w$LqfXnBDKLjRBnMGBL3UbnhSO^s0a51$36B7Fah`4_J2F)x(G8=3c2*5+& zKO@6TP%+uu+6LyES=dn3@>3^{Fd*B75du;|+%^9h89G4~1_P}Cs4`+?=mgmX6JjLP z8YZ2sHpWN>D3BvI;^7zTR?#1h%QM+e7FoEjP-FbV)wLsdVL S$g?y600006vb*#wT^NZ1m@m_VWU7eGwT0Rcl0V+stR z_+?~0@@-hcx^+LYCXnzxqP^bxUhiG|-aWu#vHW+WZIp5|8%8y&(6oq5{S>KcLm<^a zq_|gjzfODtXW8kzh#U?RpsGi^#gBYq6DYBA=#>${%JLji^B!DxqC?bdwot44xO;d- zpo##pnbemsMl?%<$(I&qyOI<7I7Uqv^c|A~jw;gp52*!jpqQGQ`xij5R?c~v!~~20 z;evA~yDN_}jAm4vsN>@Dw&QtwYqe+K&cW$eiO-Ms!@I#R<3t^C6~|RDE=GX{jpk=- zpm-R~s5m01a#h!!{cx-GgPIUQC3E7h_tHdnN2cIQKfei7iZs|{9-rRArW1uej!{F} zF@LfZmt!i8!|=ivvb{o4;la}*X@g_bBzX>4EEbD}U*HQBf{w~cm8P2j00003_Dd$d;FT%yEsR~OpK3Zm#nL~K7Kg8oGP6}r$xLrP3@D=(y(H|z!`7G04H z5-}74D?+oR8%YpKxTKqgpl-@)UUtuZF$X>Eifb$7`oms0oH^gjndhBvz8SzzBBBr? zY9=CwH7o7#c%1nOE&`|qu*+6eiO#}Y9xd(-2ubvpfhzz`4!nPhwxkmvNgD5}nQ;R| z6bGPWq`eK6qlX|3*p>4?=r^n zlo~LZGDV9^xIkdX7=zXqc#KhlgqDX0gi_U59J?Rk@d>cMZa}*^*}dYiaL+zOq?pmz z)Q;HXvLe0HVOF+)!@*dpug7AyX%&hy_oBOmp}V|HiFcRX10)H(Rh1s_kd2$MG${pb zoi@Z}RAAKMI%Ofjsql2$vwna<`>ie=)0H*NjQ$tTz4r6{Hr~1qL9JF|dQ&z(L4Ch# zz{j*tCjI#w1g~8;X`dLXg`wcG2i%=0PK=d2?VT2Ukw(OxO$!iJcuBr!+>hIM#Ruwi zsBa#`=MH{2JSE^S)nj*}_LChfSOY`RH3Wo(De#DtGxBZ6!IQzcyx#-UkhRAluW-le zC0OyG0`^xgF@O0AdG9-H4m7k3di__#KT>n&FdPzL+sYt>#_WWPAg{Xd%TKvI;|91| zyGGt%4b(S(f=<_Rij48T( zl>#iatEtwX4oZ~_EE8O5Aj&5{WI|>T<;%=DuU|(#ImUv~iBkXo002ovPDHLkV1j81 Be`Ejv literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRJOPN16.png b/assets/icons/32/PRJOPN16.png new file mode 100644 index 0000000000000000000000000000000000000000..edeed2575c9523831a1158bb381fe778051bfe55 GIT binary patch literal 502 zcmV7Y@ui%ij6Uvgf!aO*a(`!;1l=)f*{yfDv}@?v9nbK!P?GJ&?1YKFAz|S znD~b%m_ibjWUtIZ!p1Q{WOo$wD`sc8!@Y-dXZ8p9=dVM}0t4}M!m@Z5giy;2jB6oi zx?rY`z9T?13w)`#gb=dVeiNfrVtH9g&b3UizP4Fk>#74kwg=+zWg};aH4rU$Rg@V; z0&mBJl~h{bb#Vz10st-KEb-YMpjkOynJF(dpg*3rYYDZ!RHq3-py??XnLp8@L1?M+ zFQ5fRXnd9J8ROC!c*q{ZEsVBKbVY~l^QXj6gAj2Bs&8f21jtpa_U+XoJ%QMS!WP4K){RSbmy){1;$8 sgf1AD4No1}1_lna2>^;3YyDE*0e`x=hZ)GHp#T5?07*qoM6N<$f}+aYdjJ3c literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRJWCO16.png b/assets/icons/32/PRJWCO16.png new file mode 100644 index 0000000000000000000000000000000000000000..2a9bb8a23f3237c512f6235996a27693b9091926 GIT binary patch literal 1118 zcmV-k1flzhP)Rx z?)`l4@BGf;TwsC37%O0m^)bezp@!P6vvIOOa1p>c0MGi)p22Wy6OSJB>I!x(lz|Tc zyb=8MXAD-o4kpX9U7cAsz!=*Bpnb|Uh=FadKn@1fzWj$CPCf-I?fc52QFasr=F|kZ zDJ3rtU8wt>rnEaEi&Y=-T6mgVWqRSX&N2C^SaIR1fBtcWPfv$$xMEr?7~V=6`lo_E_6KvJpY} zj4>7lP!GU(y|oFU-+OO9RuHhVu^Ed>t^99Y(hQ`l`UT#ntb6^}bNY{ZIc2QFW6Ve@Whn z(GI5?A9WrFWEtMGXX4-mk35FuRn-_A_F>1~)0mc`Zw@dTQF-RI4PziM{(GSgbJb9- z1LNm^NZQZm+xGbvpt-qf%wpfiSCIc^4WyZNEm_`eME(O0YW9hRMp#=uh=a#6#l%?q zciuU{7aK%uc=QgGwjNM6n%LzwTk$z&GrIdi_|wf7N4zL9lqV2D*B=3pd;_d)A49if zi3(p){kF2(aj+JgEBQV!2Mu{73mtsBT+oLvK4S4XClW)Q*%pQwPUlUsmI$23h)%(tWo z1ist~$<+(JPJltL1H9K}OoTjHHXuy^r?vs^-xT=T)x}CnWrAiCZqSR+>u5?7G@J0H zO}$FfGEqP#=E;Dh4Np{}i5JDM6ccnI;94e%$e3b+W@MnVCT(~!6Eq_OQ!@uloj{eA zu0(+#N1Pc?GcvILeW2(r1i}(}{u)JCipF(&TGlHqR*@*frN2G!2B#20-mN>~k)Z`~%hwi4)+Ijyp`=q?Mgie$5{8-LS@M`C903!kwp5ET|Uw`cQ ktb7~Bnz#|tg!7*N0S*}N31YmfivR!s07*qoM6N<$g7Zco0RR91 literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRJWIF16.png b/assets/icons/32/PRJWIF16.png new file mode 100644 index 0000000000000000000000000000000000000000..c587257264c0c665a8646082ccc239de3a4eb594 GIT binary patch literal 609 zcmV-n0-pVeP)_rb6@E-_hOAoCI#iJiM+nX|3ftfma$HGrqrcJJpeheB{-=9Ra|W-JV4 zGl07q3c*R5pF2HbA_{_&G#|>^$YwYaf|E2qd}rB25X2#B3<$srHt$p?#3lQgf#5XE zgCKHLGZ5Stz(Toa^DqeR3t)TQ3>k|}^eWpT?6X_zxi5gRyFl(F)|(z)fB253r~aC* z&WxGx>!;Fq^RWtdV;h?|*xeI8TKM!&36J8#Ea#{hf7QMQnm_R_ z`ZAzVM+|M*4xXR5g&+I#U72vMJ~Yv3F7JrBtDL$o1A124q_ua8aX9dpE|{uDv)0bU z&gydT$+wDdwPQSKkWH!l*8(BcEmbZMQgEGVuPUeAlv1qYM(AE~O8{je4O)Y0Gb-er|2{e}57LO*3-eBP1WIKbe4y7bj)YiJk!s!&F63`O0dI_GG zn2796Impc3097@EKxIn?HAf_!YD92XrOgu5wPPmLgrdDASh6%FWM8#<4cZ<)05eqs zsEgYQj6ur-k-BWTbt1SRH7yN`l9NFMtE+NndfXBqlk!!5hlhs1%oFy2-;YsE1DMCm zfh14d5^!ATcmtq&WMml6p13jS^Wlfri>HqtAs7sTi0)N1xrgGm2Lw7RM~U>dFMYk1 zFMYk3gnl)spTeK$1Fp)Q=|Kf&nX#K>YcM^4DNyIQ(B+9+0ydjX9qtSS*&XJfF{p z=H@#H1OgKA^t+zUi!mpVy}95JGu=`Y1$O&>WMr(JmH+wkCp0(Tg|6!$;=^xyx^9bo zLB}v_%l15Gx*_ADqT)G&3xp$FfoR3Yf)gN}%K#+h=Wj)BZf?{%;fhAI<39ca6PvKn zky@fKS2MVfh>|9gm{}uGyH4b+X!zb@cmh|dm)8){`Dg^pTzk^#tuZWtMyVWpUm-$4 z-b!SxvmznEG==2%2l4)+2VLF$(3zow_8GMjib5=pg;4OEjcGH23&bXK!U>7SHAX;X zMxp!Z=t3$9b%I?;Rt?d{>fI{6rs{c2%Q3PDD4%D mR=Ie>1l43tI7Z$B;`}E>X+h_hbJ?8$0000Jf`d*@?m;M`lZ%re=u{BLLP1&_S_DCyMCqbV{sjd=g;HD{ z97S3Xb*L1fii1PVE7#hz)Fgf-x3oXFT;Ps-o;xuxt2{xP%a_^!+26)4;M?kF7cmu$kO5`?{Kd@;RXE8(Q8FNd|?95b#oz z86^Uz#)J_we}NPSQPg%;x=8f{DVjG#;~b!{eBNi{3M>G_dZMB!>iXWsZV4gqWfkn7 zJt_4dl&ZB2{AwrshSiw?YV8DS>_rAx)(qUj24dt4qNTO%V!^Wn2pF|1AcO=svl|&4 zay@|>3-gn(qFjDQ<|2>hm$!*e6Vr`J2)IOVPnTs0^!qUz8b^PhPj;JVPC`HdeqX1p z38BJ(lL_Iq@X_&QrC6FEK2g38bZQ;&byw#;v&Ct6kj}X(xV$)JzL(1e&N4T6EWS$h zg2tGuC%`DdLz=}q7}MdMr|X6UI3=%1g{xC#;CJ#KGAAt!M9k5 mOa8qI2%P?bdd^B*HhlnfCAq99AYOg|0000K#+)qLGS`f8oh*-+T;cvz%*)MBjf}-vQeU_2_j}w zWPg!mGt0c6$t(|ZNjya!x&n0d@xmm6!ek4F^#_vn&6o+XqrVQvBQl z)YZ>pI5c1ZXt?8q$q#<9W&bEb?d=xKHy5KG*eJ~!_#j5fVru}_K*?fj097~OyuMhh z_9az75E~`mnaIe@NGqTRM2JlFz*sm|Geo8dv+}wEOEg8PxbV1O00000 LNkvXXu0mjfw4#DQ literal 0 HcmV?d00001 diff --git a/assets/icons/32/PROJMM.png b/assets/icons/32/PROJMM.png new file mode 100644 index 0000000000000000000000000000000000000000..dff25c1ef2e1aba769f755aa6bf53a5162159282 GIT binary patch literal 1222 zcmV;%1UdVOP)k5jfe}erJC=?8~>|k>m^lO+<^har~ zok48TKZE{g(5S$mKm^wsx@H+S%^_2nF7IS6yu9Z5KJlE}AJTX?m-oK+-hDqH-s_K- zFP`6f-sgRu1Bi%-h-jUO^*$lpnYK2#0}20Bg4n$h@GJ8{z!h+aL6+tBAX#jOa_iR8w_o**eYf=t;cCe({?tJ-dXW#jK|f{f;7hMIN*W36?`$RHRnP~-Y^I9PA zxBsXrhq^=c%+pnCE{9U8`|$j;)hI0VsKechi9}B(veIfShy{d{e)ZYy(NMS{{SSUe z3JTn~%i~HvmO%QPlvyl@1(v~*;`)bHAI+m~9ZP(SvK;o7zI{NtqI6^-1hWepa@V%;qz?+PK> z)MUMO$0k%)mEQ6WR{!aX*C*%l^FO_F`*;V-IxL6{x?4*235X+VE#%>va%_KS<4u2V z^g;}01}3ksfr$5;I%4lw9yZUhAU27#=({yxe4$p;t15LoR$H-ZHGOD!I{l$m(G7^^ za7Qd+Yv4S^g4n$uOOxLMD6R+=qkh*`xLg814^CoqET;BkB_*`Ra7XNf-C6S$3z7vp zdY1)y)uu(Y)m^P~T%5d;-lS+4+H>5=YcCcgOWqTrL8>=Qt-Sw3%F8Z^(B96u5xcYH zI~F8Me7wJ?xWME2`ltDZC)M%sV_kf1vVhy}0JNg{@YQ($p@uzbk({yxSJH`0upmSx zSP&u;EC`Va7KF$I3qoWf=kK*Q>^Z>OrWQD!qw6*tL5NJ`%|fA5Ug2(xcuvckt2lxX znP5SPOt2tCCLD2{tAv~1l;?)d-Sm5bKma4ZMa!enfy>Ae%$pk=Q;@2fou-pPDKX-a zB9tvpBJ<`3$KAy`+|{}2_@87FU7sAm^z=-1O30aPD?Rf%o8#sny5GO*BNziR+j+l?T_CF|JUD!c{7{WDvldLh^*weImqbnKt|8M?ZHRZ^?b~m*}R#? z5rin0Mv$|=o`;h#ud{IkAu_>&5Sd^>h)l2`L?&1eA`>hKkqH)r$b=*I!#HuT5c8Vj kUMwOaA|fIpBEnky3r6d%Udd(}CIA2c07*qoM6N<$g2-ZA^#A|> literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRTFGL16.png b/assets/icons/32/PRTFGL16.png new file mode 100644 index 0000000000000000000000000000000000000000..d6404ab1d10c83df8cda0f6612c1e5a97340cf96 GIT binary patch literal 1001 zcmV*0jfIE5hDHR7U^+FMAH9{>Kwl{SH3)9z)gro%&4OIBZjvnT!Ro!Uv4mm*Jf59E zx%f~`_+UD@kqKTC&ka_e+|3RcbiXqbD{fu46#%Zp_pyWa{=>-Zd08LNRZh#jkpa)k zxe({NE_=GG7afNi4UbIRQP{A5=Sv5mT*|53R-=)D`^Fgta8x(juD;hnyMAkGfOh=V zbc}K-r*c;{;td$!qIKQ-8aOi#+P2V?974@avST@;8tV-7dt=A-oU7BejvjFP^v0|v zWlum*IMUoCU^$grHB_s<-xXtqv{%o0RUww>&Y7E$NB#<11r`mjfDJNM{_y}>3AY;C z;ifb8hCJB|S?L6ApO2lOyLsC1WdWTdLPru25tImWb%4#s^&y&TiG|(mYZD$dUIi5g z(MVEpg&j*YV&~SujhkRf2f%yB8_}K9&#u8Yk;-=B{S#q~`TU#4VZX9CkK)u1wYe9f zeQZ;ziux;S2A1|gmb)A1hfl8JN%3@S%&NJX&jGycmzR**S$z${Se-Zv?wo|v^F6=; zwhF@^d?e8}lgM5Dp(*tl2-~c;I&lX6^t*UoU}CnJO7nRm$Z~i@w*p^&_Nl#|8kotC z-quP+bGYX7R)eb_SM*zp3C-s%H?W_BYXHV|6||UWxq-Y!Ckjq$8KsrX!XLl1)_}qm zkW8nvj9M!Ejz=>;x8!wjv|(#Erjxamn47%w+&3oI-v~_vZ%B1dlpg$q!oBa-1_(;E z@R}60v99w>3<~cd2KqWYFL$i=$0VqfBSocL1!yFU?Z78Lew)}xZ~ICz1Bz^meS^mF_3&`UqPT+oRDf4)1+<9?@~NHsb|@{x3m&cH1mo_zL_B X-*%-vg8(%x`Tw8c10%!#naWK6Y7QQ3{DUmV0%L$IXJBM3 zhr5W10OBFW^1J_-K->zf4q#wlOb3xdDy9r0zS-s9zyI?Y z7~Y{sOrN`)ECZ*Pih}9P?$=oPFd$>w^q7f>F_8&uIU|D%1HAzwgAB-S7F?ERCP(7c zf9%95tm5cCMdzbCf{9_U4P*|r zG{7ih*92}0I;f$x2WSlr+!7jOY2XG|1f8wkHCRI6Kf@DH%jCrch>Pe7{xdvb0yPZ5 jju;Tj858Ml@1O$!X)>B+8#Jva#t01n2UIY>Gn9Wh7c-(_{ z(SnEwJ$rG(iij5j%W7F=X_l(Rq-{c)Hcj)JpS+i3+9uOB*kt`4GBdw<^FD9h{C@BE zLg-WRbSCO(>pGN4!%&KV84#xAra{R7%OI17N4bWj7mK;T%V^9Z~1tRa`m0b3Z{}jM7HY);w$@f89Wcm4>DPj?K>=@mQG3?+AS6Pk>xf-lg)_MgSUWu+ zulx*}4_`ejiD+(DQ7+s=v%bketXfLHT*zgY_S>lLH}Am1$z3E~c>pI~4unhekyRWe zJ3NNi?DKFZp5#|euy4t3Pyo~Ej0+=aPw)eiDFF4|)m?5n0 z0JKavq--~e@w3lDjV~YR*at-a?8At}C;Mhbo3$4}Qqsb+oiH(d1u9$xjcoK6K;-ZK z>?9LcBp7COK84~RS?2_sXFGp4b?RYXPQ`Jk*0(MDW(Ko_34kuAGtr7?6}ia7FI|N- z5<%$Pw>Woi7lYJNp8@(J%Z(~ z!)nTME~d( z_M7{5UTOk#(m8Mk@3jo< z8ki*_EGq+(=W}i*9*1-(<+GS=a}NiFo7~BaJ~4CXgM*j@EN)c#8=KsULK8ulFU8DtiiExRFiuiQXN4>x4B`b0E^ z3ADOhZWfc*vhy&IEpnK1K$=vT`A&nXI^*0r1CSLlWaZne-mW;wU5c@O=ku3lTN}rq zbmzfjo2W1BZ_m|!qvQU?3_{%u`?wBfaQZHARN;S?-7{ja0zz^%9~|+C#J;=KlL4jZ h?I6QJz{Pi${skZ0qWlozD2xCA002ovPDHLkV1mfD3Pu0` literal 0 HcmV?d00001 diff --git a/assets/icons/32/PRVIEW16.png b/assets/icons/32/PRVIEW16.png new file mode 100644 index 0000000000000000000000000000000000000000..f6008447279e527dece2f60c76bd659086541576 GIT binary patch literal 830 zcmV-E1Ht@>P)V^1-S2&J2>J8lv zm&+wj5ePfUvzSI8BQ1rt^YaUEIDSJE7gwy8pEl4kjadYY=Z<4)dgfo%5j%iT6(mjh(;{_v-rRX`Hhu&!-xT*k<%&SQ+o#l+Xy(0LrzvE z+-`U5bHL;Apr_{xK7Tg**T3(qo!bx2Cy8X3S^Ma&w(aWGc_Ol)qzoZT*0L29PH;9l5&#Vrr&A_l3hsYP>Z_){{# zu71ecWmN1myi$1{wRdhJWqb0fHI-^pkUPAFz)0{|r%DbK)63e|55YFdq|eQvm%q|8cHr0C>`PH}mW6^~5o7Jyn|F!qeW>kVu>tahJ2(U{ zcaNQ_h&coaJ273d_hNtrgSRnrWzefjN|^A6kRw6NoJ3C*JWlZ9x!<%d!R`#VXwgqEjIbycxw}geCwSZ z()$z(Zr&1E&vtk5^7e2JgWd}E4HvBX+T-;Wlyw*y@)#sYedJ3>lz6$bq43CeUUx=@ Y)?H%tr(d3Z26P64r>mdKI;Vst0GA{|Z2$lO literal 0 HcmV?d00001 diff --git a/assets/icons/32/QUESTNDG.png b/assets/icons/32/QUESTNDG.png new file mode 100644 index 0000000000000000000000000000000000000000..9985a566b8d0311d7ba3011ccd46b372e1b9b87d GIT binary patch literal 3454 zcmV-^4T18BP) zdu$xV9ml`3dwxH$6Y{calZ0SsAugnlREe$vgo;{3Tck)4K~$8ARFp^iN1=jXIRTZl zQd_7Hp{1ymQc=;;7PS=>A_yyK6R4pMrNM**9DI2ZJBjW1?6Yros^8qD_3h5y&ED;< z_u~6V{=;*#w|C#)?L2<-o8JH>N|Y#3G%yq)(P&p>0BA9QT8_xPnXfS}xN4sjP5Ls=SW+xa{a?Uy!&<=(SBRIk_#DM|Ect1GyX`0qIf#lwkJ>6#! zQbK2t*67x?+%&%ku7JYu1|dTv zO>Gmv9$*X$^L-z^tP)Jup+zb(%FSc~+%RBF=dUN{I1cb_5zX8lv|(6~Bcns6{&fy) zbz=y(UOw$nr+%zzG`Z(gJVwfHu$z31(sVQbY z=;yH6H-jvWc6Dl|{yZ2uobS$1*|-2T^V>y}G@DS9HhyvdlV?tdw#pHXep53x9PR1u zD;k5etlM%Y2YyC+JJq2lp>E-F(MN;{BN4~g@q^;Yae{M9GT@%ru1B5?wLz%kKFGE0 z4D1_Db?8Z`Z@Cm@)eQ(U)A13E#@-W8juRaGm&=*C$;%F(dD&l7aQ%+}u9x0O(^0qR zVpPv-6-`x9z&YYWgBUyZf#`1>cs0R{uX@$5c%n>Ow5!qJ`kw);mAzh8RfmT5D-fxu zK{1j{jALZr9ZXM*IaS%MGvlViJ>6$!-5|mkroP9i^R8-cL48XH7}HS9aBgBW){lwd zm_r5h>zc8qP@^ypnyHtiPX=S6uc&Sg)-~lf@!^>0TO3AWyA#Z~v5@9VE2INY_Ze$t z{lx_rb)I*|Am}^McXOC4ttCxJ8{|pe7p6v2_6}SaW7$%@hH=;$4jnSUXKUYw~MEt5a_9S{DlF$bv_tl18+zt zkDO_1R9*KzWcQ{ z1P$Gj?(G$%iNo5?*0h#|8N{T31j!mWxkbG6+HUy5!v9V1f`sl#_x6mm%gA1ig+j|* zmn($od}K8UEiN^-T>-BsFVpbX?$4sJM*Ww1;7D9d_^5NHIR-&<73v#k0=Z&|`oh|Mw|)1!-hk4rW*=GzFf`ugPM#%UVQh z;9f7gUVVxBdiq1ZJ}5PY6{ZT% zqpR7(@YsDG1gXG3i_8oyLSt2fr1ocILgAf3MHG6;Wvw;JLtj52%}6^Hjh#DnCN|4t z;PpC3P~5ym?Q`{;@SpNoy_I-8VzRkX6`7gFswRtc?h z8RRS?tF7C}XiV*O6uRFu*O%e3+tnwqZ@%yCO5#jNJKNliAtJQSWe~B!(gN+zC^m*i zr}5k?N0s}JfAkj|Egw%*yj6@A~i_o(mHIv=hCbb${+vX zFvceQ->oLqP@;8)LBuknWK({zb?C(H*Dn^vpg=k&UhW-I_H`ACR6~Y&)}`Hye<)pr z(i?@C#+nGW+_qdqH|CmmP@Gnfke1fn!D-D0q)!Ot4za!oZ9OigCh9leyF8~c&N&mW zUJ>jzI+>PM%`*&QP2?gfSoVPza}#Cdkz1Gf;^lQhrlnQ$;@-4@R1@{&rVf1jrdHS9 zU|LV#cE`ned6E6XAD?r8P1IwzFL(7+%w#HQij~DMd6A3OAlG#^31j5@>y8ag;(_Nr z5Wx~*B4SPc1?aZiAz`C^K^3;#wk&UB(30_Ezx~LwFj7@yTBbDrKbcNM;H>o{QX-eI zvGLkPD354)HBmGXeDUwOgCzVwrX^|aXb?(^cgS)=($b#k{zHI!&=GYF+pwU$vPwi1OQ z(@>_h%^s$uePdi4LJ(&mmh5!V;N~R@S{CPTJ-)NIEgSZL~$HR70Geqt?eUUAK=#{6!)b`kElVTmo-0ELD= z_sS9McRw6T@rxX>~OISrD|IgN8J57>RCHIg3PT z>5b0Mpxw*Xa?1EjNrr=>szMjdlqyu0t_cd#f;5rPm(~!T7=)G?>HG|tTYxe?Q}V7L zxMoFzs{}Pvm#zr{(m-e-Nr*|>spf}QUYw?kXmoytwVX1jQO4&WShlz-kZbaRG>~SK z1AofRK`^eO1?VsnO6+JYr}W#D2y(6xACAdWkaP44&0OHhAe3Fx)U*wh0@eB&jV%0j z(H}ZG5y&-epzkajRgp%dmD{xAuA|K;4=o*LBKrhq2Hp|Lh5h1<10!Odp$gTdYy5(~ zD}86#@Sikto3l6X=y%H4Ooy3R%c(=7OwWE9Wg?N9^r=F1=^8)CmercH$@lb~ytgCJ z$ue}9iIY+MYQA>7b_}oW%blW$>i9KV7ul?xQj7zyrnQ+{$5m{cCD)1H$5j;dfiBen zIv0!LK$mlrjyytmjyyU?=}@rl@Ei(uj?%Gtg;P3M@_as6awestSM#HEIPvK@ayao! zO2>DrQ##;&E*@}iP4J%-rv$JE+!)3R8HI9(SkqO|)??c3TFCYZG6cZ4MKp7}%Cf7M z%-Vz?ee%La&Tto#q%@xmIMB;Do}o~kpbc@3P|VOM7kVoFHoL_d;O#pcF^aXN@Xl-z zg>%XvGii-(U7JcWEb`i}vSvsvnAGmDUV!hUEdhf)n|C8bgw7z=VRIECt3~!shLxPN z4n}+JC0XyJa13!^fHB@r8!Ty0-vp9-{T#NQ*9OTpVxvrKl>Ez@Z;EnepB``PnFES%C{UD&|n8yZmhz`;A19=Qz_hmj0^%K=K^BDwZ~r>`qR`HA{`_c zW^aGOaNzQL`sRY~KmRgpKl7GBO`40LJ4KCQPQDg6ROsda5ZHX`H3JOjEAcYS$kha6 zkfZ40fGZEaFx-9q4bK1d=O4rOpZ^$i6?hofSP|B;P@D_!6oea3yk;m0lxMj9_$x!o z#A^({e*dFyNx1#=8?et0UV4w!au9%rKx}Fu)gAER>mP6qIDGX3PBlzav+X~_2UsD4 z3>NNw&T#ALR}?Y0n*X38nMy#$wy^_L6qBUs|Nl;^g#f5x0T~FYXb9WO@ByS2qz3>i WXpMX6_rY!e0000frLL@>Pb?INwQfCv16^KGDS_dv7 z?1S1wP=;VS4w$4hW#l-{%3s#&Af4*MUZFl=Fa8v`@ZK~UcJ~BL z6CD8BBt)wK_HkbVivn^Iz=W=2Y-A`L-PQm)yL*Bgrno5~F9E{He_Eym#6wM&{e=V~ zoDOt!^9EO0;&~-F~f@o|Ep?0qyl@%50%#W27EPak)W+sB!NEB()WLe_SMAz8x zz=NU#xO%;(S3(SM-P9OD+nH1F`O5PK9FMPJ;`vK_n2BT@$iC4#;lV8j(80{5ywCO7 z(HsNUX*%vsl8TkowMwg z^QO>2N9P339B!`1p}>Ch-nfQRkB4dclua9GcG+{<4MSHwCz!dfybOiHlW7eH^6bxk9b_f89UM-Tbu9_S8cUNcGb_(FHLbKUhwCL3$8MlaiUCy%Y z5P+nrDQ+joaBdNa&S%+n2mllOP*@1ks~aQ|Yj{63on=h zdMy;mR0@N)?x|neQZ|c~;{$b@!eWtAA(_*;Qo>^7*zQ3>Rim(w+expv297;v*;VFl z9wc^8GXAHqw6-*(J{b7TaJ=Vp(RoZxO=kuU+w&y*CmyAL`dPk%9sB~G%0eKaJsM*G O0000~G%|H}b{ zLSb}=BZz4lrDYHj+a5S^==_8O*s`smk%Jwg=khW)d@Gj0ZntF(cyMqC9d{p~D-=!= z@TRtttu0?1Ks~LT^KJk$G49-Zm}FsfnKHpL7F&${LuuE^B}sy-#0kgrsaZ2H@a7$QdiybbY7vf|YQulM zePTOgg;%Gm2_>BqDmWsiwCm*M?zynr3dDO&i{sY)PCR|q3q_VtT{#ykmUzWG3b4>- zg~c)jjlXWi@B0p7cx1#bd;)c*8Sp2LT9=|I$}jb`V$bKfia)RX?q5Od+Itp#{qGF_ z^QcZ7{?m`j`6UMXr7P{Yc=@_G9kPt_)GSD;0VK{jQ#_@rAg4VaOYZ;e=s0phccdSi zx3(e}>ND8atyzVoak2847DpxwMMtpv4`Z!atp!+6 z;WhX+34m46NavhD)lTTR*O_+Zsd)4_GA;{l)n)K)5&(p}>LQ~bwWq;eUJk+av%^T}@~^ffSBVv&0Ke zsne9)S5tv`u0;Ll2uFGhzD)u^2MyF%2qdpM4)6EFX0>D_pXn&VfjzYbTQvF+|8@oq zzOx1(%LtHYbU%-X#zNXo@=73)xpbxpi>lRe1G893qq%K= zM$$x&PMNSmwKhgJpT&F$5~T+`${Dyf{w#gcazJixe!{J%LgKzZv)I`@ISlwpO3$!l li8M$sCs``rcqhom(5R=KHk*0Q9iVF%JYD@<);T3K0RYh2KMeo? literal 0 HcmV?d00001 diff --git a/assets/icons/32/REFRSH16.png b/assets/icons/32/REFRSH16.png new file mode 100644 index 0000000000000000000000000000000000000000..c9d7e1ece7047ff588fe9ae3a00d188dd810eda8 GIT binary patch literal 875 zcmV-x1C;!UP)PBb$CuRKZaH-xOB18`2#o1D&0DY;1)1!Hyrat~EO zFc`r>m%efK8Zi*}x`7@Lm;nM45!_f)qG66pKu>H07BKh2r8)=jRuts=eG^#pjvz4o zQGPkpHd^df#iXuJ0>;lq# z62w5G^adJcS4UW?9z ze74kFR-ZTT-Ga2XnF@k_o~f5}d|`rI?QwQ~3QNUQQC*v6k=_^5V;?AOu1%F`?g0TN zPxsJ;Xq~tJ`nD3&0zs=`Fxz96X;$fEb`CUzW0)w!Siz+0)pjexGI;jjOMooU8A4o( z)LEdY4`3S>V|E%?ioSU(hBw~+8?>#qn=2bY{3(Ep^ny&7j}>C#gIm?f#0RYQ3Q0Et zv9Q`JTY=zRfW)kl9GJ@URC!8<5z^|0Y7#ZgcZ6d5R|Jaf6?ZszJCT5#!}-W4%8KaB zCoGUwwOw2^#t)YmE3n#6KH-2}U;^@vTacEQzWq>iUF)BOT%Fm(1h5pQn3 z;JLgm!SC{6WhRhR0<@bVln2yKL|gJ;?&}nmde>je#K1r4F0^8mA*$uLmPJi;eAfO1!K z$Fo32gNS^12mRSJmMbfqEEFHv5<%osDK4%z7(k_kA+?)bpg&II%i9+?diWqr!$7H^ z;n>^^h9>Xw^~}{#=miboKpXlx4nbP{i2Oh-apL8y(y#+Mkx$&>WAe1GvmH4dm{(O~ zFv{m?%*i|3c?^#=aXUW{gAl>|kk3C=@g#X2))xsOf(VJ&iJU-ta$mpSyb+1S{R>c4 z6qhT==}WF6T*>t%lz#k_C1#xEdwg|)rMTRPgrJ?|t295g(Onu&&S1me{{UmW+FOtJ z@PtlI)Iv^c4RwKW;T*4Yx)LftyAyWuN>>zZ!R#hEKMVfXw_?dOaU}m52NsKtb$}YL zfc*_}B6RBx6Nt+T;q>^K-`6kIOHLap0VVQkHG+E^ZaKl~6+qS*z-RA1Uv=#c;RNNN zTy;Aj@VvK2>1b^kb35IiIY*bit*uWC&S?o6`|bitK#AO}r4NnmPFTqaz8w%CCl<;p zV@?%rub1vna2xrq2p}Y*VTAz^E4hFWL3ci0ENvsFfL~j?YJxSatVI9-002ovPDHLk FV1jENGHL(- literal 0 HcmV?d00001 diff --git a/assets/icons/32/REORGZ16.png b/assets/icons/32/REORGZ16.png new file mode 100644 index 0000000000000000000000000000000000000000..7053df802ba2ab24d06e26da1a3ea282f264138e GIT binary patch literal 503 zcmV|1&&cU}Q?n>Up(?7=wv5j|m}yM=`{yGGH}C1LDkM zK@tKhPKYwWs(!(;GjKIT0;0@gVi;h+LaK(Cl!E^Z3=9vDgcPu=TtXWM;J1`?z(T49 zX6FBj$o#+m7!Nc2XOIDjFPu3M9x_%XBL8XPfQ3kwfIv)2!5>o1z~z7^pi~J>owxu< z4Y7bI^Oz89rbKYzfD3@-m=cM%pE&baV0>r^C(A%3K&*L83VT2%02X2u zn&cf{{hN^^_2NXs4>W2K5dw@MEdPI8HqJlpz(AuG5kbJnz$o+oAH!~wykouGfww2es}Y@vT5=Yl-E|Bnx=o03W~zss9WQ7#RP@?wuBO zBtAVKo2B=OasUGv;QxPy6@Qr6Ghta0y_Ez4<|QHwv~a)|28REcXD3@Op+Sp?5cq$B tneo5wnMp)hPW={^ef@rNoA84h004PcsB=Ui;-LTl002ovPDHLkV1iFj)4Biv literal 0 HcmV?d00001 diff --git a/assets/icons/32/REPLAC16.png b/assets/icons/32/REPLAC16.png new file mode 100644 index 0000000000000000000000000000000000000000..e10c2f6c41a5402624f50bdc9bd7c1eac170265e GIT binary patch literal 825 zcmV-91IGM`P)z zO=uHQ5Xb-XTx*4bDF_xUw9s@@Ye9{j_D%x$lfJl`k(QF(l!hUOGIR7jc0`rUT?UeW&oo1iTD(No?M7_ zD{xtCrWG1m+p&5PwFD3)XD8p~LJ;VoX$40CzCw&%)EXcQVQ6)j83H4+HzfndTEgLa z)EYpPNW_^0i~tCJ0$SGzSoT5x27tEK#)#DRzimc~C47?8@mBz3*lOwQbk*sdL1^;J zKKKxe{cwJz|AVM-!nA_tpm@Qqa1IoWMvc_sH)-j81eAS*Suv0XW7yriCzAIXnpQ|! z>=S7$9xD`dvX~?%`#j++xk!8^Mq-UTi_#OU$!;tRJ!)Eko=k-+y%<5x2Ds6G2?soG zM*wfTrksYgY4RYI==?pWk0n`Lw+_VB671pz_+-dRxU)P38n0gZ*Qwn(yUT>%= zTVzbD>lCUeRcvx@W^yDK;urC_><{U3VBKAFfGh+lx+cGg&;jsW>2grqi7HB!GbU$V z4*?j-6Wk@7qD*ztL z2#3SQr!Ol(+W7$kBGwyHs4oFLth3ppVG%=8t7>WH2AzUoWkSx_b00000NkvXXu0mjf D*lu%N literal 0 HcmV?d00001 diff --git a/assets/icons/32/REPORT16.png b/assets/icons/32/REPORT16.png new file mode 100644 index 0000000000000000000000000000000000000000..a09337b4c1389b923c321a3340eaf6c0467e3132 GIT binary patch literal 330 zcmV-Q0k!^#P)zYk;#QzIfRT|Q9Ylu&`ZCB!OVY#vPo6$!ShIdJ%r3A4n2_Yb!A>j7 z(aeTNF$*rm#`>C6wfyYG>sZB^7zP-y5K^G7YYL`sUOo+`V^a%BvS9J-e!TKb41+xc zZbE%dtdB?qObi1ISO_T?O#?Sa(}3=18aR!@A58LkAiFR^Kt+bX=Kp_&PH^{$Ru(fbd;r-2vWr%B cFbp{W05P{?xG5Fr0{{R307*qoM6N<$g1~-(00000 literal 0 HcmV?d00001 diff --git a/assets/icons/32/REPRTSMM.png b/assets/icons/32/REPRTSMM.png new file mode 100644 index 0000000000000000000000000000000000000000..03056a0529785cb3489cf9db879e7c5291d46217 GIT binary patch literal 1187 zcmV;U1YG-xP)V90%~<n5nO$>%bP()COwIS*vFX`CA?ZuL4bEBfx zXi+8$mSP327b1emU<~iZbh@bQMSsTaI+pu)6V!Wq#<@$0i(KzH=RWs5&vU;Ys2k?F z9=v|f?|jeU@e%<5000000002Uj=8-9pq5>4H}NO`yhCy-H2*R(JS5$`iR)Y5tSxU5G};Q={%c0fBvPjon7?vFTdtT!qiSg+bIn@h41}ClnQ@5oQgi4{QP5D zxng<3+f~1{iTVewnbX8kNH9SxGGC;cF=;>d~)vbgfAo|j_Qv{X> z$zs!ReiB)QfM`nhP7w%BMlY1SR#6^zyZXI59qlgyqN#N06f-k3l$DhwY=5N*NI_L< z&Vla_$$4arRaCN}d39d)v7w=%FlnedNu6TXj?F?32KG+OKsd&z{lUYK|E1FM3eu4G zNvBx#Z0GseuJBVnQAd=F3J%}olpCI$v-fI=|yse+MDZL&GQtcTLWfh;FY30cUU(OIlbDA_L_oNUHBosJ0$N zcRsi-QSvIo4kyP^l4HzQWK-KuN~ zE!7a`P9m&=!CU`uz#Er=MA71^ETz!mGXgn4YbVwK+^=)?OPrs*(mvqVZ3$Xk<#r<0 zD~g*lGH|%~2nroVP}0&w+Nlxswz|}8-8!Iw?h%lkZ?&PaS_Q3jpro`6o}O-e4b0dz zEZqQ5pY#qqb*l=9*NXUPdHF_h0a=z&dhGbm2f~@(@eMmQ5DYHn0i>ABW++Oe&bydPZ~BmPRa zO~|-(-9TE+_}G{-ADV;3W&`6K{_$}Hzs-Vk1X4AASGQx>(B9`GqSK<#^p`1&3=P6J zJQOJoz%P+@%Jpb)Qa1wv*IN6#WEc+txWqZ{0P!b`@$>Up#-gijL&Nw3Wb6<&^-eA0 za0#skqnpwW02eIPCq=w!Ahdt>+p#K~T%jSfHtm7FEpI?P z!jg>XASv+!B)CFDTUq>z?u4B>{rPMM19lm5BBbSoSxoufCdI(+c7S8@2d6*olk-Wd Q@&Et;07*qoM6N<$g812QdH?_b literal 0 HcmV?d00001 diff --git a/assets/icons/32/RES_RL16.png b/assets/icons/32/RES_RL16.png new file mode 100644 index 0000000000000000000000000000000000000000..efb421c55fcb20a2d4208fda504f27b55e950227 GIT binary patch literal 1793 zcmV+c2mbhpP))A!!p+&j)dhbg7i-yiqh zckajUoO91P?-ERd-Ot~(ln|5xOrc<3zPRV~510k^Kc8wH*X!PviMIW3Zw&WF!Qc0O*Et>e2QQ~P6^;I6OE+29taO2ptCS}j-Muu? zrpTQ`SRN(ku%x6S+vyZzjYif?2Sug(C5c+^yQg3hd0U4M?QWklp#nVMc*`w~hxV&X zW05sC!h2ioTR^aU$s#9GQw%YAAQ;B?XS(^YE};TE+IipY?htN|!s{7A|D{U+V+xbm z*Eb@6|HTZKM%eB-St)Q8XHJ^?`ji{tu-YqWQ^WvA^$VpR0eDK1BxL6}h2{PIm%ucQ zr_O6z_ng``)!xcV$c~_`QLmR4uV1|YMx!n^*W5CQ(`S2l{;ezD?L9hW7VuQ#(XOiM zUwXT{B0_FCA-gJWK+cgF$k+yg#dj~sn?yc(c^qfX^?@Mlz?`z3C6cC< zh_Tt1pJN%hi!q{f`!l{73R(xmB1+nN8n$0|4Ye<4mO|A|=I5o!OYbd;$r)ofQs08% zkzku)O)$SvEkT+`Tbkg01#6og@8&&gLljDFWt+RZe`PMeH+*PqwShh8Ve z*8aDt4?i{cE0E}YxR|`hdSZE zbOB%p5K5Q*W655dN0E>3AGJdRP?#p;)d#G&!y)7Fv1SAUp{7BzZ%I`ZlvH@F0RDDhTzoC%&5UaRrpjHmsJUm<%BW!iZ>){ zY|*B-e68_k$f9BLK1P^JZ%RXI?t+^l=djEvhB^^KXml{E?!vmqi{^c@?1@xwV-n#$ z0DcS^VI7+Qk?_w%Gqqc7lZu!;D|P_w+EUo1$hEFtJs)juACe6^6y|3L*`kFx!UI0v7zzv0 zK?y<2g(2?qCjsnCsK7wer#G#@cv1+Zw*$R>qcGlIgoX37C(ZLXSoPpMF;)}}hmQUn zoqGQ_d7#YM$nP2sqgQ-8bF7nU{rQU?ND>u)K(k3Nn(C0j6 z&*5l6qBBu|g1MsZUA@AEhgY}+IS02qO3pDpK7kJRuo&mvl7^h@R9;`QC}9U3LEA)4 zh5eZsD*#GQ0W5I&mk^HB{|}!xv_Vxx1`ChGLy}0WU$N{~tXe(~W>Z9A3TBx;<9E*89tHPOVL>D#{QfIA{#h$N`{E)3!7D-VQUCdQ@Yvws zadENTi*wEW7#j=6QdL#7webhhSu@8s; z-5lFS2z&B(QK0-y?@kc#r`Qh~BhLYJ1($OrcpSJpMf!2S*M-As%X8kjY2V>*_A=o6y85B(i jQF8g)AAop*C&K>$Aw9SW8%Vl|00000NkvXXu0mjfFVB2} literal 0 HcmV?d00001 diff --git a/assets/icons/32/RGTARW16.png b/assets/icons/32/RGTARW16.png new file mode 100644 index 0000000000000000000000000000000000000000..d5316c4bba09ffc1ceeac157a70a33008021e675 GIT binary patch literal 254 zcmVR<3{WwfR@(*%GO9L664JCmDPav8lvp6y20;&z4N@#1 zvO&m0v<=Es00z7qN3-$X+fR2k)B6FyslQ*k{`;N z8VHir3I;f7b*h1ox>{&})mBRk1kKfx@n3$kLgBA@1L9n0WcuQ=w*UYD07*qoM6N<$ Eg6XVf^8f$< literal 0 HcmV?d00001 diff --git a/assets/icons/32/RISK16.png b/assets/icons/32/RISK16.png new file mode 100644 index 0000000000000000000000000000000000000000..72fc3aea32ef5e270c05509cb5a8bc74c7071667 GIT binary patch literal 402 zcmV;D0d4+?P)bD*0|~$+@5Frj`u!XO<^To;hJ>&0IS!lUo{$+R2QV-&Fq-^j z{D0aw|G2{dIe>wIk%3Wy;UD8}U}R)qVPs&MOli7cVxSyQlrC6I@=pAx z+zs$_5qWl^<$(by2N=mr7fjT006bm%XHc-O-%oTM!$L*-zc4WT&pb2PY6*zrEF(pn z1I|pcAi7O}Grjz0c)-ZS7QF&Z7bz0! zU|CC#$JZY1O0HMG zLa$zPXVTY~)~wR1xBuCTKfaeRms3va)Exxyv2;2Jd|*#~g{A$kHa|7}d2L0BrFyMT zdrW`6y>y|adbhiK#SU~3zytvSOb`&j1OWj|5D=HR_2{!iqK4DM@Ero;5|{4{$>Gc0 z@^&cV^iX_-fVjw;f$wtq&Zu1P7?aVlsMEvo1p?wS(WuCSSL4!n>76|63_Cp>&m$l% z^=V{6PPX*Q@f#my@XHUUhvQk=chdKre`{&~iHZ0*bSPx)IOo!jZ{yL}Mg0BeBht9FNXi$@nzqOC8&0u2b`gK{ z+6TFCcaV#Cn-CC>QTIyPo(yvlZxaIIQL2Ls4*%fhq9$JM?m?C1+0sy5DD&s?=hek; z&_jxHXGp`ALRq^!%juzb1_AK^_0(={WuEM+%9qR#PxJm)0l9K;nWg>v28LqW1w{qA z5ACaZd(TaMA7$m@+0s-~BqjNoTJ}Y)b&jod zk&II;7urykDNWl-C2JN>LQXdV;v!25X3EaWkSr?*5{`d_fVhM@ol>v0>gykHdMLg^ zKwM%+WuDVR@Fn^*V1j@ECI|>%f`9-fxJXA@pS5dMs?XZB%C67awTcb`Xm$|wuA6MN zG7oEnc+cz zHmWtfNe%fO&;BUkdZ@2^|g%NEK>yRlnOkXcv+BueccUB0@xXVX+#*i z=baeONI<^y_0-!0O?(01BEWZvz!>1^YVeukO6RS9f5b2Wy}d3;2*(BiG?HHYYh_s zN?hVY)$tQh6y^7_#cIWoN=I_8lh$OI0AeunQIaYy=;l0X8 zI$uJ8@Z3Jv$cP4sP`csK3(lRKcEnr2yg%BWg$YdEN5FnXhi9e>vwrH}2nP8S|7?{Hm6B9yWB2y6e z!w8CT#4R(~k7bz(ek_hiln=)yXpspKHrNI&w4^O<;r1SLZa*l{QYQ3C+I#Og?|Yx; zyw5%FAqX)V8o+C;alZj5EHBQmB&R6PDE5Be;hE<`EkI+9Z)W7V*&3v#s1zK?=eD7W zE563zhHG>AVU+SzMG3MU>1t_wUpK#{SWRfPQ_tWxkCIweKlO zlGPH-W(R)lp8`O~ol)EyY>W$q?*Oe~zV9nY@{Tj#f9{>Yvf#9f;Eq%`>Mc7iAeiq9 z#wCE#Gu6%dyPk1A*h@dCEjmCbEg}R0A@tVS)`7l&zFUL)eyU}@%{Pw^MBG}lKg|ik zURVhCN+>00uHD}aPB>oo(QU(e-=~G}LVctfuO-B6>boz9fAUhL6ZSz6lBtM}Mq+Xb zs3_w8)FkXS8w=?($H+?>8+!zg@5>^tb(rF@=nO+nd^nm8D3PV+@$C60JT zui)ra1CAyONH)8DZ!v5jXYl(G5|Bgesx8>-C1;3;*oEA@JuW+lD~91z^W0DO?2!ck z?e&Z~1d0WN*}LEU@dOkAf;e_z;o z>7;wn9pewTKhyP^6>~ZMKDsUKf`*1tK6=r910V+p$3dl1K@=%W#syaZrC-!t=&!;K zfCQS5M3@{+AoMgqA|zhGL_p8ieca!)6XXE}BvxvR08S!}<)|VvJp4J4gP>bkxoZ`O z-4!L;XF5l`U9q&Zfu9h$_bA9oLa=%Q`2nTULfSJp@!bsql1}XT3c#@~F5uGi#o^;p zUP)sU2&vyp-p5x_+NWR$?SRtja=1O|DcGzXAxM?*oKarpH2&;6Ld9;D%56^Pi1I+nYJk zkBM3%0H9B^n@G*ZzP}y(IcdSfqb2Y2vLM3d5TQ*|Ko-8*fO&)v*ZcH%>y=cDKCq(d zf)2|o;)WP5lmfa24bsYchK+v7LoUE%6>w|Bh+qC%JY%66|{;Vd71tu1mp)4r#ZHY@X{&_G_m-=8#oav@$VqDS?x0i{T z=v+)ptjm&Vq9#6=7~>Ko!N9;dL>>qklL9kr{4KVnE%)AIPS@7k$%QhdKKMP{oclZX z_kCZ#b8pW9a)=LKv%YlZjdHiK#&RWoy4~g?&6_w`yz3VJ|O9*W;@i z`UV4A`wocc8Q1-aQXnL$Q|&Li%A3+K-q?YcN|YfmH`K5ij$wz}^!jsE46H~N!Q<~ZeTb`a^^ zLR={+!M%0$sBzXpE-Vz&ZjGq>l(%iWu}A#V5r?;CQB{q754VAm3G8t-qUXZ*n4g< z`c$2niTizRGKe1(pF&qe$JTVoa5Ka$r|ym6VG?femWDE8Ugeh z$*r;FHKX4!0Rf#`-ejchA0Hc&{|GLlvbq|&*v7`kv9!1#cC@*Cjh{%b_1Te8pAQe6 z57Zxtg1y~R6qao)K6HJJ=u;qUfOn6&59m715h19U5^VZddLs#m*XARwN5!vk3hj6vG({rce=Ed`YzlVXlbyJLcvkd?Ucn)_Hf=y7%NGEg1*L_sI?FeAUM3`ZM6cjTa%FFz z;?M(bfLf&j3AX$009iJFP!c_&S8xcfo19r105n-#rNTTg!vSKm5WRxK$eE>q{|*fQ wcLS2~Cc3nO$sexd)WB9HFf9S5JD?GN0-PS0Y*LjBEC2ui07*qoM6N<$f=TQdrT_o{ literal 0 HcmV?d00001 diff --git a/assets/icons/32/ROLEOP16.png b/assets/icons/32/ROLEOP16.png new file mode 100644 index 0000000000000000000000000000000000000000..c49cef693a46a6f3c2ea00588954290555c486fe GIT binary patch literal 806 zcmV+>1KIqEP)oABVnIqo(x>@BB19qt2~-j+2*#iwBwF=Bih_`W zJ~Ze{P@q&RDGdZ8us*DEwWaCO4MlW&Z#V91MkOxyYAx^wk9+QY=XcMKbMHIv0IMD3 za5yBdKYRv+W&*O4Au}KZhO5N|S*M*&r>sSQ#Df!|Qwv!YOz8Cb!+d&DlK>(#bK~YU zmli&b9BW5>4^09DB$@VQpm`5z(HMI98tH(5G(%dcV`Z6@R(A$gg08me8Ud^lU@{T< zPq5&OJufxFeG><*YikvblHjmd=lb%(H{yaMG_J5hV!AoO}YPlnyqx~nW@ z0zk2Sd??;p0)xTuec5C-V{>7VYAYnyq)Y%Y82KnkOHXrgjWIH&OaLPq7z_B-z@ENd%+Abkm*H@h;c?0Yv|sXs5MvFD zAvpdipo)0*#Dg!vN&b2i0yQ|D9yyVK5I6jRG0h@6E)VvT7~RHzvjBTQVD|ua$`~<} zc3gP=CJ~noA8k9gl7{5g^@~gX1(rr@o=l>PKzWI{3~XFtO1rOTWc=565^tx}jwZ>L zEVspKQs$)l1T6cFFM>c&NGi!~vF@4d9{H&%5;VZlXfrA_)eF#Wy~%)_;&loAr@cW$ zW_d+q{UTdi>+A8%YZhR0*rd0ke;b^G`+W0N3zI#*NAelSZz{DDqdS5qU_-?w=rVOliI2`j z@p99S9^;29Cg#3%>V!Z07*qoM6N<$f)Yb$u>b%7 literal 0 HcmV?d00001 diff --git a/assets/icons/32/ROLESMM.png b/assets/icons/32/ROLESMM.png new file mode 100644 index 0000000000000000000000000000000000000000..79e61a1c1a4abd0307fc5f510f244fe4de313af0 GIT binary patch literal 1386 zcmV-w1(o`VP)hNKGDYyqg_og@~;&8H;wrnLn6icKJ3v;f0 z*$60IKz$P3W08S$52NbD!bB-{%+(aT7+tz_vMgbE2&v)>M z3(tS@>KJT@sCNg5v*i#%bnV{f!($ySfRqzg-}z<`HiCB$vNdujgcx{b^2j)B1O*{m zBS#J)241@G+G*GXTMV(z4jt@COPmpqht=N_V#*^heDd7PJacQ$-7+}9QL`%eR9Lx>d;&yhbWbAiz9?Xi(Sz+7%`@2K}i z+A}60jtfybS4zYMWaw#6dSrS!V6wlX-ucL~ejbEDe`WSO^mOkW2?WgLR*L3AIU0Hn zl9j_>rmRiX_`IC}q92&b&B#$c7x4S;wF8Km%2jee2>)iEI2mz-|3+FL*_z5#a)>hL zK^I5BKOb2(om&Z-OXX;2L9%xa9NN=?_SWW-C9y;jSLXiC)tbF9^xVUJd(hR{TC!j% zn!wcMxm>NuT%qSa-t!_JZP`__;=#%t{5$_+uGUnp$exG&`<}s$9i{tw_ih5e{Q6t2 z)>1(<7t7J;lXQJJVI)UUTU({MMsgIjna|A*tBm9*Xfqgs8KBo1$x+l+Np4v*m&?)U zf{;2wIWkZXvH{Am4h10vP>w<<2zdzQ*a!t7I+UX{6ogQYO`sqyhjKVfkgu;r^uuZ{ zetAtltY&HUTm7(_t2007M=eke2MR*0fpVCGg18XM;S53Ix%E~?a58JY}CW+_PTN#npRyLP%IAyV-L`bbr)fXd{pkN-NYR#i+{n^Ec8z`EG zRFEq}YNc*wG2%uF=OL=rWU53+t>#sW5lfLj4^g$7Wl;_X-9gkI4@d;dd@8Da5JA1x zZ0`1$sx6-j1hciKPx%D9P>u?rATHp5=fF1g+Pad!KOKb+5h#aE=ODxy`cItd0_2f5zo+IXM;SN= zaWHG%JI4e(8~3S8%p}wIV;<2IUYMMv9GgHv9E=oVV10-nS0Qmp3eVXuK0BBBQD0IP z3gS?XzBlj&(xOLwi72EDH+eB04o&<~?|#`03gS?N6tAZthrB6V42LHwS^GtZ^HD!p sTJJs(LI@#*5JCtcgb+dqA*e6^1Ii0+^xhL6#{d8T07*qoM6N<$f-ho;yZ`_I literal 0 HcmV?d00001 diff --git a/assets/icons/32/RORGAL16.png b/assets/icons/32/RORGAL16.png new file mode 100644 index 0000000000000000000000000000000000000000..c3bf52cff607b245b25553bac8f0bdb183d2694d GIT binary patch literal 411 zcmV;M0c8G(P)4;<}AVR0yNE8NFcld0&y79OWGz#9-sn& zIDtHNNXv<%cU#!qgyf)~Y0{m4XF8qy*+tOA>y5a0GQ$(S<9;&Od;ts4w1Bb*;2fmf z%cAY)YTTf|x(h5X0l`_g5kn400f7Yw=pd~m?n%5ezgm<0Q|uHm0_C<0K9g)aXX9ra~&<&Ca)CI?wk#^x+>CeOKT8S9b?I- zx?f)wpevY5%rHUZAd9~I|6eQM4TulY3;)4%17Rwx^MEONG3C=~SCN|!A>%7aF;)jq zP@0WWU#yY25h2356f$wUk85B7*@*v!6G8KT8{Kt|hb?WPf)8Nr>4fh_&u;(#002ovPDHLk FV1j!hsw)5h literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPADDG16.png b/assets/icons/32/RPADDG16.png new file mode 100644 index 0000000000000000000000000000000000000000..0a4b4ffb0f3f9e71493b49e1a767c52bcc7feafd GIT binary patch literal 293 zcmV+=0owkFP)e`uWZv_4F9%;5U?Emvnpp%z7S$YR!79$gFjPWd)~OXVaR3v;00S0c6^^EXS)*yd zY?!72MwtY?$MmR-KtNJRoZ(dOF4WqPiSd6T0|Ubonp+O4j+2`)#2E?o3vOOMO%n&f rLx5p`0n?}h7)H7S7;#CAnBFk}eNr}lMp;<*00000NkvXXu0mjf4y0_w literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPADDI16.png b/assets/icons/32/RPADDI16.png new file mode 100644 index 0000000000000000000000000000000000000000..46b4f7cbe321650f4e6b5f129981637bbea056e4 GIT binary patch literal 553 zcmV+^0@nSBP)eP$*T;GMS)quhL{`6k*K?Dww9 z*#sGe)fc*_CM*r?Z*JAJNxFv#C<=rCJ_*0=TLFc9dWOd6AaZF?ZeKadFqhK>j>&_W zkf)1O6E5*t2%w((X==EkfVAZ5aD}489-QL6^#YV}7!IItSTAr*O65J*6UeGXjLEiM zKtlT9&e*R|hyS=N#@gW|Y&iuSlZV-y9(m6N5m-5LWAD_H?60k8u~tAKB090`AH(tG zX0qlxSu{<8P1l(ac+Bq%BN#qN=`)fLMT+&KX~YE{uF5tr4EaBSzwtZ#+8#tGdTuya zFA?FdvE&=Y)&1k2Gs=fhSKSWQ@!{VD!dwt@-XTQ!+qCv-iNgFUtoX+fOK{1)(;FY$ zTi?-8(*b8z?vvw*zHkvffO~7;Md50Rh20TNxWY~31T!0b@}yoQ;Mo}lACJIHq{&DU z=b`=Q1rh>pYPkBn9`Dfe0#-srno=Xk5U$ata_O3K3S#TM7Dsn#S_Bz})fd9^T0^TL rcr7dNv8SZM&R}Qx?H@by-hmMhNXfuh^mEy(00000NkvXXu0mjfF4hGN literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPADDL16.png b/assets/icons/32/RPADDL16.png new file mode 100644 index 0000000000000000000000000000000000000000..47f4b386635cf769073ab20b692a9e6de1e041ac GIT binary patch literal 310 zcmV-60m=S}P)T1ZZO0e})hLnHXkD331mPJb3UANQea{2e$k_ zLpj1pGyseY0w6n{z55E{RiMbJ>6pA%(=qvf^3<9Cv;rWrL3V)bg4xT2d)&c6ereI7hKFJQC7hr@jK&cZ%-@JU9rWV3N<<^xmjDsQsMjgO{ zOM;jbObWo2wwM?OYY5z=ac&qiA;2`49Pj}|oH~7$W|kqD4Ymse;A!ALBg0HkV<9#v zgJupuwhJQ!q=dL@{xdRkf|^aVvzg%o$PSQQG_zwAjDjHt0Bq%>3V)#cApigX07*qo IM6N<$f_8g*!TNvU|2*tjU2Il4Jvy3kY&3HE7<)JaiEUAxt35p`_%IYj}4xd%`G72ANV0Lp_ z`)Kxb|I0^`N@Fh{6lC&Q%$FchdcdQcL0PX;@Uk@?0|KKy55m?aBZC0Q z&S&qwGBBv=n7mihG5LS;)S3VE0wB9Uc7p6?Vqky-yP2smR>%JQ^@|}rrx1+4efv(8 z06?-!0OSC?VCSyA3Bmg7{Xu4@X$qyi>F3Xm;bvV0Z8-@kuJwuEd4T)cFJ z;mXzPaQ>S&Zy9#(-b+6REJX4>J3AYgUa%N`*Wa7loCyJHu`x3<=n4ARn43@cWx zg@=lcwkB46rdCc2pFV#^5#!_KWrzq1VkpSXWMF1yCN2b)EME0h_mMXL$eN1DKr<6A2fOkA<*7Ap;5_Yyew%0u#d)I!xFM0cAH> z+%>gz!Si@}b|GBN>UA5yAw?-*LKirD{vyNm8@IshzyKed8o^l-nn;nssnch1ih(>t zFc&OD%4RVUVGLDeMJV#0KYwPhbMXcj%b>*Q=i`YYADfhc)6t-ufHwqw{`$r6=<#DP z+ri$3K~7EvLjx}_FGG;OFPQ!Q{RfQ1h|QNEv9#oPa5h8-jG$Tx!~msM7&v_NID?>o z0M5Mr=+P5~>o;#QxHvgrDK{5c~KO;jY6R24PVt|@S^s|}a1ISL0-E^~a6pVsF3jpc}UGu99QrQ3i002ov JPDHLkV1iesA$b4* literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPEDIT16.png b/assets/icons/32/RPEDIT16.png new file mode 100644 index 0000000000000000000000000000000000000000..b3a37c90cf046454f6fecf2469f844b5e721778e GIT binary patch literal 353 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=hEVFlu!8bOGN?||Nf~uU%V5wC)0uL$b{m6g`LcDvO5lc_;dI4!P#sx z-1aa>NJvP`Yq-Ryu`YvErS(YRDMLfUfBr32O^s`RhJDKBRZm^aeS#XxsNBJJ3 z4$pr{xcQEjjO+5ee literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPEXP16.png b/assets/icons/32/RPEXP16.png new file mode 100644 index 0000000000000000000000000000000000000000..a5042af7ba21a7ff3a87c53228c5ee61aa508bee GIT binary patch literal 554 zcmV+_0@eMAP)AP!&}5L-tbfCQKr z1{g4nI)GuYlmp~~<0norRMa%W`9#+(|NlSv&%~HWFa%^1^}+blx6fGRL6*OG`HF#L zz{n`W_>W;e(IMd963ei-Xc~izh!l!A%<_W19bh`sRT!^1(|5lG(-Vq37#J8CWQa}! zcb?y8@N0=>xb)x}12q8?u?o3Fc^F=Qe8Ujdnar^F;vxDwKtx-DflpSD;p>lY3@MWf z7?vDZP5)dVpe)S5!okAu{>~eQ%7rZqPu@JEe>uP-%?}O@CT1pvsaxkU{8IV@N=)=E z2RKEz8N~FZ7+zm_!SF}u55s@fKNzW;<|QE$D>DNV3q<>WmjCn(fnT3~fPMe>*B=I^ zFH8*Vx5+P1nMl>}{moZ~R~MgwE%!6`VBomP!oc{Kfj%Md<>^Oo4*387KSQ>65<^8u zK7;yHQ>~1Vez5EJjR&gki)308h)8=K=ySuK)l507*qoM6N<$f~iIK+yDRo literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPIMP16.png b/assets/icons/32/RPIMP16.png new file mode 100644 index 0000000000000000000000000000000000000000..e416089d46388a73c6531f9a3c9a746b9957460f GIT binary patch literal 647 zcmV;20(kw2P)F|9RA*$nbvj}hh2A+Z433Fq3Kp+w~lq`ARX#b77NlPp$$W63+;YrRJjI{#2X<|*D~bVH6xII*egZ|2LH|hu8UqAE z!GSHI;DF(6XcsgNSl+6D00)fpc-A&$0B=7}V5we##%YCLg5mKeXzps!#hpG^VGZ1k z-pA3%3Cv3iaQjQ)+vYdSWvz;fL;dI!!$_zq_)0JMYOg6iYel^KPA?+2dq4<*w?=?F zz-Ps54h1#a4X8;KXT>nYhy5UwpscO}PQjfKv$4ztIkx!QT&!8~#bpWYSI%KDdJmML z5Q3ZF;7hXNgvMXj!TX^%`59E6W(k*$hq1e6 zClo1;>Bk?SNQxx`Wc5}&_H5Wx9klgy;KAr4P>zAn;LoaqZ{stNV^Yo>iKVo0nvZLj z!->9=7jbA$Gm?smnWvv1&t_Kq!ql8Dl53=)jpW@27|I~hdLHGx50?k8V)n%}Jhg(} z2{Ym}Qk^SDRh8$XiHJ&K^X}G^>FK%`8fh5!GUvL8{q_(HyB?qDydKRwFm5j;+C9m|A9Z6NW h;XVMH@z=bLe*glnzAp8A4Lkq<002ovPDHLkV1nl?FKGY( literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPPGF16.png b/assets/icons/32/RPPGF16.png new file mode 100644 index 0000000000000000000000000000000000000000..9754230bf4b60e742570073dffac36da2d996d02 GIT binary patch literal 347 zcmV-h0i^zkP)zYk;#QzIfRT|Q9Yh!8q|wq13=^izg4qRj027iNO@bWJUE}o~bl*0J2>eA)q3|U-SPz tLnpZVL@SFK7(RgP0NF(=I~ax>007X1TZj)1Kh^*M002ovPDHLkV1mc|g);yE literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPPGL16.png b/assets/icons/32/RPPGL16.png new file mode 100644 index 0000000000000000000000000000000000000000..8afdd511fc68171f57647287dbb98fb097c34d46 GIT binary patch literal 344 zcmV-e0jK_nP)zYk;#QzIfRT|Q9Yh!8q|wq13=^izg4qRj027iNO@bW+_)#0uO2A^Pv+0 zzYk;#QzIfRT|Q9Yh!8q|wq13=^izg4qRj027iNO@bWflbU?HRcJx+0@2~y*J=!5_vK(5b+eh56I(C64f z-~))be)A3ktpJkQV7ov7-ZP3$F6f|j#{>rc|7Yl2I(GtUzd%KXzXl`$?mp4VVg`l} iAUi;I(aH{nAqN1O$w+E~aJDP}0000zYk;#QzIfRT|Q9Yh!8q|wq13=^izg4qRj027iNO@bW<=K~`pr8Gv;s(GgY5zVc+V(0xuApA9TOP%|DU0A>D&pZ{Q?yk{u+=3xcfvaiy0U` jfb0O-MJqcPh8zF@ai2?WKm!pE00000NkvXXu0mjf9uk9S literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPTGLB16.png b/assets/icons/32/RPTGLB16.png new file mode 100644 index 0000000000000000000000000000000000000000..5622da35de21e822d4e5dad387a8e94034696d69 GIT binary patch literal 1021 zcmVpcXEUQVZ^nuG!JT*C<-Bu# z=e+aIIRkuRuyg``Efg?J-T=llDY1ny6w$eqh%kmHkh0yu&0mJv&kp94fL{v*Ovx`u z$%0@IAJihDGbUR&Gn+Cc!sa{l)ifUl!!sVLgoIu#M6RLbxFzaP4qF#(^}d>9fpIp^4SU^m>Q6L|Fc7NW+>c^@X@ zM54^4fq|pD`zh|V{teSKNpt;hd-_PQyU#F^`<-L{Jsc1OXDC1kZwO@S=j-{gb z#!r_cDM^SYbP0#wztar757=A^Mojd{d1Ro#EX}&Xj>j9v44%w_oh3t%l!KrK*}86n?SNmK^mLg3IZ| zbTm3kg3}?@YsOd$wbZshI+dUu@3Vn!=+>4crKtrki z#t3$IJr&(uxzCFQ2@v9wOub(VH6@Pac0F4(ffOR=<16P7xl)vE4sd*8h+HYkHU~I9 r_dlmt015NJqL6(A7+M!?o#F9Y5z%>X0y^JI00000NkvXXu0mjf!lUi_ literal 0 HcmV?d00001 diff --git a/assets/icons/32/RPTGRP16.png b/assets/icons/32/RPTGRP16.png new file mode 100644 index 0000000000000000000000000000000000000000..57c3092c66f11092d259973fc8ff56c0bd5e35b0 GIT binary patch literal 439 zcmV;o0Z9IdP)*;;nScq0!Ng!N`1|Y6{`jmC33464h#ms{9koPh zZ0?-Q@b3Kw821J<8;c`3A;E$!AR;V8ltv~dNZ@gEaWQ=T_DusC5+pl+QxM zBq#u4YLF8hOq4o+i;I&XB+!>^N3c-pfK_WZfurO1@82*XkRzTWr!Sg>fV`|UnEvwR zE5oNxpBcV?|A8VOpPmoTDO3poMn*=Wd_*c>Vi;h+f=goh+~russa;|+5orhmtx8Nr zbe}Dr-H$g7P`kurVIUJwtHfj>H4RWwV(!{=02CT1j$mS-6Tnqsvf$E?nH-72&q|4+ zNr}nAKw|(ZG2gs>2QD$O0Tx=Pfr9KLumf=A4i*MF0Bku1mOEI`C1O(xNiv+&kU~#e zOmG$>!xn}C04y-ZlGzh{$uR)kN5iK!q<P)3isRBh_(OmYK=&D;5F7j<@QuVc zjY%nhi9di)H^5{}O2K_JI}|_!GaHNK!f8D(Xb}PmFiX(*DB^#A{n;O%RU(0|nGu(% zgyIwy0{tDecwN`rIhoc8Ffq^x z_3}IzyH86YwkjZ_}EAWK>=|5VgOKXKnJkg!9tGZ9PAwZKYsiG zTmI?uX9gA)W`>2!HZZWWvlG;xnH-72XCcS(^0E?!OP4M)Y}&kq;qTwS3`q$wL|Kjv zu#jW9x|$k;gt$1vvEwHg4D@suN(yoqn3Mf#qv9FHu!dj-jW|VSo`t?BBniK9N1z=_b&(Gg@>q^hpz tPAOsTB}Dn0kzotNe+D0lY-eP+007caW>K6Yg}wj)002ovPDHLkV1iDjD&_zH literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSATSK16.png b/assets/icons/32/RSATSK16.png new file mode 100644 index 0000000000000000000000000000000000000000..d95fb35b9c338c7863e371cbbb1dc7f75640631a GIT binary patch literal 688 zcmV;h0#E&kP)Fq_{xV{;rD>^AVNlYIE~bzW7d7z@V30%?7w|`%iiB7Pl>rkcT}X5= zad6RSSfl~tF9zbKAwYlFHbsM4n>5(>&fMGLpoNmRZK{#)a+k|<_x(I~&pp7lw)MY@ zJg2)wJq}7vz9S?17@90~eG<7GHgrJvMx-VHhQH+o?!0+Ww?l6Z_4E=U2#6wsn7%Oa zcCIQwJ#_nA$XYNJ9)YO8v_jwj#)pIVbB@-*v9V~ep#X)lx!GcY&%Ym>fpa#;F^=(#jMcKig)W{bX_`}P%6Paf+qiV*(uw_Yzd zqzFlWbLg3`n@id34!ArXea=}arXc`;(BD^P`nz~}jf+xD#Ttm0uhOVwwabEwFD>F= zXQ!UI)Tfm!(y0_6L{XT;Y(rb|_;BzZfB{8O;A;2inWxh!2+l#kwTlz4{^)k9(H>q& z@~g>e*EH=+G9D`}%FKzbU#eg(RX1~YC=yUO59o92=Z<#UYL5_9jOTX0$mX3HJ&4gl zB04f#cK~nbYCq@VDX4m1A%Vff%$3Qy0k}hv0ONcH1Z%5(514AI7$*crVKoB?6v60Z zGCK0CW&mGkv_s>{OAz+$X!FAE>Dn|tpIt^S^+7^>C&u~`(eRvM09R`}iLDm6(LcfN4h!HzHN2ccppD&RuYL4{ym_%H}=<2`q07TzP01KtP<5 zqthP%F=gu;iQw=Z0aIHfM4;wYyiw6@&cJ>_Gc;MO*#K&-2V~}_{^1)Cm~X1TH2(<_ Wci6JX*_aIg0000p;!;4JyZ~(coFpG z!GlUm5o~Bh#e%&m(r?ljD~-lrsM#5rX%^b0N!m1P@wv?IJMYZa( zr0wS7rkHon4m{}g@nUG~r^e*?`{Vg-af$<$y4MAr!)s)#6NTOlnLGa%4kU~NXV#Wj zqGY$g=zNPt#Z}9m_FNjZ%mML}0WfGdVUmaqiX1a_P7PgeIZX&!0iL1YlU*YpW=a7{ z3MJg{)ST(E^fM6BW}14E^i*{8_eV1O0Zil4o35jLA$#*;sPVB+Nq38Qe{c=O)-g<=6{UOM^BAv-sU3%T4L)cXDM znbFN0O8@{azpv=jES8NizL{eQ00o~EVa#QGoLdSNXK1w_x~2>tg`z zilU&l-Y+{}U5$b>CKlhlHS$i}ck6CJ(o@kPPP?w_S5}r5H-n;cLI%6{SzIWu19jR! zNMS4_pPk=>^{(|6&Piq|dE`wz<&DWCO1>;d`ld?`(4gIEV~mf16n2SlbSzKZepE7m zI&C0C8Jhxuv%*~os+R4zm~)2odJN#mfRalqk-qVL0|c~iP-n_p5Y!y zzJO%(vw-+TC_S?r>76P18rEuIpUxCvdyUOo4R?K0!3`W$K{zS{q7^4+?73eHA1fL_ zF z6o8>zhc2H8p?iZiYTUdnm<<9eCEwR7{RNdB`|M002ov JPDHLkV1f(-W-tH% literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSCSPD16.png b/assets/icons/32/RSCSPD16.png new file mode 100644 index 0000000000000000000000000000000000000000..5b5c3640fa1f87ef63a5ba8265e2fa89d0c35874 GIT binary patch literal 783 zcmV+q1MvKbP)>7yl$A_MR!iS{wkS|I^PnxKM5QX+21X&Rw z1o_}Yh2cXqQW5pR=Lp5Ab6KGyR)&6<6A<+*m=i|HIch2wo&i9>jFYv#E zwAedXIwu@?<|KQu=djP@ z8FN~DdR)QS1k6qGXAfuS?(G}O*k-@^mq}!Ctxg9^#ZgF-gyp40>;wWWhAqDzz@3cM zz(BjLA+mVW)n=TjK8xyewP?I_85)fSj1c?dc3XMI2oPn@p+v6L>UQ;c1|v!YL6IpJ zvdIVmfGPVcr~OaRu#U2jO-fzxfM1rGgUq`nm^G=9}LcUGuj0{V@|7F?UE$fSKZ4Yr5rgS z{r8x!#uGVKJ+ zVqYVrbexgUd~4eU$`eL2BDV%(D68*nUHSa*W!easM2D49ItBth$4~^0&x&ft7=?e+ z3kD1eVxM=_)%D?b0xG(|B6gQcl#YWyf1uC|gHRRMcUxzG&+~-`Wus-Hn2+UaZYO0z+wKLZ95j<;X3v$XA4(QTkR8yN{{vf=90$!;G-1?A(JenolW5 zVKT@woq)9Chkxr^F{ox#bp{yNHF?ahu!3-!`TeNM_qD3uQ z1VIV$z$htFDhLGO`C}nD*^KGvjPJe^cl?1r$lkL?DE+SPd*__*`P_Fe=K*`#({2}S zrznvy^w?&EMBLX#U2)z}|=ev3b?4kkm#A6YMXpn%) zP%(Bz#n`Bgh531vVhav5clBCnub#Re013LSnybcbCruD7@i#@AVfDSlx71Wb zB6k@;w^vWiYvO~1X@Iy>t&hcGtIZ3$&~-$QpICYzobj_M&1+&hy-)*?5e$W382dKG z4^&sLEF(n$C|NX8V0NM2zaxI? z2SE3e?6SC|k?a^59yWetW>6On!)1m&GJ^E?X)q&ID*0wn=fIt=mea0_heTLC^kvx^ zos>dZtFT=52kQ1DO$fr^7$=I3UnF!$9~5VO!^ z>x7m3ylsF6GZB$X&1=f4>rqj66kaql@deq`xPq7znrt1llD6+T&|oHNq${4Q=0@dV zRMc+#`TbfdSJkLm<)OTM14tH+L1-)uR$+g*30O1xe=DLwjjB~11us7UwdRc$0PUj0 zK-H0EkS4r0Ut!Qhp;mb)uVqhf000-NM4${Ld=1O>5JE3_to8H=uyfL|+X3{gg8A8L pOb)&H5553nLWeW7Bfapi=_jda)e{j@rs)6x002ovPDHLkV1lpYPK5vf literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSRCCD16.png b/assets/icons/32/RSRCCD16.png new file mode 100644 index 0000000000000000000000000000000000000000..cc69068d991115eaf311c85b358f702077560bc5 GIT binary patch literal 817 zcmV-11J3-3P)=~TT_gMP2X&*;gM^1j579yOcB8PZnb>+ye$Nt)!8#-gWLf^DmOi9_gRg#PN!S>7XnhEgm80{ z*^ENleyFO7iSaQ6*Vbw*i?R&h+Lk%cq}fh-dGk|es$epiwYYD22|aH*H8LV&wwq5r ze*0SjLR@y*nL|?^ZqAWuu_7lwU%RJ5C}&Fu08Beyu5>f#dW^DA&X&x80M38Hjltgkh8ta=E_QJNr9^1Zcid@e)9dD2m9* z%h#08%y_^k&o%CSTV2z9ZA=0M_J@^}vM!LsE)j;>yX8+` z#3Ru5DzrGOt4h)38iKs4&2FO9_0Asz3hj;}l~S%eBQ3iCmi&^q1^s3Ve4gQiE=4+HG)j;R0w;hCFXq@C*(w!z z^L?hQy|CmJCsdTarwBB-3ccWSz|{u=K|TlV8y1noq*f4=>`31UYeA{D3iTi}_mHkU zMWN_Y!Q9|N{la8AXKIY00000NkvXXu0mjfW-)d; literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSRCOP16.png b/assets/icons/32/RSRCOP16.png new file mode 100644 index 0000000000000000000000000000000000000000..dbecbc36cf2243b83a7f2af9106a0f67f75d0667 GIT binary patch literal 787 zcmV+u1MK{XP)~bw1W4cYQ%d_!ka7%ptKrq_w@EpkbRJFA&rTpA!;tj|+Sl%? zBSHxLxM*6{Je z8UlVlz=>M$5!D`vM4HB)Jw<7`O`CZj;0I?6MAUn;e|l9n0RrMz6VCpLBr+hbQ=Fq$yIv)MQpH`QGJ_y5G3M`wrTp-3eRB6zAh*~d zjtDbnY{aIxtI|Hx?Pt2Z9Q;ytZUG7oRf8l$a*muMxcCO);CrzivuSTcf?TxumCoeJ z1&CmE9D^ihi%d9oyc0@tR?0p^QbM$Z3`5Ga0C}eYR%gfl;tX)iW|Uu$e*@wn_sZwY ROrZb(002ovPDHLkV1n3yY+C>T literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSRCPLMM.png b/assets/icons/32/RSRCPLMM.png new file mode 100644 index 0000000000000000000000000000000000000000..0eee8b6c1aff6f94953e5ade456deb15bbccd8b0 GIT binary patch literal 2949 zcmV;03wrd4P) z3v64}8OQ(MwH-TgLLaHygr+o<&H?9ouOE6Z>AD zpXA!P=iL9boBQ{9eBU_%Boc{4B9TZW5{X12kw_#Gi9}*x2qlW!4eL~Y_5DOt?RECA zX=y>M(CYYaeFPmx2S-GN=oLi61knXhOa=XU^+SEn7UTm-3WgOXM1j}T$89l^+`=Om^4UEQpn;unW77gu zR+goiAs1ZdqWQJj9xHHO-adNPJ>Y5b5&K@zn%=yh(=Pg82ICwg$=5} zCW5%0e-@yf3Ss@)hj+J|QLm6BI^ibb@eR|oE|IgMEN_~+mabh$_~sKrd`#LDH97df zulX34nN6?I6wS9{zKD~m4ZY8#TXm-BTC9yiBd`ge%DQuA;*!f3YKK00e>b|0c2*|J zu+mg|1;%tO2*p(Gx58tOe4%UU+J!_UyDfb4+3j}iq2GvlnVIwojbgSq2LX@s>-rg! za@Hg3S+Ldp6pndY;F$LWY_&fGl=7VQbuHFT#8M=sf?}o!xuE!K+`P{@--Wrer{*+= zefC4Jx|%?a86d|@SZh|n-tYjRWN&p?i#1uBuff+sfgsRMz1tEFhqVX4PAxN&UZE*` zpE^&uRTL2038fTkS0%`;3g^igP}!Q<@Mv_EOgKSd*uGyL*P}0kOT+ z?YeGt3y0sw8Nzx9aV_`hyN-6I6bL_v)|*bRz?h;1u>|n|0ShOb<-p=A&l_`qu2ePV z);TM88EdjOUxTlu1hjmvafhc$iRfYhybOq8e(-BP_En})i(RkKn4$#{5EJ>?VLyY9 zBjR7JED2v@2!$niqpd6zy+UFNgOo?2YeF{LLT{gcF6UHn+DNWeBtEnoR!8=5M%a49LH3A39qtS7_0TwNCTRp1sI{~_j2otlvNB9Wh$@3KT{&(JKi5Xe1STIEw z>-Nn4<*3^<2h3MsL@ij4y@XZIJ z4Y_VUMk^!Qpw%_FUa??`7KHi9MsLRx>#LhoA>Q71z+1^wE?-M z>S74Qq5A%vFh`Cq*1`5Z>^tDq2AYb3rn@(KJ239hUHtFlhRaY^nSBa7;vd97`v-d6 z`;4tu9GId7(Ybrm@ec{g&-nF`&Vk$&)rdA*753bZh{uiC@ttFiKXfhD=4+r3B)^$+ z-F#_fV|&xD{=A6O|YO#VqFVbopK& z(AuzCwS0eI31X@xZ~8nyXDmW7#K2OLKNPc=14PX>n+?v23Y>_!@Nxg;P}Te-ECzy! z7DSE5S3kP0`Y8@f=0#Xi^cbp(b@LtfHj+s1zk0fS_vq$W`Tb=mcR28uZLeT3JRMK% zI*G*#2Ggg6%T&ymqHWS}TJ!}|Is~lM5+(v-ZmZk1tRRte$+%(|gWP)O&#w?Fy_anj zy>5=PYZEC_H!S}Sw!iuYKJrv)kJ0>cWhWYHLm6h+yDx3YZRT~X7FcZxLZRptmVo+# z+l`fSKP_`(7=s9vw8b{ug_<;Jq!F>(%W&Bxji{M6lAOp!xpBq!@WDrW5Dt&D0E2@* z1cE`l|A`;}?Aw0`-90Dpw_QD%+y0!!98;4+k82m5k6mvcMl=?0 z7DUadbrlG-Zg5?>dSjoQ@iGC1Ge|yALH>ckVCAcC>>JrQP9VnX&UrIA4l?R+`GN~- z;hN$+b&QR&^qSe&yRQe4=t%s8bwZ&i5Z5+%7#D-|?s-#tu4!Ca5_;oJNgAX(wBT1Y zW$jBsq38eE_OQ0M0wZfZQ zWr33uD=HkQC?EOuAB}!)L^zjto%2@-AzFAjiPzb`SOv*_c_qecK~mxzD|ohQ!Tfm{ zbsUZ|G}O<~2JB2QG>rBmpCcMgpJ3v14<7O$8jY^-bTw{8-PNmFS`t~Mt?N+S2>3Wf zgY%ij%5^$b*XVjhg4IYtK%UB-Hr18Ua-^Dr;a23_bEe~vCv`;|v~yX5r+}l;XtSrw z$JbZ|v_J`nL<^N`u@zaMl+V&~w$#vPS*z&hDiAlg-FPm)Q^4X$fHowO{c`v9N9r0~ zuQ({`E|%wup-rjg(BmAbl$Z0)8JTOzt12sCwPvQ9um)?fCTn}T2j1rCTK-cAJX@7m zd!7!jUFQuR>~kK0eeR>$Gubk~CHY*|U@g|L@xx&;}wML2c6je~p7zqlP=^z>%b;qgW=n3*~X~ z$OAQaIO`H!5znm88my(qS5zl8eVxxQDJ+KR7v6Hmy|)4M%mwpipHZqwHuO{zK-~V^ z)0>|i{r3vFTXg-kb5K3GBJDgLkeAipr**4zb3{7-q%Ge~<@i7lJO6P|AAh{8I_XxK z@oQ{~z6JTF;TzcN?7xX`Xuh!z9?tB-iRhp3|5U~?kyHz^+xvVAA;LSl%2MV*%+1aH{(TSKM=D1@?@kLO@>H%qTa`;|T;8(gJKs7uX1Y7m*B{85?k+JGhA{~9 z{L`B=Zfv*P-Nrdpx=G4xHf_s&5O$n5ed4KP#M5FyJL1r$XOmO3r|9WDnHESK6)n%M zB{2ntndUvyq{if-HV!ay4CTw{w61eCT7;U`LJ6XKI3k{9$t@ReBO#aEni*3VBz5CB z0w#pZqHDgaIdbd5noMSFPT8~p1hJ#nd0cMVU~)`jkZ+PylOzvugj{a>QvyhXdlC5(>Kz^lk+fVL$K>@J7gsyva=HMjMhrVS<5r(@ju! zT?qZa@Fs^wMnXc;g@`&GYW~1<4u^3tP z;AEWj^)}o3k_wP%HKO`*F>i0zGNh-jb{vXgZ0RmR?irKrc?{ArmXR-MKm_$CBc}^l~~}_Ru6F)XT1sOcj-ull<&AuO2mF$DN9c zjG+>s2nP)|b$uN@4j_v)u)D!y4yT0sz*yC;saHX3T3uV4FS6I~qTNr7kFsMq5Z)C})GCUC+yb zmUsZvSOeuzle=Bhv|E8$|MsBloUtd(aTb?~$$>miyIT>$tzVm0o%tDS6+|pD8_fE& z6v|xGgE*U<^R*72I6#5tVU-Zn4|cd)j8Hc>^x(yb0pxkw-CT$vFqqRUc5pRi&p0B1 z@Y*6kh=8*j0blEfV*?a=yiQFhpTUrmZYzMrQF36S(9#To^Ai$clW~4&&et*;_c6@% zcx{?cr0qF|%xqZliw{j?I_reVUMO2KlMrtm9`E_M0aQ|-gP|nVbOzRfQvFdFi!$5N^4QaREfN-=;fAjPWBubDXmHX#=PS pO)icN{KpOu#+*PPVfjx=e*oNp57yZ7a=icm002ovPDHLkV1kiNf%O0Y literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSRCU16.png b/assets/icons/32/RSRCU16.png new file mode 100644 index 0000000000000000000000000000000000000000..26ba7d1573d62bb08f9b3203cbbdcd748e63a5cd GIT binary patch literal 891 zcmV->1BCpEP)y z&rcIU6vw|ay9FxHRs$lmN{dn(1EGm1B*qjB!9>OQ2Y8S~FJAl^<3S`GJPr9aF)_r5(gH;rQPEiI?mRPF8!OUwX)PT5Ce7}?&YSmnZ)RQw_}|6M z4!nG#sf95#1Eg`#;OVQQV=Dr1<9MJXYKiuNv9?8j-C3{~cJ}lPX}JKXnFb_+7g?>S z_S8Vvb-bN?jUTbtVcW-O6u_~(Rp7EwcJ^2XZ{L3aMMYM_zVP`I1|B{zU=$+HscX;Q zWDCI4(iv+GBlARXsZyIAl`fa@E_i%QUH||x)>me_SmKvWP<%{Y061t+KBp#M8)Z)@ z^8OuWXJ!B*jZ_-W>nXT$viUZE!-}Gy(&;iXpPiin2_c;?ow@q#LS9e7g1xX)?si?* zkA|k+#*H#_#(K}@7+flC1!}kL@I!%LzE?TmuCTKvB50ux^fdAXVPgU&UL9*y)ohy- zOBuYru?>Ry8DlA{WKn?j1_jP_e@$b$NvSC_C+d^IJ)Rm^t-p_8vNo@oK&69_OOs-Y z4O<(U+@xzG0Nc>e;74ogo+TZ{*J(s2?;+PF#gjk0+qahqP4Ab%Yiqp-1X@x$>fekl zkaLsb$sZJBHyMMks>+G>_PyYoXDnW>O^W|9CE<{Kc61zs#bQb8s1(Pu%(Y3WOBqvb zx!CV)h<$u%todI}im~2vS4P8G0hm>RvkhPhwD}iEG$}#GulM|Qb4^M`mYSRY zj=2vp06Rg758_)GQ^6pnBN{&Qn#ji8`;LIKSHYpKVbjOZTh~Ztf(uJIqNUBIZgh;$ z8GLf_);|LfsvX};cY&CSLR&ewy7Xox5{S-+0fGk3IzmHTk1_&eQgxu)tqWxY3>(&z zZGz3^OFRDSyEj;vnUD})80W3Qp$lWnypa4>WuUuE7fQbjUgW5N&AAnsRJ`7e;__;l zW(f&#-xcWIk~M%z>P;~C3X0dlzNyZ*ubEM4l@}6NfUwasKtlNCGG+ykP^wLrPK@!C&>X8QzS;olavj3s1OF6YWh+1!cLSkh+fUo{SOnDx R+v@-T002ovPDHLkV1g+^oQ?nh literal 0 HcmV?d00001 diff --git a/assets/icons/32/RSRCUC16.png b/assets/icons/32/RSRCUC16.png new file mode 100644 index 0000000000000000000000000000000000000000..eddceb28fd4d9d430fe5a333448d00dcc8e1a9e9 GIT binary patch literal 1045 zcmV+w1nT>VP){*wFeobPpywzjJ|C9VDMY@5gN&grFVZngTv>v~PIie<5)Ch|dx=MK6Mo&J|tfXKdx~pFDX( zD+U3o*O3lhVK!rvs}ad$5)+Tckch_*StHRXfDcMG1HE$E$#oIDYu|oURG4M^%!}u^ zdgZbtqjK*0^wiDqmnER&WF^-eGV^qBfhwyFwN9seXG+SZBm@91*H>h^5^SN3@sv$T z2q@qK;`#W|n4I=BrlphT;r7gT+%A|>XY{G031?P6}1kh%sd#J1ZPYP`r@;` zq2nbb(9`3i)=2aWC!~9^QDjcYm*D)zVrc`()!6j<4lh)A#e1C{4I6EwjdN(>S^mpj zukuzgwSi^@-@3gMjQI&CvM(4G7ngnewyFC?i4;>CNLJ#Iio0uZNB@ z<#P^lm=M@k^TRnJ1pM4)g&o&Dj#uJoIEJUs;sADns~)iV(89hLlKmn$2svhCJyHb8 zu~DYz{|{thJUEXF*CxSON)J-7t#o@>+}CZ{filb5RsF?h!+7>^SdO8Y9esUYXBjhU zL#%2Sgf5j^*F&MX_XrlIT?B94Vnyw`a$LSOmD6;QAc1|=8Q@AKVwQFpyt29;R;LF> zaR131zWLCN_d06O?+;+$_pq)l6}Ja>N3xc#*4I<5GIbCHo(lU$SRKtUiuqU){*ixh zaMuR(cDwQG*bL5G3E=j_7e;?b0Lp2<2wt{kEo}8~$emLNzR#Hcmc}Za{pdA$xgC|p z2yk$z4R)6oL{U*F?vBr5H2Cl0cU)tbk1=d*u%OJe6qe?5q`T=1;L^|(j=sAIe>|B( z_o@4cCs?+Blo0;mX_@(r-@-YAmz+RkPLmZdcrT)BL-RQa-MMNk8b?IbwGf$1A^P@* zARhcRx6D-7q{mQW-VHH0C*(Dya7zf?S$&Kyfxu5E3aUGCun280^f3Al&oz=(LbS9}enB)6n;3=NV?o@Ai6$=DkYGrR21NrKln`-2Z~=)6iEfO# zCPobjE(FB{g$410iQx}Y!bhs5QcB;9nW;s^QeI2TMo#iRnRjN+xp(fn1MFZ2|2s&y z6Pl|EiwQvyz_03qg z1|(H3#hyb%9uVh9HW*>HTE#n+{G6B=0GQZc9_f0}Ut^T{IWaLHfpzic#OR1fdjRuu zvv5pL1C05Ymi5H+FSvE7=mCH-jYb2r#VR6qIHtiU<%`_B($ZTO)4#xFOep8ot|&^y z)Wo=dkVj5P)71#YIaFmJU2e2%D7A}s{X(WCd9jc&;+t^oc|Gek%?Of2h9d8W zAs3S6dhIZk8W~6>AuxsFG6p9BYs-;nT~GsNxjt2)8ZN$1XW9#c<-n$qaB&b)t7bp^ z21)HOm4atL%d~eHVfpd9QeezDEM}-!wvyj>=N?16J|!g6yR?X}Lw#b76pX;YPV=WJ z%MK!G)RwbII~PBiYe4Dov<<0i1_?|dJ7J_nH#q4=%~=~B)fAw(ASD`SL3mhRQP9!9 zfILeQnk({fuj-J<%C;Hcc=C1*0UXIr#+{1?#l=mj?gKLeorn}4#+ESb_<-A literal 0 HcmV?d00001 diff --git a/assets/icons/32/RUN16.png b/assets/icons/32/RUN16.png new file mode 100644 index 0000000000000000000000000000000000000000..120e05ce20f72e35378a9f0f4808bde290ee00de GIT binary patch literal 766 zcmVJx5M9dm;iiSOv{R5(89)tWqi6yR4m>&kK9lmgjNBEoYz$)ojJ>sb^FK*;8_ z!_(G)eKk%IdWejndQH8DVgU#-nW47XgUZ9zAYw8R9xL4~Z@gM-C5i#Ct@48|xKGwY zvWb4A4xNnAhAYi&C>DT_y~1IZ#NjFx5RHbxJ~U|RbrcIgNU}+At97XGR*8eg!3ocl zZuMpD%_g%^_6)G!US{ctt2k6;g0K=vJh@~~%0qbpY-=NvM6O~s$!t;~4%F#j9e)5WHe#EwV@j#9FaNe4Ex8XcN@p@cIH6*+Y**0 z7Pibee=c#?nQ<bD_LeKu>283oRhCo)Te#6WxgTgRiX2A@9{ZwUWfrk9kER`WHt1i-nG<(wWw w0^_}fFtz|d1Ax)Y2t70Y;JZSa|Cd;Sp9OV07*qoM6N<$f_9T`SO5S3 literal 0 HcmV?d00001 diff --git a/assets/icons/32/RUNBAT16.png b/assets/icons/32/RUNBAT16.png new file mode 100644 index 0000000000000000000000000000000000000000..16f2954cb1528911f513489b2d2b9f2458d81d39 GIT binary patch literal 703 zcmV;w0zmzVP)Xc^#hafNo}a-dc6j+ylVgeEnxhWmW)3dcrc*W;UUY{4sh~Z zI~cbobAK^im^gjAFI3AwmUj){4+qfRt3hq{h;mS=R3;<0ditFVWO>&BLf$|V!hIT= zgFdlO&sr9L7a58r;UHPwHGmNJC^!}G!0~9SI4aG=*z+^V*r?N-WqHSA*m<@4FK9RS z1NqMzuuMyoA4sJHGuW~WzcQN292gvR=vc^)_Pz)_ey=F|nZYJy`Oe|kV8a1~JU$P? zmo)g=T0|L!BySNWv}F8V!vTbt!V$U{MzAX+%`?WuUU;k}<1gFpT(DCKNd?$fAaX*Q zZ;N+8@!I?GMpH?B^G^X9k>XXr)!)kz@TY}pBW9)Sjx@iuu(^LK-m7FJ8tVW7#l<{w zpVp;$u{Z%wyQ0A>X?=cOx&vm#w9j_AP!gqRL5mE}i0)?e)YwWDr`EH0WqS|Vxiy%3 zhWM;+7V!jUG$q5Y>a)`avD|I(owe`S_?WTH2=rPZ-n**LOdl4{o&F$;kYCuu)|X8X zk+>dqM_aF@^_k*f@HIzZlns01RJP0FD~bwZH6qB!vI~002ovPDHLkV1oKkP;&qP literal 0 HcmV?d00001 diff --git a/assets/icons/32/SAVE16.png b/assets/icons/32/SAVE16.png new file mode 100644 index 0000000000000000000000000000000000000000..0355f6a99266112adeb69d4ccacae73490d41e27 GIT binary patch literal 307 zcmV-30nGl1P)32aunt{Fww=9Q3v1wObjF40W5?R%t+#+$byV{ zpN4n{5DNnG)}Zh=ObQ`N9}~j>1Ex_2Fbp;a{QvitW|m(Bo9tP%-oIe-xs0{tDecojBx zPG)%b{sWAAgPD!Rks2Yv1Y?K@3*p5~Oc15qTwEYZgIXcMM5+c~Z#M=ZK>?~cf{9cO zTwI(CA%VVBa|8=62}VXnMr`6s=1gFqCSYP1V8B91fxLaa#^3+U^BEWzEU0Yv5oX4} zsRToSMwWws4ajVQApo;nT+f+-k%^h%^h9%tY&Fe4$?*T*Uxt^L_JYl3B32{Fa%ur& zvslPA;)?SZ7j|J2K0q)8Kuu=`28I(vIFwXyfSK`cA^@;7 VXv+w=hp_+v002ovPDHLkV1gWesVD#d literal 0 HcmV?d00001 diff --git a/assets/icons/32/SCHDUL16.png b/assets/icons/32/SCHDUL16.png new file mode 100644 index 0000000000000000000000000000000000000000..bfe094f38886a8ed1d09f2d76c95f690da865f4c GIT binary patch literal 1280 zcmV+b1^@bqP)jK0rVPVmjIfJPmCLzYesW3<6gE3i11QHwLEHTS`B(`%~ zs&OG2KNus*rpPpzQw)o#E`h}ujN(Lr(4hi*umQF}ANL;fKjoGJ?QK~$zxYc|?&&%I z$FJx79|!oqgJmN$>G3%@VvUS3Cpan@Louy$jwvtaz{yKGvF$#NjZIJ!8bw)GHUX`OqI>;u?)46s3xp*YGAbCg3ZECRRX#g&6|FkHC=IWPh# zFbXI!A`%4n{u1{KCvKR)l=s+k0Qb>c*;0YXeNONko4%n?5T<@Vq_JUb#Z~Nn{>^n0 znDidm$G|#i9^Lr>qTBC*fdOWt0VauI*Uo!|T;KU05K%b7Q57m*);Iq0BaG+27xVD7 ztFFy&cy&n_RygDY73EBNVx zWJyN@*&thHd+|m~?k0Ce0-W+3kSW?J;ONfva`gDyJ~1?qEa@cd<=8~#fH9ctB~4>a zr$v_lqas65?0iopC>yz@$p9@8L|ci=IdQA z;;YY3BH5Odn-5jx59$(NT6tY6GB=8G^&-y2zQf$&Ov0AIY#~QwspRE!hMsI_Sdn%V z@tL5g@$a-cjl*XTqPhA2%9l%ZfqoEjOljqnKt*P~NY+{4K^*RV2|vl#p@tXJ>d1*1 z!ytfS>B=RS&R}|m;QNj#HRweCLIk=*EWdnTix&D(Vz|YbBts-0q&=-6o|`F zc@2e^4Q2w#CYNLl8;c9kZT|$TR%VOPo^q6iz z;!DmWvD8;~*Vb}atri5v#%s;F_HQ3PUSEHv<8ojf;t^V3K_LE;;rnS$EtOj9%|u>)E_U3# z9agK=2C!2#$Lrl|E;s&?VJ?k?`RteCv7w=M&t5TBgJeiH6J%KyL&P6b9VrVDy<{#P zaEpFU*I^wW%lb(MokAK4&13NA3kZiJF~)goPxEK*q^*SXk{NDn9HM?sEma!*9W>H{ zbA%`UOiSR}^mY7p;SVT^GQ(h~?`i&|H+~E{sOaeUdcav#Vana)w%ALWjJIznkn{3I zZ6{ELi_Og5|q=G{R1O4?R6qAo_+iov3;ul3??T;+V_UT(R#n@i5w+J8foS>jf1Y0^e`Bo7Kh2~cT+kZ-c18agU q9kPG+W{=)TIJ)bbrtXZ+N%~)OdkBB6mDc(I0000*HC1%TaZy=)Zi2mhE72Q5(P#>G(|(ZOVm`+(C8E{L6dGv)Y%H?u0iEAS^-Hw+xP~ zHZ{PK#{t3Ya!kXd>)5UoL3raHrx!C5b68*SRg56K@yRi_{Jf{Lw_*fo23{DAa14zD z5{eO|SvcLvMG(j5N01~bBS5-m7Emi52>E545P0I((L*KyYH-y7YH?KoEbxW{Sm6x? zu*B;QV2#%mzyq&2fEQj<08gAw^L{xcDIM<~vsl_lL43_&eqa<9#yDNoH*gS2%eYSm zj3gq^#)3?7I!(3XnzJ3Q=m!k>chq*~mw&%(ZYFrufbV1$$-Pt&FN{XS6E_H4MO5Q- zLzYk;#QzIfRT|Q9Ylu&`ZCB!OVY#vPo6$!ShIdJ%r3A4n2_Yb!A>j7 z(aeTNF$*rmr_NlUs^w-T23WC*z<_Dg0Su!K7+}CO z>HvmO2MjP^8g&4}NOu4WrSRiT|DT}~+z z&1(}u7{;HOT~lMVDJ>LCSDQjBcoD@?5e5GNh5B*vB&A>!J=j88h0?InLM&RPAfbvy z@t}wz=s^^Vh&NI6P_c(pBd&x7B8gywNt%@z*>$&?WRqrE#2tf) z?D81+_To9_u7qtdCZ3lh@k@}Nd5_QPkS*p?HehDYUhzwi`HSmp& zAzR}vdM|YMp+HD>lGj$y+a7hTPZ)E5?pzOH~Q9oWZM_n$UV- zoIm3R&4Dwh-L@T-BA0u^>h?`&zj+&}sVBVc^l_`$K)B%h+yzWWfBlvK#R?;rdxonv z)Y48GM`ux3a&s+)Spi+g1p6>y=XTLBtv@Qzrg#Q*9q0JxlPF;z$uyXjC=L8``~*lx V#4t<;e5(Ke002ovPDHLkV1lCyMYsR} literal 0 HcmV?d00001 diff --git a/assets/icons/32/SELECT16.png b/assets/icons/32/SELECT16.png new file mode 100644 index 0000000000000000000000000000000000000000..70d91c7747ceea5a2744ae11a0fb994f69c8919a GIT binary patch literal 232 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJ^`0({Ar*6y6C_?X7^*FOV6Uqi zVU*6KY*(q)#>l2);O6Kj70Nr$AXO~z)eH$X34`7W_6-Llj{TaYY{SCA=;r3O=V#@Q zb_P3z$qU>=GJmBUR6X`klF2~f`GP|Yyf#(^?Tq3HNfJ7W0<)tmHt;PdYf=u==U(`$ z>Vle+r3`0Z#MTWhCyy8$Xvn<6$fJChQRhk4k+3~{Zx_voXjtndd+Dm-IJ-lx~-Q`1YLC5BeaRD>cVK#pHS3!%P@TNGD9H1 zzeBdeNX1tI!bj1_O!uet&4&Q{2o-@QFb0N203t9jECLXLff>6L>4MTo#YNjD1mw&* z*_}7XRsuu_(2cMxc?)3Tv;qS1jtyTk3Bh8v44nj+bz%&%z9p<;_<+s030hN1=D9xG z*N)ILa}}GfdWPgHxNZ`M%Zh$`0`DeK-MoT*3kU*gxC3c#EHezRXO92?002ovPDHLk FV1lU`Wp4lg literal 0 HcmV?d00001 diff --git a/assets/icons/32/SHOWRESCURVES16.png b/assets/icons/32/SHOWRESCURVES16.png new file mode 100644 index 0000000000000000000000000000000000000000..dc2822c703b7f39a26013a01e91ddf06762d5f47 GIT binary patch literal 740 zcmVDQO0udJI@$c7#JDT zL1O-1&J0qLVsx?p+4ENn8@KIc0NKsNzyJw$dRdNUmjK8C0}5Ek)%f7$cZMTZKQJ7> z@sWXE5JThAdkkmqd?G0{ zSnx?+y!V-5$-d`cc4wk0*kWA3ScQ*aWrZ%ol+BMx3Jn%~abCOlE;tH;t;KO#{{6fs z3ZLiX83r#_U54|#eME%@6D|jIt$7GeXtE+44Eg@D45R=F#>?Q)09pF&=U;GWWKX*R z_6$)WuF9=!U_Fk#~( zFgxF0jzLC*gMpd=S12&S7$BE{N;(^DL53h}+SH7&P}q3x8 z#|3cZnwp4f3~ok33=5WAM0Ef&6C*>C8^ndQ1pbzy_{)LsB<6QY0TWG39d!T+fQey% z0n?}h7)Bky0O}}0x=Zu|NOpZ-oHl!D2i-fTF!29>CljcP3}QgK%=EID;RDD{klg@g Wya!u5>gNvt0000f~UdeIO`7B(HH4n?Q%4AxB=)#Fv}A_imHMDD|J-J@?-C{rB8+E^ydIYT$HYR@~#_ zhYj+Z_gbg>KgO74s7}33tj2@ZdF@lh7_<1$8!*&>SCt2?3%cunCj-R+`(C%||Nac< zDyRn3_rOtuj^k(e!cqI}gW4a@K%FP?BXkB*{l4Ok)2PAm_?=_B6UH+DS2|Ea#@<|g zK5_$*WG=ykS0GHg;{vI$@RV(tm62URY$kVu8Shj$1mD=nfMr&k;elshZf?o=Qr%f0 z;BL>PV1q!{ZObgRLv)bv$+Ou=C`2y+oaU#x|^g?&qG!#qCU*r(I zSK$KGL>f2CR{oX>?`t4BlfB1{`o~x*drcP}P30CL^oD>_-Eb+f(D|~p_S9=Hsc<4% zZta#j2$}7z{LB5cm`m#<)G4+=1CjK?v~zM0{eB&NOn9}JvqykOWh;Ll8shfH*Ujb6 z4y+07*dqgif_fc(Ek=yXy6`4K4K!hbLcdH*oe00)Pm2v?Ai%^YfD)ZpK#S>!ye9gZ zP{BYA(zxwczE(982adf$Qkn_>H#S6UQe`-BKl01RtiO@(tNQ|`t)4O0?EkIUL!oCj&2pb! nAiDX@v)$f5JS`X)ygo3Ao)_TlYR2>_p04&q4uLEMlGteSTzfLyVX!+LfV$d+ufBD0T|~XdAGymF=*@A0^@8DU zQQ*|+wZ+=J-}s*>(7eJ))(VFIvI3#70nbl<7Fp`XKN19Dr}32q1##-pv5#h=p#+`8_)d@a3@w zpeTtGlpJ1HG-{^f%y@$&7sQ3z>Y$hkq+bgM;U62sz_k!ge&xr}gGJZ~Q0kz@*=Y@e z<_st(t#P2LvKWqCWpb{6Xd0tqf510<0i{I>20pW;Dd2Q=sv`z_mxEe}P?(RDa|8&y z+s=%RGzI3M)^W~Z+O$QUykS=vEate@!uI|-4`#Ap#vj3yPe*xiA`burIf&XOC-9^QR{o^yBaA1M(S`I-w#qs4^X~(5%e) zxuI!x ztzHxyH)^Hq0)l+j>yh@(d(Pt2@u8dq9`8I(G;hbtd&}`@-voZX;$QtOc+z&EY2s?d zx6ufyMZt-j3)#iV1u8a8WB2{J$psc7I{Gg9@Z1w+_~6KP42{m=3aMsr-GK- zpt9lEuK?=6F$F@obaLDPP$K%2o#_>Bw@b@-MixhT-BWV>aFrE3tvl296#;a8J&xhY z5T*uyls=Y4?(D3VE=9d|?J!``??>vrt9-`+{?5C3^Pw^9{{i5-#6hPm=U-IPc%l>7_1=KA0d0c*(b3%deaUcwil7z1+ zB@KC12+V8p2J~MIN ze17I8h9~1!If=zJ9D#HhiP?$haj&~0`4R9#rNdP(Du2TL_9qEnht1jfh0fJ?L>iWE z1Me2?HQwQtFg2J@Bi@}BfSt6a%e4S@HH=U(3XD(Z{ls+ubuvjLA!@`TgtGWs)1TTy(g6JabCW11MDDW!6 zx(Ez{5@w_!Qd*{wSj!Df%&(l8`*5GWu`_0AYdh-3g8JROhyVMY_y3&3^PKkp|M}Np zBE8|ss@etyI3}=pABnU82B;CbmIA7X3kYzpv7R5N%`;2t>(b=>SbgpitX3PMCSZBP z<*+Qvk0e@+d)|G3NE9D*&h7RrUK2zSm&+Y?4I51XlzK7r>KYt#Be4-M+;ttZ!!1y{ z>X8If&^06)`SvmS@gdBnCn(jbkuGOI7j9$7SpkPwyE*~P3i6#2KZcRF53pxf7L-{s zzGk(|qg#I&o3uBOoUwc50>b4xz_%$Qp5Hxz+?-VG$W!n&k7ohTUJN2RTeqaS4-(0I zJ8U!1Kd!-gIl=y-9KJ>=MO%jnRJcxP*7T)cm^o!5;_C#F^PSfC*$Dz z5I*3~&=J%hT!zs>01M6KiJ}$|z()6O3Czg_UYw5mYF@6lkMo&7t>${WLzdmaCeU2i zL`qpr#kDv-r*NFn*LOwnsGk)W$@8M~j)Y~TZ2`s6H;aHU=sO5}dV#LK-|@T&#;#k} z(1rqW-=-+azT0{y6VUCuHyKLX0*b3|Z2`g5x3&P7`ZgAz?%P-(Chpr1KIqEP)F|9RA*$*i*^Wt zIvCxmLu*~6K!vjKkckDNF6JNBo!yyv@kU3son5ot5wi~-{NDF|%=i0!zqhkPkbs9B zg%v6#{RF7Swt&48bhKUW34P%^ns~gu;vA%gYnVIHa=b3y+HnsKr^{C9SX4oO&&>@D z4vPaO>=sY;Oo|-_-RT0vttMW)^&umnfxE|dxdQ_!I>;0hyTyUN!SrfvZ`A)22ipJ8 zNxGo;mmLU4bc|0%AqWJO9w%H5lJ?z5<)E01jA$<0=$*sh&WaG^dA*INpb z7LqQ+L_*PAcr<M4x{(k0*8PO99Iey*i_CWak;3`;HbP%PAO($DF4Q7v>f;%!D-i3(!GSBVcP6FDcf~ z%sXIf0U~0fBGnKJFB&r+8ko0fmHYE`Jh1!<>fFO^-#?YUh$<)#O$-||=eG0C zIZAV8GZrU;&}wc-vJA=BIRd~7h8Ym-Gf0MS0E+l~>JZgRgTcVseaR4_MO^lmgTc#V zfzo;vv3U_tRRWPPVH!a0B*YT{UfWRswJDc@c;k-07*qoM6N<$f<^Fk=Kufz literal 0 HcmV?d00001 diff --git a/assets/icons/32/SUBMIT16.png b/assets/icons/32/SUBMIT16.png new file mode 100644 index 0000000000000000000000000000000000000000..e66d0083694df867fbde99082b008f5bce4987d5 GIT binary patch literal 536 zcmV+z0_XjSP)9WXV%T?eR*X7L*VcEX~n`5`t$h(@Tp>i zwF#{(%&24UjXW^L#K_3-@Be=WhX4Ox{AXk+&F*=-gsvgr@2$-sCBetQz{n`U$iTRG zT8YTvX~p6?G|vSvz|Y6Q;O3;paR1>uhBN1%Fns;?%LW=PQ-A*X(@;3^;|GvBn&$#V zc_D^C9~}l=ElCC@CPo$pM#g-07MAN%ON3+S;s6j}VPRr0Hju`QmQs=JbS(!s*jX5O zxY?0~B;aY_*s2!1nhDkGFkpox)BXSdpW)WsHwo17^gOP!;m6Myhhw23p zI(Yr&E5pe%j~L#(`wA1nZCJW>NGbR-m=A^Zp)k;v!s@n%K_B+C4rvE_ z+n%_;nJ+rJ`lEAx~ z+Xc;?+kawJCifoC?cZLOscvfw#FvfB0P2bl>_=&h4-m*{y3~`}o&m`c2T#?v=u-A6 zLh*WDDo3He*zPH11qLJwRJJ#MWJu#n)um~^IzL?d+#6$y6Z6nxapWpZCfBQFKpgDo zXGgWMVB}jsw!4b+;j6EJ>Qb#SsT-IX`3ox#mypX;ncV-F42VNjx7GT`f{~v9yiw@i z2hWQ>2xa}v5MNot^sPy(Eyc{Iy-?LoHE!hOVI&YJ2?dkbo&j;7s?&8%x}jVaLikIb zFGF$F=9%1RWCb&SOu~rkW*|C4-NP4=!-7d}&ww~gRaui)serpQe`9Rn z{v77+K7^EV5mKB8^$cCLb+TE20ddfJ<8E;F3kh+~Rp^4Rt^!(qo;4;7iP_uJSelwQ zpN^{1I3Db|HEQ>qvjGF*0M%`cC1b(J4}fUNFDrz%_E`vZy(Of_bW9IVBDN5PguEIn z&`(T%J+f%`oU;YHSQ)PJbVFTS$N>N?`vV^9Ox5FX#O9-z`t80I4gjCmRC`((j=jYr zNCrE2s^J~OK%c5AMV^<-QQ#}u7+acJ!0ew7to4Qzq9c51uy@ymBT8LBhK@Ad`}gzu zUj_o^*WtGgjc@n!9Dlm;50Ae-{eJ7 z0Y{oHWYYYHGh|%GmFC79H*75{26p&;jwcvjT3yDuuJgE3q6gfi1=e~)$y>kpXRPVg z#lL7|84W86KAF@|8i#pUDaw@jXWF3eT9 zaHUlC&1vv&EgPB_{mjL9Ji2Bs#=q;jr(E<$H!CHyy*al#bgaKWZrc&$wd>cnJ=D?8 z%Z7#&eL@It*_N{5^7JBRM<2k@t&4vh;qKwCw{4wm?%*Ol!^?(`#%HYufGH`Jli{Ah zYj(~x*DxTCC>zR~QbTLFYltVR(u@IdK-qA$K=0u74SO&kHelJ%IT(;MW7*JI7?3n! z+0dC7kThV~(79MvOfi-XosCD36k^%X`H~JuWqbX9%8InfkVsfI1Q0T$Xr1UDylL}P zDOCY+mlUvz^#qDbgXabBwq-*A*Hjrl8R{9CvU{GC!hn>&dLY@C$O&7^hBeimv;CdB zFVRtYa1D|M+m#K&c2A1Z6Oez3bo2zV#Z|1#ST}ED+0cO)kkm6z+x{pu`Kehp-1>Q% zRO9|^4u~qnbJ#q+I_0`#+z7fl-EmB=G+UBNJm{?W1RV@Tp=VXbf4Fg8-upL@$28LX1HmGOwkM zB223h5-glBi;d{fRT^_xkO!;fBzXl zO)FBHWlxwG|0h10f0?p2;Xm>$2LTzVUW!{pG9aR*tcE1pYr0zCdWT1waMr06G;shE zO-vni011GJVWc~Ng$OmE=9tW*19!+VpYk>#s5m9YAZ(UH_2LBpdkapLLbUF@00000 LNkvXXu0mjfPT_f0 literal 0 HcmV?d00001 diff --git a/assets/icons/32/TMAPVL16.png b/assets/icons/32/TMAPVL16.png new file mode 100644 index 0000000000000000000000000000000000000000..56c2fbbd039837171397e1be8348d06549a5e699 GIT binary patch literal 1265 zcmVSxuuJ%n-zb(Q1!9#-Q5u#KoMn%>150OTXSXa#qhGQ!JNKS* zzH{%Kd%gkwV^FY(`u7uFk(et$oC{Fe+9=-uQ?Hk(sp|8&%i)q)8%kmwwu=iP6R1C) zkVX;QNI-6=U<~x~Dpgk1&E41xd45CLex_ABfloM(w0~`wK>d3O2PDbc36NPlC#61( z)IEC<8@EfHUzop*smU?in!4^w!|nA-#Z_nKx328#q(Ia``20$Ch57V zTH~FtHk2hQwCVzosvRe$q8?l8RcT|u!;L=j*WNn5K`zkcm_*0rpK)(lQJ=+}uo1Sx zXU*4uys121A&*^84#sIgF8)fsg7dv|vGVOv(RdJqjj&zc##|A@kNo>Gv!blD1C*|F zJ?FHwo%B6O>V>$%_s+E|e-MPN@X^Ll$?aB?a?jHa;DDb4p+!!aKc*d$)GM#8UKCuo z*zj48p_0$UT>$7Me@p&BesaFtQRMIhCIG1C+*j?v(0S!L7Tqhjb#G~7Oyi@*P^RO~ zg7Lb}wOig{D%F!~69|btyW`aRnXkI>^2gudki83C(=!2f`3(of(R$Z^lqY0)TdCuX zX17sn)B0T;p)_&MeeYC@FFq+jci%KVb@XB3nFy>h=tyXbJD$rvGNM-*zF&p`y;Z=PZ&I-_^OmE^x`40eM}#V%XhL@4r& z1cb1N-Y))&4!69tXlQJGJSiXvFOmAwl1s$JPFwS^-hartFV-*t0X9*kXse>Vc6?J8 zbSFd-Rmn+^m;>e*5LIsLIouJT4deOQ`y>95Z;s?=zpWjot%}i1Oai)-)BRQtP^I%o z>$iIH(Y(xbCfI3RjKEZFarOI)(N^U6N{Z$DAJMTN0(b=AYOT!rFmBCG^eP-EM#M#X zdj_vQ)DMygYi9h4Le~h;>%nP@b3oMt!b8Hi)oS)COPv9F06u4N4pxQL3B!fmYBhNk zcc2&nE%UP3K#anK(Q(p}$0E|2?tkwvOg^Brq*`k=w|gd3zsp^c<}7;W|>DJk{hJ7n8i}K9i~iel?-b= z?l-4t^+Hb$o(icBPt70x;?fr{2?;arWsHhSa-1G-vwQxsZ^xI3En1?g*2c)D^MWZ| zKW_PI<{2-tZm(e8zyK2TSgTe~DWM4fHHlpU literal 0 HcmV?d00001 diff --git a/assets/icons/32/TMSHT16.png b/assets/icons/32/TMSHT16.png new file mode 100644 index 0000000000000000000000000000000000000000..5229c0d780724c11270a55d0509027337dc9aef5 GIT binary patch literal 852 zcmV-a1FQUrP)P1Nc3m2^iUGG8EI}LDfl92=}M5U5m`i$ zz4>6F2pZC2VlNVbKZS&7QoAaFKUwSCICpm>WgEBM1&#V(x%ZwuGv~~?=lkvqGiB#- zECHU}zs+cru*A@-ljPII+Ma_gVtDX&y{6mwZ3CKq2~*GJttBimr2h%vUr#{4u*(;N z+U5TGb#yM<3dA1P_ViRJ=fYV{x7xaTO}~!LuH{+*AHf(C8on6J*;zi_Pr~2E0xgu3 zKp#07p29gZGKsAtn=;G$0Lh+P<*)~33x0nBeISIchD!e=1ON_&?*qA1_!WV z(@yM8If_-G;b>`pkE!V&NXt5dnF%L4S{pF@v7g+o+X`ft+3F|`xCv`45hgWw@}c86 zm~l=7CsfqF!j1A4jDMXL)kx1YV{6iW_l1lXRbQ2j0VP1CXHd%2Cr{kvxw!`Rq-G#0 z#{HtgBwj(I-zZ@!#+A5$m5`|B4GHnG7_08t zao|)P@=9LdP4|$nDZgAJ`5Rc_tdBNCF|(jpd=uYD3D7@Uez`6oTx^@ z$DAYh?%8vCat?l34IZ=v2&C;KucUBZ9T=La>}Kodck|6bMs>a%4;_poGVTDZm%9Dp etueO8%9$V@XVFvjB9{S?_Bn_5U#nqguXV88-noV|E` zKpem{AhwP=09zWM7MM0?8L{Qc5oYH9sRJ1THh=yy&SwFYV4(avVahCuO%&kgV+iu| zAgJ!opT7*7w(VwMWMHsh0u`TNM^Fg(`S}>agZ+t8%fiA8XEPETr`UXU{KQEHbu~2x zAt6B$oy)+mZqp7h%|x zrUS4!V&?3*^r;Q)u;g(N*uHZY7!UvUz@dG(eTfe+5vveXg;EP3o5eze`Xivm1E~I{ r0XRS~1VGKE{|pQ#Xkj@cGh-qEL*=5rV*ow100000NkvXXu0mjfucx)_ literal 0 HcmV?d00001 diff --git a/assets/icons/32/TPOOL16.png b/assets/icons/32/TPOOL16.png new file mode 100644 index 0000000000000000000000000000000000000000..0cbf173697bfdcbd2c5a83fcecf4a44a7b4e62d2 GIT binary patch literal 346 zcmV-g0j2(lP)V|H{rVh zMqsG>9;YHNInE423dfmIX0e!#Z>rxLj+|zO5g26_-`ia#*e3^kE>}1ne>3~lY6YEk z3-zcb(f}6)dBrt)PiNvkaE&RR=ZCz;Tww%;x`X(~tMN+wz&g~2yfskb2Pz7TAw~QE z;A1wShnxXbcEGnE*y^+gKPcM^(tcnBhKhoF`GE^NyOSTt_MWsK7=cl)7q9)`3X8n* sYTyRQ_JXJ%QY6+tAm)dQi175B0A4(ZDmu#n&j0`b07*qoM6N<$f`+k|&j0`b literal 0 HcmV?d00001 diff --git a/assets/icons/32/TRACK16.png b/assets/icons/32/TRACK16.png new file mode 100644 index 0000000000000000000000000000000000000000..915e0e889dabf7970adaa826c688936ccadd3920 GIT binary patch literal 659 zcmV;E0&M+>P)4Su`19cdSd5X4je+0Mnc>6E?cf9{;Nr$0=;edc3>I=M{(j>+ z!<$vh89wgW1-1likgza=NLVC;kgq=jGrs`Czwh4}zTddUAXQp{*DMxdEd^Qh`PdPL zH_MhVe7$r5C2@f)=67*JiDTj5PzFY376xV>UdkNs_seHU{H|Kg@ay?=uo%c9K05~n zk+28`Eg*i0Bd1_4_Ge@M&TcgUyIuT9}nzfcvM}E5{x3@kqmsc z_6)QFEXW*?MI1`X@Px&oszx)5u{wZ}nVCUl!BUbc6RJ7@1PED9C{BlNdjK7n=AT62 zpPp#WKnuXcFu;I?S_Y9DVoVGJ446h8z%U3L@BzfQe)A69EJd>G17mb@K?l7%r!esU tKSL)IsEZ6@fV<4}vY3J41ISL0-2frjv$C4^Otb(1002ovPDHLkV1lUD9$^3g literal 0 HcmV?d00001 diff --git a/assets/icons/32/TRACKMM.png b/assets/icons/32/TRACKMM.png new file mode 100644 index 0000000000000000000000000000000000000000..1c5343df12271b914b68c7a3b6ac945388acf1cd GIT binary patch literal 3401 zcmV-P4Yu-$P)Yp*08UpTZnL1VYFv*z2}mq@1PEW+Z#-OcsVRU1Kr9sAA;(13ZtT zecW%|4#&%$K;Z0L%!deMk;88AypZm=Z=d`7nSE(NY3f%-jH9;iASxrLuuQK*rBM$B zML|l!HH9MhA{>DrqHZpyLjSW#p{&5=LCmJDNUp%n#cmApS3PvG;u z0fb^a2a0;Y?dy7NF6Ti6LXa^oSv6rC>Nqhk^Pt5fzC7?5s@hIqX}$(43k#tfvl=at zL7e6yNDAVfBosgN`24=Po(~bo0>;gICbz3854&D5y%1~l_xN( z)ux&PGc>dUUxWuM&V&cw+rc{CNq~OX14DTb=Akl*2xNh9i9CT!g;9?s`C6Rf!W(_jp_@Id^JyU#f85jCJ2>6@ zuv=HBt>pIYY)swuvQ+!pKtniMl&8^ETTIBKX?cIw& zY}xLz|N1Y;JlZgayN(`0`9Lo!%|_i)eZIUuE(mBG2*W!xg0}M8(X{d&Bo(8dWxgN+ z$>G{0x6P(gsF^1z5!;p-^poZZ5;OxBL!-)UK)zB5t6GH{9X83gx1Z#~FWuSo77i4w zpZ4ciazpuqaYx#&PSthL+ZIZ5=6#BijKLl33JM~*vys{4=)5P{4S zI{UH-Z~F<~xH4@FVC>vfc#Jcdf60p$j>>;fi4QF8sz z8i`86{_~q(aB` z`1+rofMYm{Yl>_WTtLZcMB;HD6x0Lmj;?purOY;D5kw$4gp? z@$}1B(!Lk_b=Bz1E55S%+HAU$O^sONZyzlcDY8yhD)Od~!~-5**PPT+T`3D*Ag=3o z+>q|L|G$sUX)Vue=Lwuztx^hyUYI9H2*RNx=zAO3vNP$f^_Z{gHFrtLzxrbFN9qDS zzbw(`Yb2LPO)KOOt0PZ?FT!CMgS*j|w*)ShEuTqPIOPJ?20JG$73mRxy{p#Z)A#

    b0{IG<1bo@k6=;Be2G{p?x3e1_#HnE)HbfiY z4RoQ(Y@BgexFC`Mo#YQ*$^{Gxz>$r2q3NsFAyW4ta)Cu75KDQ@gmG}55>Hbt6`>(M zr&Lh4t}z&JVV6>NlEU^ADrC zzB~{!532PlRAU(JxyMC#^)a!*-Di$P3Aazkl_H>R!DO)*KXv z1QEy;V%qxSw6#gx&Sx(h1SksD<7@sm;8gIF<_UtdfTnv_pm&8CnW9fsfL+cz@uSvf z(}snmQWnX&jCTP$qeBUi5}y`m)g!%n<1liVoD+y?>yOiR`*S;=owz!{7?hZVA>08< z5D+mgK{lXFjG*%PizsXV&sa<8#d(6(LN)eR7*Uu(aZD#HoFe4{4kwfC6eZsKSZCm4 zY5&~h|cc3XG_gFdAZL5%}dF8k&r zr9701^|M=7r|;3;**Iwns`ZAOCXCNsCQ4)JJB@1&KMgD2m$s$!gDU;2m}flW!@}BR zTUVgxTv#|c&ILTpYOuUzq-rKr!r4kL3Pi?IyH5ToSp-ve0NR85VT*)N?Q$MQv$%?; zDUF_CaJ$$BV?G0u$_Rsskp&Xs`uS#XYV}Lfc)QENi4;CQ(mJ%U*Puku#DG^) zv)-e9zNPfJ(Uww2`j%1_)_E7mgs||9t8uD7j_dt#{LdGJD2f;~FsQ3Gpu?)dtA|<_ zj5u;mAd+QxB@%)?5<>Cb0oXd*Vd@S-l}td-C}B~nU@S1z$bRye7$!sV@ujT5Z2P@F)`rmT68J}^y}ya*HStY{1yfW?yP|I3l$Bh0< zq>yD^9xc}1J!vbM9Y(JM5P(Xm0AAl{^gMwI}{6Nyp zJtMOz2I*n!FD-?aPsk3x@yOe!mvTKge8gyt&;P&|+N$qo&I4VB+QvT_} zPy(zVzz`Ua6Jb&|TN2B(T(c;L&_EoHEN>|#WKbaPlA_WBk<;hIVB!0rf^hzwL5e1s z3pH0_8O{{B$^%X_V(YJ$U7D0TlM1U|$#VD}Z=i|2(S|d2wcJvwNJt_Xf~j*5%#i?W z;XxP%lGAq0vbm*{kU@dyz|`Im`ed9KEHkzYQUs|_r$lKq{%eH-4GD^=mmYr8E#H(a zly%v1%r$~i0j^jlZyo$-^zsM)>9x@mRXZRiY9-fC4~fz?-}6`~Y|ilibFS~V=mkO` z%uBK2beGkc>gwQA?bsvpSzPm(D~JUl5N31PP2#T;a*3Cpf9i^smL(R1Kp+qZ1OkCT fAP@)yWC#BTQ|QYYrGkXM00000NkvXXu0mjfdk|cw literal 0 HcmV?d00001 diff --git a/assets/icons/32/UNDO16.png b/assets/icons/32/UNDO16.png new file mode 100644 index 0000000000000000000000000000000000000000..20978aa7d880c647504d324a4ddd35928f95dfda GIT binary patch literal 483 zcmV<90UZ8`P)mR9lCeu*10aB1kug2rzFXs z!c2TCcc0i@H^Nv})2)d8!LT#W4l~d5e`cNm92_i&EbfrnU=tj_jA-`5h&mWw(#D0% z*8fz1Sw(JepFQtxMM43LvLKuZTsh9CQ_nxE07C>|D`0HDr3l5yLTWFX+;*8yw}`w~ zR%w?!ae; zJbnab=P~S+R40Nm38$Uu;21EKyBu2e%Ey>-0n$uDR|2XMe8b*b(8fCvg)bZfn7+kZ zt&FGKHHgp;w|>O)>r<8wMjMgyupE?MDgrj@Xe*)mk=tb||GGGj8i zdqN6bR3Gx9dn^pm?bGZoDWu;F#+Lycs5V;;;ca^Jk{BJS{d%eRVITJR^$t} Z-T~Mqhvkh=2q*vm002ovPDHLkV1j8;*2Mq- literal 0 HcmV?d00001 diff --git a/assets/icons/32/UNKNOWNFILE.png b/assets/icons/32/UNKNOWNFILE.png new file mode 100644 index 0000000000000000000000000000000000000000..f6b88928485e4bf410a062cb06bb7d3633cc79f8 GIT binary patch literal 648 zcmV;30(bq1P)S16a(qLjR82tV9XMcQFi3G6@U?da*{T;PL z8Pwc4nc?004>0ZxW;PZ_VnTw2kOC25A)*|>!~_XUZZ0l{uiw6DKtqC{BbXSd41B%a z7=#1`Kuir{qJxRr4&dVAWC#iLCE5`z)ONtCwVS}v@%#60m=MSj&vB(U7IG}P_4FIV zl6}t^t~~g{z|73ZV5Gv!z{Dxcz`*d1;men=SoOrG=PN9nIq?C-4p?{e6+_pW2MmAz z!HNk6h6gXdGjOq+G2}+MGdSo8;>#Tj6glA5({Cu23vjbA{Qbwk@cH{6hHpRrGECn7 zp25*XjzO506(e_0B@urA`Io^=ou7f3iIE}AQ-)zjixI<)7DEPqOEIuK$Pud#y(Gm* z29iQRUx}AtQieLi+t0tjz6Uu3g!BF77&ab%1y*zU!57*&00xkQ7zBR(`3Gl%5+x~s ziGd0Lk_ef>Y-1H(lJv4r!vVj3|7YOgWM&W(U}Fff7N?&B{{H*VFmKm0hFRO6fce4J z;taf;%=B@<-+%uZO6J^RIC2${$3fWXg z2FO8lb-=BsUl}qcUk9^6Q9*8KFfj};U||^PiI9n5fB_331+l4xG<5*(5MX53LN!|$ i87?SD2tcY#Gyni%MZ=C#vOxX-0000Y5PdUuHdYby7X%AS3yb`OK(JI2qL8GL7=nU!mV!YN5kU#Ykf2~AfAYexnpw3XSO7Y~uGXb$gIxL{OPQ{}j7C~0sh@hUfEA=+2 z@&O4zT`@0AdK}zdG|#*{xmZxxHNIu8TFjIF^jhyVZJi1Nnu`fxwgWLmbUAGh?N=}J zxo+ojxljj?izYL=^rIdwaNw!~5IyZ37_(CRi!@;C<4z_3y@OXSG^-toL7UT|wH4qG z7(T;nE%cO6We0fb1&~w6^X&Yh#Z)3-#hcVpGZd1J|6gyDYf#8ylpG6aB~R_;JxPCY zm}$mj_zZJg!qwVyP2O2Z<8BJvLU1{rgb^Sbae`9^wmdEfJ{0{_3 z`}yVTO?b8w6enlengyqR44=VMFTnIV;Ha~A-2ux|<5Fy6m}Bs207BK<7uN#1@aVV$ jhLWTJPhKV`!`S=*^2v+RX`?=;00000NkvXXu0mjfSj*O` literal 0 HcmV?d00001 diff --git a/assets/icons/32/UNSEL16.png b/assets/icons/32/UNSEL16.png new file mode 100644 index 0000000000000000000000000000000000000000..7e1d4a2a39afbe02a27f99a5efb469439e5aa7b5 GIT binary patch literal 543 zcmV+)0^t3LP)nJMa(ljJVEBP-ISTmCSgCjXbO$^Uk^@-SxVQZK{q+dQ=V(&kkPv2Ic!ACG z{|pQ_nAsQ>fY|U5SUejRilpTNP;i4R!{P|60BkucqodBj(=Vu!26PS{`~nJYP_UC~ zIS9Z*fYMejp^(64IS5d#8~`Oa21uM^1&j;~Zx|T3zF-lj9H3`4JOG?KK+#6E5ZF(= z_qQ0F`J9!}5l`;0`TOfj3B?Z3KX!V-KL*B$xKcZw zEV||$8&3UpU7MS1!Y`K9F&J;&pZw*~ro88WYqr>anHJC!e|o;#bb+qIu*wq7 zg%au0`}Gt>lEW(B3pp94P2aD(@XYx$XLw}wvg##-H-B0Pasz{>tDnm{r-UW|vHv$z literal 0 HcmV?d00001 diff --git a/assets/icons/32/USER16.png b/assets/icons/32/USER16.png new file mode 100644 index 0000000000000000000000000000000000000000..faaeace782e4ea443b3dcd105494e4fffe32537d GIT binary patch literal 717 zcmV;;0y6!HP)-9XfQV zLx-S4Vk{UYYT8y%lDU-!A+6mqb#>l(;#FHJ(Ppd_O23!+@qC}}^O<>vcYrNzX|s#g z(-e({w478rOw2VzFkqsm^;%!gh5%fO)Kw74TLkj`QhMxQKGV|Km&h7GdnD*Jh=vI8 zxN~z+xVs2!nt1m%fw|dPWl1>LRoT)ROIpp;>;Op6Wi?z4t~(q8(Gq`oMI~Zg4=^?P z!7Guz0HD=srm$+f5e?}eZc^ugU@$X$@hLP76;;(s7le~`9!gj>CX;jd0O>hyH*|gb ziu%sHyzi&ptN=I{^hq!qGcz+-n4e!!Po*-;K9LoGv)5zOAatpZENdcj$N8+G2CCDY9zZyT7_gz>I)s?PX&& zOo-0cFZ%EOHGooopq?cj((i_67}y{Oj*P?yd;S=}=dUW4CVB~Q2Le?nF5a`Ie{Adx z1_uYgz_df4_GNtF`MLr29SnL|8odDJ`~7}2G#rH$b$53m9*?VcF+mQk_SMtXe^6qz zLRndLzG=w&YIsRWDZ=3fSe5ds9@VQdRF-Xk1;Mw8;43I7L}TMI2w{28TJ)+O)vGd8 zmMs9^fkQO})VtleXl_0Mr_%|$Qa!3yWvDEbX&Hb`sjH*MHA*(x~XuAHfiUs4VnH2%$d22!)`epQ8MX z2os||QZ%qeq0|h`x8{hNPCjxR@4Y+DokmBShmRS5YQfCCvuB;N*52oweSrV?*TFVQ zthkz%!5Gp35(Q90QKh+cM-1G*Y|`3-Y%joA*1Er*&FO;k%gP$X?HEw|A~?lEG#bR{ z;~+^Ah6ehvY`5oyS#34|mjYIS3Z?Aq9T(3&lY@{DjS`=m{fRequM{&XBK`HM4})7Z zAb54BtT~j-o#Gs!VLC)aM=S5L;NS$r06@z6@=Vu5{u7hQ!3l@~0o1^s!vpF?7o5*`yCg{k zqr*dvAkUn!@|)Wf=kQtq!?Dz4sF2LxBf}AUP{-1UAdXJc`>A=1D-$rex2L_W+3yAn z#^YI#sh%!WWjwO@U-cCOk2pm_a>xbmv)a=rhR?})4gV8jIaeI5BiR> zbMcgfFyx%r?~%G2ys>@8tvE+O z4OkaMG<3|M>5J7PNAQ~(!Rl->u6Xj+f}ZaSYho)Lg4K_EfU0?Wb#%B@jDPYz#%~qi m7Ym5W`96B)>0F+J^N9yP1h(BWo&S^tB$Sf#TbKPFG?pXgBENHv#?;AFqp#) zm0612*15vt6Vmey4zlC++jGv3df%w$GWO-9-Y*jKj5n7N%h`lyCs5Ov>aeg2lY9ydvfZ6LZwRH~tv!gRx*rGaM(Ll3IlbzdloYG2V-tjrT3mRCa)x;F>lDp(`x zJsyuESI-#$u)}7PWtUQo(zTUrupNZ`xrH;osj4ckXd_aJ%5ePML*hGml7*u=9Ym;R z(sy?HP*Aj5luz6l#fhTN;UGIEe3&{6))A7XIy|}vx(cS5sjv7W7Xx_O+DiR z!mIKI0YvWp6%=EhjGNakAUre8SMt$omoCknQ0YvJ^tk(puRdSMciP=ffpiPMVT&w=L&s_QN-w z31`7VU@|6U@_1p)3CYUygV8kcxp+Wk7;HC_F=?_BlxecX@LwmW?}-XX6hZwjlD_R9 Xq{VyEB{^X000000NkvXXu0mjfCNS^` literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ALIGN_CENTER.png b/assets/icons/32/VMENU_ICO_ALIGN_CENTER.png new file mode 100644 index 0000000000000000000000000000000000000000..a2f22ac68a614a0aa0f3aed2f2f4bb9a2d1285c8 GIT binary patch literal 279 zcmV+y0qFjTP)o5mYC>?XK4iprrG6Mso!pQtdiGp$u2nljN$<5t!{B(At z2gHuB8u! zo5NQ;Ce@~E(<^#LtOIE literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ALIGN_LEFT.png b/assets/icons/32/VMENU_ICO_ALIGN_LEFT.png new file mode 100644 index 0000000000000000000000000000000000000000..f5d2e7ba68a3ef8d92b1604211be3754db35459d GIT binary patch literal 276 zcmV+v0qg#WP))qYGCW3tz3OyhP z;G6;D_IlWJA6E+s0jln=oR2k7IACdXwXyC=<_u5{fYbvh|HD!@plz-yiWP8w!jB2x z@mi_5zPWzFzZj7gniIF5_(mi(CtiOcFe0frvHA%=hLR6Z2#iQ-PON_78Ergl~U00009H##K-`v=^^5eCsmt_^?gxAU(IPgKf`>6th5c5e#2JW{q2N<^fIiw^g z;@G^yyueamK_Z6$`wX`|%n=zG-}nP!oFB`~mRalEuu*W*(+dax%k%W`Oy&8)mSv^( z-?8GtQpRP0>;^q0>>CzvCwQ+^)@Dg~aBZq_#ci$)6O@+l#r|Eu&FGdCt#@RV@?zI7 z^H)sc{`krx_`Flj=~k9fm6hp95(x)P9?2en3n=Y->XgNuK4EKz+rb5_40ChSw%kkU RybkmvgQu&X%Q~loCIF19Y+wKY literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ARRANGE_HORZ.png b/assets/icons/32/VMENU_ICO_ARRANGE_HORZ.png new file mode 100644 index 0000000000000000000000000000000000000000..e650b28ca1aa9c360df48d8b30ee7b4169c81e08 GIT binary patch literal 292 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJ*PbqpAr*6y6C_?XObp@8vRWp} z!}I@@q=bZJK-vQqo+ zSaD(*By>drG2f=S>7EMUv*Tr6nNxv3N8gJxZF|Bz|9F(dD%!l|`>IsPY_T+}N4gza@8l|h&e}8`msQ3mXcfwdtA?^lZJw@_25a%g`%*b~e zQfmR>+b3X6BVrONU7cb)g}@Gzr>IiAKyoJ>l@Oy6MncGp;7)i~!WUs@O*8!sB`k&u X)8lA@8PoQ z+AC3j2{I62Kz9u2>wI#j9skJ$5(f}uGOK+3wCz`FfFvE+w#4V3gUN1Tnb!;s_J^zl z;IwjN5RdZtj{vG5vtv;v_exTEfu#Tp=*}e0fWvOL3x$O~FoqJVAvgp2^u(_#B9wg; zwSjuoI8k(>>U3oq1g8;QCAw1Uh4>WA!jk78ggigSbB<#3NT??sr&-#FMQ+ zjIM0Z1|Z&ki{SIm#l%=TP=>{5EHU1_YiGOdI8n7_36(W3r#-*3?DX4 bonhb~4#0=j1g4jH00000NkvXXu0mjflS*;f literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_CHART_LAYOUT.png b/assets/icons/32/VMENU_ICO_CHART_LAYOUT.png new file mode 100644 index 0000000000000000000000000000000000000000..87c2b5a77d7d0f2d0bc19675e5770c0519b97cba GIT binary patch literal 246 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJy`CF*vQSBeZb!S+>G_2N8DR!wk&J1m80p zYxHaJ;o<4&ouK2G|KUG7v$C`5-?y?k4TW1&QY3Ua-FGoduv-Zl^-gPX-l6h`U+-jI ztmR$CM-%h-O1%!rZ(ld(VT(nBPI29YSfN8+Mk>Z~y=R literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_CHART_VIEW.png b/assets/icons/32/VMENU_ICO_CHART_VIEW.png new file mode 100644 index 0000000000000000000000000000000000000000..bfdf3dcc53c68e621cf665cad72a8fdd682329f8 GIT binary patch literal 286 zcmV+(0pb3MP)Ne|{|zXQ8e_Nlwbh~6-o6u{{Q0PaQW+5T7@8!_D*H`#2RM2I)b*p!y}Hn4LDPB% zbi=Wfu8A^6hQbq1d(x5WP?BahpWx8I=(1RT8j$Iz(8S|NIwBp$$nb0cu^Ujr#M2f~ kL^>Rvc)F6#uXGR@4?;do6*pO-1^@s607*qoM6N<$f(X)o5&!@I literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_COLLAPSE_ALL.png b/assets/icons/32/VMENU_ICO_COLLAPSE_ALL.png new file mode 100644 index 0000000000000000000000000000000000000000..0ffdc6e53f3da7eb471fa7992632781c6fdb7c38 GIT binary patch literal 162 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJOivfbkcv6U2@)?G1gE#malBWb z@^3Ns|!6F(m*1 literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_COLLAPSE_TO.png b/assets/icons/32/VMENU_ICO_COLLAPSE_TO.png new file mode 100644 index 0000000000000000000000000000000000000000..0ad393ee0d8320d084c51a703501cf75574b87d1 GIT binary patch literal 147 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJC{Gv1kcv6U2@46D_2Q(NMHuwn0s&)K`1KPsi>FVdQ&MBb@0P%<~82|tP literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_COLUMNS.png b/assets/icons/32/VMENU_ICO_COLUMNS.png new file mode 100644 index 0000000000000000000000000000000000000000..0c9786f73fd0bb5d3f723b624010af88f78aabba GIT binary patch literal 285 zcmV+&0pk9NP)P1_p*(SI#gFiVz^W9EeRV1k;OW_v1B?SamSK z#4x~sX~a8#5ylwJ1u!t03r3s+7-5XjT)^<3;R&d{4s#(*0mv>WV1kP=F(iVzO|-Wh j)HP#Bq`5r|Lj?c;n%PMwFC0lc00000NkvXXu0mjfKsave literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_COPY.png b/assets/icons/32/VMENU_ICO_COPY.png new file mode 100644 index 0000000000000000000000000000000000000000..05be78f95a9eac9bd6b3092fad150115722b75c2 GIT binary patch literal 545 zcmV++0^a?JP)(Bo9tP%-oIe-xs0{tDecojBx zPG)%b{sWAAgPD!Rks2Yv1Y?K@3*p5~Oc15qTwEYZgIXcMM5+c~Z#M=ZK>?~cf{9cO zTwI(CA%VVBa|8>i8dj~{1dfj1zkkDoK#q70N>4Nm0eM+zF#YArSB6iYJ~Mp({sTom zK0P0vQ)m(bg*nM&`H<>qfZBisT_85K5U&O~gFJA#@t@&8p^_5}7#SGBQNzgkNAlt6 zX)h>Fgy;qn3;z9P*)MOJ<%sSGMp#L>cy>Qt0~i?@8IeQa=+=6oEDlMU$ng9nqy+uX zz;J_!^$&_8SQy9zGEzcBsbgk_Br^eiE`|>uziFU{1PiHYfLu_K=gu&B&VGic&p)6z zf{B4n02Bhv6@CoTk^-O-3+4z3j1a(;7M9GJK#>Eg+cq#TGchsz_z5XNL5}$Uo8>v# zX@FRur7q3zrhx9`4Um1m)K8kpUe0(Jnd+`+;?2Y@Zdz;Xu*r9PK8%qL0x!}AkS z_)H9p3|klm5U?znJ;9d}1JHdm^lL- j@SlN^Y9;4?hW{4;&&IT^2bjKl00000NkvXXu0mjf@1^0~ literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_CUT.png b/assets/icons/32/VMENU_ICO_CUT.png new file mode 100644 index 0000000000000000000000000000000000000000..dece38598deb7f5db275d93a1c9dfa57d8811211 GIT binary patch literal 915 zcmV;E18n?>P)Y@u5T{LQA#ei135Q^Z!g@PM5nh=#JBHAjgpoR zj&PGd7;fBR#|!LftPSjG+E%PC*%2a{e4|y0L~k_zwKhGT~RDi4jvIsS#<`~W&PIF)G;|9MnSlJ zy{~(qWKTgZM+}7W zLkE~D6i&rLb$Wpe9RgLZtKVRR4uCqiMXM1zG!F`PzK24;;iNw=+%)Hj(XISkVj}MPIHn6;Q&3>J6j>z~DngIio z1QC4kc;wda@aHt(U0vsgrr)!~m=Pml`S{gZqGdXHC zXizB|UPPq1<=Yw{9obJRs`aj1+hU2m|L|45@jT|u(x6-ZPkW&Ne7^eXw9p>NvokNo z1Tj>QDF$$Ifuhxnj*h0>@NGK~j}MO#I4Gw#>vBo17zDQGiaF)mcEEzqS669FFY|hN p&IBG)O!G5(M9X3IsR=0tb8o=4K{I&`ofaEDaeRCIGb& z63C9cuqI`>ws-eNg4kcJx8{DoyL-I{u*iQ+v*qu)Zdj+z6NX`}=>-Qx|8v=(`|} zP3-M7jYnqiU&xa|KRK7~fF*D+yFd$f63zNNYf+CMa-a z0aXcIxRwA03vPPm@-TP-SW>zzwFSb`>ow!+_YOWUxTyrE!12tfy@ONWSa6iyQ7WK% zy;2((r@*r@iUg;^sSy%)#vm(m1IJ2-aTU=@hLGjFywPO-kIb1edYk#EBZkS(+EQ0o8y N002ovPDHLkV1o8<#5({0 literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_EXPAND_ALL.png b/assets/icons/32/VMENU_ICO_EXPAND_ALL.png new file mode 100644 index 0000000000000000000000000000000000000000..86bd064aade349585d631f89b4e50cf8e7a96b9f GIT binary patch literal 126 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=fdzS5Ftmkcv6U2@~W%=1c|#h97v8{9yRckPCJPE)}Gfi0HXTO~JC=b)KvI~ihk@b$6?F0c3=9u`3Ujx>_)N5Nz`=tD|NLWQPDK}IWMa&Gc<|s4 zy5xd8mrtEw_|GsC#{bXAu;JFF(>qWc#6V-9udgrg{V&V){|t;gOw7!>H!q%iz(8-H os%;VhNt6Q!?CtF_>YYIW0E$;kW1dHwGynhq07*qoM6N<$f`$Z_7ytkO literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_FILTER.png b/assets/icons/32/VMENU_ICO_FILTER.png new file mode 100644 index 0000000000000000000000000000000000000000..f85d4834a6a3941891f269e753d3e157e769ada4 GIT binary patch literal 682 zcmV;b0#*HqP)?A~YE2oq52x? z_;&j42x9AEW9DAs#{z8f_OYm6EA2uMi^Z* z4PU+l;1fZZuU~^@{8rllUVo@%O)&Tsg7CR&&bVThHUg`h5>hmce7Ypa-v)=)7WRFsQ=+{b-Yo7 z8ZDbGl}dQ>bPB0-TDAG!UJ-V?9mQgimNuhd;6bBW-mH-n_1#l|*97s{I;jeR%x$(0 zC=`Ct>*h8Z^kae`R5}76T`=hB%Vf*t@|b=;gM2=ZMxt@MTrOm@Su$VM$@&}3%tj02%W4q16U`Bsb|x5 zHT0e*liw-a)+y|2I2_KY>CK^1bT?X=jaK8$&AR-~&d*vy#x0`gt1Y?-Kx)>QvFdLH z3TLX#No@iA5Ai+#`T%Dv-UmRh186(lcys*rnN7geBo`Vye=d0f9`v6605Sg_3fNsw QK>z>%07*qoM6N<$f;<2{C;$Ke literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_FIND.png b/assets/icons/32/VMENU_ICO_FIND.png new file mode 100644 index 0000000000000000000000000000000000000000..d6fb27ae00d684944fe6eaf5d8b5145b5baa24b3 GIT binary patch literal 315 zcmV-B0mS}^P)w zPiPZS5XQfG*(liv8|ooVZhU|d zRM3J)Pa-H4Z9FK&m_tEOXyc)W)cy&k>62NEO=3*mCL1mIL3We8dHell_RUalenA}YlrfPnEz<^=5a`3wYu0T3bVG=v~vqMG^HSQO`C(S|^fig_>) zu-4M)G%jAcjG38PNQtCd(!P4ngitkS8HV9_C4{PZqacJG^F}}jzGP|PjHmx<(Vn5}w~M_#@$-DE`#}T;I#xD2(yhlz>!9}Zeo7(~?R3-ELJKs9k<=iW1q^MdzZ~ve*SG#tt zoqi|u>hx~YKp?*XVdSf(EtDd M07*qoM6N<$f)`3Za{vGU literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_GROUPING.png b/assets/icons/32/VMENU_ICO_GROUPING.png new file mode 100644 index 0000000000000000000000000000000000000000..3e02b1b3175ccfeba44a428774a7762da5ce46b5 GIT binary patch literal 258 zcmV+d0sa1oP)8MTG?n zQc{u(jEoE#zZt=fkf5sr`1$!6YOAY=b_5f(9YCrhm}ubuQXIiTZHpV5S{Rs_5&rt| z<0qH~IpPoF|L5pAkBM3qYig*0>38qmF}!~L297^}{*0ndUEdsBU{O5;rcUf(c=`UQ{4fsz7?5*NVL%3t4%}hD2bdU! zY6!>@h;wvsTk0VLgA|x~U&c_6;mLwaj6*vFaK$;PX@ZGifC1BpcK{2e2B633@F@q> zbxrYVmG0$Uhp2QEkma6G}=Gh!eU$Rz0D?b5+Y eK6EhPX#fEB#eg>ABzs{10000W zUrWo>5!n&=01GaOeLFXiWN}nn3d4(+uNW8^88m(~5bp>UToTe!k|a5RnVA_(3kdKt zeE9GY?g+9SKrT2iiIstYK?KCqU|?W)zM$+JN?L#cSejsB7+}CcZ37R!t6~rp5n=fF z@gqZXYa7G1E+eqGNz7Z6+yMhj3^W4#{QL~H)m7-ZLxScZ(Ad<%z|4&B*X~{j4ayyV z82>*J4400X8`2QZ8}V1NPBr~?=V7_i`yP}embun^cnL;EgB i2yi^1q4^9$4*&q1iC_~GElsfi0000>-Fkd@6c~ z9)qCXR1#X*$WTk|in>e}O+{BZM0etDyE@w(Zr+;@_Jhkk-#O>|&hLEpobP^weZo@T zbb*k(NJL&~m{E(&9AXI1#Id0lh2~SKfomO&7LA~J0ze8}2%*j7=H;nRA4J6n*qm-V zfIfiC8I=gebAZP)%i2L`+ujk50%(~W4Ug}e!0F~@UD@KV&jg%d;3tS~d>I*fl+V}d zYPtgE`ve#mm{~ujKQ}utkjVBCiX~9KxaK2pI&*@5x8M>|HiAFx%H|`n->pyr4o8#O zTJO2ESN}SfyWQq?n-nd=y};r+?-e+CC!Z}zLbo{bE~F{}309})B>}#_)cupA?^`6H z=o%;%f=1JkD%Ncz0PfhbLuE{Sd^-bhw>)O%Kz2J)U$29|ep@NHNL6Jy=A!YM>%kvV zKbHiX)ANQI#&wgvF}oG%VV8;bxW;%A)KV%5>F^?kd15TwpRL!*LVH_7-iaFvkX+BunR&p8PNSup6!@;=7u3iw*kG0vx z@ZhV|+v_=nlP8Rd2OkVgBlQHAr4kBf*3QNmt>EO)K3WK2s zi0v%Ga3=eP`WnT9OBf!RPYXnWtG8#j{)U1q$l2GPRlfM7>?3o_DY-(g@7c8t8`RDo wKz8;!2>gre^Fb>MtMLRLKMmv1orM4K2j+I-g~}gyKmY&$07*qoM6N<$f>sJrq5uE@ literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_PASTE.png b/assets/icons/32/VMENU_ICO_PASTE.png new file mode 100644 index 0000000000000000000000000000000000000000..bd95cb52d82afd495d73498b98049fbd9ae9cba6 GIT binary patch literal 499 zcmVHsIjL$<0Ao*)r3S;l|MM9b7%Y$_E_{J-3v$x% z8ZcqXEHG`ra{@*DKLf)NMkdD8lD^|N@abp5W;rzgBLjmC)NH(f1!j3rL=*!H3y2E= z7iQc-@gX4)783_&|M~NWVcm*l48(Yh3GNak%R#_Em5(Tkv8hEj3m;&?B@yN<0mifj zOfg7NC^?8j+q&f z%mnzk7(RUbhT#Y%20DR?Ja-0ZNde@Lkf5srKq1gv;fLV}7J50Lx@`jkGZPcTkDtH6 ze2^pl|7Lkka|dXtOEWxq_KxB0yRTT~S!nHm*?lQs2jI#bEDUr2*m4Xkcd$@uxV&LL zN$MY-pE$(p0zy6_6)+(;r3V7AFfuS4`Om;$18v9CKMnk6VoYUVU_k9x(Gf6`ssYv> ppcWuG7yM^n+(IqO|1flbV8JC36%$8QilA0Vu5_@U;#9Gct5C zfvQ9h15`ya&16ID6q{I-(_~Y^X>P(x9^*o5;RDz z2F6DQe1;AXu#=CbB-uws0#kZowfJlTg@Q4JN*FcjB|*6a-oAOMD{;%IHcWm0Q7{Qp z?ho5*?79euqNt8Gn-$UMFGm8b-|6(Mn}h&^aKYDsni@NZ;7E{4qIyFKSglrE?Yg3y zgvlrZ-PdnG6a~cNf7E+UVu{#frq7C^z+Q)>j@Sj1sE8*zJ!0G`+tGZe*Oh&xK>GWC@ zaiJ-hgbTnDgD{v_DC?V;@W+el0k79jl_N0xTx88TL8}+jj4QAd39kR)Oe|q?EMGz)Kus4G>poDpdkt*Q*OuB+S;tjb78Yrqr9>*6+@|* zbt}-GXGJ^L*20G+^`(lkHd$>BF{Z{Cq5y+1$j8X|xN5k3h>U+;el7@5V+`>?qN=RV zJQJHvDoPc1J2%`)mHT_1q$$gxp#j-21t$FdI1zR7Yu;+FZ{0?8^4}4VEA!%7H@?WJ zoQ%k~!|k>iz86U9BEy!;FR!#AsU)*M3&EFS!7c%449f!{!*;{49O&SSO#07E>}ND1 zIg=UTXzCJo0pjPwe#uqu$SMd1?S{P1d8=`^bHjy(g0kD~wk;~APg?Rcv8hZY$S4B& zpjF(Tj|AlsSPNk}sQWyy8VMm|-YXOdn%s?AQVl6jP_dG(gcX!{zM%wiNW8OeDR2G@ XnS4pf0|xw=00000NkvXXu0mjfOc9WO literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_SAVE.png b/assets/icons/32/VMENU_ICO_SAVE.png new file mode 100644 index 0000000000000000000000000000000000000000..0a0a3e57928369a198c1dc83b669c1a3feaeff5d GIT binary patch literal 311 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnE1|*BCs=ffJf1WOmAr*6y6C_?X2p$W#Y0|ycuy}ADz8^|Q4{Fq<$`qWKn1v}wM(HVJ`H^kW3q*ufy9B5Ku-}Z;S+me}? z+4%6`&%!ISHttEZV`e@a&(>$J{;;f(A&BDugK?;?T8bIBqHel=-0~A%$+ftCta%#xQIu)$u_VX81|H~Zx9IDkmtzeD#oIE zM&gm8gHA_Rr}IPo=uI6OwIEYwxXB(c_#yLQdfTiTcutV+&6kvzVeOS<<|@`eJOSZ1=cBfeaYWp3G$5608eOyWI(&L2uJ3WCVZF1W9B zXGtXoVXl0Zu>&BQPezvi%wkonlqghPHlu*ZRH|RzoakUN{Y2<2Ryo7Z@=13F77+Un znYrO_l5CH(qOKxlQ5}b$#RR;Yw&Z0FHLypv*r*eo-P`Y^#mLWM3AbvorUV#7d?i8{ zmKL)C=@N}Z)bRpE;qe2%EpJ+YQ3Rtvg2uCnD<5$Lkf}f;!pdUDB0yp=zCP+fydXv! kGZOg)_h~utA2>R80bFJG-%0y13jhEB07*qoM6N<$g5XOOnE(I) literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ZOOM_BEST_FIT.png b/assets/icons/32/VMENU_ICO_ZOOM_BEST_FIT.png new file mode 100644 index 0000000000000000000000000000000000000000..95a6992b67cddeadd9154047789d3408c6cd1de1 GIT binary patch literal 1055 zcmV+)1mOFLP);_{@U%H4ORbeeEQ>oK*9jlrIjY*p1{`rk_(_7N4&2BZ(mz{^?{_g#r zb3VWG`~A+n!2kA=jhu)A!CFfc9YTa$)F00Cnfz_xl^rvSPV){l~rgh(w}= zAfqJ7J8qAS+<#_(_FVGI05$R0>-D04_fG75dpnw&bJe$PVqy|!&i#Os-=9G$m9inG zNRrn%fuO=0fxbS)6HQ#UXTGL$HNO7xGq^oI96xmt7k<5tyZ0Vg+SV0~*tWR~dv|R@ zHj}`?4-VtT&EID$k!kR)3x|p?2Nm9ETl2;sfFpMD6UV;ArIB$Q8aRPuDg((|jS64A zrPUHK7^yf^uLoZZ?!kuMmDscIy*vnfa_7di0mlHrV6b-DsQ4Rz!e#$y=oD_=j$r>s z$3RsQ{O|k)GL}K48z9nth-p8v4|K$D{RYY=@y+M^(Anv{%Q9oDNt1 zAZ5t?oSd(D&AIG6bKzD|x4sRMFAG=AT}X{rAP0U%MaOqg*AJn7?N&>}TJ~Yz8B=Cr z!Vv)RIiE4!aK}$yw8~!H)(g2Vx9){zM7uzeYH3)@KI}VR%>M)c&}|4Ip^Ij`(^@(LMb2;%@FC_hGb){eM0OQ zc1))L3!3>T_^*4$qoR{@WUhkoq}}1{bFL?Hoz9GP0z#f6ri$d8F>Bc;KZYICDZnWI zaC_wrw{1%o^i&+$lZOz72WG5ej#zqa804L@u35uc_F><=7Cq`1KtPeW2 z5>CcRX8{ZirlA8wm&#Uwg(|_xW8>FgYT2``r0*^}Kp_Or+)f?}9o1h5Kt2SQ-A>LA Z{sDW|R!62H-FpB4002ovPDHLkV1kyW12g~t literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ZOOM_IN.png b/assets/icons/32/VMENU_ICO_ZOOM_IN.png new file mode 100644 index 0000000000000000000000000000000000000000..7e0e9aebe1d2b258c957003240c931b861d3b761 GIT binary patch literal 791 zcmV+y1L*vTP)(F|-#cF^5F^}ct6(>l7{K}2l}c5&Szg}VPO&DZ{A_-)i~1Ww18M5ztZgmf}8{4SWK;2S)UXu z@3?pY&z?TPsgoyM9sT_E8~5%%z|7|_0wS?hcceQNci#?j4xH<_G6LYC2>$ZLb7)$1 zVZQxR=Z^1ZKTQ?d>GURU-M%A1;PJPa=^-}&pWKN=A|U{SBJI3#Ie0Pgw|N^)3=P^o zy#b^Rr5}KG+Ii25rF}QC4cppMZJ*u%i0`>AK5+Y$Y%BZRO^Tx*6<1B1cITcuwcD9s zTlQgJ(H+;=H3I;wsN$Xo9;$Lib^^v#VuAqZvuA>ow=qj%xc8mxX!-*$x{l<}7=tG2D1HJ$afXS?820)-hj z2y%B?+D|D$J&i`r|6ZvMHrAf$^aMdDv%;}Q=SzX0as!kKL6ra~1;SS;08THjkb`hA z4q5;(vd9@aK=h$v8Q3cm9DH?d8oBKD>o(H+Dh}X;;FXKu@%XTQC;&19r(Fc+iNCev VvKiWd2VVdH002ovPDHLkV1kz=b(8=A literal 0 HcmV?d00001 diff --git a/assets/icons/32/VMENU_ICO_ZOOM_OUT.png b/assets/icons/32/VMENU_ICO_ZOOM_OUT.png new file mode 100644 index 0000000000000000000000000000000000000000..5a3f246666a50d761bc1aafa4d7cfdaa90b78adf GIT binary patch literal 799 zcmV+)1K|9LP)f;-M7^7V5=|;6YFiUIZ!h;-MbAdGTUE zp<+FF=}7`Yk$Ol_(L&LtRNF&a3Z`k=>}KUlcIvw5cDG6D#qY4p%+7n?H}B278KVFA z$6z;;qVaghrz^uue1QxjLClfL55rg>=8Qqc*M?&#>-_eHvK>kfVR_(_P!Y_{z0%cY&uA=wA~E6DjT@+XfU z?MMz_4(7tfTw9{*%R>a>@px!M-?vCaD#HG1;+ZRQdn7InTo&mlHp!*-ti$P$tet|c z41*kPnFrf6T3Zjw#O6s%=_tzEqs_q z^tWTY(>? zfI-HjXrsLD7FJuU&m9E>WG#i_fi`M8ii%gj2DT=OrcZYQvek+;hBhi0YI~uu;hG$C zt2Wh3sib!0*Fyba*8+gemf$EZ60~u#T)BG9RU|M6bH!!EY8x4cds_9f{5qPvcXCg! zWA+`S;JKSbzC*M+J5Acg`jRZ^=X2?i&#na2@*u&=gNf@T1==e8vbN#j3 z0O7?7K>{+6ZVS*$RMs^j<~I$Cz~3SP^3~aQR4#2j?`CbN;R5U;uyR43PLF7NBETvF dVHf21@e^J(vv_cRt8@SW002ovPDHLkV1lVVgxCN8 literal 0 HcmV?d00001 diff --git a/assets/icons/32/WARNDG.png b/assets/icons/32/WARNDG.png new file mode 100644 index 0000000000000000000000000000000000000000..ded1226caab5829999bef05a9a6deee132801ff0 GIT binary patch literal 2505 zcmV;)2{!hLP) z-D_OO8OEPEyDLk!WUoH3cg5-3%SUJFC0>+hzt(aIySLE z0kw5o7fL`;oZh&9LMXimv=@cuB59y0q;8Yq)M-;fY`3Y4wNi_A&y@FQrD$j7?C#k; z=jvDb%}6C$OFJ?|jXb}GfDx#GynZP~UsJPU``Ab~CdYeJ zFL`F^rQ`_&h(HB|n}vA>lswXQwC~2ip-!ZeZRqQ5mtSO>ff^-7kR%eAI3u7|QZPa_}%CLjjm*JxhY+LlhWp*y{I^Y8oiHsjF2PU*Fr<62N8l|TgK z^|{VzaGVm`A3xeB^`%h~iIo1g7?4Ti64L0>kw6558*EcR+~8n;2RhnYq`oc9F&r68 zN$mzVuLVI;(LNxrWs_$_iG=2fqw1$Bi_wuZnwlb|jf|yNmvdQYj@ALWIp5#RP?#6n zhX#{qYu#o0x~5nJ6QhcNG0eSjp}Pwjqjf-5bGaFk)VH?Loj-acUGcSp0|~V5k%AU4 z7r<1b{R;Xnvr1q7sn^!^G$#@&(RkX$>BlqHRD{qfJ>+B57%fAv0WgbZl_= zAWi(cWl4qB;59|dfGlPcY0mhZ*iLtRG+O;zW{hEK;>*Nw6OJ=hqNyQYbB87*5Y+SyMQdsr7|jsgc3fw<7?sg#yMQp3mn4#| zjy>q#uMiHaq_bl;4)nDvN1|?$ilLiC!oegV@YqqsJm3(TOC;fuV?sAcMXP{t#-u8e z{XKC@TCW#MBnKZ&NbLsns#4J=AWL&y&(dJn+D3QuahGpRq;FpStXv5KBLQ59t4%_{Q;F`2I{A1Qp)m$WRI&-M)|2)wQk7@#0#2!^Ovjj}W>u4VYKN z_Tk5pXx-DKe9bR@`(M2EjvNev+UOefu@fH0N4iy)W{Yd~J3AmN(ddgLjf(=}SVsAw zS={}?toVD&^`Xg~63wkpB1&ua*vSDQi3E&Y65B_QbX#|_S5SgEIi?aGakkNtN<#w@ z0Tx7wq@_i@;^#K&D~`JrD~nt%;NA%VdE-Lo5a(R74or>rTGF{6JU*q6R2ZHr+8lOP zKnezvB$D=cizS)+1tpw4-TSJuIc(>ESXCszX|a8BtabshR&3HT`WI5Ryp9 zm?^eXO>R=GUiT3@;gR05-;#>20ZA@*en+e#Ap!BY3-WrskW3@haslK;xx6g{vN)e; zWr`{i`u;9gW91i=h^h)GIB@=FFLm^8yMVA|Gb>6Y^u0Yft`-m*!N^eBN=&yxiEEx4 z(nCm~140rBW00yyGQ-u?SosAdq{@d2)4wVeUjo87e+6JAvv%{YC`KIASosB+f5_G# z)pC&?VmkzcsstJEyx2aLdBjrzu~y2|a-AwBw80LDWxNz55|X~D_EuN=dgHQ*)Mm{; zPys0#E}v1EH2o3~YsJPydaStiAJ7q^FkEh!G<7F!XCh^M!OL1M!()kLx|~Tdv6bM9L7gY6El(h-IYYe707TrtU=SOr*eRHzgI<0usra z3!+5g)TF69N)su4b20Zui7NrQak29l2Ya?&lcw(236Bgou{f8IB%)ey<dGSd}%T;1=wxEIy5nE9`@h^LY8j zLwtI-)YrB@6~PZ?+Aw<9AN%AVKKRV~~O}D?MUcT{AY53giQz-VSY(=b_GA7c~wVaFP zI3TpwlxRb%WYTn#cW* z#1kVi>(RCn)Q9@|iLHs$!MRvQJ?A|&!lW57VC5MqVR5rhq}Znc%D=KM*ulA2Ms=GR z%e#0s%A`q9()aVLapg#%HoE3lVpy$-lxhvCkyN79o%h5J=w#9)=mUTAN9_%jPRf}` z@BHlx6iO4JjdQWeRz0#>BoeB5{rXoA*ZH=$H^2M+r})!{cO6SAhST$&bTMh_j?zS0 z#kp9vBZT&jG7AMdE3oA0fP51+rTQTPAO7W@yof~@##dhW@x6B(%^|Auo`}2mm+{uG zKeBsSNcA?2uT?!ltRt~Ge@`sy32_mIZ@zH-pTDeX4pE)=6yh#+=VBSvp7#{uE_UZ) z8P%Nk6ygo4bFrdg-jU<%RgeDt5D~_(w)&9L`hQ5*LPA19LPA19LPA19;1B-?b+(R^ T{=}@600000NkvXXu0mjfVaLN` literal 0 HcmV?d00001 diff --git a/assets/icons/32/WBS16.png b/assets/icons/32/WBS16.png new file mode 100644 index 0000000000000000000000000000000000000000..66d55a9556c9039237d8399c39553fae93f8b6a5 GIT binary patch literal 314 zcmV-A0mc4_P)2i%i3B19{3N@sStObI zy*IOu-I=xO-El)i_8dSH-@&mh(Lb#x2bm_)L>{A^%#s2>$cLkW66O@6?3T3MVya1u>0yuBs?drpGcL;p%V_mH?jbxmY@(S?WeI~hzb8_D5 zz`x)d$9(6U1OrGrC#w$8<(LG+U{e|Jw1FrT#x~%@Pa?UMg@a-<0I)H_4uF$CTq~8vpARlaAVm`sl`IDV8<1I~YGQ#|p48AqmaQMQOk()+ z??1z)b59w_@dy(G6#xqpBl&t6u=t3cfQhcQjXD4eU}6~Q4qzcx;pZQJ7|uR;$MEjU zFTCoexrqHIrQ~EH)&ay=PEN_mLab_-<>Z!_xJphYh5-P`B_|WZ00X9hb^yyj)d3hG z@aG?~xrh28a0HYkK&f&d028P%`2YX^i2<>lfq{Vq+J>_vq>zLXZfNBKrcnnlj5=VX zJAj2$4b-kPm`K$?jXDF_3>Fgf(W1^cKy(Pupw2kJ$jq1s0B literal 0 HcmV?d00001 diff --git a/assets/icons/32/WBSLKR16.png b/assets/icons/32/WBSLKR16.png new file mode 100644 index 0000000000000000000000000000000000000000..a20a9521cd0308d5d1317dce27393b3c47f4f0e0 GIT binary patch literal 412 zcmV;N0b~A&P)*FfuVDGEwRPvMdJyMg|#>UY40|k{W;h{+Z9n$Y?=| z{;WN(7-0s1sKvAUNwPmSwGgbAi5$zR30Pp3CpC1Dq%mtx0#@o^;KP)-7|uR;$MEjUFYF5b zGduy6XyB3!AJDRa(8%ikGdv*}0(dP4mBdU8iC{;N3ZRt{3n6td%h5~9qy~on#MlEW zSN{C_&#>v-Q`9sc3S{gp;0Ac_W!$@}k3$Y4m zRZ=n$tB{hC5}#fcBJ@+Uq&$EwKrjTTSW+HfWM)i67X<*7sD0Iey;(K@0000<#i=H185tP9 ze7^QEYRk1}-EY56y*|G`{@&)kd)09~t7h`mg=WHk;JrbY(^ z0j$)GZc~Bk)ma9P4OU^V&whPw_{D06u_Kb=ri=3@JnRdQ|9$tnhP^k?tjRys_ntDp z^Zv-{ZTB`BL6t5z^8SwD+|um5TW2U3wC;|$dT!U&ds05w?F2g{fvbAss<(ePf>Z$m c1`KW$=Y{+FVdQ&MBb@0MN~QF8}}l literal 0 HcmV?d00001 diff --git a/assets/icons/32/WBSROT16.png b/assets/icons/32/WBSROT16.png new file mode 100644 index 0000000000000000000000000000000000000000..7715c1c47c1e8d181687b5835ced3a7a72694891 GIT binary patch literal 344 zcmV-e0jK_nP)c7m1DF^F7%;}96#S>D4Fu8<69cUQfi%PdV=SKCPZRrNQw#B?Atr_a1}ref z*^Ac)!~skUgCztA0TTl)Murg`0x%$NU$61^KQky>SujurjxaO+O(i)5sAM?^*nrF; zIRs#qSJh;ZW$U~xcNqTv`^)h1(q6DxObi167@3&iY!*rl1Nmr3=K`h??*JB1eGRIu zCQO+%AP!&xH5R~*7$Cp`ZK=qP*fhX2;vK*;P$eM6A@Kj-Uj}OEWg$cV5l~eMt<5L} q2S^S9P$PnYf#C!-EN5o?n+O2H0#b&%SgvLO00004%P)@fk>}IZON7YC6Umr08L!n&rBtiy8m_kAZSqZ(TW4LpKMg>6#QU{AcL*_H<)-|NaBR(c>ro zFmfGNj>Mn=XzoPT)!kW>&+VtIL43B#pJml-x~ z-oo(r?_UOn{|r+vUOf1L7&DltVY#}R8iSjw3xkM=2uNy;qzHEfx#kjWxt@v5|D~%o z{6BNy+W)-=kNUrMIsxatHZauVFfj~^MDTiY0(J$t@J zQkXmP;K74LWjSnsX&@~p=m1(<4gxH+vYgnK5fd#eACy_`8!@>+Z2)}E0%NFa8#}NM zRItOq@->?m)2f6cs*$^Y|9+Oe2Tm-fTk(nusOp*~(93cFqVP&%oCPx<00000NkvXX Hu0mjfjeWLQ literal 0 HcmV?d00001 diff --git a/assets/icons/32/ZOOMIN16.png b/assets/icons/32/ZOOMIN16.png new file mode 100644 index 0000000000000000000000000000000000000000..d98ec32230df02959e242a8da52f3356bfb6d282 GIT binary patch literal 783 zcmV+q1MvKbP)9a;R~2)pL&>`2**tvu|d$3=p@1 zPXg4+eNEGl?oT0g;T+oAt?Wz9&gL=p{3S-8jzQOT2{A|hK(7}Fat_4$`a(?$g-JQ{ z&J)LR|K433Jh0!@(f1!eapUGKOnv+$Au=n?J9~2z?#n^Wfuo(Lh5_7`!Jj;O08QJm z_CDTqdfoTaAKtFDb$uC^uU=OmaOca^yFoVqpV~0Zs(#f@*%WJh_8@9Dow0(L5$XfUL2)FrS z;o8pS)vNeh%f`Bt^yt1qKG|blXxn}ntwthP?COHCtk3y{IJ5Bh;b%_(b-9kiVXXFF z!m1X=ugrUt^`%WA2zCA;;hE!N3W)5r`lXU91fh<LY>uo<=U}oAgJB|)k07s0IGrTH41>!%QNI49E^iX z3BxcSfL=E&1Dj=n1KU8)7Gu%=h66Yu7(fQc(2%h$04fBhT?XeDe*iX%wgxkIg`WTb N002ovPDHLkV1gV5b147- literal 0 HcmV?d00001 diff --git a/assets/icons/32/ZOOMOT16.png b/assets/icons/32/ZOOMOT16.png new file mode 100644 index 0000000000000000000000000000000000000000..e3b97eee61962826bf6f2f7dccda05b2894944c8 GIT binary patch literal 790 zcmV+x1L^#UP)JnnZjoEb*!6mc#SW0BSi&WprYjuW4)N%d?YpI_@KKs1{4xVNw0BH}lQn8(}| zuMn}R>JQ&!p)gnJ8Xy)=jPOQ%hKR}f=fPlr_U{{MwLgDZq}A1u5hTYX=lDYY^i z-;Qy+O&GzSIOp9+=ObbVVBm5X`bAOUx|PmH%cs>nkVDF_cBpVzORT9~!B$tI;nP|M zIPqE0MtSX2dRx8Ewg6tKo<;FM8?_xp#jaojTTKv1i`4s!iKX0!Fml~7lQQzzz&3?UjRri zW{4mNhM+>cUT^(~*sH!};BT2gU=8T$S~QgIJAe@a03tX|OwD;Im8*TQ-Szt2~cG19x9>j;JhaNH#QjDU&FvKK-dgw*)p(ra1f_#W1 zsldpHAbgS_=tX3Lkp$%*Rt703>2+ZVl?sd~%`oY-w?m6f8{mysJ`OXLY z$3F%$GRPkcy7J<-1_pKroC{!Vht$D&7>tED_(0Se>zy1KnaimFzrV_!zj5&@z}o<3 z*QeqUfORhaaCS^izKPtsr(6k)ji4;4SyUR z+WEJ67L6?(bLF0A0~N>0tD_@e-C@z#VI{+53l)dNY4i+)C}isN`umid0A)uN2XPvU z00$pH4nV2dC@0e0TYu>LF@(RrpVY9l$Y zliEbka`7@mamlcA8Y|C{oI~_(T?h-6K2x_~+3oD0CzaZi(lMoZnlwCTBnk^_ifRE6&m09$S}!L>&pWbL#vB XEz!k02ZWiy00000NkvXXu0mjfJ`|Lj literal 0 HcmV?d00001 diff --git a/assets/icons/openxer.ico b/assets/icons/openxer.ico new file mode 100644 index 0000000000000000000000000000000000000000..629ca0b4c860510994be5c569f6e8df7f0b66fb8 GIT binary patch literal 12667 zcma*Mby!@>vo^X0cL;7lgS$He1PKz{-92b=?4lMKLly+<#U#B4a6BglGQ@Cw^zJQ zR-Ekh6D2>RqupdT%<s7el1K7*&81_%XF9^2ycD&y{-OqyXA_&8QF=o z%a^Kb!i%A@YMGW}#`aQ3`&|jj$szp4l<@2q5h4~i0NQy}th83@K+aamJ>x;u2@SWLNZKk+v<%v+Jj2;4Hs398u zM*X0E%L8sFKK^uX-6WS$Xk!z7)nt8#G`cBEvwV>mwz^VQNxbv>BaRn!t7QQ%n;3LO zD<{zp?b#v@W>c*`qu@`0N~-k61O!!ADA;?=D5gz1Q*a2a9s<4S2QK2 znF%-1dTQV*+MBQ)N3>JV|4fBtgPX+s3+S5ypae8J1cDX(#Rh+qsF$mPi ztU*@rZwx+bMjn=zY5 zJ`!6fG}cBI*#=PR229-=>Ah30Xa%Gtmf#TDl_IU}-rh zg)L8bd_!Y+HC;I>;r5p&c#U?**!a(xL3?^v=lW-aS@G(@7o2ca;Dmva%JF*T@j+w% zcILC;Tc&Vr-qabfBoDxC{7K+U0#w=n~k$yrJobu zg%`m+az(glCFU!|8UDgnMnX_%CJN*%MWxP)Em0-Z*mCb?E7GK2>+6&K=66G)?{|ob zKzA)E3ge3AY%p$gcdeIvABAvky=oYN&?lH5uO@=EUPLc1*B&16tF-QID2CYQPv`Y} z-v0h5sd#vG_xX|is~Y(!O9t#tRjq|s6dWdU)Dg+`UeFv>l!880(RgqQh01)P7Z6=B zd9T1Hm1*)*ns^!GyV~-7vEv019lTpI2#y;7Z3~Bx);vep zTv4H*qmr>Tw}`iGn!MM1xu?B+1MT_|^1R57p_NhXqfyH|Fz@{*{|%MilQSy_x)|T8 z%#fR_jH=U2EU!MDF^nKU!|9wa>dwA)ZNMB9_5l4&J%d#4Cv`%0M%X*aWm<2}ufZ)+ z8j4)>Nh2+$=@=6RUN}5N5-{-89z3_C7o}IF71$K2STU>|Az_Ya665&v)U0wjE2{Hs zO`e^BZscZSLTdO3##_Oo6hnl$_yq}CoCKQj#-dr{u~f9xXS}Q`JC_?VO1ibFYu_>m znD7~zfG)eYVxn4_20P+epS=&F$hcbYplk-8BH zl{~`d%}Jok$#IT*4lJ$;C9T8>AiwEc9U2z98L~xx8p-(M4Aa`}c-%#L|FXN9+6C%b zL>$Esev1BIc!BJ-pX_g5aQ5`P1OQlpe|Vu^L#GT!4gY!8%zQG}XV_W3EZwut8^IHU zZkmFQVhFEb^gSLlIR+&P`2ib+x58z?B^A3O9Rhhc_5nHe^h{OhyN^Pa%E~l1$74qs zT8D9d<14#IpB{9Zk)G@38!Tq4AUdml8GeXziw~H$-L5ayE8p4(7v(n5G|60C*N0;7 z$ruw>$v_B%q^p>wl_X2lA}mNr)fDl0;I_9|@5nHf?=eNa%UN<3dDy;!PmCj(v&@KG zYvQ#@)p5}&E1;=CZvwD4dO?s(1fWLe=8#XN{1gXj3U;nw zFft9C@0SSB07eK+Qc8cP(mCF{q&PhxrB7|kDy+?Fh#jGXb6B!J!s4f=aFr4GZUA&1 zx6Xp%_z??~Fr4U5X14p-_18G!E)2n{{dK%gv0QNGxjoL=eaP2gs%TMcAaW_5lNx~2 zF7X3giDGB#C*;7oaNgKAsbay~%FhCp$+Ct&tP`Xg1ZjElmudgr5=kb_0)+JkUosn#AJ&S{gRK89~DQJRnI;yWqFw`sGqpFysZ(>@Qsm9qI=DbShtD;@aYN>VB#8?Yx5catwUH8)#B;fjDg84LAXFj* zb$k1SBQ{z2jk_wd?^!wEqSQ{j3J}K|%pRZgU@L$RXD^pC4N*x+4lwvb0DB{CwUr1A z?$1ZILxfq;T_J{D_N<2K;E@H~nY)s3Yq;uf$AZ%~n7!#Rv^e>4ykbx9{pD&fUz|`( z*$VdHZ#R-!POp00l;~htXRpmth$H=BgQeuP(~O)^rB9&(BxinPLA)bb8S{0~3{e=k zOgu%q8A}6^%XTKW1>rP9K(oulUh`L8-wm`i;Obq0t#;i222rXu?d9!FgEj)SUQD{tW1gmp+;3dqnI~T{qtp5hc{g zj%T(76{g$VjoGbPME}(kMwd>6AdZ}&5A9DsA?_ZJgvPy3au)m`SS!c14dtV|Ph62B zA=6B7MzuNl{1}Ia9X_$~}>dLZ4iYd&1KYxi$~5847{kEy;Sgax+LLh zDh8YwRE;*T^Mylln^Ud%jUXjYl9Z!nOl{*|Gy{>`}>POlC z0ru}=CkpI}PqA?Xrlp?F37PX0JVpCSVB^=V(gLw zBk6asvg+z(pCUgR=M3oz|7f}K#Vb{KCh+sNg1P(VFY|pYZZUmq3nBQsF8nDp@tZ#^ z(Ta;eG%u7`{+v)Q9(@k1*lK_|gZFx;mqTw1(c!yP7L@0po7xRhKc8P9%?w#2o`Sbq z*v{4gjBM27IMRu00ea{rr|Y#MG}5C$di(AJ?_C%c{@pTbAnjmHcC3-rgv4UX7Z_e7 zwuo;u0~V0)$R!!dUNDT`zh7pwf#X(5Ne22JuoPv!Tikj3JFEyE(gu9KoPnLUMag=x z`vd#Vkck}6eg39HFIy>x!P11)`;l=XMqleqgqd1416Ko;Sn|bLH4SMn4-47Vz#HGw zG5dr`*q`Pp2z3Km7e`3Pi3wu)yej?IwL(GrVz{EiuFhoM&S+SH%TPo)BX+>XtoBCh}gueJBY4KCQv z4#r}lGmI9+h>Jz{n>CF{lVouTZLweqYHnq`xR^VP+K~2x=HOU}F$h1iUj^&~GFl^F z!3eAZrKQOINS*dgJuG2jTH;s^gO`W-5kP-Wn(5D&&R^dD(5fZP1CKif4N88=7~C4Z za+Xaf(RJMxK(Aty*z?;X46Npwua{Z2Li}or!)Qw%{`01UPL<_>Hh28JButa|j1C_N zd8j=kn#s20#8_9d36s3sPMXpXE8s^A4EDL=R|&_8dP}~Q46z*0m|K>5Z`%iOaxE*L z-Ve9VJF*pzCo+A$drHCPL*XQ)1X)qnTP`xA1 zI3;JP>Kzz&6e1007AKEm^>BJ?UJG-|y{B4q{Mih)V)wi(MjGZ2HCa`0zw^Dy{urE{ zPjm*)2KFN+?guPwS8ol_S{NZxu<_Su8J9B&RVlZ8vl-p17-gwI#Rg2XYTf#K1XP|d zUP90f*b_)romwRNzG43xk#UC~t(^@1F*cXob>%ZoMFfr}Cn9m%&$ub&XkH9U^>41n zDE>D271BK~<`1i^7-~keUaMJOJp)f;7AXZC5189^#wbf|sUvFMtjRPO7yo*kEsGpY z!N}F^gHksnt1#T%sdTqFR|!{j^@QBhp|qj4!3SwXeZ#PzwQI4=dXb{GGZUgo{mQx5 z3OnEOCyi)Zg=5`fDR!}z07|#AlP5`jsE!1;-$k78g~P#a@R%c22^kT?sI?O+&+F$r z)^V~!UxZJLNgDUM#Y-zr97^Ev34zgRKI8yZKk&fG1+OD0W_QXL>!8y!xKJHA>q@b&e^eZ{-BHV88UD_7# zGY5)wm8n%vNyZWjg(4U2uDhkf1VstO7;kXp{N$|7(Q^=#!!;6(uZe}<-s4kj_@MA(JK=kXikLbz8eWjxx$X%Ewsq@VgzdYTfz*x|G z{T=eWbdq1nNO6vCgx000r|pH28!=bue@XKbmh&Fz?%TP;2lDS5hr92H$@g?^f|gicwFHXk2R)Br=d z51JlbluY%vBdt$C0zLT*?o~|S47H#LC2hf{%rEp}6fz}W$kig>C~tDZ9?h?;K5zt0 ze0O_FsyWv4axiMJs%K=U6Pap z=f@v4bTa{=YxyAFZas_lv^1Wy4tg{Q?sKAf^^WIlXFMbxyV`of%7o+bIP;#ny)968 zZ%Q2e<%D;$VQo?7ztq=&KR}!2WA_X+wL0^n%}BCzUGJ6jN9W_JJzs>8sxCb6Wi0u} z(2HnBsS(r9Ytp%O=ydR9E2Eiab94sf@od4?Ir@xHP2Dhe`QB=bzxsU`Vqa>sxWw=X z$&bJcpf>q z@QtMM0K2?S(rTiq;*!FloGLr7rH0jTcq=+)WYrTgwr()V12rx=YSMeH;^kY9IwENH z$yCiHQ&p2n$-9GYa_C^3zmB;I>yVnCgs8cYgAneULx6J|%&^JU_JbnBAJx0dv(``w zHmJkC)~~VbPT>=4%-yN@O*#-kr%L66PrMdooCSsr1r1a88M4(n7(Lghe6%heMnOEUQWOElEN;AT6D3o31h z7{&){TzKr8uV}^k0WMg~&TXZ|d z-v0CHk3gatbt<`@VQcW)HsLUDauLlqjL|1fu7jVb>9h58R2a8E#`Bj6C-xvN*pU3SULNNojGMOXgs3H@X-m(8W!=8H0oe-W?G1bZf#i5>?=wiFx#>@mt zc8(?ueO|ip6)TF%xnF)gqcqPbn_eF<8T8q}F34ZDvzcRNbu+-k4?^-?w=xQ4b!jv^ zPU^XS_jgwwU(5Ag#dWk7IuNkhy!7o{_FF{1>X-8mGvc(ByWnfvLkaF{nLE!(8 zKi00chDk*1aeFRgc zi{fxKW4?eZY$RuQczx9{G;ytaPVmaXPMtWPFE@?mZ{M}{de_otDb-<(5@JYJld zgNg)U__T2DCwHU;lgRIm+W!n3C7iPPkC-R)lZ6$G_y74r$x^|HM}T;UFBh90JE>}Y z`(w^G(g$5Iv{J<^SZV3}XzFvdE9&_#GLd@X)pfTzxunE0bm4SSKW4q|PZrl7_Ha3a zi<4R4e)dPhoGtRFYf_JzGv`y1`s%lQY?N!c+?_QF<#sU_88}SAETBpNIQ$M3R*e{M zixk=#q=M`MJ655vSWt})VghiK)=Nxz%IdCnsb!8QNKji*VHGESNFZ^)I}44CQ1_pp zQ6!^X2g~#NkCEtHLIvrQEf2y59O7s0%#XxG`@%L@5yPufGrNu6r63UwdyW8x#sb+Om+teY!TyS>M zCl{zKG$}O{jfuQ0L8Hx>JhR0h{F*R!1R~;Ku5fu@r@>YtSOC$ScpiVY{7+{GF)s@w zV5^?-ebWJGq4JEV=0O^xCYU_xWmf3X${X2kCWUC>mzFq}5~00*e=qq+~M!WIq2O6J~ks zo>s(J0%L$r-HG)_E~UwuPhk5G%UxlQv$;k6Ks7U5OAhvntrCS6xsX4v)676>h=w&Y zE$KV;fFg?+bdMvGlpGoYQ9Am0$-_?m`6Lj;bGNj~s1F8gu$QPrnf ztO}vUR6v+EppIZZ>8ZWhk;_F&PQKa{d`;I@Lex|_a2u8rjrG^ z@ep23aJUxFtdeUaI=aoQ&^AcGb!eXj^~r?jx6IH@!Ub~uKp$KFoMV2G18$*gXPoA% zt$b_5#O+H0K~w(EP+`vB-J!zVbFUTepVx|CAS%Y&o$%t6O<4E^eCuZwtZd5h`swxm z>*EsWwHE~ZeU{R7DtrA%i&gobv()k@+qb`S;7)h5zxsSKp?QaqxD%p?@F!SIx=nOc zd5@{kx?HAFkvygBAwa!io(0D^N}Zu;zW$F)CC(@8E9A1u$lvOP)!IGuqD1Nv4j$$8 z6pL^Pu*qK<4;G!hob?FiL4_Seu?fmgySu4 zZ1E#OhL`80Hdhp@P=$qf@i4?>89FdwH*a-(6n~jC1Y=)k0type&$;z5Vg=A^CRb<3 z9o=m>NCqK2yZJxUZn)oQ5j5tXa-#U|*t~q@A;OyWq%9VM>+ZjL0F$P#F`LXV$r!Oh zj>!*F+0s=;j%H=Rmy(;E1_g#lSisf2`>IXAO$+GsQ;CDw%HsQEZW9L)=+!RO2e1_< zwKlE47)*C75j6zGA3_^~>S2$pG#lMRj_M6LZ7@Oa-3Bx@x?Vg@#?V1%dkIO`3?-c| z-yBz+e^OB+wGAE)xDf*Y z3jA35qgIp`W${@i8MAtEyO1mT+P~j#;1FIF$;_0sgsbyT(!`dh0v})>x_J-*10^RX z&w41THXzIKmM)ndtnH6ptUga7t0E6JiS_K}yJq~~S~P-!g%JI@uFjh1Pf0?4%-Z=1 zGhT=AmCbs)&(hE{mKff{`9Jscv+f1<2p2sq#&T1~<{yFTYJ@v~!>rUyWIe)JcOr6u zM>&L2TFh8kVK@{I+h@Re2N=jdOocJ^Yr!zIoa1aIK1<<>CP|V zvXgBSh_?o+Dqnu7W5Fo&A799>%lhRFshJzHq6E6L3`9@g5A?=BP8f6nM*RaX@>$C+ z&bvuDX!eM(As2mc;QExi9#jxr(UZ+|t2llGmT}%zk(_(Zs{UgD`qPRPE_h1oS*(qE z1I3r2Dp5Nr^Su%jS@wDuevJ2x&w7w8`VZ;b%g6*HEp9)#^LQx^TupI z-9)))J#wMk4P+W|Qf8m0mmd^f{}#D!S;oHnH+m;$D8s=fB?NAzyll|B{Lj8-LuxoJ zfk$*Y0bz_gNL#kC>u7tRPmZ3+|JSKqv(P4sZevh5yG1ouNN1h7NjMHLvPOLf=QvBM zWIvRdo{CZT+qTpMn3MEPv+yfish`vRJU)O5?7uA9J$^-#!BDC&o>@xmU-*a%lunWI zU9i~RKM+6B9MF~X$+j$Nx7ABV9K-UTwxow&O(x|&y_^{gP;|XazOZKOJw;T=+#w&Q zgi~7Mb*~hg010l-XA58@`J*O0y*5XvZrZ9iZ&22Y_+8yhZjdHul74w}FA+{gl|nkl1H{nboypw**+^K&b)o@W@Q;v$)m<_&C1Kkpi^}E3 zS-5wFPBLa8Q-y?jtuT4Fmui|`!~L4yJa&EOm{<6(abq9PP#+=o`baMdzg35U zc(IowJbRQV0~>CqRzBZz``(?=-c4Ha(=jXsHU#=ICs3Wyg`{oUrus}M1*yI`o3y`v z)0MUDW1oTHoC0ZYfd<-6hjenGOb$uy_w`zbhdGGhnT1GfIk67kfa=>;8H?wvW*;`l zc$pyIfKydDA^jU*+F-d^=-L^Bj+}3nSg|@(2F4#n^*7v~BM1)PtkYQe<7YMID<%73 zHVcOQM;TI}eI^Z^ZwF=NoWW;%=pE?@e4Ni+iZEarO1d31*!h>mQP@t{Ka%*25FC)u ziw}sSnE)7kRZecu%JxDpx9$~?xom^(6`!!W%>p4_$HW#=ix`kdM3r8L;MGn0QDVyN zkC?o^=2{_to>fnptD91=5uQJiRX=PIe%B3yhrQ%B8&FnvF!yQ13yVGuBoe|Us5@F5 zCF=JBAalZp_8&4r0Vu-G*vY8QGguVf-QO8J-`Z7ad-z%}zRxiN6e*-)J974Rb$sI& zniY5FVgKdyI+t(ydcN*QqqUbHvdVd7;s1!TnkxS#YQTe7sID@Jo%ya+?OKtZ6rahj zbBUc}LCFUD&?15teJYj{@EXLcKV_)Ejf&_pw})&%YHT0E{qw zzHk~hp@bWA)m&l|zFAe&lvcd85Q`V0Qu*8;%>s53pTb8&O3V2K!t}sC(ftN&DM$dh zU;fK|5Pa{|;ddto&!VU4U5kb;PkKB+>{*fY<<2kIuMrcfKC+t8bhznggA|;xMLBoJ zw_xxo1;xK%3*8N(GCBI|@L~nKP|Wxt{hvUw0pY|0|Bl>W3iW*tK-Ig&&xA%0vb0-3 z$Bdp!2M25)e8hFH`EL>XZ{F=FnuaUkaqHt2iaN{UFOeaqFUi^9O`~;jaOR*j@5PA2 zt)B)Pfb;>$XWs>4?EZ^DB&(gLG;vVl8P(StP4?wpFWbWfztpdzZc+%3f$7Zt!zBG^!_trj4Ic7+(wQ;v3$W45)!!|C%=0O@-nQ zm2;Oi%g4lRFM9|H&I@6{2Vlvbl&r2**cjXHK3Tx&61*y)eQmGt!d{&$HlW}{-Y{Pc zTY_;$PQP%-H$ve9d`X9o?K2ubE1|P0Nykw9vwy2k?sgz))}n3+f(LAWzBu1@HfgI}0?X#O+ubO<`xue{e25 z5(yH)ULX3pXTjC{=mZ{#(fhXpG?~RSN|;gP$Umc(Q!g(u)^_-NCRHA`WRQO(_0?_Zjao?3aik=tXHz3Ub#F0WDMeLAE<$b6)Yq_8|VI`$or!a24ot?+HDIkr0b-fDd-yvO60HN9`4wCwnW zSEDew{ljbZ2;5}xU8SGpb*(7<{4ZWQ*>&@Tb-A+{;4Q!lF9#0uyKW_aUVL94n+Wb} zd9l&Dm79o)@ld&y;0AZCd3k+E^aYz>UObK{i1QdAP!uS@NXhBT$@yIG#*OM7 ziHGZyA;+WJQ)El;Q#^+IsoS9}0n8DUqJs34pwpAR!)RuUjMgJ5^#j=h#lyP?b#4^k zAmccVxEKBT+${RKNs+6_r`loFlyo#0BqBs^G3dqJ5n9n^@yn*f8j%$!qw#qju0;QV zlcYh4a`PPpA4ujSpd~6dYsSZHj z8q;NLZB|su)D{)cuZ{lUM0~h{=B;^Z&2Kh&TC1jkhd4og4tI zN_}KaC0eTCD#7ajw8R$GSpKifzsQ4Ba~6Yi)3NtDxbjVB=n~rC#$n;n&NMK9A}`q$ zl(w;>h$D2{c9m{*)q}%P-RY3WVe$8FZ3`L`_tp45*IqO+l;LpHALGzJA4TNleBCm) zB6kib@+LY^hMz7)Y|oz^l$5o;t<@(yu~C?}o>Xr;(+14x&)XvPfXLkhaLvH#%Op;E zjiH-i>uYid$}c2p`@iKA&yLriDS9)dx3M6*3@Or5Z7HG;lncCdTRRPP#O%>U)J@ z!i(g0JdMEYK6aknD?JmJ3Vv9BT(q&dSc#raTxj@hx53=4%t%~^CSFG*GNYsHoGL0} zb3B0PpGJh`L}%oe_>Q9RbAQ?Qr>Lf^5xMS;gwJ2$C{z~rb=MVL4 z+2|rOL^4e_%%bD2*nsRhBtVqm9IqZnWCm+io5M1MD@z>+_CX9Or8MAV#ow(Cr=`=W zrW1Ty`m*|G*&hzvfF|Q04=6P^T95*bGY1d-C*S<4gnbLp+IwZzv(JilcJp_PVbR~X z^q|Cci#Gz%J-Yc%F818iRc=tOGf?q7sxrs1OT2$r$E8p(%)}0dHt>{-9HYSAqp`kS zKi)Ubr3b9buOx;WNB(`7ed6zQZP{r^Vxe0b8H!2ggN5-ewf`u-TPOrWIf~H_z{d)6 zxT;CnFAhiblCs`*9&>#ePzRJUH)d3`7akk(_AlX?e?KckM|6%3UC!|e#M3hQKp$sD zl5x>BWq1Ibgjh_d-jmm@hL*t%&=HBs6?(F`%1O#uZ@YY27MrdclDc5)sLsdnG8G$s zEk7es>}C`w9sV(}d*nMGn=ftkc&VxVLs!yi<`rZ6?YJKHjSpve4t_srC9Vp(e{ak~ zF7#NhBQ>*s3o@3=z@hzIY>LM>y{KhrPMblM9wF8`VRu%1l5I|-LV4yp>G64dxe%^& zkwU=zHD`^Tz5Q|(B14Ikv9mXPbhJZHtib5%di=y7al@02$w{ZdbundfNR$++E^ABB87c zM|=R+)$pR4zf`_)wcyMN=GX*KeaFZhR;GCmhg&)_DELCy7(H-Z6!X=fxPvYu$5Q|; zpg|=p%fg+3P3^`}ziC~w;lWesk>XeLP5;%fPM|A7pY1NfFW*K@XKq^pjFjAI)~14f zwpuiq2}8-uCoA0(f!#0UCWi-`Iv>}LBVAn9CIj>TN~&=|DL2tzvJiuR<N_QKA^Pit8E#JgiX$5z2*Tefmv#V+;*fxGy1-dkUNE%{|Fu$CLG4FG^0| zfv!$r-%k5WG?C?uK?n^!?nT|w@3hN-T)QoPXbZik=ffB_aHEh`cv<1~Xs=-6(qx`0 z`IoioHlytCo*nJzXtZ(RyN-Fn`;a+ z(dXuEd)?>RD8Y~EnvcQ(sm z%;kES+S;cKnfNUs73h$unnT{>c@)kBXU{n^@n$Ahjl-!e z^;xXR6?vDz>deHRl^#B@c{?G`>z-&MTR&0z6;{rB=fnpFDQX?7M96^UDB`fsh63HQ}ylV7+7$en0d!dy3?4Y@*2ka7Ui!TZ$wS|x0`mcMc&US#uXWM&w{_ z3WQCu_2-INmc95f8044XBG%=lD;p26a}YM`^I#VZBHk$u@SK^tl%eJk0A-wQwK{}& zsYp0TA@!NsnuH_>97uvx%+YXvcJr~McCn)o1R~0Vt793kvu&l_^XTUSajrdiN|G(c z2EPxSy=%hUc5tw_j~%`U1jA3a7L?lccjU8eg<}-AO_mww77mu=^pGNYZq^Ix%HUoX zfB`}-`B1H=!7)XJWgM@ZS}syeA|X4Ya2qUEY@Rn2idC`uh917^Zv_CQ?%hKu1SsCx zqB?O{`G9T@pj%<>Jj>VbD@0PDv(Q7I^jf7`tDai#(YBAGb&eoaced+gh^J#djQJsS z&y!*_OUEL@#w2CV7rP#Sk<|81g|&z6y00ixDQXfag?La+l`eLaX{KuM1sUv(J)#Qf zQ`UKg_Eb<{Qa0OY8R2-7K|-JMyN17H&*=KDmBxC)P)nAqS-NuGbt1Kd&FthG2|a}g z`yRpm+sT{uDeO1-0H5`z=<<;5u6%4cUyj*;vi727@C~MVw=9I$v5z-DDV>~3Rl_07 zbAYw?d)EP-i#(iL$E=-afrl@j)Oe9I2o;E`grVnbziWZT?@DW4JTA*z9WoaK!`?_Z3B zuRZ#CT13t(m81O54RhTP^IIR_tkJ1_7rS<-)2wmR(;wLjcc|m3Bpxef@5SdLAbw z7@m|RcrrN*psta}uv1g}($!PeaJh~ou%=Oi}3fny@( z{@poQ&$(+xeM>xmaYIBVJgR7>cHHrg0o+mGJ8jC3{EidGZT{AMKx^$VQF?!0Oxz;d#lUa+1&WhU^dYVt6ZM)#aTWLcyh3qv-{9D*Q`{uK_ zGv54dGp{{>C!y5sNr<@#zMkKyIgp`EsvOyMUuV#5|c@6%{qt^{t1OPuGos z&lUy2JY$B7PC7L)73}@8w!7ccY1eqqb1$m)g)Zg7j24M6g}i-~Oz?MRqnVCc^#E!5 zG(5jQN1}_5T2PZF;)j37N?*sKlo+v}$5fG3rZfmtM3;^Xg=NCD6Jn8}4totO%6WtdHO6z0V_)3WCO{YCHD5PSlI~ z0Eh+&Fe1C%H~{h3Z6(ojKeFXb&mQc%Q1|>Q9KsRaQ8)b+gbiA+OmM;&+X(0-_;~p`8Bao%&20deBrw( zpbVGqj8N^LA1!YW4lH8?2h%*{x^jD~kAp+3RXpUJOeb&T37XzmWm6+szXt?Ni`A%G4Oi7vM#aJguWKyS#;xjftEUJ)p z@Q9^jXQMGF;NC0B=T$hW^_~nrpieauq3uUSN7Wr?s7%dr`KE z0NYiz$nU`f_pmR5&=)Q0CFxzZ)T4+9PGj1EQ*L;$KuHwlV~?mSaH9WH*J=%Z1^v>; zakEsiuARtBa3j{*=T4%8QBeUKZneUUQfb4c19J~sHG39@9#k>UzsnqIJI8@!$lK2x z)09*5H{Kvb7sSX40L-Ekb1#ym;`!$NJ8-b0AYH+T@Fnrb(w*Q73}EQ73p+ixA-uiB zH_9e;3<7}W(+zUVi0!9x#uw!x{T#^LQJbMv%#kG`yaVXY?kB!-Uk{x_xdBW4LSD=N z=zpWqU%)hj;>ERTdm389zcape4|PNkFgP|=<(y*T6w(8Wn8%sAPmQ0JA~&(%8Mr-N z|KYln78o!$q%&QAn7*BolD6ZWo{X6<=Hf6=`4gr6iq$1o`lyF@%79s?O4&IEs$0S1- zDCACp0r`?GjR zJ-pGfQ=XoyGf~K&G^~rl z?}(9cva810cG*hotE7&8Fpj*yN42NhJ%#jt=QmVL9&S;Okx6)j{JRn*fuKtYzn7-J z6oZVSusM=HK6*9pP+QBIxZF-p(UBH=A_JOUe*VifEa*ehy&6YWbL1;^ofB*TMx>JUm~o_0k8Y;e9^F_vduj1)xp57F9(G1Q z@$M+@IR4_FM$f-vs)wSGIVUu~;g)u1B{In+X9pOblBeWiG6k@#^d~?__!HwDT%g zVgm}4;eUOteL?*O2;0W-mREz_*#Y>@$2el#aI0ST*5AXT_o+7NG6m20SL(2vxdYSeGxLYu{T;TleZ8X@S&4U4tFOZw_{Xa*Z|RyM`B9OxTq)ytX9TJN#CfH);?82oBcYC1Vd1qumBUl zyrB**0@RJHA9ilNkE+l`yyR@@fX(M_zgk%>TybaSIu_i{kxRk(yj@ zN23_y(=FaQ8S_~@wRmx=H4;5lPeMIyWv)5*V}L)$4E1H2$|k;={nC8ntBW65^GE+g zNmDqjs`{&RG1l{bvhVxNTIOSsDrI>Bog(FYmR!h=~+` z_WtWIM1JbiKkZFe`mIOHYbdSpZ;TMK_-P49s_540c~Opd8T=$MCxQ#N&@a>w4a zXADzSuL$vsSw}5gt<M>eyye zA78YNE}n5$jmzjqAWl?s&$0F8a8~BQWa@tUWco?tVCA$2syjVX*2pV`?v>gjTgUqc zfy({!YO$qu2VlOE-Y#w0$+{#Q=~ePOm)98S?7VvyIUk@bV_(3-WEHJ<1D)&V?NEpJ z%*ox(z8&uu0I2hR;XEc~;n<^w(3O@fHVxct^rzn)yB)#N8(<($PMPO#l*-VYyj0Qgo4 zZzi>6{Zdbp+Pr-6fW_^gsf7jSS};t#wXHPsphln-tBb(;|KfyBXLk`KW%z#9 zd>hUDh0FI_(qe==QK%cqijX=T`?%5~QeTI5`nRD1E3r3omCbHH27$d4i;1+|25!&m zr{|=Hh!@HDtepp1_Oc%_jX|Pnx1&%>drgWOX}ctDPd#eGvcDsBEYXY{;{}SC_-&YD z?sM!oZ{GhMl3Vo=;!?{hL321us#ED}@eyPy2h%SXFNUZ@1~sXe9i#*Eqk6!w zFu-kQ>MF0hD12K`N*L6ip%^v|#Ac94Lmu-`d$# TK_Complete' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 280 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 370 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 490 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 610 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_drtn_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 750 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 840 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/critical-and-near-critical.rpt b/assets/openxer_reports/critical-and-near-critical.rpt new file mode 100644 index 0000000..8ceb747 --- /dev/null +++ b/assets/openxer_reports/critical-and-near-critical.rpt @@ -0,0 +1,455 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Critical and Near Critical' + ReportName = 'Critical and Near Critical' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Activities that are not complete and are critical or have less than 10 days of total float, least float first.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 280 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 370 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 490 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 610 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'remain_drtn_hr_cnt' + FieldTitle = 'Remaining Duration' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 750 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'total_float_hr_cnt' + FieldTitle = 'Total Float' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 840 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'wbs_name' + FieldTitle = 'WBS' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' status_code <> TK_Complete' + ' #begin_or' + ' critical_flag = Y' + ' total_float_hr_cnt < 80' + ' #end' + '#end') + SortBy.Strings = ( + 'total_float_hr_cnt ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 280 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 370 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 490 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 610 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_drtn_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 750 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 840 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/lookahead-2-week-by-wbs.rpt b/assets/openxer_reports/lookahead-2-week-by-wbs.rpt new file mode 100644 index 0000000..c2b05cc --- /dev/null +++ b/assets/openxer_reports/lookahead-2-week-by-wbs.rpt @@ -0,0 +1,513 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = '2-Week Lookahead by WBS' + ReportName = '2-Week Lookahead by WBS' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Activities not yet complete that start or continue within 2 weeks of the data date.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 630 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'remain_drtn_hr_cnt' + FieldTitle = 'Remaining Duration' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 770 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'total_float_hr_cnt' + FieldTitle = 'Total Float' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 860 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'activity_status' + FieldTitle = 'Status' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'PROJWBS' + GroupByType = gtTree + MaxLevels = 0 + HideRowIfNoChildren = True + IncludeParents = True + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + ShowIndent = True + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupByTreeRecurse + Top = 1 + Width = 960 + Height = 20 + ContainerAlign = alcTop + end + object TCVReportGroupBy + Top = 21 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByOuterJoinPath = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' status_code <> TK_Complete' + ' start_date <= DD+2W' + ' end_date >= DD' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_drtn_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 770 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 860 + Width = 100 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'activity_status' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/lookahead-3-week-by-wbs.rpt b/assets/openxer_reports/lookahead-3-week-by-wbs.rpt new file mode 100644 index 0000000..f8223d2 --- /dev/null +++ b/assets/openxer_reports/lookahead-3-week-by-wbs.rpt @@ -0,0 +1,513 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = '3-Week Lookahead by WBS' + ReportName = '3-Week Lookahead by WBS' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Activities not yet complete that start or continue within 3 weeks of the data date.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 630 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'remain_drtn_hr_cnt' + FieldTitle = 'Remaining Duration' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 770 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'total_float_hr_cnt' + FieldTitle = 'Total Float' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 860 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'activity_status' + FieldTitle = 'Status' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'PROJWBS' + GroupByType = gtTree + MaxLevels = 0 + HideRowIfNoChildren = True + IncludeParents = True + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + ShowIndent = True + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupByTreeRecurse + Top = 1 + Width = 960 + Height = 20 + ContainerAlign = alcTop + end + object TCVReportGroupBy + Top = 21 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByOuterJoinPath = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' status_code <> TK_Complete' + ' start_date <= DD+3W' + ' end_date >= DD' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_drtn_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 770 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 860 + Width = 100 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'activity_status' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/milestones.rpt b/assets/openxer_reports/milestones.rpt new file mode 100644 index 0000000..c066ea5 --- /dev/null +++ b/assets/openxer_reports/milestones.rpt @@ -0,0 +1,451 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Milestones' + ReportName = 'Milestones' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Start and finish milestones in date order.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Milestone' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_type' + FieldTitle = 'Type' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Date' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 630 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'total_float_hr_cnt' + FieldTitle = 'Total Float' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 720 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'activity_status' + FieldTitle = 'Status' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 820 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'wbs_name' + FieldTitle = 'WBS' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' task_type like %Milestone' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_type' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 720 + Width = 100 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'activity_status' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 820 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/open-ends-and-logic-gaps.rpt b/assets/openxer_reports/open-ends-and-logic-gaps.rpt new file mode 100644 index 0000000..4950462 --- /dev/null +++ b/assets/openxer_reports/open-ends-and-logic-gaps.rpt @@ -0,0 +1,654 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Open Ends and Logic Gaps' + ReportName = 'Open Ends and Logic Gaps' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Activities that are not complete and have no predecessor or no successor.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 630 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'total_float_hr_cnt' + FieldTitle = 'Total Float' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 720 + Width = 240 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'wbs_name' + FieldTitle = 'WBS' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'PROJECT' + MaxLevels = 0 + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 24 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 23 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'No predecessor' + FontStyle = rfsHeading2 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -16 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' predecessor_count = 0' + ' status_code <> TK_Complete' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 720 + Width = 240 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + object TCVReportGroupBy + Top = 121 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'PROJECT' + MaxLevels = 0 + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 24 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 23 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'No successor' + FontStyle = rfsHeading2 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -16 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_and' + ' successor_count = 0' + ' status_code <> TK_Complete' + '#end') + SortBy.Strings = ( + 'start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 300 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 390 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 510 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'total_float_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 720 + Width = 240 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/predecessors-and-successors.rpt b/assets/openxer_reports/predecessors-and-successors.rpt new file mode 100644 index 0000000..a4c25ea --- /dev/null +++ b/assets/openxer_reports/predecessors-and-successors.rpt @@ -0,0 +1,593 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Predecessors and Successors by Activity' + ReportName = 'Predecessors and Successors by Activity' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Each activity with the activities before and after it, and the date they finish or start.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 110 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 110 + Width = 380 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 490 + Width = 60 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'pred_type' + FieldTitle = 'Type' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 550 + Width = 80 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'lag_hr_cnt' + FieldTitle = 'Lag' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 630 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Date' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + SortBy.Strings = ( + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 22 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 110 + Height = 21 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 110 + Width = 380 + Height = 21 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByOuterJoinPath = 'TASKPREDPREDS' + MaxLevels = 0 + SortBy.Strings = ( + 'PREDTASK|task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Left = 10 + Width = 135 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Predecessor (finishes)' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 145 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'PREDTASK|task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 235 + Width = 255 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'PREDTASK|task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 490 + Width = 60 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'pred_type' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 550 + Width = 80 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'lag_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 110 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'PREDTASK|end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + object TCVReportGroupBy + Top = 121 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByOuterJoinPath = 'TASKPREDSUCCS' + MaxLevels = 0 + SortBy.Strings = ( + 'TASK|task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Left = 10 + Width = 135 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Successor (starts)' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 145 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'TASK|task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 235 + Width = 255 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'TASK|task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 490 + Width = 60 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'pred_type' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 550 + Width = 80 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'lag_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 630 + Width = 110 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'TASK|start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/progress-this-period.rpt b/assets/openxer_reports/progress-this-period.rpt new file mode 100644 index 0000000..ad31964 --- /dev/null +++ b/assets/openxer_reports/progress-this-period.rpt @@ -0,0 +1,452 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Progress This Period' + ReportName = 'Progress This Period' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Activities that started or finished in the seven days before the data date.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_code' + FieldTitle = 'Activity ID' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 270 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_name' + FieldTitle = 'Activity Name' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 360 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'act_start_date' + FieldTitle = 'Actual Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 480 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'act_end_date' + FieldTitle = 'Actual Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 600 + Width = 90 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'complete_pct' + FieldTitle = '% Complete' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 690 + Width = 140 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'remain_drtn_hr_cnt' + FieldTitle = 'Remaining Duration' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 830 + Width = 130 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'activity_status' + FieldTitle = 'Status' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'TASK' + MaxLevels = 0 + Filter.Strings = ( + '#begin_or' + ' act_start_date >= DD-7D' + ' act_end_date >= DD-7D' + '#end') + SortBy.Strings = ( + 'act_start_date ASC' + 'task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 90 + Width = 270 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 360 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'act_start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 480 + Width = 120 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'act_end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 600 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'complete_pct' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 690 + Width = 140 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_drtn_hr_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 830 + Width = 130 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'activity_status' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/resource-usage-by-week.rpt b/assets/openxer_reports/resource-usage-by-week.rpt new file mode 100644 index 0000000..bd22e59 --- /dev/null +++ b/assets/openxer_reports/resource-usage-by-week.rpt @@ -0,0 +1,418 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'Resource Usage by Week' + ReportName = 'Resource Usage by Week' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + DateUnits = utWeek + StartDate = 'DD' + FinishDate = 'DD+10W' + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 106 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Remaining units of each resource by activity for ten weeks from the data date.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + end + object TCVReportRow + Top = 85 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 230 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Resource / Activity' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 230 + Width = 70 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[column_date]' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + ShowTimeDistrib = True + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'RSRC' + MaxLevels = 0 + SortBy.Strings = ( + 'rsrc_short_name ASC') + HideRowIfNoChildren = True + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 22 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 90 + Height = 21 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'rsrc_short_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 90 + Width = 140 + Height = 21 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'rsrc_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByOuterJoinPath = 'TASKRSRC' + MaxLevels = 0 + SortBy.Strings = ( + 'TASK|start_date ASC' + 'TASK|task_code ASC') + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportRow + Top = 1 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Left = 10 + Width = 90 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'TASK|task_code' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 100 + Width = 130 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'TASK|task_name' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 230 + Width = 70 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_qty' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + ShowTimeDistrib = True + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + object TCVReportRow + Top = 1 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Left = 10 + Width = 220 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Total' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 230 + Width = 70 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldSummary + DataField = 'remain_qty' + SummaryGroupByPath = 'TASKRSRC-RSRC:' + AggrMode = amSum + FontStyle = rfsHeading3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + ShowTimeDistrib = True + end + end + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/openxer_reports/wbs-summary.rpt b/assets/openxer_reports/wbs-summary.rpt new file mode 100644 index 0000000..400cf3b --- /dev/null +++ b/assets/openxer_reports/wbs-summary.rpt @@ -0,0 +1,452 @@ +object TCVReport + Width = 1056 + Height = 600 + ParentFont = False + Color = clWhite + Title = 'WBS Summary' + ReportName = 'WBS Summary' + VDBEngineName = 'VDBORION' + PageSettingsList.Strings = ( + '(0||()(' + ' (0||page(orientation|2|paper_size|1|length|8.5|width|11|scale|100|use_fit_to|N)())' + ' (0||margins(left_margin|0.5|right_margin|0.5|top_margin|0.5|bottom_margin|0.5|header_margin|0.3|footer_margin|0.3)())' + ' (0||header()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text|[date] [time]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))' + ' (0||footer()(' + ' (0||left(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||middle(text|Page [page_number] of [total_pages]|image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))' + ' (0||right(text||image_file_name||mode|T)(' + ' (0||font(font_name|Arial|color|0|size|10|style|Regular)())))))))') + FontHeading1.Color = clBlack + FontHeading1.Height = -19 + FontHeading1.Name = 'Arial' + FontHeading1.Style = [fsBold] + FontHeading2.Color = clBlack + FontHeading2.Height = -16 + FontHeading2.Name = 'Arial' + FontHeading2.Style = [fsBold] + FontHeading3.Color = clBlack + FontHeading3.Height = -13 + FontHeading3.Name = 'Arial' + FontHeading3.Style = [fsBold] + FontHeading4.Color = clBlack + FontHeading4.Height = -11 + FontHeading4.Name = 'Arial' + FontHeading4.Style = [fsBold] + FontBody1.Color = clBlack + FontBody1.Height = -19 + FontBody1.Name = 'Arial' + FontBody1.Style = [] + FontBody2.Color = clBlack + FontBody2.Height = -16 + FontBody2.Name = 'Arial' + FontBody2.Style = [] + FontBody3.Color = clBlack + FontBody3.Height = -13 + FontBody3.Name = 'Arial' + FontBody3.Style = [] + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctReportHeader + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 86 + ContainerAlign = alcTop + ContainerType = rctPageHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 28 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 27 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = '[title]' + FontStyle = rfsHeading1 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -19 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + object TCVReportRow + Top = 29 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 560 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Project: [project_code] [project_name]' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 560 + Width = 400 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctVariable + VariableField = 'Data date: [data_date]' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 47 + Width = 960 + Height = 18 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 960 + Height = 17 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctCustomText + Text = 'Each WBS element with its dates and the costs of the activities below it.' + FontStyle = rfsBody3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + object TCVReportRow + Top = 65 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 330 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'wbs_name' + FieldTitle = 'WBS Element' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 330 + Width = 80 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'task_cnt' + FieldTitle = 'Activities' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 410 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'start_date' + FieldTitle = 'Start' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 530 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'end_date' + FieldTitle = 'Finish' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 650 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'target_cost' + FieldTitle = 'Budgeted Cost' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 750 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'act_cost' + FieldTitle = 'Actual Cost' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + object TCVReportTextCell + Left = 850 + Width = 110 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + CellType = ctFieldTitle + DataField = 'remain_cost' + FieldTitle = 'Remaining Cost' + FontStyle = rfsHeading3 + Borders = [rpBottom] + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupBy + Top = 1 + Width = 960 + Height = 120 + ContainerAlign = alcTop + GroupByTableName = 'PROJWBS' + GroupByType = gtTree + MaxLevels = 0 + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcTop + ContainerType = rctGroupByHeader + object TCVReportRow + Top = 1 + Width = 960 + Height = 20 + Color = clWhite + ContainerAlign = alcTop + object TCVReportTextCell + Width = 330 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'wbs_name' + FontStyle = rfsHeading3 + Alignment = taLeftJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [fsBold] + ShowIndent = True + end + object TCVReportTextCell + Left = 330 + Width = 80 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'task_cnt' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 410 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'start_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 530 + Width = 120 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'end_date' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 650 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'target_cost' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 750 + Width = 100 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'act_cost' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + object TCVReportTextCell + Left = 850 + Width = 110 + Height = 19 + ParentFont = False + Color = clWhite + AutoAlignment = False + DataField = 'remain_cost' + FontStyle = rfsBody3 + Alignment = taRightJustify + Font.Color = clBlack + Font.Height = -13 + Font.Name = 'Arial' + Font.Style = [] + end + end + end + object TCVReportSectionContainer + Top = 1 + Width = 960 + Height = 200 + ContainerAlign = alcClient + ContainerType = rctDetail + object TCVReportGroupByTreeRecurse + Top = 1 + Width = 960 + Height = 20 + ContainerAlign = alcTop + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctGroupbyFooter + end + end + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctPageFooter + end + object TCVReportRowContainer + Top = 1 + Width = 960 + Height = 48 + ContainerAlign = alcBottom + ContainerType = rctReportFooter + end +end diff --git a/assets/playbooks/audit.md b/assets/playbooks/audit.md new file mode 100644 index 0000000..db45f3c --- /dev/null +++ b/assets/playbooks/audit.md @@ -0,0 +1,23 @@ +# Audit logic and health + +Goal: a short list of findings, worst first, each with what it means and what to do. Read only; change nothing unless asked. + +1. Start with `openxer_check_schedule`: one call gives every health count against its target, and each row with offenders names its first five. Use its rows as the backbone of the audit. Call it again with `check=` and a row name only when you need more than those five, and only for failing rows. + +2. Open ends: row `Logic`. An activity without a predecessor floats to the data date; one without a successor hides its delay from the finish. Only the start and finish milestones should be open. List the IDs and the logic each needs. + +3. Constraints: rows `Hard Constraints` and `Soft Constraints`. A hard constraint can push dates against logic and create false negative float. Ask whether each is a real contract date; `openxer_load` with `fields=task_code,name,constraint,constraint_date` and `activities=` shows them. + +4. Lags and leads: rows `Negative lags`, `Positive Lags`, `Long Lags`. A negative lag (lead) hides overlap that should be its own activity; a long lag is usually a missing activity such as curing or delivery. The listed relationships show which ties to rewrite. + +5. Long durations: row `Large Durations`. Work longer than about a month is hard to measure; suggest splitting it by area or step. + +6. High float: row `Large Float`. Very high float usually means missing successors, not spare time. Check the successors of the listed activities. + +7. Relationship mix: row `Relationship Types`. Mostly finish to start is healthy; many start to start or finish to finish ties, or any start to finish, need a reason. + +8. Out-of-sequence progress: row `Out Of Sequence`. Work done before its predecessor finished means the logic or the progress is wrong. + +9. Negative float: row `Negative Float`. The schedule cannot meet a constraint or the must finish date; find the driving path (see the critical-path playbook). + +Report: the overall picture in two lines, then each finding with its count, the worst few Activity IDs and the fix. Say which rows passed. Rows `Late Activities` and `BEI` compare with the project's own dates in the chat, not a baseline, so do not draw conclusions from them. diff --git a/assets/playbooks/build.md b/assets/playbooks/build.md new file mode 100644 index 0000000..467effe --- /dev/null +++ b/assets/playbooks/build.md @@ -0,0 +1,19 @@ +# Build a schedule + +Goal: a schedule the field can run, with logic that drives every date. + +1. Read what is there. `openxer_load` with `limit=0` gives the counts, the data date and the options. Then `fields=task_code,name,wbs,status` with `sort=wbs` shows the current outline. Ask the user for the scope, the start date, the work week and any fixed dates before you propose anything. + +2. WBS first. Agree an outline that follows how the job is built: areas or systems, then disciplines, demolition before installation within each. Propose the elements with `add_wbs` in one `openxer_apply` batch. + +3. Activities. One activity is one crew doing one thing in one place. Name each so a foreman knows what to do without asking: verb, object, location ("Set pump P-101 on foundation, Area 100"), never codes or internal shorthand. Use milestones for start, finish and key handovers. Propose them with `add_activity` (with `wbs` and `name`), then `set_activity` for `original_duration`. + +4. Durations. Base them on quantities and crew rates the user gives; when there are none, say the figure is an assumption. Keep most activities under about 20 working days so progress can be measured; split longer ones. + +5. Logic. Every activity needs a predecessor and a successor, except the start and the finish milestones. Use finish to start unless work truly overlaps; then start to start or finish to finish with a lag, and say why. Add ties with `relationship` (`action` add, `kind`, `lag_hours`). Do not use constraints to place work that logic should place. + +6. Calendars and resources. Put each activity on the calendar of the crew that does it (`set_activity` field `calendar`). Assign crews with `assign_resource` when the user wants a resource loaded schedule. + +7. Schedule and check. Add a `schedule` operation at the end of the batch so the preview shows the dates. Then run `openxer_check_schedule` and fix what fails (see the schedule-check playbook). Report the finish date, the driving path and anything you assumed. + +Send the work as a few batches the user can review: outline, activities, logic. Each batch is only a proposal until the user approves it. diff --git a/assets/playbooks/critical-path.md b/assets/playbooks/critical-path.md new file mode 100644 index 0000000..2dfb359 --- /dev/null +++ b/assets/playbooks/critical-path.md @@ -0,0 +1,19 @@ +# Read the critical path + +Goal: say which chain of work sets the finish date, what is close behind it, and where float is being used up. + +1. The finish. `openxer_load` with `limit=0` gives the scheduled finish, the must finish date and the options (longest path or a total float threshold for critical). + +2. The critical activities. `openxer_load` with `critical=true`, `sort=early_start` and `fields=task_code,name,early_start,early_finish,total_float_minutes,driving_path` lists them in order. Relationships come with the page. Walk the chain from the data date to the finish through the driving ties; a break in the chain means logic is missing or a constraint is holding a date. + +3. Near critical. `openxer_load` with `sort=total_float_minutes` and a `limit` of about 30 shows the activities with least float first. Group them into chains; a chain a few days behind the critical one can take over after one slip. Floats are working minutes: divide by 60 for hours and by the calendar's hours per day for days, and say which you used. + +4. Total and free float. Total float is how far an activity can slip before the finish moves. Free float is how far it can slip before its next activity moves. Free float of zero with high total float means it shares float with the activities after it: one slip uses the float of the whole chain. Ask for `free_float_minutes` in `fields` to see this. + +5. What consumes float. Compare float along a chain: where it drops, look at the ties into that point. Long lags, start to start ties with lags, constraints and activities on a shorter calendar all eat float. `openxer_load` with `fields=task_code,name,calendar_id,constraint` and `activities=` shows the suspects. + +6. Negative float means the finish or a constraint cannot be met as planned. Report how many days late, the chain that causes it, and point to the delay-recovery playbook for options. + +If the project uses multiple float paths, `float_path` and `float_path_order` in `fields` give each path in order. + +Report the chain in plain words: Activity IDs with names, start to finish, and the two or three places the finish is most at risk. diff --git a/assets/playbooks/delay-recovery.md b/assets/playbooks/delay-recovery.md new file mode 100644 index 0000000..6f29830 --- /dev/null +++ b/assets/playbooks/delay-recovery.md @@ -0,0 +1,19 @@ +# Find the delay and recover time + +Goal: say how late the job is, what is driving it, and list real options to pull time back with what each costs or risks. + +1. How late against what. The chat reads the open project only: its baselines are not available here. `openxer_load` with `limit=0` gives the scheduled finish and the must finish date; compare those. If there is no must finish date, ask the user for the target date or the baseline finish. To compare activity by activity with the baseline, tell the user to use the baseline columns or Check Schedule in OpenXER itself. + +2. Find the drivers. Follow the critical-path playbook: `openxer_load` with `critical=true` and `sort=early_start`, then walk the chain. The drivers are the activities on that chain that started late, are running long (`remaining_duration_minutes` against `original_duration_minutes`), or wait on a lag or a constraint. + +3. List options, each with its cost and risk, never only the cheap ones: + - Overlap work: change a finish to start tie to start to start with a lag where the work can really run in parallel. Risk: rework and crowding. + - Shorten durations: more crews or longer shifts. Cost: labor and overtime; check the crews exist (`openxer_usage` with `resource=` shows their load). + - Change the work week: put the activity on a longer calendar. Cost: premium time, fatigue. + - Split an activity so the next trade can start on the first part. + - Remove or relax a constraint or a lag that holds the chain, when it is not a real requirement. + - Re-sequence: do work off the critical path later. + +4. Show the effect. In Edit mode propose one option at a time with `openxer_apply`, ending the batch with a `schedule` operation, so the preview shows the new finish and float. State the days gained against the change made. Never shorten durations or delete logic just to hit the date without saying so. + +5. Report: days late, the two or three drivers, the options ranked by time gained against cost and risk, and what the user must decide. Nothing changes until the user approves a proposal. diff --git a/assets/playbooks/earned-value.md b/assets/playbooks/earned-value.md new file mode 100644 index 0000000..33f1421 --- /dev/null +++ b/assets/playbooks/earned-value.md @@ -0,0 +1,19 @@ +# Analyze earned value performance + +Goal: evaluate schedule and cost performance using earned value metrics, identify the activities driving variance, and separate measurement gaps from real field slippage. + +1. Read project and activity earned value. Call `openxer_earned_value` with `basis=cost` first, and if the schedule is labor-driven or cost values are zero, also call `openxer_earned_value` with `basis=labor_units`. Record the project totals: BAC, PV, EV, AC, SV, CV, SPI, CPI, ETC, EAC and VAC. + +2. Verify the data basis before interpreting ratios: + - Check whether activities actually carry budgeted cost or labor units. Run `openxer_check_schedule` and inspect the `Resources / Cost` row to see how much of the schedule is loaded. + - Note whether EV and PV reflect current planned dates rather than an external baseline, and state that clearly if no baseline is loaded. + - Watch for activities with actual units or costs recorded while remaining work or percent complete looks inconsistent. + +3. Isolate the biggest drivers. From the per-activity earned value rows, rank the top five to ten activities contributing the largest negative SV (behind schedule) and negative CV (over budget). For those Activity IDs, call `openxer_load` with `activities` and `fields=task_code,name,wbs,status,early_start,early_finish,remaining_duration_minutes,total_float_minutes` so you can tie financial or labor slippage directly to critical path impact. + +4. Inspect time-phased burn on the worst offenders. Where a key activity or trade is burning faster than earned progress, call `openxer_usage` with `activity` or `resource` and `interval=week` to see whether the overrun is front-loaded, sustained or concentrated in specific periods. + +5. Report cleanly: + - One headline table of project totals (BAC, PV, EV, AC, SV, CV, SPI, CPI, EAC, VAC). + - Top schedule variance drivers and top cost variance drivers by Activity ID and name, noting which ones sit on the critical path. + - Data quality caveats and the next two or three corrective checks for project controls. diff --git a/assets/playbooks/lookahead.md b/assets/playbooks/lookahead.md new file mode 100644 index 0000000..4d0b9dd --- /dev/null +++ b/assets/playbooks/lookahead.md @@ -0,0 +1,19 @@ +# Build a field lookahead + +Goal: produce a practical 2, 3 or 6 week field lookahead grouped by WBS or area, flagging critical work, open prerequisites and readiness risks. + +1. Confirm the window. Call `openxer_load` with `limit=0` first to read the project data date and activity counts. Unless the user asked for another horizon, use a 3 week window starting at the data date (or 2 weeks for turnarounds, 6 weeks for procurement and civil work). + +2. Pull upcoming and active work. Call `openxer_load` with `sort=early_start`, `limit=50`, and `fields=task_code,name,wbs,status,early_start,early_finish,remaining_duration_minutes,total_float_minutes,constraint,constraint_date`. Page with `offset` until early starts pass the end of the lookahead window. Ignore activities whose status is already Completed. + +3. Check readiness and constraints. Look for: + - In progress activities that should finish inside the window, especially any with zero or negative total float. + - Upcoming starts whose predecessors are still incomplete or out of sequence: inspect the relationships returned with those activities, and check whether any driving predecessor is running late. + - Constraints or external dependencies: call `openxer_records` with `kind=issues` or `kind=risks`, and `openxer_documents` when permits, drawings or submittals are tied to lookahead activities. + +4. Group and prioritize cleanly for superintendents and foremen: + - Group rows by WBS or work area, ordered by early start. + - Show a compact table with Activity ID, Name, Status, Start, Finish, Remaining duration and Total Float. + - Highlight critical and near critical activities at the top of each group. + +5. Close with a short readiness checklist: the top three to five handoffs, permits, drawings, materials or predecessor completions needed before the next week starts, naming each Activity ID so the team can jump straight to it in OpenXER. diff --git a/assets/playbooks/narrative.md b/assets/playbooks/narrative.md new file mode 100644 index 0000000..a7bf6d7 --- /dev/null +++ b/assets/playbooks/narrative.md @@ -0,0 +1,18 @@ +# Write an executive schedule narrative + +Goal: draft a clear, factual weekly or monthly schedule narrative that a scheduler can paste straight into an owner or management report. + +1. Gather the headline numbers. Call `openxer_load` with `limit=0` for the data date, scheduled finish, must finish date and total counts. Then call `openxer_load` with `critical=true`, `sort=early_start`, `limit=50`, and `fields=task_code,name,wbs,status,early_start,early_finish,actual_start,actual_finish,remaining_duration_minutes,total_float_minutes` to read the driving chain. + +2. Check recent completions and current work. Pull active and recently finished tasks with `openxer_load`, `sort=-actual_finish` or `sort=early_finish`, including `status`, `actual_start`, `actual_finish`, `early_start`, `early_finish` and `total_float_minutes`. Also run `openxer_check_schedule` so any serious health issues (open ends, out of sequence work, invalid progress dates or negative float) are caught rather than hidden. + +3. Add cost, earned value and risk context when present. Call `openxer_earned_value` if the schedule carries cost or labor units, and `openxer_records` with `kind=issues` and `kind=risks` for open project issues. Be explicit when baselines are not attached in chat: compare scheduled finish against the must finish date, and note that activity level baseline variance comes from OpenXER directly. + +4. Write the narrative in short, copy-ready sections: + - Executive summary: data date, forecast finish, variance to must finish, and overall status in three to four plain sentences. + - Critical path and key drivers: name the driving activities by Activity ID and name, explaining what holds the finish date. + - Progress this period: completed work and active fronts. + - Upcoming focus: key starts and milestones in the next two to four weeks. + - Risks, health notes and decisions needed: concrete items requiring owner or management action. + +5. Keep every date, duration and float grounded in tool output. Never pad with filler or invent variance numbers. diff --git a/assets/playbooks/resource-review.md b/assets/playbooks/resource-review.md new file mode 100644 index 0000000..026f8c8 --- /dev/null +++ b/assets/playbooks/resource-review.md @@ -0,0 +1,19 @@ +# Review resource load and crew bottlenecks + +Goal: inspect time-phased resource demand, spot crew peaks or overallocations, and evaluate practical ways to smooth load without hiding schedule slippage. + +1. Understand the schedule frame. Call `openxer_load` with `limit=0` for the data date and project finish, then inspect critical or upcoming work with `openxer_load`, `sort=early_start`, `fields=task_code,name,wbs,status,early_start,early_finish,remaining_duration_minutes,total_float_minutes`. Run `openxer_check_schedule` to see the `Resources / Cost` coverage first so you know if large parts of the schedule are unloaded. + +2. Pull time-phased demand. Call `openxer_usage` with `interval=week` (or `interval=day` for short turnarounds, `interval=month` for multi-year jobs) for the target `resource` or `activity`. Compare budgeted, actual, remaining and remaining late units across periods. Use `costs` enabled when the user asks about cash flow or burn rate rather than crew hours. + +3. Spot bottlenecks and timing flexibility: + - Identify peak periods where remaining demand spikes above normal crew capacity. + - Check which activities inside each peak have positive total float versus zero float. Non-critical activities can often shift inside their float window without moving the finish date; critical activities cannot. + - Check whether remaining late demand pushes a bigger spike near the end of the project, which signals rising schedule risk. + +4. Evaluate mitigation options honestly: + - Shift non-critical work within available float using soft logic or leveling. + - Split or stagger overlapping work fronts, or adjust crew sizes (`set_assignment`) and durations (`set_activity`) where productivity allows. + - In Edit mode, test leveling with `openxer_apply` using `schedule` with `level_resources` so the user sees the exact finish date trade-off before approving anything. + +5. Report: peak periods and demand figures, the specific Activity IDs stacked in each peak (flagging critical versus float-bearing tasks), and ranked options with their impact on both crew demand and project finish. diff --git a/assets/playbooks/schedule-check.md b/assets/playbooks/schedule-check.md new file mode 100644 index 0000000..cab0acf --- /dev/null +++ b/assets/playbooks/schedule-check.md @@ -0,0 +1,25 @@ +# Run Check Schedule + +Goal: the schedule's health in one call, each result explained, and what to look at next. + +1. Run `openxer_check_schedule`. Each row has the check, the count of offenders, of how many it looked at, the result (a percent, or an index for `BEI`), the target and whether it passed. Thresholds for the long lag, large float and large duration rows are in hours in the answer. Each row with offenders names its first five; relationships come as predecessor, successor and type. Only when you need the full list of a failing row, call it again with `check=` and the row name. + +2. What each row means and what a failure points to: + - `Logic`: activities with no predecessor or no successor. Open ends hide delay. Add the missing ties. + - `Negative lags`: leads. Usually overlap that should be its own activity or a start to start tie. + - `Positive Lags`: waiting time with no activity behind it; check it is real. + - `Long Lags`: lags above the threshold, often a missing activity such as curing, delivery or an inspection. + - `Relationship Types`: share of finish to start ties; low means heavy use of overlaps that need checking. + - `Hard Constraints`: dates that override logic. Keep only real contract dates. + - `Soft Constraints`: limits that still let logic move dates; fine when they reflect access or permits. + - `Large Float`: float above the threshold, usually missing successors. + - `Negative Float`: the plan cannot meet a constraint or the must finish date; see the critical-path playbook. + - `Large Durations`: remaining work above the threshold; split it so progress can be measured. + - `Activities with Invalid progress dates`: actual dates after the data date, or open work forecast before it. Fix the progress. + - `Resources / Cost`: activities with no resource or expense; fine for a logic-only schedule, a gap for a loaded one. + - `Late Activities` and `BEI`: these compare with a baseline. The chat has none, so they are measured against the project's own planned dates and say nothing about slippage. Tell the user to run Check Schedule in OpenXER with a project baseline assigned for real figures. + - `Out Of Sequence`: work started before its predecessor finished. Either the progress or the logic is wrong. + +3. Look closer at the failing rows. `openxer_load` with `activities=` and the listed IDs, and `fields=task_code,name,constraint,constraint_date,total_float_minutes` (or the fields that row is about), shows the detail. Relationships come with them. + +4. Report: how many rows pass, then each failing row with its result against its target, the worst few Activity IDs and the fix, most serious first (logic and negative float before the rest). diff --git a/assets/playbooks/update.md b/assets/playbooks/update.md new file mode 100644 index 0000000..61f5b01 --- /dev/null +++ b/assets/playbooks/update.md @@ -0,0 +1,15 @@ +# Update the schedule + +Goal: the schedule shows what really happened up to the new data date, and the user knows what moved and why. + +1. Where it stands. `openxer_load` with `limit=0` gives the current data date and finish. Then `fields=task_code,name,status,actual_start,actual_finish,remaining_duration_minutes` with `sort=early_start` and a small `limit` lists the work that should be moving; add `wbs=` to stay in one area. + +2. Collect progress from the user, activity by activity: actual start, actual finish, percent complete or remaining duration. Never guess progress. If the user wants everything progressed as planned up to the new date, that is `update_progress` with the new `data_date`; say it assumes the plan happened. + +3. Enter the facts. In one `openxer_apply` batch use `set_activity` for each field: `actual_start`, `actual_finish`, `remaining_duration` (hours) or `physical_percent_complete`. Then move the data date with `set_project` field `data_date`, and end with a `schedule` operation. + +4. Check the progress makes sense before you send it. An actual date after the new data date, a finish before its start, or remaining work on a finished activity is wrong. `openxer_check_schedule` with `check=Activities with Invalid progress dates` and `check=Out Of Sequence` finds these after the update; out of sequence means work started before its predecessor finished, so ask whether the logic or the dates are right. + +5. Explain what moved. The preview's diff lists every changed date and float. Compare the finish before and after. For each activity that slipped, follow its predecessors with `openxer_load` (`activities=` with the IDs, relationships come with them) until you reach the cause: late progress, a longer remaining duration, or new logic. Name the cause in plain words. + +6. Report briefly: new data date, new finish and its change, the activities that drove it, and anything the user still has to confirm. The batch changes nothing until the user approves it. diff --git a/assets/playbooks/what-if.md b/assets/playbooks/what-if.md new file mode 100644 index 0000000..d4667f1 --- /dev/null +++ b/assets/playbooks/what-if.md @@ -0,0 +1,21 @@ +# Run a what-if schedule scenario + +Goal: test a proposed change cleanly in Edit mode, measure its exact effect on finish dates, milestones and float, and let the user decide whether to apply or discard it. + +1. Establish the baseline state before proposing anything. Call `openxer_load` with `limit=0` to record the current data date, scheduled finish and must finish date. Also call `openxer_load` with `activities` for the affected Activity IDs (and `critical=true` if the change may shift the driving path), requesting `fields=task_code,name,status,early_start,early_finish,remaining_duration_minutes,total_float_minutes,constraint,constraint_date`. + +2. Define one clean scenario at a time. Never bundle unrelated edits into a single test: + - Duration change or crew acceleration (`set_activity`) + - Logic tie change, overlap or lag adjustment (`relationship`) + - Constraint addition or removal (`set_activity`) + - Progress impact or delayed delivery date (`set_activity`, `update_progress`) + - Resource leveling trade-off (`schedule` with `level_resources`) + +3. Propose the scenario with one `openxer_apply` call in Edit mode. Always include a `schedule` operation at the end of the `changes` batch so the dry-run diff recalculates dates and float across the whole network. If the chat is in Ask mode, explain the exact scenario you would test and let the user switch to Edit mode first. + +4. Read the dry-run diff carefully and report the before and after impact: + - Project scheduled finish before and after, and days gained or lost. + - Key milestones or downstream activities that moved, with Activity IDs and dates. + - Any new critical path, newly negative float, or unintended side effects on other areas. + +5. Remind the user that nothing has been written: they can click Apply to keep the scenario (and undo in one step) or Discard to leave the schedule untouched and test another option. diff --git a/assets/sample-project.txt b/assets/sample-project.txt new file mode 100644 index 0000000..aaea63b --- /dev/null +++ b/assets/sample-project.txt @@ -0,0 +1,470 @@ +# The sample project a new workspace starts on (xer/src/sample_project.rs). +# Everything here is invented: the plant, the people, the vendors, the +# quantities, the rates and the dates. Fields are separated by " | ". +# +# Durations are working days of the activity's calendar: 5 is the 5-day +# 8-hour office calendar, 6 the 6-day 10-hour construction calendar and 7 the +# 7-day 10-hour calendar for concrete curing and the plant outage. +# A duration of "start" or "finish" makes a milestone. +# Predecessors: ID (finish to start), "ID SS2" (start to start, 2 days lag on +# the predecessor's calendar), "ID FF1", "ID FS1". +# Resources: "ID units" where units is the crew size (units per hour) for +# labor and nonlabor resources and the total quantity for materials. No +# value may hold a "|". + +## project +RIVERBEND | Riverbend Process Water Upgrade | 2026-06-01 07:00 + +## holidays +2026-07-03 | 2026-09-07 | 2026-11-26 | 2026-11-27 | 2026-12-24 | 2026-12-25 +2027-01-01 | 2027-05-31 | 2027-07-05 + +## units +CY | Cubic Yard +TON | Ton +BAG | Bag +LF | Linear Foot + +## roles +STAFF | Project Staff +SUPV | Field Supervision +CRAFT | Skilled Craft +LABOR | General Labor + +## accounts +1000 | Project Management and Engineering +2000 | Direct Craft Labor +3000 | Construction Equipment +4000 | Permanent Materials +5000 | Subcontracts and Vendor Services +6000 | Permits, Freight and Other Expenses + +## expense categories +Permits and Fees +Freight +Vendor Services +Testing and Inspection + +## topics +Scope +Basis and Assumptions +Constraints and Access +Safety +Quality and Inspection +Field Notes +Change Notes + +# id | name | type (labor, nonlabor, material) | unit | calendar | rate | limit | role | account +## resources +PM | Project Manager | labor | | 5 | 135 | 1 | STAFF | 1000 +PE | Project Engineer | labor | | 5 | 110 | 2 | STAFF | 1000 +ENGR | Design Engineer | labor | | 5 | 125 | 4 | STAFF | 1000 +BUYER | Buyer and Expeditor | labor | | 5 | 85 | 1 | STAFF | 1000 +SUPT | Construction Superintendent | labor | | 6 | 115 | 1 | SUPV | 2000 +GF | General Foreman | labor | | 6 | 98 | 3 | SUPV | 2000 +FE | Field Engineer | labor | | 6 | 95 | 2 | SUPV | 2000 +QC | Quality Control Inspector | labor | | 6 | 95 | 2 | SUPV | 2000 +LAB | Laborer | labor | | 6 | 58 | 8 | LABOR | 2000 +CARP | Carpenter | labor | | 6 | 72 | 6 | CRAFT | 2000 +IW | Ironworker | labor | | 6 | 82 | 7 | CRAFT | 2000 +PF | Pipefitter | labor | | 6 | 88 | 14 | CRAFT | 2000 +WLD | Pipe Welder | labor | | 6 | 92 | 6 | CRAFT | 2000 +ELEC | Electrician | labor | | 6 | 86 | 10 | CRAFT | 2000 +INST | Instrument Technician | labor | | 6 | 90 | 4 | CRAFT | 2000 +MW | Millwright | labor | | 6 | 85 | 4 | CRAFT | 2000 +PNT | Painter | labor | | 6 | 66 | 3 | CRAFT | 2000 +INSUL | Insulator | labor | | 6 | 70 | 4 | CRAFT | 2000 +OPR | Equipment Operator | labor | | 6 | 80 | 3 | CRAFT | 2000 +CXE | Commissioning Engineer | labor | | 6 | 120 | 2 | STAFF | 1000 +CR90 | Crane, 90 Ton Hydraulic | nonlabor | | 6 | 310 | 1 | | 3000 +CR250 | Crane, 250 Ton Crawler | nonlabor | | 6 | 650 | 1 | | 3000 +LIFT | Manlift, 60 Foot | nonlabor | | 6 | 45 | 5 | | 3000 +WMACH | Welding Machine | nonlabor | | 6 | 18 | 6 | | 3000 +EXC | Excavator | nonlabor | | 6 | 150 | 1 | | 3000 +HYD | Hydrotest Pump and Gauges | nonlabor | | 6 | 35 | 1 | | 3000 +CONC | Ready-Mix Concrete | material | CY | 6 | 185 | | | 4000 +REBAR | Reinforcing Steel | material | TON | 6 | 1450 | | | 4000 +GROUT | Non-Shrink Grout | material | BAG | 6 | 42 | | | 4000 +CABLE | Power Cable, 600 Volt | material | LF | 6 | 9.5 | | | 4000 + +# code | parent | name +## wbs +PM | | Project Management +ENG | | Engineering Deliverables +CS | ENG | Civil and Structural Drawings +ME | ENG | Piping and Mechanical Drawings +EI | ENG | Electrical and Instrument Drawings +PROC | | Procurement +LL | PROC | Long-Lead Equipment +BM | PROC | Bulk Materials +CONST | | Construction +SITE | CONST | Site Preparation and Temporary Facilities +FAB | CONST | Piping Fabrication Shop +A100 | CONST | Area 100 Pump Station +A100.DEMO | A100 | Demolition +A100.CIVIL | A100 | Civil and Structural +A100.EQUIP | A100 | Equipment +A100.PIPE | A100 | Piping +A100.ELEC | A100 | Electrical +A100.INST | A100 | Instrumentation +A100.PAINT | A100 | Paint and Insulation +A200 | CONST | Area 200 Pipe Rack +A200.CIVIL | A200 | Civil and Structural +A200.PIPE | A200 | Piping +A200.ELEC | A200 | Electrical +A200.PAINT | A200 | Paint and Insulation +A300 | CONST | Area 300 Heat Exchanger and Header Tie-ins +A300.DEMO | A300 | Demolition +A300.CIVIL | A300 | Civil and Structural +A300.EQUIP | A300 | Equipment +A300.PIPE | A300 | Piping +A300.TIE | A300 | Header Tie-ins (Plant Outage) +A300.ELEC | A300 | Electrical +A300.INST | A300 | Instrumentation +A300.PAINT | A300 | Paint and Insulation +A400 | CONST | Area 400 Electrical Room +A400.CIVIL | A400 | Civil and Structural +A400.ELEC | A400 | Power Distribution +COMM | | Commissioning and Turnover +MC | COMM | Mechanical Completion +SU | COMM | Commissioning and Startup +TO | COMM | Turnover and Closeout + +# id | wbs | calendar | duration | name | predecessors | resources +## activities +MS0000 | PM | 5 | start | Notice to proceed | | +PM0100 | PM | 5 | 2 | Hold project kickoff meeting with owner and plant operations | MS0000 | PM 1, PE 1, SUPT 1 +PM0110 | PM | 5 | 10 | Submit project schedule and cost breakdown for owner approval | PM0100 | PM 0.5, PE 1 +PM0120 | PM | 5 | 12 | Prepare and submit site safety plan and job hazard analyses | PM0100 | PE 0.5, SUPT 1 +PM0130 | PM | 5 | 25 | Obtain county building and excavation permits | PM0100 | PE 0.5 +PM0140 | PM | 5 | 1 | Hold pre-construction safety meeting with plant operations | PM0120 | PM 1, SUPT 1, GF 1 +EN0100 | CS | 5 | 25 | Design pump foundations, rack footings and equipment pads | PM0100 | ENGR 2, PE 0.5 +EN0110 | CS | 5 | 5 | Review soil report for pump foundation bearing pressure | EN0100 SS5 | ENGR 1 +EN0120 | CS | 5 | 10 | Resolve owner comments on civil and structural drawings | EN0100, EN0110 | ENGR 1 +EN0130 | CS | 5 | finish | Civil and structural drawings issued for construction | EN0120 | +EN0200 | ME | 5 | 35 | Design pump station, pipe rack and heat exchanger piping | PM0100 | ENGR 2, PE 0.5 +EN0210 | ME | 5 | 10 | Resolve owner comments on piping drawings | EN0200 | ENGR 1 +EN0220 | ME | 5 | 8 | Prepare piping isometrics and tie-in package for the outage | EN0210 | ENGR 1.5 +EN0230 | ME | 5 | 5 | Prepare hydrotest packages with test limits and test pressures | EN0220 | ENGR 1, QC 0.5 +EN0240 | ME | 5 | finish | Piping drawings issued for construction | EN0220 | +EN0300 | EI | 5 | 30 | Design one-line diagram, motor control center schedule and cable schedule | PM0100 | ENGR 1.5 +EN0310 | EI | 5 | 25 | Design instrument loop drawings, instrument index and hookups | EN0200 SS15 | ENGR 1 +EN0320 | EI | 5 | 10 | Resolve owner comments on electrical and instrument drawings | EN0300, EN0310 | ENGR 1 +EN0330 | EI | 5 | 5 | Prepare cable pull cards and termination schedules | EN0320 | ENGR 1 +EN0340 | EI | 5 | finish | Electrical and instrument drawings issued for construction | EN0320 | +EN0400 | ENG | 5 | 3 | Issue construction work packages for Area 100 pump station | EN0130, EN0240 | PE 1, FE 1 +EN0410 | ENG | 5 | 3 | Issue construction work packages for Area 200 pipe rack | EN0130, EN0240 | PE 1, FE 1 +EN0420 | ENG | 5 | 3 | Issue construction work packages for Area 300 heat exchanger and tie-ins | EN0240, EN0340 | PE 1, FE 1 +PR0100 | LL | 5 | 8 | Issue purchase order for process water pumps P-101A and P-101B | EN0200 SS5 | BUYER 0.5, ENGR 0.25 +PR0110 | LL | 5 | 20 | Review and approve pump vendor drawings | PR0100 | ENGR 0.5, BUYER 0.25 +PR0120 | LL | 5 | 44 | Pump vendor pours and machines the pump casings | PR0110 | BUYER 0.25 +PR0125 | LL | 5 | 44 | Pump vendor assembles and shop tests pumps P-101A and P-101B | PR0120 | BUYER 0.25, ENGR 0.1 +PR0130 | LL | 5 | 10 | Ship pumps P-101A and P-101B to site | PR0125 | BUYER 0.25 +PR0200 | LL | 5 | 6 | Issue purchase order for transformer TX-401 and motor control center MCC-401 | EN0300 SS10 | BUYER 0.5, ENGR 0.25 +PR0210 | LL | 5 | 25 | Review and approve transformer and motor control center vendor drawings | PR0200 | ENGR 0.5, BUYER 0.25 +PR0220 | LL | 5 | 44 | Vendor winds the core and coil of transformer TX-401 | PR0210 | BUYER 0.25 +PR0225 | LL | 5 | 44 | Vendor assembles transformer TX-401 and builds MCC-401 | PR0220 | BUYER 0.25 +PR0227 | LL | 5 | 15 | Vendor factory tests TX-401 and MCC-401 with the owner witnessing | PR0225 | ENGR 0.25 +PR0230 | LL | 5 | 12 | Ship transformer TX-401 and motor control center MCC-401 to site | PR0227 | BUYER 0.25 +PR0300 | LL | 5 | 6 | Issue purchase order for control valve FV-301 and field instruments | EN0310 SS10 | BUYER 0.5, ENGR 0.25 +PR0310 | LL | 5 | 40 | Vendor builds and ships control valve FV-301 and field instruments | PR0300 | BUYER 0.25 +PR0320 | LL | 5 | finish | Owner delivers heat exchanger E-301 to site (owner furnished) | MS0000 | +PR0400 | BM | 5 | 5 | Issue purchase order for pipe, fittings and valves | EN0220 | BUYER 1 +PR0410 | BM | 5 | 40 | Receive pipe, fittings and valves at the laydown yard | PR0400 | BUYER 0.25 +PR0500 | BM | 5 | 5 | Issue purchase order for pipe rack structural steel | EN0120 | BUYER 1 +PR0505 | BM | 5 | 25 | Steel fabricator prepares pipe rack shop drawings for approval | PR0500 | ENGR 0.25 +PR0510 | BM | 5 | 40 | Steel fabricator builds pipe rack steel | PR0505 | BUYER 0.25 +PR0515 | BM | 5 | 15 | Steel fabricator galvanizes and ships pipe rack steel | PR0510 | BUYER 0.25 +PR0600 | BM | 5 | 18 | Purchase and receive cable, cable tray and conduit | EN0320 | BUYER 0.5 +PR0610 | BM | 5 | 35 | Purchase and receive anchor bolts, embeds and reinforcing steel | EN0120 | BUYER 0.5 +PR0620 | BM | 5 | 15 | Purchase and receive instrument tubing, fittings and supports | EN0320 | BUYER 0.25 +PR0630 | BM | 5 | 20 | Purchase and receive insulation, jacketing and heat tracing | EN0220 | BUYER 0.25 +ST0100 | SITE | 6 | 5 | Mobilize site trailers, laydown yard and temporary power | PM0140, PM0130, PM0110 | SUPT 1, GF 1, LAB 4, OPR 1, ELEC 1 +ST0110 | SITE | 6 | 3 | Install temporary fencing and traffic barricades | ST0100 SS2 | LAB 3 +ST0120 | SITE | 6 | 3 | Locate and mark existing underground utilities in the work areas | ST0100 | FE 1, LAB 2, OPR 1, EXC 1 +ST0130 | SITE | 6 | 4 | Survey and stake new foundations and rack column lines | ST0120, EN0130 | FE 2, LAB 1 +ST0140 | SITE | 6 | finish | Construction mobilization complete | ST0110, ST0130 | +PP0100 | FAB | 6 | 15 | Fabricate pump station piping spools at the fab shop | PR0410, EN0400 | GF 1, PF 3, WLD 2, WMACH 2 +PP0110 | FAB | 6 | 20 | Fabricate pipe rack header spools at the fab shop | PP0100 SS5, EN0410 | PF 3, WLD 2, WMACH 2 +PP0120 | FAB | 6 | 15 | Fabricate heat exchanger and tie-in spools at the fab shop | PP0110, EN0420 | PF 3, WLD 2, WMACH 2 +PP0130 | FAB | 6 | 4 | Radiograph shop spool welds (random 10 percent) | PP0120 | QC 1 +DM0900 | A100.DEMO | 6 | start | Plant operations releases existing pumps P-1 and P-2 for demolition | ST0140 | +DM1000 | A100.DEMO | 6 | 2 | Lock out, drain and isolate existing pumps P-1 and P-2 | DM0900, EN0400 | GF 1, PF 2, ELEC 1 +DM1010 | A100.DEMO | 6 | 3 | Disconnect and remove existing pump motor cables and conduit | DM1000 | ELEC 3 +DM1020 | A100.DEMO | 6 | 4 | Cut out and remove existing pump suction and discharge piping | DM1000 | PF 3, WLD 1, WMACH 1, LIFT 1 +DM1030 | A100.DEMO | 6 | 3 | Rig out existing pumps P-1 and P-2 and their motors | DM1010, DM1020 | MW 2, LAB 2, OPR 1, CR90 1 +DM1040 | A100.DEMO | 6 | 4 | Break out and haul away the old pump bases | DM1030 | LAB 4, OPR 1, EXC 1 +CV1000 | A100.CIVIL | 6 | 4 | Excavate for new pump foundations | DM1040, ST0130 | OPR 1, LAB 3, EXC 1 +CV1010 | A100.CIVIL | 6 | 8 | Form, set anchor bolts and tie reinforcing steel for pump foundations | CV1000, PR0610 | CARP 4, IW 2, LAB 2, REBAR 6 +CV1020 | A100.CIVIL | 6 | 1 | Place concrete for pump foundations | CV1010 | GF 1, LAB 4, CARP 2, OPR 1, CONC 48 +CV1030 | A100.CIVIL | 7 | 7 | Cure concrete at pump foundations | CV1020 | LAB 1 +CV1040 | A100.CIVIL | 6 | 3 | Strip forms and backfill around pump foundations | CV1030 | CARP 2, LAB 3, OPR 1 +CV1050 | A100.CIVIL | 6 | 5 | Install pump station access platform, stairs and handrail | EQ1011 | IW 3, LIFT 1 +EQ1000 | A100.EQUIP | 6 | 2 | Receive and inspect pumps P-101A and P-101B | PR0130 | MW 2, OPR 1 +EQ1010 | A100.EQUIP | 6 | 1 | Set pump P-101A on its foundation | EQ1000, CV1040 | MW 3, IW 1, OPR 1, CR90 1 +EQ1011 | A100.EQUIP | 6 | 1 | Set pump P-101B on its foundation | EQ1010 | MW 3, IW 1, OPR 1, CR90 1 +EQ1020 | A100.EQUIP | 6 | 2 | Level and rough align pump P-101A | EQ1010 | MW 2 +EQ1021 | A100.EQUIP | 6 | 2 | Level and rough align pump P-101B | EQ1011, EQ1020 | MW 2 +EQ1030 | A100.EQUIP | 6 | 1 | Grout baseplates of pumps P-101A and P-101B | EQ1021 | LAB 2, MW 1, GROUT 40 +EQ1040 | A100.EQUIP | 7 | 3 | Cure baseplate grout at pumps P-101A and P-101B | EQ1030 | LAB 0.5 +EQ1050 | A100.EQUIP | 6 | 2 | Final align pump P-101A to its motor after piping is connected | PP1040 | MW 2 +EQ1051 | A100.EQUIP | 6 | 2 | Final align pump P-101B to its motor after piping is connected | EQ1050 | MW 2 +PP1000 | A100.PIPE | 6 | 8 | Erect suction and discharge piping at pump P-101A | EQ1040, PP0100, DM1020 | PF 4, WLD 2, WMACH 2, LIFT 1 +PP1001 | A100.PIPE | 6 | 8 | Erect suction and discharge piping at pump P-101B | PP1000 SS2 | PF 4, WLD 2, WMACH 2, LIFT 1 +PP1010 | A100.PIPE | 6 | 4 | Install pipe supports and guides at the pump station | PP1000 SS2 | PF 2 +PP1020 | A100.PIPE | 6 | 2 | Radiograph pump station field welds | PP1001 | QC 1 +PP1030 | A100.PIPE | 6 | 2 | Hydrotest pump station piping | PP1020, PP1010, EN0230 | PF 3, QC 1, HYD 1 +PP1040 | A100.PIPE | 6 | 2 | Bolt up suction and discharge flanges to pumps P-101A and P-101B | PP1030 | PF 2, MW 1 +PP1050 | A100.PIPE | 6 | 1 | Install temporary flushing screens in pump suction strainers | PP1040 | PF 2 +EL1000 | A100.ELEC | 6 | 5 | Install conduit and cable supports at the pump station | DM1010, EQ1011, EN0340 | ELEC 3, LIFT 1 +EL1010 | A100.ELEC | 6 | 6 | Pull 480-volt power cables from MCC-401 to pump motors | EL1000, EL4020, PR0600 | ELEC 4, CABLE 1800 +EL1020 | A100.ELEC | 6 | 3 | Terminate and megger pump motor power cables at the motors and MCC-401 | EL1010, EQ1011 | ELEC 2 +EL1030 | A100.ELEC | 6 | 2 | Install local control stations and motor grounding at pumps P-101A and P-101B | EL1000, EQ1011 | ELEC 2 +EL1040 | A100.ELEC | 6 | 3 | Install pump station lighting and receptacles | CV1050 | ELEC 2, LIFT 1 +IN1000 | A100.INST | 6 | 2 | Install pressure transmitters PT-101A and PT-101B and pressure gauges | PP1001, PR0310 | INST 2 +IN1010 | A100.INST | 6 | 3 | Run instrument cable from the pump station transmitters to junction box JB-101 | IN1000, EL1000 | INST 2, ELEC 1 +IN1020 | A100.INST | 6 | 2 | Terminate instrument cables at the transmitters and junction box JB-101 | IN1010 | INST 2 +PI1000 | A100.PAINT | 6 | 3 | Field paint pump station piping welds and supports | PP1040 | PNT 2, LIFT 1 +CV2000 | A200.CIVIL | 6 | 5 | Excavate for pipe rack spread footings, bents 1 to 6 | ST0130, EN0410, CV3020 | OPR 1, LAB 3, EXC 1 +CV2010 | A200.CIVIL | 6 | 10 | Form, set anchor bolts and tie reinforcing steel for rack footings | CV2000, PR0610 | CARP 4, IW 2, LAB 2, REBAR 9 +CV2020 | A200.CIVIL | 6 | 2 | Place concrete for rack footings | CV2010 | GF 1, LAB 4, CARP 2, OPR 1, CONC 72 +CV2030 | A200.CIVIL | 7 | 7 | Cure concrete at rack footings | CV2020 | LAB 1 +CV2040 | A200.CIVIL | 6 | 4 | Strip forms and backfill rack footings | CV2030 | CARP 2, LAB 3, OPR 1 +CV2100 | A200.CIVIL | 6 | 3 | Receive and shake out pipe rack steel at the laydown yard | PR0515 | IW 2, LAB 2, OPR 1 +CV2110 | A200.CIVIL | 6 | 10 | Erect pipe rack columns and beams, bents 1 to 6 | CV2040, CV2100 | GF 1, IW 5, LAB 1, OPR 1, CR90 1 +CV2120 | A200.CIVIL | 6 | 4 | Plumb, bolt up and torque pipe rack steel | CV2110 | IW 3, LIFT 1 +CV2130 | A200.CIVIL | 6 | 2 | Grout pipe rack column base plates | CV2120 | LAB 2, IW 1, GROUT 30 +CV2140 | A200.CIVIL | 6 | 4 | Install pipe rack ladders, platforms and handrail | PP2000 | IW 3, LIFT 1 +ST0200 | A200.CIVIL | 6 | 3 | Erect scaffolding at pipe rack bents 1 to 6 | CV2120 | LAB 4, GF 1 +PP2000 | A200.PIPE | 6 | 20 | Erect 10-inch process water header on the pipe rack | ST0200, PP0110, CV2130 | GF 1, PF 6, WLD 3, WMACH 3, LIFT 2, CR90 1 +PP2010 | A200.PIPE | 6 | 6 | Install pipe shoes, guides and anchors on the pipe rack | PP2000 SS4 | PF 2, IW 1 +PP2020 | A200.PIPE | 6 | 3 | Install high point vents, low point drains and expansion loop | PP2000 | PF 2, WLD 1, WMACH 1 +PP2030 | A200.PIPE | 6 | 3 | Radiograph pipe rack field welds | PP2000, PP2020 | QC 1 +PP2040 | A200.PIPE | 6 | 3 | Hydrotest pipe rack header | PP2030, PP2010, EN0230 | PF 3, QC 1, HYD 1 +ST0210 | A200.PIPE | 6 | 2 | Dismantle scaffolding at pipe rack bents 1 to 6 | EL2020 | LAB 4 +EL2000 | A200.ELEC | 6 | 10 | Install cable tray on the pipe rack | PP2000 SS5, PR0600 | ELEC 4, LIFT 2 +EL2010 | A200.ELEC | 6 | 5 | Install heat tracing cable on the pipe rack header | PP2040, PR0630 | ELEC 2, LIFT 1 +EL2020 | A200.ELEC | 6 | 2 | Terminate heat tracing and test it after insulation | PI2010, EL4070 | ELEC 2 +EL2030 | A200.ELEC | 6 | 4 | Install pipe rack lighting | EL2000, CV2140 | ELEC 2, LIFT 1 +PI2000 | A200.PAINT | 6 | 4 | Field paint pipe rack field welds and touch up damaged primer | PP2040 | PNT 2, LIFT 1 +PI2010 | A200.PAINT | 6 | 10 | Insulate and jacket the pipe rack header for freeze protection | EL2010, PI2000 | INSUL 4, LIFT 2 +DM3000 | A300.DEMO | 6 | 3 | Remove abandoned strainer and piping at the heat exchanger pad area | ST0120, EN0420 | PF 2, LAB 2, WMACH 1 +CV3000 | A300.CIVIL | 6 | 3 | Excavate for the heat exchanger pad | DM3000, ST0130, CV4010 | OPR 1, LAB 2, EXC 1 +CV3010 | A300.CIVIL | 6 | 5 | Form, set anchor bolts and tie reinforcing steel for the heat exchanger pad | CV3000, PR0610 | CARP 3, IW 2, LAB 2, REBAR 4 +CV3020 | A300.CIVIL | 6 | 1 | Place concrete for the heat exchanger pad | CV3010 | GF 1, LAB 4, CARP 2, OPR 1, CONC 36 +CV3030 | A300.CIVIL | 7 | 7 | Cure concrete at the heat exchanger pad | CV3020 | LAB 1 +CV3040 | A300.CIVIL | 6 | 2 | Strip forms and backfill the heat exchanger pad | CV3030 | CARP 2, LAB 2, OPR 1 +EQ3000 | A300.EQUIP | 6 | 2 | Receive and inspect owner furnished heat exchanger E-301 | PR0320 | MW 2, OPR 1, QC 0.5 +EQ3010 | A300.EQUIP | 6 | 1 | Set heat exchanger E-301 on its pad with the 250-ton crane | EQ3000, CV3040 | GF 1, IW 3, MW 2, OPR 2, CR250 1 +EQ3020 | A300.EQUIP | 6 | 2 | Level, anchor and grout the heat exchanger E-301 frame | EQ3010 | MW 2, LAB 1, GROUT 12 +PP3000 | A300.PIPE | 6 | 10 | Erect heat exchanger inlet and outlet piping to the pipe rack | EQ3020, PP2000, PP0130 | PF 4, WLD 2, WMACH 2, LIFT 1 +PP3010 | A300.PIPE | 6 | 3 | Install control valve FV-301 and its block and bypass valves | PP3000, PR0310 | PF 3 +PP3020 | A300.PIPE | 6 | 3 | Install pipe supports for the heat exchanger piping | PP3000 SS2 | PF 2 +PP3030 | A300.PIPE | 6 | 2 | Radiograph heat exchanger piping field welds | PP3000 | QC 1 +PP3040 | A300.PIPE | 6 | 2 | Hydrotest heat exchanger piping | PP3030, PP3010, PP3020, EN0230 | PF 3, QC 1, HYD 1 +PP3100 | A300.TIE | 7 | start | Plant outage starts: existing cooling water headers drained and isolated by owner | PP3040, PP2040 | +PP3110 | A300.TIE | 7 | 1 | Tie-in TI-01: cut out existing 10-inch supply header spool | PP3100 | GF 1, PF 3, WLD 1, WMACH 1 +PP3120 | A300.TIE | 7 | 2 | Tie-in TI-01: fit up and weld new 10-inch tee on the supply header | PP3110 | PF 3, WLD 2, WMACH 2 +PP3130 | A300.TIE | 7 | 1 | Tie-in TI-01: radiograph new supply header welds | PP3120 | QC 1 +PP3210 | A300.TIE | 7 | 1 | Tie-in TI-02: cut out existing 10-inch return header spool | PP3110 | PF 3, WLD 1, WMACH 1 +PP3220 | A300.TIE | 7 | 2 | Tie-in TI-02: fit up and weld new 10-inch tee on the return header | PP3210, PP3120 | PF 3, WLD 2, WMACH 2 +PP3230 | A300.TIE | 7 | 1 | Tie-in TI-02: radiograph new return header welds | PP3220 | QC 1 +PP3310 | A300.TIE | 7 | 1 | Tie-in TI-03: remove blind flange on existing 4-inch header drain | PP3100 | PF 2 +PP3320 | A300.TIE | 7 | 1 | Tie-in TI-03: bolt up new 4-inch drain connection with new gaskets | PP3310 | PF 2 +PP3400 | A300.TIE | 7 | 1 | Leak test tie-ins TI-01, TI-02 and TI-03 at operating pressure with owner operations | PP3130, PP3230, PP3320 | PF 2, QC 1 +PP3410 | A300.TIE | 7 | finish | Plant outage ends: existing headers returned to service | PP3400 | +EL3000 | A300.ELEC | 6 | 5 | Install conduit and cable tray for Area 300 instruments | EL2000, EQ3020 | ELEC 3, LIFT 1 +IN3000 | A300.INST | 6 | 3 | Install flow transmitter FT-301 and temperature transmitters TT-301 and TT-302 | PP3040, PR0310 | INST 2 +IN3010 | A300.INST | 6 | 3 | Run instrument air tubing to control valve FV-301 from the existing air header | PP3010, PR0620 | INST 2 +IN3020 | A300.INST | 6 | 2 | Install pressure gauges at the heat exchanger inlet and outlet | PP3040 | INST 1 +IN3030 | A300.INST | 6 | 4 | Pull instrument cables from Area 300 instruments to junction box JB-301 | IN3000, EL3000 | INST 2, ELEC 1 +IN3040 | A300.INST | 6 | 2 | Terminate instrument cables at the instruments and junction box JB-301 | IN3030 | INST 2 +IN3050 | A300.INST | 6 | 4 | Pull home-run cables from JB-101 and JB-301 to the control room marshalling cabinet | IN1020, IN3040 | ELEC 2, INST 1 +IN3060 | A300.INST | 6 | 2 | Terminate home-run cables at the control room marshalling cabinet | IN3050 | INST 2 +PI3000 | A300.PAINT | 6 | 3 | Field paint heat exchanger piping welds and supports | PP3040 | PNT 2 +PI3010 | A300.PAINT | 6 | 2 | Field paint tie-in welds at TI-01 and TI-02 | PP3410 | PNT 2 +CV4000 | A400.CIVIL | 6 | 3 | Form and tie reinforcing steel for the transformer pad and oil containment curb | ST0130, PR0610 | CARP 3, IW 1, LAB 2, REBAR 2 +CV4010 | A400.CIVIL | 6 | 1 | Place concrete for the transformer pad and oil containment curb | CV4000, EL4000 | LAB 3, CARP 2, CONC 18 +CV4020 | A400.CIVIL | 7 | 7 | Cure concrete at the transformer pad | CV4010 | LAB 0.5 +CV4030 | A400.CIVIL | 6 | 2 | Install transformer bollards and gravel surfacing | CV4020 | LAB 2, OPR 1 +EL4000 | A400.ELEC | 6 | 3 | Install ground grid and ground rods at the transformer pad | ST0130 | ELEC 2, LAB 1 +EL4010 | A400.ELEC | 6 | 2 | Set transformer TX-401 on its pad | PR0230, CV4020 | ELEC 2, IW 1, OPR 1, CR90 1 +EL4020 | A400.ELEC | 6 | 2 | Set motor control center MCC-401 in the electrical room | PR0230 | ELEC 3, OPR 1 +EL4030 | A400.ELEC | 6 | 6 | Pull and terminate the 4160-volt feeder from existing switchgear to TX-401 | EL4010, PR0600, EN0330 | ELEC 4 +EL4040 | A400.ELEC | 6 | 3 | Install and terminate the 480-volt feeder from TX-401 to MCC-401 | EL4010, EL4020 | ELEC 3 +EL4050 | A400.ELEC | 6 | 2 | Test transformer TX-401: insulation resistance, turns ratio and oil sample | EL4030, EL4040 | ELEC 2 +EL4060 | A400.ELEC | 6 | 2 | Megger and test motor control center MCC-401 starters and breakers | EL4040 | ELEC 2 +EL4070 | A400.ELEC | 6 | 1 | Energize transformer TX-401 and MCC-401 with owner switching | EL4050, EL4060 | ELEC 2, SUPT 1 +EL4080 | A400.ELEC | 6 | 3 | Install electrical room lighting and receptacles | EL4020 | ELEC 2 +EL4090 | A400.ELEC | 6 | 1 | Install arc flash and equipment labels at TX-401 and MCC-401 | EL4070 | ELEC 1 +CM9000 | MC | 6 | 2 | Walk down Area 100 pump station for mechanical completion | PP1050, EL1020, EL1030, EL1040, IN1020, PI1000, EQ1051, CV1050 | GF 1, FE 1, QC 1 +CM9010 | MC | 6 | 2 | Walk down Area 200 pipe rack for mechanical completion | ST0210, EL2020, EL2030, CV2140 | GF 1, FE 1, QC 1 +CM9020 | MC | 6 | 2 | Walk down Area 300 heat exchanger and tie-ins for mechanical completion | PI3000, PI3010, IN3040, IN3020, IN3010 | GF 1, FE 1, QC 1 +CM9030 | MC | 6 | 1 | Walk down Area 400 electrical room for mechanical completion | EL4090, EL4080, CV4030 | GF 1, FE 1, QC 1 +CM9040 | MC | 6 | 6 | Clear punch list items from the mechanical completion walkdowns | CM9000, CM9010, CM9020, CM9030 | GF 1, PF 2, ELEC 2, LAB 2 +CM9050 | MC | 6 | finish | Mechanical completion: contract milestone | CM9040, IN3060 | +CM9100 | SU | 6 | 3 | Flush new process water piping to clean water | CM9050 | PF 3, LAB 2, CXE 0.5 +CM9110 | SU | 6 | 1 | Remove temporary flushing screens and reinstate piping | CM9100 | PF 2 +CM9120 | SU | 6 | 4 | Calibrate transmitters and stroke control valve FV-301 | IN1020, IN3040, IN3010 | INST 2 +CM9130 | SU | 6 | 4 | Loop check instruments from the field to the control room | CM9120, IN3060, EL4070 | INST 2, CXE 1 +CM9140 | SU | 6 | 2 | Bump motors and check rotation of pumps P-101A and P-101B | EL4070, EL1020, EQ1051 | ELEC 2, MW 1, CXE 1 +CM9150 | SU | 6 | 3 | Run pumps P-101A and P-101B on water and check vibration | CM9140, CM9110 | MW 2, PF 1, CXE 1 +CM9160 | SU | 6 | 3 | Performance test heat exchanger E-301 with owner operations | CM9150, CM9130 | CXE 1, INST 1 +CM9170 | SU | 6 | 2 | Train owner operators on the new pumps, heat exchanger and controls | CM9160 SS1 | CXE 1, SUPT 0.5 +CM9180 | SU | 6 | finish | Startup complete: system in operation | CM9160, CM9170 | +CM9190 | SU | 7 | 30 | Run the new system through the 30-day reliability period with owner operations | CM9180 | CXE 0.2 +CM9200 | TO | 6 | 5 | Assemble turnover packages: test records, radiograph reports and loop sheets | CM9050 | QC 1, FE 1 +CM9210 | TO | 6 | 5 | Submit operating and maintenance manuals and spare parts lists | CM9050 | PE 1 +CM9220 | TO | 6 | 2 | Owner acceptance walkdown and signed turnover certificates | CM9200, CM9190, CM9210 | PM 1, SUPT 1, QC 1 +PM0900 | PM | 6 | 5 | Demobilize site trailers, equipment and temporary power | CM9180 | SUPT 0.5, LAB 4, OPR 1, ELEC 1 +PM0910 | PM | 6 | 8 | Submit as-built drawings and closeout documents | CM9220 | PE 1, ENGR 0.5 +PM0920 | PM | 6 | finish | Project complete | PM0900, PM0910 | + +# Constraints: "plan" puts the date where the unconstrained plan finishes. +## constraints +PR0320 | finish on or after | 2027-01-08 15:30 +DM0900 | start on or after | 2026-11-23 06:00 +PP3100 | start on or after | 2027-02-13 06:00 +CM9050 | finish on or before | plan + +## codes +Area | 100 | Area 100 Pump Station +Area | 200 | Area 200 Pipe Rack +Area | 300 | Area 300 Heat Exchanger and Tie-ins +Area | 400 | Area 400 Electrical Room +Area | GEN | General, all areas +Discipline | PM | Project Management +Discipline | ENG | Engineering +Discipline | PRC | Procurement +Discipline | DEM | Demolition +Discipline | CIV | Civil and Structural +Discipline | EQP | Equipment +Discipline | PIP | Piping +Discipline | ELE | Electrical +Discipline | INS | Instrumentation +Discipline | PNT | Paint and Insulation +Discipline | COM | Commissioning +Phase | 1-ENG | Engineering +Phase | 2-PROC | Procurement +Phase | 3-CONST | Construction +Phase | 4-COMM | Commissioning and Turnover +Responsibility | GC | General Contractor +Responsibility | MECH | Mechanical Subcontractor +Responsibility | ELEC | Electrical Subcontractor +Responsibility | VEND | Vendor +Responsibility | OWN | Owner + +# label | data type +## udfs +Work Package | text +Drawing Number | text +Permit Required | text +Crew Size | number + +# activity | label | value +## udf values +DM1000 | Permit Required | Hot work and lockout permit +DM1020 | Permit Required | Hot work permit +DM1040 | Permit Required | Excavation permit +CV1000 | Permit Required | Excavation permit +CV2000 | Permit Required | Excavation permit +CV3000 | Permit Required | Excavation permit +PP3110 | Permit Required | Hot work and line break permit +PP3210 | Permit Required | Hot work and line break permit +PP3310 | Permit Required | Line break permit +EL4070 | Permit Required | Energized work permit +CV1010 | Drawing Number | RB-S-101 +CV2010 | Drawing Number | RB-S-201 +CV3010 | Drawing Number | RB-S-301 +PP1000 | Drawing Number | RB-P-110 +PP1001 | Drawing Number | RB-P-111 +PP2000 | Drawing Number | RB-P-201 +PP3000 | Drawing Number | RB-P-301 +PP3120 | Drawing Number | RB-P-351 +PP3220 | Drawing Number | RB-P-352 +EL1010 | Drawing Number | RB-E-110 +EL4030 | Drawing Number | RB-E-401 + +# activity | step | weight +## steps +EQ1010 | Rig and lift pump onto foundation | 30 +EQ1010 | Set on shims and anchor bolts | 40 +EQ1010 | Check elevation and centerline | 30 +PP2000 | Lift spools onto the rack | 30 +PP2000 | Fit up joints | 30 +PP2000 | Weld joints | 40 +EL1010 | Set up pulling equipment and reels | 15 +EL1010 | Pull cables to motor P-101A | 40 +EL1010 | Pull cables to motor P-101B | 40 +EL1010 | Tag and seal cable ends | 5 +CV2110 | Set columns on anchor bolts | 50 +CV2110 | Set beams and struts | 50 +PP3040 | Fill and vent the piping | 20 +PP3040 | Hold test pressure and inspect joints | 60 +PP3040 | Drain and record the test | 20 + +# activity | category | account | name | vendor | cost +## expenses +PM0130 | Permits and Fees | 6000 | County building and excavation permits | County Building Department | 18500 +PR0130 | Freight | 6000 | Freight for pumps P-101A and P-101B | Valley Freight Lines | 6800 +PR0230 | Freight | 6000 | Heavy haul for transformer TX-401 and MCC-401 | Valley Freight Lines | 14200 +EQ3010 | Vendor Services | 5000 | 250-ton crane mobilization and demobilization | Northgate Crane Rental | 12000 +PP0130 | Testing and Inspection | 5000 | Radiography of shop spool welds | Summit Inspection Services | 4200 +PP1020 | Testing and Inspection | 5000 | Radiography of pump station field welds | Summit Inspection Services | 3100 +PP2030 | Testing and Inspection | 5000 | Radiography of pipe rack field welds | Summit Inspection Services | 4600 +PP3030 | Testing and Inspection | 5000 | Radiography of heat exchanger piping welds | Summit Inspection Services | 2900 +PP3130 | Testing and Inspection | 5000 | Radiography of tie-in TI-01 welds (outage call-out) | Summit Inspection Services | 2400 +PP3230 | Testing and Inspection | 5000 | Radiography of tie-in TI-02 welds (outage call-out) | Summit Inspection Services | 2400 +EL4050 | Testing and Inspection | 5000 | Transformer oil sample and electrical testing | Keystone Electrical Testing | 4800 +CM9150 | Vendor Services | 5000 | Pump vendor startup technician, 3 days | Pump vendor field service | 7200 + +# activity | resource | curve +## curves +PR0120 | BUYER | Bell, Centered +PR0220 | BUYER | Bell, Centered +PP2000 | PF | Steady with Ramps +EN0200 | ENGR | Early Weighted +CM9040 | PF | Ramp Down + +# target (PROJECT, a WBS code or an activity) | topic | text +## notes +PROJECT | Scope | Replace the two worn process water pumps in the existing pump house with new pumps P-101A and P-101B, run a new 10-inch header across a new six-bent pipe rack to the owner furnished plate heat exchanger E-301, and tie the new system into the existing cooling water supply and return headers during the February plant outage. A new 1500 kVA transformer and motor control center feed the pumps. +PROJECT | Basis and Assumptions | Crews work a 6-day, 10-hour week. Office, engineering and procurement work a 5-day, 8-hour week. Concrete cures and the outage tie-ins run 7 days a week. Rates include burden and small tools. The pumps are lump sum from the pump vendor; installation is ours. +PROJECT | Constraints and Access | The plant outage window is fixed by operations: headers are drained and isolated on Saturday 13 February. All header work must finish inside the outage. Mechanical completion is a contract date. +PROJECT | Safety | Lockout and line break permits from plant operations are required before any work on the existing pumps and headers. Daily job hazard analysis at the 6 AM toolbox talk. +PROJECT | Quality and Inspection | Field welds are radiographed by a third party. Tie-in welds are radiographed 100 percent. Hydrotests are witnessed by the owner inspector. +PROJECT | Change Notes | Change 001 (approved): add freeze protection heat tracing and insulation on the pipe rack header, added after the owner's winter review. +A100 | Scope | Demolish the old pumps P-1 and P-2, their bases, piping and power cables, then build new foundations and install pumps P-101A and P-101B with their piping, power, controls and instruments. +A100.DEMO | Safety | Old pump bases contain asbestos-free grout per the owner's survey dated 12 May. Old motors go to the owner's scrap yard, not off site. +A200 | Constraints and Access | Bents 3 and 4 sit beside the plant road. Crane picks over the road need a flagger and the road closed for the lift. +A300.TIE | Constraints and Access | Tie-ins TI-01 and TI-02 are welded tees on live headers after isolation; TI-03 is a flanged drain connection. Each welded tie-in is radiographed before the leak test. +A300.TIE | Quality and Inspection | Prefabricate the tie-in tees and pre-bevel the spools before the outage. Keep spare gaskets and a second welding machine on hand. +A400 | Safety | Energizing TX-401 is done only under owner switching orders. Arc flash labels go up before the room is turned over. +COMM | Basis and Assumptions | Owner operations runs the control system. Our scope ends at the marshalling cabinet terminals; the owner configures the control system. +MS0000 | Field Notes | Notice to proceed received by email from the owner's project manager. +PR0120 | Field Notes | Pump vendor reports castings poured on schedule. Shop test witness trip booked. +PR0220 | Change Notes | Vendor offered an earlier ship date for a premium; declined, the standard date holds the plan. +PR0320 | Constraints and Access | The owner purchased E-301 directly. Delivery is the owner's; we receive, set and connect it. +DM1020 | Safety | Pipe may hold residual water and scale. Drain at low points before cutting. Hot work permit each shift. +CV1020 | Quality and Inspection | Slump and cylinders taken by the testing lab. Pour only above 40 degrees F with blankets on hand. +CV2110 | Field Notes | Bents 1 and 2 set on the first day; anchor bolt at bent 4 west column was out of tolerance and was corrected by the engineer's sketch SK-07. +EQ3010 | Safety | Critical lift plan required for the 250-ton crane. Lift plan reviewed by the rigging engineer. +PP2000 | Field Notes | Header spools arriving from the fab shop in rack order. Two welders on the rack, one at the fab shop. +PP2000 | Quality and Inspection | Weld map kept in the field office; welder stencil on every weld. +PP3120 | Quality and Inspection | Hold point: owner inspector to witness fit up before welding. +PP3400 | Constraints and Access | Owner operations opens the header block valves slowly; we stand by with two fitters until the leak test is accepted. +EL4070 | Safety | Energized work permit and switching order required. Only qualified electricians in the room. +CM9050 | Change Notes | Contract date unchanged after change 001; the heat tracing work fits inside the plan. +CM9150 | Field Notes | Pump vendor startup technician booked for three days. + +# Progress at the data date. A slip adds working days to an activity's +# remaining duration; an overrun scales its actual units. +## progress +data date | 2026-10-12 00:00 +slip | PR0125 | 3 +overrun | EN0200 | 1.08 +overrun | PR0110 | 1.10 +overrun | ST0100 | 1.15 +overrun | DM3000 | 1.20 +overrun | CV3010 | 1.12 +overrun | CV2010 | 1.10 diff --git a/assets/skills/activity-definition-review.md b/assets/skills/activity-definition-review.md new file mode 100644 index 0000000..1e16341 --- /dev/null +++ b/assets/skills/activity-definition-review.md @@ -0,0 +1,69 @@ +--- +id: activity-definition-review +name: Activity definition review +description: Are activities single-scope, single-crew, measurable, sized for the update cycle, and named so a crew understands them? +request: Review how the activities are defined. +use_when: The user asks whether activities are well defined, too big or too small, named clearly, measurable, or fit for statusing by the field. +kind: check +order: 140 +examples: +- Are these activities any good? +- Can the foremen status these activities? +- Which activities are too big? +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_load +--- +# Activity definition review + +You check that each activity is one piece of work, by one crew or +responsible party, with a clear finish, small enough to status, and named +so a foreman knows what it is. You only read. + +## Ground rules + +- Every count and duration comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several), and ask + the update cycle (weekly or monthly) in working days. +2. Run `openxer_schedule_stats` with `update_period_days`. Take + `durations` (spread, longest, zero-duration tasks, + `longer_than_two_update_periods`), `names` (repeated, one-word), + `open_work_without_resources_or_expenses`. +3. Run `openxer_load` (page through with offset when there are many) to + read the names of the activities, then judge each kind of problem with + examples by Activity ID: + - **Too big**: longer than two update periods; hard to status, hides + sequence. Suggest how to split (by area, by step). + - **Too vague**: names like "Piping", "Misc work", "Electrical"; one-word + names; repeated names without the area that tells them apart. + - **Mixed scope**: names joining different work or different crews + ("Install and test", "Civil and mechanical"). + - **No clear finish**: names without an end point ("Support + construction"). An activity needs a way to say it is done. + - **Responsibility**: when the job uses codes or resources for who does + it, work with none. +4. Rank by consequence: big or vague activities on the critical path first, + then the rest by size. + +## Ask + +One question at a time: the update cycle, how the field statuses +(remaining days or percent). + +## Do not + +Do not rename or split anything. Offer the "Change interview" skill for +changes the user wants. + +## Answer + +- Two lines: the share of activities with a problem (from the counts) and + the worst kind. +- One section per kind of problem: count, examples with ID and name, and + the suggested fix in field words. diff --git a/assets/skills/add-scope.md b/assets/skills/add-scope.md new file mode 100644 index 0000000..ac22104 --- /dev/null +++ b/assets/skills/add-scope.md @@ -0,0 +1,73 @@ +--- +id: add-scope +name: Add a fragment of work +description: Adds a change order or added scope as a small set of activities and ties it into the existing logic on a new file. +request: Add this change order's work to the schedule. +use_when: The user wants to add a change order, extra scope or a new piece of work to an existing schedule and tie it in. +kind: workflow +order: 240 +examples: +- Add the new pipe rack to the schedule +- Put change order 12 into the schedule +- We picked up extra paving, add it +tools: +- openxer_load +- openxer_paths +- openxer_milestones +- openxer_apply +- openxer_schedule +- openxer_compare +- openxer_check_schedule +--- +# Add a fragment of work + +You add new work as a small set of activities (a fragment), tie it into the +existing logic where it really connects, and show the effect on a new file. + +## Ground rules + +- Every date and move comes from a tool result. Never estimate the effect. +- Plain words; activity names a crew understands. Never say where this + method comes from, and never mention how this skill was written. +- Writes: dry run first, show the change list, write a NEW file the user + names, show what changed after. The user's file is never overwritten. + +## Steps + +1. Settle the file, the project and a NEW output path. +2. Define the fragment with the user, one question at a time: the + activities (demolition before installation in each discipline), their + durations and calendar, which WBS element they belong to (or a new one), + and the reference for the change (change order number) for the names + or a notebook. +3. Tie it in. Read the neighbours first with `openxer_load` (the activities + it touches). For each fragment activity, agree: + - what in the existing schedule must happen before it (access, a + foundation, a shutdown); + - what in the existing schedule waits for it. + Every fragment activity gets a predecessor and a successor. A fragment + with no successor into the existing work cannot move anything: say so. +4. One `openxer_apply` batch: `add_wbs` if needed, `add_activity`, + `set_activity` (`original_duration`, `calendar`), `relationship` adds + with `comments` naming the change, optionally `set_notebook` with the + change reference, and `{"op":"schedule"}` at the end. Dry run, show the + list, then write to the new output. +5. Measure: `openxer_compare` the new file against the old; `openxer_paths` + on the new file to see whether the fragment is now on the critical + path; `openxer_check_schedule` for open ends you may have left. + +## Ask + +One question at a time: activities, durations, ties, the change reference. + +## Do not + +Do not tie to activities just to close an open end; tie only where the work +really depends. Do not change existing durations or ties unless asked. + +## Answer + +- The file written and the activities added. +- The finish and milestones before and after, from the comparison. +- Whether the new work is on the critical path. +- Anything left open. diff --git a/assets/skills/baseline-review.md b/assets/skills/baseline-review.md new file mode 100644 index 0000000..c06d292 --- /dev/null +++ b/assets/skills/baseline-review.md @@ -0,0 +1,76 @@ +--- +id: baseline-review +name: Baseline schedule review +description: Before a first baseline is accepted: complete scope, sound logic, contract dates in the structure, a believable critical path. +request: Review this baseline schedule before we accept it. +use_when: The user is about to accept, approve or submit a first baseline schedule, or asks whether a baseline is fit to be accepted. +kind: check +order: 160 +examples: +- Is this baseline ready to approve? +- Review the contractor's baseline submittal +- Would you accept this baseline? +tools: +- openxer_inspect +- openxer_check_schedule +- openxer_paths +- openxer_milestones +- openxer_schedule_stats +- openxer_wbs_summary +- openxer_resource_loading +--- +# Baseline schedule review + +A baseline becomes the yardstick for every update after it, so it is held +to a stricter standard than an update. You check that it is complete, +logical, built around the contract's dates, and has a critical path a +superintendent would believe. You only read. + +## Ground rules + +- Every count, date and float comes from a tool result. Never work one out. +- Plain words. Never say where this review method comes from, and never + mention how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). Ask for + the contract milestones and finish date, and what the contract asks the + schedule to show (resources, costs, a level of detail), one question at + a time. +2. Gather: `openxer_check_schedule`, `openxer_paths`, `openxer_milestones`, + `openxer_schedule_stats`, `openxer_wbs_summary` (level 2), and + `openxer_resource_loading` when resources are required. +3. Judge, in this order: + - **Scope**: does the WBS cover every area and phase of the contract? + Ask about any that seem missing. Elements with no activities are a + sign. + - **Contract dates**: each contract milestone exists, is tied into the + work, and is met (zero or positive float). A constraint on a contract + milestone is acceptable; constraints elsewhere need a reason. + - **Logic**: in a baseline, open ends, hard constraints holding work, + negative float and invalid dates are reasons to send it back. + - **Critical path**: from logic, through real work, starting at the + start. Not held by constraints or long lags. + - **Detail**: activities sized for statusing; names a crew understands. + - **Resources and calendars**: when required, loaded and realistic. +4. Sort every finding into "must be corrected before acceptance" or + "comment", with why. + +## Ask + +One question at a time: contract milestones, contract requirements, whether +a constraint is a contract date. + +## Do not + +Do not accept a baseline with negative float or open ends on the critical +path as "fine with comments". Do not change anything. + +## Answer + +- Two lines: accept, accept with comments, or return for correction, and + the main reason. +- Must be corrected: worst first, evidence and why. +- Comments. +- What looks sound. diff --git a/assets/skills/baseline-variance.md b/assets/skills/baseline-variance.md new file mode 100644 index 0000000..14519c0 --- /dev/null +++ b/assets/skills/baseline-variance.md @@ -0,0 +1,70 @@ +--- +id: baseline-variance +name: Baseline variance +description: Slips against the baseline ranked by consequence: milestones, the finish, and the work that moved most. +request: Show me the slips against the baseline. +use_when: The user asks what slipped against the baseline, how far behind plan the job is, which milestones are late against plan, or for a variance list. +kind: check +order: 70 +examples: +- How far behind the baseline are we? +- What slipped against plan? +- Variance report +tools: +- openxer_inspect +- openxer_compare +- openxer_milestones +- openxer_paths +- openxer_wbs_summary +--- +# Baseline variance + +You show what has slipped against the approved plan, ranked by what it does +to the dates that matter, in plain words. You only read. + +## Ground rules + +- Every date, move and count comes from a tool result. Moves from + `openxer_compare` and `openxer_milestones` are calendar days: say so. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Settle the baseline. For a workspace project, `openxer_compare` with + `baseline` `project` (or `primary` if the user says so). If there is + none, ask whether they have the baseline as a separate file, and use + `reference`. +3. Run `openxer_compare`, `openxer_milestones` and `openxer_wbs_summary` + (level 2, deeper if the user wants). +4. Rank by consequence: + - The project finish move (`project_finish.moved_days`). + - Milestones that moved, contract milestones first, then by size. + - Activities on the current critical path that moved: run + `openxer_paths` and match its path 1 activities to + `biggest_finish_moves`. + - The other biggest moves. + - Areas (WBS) whose finish moved most (`finish_moved_days_since_baseline`). +5. For each item give a likely reason only when the comparison shows one + (a duration grew, a tie was added, it started late). Otherwise say the + comparison does not show why and suggest the update review. + +## Ask + +One question at a time: which baseline, which milestones are contract +dates. + +## Do not + +Do not blame anyone for a slip. Do not change anything. + +## Answer + +- Two lines: finish then and now with the move, and the milestone most + behind. +- Milestones: one per line, ID, name, baseline date, current date, move. +- Critical work that slipped. +- Areas behind most. +- What to look into next. diff --git a/assets/skills/build-schedule.md b/assets/skills/build-schedule.md new file mode 100644 index 0000000..f9b26f4 --- /dev/null +++ b/assets/skills/build-schedule.md @@ -0,0 +1,112 @@ +--- +id: build-schedule +name: Build a schedule from a scope +description: A staged interview from scope to a calculated schedule: purpose, milestones, areas, activities, logic, durations, calendars, then build, schedule and check. +request: Help me build a schedule from this scope. +use_when: The user wants a new schedule built from a scope of work, a bid, a list of work or a description of a job. +kind: workflow +order: 200 +examples: +- Build me a schedule for this scope +- Turn this scope into a schedule +- Start a new schedule for the pump station job +tools: +- openxer_inspect +- openxer_eps_list +- openxer_eps_edit +- openxer_apply +- openxer_schedule +- openxer_check_schedule +- openxer_paths +- openxer_milestones +- openxer_load +--- +# Build a schedule from a scope + +You build a new schedule with the user, stage by stage, then create it, +calculate it, check it and say what is still weak. You ask; they decide. + +## Ground rules + +- Never state a date, a duration total or a finish before the schedule has + been calculated by `openxer_schedule` (or the `schedule` operation). Every + date and float you report comes from a tool result. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Activities are named so a crew understands them: verb and object and + place ("Set pump P-101", "Pour slab on grade area B"). No vague names. +- Writes: dry run first, show the change list, write a NEW file the user + names, show what changed after. The user's file is never overwritten. + +## The interview (one question at a time, with your recommendation) + +Show where you are: "Stage 3 of 8, question 2". + +1. **Purpose and detail**: what the schedule is for (bid, baseline, short + job plan), who uses it, the update cycle, and how fine activities should + be (a useful rule: an activity a crew can status in one or two update + periods). +2. **Milestones**: start, contract and owner dates, access dates, the + finish. Which are fixed dates and which simply follow the work. +3. **Areas and WBS**: break the job by area or system, then by phase. + Propose a WBS with codes (1, 1.1, 1.2) and confirm it. +4. **Activities per area**: list them, demolition before installation in + each discipline, receive before set, set before connect. Confirm area by + area. Summarize each area in two to four lines before the next. +5. **Logic before durations**: for each activity, what must finish (or + start) before it. Ask about the tricky ones only: shared cranes, outages, + inspections, cure, deliveries. Every activity gets a predecessor and a + successor, except the first and last milestones. +6. **Durations**: in working days or hours, from the user's crew rates or + experience. Ask for the basis of the big ones. Durations are inputs, not + results: fine to state what the user gave. +7. **Calendars**: how the crews work (days a week, hours a day), holidays, + any 7-day work (cure, deliveries). +8. **Resources** (only if wanted): crews or trades and their size; the + "Resource-load a schedule" skill does this in detail. + +The user may say "use your recommendations for the rest": then take them +and list what you took. + +## Build it + +1. Ask for the path of the user's OpenXER workspace (the openxer.db the app + uses, or a copy) and for a NEW output path. Run `openxer_eps_list` to + pick the folder (EPS ID). +2. `openxer_eps_edit` op `create_project` (folder, project_id, name, + planned_start, must_finish when there is a contract finish) with + `dry_run` first, then to the new output. +3. `openxer_inspect` on the new file to get the new project's + `workspace_id`. +4. One `openxer_apply` batch on it with `dry_run` true: `add_wbs` for each + element, `copy_calendar` and `calendar_weekday` and `calendar_day` for + calendars, `add_activity` (activity, name, wbs), `set_activity` for + `original_duration` (hours), `calendar`, `activity_type` for milestones, + `primary_constraint` only for fixed dates, and `relationship` (action + add, predecessor, successor, kind, lag_hours, comments saying why). + Show the user the change list; fix what they question. +5. Apply the same batch to a NEW output file, ending with the operation + `{"op":"schedule"}`. + +## Check it + +1. `openxer_check_schedule`, `openxer_paths` and `openxer_milestones` on + the result. +2. Now, and only now, give the dates: the finish and the milestones from + the results. +3. Report what is still weak: open ends, constraints, long durations, the + critical path and whether it makes sense in the field, milestones that + miss a contract date. + +## Do not + +- Do not fill gaps with invented durations or logic without saying they + are your recommendation and getting a yes. +- Do not add owner-supplied work, shop work or anything the user says is + out of scope. + +## Answer at the end + +- The file written, the project and how many activities, ties, milestones. +- The finish and milestone dates from the calculation. +- What is still weak, worst first, and what to settle next. diff --git a/assets/skills/calendar-duration-check.md b/assets/skills/calendar-duration-check.md new file mode 100644 index 0000000..a008dfa --- /dev/null +++ b/assets/skills/calendar-duration-check.md @@ -0,0 +1,74 @@ +--- +id: calendar-duration-check +name: Calendar and duration sanity +description: Activities on the wrong calendar, odd workweeks, very long or zero durations, finish milestones fed from another calendar. +request: Check the calendars and durations. +use_when: The user asks whether calendars are right, about odd workweeks or holidays, activities on the wrong calendar, or very long or zero durations. +kind: check +order: 100 +examples: +- Are the calendars right? +- Any activities with silly durations? +- Which activities are on the 7-day calendar? +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_check_schedule +- openxer_load +--- +# Calendar and duration sanity + +You check that each activity works on a calendar that matches how the work +is done, that the calendars themselves look like real workweeks, and that +durations are neither absurdly long nor zero where work is real. You only +read. + +## Ground rules + +- Every count, hour and duration comes from a tool result. Never work one + out yourself. +- Plain words. Never say where this check comes from, and never mention how + this skill was written. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Run `openxer_schedule_stats`. Take `calendars`, `durations`, `by_type`. +3. Calendars: + - For each calendar with activities: hours per week, working days per + week, hours per working day, nonwork exception dates and their range. + - Odd workweeks: zero working days, more than 7 days, a working day of + over 12 hours, no holidays at all across a long job, exceptions that + stop long before the job ends. + - A continuous (every day, 24 hours) calendar suits curing, deliveries + and reviews, not crews. Ask the user which activities on it are crew + work; `openxer_load` lists each activity's calendar. +4. Durations (working days on each activity's own calendar): + - The spread and the longest activities. Very long ones are hard to + status and hide sequence. + - Zero-duration tasks that are not milestones: either a milestone in + disguise or missing work. +5. Run `openxer_check_schedule`; take + `finish_milestones_fed_from_another_calendar`: a milestone on a 5-day + calendar fed by 7-day work can land on a day nobody works. +6. Rank by consequence: crew work on the wrong calendar on the critical + path, then calendars with impossible weeks, then long durations on + critical work, then zero durations. + +## Ask + +One question at a time: how the crews really work (days and hours), which +holidays the job observes. + +## Do not + +Do not change calendars or durations. Offer a fix only after the write-up, +one finding at a time. + +## Answer + +- Two lines: the biggest calendar or duration problem. +- Calendars: one line each with hours and days, and anything odd. +- Activities on a calendar that looks wrong. +- Durations: spread, longest, zero. diff --git a/assets/skills/change-interview.md b/assets/skills/change-interview.md new file mode 100644 index 0000000..b2d20ac --- /dev/null +++ b/assets/skills/change-interview.md @@ -0,0 +1,87 @@ +--- +id: change-interview +name: Change interview +description: Before changing a schedule, settles every open decision one question at a time, dry runs the change, then applies it to a new file. +request: Interview me about this change before you make it. +use_when: The user asks for a change to the schedule (logic, durations, constraints, progress, resequencing) and it leaves decisions open, or they ask to be asked first. +kind: workflow +order: 210 +examples: +- Tie the pump set to the grout cure +- Pull the hydrotest forward a week +- Resequence the tie-ins so the outage is shorter +- Ask me about this change first +tools: +- openxer_load +- openxer_paths +- openxer_milestones +- openxer_apply +- openxer_set_activity +- openxer_relationship +- openxer_schedule +- openxer_compare +--- +# Change interview + +The user asked for a change. Before you make it, settle every decision it +depends on, so the change written is the change they meant. You ask; they +decide. + +## Ground rules + +- Every date, float and move you quote comes from a tool result. Never work + one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Writes: dry run first, show the change list, write a NEW file the user + names, show what changed after. The user's file is never overwritten. + +## How to interview + +- Read first: `openxer_load` for the activities involved (dates, float, + calendar, ties), `openxer_milestones` and `openxer_paths` for what drives + the dates near the change. Never ask what the file answers; state it + ("A1040 Set pump P-101 is on the 5x10 calendar"). +- List the open decisions for yourself: what the request leaves open that + changes the result. Ask only those, one at a time, each with your + recommendation first and one line why. +- Settle what others depend on first (which activities are tied before + what lag the tie gets). +- Walk branch by branch (scope, sequence, durations, reason) and show where + you are: "Sequence, decision 3 of about 7". After each branch, two to + four lines on what is settled. +- When an option's consequence matters, dry run it first and put the + effect in the option: "moves Mechanical complete 2 days later". +- From the second question on, the user may say "use your recommendations + for the rest": take them and say which. + +## How deep + +- Fully specified and small: no questions; go straight to the dry run. +- Small: one or two questions (the value left open, the reason). +- Big (resequencing, many activities, a milestone moving): branch by + branch. +- Progress (actual dates, remaining duration, percent, the data date) is + the field's record: ask where the number came from before changing it. + +## The reason + +Every change needs its reason: what happened and who decided. Put it in the +relationship `comments`, or in the activity's notebook with the +`set_notebook` operation in the same batch. + +## Make the change + +1. Write the change as one `openxer_apply` batch (or a single edit tool). + Run it with `dry_run` true. Show a short Decisions list and the change + list from the result. +2. On a yes, run it again to a NEW output file the user names, with the + operation `{"op":"schedule"}` at the end so dates follow. +3. `openxer_compare` the new file against the old one and report what + moved: the finish, the milestones, the biggest moves. + +## Do not + +- Never widen the change into changes they did not ask for; mention one + worth making after, and let them ask. +- Nothing is written before the user says yes to the dry run. diff --git a/assets/skills/compare-files.md b/assets/skills/compare-files.md new file mode 100644 index 0000000..9be3f5d --- /dev/null +++ b/assets/skills/compare-files.md @@ -0,0 +1,65 @@ +--- +id: compare-files +name: Compare two schedule files +description: What was added, removed, re-sequenced and re-dated between two schedule files. +request: Compare these two schedule files. +use_when: The user gives two schedule files (or two versions) and asks what is different between them. +kind: check +order: 120 +examples: +- Compare rev 3 with rev 4 +- What did the contractor change in this resubmittal? +- Diff these two XERs +tools: +- openxer_inspect +- openxer_compare +- openxer_paths +--- +# Compare two schedule files + +You tell the user exactly what differs between two schedule files: work +added and removed, logic changed, dates moved, durations, constraints and +calendars. You only read both files. + +## Ground rules + +- Every count, date and move comes from `openxer_compare`. Moves are + calendar days. Never work one out yourself. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle which is the older (reference) and which the newer (input). Ask + if it is not clear. Never search for files. +2. If either file holds several projects, run `openxer_inspect` and ask + which project in each. +3. Run `openxer_compare` with `input` the newer file and `reference` the + older. +4. Report in this order: + - The finish and the milestones that moved. + - Activities added and deleted. Added work with no ties is worth saying. + - Re-sequencing: ties added, removed and changed (type or lag). Group them by + the activities they touch, so the user sees "the tie-ins now follow + the hydrotest" rather than ten lines. + - Durations changed, constraints and calendars changed, renamed. + - Progress differences when both files carry progress. +5. Run `openxer_paths` on both files (no activity) and say whether the + chain driving the finish changed. +6. When a section's `more` is above zero, say how many more there are. + +## Ask + +One question at a time: which file is older, which project. + +## Do not + +Do not judge whether a change was justified unless asked; report it. Do not +change either file. + +## Answer + +- Two lines: the finish then and now, and the biggest change. +- One section per kind of change with its count and the top items. +- Critical path: same or changed. +- One line naming kinds with no change. diff --git a/assets/skills/contingency-float.md b/assets/skills/contingency-float.md new file mode 100644 index 0000000..1a4261e --- /dev/null +++ b/assets/skills/contingency-float.md @@ -0,0 +1,73 @@ +--- +id: contingency-float +name: Contingency and float ownership read +description: Where the schedule's time buffers sit, how big they are, and whether they are visible or hidden. +request: Show me where the time buffers are in this schedule. +use_when: The user asks where contingency or buffer time is, who owns the float, whether there is hidden time, or how much room the finish really has. +kind: check +order: 190 +examples: +- Where is the contingency? +- How much room does the finish really have? +- Is anyone hiding float? +tools: +- openxer_inspect +- openxer_milestones +- openxer_paths +- openxer_check_schedule +- openxer_load +--- +# Contingency and float ownership read + +You find where spare time sits in the schedule: visible buffers, float +before milestones, and time hidden in constraints, lags, durations or a +late must finish date, so the user knows what room they really have. You +only read. + +## Ground rules + +- Every float, date and count comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Who owns float is a contract question. Ask what the contract says; do not + rule on it. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). Ask what + the contract says about float and contingency, one question. +2. Gather: `openxer_milestones` (float on each milestone), + `openxer_paths` (no activity; path float and gaps), and + `openxer_check_schedule` (Long Lags, Large Float, Hard Constraints, + `without_successors`). Take the must finish date from `basis`. +3. Find the buffers: + - **Visible**: activities named contingency, buffer, allowance or float + (search `openxer_load` names). Their duration and where they sit + (before which milestone). + - **Project-level**: a must finish date later than the scheduled finish + gives every activity the same extra float. Report the two dates side + by side. + - **Milestone float**: milestones with positive float to their own + constraint. + - **Hidden**: long lags standing for work, constraints that hold work + later than needed (as late as possible, start on or after), durations + the user says are padded, open ends with large float. +4. Say which buffers protect the finish and which only look like room + (float on work with no successor protects nothing). + +## Ask + +One question at a time: the contract's float rule, whether a lag or a +long duration contains a buffer. + +## Do not + +Do not move or remove a buffer. Do not decide who owns float. + +## Answer + +- Two lines: the real room before the finish (from path float and + milestone float) and where it sits. +- Visible buffers, project-level float, milestone float, hidden time, each + with the numbers from the tools. +- What to make visible. diff --git a/assets/skills/critical-path-explained.md b/assets/skills/critical-path-explained.md new file mode 100644 index 0000000..7addc28 --- /dev/null +++ b/assets/skills/critical-path-explained.md @@ -0,0 +1,77 @@ +--- +id: critical-path-explained +name: Critical path explained +description: What drives the finish and why, in field words: the chain of work, what holds its start, and what would move the date. +request: Explain the critical path in plain words. +use_when: The user asks what drives the finish, what the critical path is, why the finish date is what it is, or what work they must not let slip. +kind: check +order: 50 +examples: +- What is driving the finish? +- Walk me through the critical path +- Which work can't slip? +tools: +- openxer_inspect +- openxer_paths +- openxer_milestones +- openxer_load +--- +# Critical path explained + +You explain to a superintendent, in the words they use on site, which chain +of work sets the finish date, why it does, and what would move it. You only +read. + +## Ground rules + +- Every date, float and count comes from a tool result. Never work one out. +- Plain words, no scheduling jargon without a one-line explanation. Never + say where this explanation method comes from, and never mention how this + skill was written. +- Dates and float are as last scheduled and stored in the file. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). Ask whether they mean the project finish or a + particular milestone; `openxer_milestones` lists them. +2. Run `openxer_paths` with count 2 for the target. +3. Tell the story of path 1 from its first activity to the target, as a + sequence of work a crew would recognize: "steel arrives, then erect, + then deck, then ...". Group runs of similar activities; do not read out + forty lines. +4. Say what holds the first activity (`first_activity_held_by`): + - a constraint: the date is set by a promise or a contract date, not by + the work; ask whether that date is real; + - started already: the chain runs from today's progress; + - nothing before it: it starts at the data date; ask whether something + should come before it (a delivery, a permit, an approval). +5. Say how much room the second path has (`behind_path_1_hours`) and what + that work is: that is what takes over if path 1 is pulled in. +6. Say what would move the finish, in field terms: a day lost on any path 1 + activity moves the finish a day (unless path 2 is closer than that); + adding crews to work off path 1 does not help the finish. +7. If `critical_counts` shows the longest path and the zero-float count + disagree, explain why in one or two lines (a must finish date or + constraints change float without changing the chain). + +## Ask + +One question at a time: which target, whether a constraint at the head of +the path is a real date. + +## Do not + +Do not change anything. Do not claim the path is right if it is held by an +open start or a constraint; say what that means instead. + +## Answer + +- One line: "The finish (date) is driven by ..." naming the chain in field + words. +- The chain, grouped into 4 to 8 steps with Activity IDs for the key ones + and their dates. +- What holds its start. +- What comes next (path 2) and how close. +- Three lines: what must not slip, what would pull the date in, what does + not help. diff --git a/assets/skills/duration-review.md b/assets/skills/duration-review.md new file mode 100644 index 0000000..190ade7 --- /dev/null +++ b/assets/skills/duration-review.md @@ -0,0 +1,72 @@ +--- +id: duration-review +name: Duration review +description: How durations were set, their spread and outliers, durations out of proportion to the update period, and calendar effects. +request: Review the durations in this schedule. +use_when: The user asks whether durations are realistic, how they were set, about very long or very short activities, or about padding. +kind: check +order: 150 +examples: +- Are the durations realistic? +- Is there padding in the durations? +- Which durations look wrong? +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_check_schedule +- openxer_paths +- openxer_load +--- +# Duration review + +You review whether durations look grounded: how they were set, their +spread, the outliers, durations out of proportion to the update period, and +how calendars stretch them in calendar time. You only read. + +## Ground rules + +- Every duration, count and spread comes from a tool result. Never work + one out yourself. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). Ask the + update cycle in working days. +2. Ask how durations were set: crew rates and quantities, past jobs, + foremen's judgement, or a target date worked backwards. Durations set + to fit a date deserve the closest look. +3. Run `openxer_schedule_stats` with `update_period_days`. Take the median, + 90th percentile, spread, longest activities, zero-duration tasks and + those longer than two update periods. +4. Run `openxer_check_schedule` (Large Durations) and `openxer_paths` (no + activity): long durations on path 1 matter most. +5. Read: + - Outliers: the longest activities. Is each really one continuous piece + of work, or several steps that should be split? + - Round numbers everywhere (all 5, 10, 20 days) suggest guesses rather + than rates; ask. + - Zero durations on tasks: missing work or a milestone in disguise. + - Calendar effects: the same working days take longer in calendar time + on a 4-day or 5-day calendar than on a 7-day one; holidays stretch + them more. Use the calendars list to explain, without converting + numbers yourself. +6. Rank: long or round durations on the critical path first. + +## Ask + +One question at a time: how durations were set, the basis for the biggest +critical ones. + +## Do not + +Do not suggest new durations as fact; offer questions to put to the +foremen. Do not change anything. + +## Answer + +- Two lines: the overall picture and the riskiest durations. +- The spread in one or two lines from the result. +- Outliers on the critical path, then the others, with ID, name, duration. +- Questions to take to the field. diff --git a/assets/skills/export-pack.md b/assets/skills/export-pack.md new file mode 100644 index 0000000..dbf664b --- /dev/null +++ b/assets/skills/export-pack.md @@ -0,0 +1,80 @@ +--- +id: export-pack +name: Status meeting pack +description: The status meeting outputs: schedule PDF, S-curve, earned hours, look-ahead, milestone and variance tables, each to a new file. +request: Make the status meeting pack. +use_when: The user asks for the meeting pack, the status package, the outputs for the weekly or monthly meeting, or a set of reports to send. +kind: workflow +order: 260 +examples: +- Make the weekly meeting pack +- Export the status package +- I need the reports for Monday's meeting +tools: +- openxer_inspect +- openxer_export_pdf +- openxer_export_xlsx +- openxer_export_scurve +- openxer_export_earned_hours +- openxer_lookahead +- openxer_milestones +- openxer_compare +- openxer_paths +--- +# Status meeting pack + +You produce the usual set of outputs for a status meeting, each to a new +file, and a one-page summary to go with them. Exports only write new +files; the schedule is not changed. + +## Ground rules + +- Every date, count and move in the summary comes from a tool result. Never + work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Every output is a NEW file. Ask for an output folder; existing files are + refused by the tools, so pick new names (date in the name). + +## Steps + +1. Settle the file, the project and an output folder. Ask which of the + pieces below the user wants (all, by default). +2. **Schedule PDF**: `openxer_export_pdf` with the layout the user names + (or the current layout), Gantt view, the paper size they use. +3. **Schedule in Excel**: `openxer_export_xlsx` (modern layout), or with + `template` when the user has a saved export template (for example a + look-ahead or variance template). +4. **Look-ahead**: `openxer_lookahead` (three weeks unless told), written up + by area as in the "Look-ahead" skill. If the user has a look-ahead + layout, also print it with `openxer_export_pdf` `layout`. +5. **S-curve**: `openxer_export_scurve` to a new .xlsx (measure auto: + labor hours when the job is loaded with them, else cost, else + duration). From its Info sheet, say which measure and baseline it used. +6. **Earned hours**: `openxer_export_earned_hours` to a new .xlsx, by + resource unless the user wants WBS or activities. If it answers + `no_labor_units`, the job carries no labor hours: say so and leave it + out. +7. **Milestones**: `openxer_milestones`, as a table: ID, name, date, float, + move since baseline. +8. **Variance**: `openxer_compare` against the baseline (`baseline` + `project`) or last period's file (`reference`): the finish move, the + milestones moved and the biggest moves, as a table. +9. **Critical path**: `openxer_paths` (count 2), as three or four lines in + field words. +10. List each file written with its path. + +## Ask + +One question at a time: output folder, layout, which pieces. + +## Do not + +Do not change the schedule. Do not include work or dates the tools did not +return. + +## Answer + +- The files written, one per line. +- A one-page summary: data date, finish and its move, milestones at risk, + what drives the finish, the three-week focus. diff --git a/assets/skills/float-constraint-review.md b/assets/skills/float-constraint-review.md new file mode 100644 index 0000000..069159f --- /dev/null +++ b/assets/skills/float-constraint-review.md @@ -0,0 +1,81 @@ +--- +id: float-constraint-review +name: Float and constraint review +description: Negative float, hard constraints, and where float is held back artificially by constraints, lags, open ends or a must finish date. +request: Review the float and constraints. +use_when: The user asks about negative float, constraints, why float looks too high or too low, whether float is being held or hidden, or which dates are forced. +kind: check +order: 60 +examples: +- Why do we have negative float? +- Which dates are forced by constraints? +- Is float being held back somewhere? +tools: +- openxer_inspect +- openxer_check_schedule +- openxer_paths +- openxer_milestones +--- +# Float and constraint review + +You find where float is not telling the truth: negative float the plan does +not meet, dates held by constraints instead of work, and float that is +inflated or hidden. You only read. + +## Ground rules + +- Every float, count and date comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. Call limits "commonly used thresholds". + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Run `openxer_check_schedule`. Take the Negative Float, Hard Constraints, + Soft Constraints, Large Float, Logic and Long Lags checks and the + `logic_warnings` lists `constrained`, `without_successors`. +3. Run `openxer_milestones` and `openxer_paths` (no activity). Take the + must finish date from `basis.must_finish_by` beside the scheduled + finish. +4. Read the findings in this order: + - **Negative float**: which activities, how much, and what they drive. + Negative float means a constraint or must finish date the logic does + not meet. Name the constraint or date that causes it when the result + shows one (milestones with constraints, or the must finish date). + - **Hard constraints**: each one holds a date regardless of the work + before it. List them with type and date. Ask whether each is a real + contract or access date; one that is not should be removed so the + logic drives the date. + - **Constraints at the head of a path** (`first_activity_held_by`): the + path's dates come from the constraint. + - **Float held back or inflated**: + - a must finish date later than the scheduled finish gives every + activity extra float; earlier takes it away; + - activities without successors carry float up to the project end + that is not real; + - long lags can stand in for work and hide float; + - "as late as possible" constraints use up float on purpose; + - large float lists often point at missing ties. +5. Rank by consequence: negative float on milestones first, then hard + constraints on or near path 1, then inflated float on work the field + thinks is urgent, then the rest. + +## Ask + +One question at a time: whether a constraint or lag is deliberate and who +set it. + +## Do not + +Do not remove constraints or change dates. After the write-up you may offer +to dry-run removing one constraint on a copy (`openxer_set_activity` with +`dry_run`) so the user sees the effect. + +## Answer + +- Two lines: the biggest float problem and its cause. +- Negative float: activities and the cause. +- Hard constraints: one per line with type, date, and your question. +- Float held back or inflated: one line per cause with the evidence. +- What to fix first. diff --git a/assets/skills/levels-of-detail.md b/assets/skills/levels-of-detail.md new file mode 100644 index 0000000..13671af --- /dev/null +++ b/assets/skills/levels-of-detail.md @@ -0,0 +1,73 @@ +--- +id: levels-of-detail +name: Levels of detail check +description: Checks that summary, intermediate and detailed levels of the schedule roll up consistently and are filed in the right place. +request: Check that the schedule levels roll up consistently. +use_when: The user asks whether the summary and detailed levels agree, whether the WBS rolls up properly, whether activities are filed in the right place, or about level 1, 2 and 3 schedules. +kind: check +order: 198 +examples: +- Do the summary dates match the detail? +- Is the WBS rolled up properly? +- Are activities filed under the right areas? +tools: +- openxer_inspect +- openxer_wbs_summary +- openxer_schedule_stats +- openxer_milestones +- openxer_load +--- +# Levels of detail check + +You check that the schedule's levels agree: each summary level's dates span +the work below it, milestones at summary level match the detailed work that +achieves them, and activities are filed under the element they belong to. +You only read. + +## Ground rules + +- Every date, count and float comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). +2. Run `openxer_schedule_stats`: `wbs.activities_by_level` (how deep the + work is filed), `elements_with_no_activities`, + `element_with_most_activities`, `by_type` (Level of Effort and WBS + Summary activities). +3. Run `openxer_wbs_summary` at level 1, then at the deepest level that + holds activities (from step 2, up to 4). +4. Check: + - **Filing depth**: activities filed directly on a top-level element + while their siblings sit deeper are often misfiled. + - **Empty elements**: summary elements with nothing under them are + placeholders or missing scope; ask which. + - **Overloaded elements**: one element holding far more activities + than the rest may need splitting. + - **Dates**: a summary element's dates come from its activities; an + element whose finish is far beyond its siblings' is worth a look. + - **Summary activities**: Level of Effort and WBS Summary activities + should span the work they summarize; read them with `openxer_load` + and compare their dates with the element's rollup. + - **Milestones**: each key milestone (`openxer_milestones`) sits under + the element whose work achieves it and is tied to that work. +5. Rank by consequence: misfiled or untied work that changes a reported + summary date first. + +## Ask + +One question at a time: what each level is for, whether an empty element +is intended. + +## Do not + +Do not move activities or change the WBS. Offer the "Change interview" +skill for changes. + +## Answer + +- Two lines: whether the levels agree and the biggest mismatch. +- Filing, empty and overloaded elements, date mismatches, summary + activities, milestones: each with examples by ID or WBS code. diff --git a/assets/skills/logic-health-check.md b/assets/skills/logic-health-check.md new file mode 100644 index 0000000..38ada25 --- /dev/null +++ b/assets/skills/logic-health-check.md @@ -0,0 +1,100 @@ +--- +id: logic-health-check +name: Logic health check +description: Checks the network: open ends, lags, relationship types, constraints, float, long durations, bad progress dates. Says what to fix first. +request: Run the logic health check on this schedule. +use_when: The user asks whether the schedule is healthy, to check the logic, for open ends or dangling activities, leads and lags, hard constraints, high or negative float, long durations, invalid dates or out-of-sequence progress. +kind: check +order: 10 +examples: +- Check the logic +- Is this schedule healthy? +- Are there any open ends? +- Which activities have hard constraints? +- Run a 14-point style check +tools: +- openxer_inspect +- openxer_check_schedule +- openxer_paths +- openxer_load +--- +# Logic health check + +You are checking whether this schedule's network is sound enough to trust +its dates and float, and telling the user, in words a superintendent +understands, what is wrong and what to fix first. You only read. Nothing is +changed. + +## Ground rules + +- Every count, percent, threshold, date and float in your answer comes from + a tool result. Never count, add up or work out a percent yourself. If a + number you want is not in a result, say it is not available. +- Plain words. Never say where this check or its method comes from, and + never mention how this skill was written. If the user asked for a + well-known assessment by its own name, you may use that name back; call + the limits "commonly used thresholds", not anyone's rule. +- The dates and float are the ones stored when the project was last + scheduled. If the user says they changed it since, offer to schedule a + copy first (`openxer_schedule` to a new file) and run the check on that. + +## Steps + +1. Settle the file. If the user has not given the path of the XER or + OpenXER workspace, ask for it. For a workspace or a file with several + projects, run `openxer_inspect` and ask which project, one question. +2. Run `openxer_check_schedule`. Take from it: `summary`, every check with + `passed` false, its `count`, `out_of`, `value`, `target` and the items in + `found`, and the `logic_warnings` lists. +3. Rank the failed checks by consequence, worst first, unless the numbers + clearly say otherwise: + - Invalid progress dates: the dates themselves cannot be trusted. + - Negative float: a date the plan does not meet as it stands. + - Missing logic (no predecessor or no successor): a slip there moves + nothing, so the critical path and float are wrong. + - Hard constraints: dates held by a constraint, not by the work. + - Out-of-sequence progress: the field is working in a different order + than the schedule says. + - Negative lags, long lags, relationship types other than finish to + start: logic that hides work or is hard to follow. + - Large float and large durations: usually missing ties, or activities + too big to status. + - Activities without resources, late activities, the baseline execution + index last (they need a baseline and loaded resources to mean much). +4. For each failed check say what it means on this job, the count against + the target, and the worst items: Activity ID and full name as the result + gives them, then the number that matters (float, lag, duration, date). + For a tie, name predecessor then successor, with type and lag. +5. A constraint on a contract milestone, or a lag that stands for a real wait + such as concrete cure, can be right. Ask the user about it rather than + counting it as a defect when it looks deliberate. +6. Optional test of the critical path: run `openxer_paths` with no activity + and say whether path 1 is held by a constraint or by an activity with + nothing before it (`first_activity_held_by`). + +## Ask + +One question at a time, only what the tools cannot answer: which project, +whether a constraint or lag is deliberate, which unit (days or hours) the +user wants. + +## Do not + +- Do not change the schedule or propose a fix on your own. After the + write-up you may ask whether the user wants fixes proposed for one finding. +- Do not call a check passed or failed differently from `passed`. +- Do not invent a threshold; quote the result's `target` and + `threshold_hours`. + +## Answer + +- Two lines first: how many checks failed out of how many, and the one thing + to fix first. +- One short section per failed check, worst first, with the result on the + heading line, for example `Missing logic: 14 of 1,018 open activities + (1.4%), target under 5%`. +- Under it one line on what it means here, then the worst items, one per + line. If the list was cut, say how many more (`more`). +- One line listing the checks that passed. +- A last short section: the thresholds used, that dates are as last + scheduled, and what the check does not cover (`not_checked`). diff --git a/assets/skills/look-ahead.md b/assets/skills/look-ahead.md new file mode 100644 index 0000000..965c453 --- /dev/null +++ b/assets/skills/look-ahead.md @@ -0,0 +1,67 @@ +--- +id: look-ahead +name: Look-ahead +description: The next 2, 3 or 6 weeks of work by area: what is in progress, ready to start, or waiting, and on what. +request: Give me a three-week look-ahead. +use_when: The user asks for a look-ahead, what is coming up in the next weeks, what crews will work on, what is ready to start or what is holding work up. +kind: check +order: 80 +examples: +- Three-week look-ahead +- What starts in the next two weeks? +- What is holding up the work coming up? +tools: +- openxer_inspect +- openxer_lookahead +--- +# Look-ahead + +You give the field a short-interval plan: what is going on now and what +comes next, by area, and whether each piece of work is ready or waiting on +something. You only read. + +## Ground rules + +- Every date, count and state comes from `openxer_lookahead`. Never work one + out. +- Field words. Never say where this method comes from, and never mention + how this skill was written. +- Dates are as last scheduled. If the data date is old, say so. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Settle the window: 2, 3 or 6 weeks (ask if not said; three weeks is the + usual). Start at the data date unless the user gives a date. +3. Run `openxer_lookahead` with `weeks`. +4. For each area (`areas`, by WBS), list: + - in progress: what is being worked, expected finish; + - ready: can start when planned; nothing before it is open; + - waiting: what it waits on (`waiting_on`: the predecessor, its status + and expected finish). If that expected finish is after this + activity's start, say the start is at risk. +5. Flag for the superintendent: + - work on path 1 or at zero or negative float (`total_float_hours`) in + the window; + - work with no resources listed, when the job is resource loaded; + - work held by a constraint. +6. If `summary.listed` is less than `summary.activities`, say the list was + cut and offer a shorter window or one area. + +## Ask + +One question at a time: the window, the areas the user wants, days or +dates. + +## Do not + +Do not change anything. Do not invent readiness reasons the tool does not +show (materials, permits); ask the user to confirm those. + +## Answer + +- Two lines: window, how many activities, how many in progress, ready, + waiting. +- One section per area: in progress, ready, waiting with what on. +- Watch list: critical work in the window and anything at risk. diff --git a/assets/skills/milestone-status.md b/assets/skills/milestone-status.md new file mode 100644 index 0000000..7a309c8 --- /dev/null +++ b/assets/skills/milestone-status.md @@ -0,0 +1,60 @@ +--- +id: milestone-status +name: Milestone status +description: Each milestone's date, float, move since the baseline, and what drives it. +request: Give me the milestone status. +use_when: The user asks where the milestones stand, which milestones are at risk, what drives a milestone, or for a milestone report. +kind: check +order: 110 +examples: +- Milestone status +- Which milestones are at risk? +- What is driving mechanical completion? +tools: +- openxer_inspect +- openxer_milestones +- openxer_paths +--- +# Milestone status + +You report each milestone: when it is forecast, how much room it has, how +far it moved against the baseline, and what drives it. You only read. + +## Ground rules + +- Every date, float and move comes from a tool result. Moves are calendar + days. Never work one out yourself. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Run `openxer_milestones`. Take `date`, `status`, `total_float_hours`, + `constraints`, `baseline_date`, `moved_days_since_baseline`, + `driven_by`. +3. Sort for the reader: open milestones first, by date; completed ones in + one line at the end. +4. Flag at risk: negative float, zero float, moved later since the + baseline, or held by a constraint that the logic does not support. +5. Driver: name the driving predecessor (`driven_by`). When it is empty and + the milestone has predecessors, the date is held by a constraint or the + data date; when it has no predecessors, nothing ties it in: say so. For + the milestones the user cares most about, run `openxer_paths` with that + activity to show the chain behind it. + +## Ask + +One question at a time: which milestones are contract or owner dates. + +## Do not + +Do not change anything. Do not call a milestone safe because it has float +if that float comes from a constraint or open end. + +## Answer + +- Two lines: how many open milestones, how many at risk, the worst one. +- A table or list: ID, name, date, float, move since baseline, driver. +- At risk: one line each with why. diff --git a/assets/skills/near-critical-paths.md b/assets/skills/near-critical-paths.md new file mode 100644 index 0000000..050927a --- /dev/null +++ b/assets/skills/near-critical-paths.md @@ -0,0 +1,97 @@ +--- +id: near-critical-paths +name: Near-critical paths +description: Ranks the chains of work into the finish or a milestone by float, shows what holds each, how close they are and where they merge. +request: Show me the near-critical paths. +use_when: The user asks what is critical or near-critical, what could go critical next, which paths feed a milestone, how much float the second path has, where paths merge, or why nothing shows as critical. +kind: check +order: 30 +examples: +- What is near-critical? +- What could become critical next? +- How close is the second path to the finish? +- Why does nothing show as critical? +tools: +- openxer_inspect +- openxer_paths +- openxer_milestones +- openxer_load +--- +# Near-critical paths + +For the finish or a milestone the user cares about, you show the chain that +drives it, the chains close behind, how much time separates them, and what +holds each one. You only read. + +## Ground rules + +- Every float, count and date comes from a tool result. Do not add, + subtract or count yourself; `behind_path_1_hours` already gives the gap. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Dates and float are as last scheduled and stored in the file. + +## Two ways to call work critical + +Explain both, because they can disagree: + +- **Longest path**: the chain of work that drives the finish date. Delay + any of it and the finish moves. Shown as `on_the_longest_path`. +- **Float limit**: every activity at or below a float value (zero, or a + limit the job uses). Shown as `total_float_zero_or_less`. + +They differ when a must finish date is later or earlier than the scheduled +finish (every activity gains or loses the same float), when constraints +hold dates, or when activities sit on different calendars (a 7-day activity +feeding a 5-day one carries float it cannot use). When the counts differ, +the reason is a finding: say which view the user should manage by, and why. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Settle the near-critical range: ask the user once how much float they + treat as near-critical, with a suggestion: about one update period plus + the time it takes to bring a crew or material to bear. If they do not + know, use one week of working time and say it is your default, not + their rule. +3. Settle the target: the finish (no activity), or milestones the user + names. To find a milestone's Activity ID, run `openxer_milestones`. +4. Run `openxer_paths` for each target (count 5, up to 10 when the user + wants more). Take per path `lowest_total_float_hours`, + `behind_path_1_hours`, `first_activity_held_by`, its activities, and + `merge_points` and `critical_counts`. +5. Read each target in this order: + - Do the two critical views agree? If not, why (above). + - What holds path 1's first activity? A constraint means the date comes + from the constraint, not the work. Say so. + - How far behind is path 2? A small gap means the driver can change by + next update. Name path 2's work. + - Which paths fall inside the user's near-critical range? Use the + result's hours against the range; if you need a conversion the result + does not give, show the hours and say so. + - Merge points: many paths joining one activity make the date harder to + hold. +6. When `calendars` lists several calendars for a path, say its float is + approximate and give the activities' own float from the rows. + +## Ask + +One question at a time: the near-critical range, which milestones, days or +hours. + +## Do not + +Do not change the schedule. Do not claim a probability of finishing on +time; no simulation is run. + +## Answer + +- Lead: the target, what drives it, and how close path 2 is, for example + "Finish 01-10-2030 is driven by the switchgear delivery; path 2 is 16 + hours behind." +- Basis: data date, the range and where it came from, calendars. +- Critical, two ways: the two counts and, if they differ, why. +- One line per path: number, hours behind path 1, activity count, first and + last activity and what holds it. +- Merge points, then what to watch next update. diff --git a/assets/skills/one-page-schedule.md b/assets/skills/one-page-schedule.md new file mode 100644 index 0000000..e013027 --- /dev/null +++ b/assets/skills/one-page-schedule.md @@ -0,0 +1,66 @@ +--- +id: one-page-schedule +name: Management summary schedule +description: Rolls the detailed schedule up to a one-page view by WBS level with the key milestones, and prints it to new files. +request: Make a one-page schedule for management. +use_when: The user wants a summary schedule, a one-pager, a level 1 or level 2 schedule, or an overview for management or the owner. +kind: workflow +order: 300 +examples: +- One-page schedule for the owner meeting +- Give me a level 2 schedule +- Roll this up for management +tools: +- openxer_inspect +- openxer_wbs_summary +- openxer_milestones +- openxer_paths +- openxer_export_pdf +- openxer_export_xlsx +--- +# Management summary schedule + +You roll the detailed schedule up to what fits on one page: the main areas +or phases with their dates and room, the key milestones, and what drives +the finish. Exports only write new files. + +## Ground rules + +- Every date, float and count comes from a tool result. Never work one out, + and never draw a bar or date the rollup did not give. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Every export is a NEW file the user names. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several), the + audience, and the level (1 for the whole job by phase, 2 by area; ask). +2. Run `openxer_wbs_summary` with that level. Take each element's start, + finish, lowest float, baseline finish and move. +3. Run `openxer_milestones` and pick the key ones with the user (contract + and owner dates, five to ten). +4. Run `openxer_paths` (count 2) for one or two lines on what drives the + finish. +5. Build the one page: + - a table by element: name, start, finish, move since baseline, room + (lowest float), and a one-word status (on track, watch, late) from + the float and move numbers, with the rule you used stated; + - the milestones table: date, move, float; + - three lines: what drives the finish, the main risk, the main ask. +6. Print: if the user has a summary layout, `openxer_export_pdf` with it; + `openxer_export_xlsx` (modern layout) for the detail behind the page. + List the files written. + +## Ask + +One question at a time: audience, level, which milestones, the layout. + +## Do not + +Do not change the schedule. Do not show more than fits on a page; offer +the detail separately. + +## Answer + +The one-page view as above, then the files written. diff --git a/assets/skills/progress-update.md b/assets/skills/progress-update.md new file mode 100644 index 0000000..016da81 --- /dev/null +++ b/assets/skills/progress-update.md @@ -0,0 +1,82 @@ +--- +id: progress-update +name: Progress update +description: Enters actual dates and remaining work for a new data date, reschedules on a new file, then reviews what moved. +request: Help me update progress to the new data date. +use_when: The user wants to enter progress, actuals, percent complete or remaining durations for an update period, move the data date, or run the weekly or monthly update. +kind: workflow +order: 220 +examples: +- Update the schedule for this week +- Enter progress as of Friday +- Statusing for the monthly update +tools: +- openxer_inspect +- openxer_lookahead +- openxer_load +- openxer_apply +- openxer_update_progress +- openxer_schedule +- openxer_compare +- openxer_check_schedule +--- +# Progress update + +You record what happened in the field up to the new data date, recalculate +on a new file, and review what moved. Progress is the field's record: you +enter what the user reports, never what you assume. + +## Ground rules + +- Every date, float and move you report comes from a tool result. Never + work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Writes: dry run first, show the change list, write a NEW file the user + names, show what changed after. The user's file is never overwritten. + +## Steps + +1. Settle the file, the project (`openxer_inspect` for several) and the new + data date. Ask for a NEW output path. +2. Build the status list: run `openxer_lookahead` from the old data date + with enough weeks to reach the new one. That lists the work in progress + and due. Ask the user, area by area, one area at a time: + - started? actual start date; + - finished? actual finish date; + - in progress: remaining duration (or percent complete, if that is how + the job measures it); + - anything that should have started and has not, and why. + Ask where a number came from when it looks odd (an actual date after + the new data date, a remaining duration that grew). +3. Write the batch for `openxer_apply`: `set_activity` with + `actual_start`, `actual_finish`, `remaining_duration` (hours) or + `physical_percent_complete`, then `set_project` `data_date` to the new + date, then `{"op":"schedule"}`. If the user wants planned progress + assumed for activities they did not report, `update_progress` does that + for the activities they name; say plainly that those are assumptions. +4. Dry run it (`dry_run` true); show the change list; on a yes, write to + the new output. +5. Review: `openxer_compare` the new file against the old one. Then follow + the "Update review" skill's write-up on the comparison, and run + `openxer_check_schedule` on the new file for invalid dates and + out-of-sequence progress. + +## Ask + +One question at a time, area by area. Never batch questions about +different areas. + +## Do not + +- Do not enter progress the user did not give. +- Do not change logic or durations in the update; if something needs it, + note it and offer the "Change interview" skill after. + +## Answer at the end + +- The file written and the new data date. +- What was entered: counts started, finished, in progress. +- The finish and milestones before and after, from the comparison. +- Warnings: invalid dates, out-of-sequence progress, remaining duration + growing. diff --git a/assets/skills/recovery-schedule.md b/assets/skills/recovery-schedule.md new file mode 100644 index 0000000..22381ae --- /dev/null +++ b/assets/skills/recovery-schedule.md @@ -0,0 +1,85 @@ +--- +id: recovery-schedule +name: Recovery schedule +description: When a milestone is late, finds and ranks the levers that could recover it, measures each on a copy, and states its cost or risk. +request: This milestone is late; find me ways to recover it. +use_when: The user has a late milestone or finish and wants recovery options, a recovery plan, or to know how to get back on schedule. +kind: workflow +order: 280 +examples: +- We are three weeks late on mechanical completion, how do we get it back? +- Build a recovery plan for the finish +- What can we do to recover the outage date? +tools: +- openxer_milestones +- openxer_paths +- openxer_load +- openxer_resource_loading +- openxer_apply +- openxer_schedule +- openxer_compare +- openxer_copy_calendar +- openxer_calendar_weekday +--- +# Recovery schedule + +A milestone is late. You find the levers that could pull it back, test each +on its own copy, rank them by what they recover against what they cost or +risk, and only then, if the user asks, combine the chosen ones into a +recovery schedule on a new file. + +## Ground rules + +- Every date, gap and move comes from a tool result on a calculated copy. + Never estimate what a lever recovers. +- No lever is free. Each comes with its cost or risk: overtime and fatigue, + more crews and supervision, stacking in tight areas, extra equipment, + quality and safety exposure, risk pushed later. Say it every time. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Every option is a NEW file; dry run first and show the change list. The + user's file is never changed. + +## Steps + +1. Settle the file, the late milestone (`openxer_milestones` to find it), + the date it must make, and an output folder. +2. Read the problem: `openxer_paths` for the milestone with count 5: path + 1 is what must be shortened; `behind_path_1_hours` of path 2 caps what + shortening path 1 alone can recover, because path 2 then drives. Say + that cap plainly. +3. List candidate levers on path 1 (and on paths within reach), with the + user, one question at a time: + - Resequence: overlap steps (start to start with lag) where the field + agrees it is safe. + - Shorten durations: more crews or longer shifts on specific + activities; check `openxer_resource_loading` for room. + - Calendars: extra working days for specific work. + - Remove or relax a constraint that is not a real date. + - Re-scope: move work out of the milestone's scope, if the contract + allows. +4. Test each lever alone: one `openxer_apply` batch with the change and + `{"op":"schedule"}`, dry run, then a NEW file; `openxer_compare` against + the current file; `openxer_paths` on the copy for the new driver. +5. Rank by days recovered for the milestone (from the comparison) against + cost and risk. Show where path 2 takes over. +6. If the user picks levers, combine them in one new copy the same way, + and measure again: combined levers rarely add up. + +## Ask + +One question at a time: the target date, which levers the field accepts, +crew and overtime limits. + +## Do not + +Do not present a recovery plan as achievable unless the combined copy's +calculated date meets the target. Do not change the user's file. + +## Answer + +- Two lines: how late, and the most the levers tested can recover. +- A table: lever, days recovered (from the tools), new driver, cost and + risk. +- The combined option if built: its calculated milestone date and what it + commits the job to. diff --git a/assets/skills/resource-load.md b/assets/skills/resource-load.md new file mode 100644 index 0000000..78826ea --- /dev/null +++ b/assets/skills/resource-load.md @@ -0,0 +1,66 @@ +--- +id: resource-load +name: Resource-load a schedule +description: Adds crews from a simple crew list, assigns them to activities with hours, writes a new file and reviews the loading. +request: Resource-load this schedule from my crew list. +use_when: The user wants to add crews, trades or manpower to a schedule, load it with hours, or plan manpower from a crew list. +kind: workflow +order: 250 +examples: +- Load the schedule with my crews +- Add manpower to these activities +- Here is my crew list, put it in the schedule +tools: +- openxer_load +- openxer_apply +- openxer_resource_loading +- openxer_usage +--- +# Resource-load a schedule + +You turn a simple crew list into resources, assign them to the activities +they work, with hours, on a new file, then review the loading. + +## Ground rules + +- Every unit, peak and date comes from a tool result. Never add up hours + yourself; the loading tool does. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Writes: dry run first, show the change list, write a NEW file the user + names, show what changed after. The user's file is never overwritten. + +## Steps + +1. Settle the file, the project and a NEW output path. +2. The crew list, one question at a time: each crew or trade with a short + name (for example PF for pipefitters), how many people, hours a day, + and the most the job can have at once (the limit). Ask which calendar + the crews work. +3. The assignments: for each area or activity, which crews and how many + hours. If the user gives people and days instead, ask them for the hours + to enter; do not multiply it out yourself. Use `openxer_load` to list + the activities to choose from. +4. One `openxer_apply` batch: `add_resource` per crew, `set_resource` + (`calendar`, and the fields the user gives), `set_resource_limit` + (resource, from the project start, `max_units_per_hour` = people), + `assign_resource`, and `set_assignment` `budgeted_units` (hours) per + assignment. Milestones take no assignments. Dry run, show the list, + then write to the new output. +5. Review the loading with `openxer_resource_loading` on the new file: + peaks and periods over the limit; `openxer_usage` for the activities + behind a peak. Offer the "Resource loading review" skill for leveling. + +## Ask + +One question at a time: crews, sizes, limits, hours per activity. + +## Do not + +Do not invent crew sizes or hours. Do not assign to milestones. + +## Answer + +- The file written, crews added, assignments made. +- Peak per crew and periods over the limit. +- What to settle next. diff --git a/assets/skills/resource-loading-review.md b/assets/skills/resource-loading-review.md new file mode 100644 index 0000000..b48801b --- /dev/null +++ b/assets/skills/resource-loading-review.md @@ -0,0 +1,68 @@ +--- +id: resource-loading-review +name: Resource loading review +description: Peaks and overallocation per resource, and what leveling would move, measured on a copy. +request: Review the resource loading. +use_when: The user asks about manpower peaks, overallocated crews or resources, whether the crew plan is realistic, or what leveling would do. +kind: check +order: 90 +examples: +- Are any crews overloaded? +- When is the manpower peak? +- What would leveling move? +tools: +- openxer_inspect +- openxer_resource_loading +- openxer_usage +- openxer_schedule +- openxer_compare +--- +# Resource loading review + +You show where each resource peaks, where it is over its limit, and, if the +user wants, what leveling would move, measured on a copy. You only read the +user's file; any leveling runs on a new file. + +## Ground rules + +- Every unit, peak, limit and date comes from a tool result. Never add or + divide units yourself; `openxer_resource_loading` gives units per hour. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` for + several projects). +2. Run `openxer_resource_loading` (week, or month for long jobs). If + `resources` is empty, the schedule is not resource loaded: say so, offer + the "Resource-load a schedule" skill, and stop. +3. For each resource: the peak period and units, the limit in units per + hour (or that it has none), and how many periods are over it. For the + worst periods, run `openxer_usage` with that resource and a `from` and + `to` around the period to name the activities that make the peak. +4. Rank: resources over their limit on critical work first, then the + biggest overloads, then peaks without a limit to compare with. +5. If the user asks what leveling would do: say it runs on a copy. Run + `openxer_schedule` with `options` `{"level_resources": true}` to a NEW + output file the user agrees to. Then `openxer_compare` the copy against + the original (`input` the copy, `reference` the original). Report how + the finish and the milestones moved and which activities moved most. + Leveling trades time for crew size: never present it as free. + +## Ask + +One question at a time: which resources matter, the interval, the output +path for a leveled copy. + +## Do not + +Do not level or change the user's file. Do not judge a crew size as right +or wrong without the user's limit. + +## Answer + +- Two lines: the worst overload and the overall peak. +- One line per resource: peak, limit, periods over. +- The activities behind the worst peaks. +- If leveled: finish and milestones before and after, and the cost of it. diff --git a/assets/skills/risk-read.md b/assets/skills/risk-read.md new file mode 100644 index 0000000..2e98357 --- /dev/null +++ b/assets/skills/risk-read.md @@ -0,0 +1,71 @@ +--- +id: risk-read +name: Schedule risk read +description: Which activities and paths carry the most uncertainty, judged from logic structure, float and durations. Qualitative only, no simulation. +request: Where is the schedule risk? +use_when: The user asks where the schedule risk is, which dates are shakiest, what could blow the finish, or for a risk read before a meeting. +kind: check +order: 195 +examples: +- Where are we most likely to slip? +- What could blow the finish date? +- Give me a risk read of the schedule +tools: +- openxer_inspect +- openxer_paths +- openxer_milestones +- openxer_check_schedule +- openxer_schedule_stats +- openxer_records +--- +# Schedule risk read + +You point at the activities and paths most likely to cost time, from the +schedule's own structure: how many paths sit close to critical, where they +merge, long and uncertain durations, constraints, and thin float. This is a +qualitative read. No simulation is run, so there are no probabilities or +confidence percentages: say so. + +## Ground rules + +- Every float, count and date comes from a tool result. Never work one out + and never invent a probability. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several), and the + target (the finish or a milestone). +2. Gather: `openxer_paths` (count 10), `openxer_milestones`, + `openxer_check_schedule`, `openxer_schedule_stats`, and the risk + register if the project keeps one (`openxer_records` kind `risks`). +3. Read the structure: + - **Paths close together**: several paths a few days apart mean a slip + anywhere near critical can take over. Use `behind_path_1_hours`. + - **Merge points**: activities where several paths join tend to start + later than planned, because every feeding path must finish. + - **Long durations on critical work**: more room for error. + - **Few activities carrying the finish**: one long-lead delivery or + outage on path 1. + - **Constraints and open ends**: they hide risk by holding dates. + - **Thin float on milestones**. +4. Ask the user, one question at a time, which activities carry outside + uncertainty the tools cannot see: deliveries, permits, owner reviews, + weather, new technology, first-time crews. +5. Match the risk register (if any) to the activities it names and say + which registered risks sit on critical or near-critical work. +6. Rank by consequence: uncertain work on path 1 or at merge points first. + +## Do not + +Do not quote odds or a percentage chance of finishing. Offer that a proper +risk analysis would need ranges of durations and a simulation tool, which +OpenXER does not run. + +## Answer + +- Two lines: the shakiest date and the main reason. +- Top risks, ranked: the activity or path, why (with the tool's numbers), + and what would reduce it. +- One line: this is a qualitative read; no simulation was run. diff --git a/assets/skills/schedule-basis.md b/assets/skills/schedule-basis.md new file mode 100644 index 0000000..bedbb58 --- /dev/null +++ b/assets/skills/schedule-basis.md @@ -0,0 +1,79 @@ +--- +id: schedule-basis +name: Schedule design and basis +description: Settles purpose, users, detail, WBS, coding, calendars and update cycle before building, and writes the schedule basis document. +request: Help me set up the schedule basis. +use_when: The user is about to build a schedule and wants to plan its design, or needs a written basis of schedule (scope, assumptions, exclusions, calendars, constraints, critical path, risks). +kind: workflow +order: 270 +examples: +- Write the basis of schedule +- Before we build it, how should this schedule be set up? +- Document the schedule assumptions +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_milestones +- openxer_paths +- openxer_check_schedule +- openxer_apply +--- +# Schedule design and basis + +Two parts: before building, settle how the schedule will be set up; once a +schedule exists, write down the basis it rests on, so anyone reading it +knows what it covers and what it assumes. + +## Ground rules + +- Every count, date and float in the basis comes from a tool result. Never + work one out; the design decisions are the user's words. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- The only write is an optional notebook entry: dry run first, a NEW file, + never overwrite. + +## Part 1: design (one question at a time, with your recommendation) + +1. Purpose: bid, baseline for approval, execution plan, recovery plan. +2. Users: owner, project manager, superintendents, foremen; what each needs + from it. +3. Level of detail: summary, control or field level; a useful rule is an + activity a crew can status within one or two update periods. +4. WBS: by area, system or phase; how deep. +5. Coding: the activity codes the users will filter by (area, discipline, + responsibility, phase). Keep the list short. +6. Calendars: crew workweeks, holidays, 7-day items, weather time. +7. Update cycle: weekly or monthly, data date day, who reports progress. +8. Key dates: contract milestones, access and outage windows. + +Write the decisions as a short design note in your answer. + +## Part 2: the basis (once the schedule exists) + +1. Settle the file and project (`openxer_inspect` for several). +2. Gather: `openxer_schedule_stats` (activities, calendars, durations, + WBS), `openxer_milestones` (dates, constraints), `openxer_paths` (what + drives the finish), `openxer_check_schedule` (open ends, constraints). +3. Ask the user, one question at a time, what the tools cannot know: scope + included, scope excluded (owner-supplied items, shop work, work by + others), assumptions (productivity, access, deliveries, permits), and + the risks they see. +4. Write the basis with these sections: purpose and use; scope covered; + exclusions; assumptions; calendars (from the stats); key dates and + constraints (from the milestones, each with why it is held); critical + path summary (from the paths, in field words); known risks; update + cycle. +5. If the user wants it kept in the schedule, add it as a notebook on the + first milestone with `openxer_apply` `set_notebook` (dry run, then a NEW + file). + +## Do not + +Do not invent assumptions or exclusions; ask. Do not state a date the +tools did not return. + +## Answer + +The design note (part 1) or the basis document (part 2), in the sections +above, short enough to read in five minutes. diff --git a/assets/skills/schedule-maturity.md b/assets/skills/schedule-maturity.md new file mode 100644 index 0000000..b5ac22d --- /dev/null +++ b/assets/skills/schedule-maturity.md @@ -0,0 +1,68 @@ +--- +id: schedule-maturity +name: Schedule maturity read +description: How developed the schedule is against how well the scope is defined, and how much confidence its dates can carry. +request: How mature is this schedule and how far can we trust its dates? +use_when: The user asks how developed or mature a schedule is, whether it is detailed enough for its purpose, or how much accuracy its dates support. +kind: check +order: 130 +examples: +- Is this schedule detailed enough to commit to? +- How much can we trust these dates at this stage? +- Is this a summary schedule or a real plan? +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_check_schedule +- openxer_paths +- openxer_wbs_summary +--- +# Schedule maturity read + +You judge how developed the schedule is compared with how well the scope is +defined, and say plainly what kind of confidence its dates can carry. This +is a judgement, not a measurement: say so. You only read. + +## Ground rules + +- Every count and spread comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Never give a percentage accuracy range as if measured. Describe + confidence in words (rough order, planning level, commitment level) and + why. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). +2. Ask the user, one question at a time: how complete is the design (idea, + early design, mostly designed, issued for construction); what the + schedule will be used for (a go or no-go, a bid, a contract baseline, + field execution). +3. Gather: `openxer_schedule_stats` (activity count, duration spread, + names, WBS levels, resources), `openxer_wbs_summary` (level 2), + `openxer_check_schedule` (logic completeness), `openxer_paths` (whether + the critical path is a chain of real work). +4. Read the signs of development: + - Detail: a few long activities per area, or activities a crew can + status? (median and longest durations, activities per WBS element) + - Logic: is every activity tied (Logic check), or are there many open + ends and constraints? + - Critical path: real work in sequence, or summary bars and constraints? + - Resources: loaded or not. + - Names: repeated or one-word names suggest placeholders. +5. Compare with the scope definition the user gave. A detailed schedule on + an early design looks precise but is not; a summary schedule on a + finished design is under-developed for execution. + +## Do not + +Do not quote a numeric accuracy range as fact. Do not change anything. + +## Answer + +- One line: the maturity in plain words and what the dates can be used + for. +- The evidence: detail, logic, critical path, resources, names, each one + line with the number from the tools. +- What would raise confidence next, in order. diff --git a/assets/skills/schedule-review.md b/assets/skills/schedule-review.md new file mode 100644 index 0000000..aaca1f3 --- /dev/null +++ b/assets/skills/schedule-review.md @@ -0,0 +1,96 @@ +--- +id: schedule-review +name: Schedule review +description: A senior scheduler's fresh-eyes read of the whole schedule: logic, critical path, progress, where time hides, risks, ranked by consequence. +request: Review this schedule with fresh eyes. +use_when: The user asks for a schedule review, a second opinion, a senior scheduler's look, whether an update is acceptable, whether the finish is realistic, where time is hiding or what they are missing. +kind: check +order: 20 +examples: +- Review this schedule +- Give me a second opinion +- Is the finish date realistic? +- Where is time hiding? +- What am I missing? +tools: +- openxer_inspect +- openxer_check_schedule +- openxer_paths +- openxer_milestones +- openxer_compare +- openxer_schedule_stats +- openxer_lookahead +- openxer_load +--- +# Schedule review + +You are giving the user a senior scheduler's read: can the dates be trusted, +does the sequence make sense in the field, is the progress believable, where +is time hiding, and what could go wrong, ranked by consequence. You only +read. The tools give the numbers; your job is judgement on top of them. + +## Ground rules + +- Every count, date, float and percent comes from a tool result. Never work + one out yourself. +- Plain words. Never say where this review or its method comes from, and + never mention how this skill was written. +- Dates and float are as last scheduled and stored in the file. + +## Steps + +1. Settle the file and project (ask for the path; `openxer_inspect` when + there are several projects). Ask one question if it is not clear: is + this a first baseline for approval or an update? For a first baseline, + the stricter "Baseline schedule review" skill fits better; offer it. +2. Gather before judging: + - `openxer_check_schedule`: the network's health. + - `openxer_paths` (no activity): what drives the finish, how close path + 2 is, the critical counts. + - `openxer_milestones`: each milestone's date, float and driver. + - `openxer_compare` with `baseline` `project` for a workspace project; + if it says there is none, ask whether there is an earlier file to + compare with, and use `reference`. If there is nothing, say the + progress review was not possible. + - `openxer_schedule_stats`: durations, calendars, WBS. +3. Judge under these headings: + - Critical path: does path 1 come from logic, or from a constraint, a + long lag or an open start? Is it plausible that this chain drives the + finish? How many activities sit at zero or negative float? + - Sequence: does the order of work make sense in the field (access, + trades stacking, inspections, cure, deliveries before install)? Point + at specific activities by ID. + - Progress (updates): actual dates rewritten, status going back, + remaining duration growing on work in progress, out-of-sequence + progress, a finish that holds while milestones slip. + - Where time hides: large float from missing successors, long lags + standing for work, a must finish date far past the scheduled finish, + a near-critical path that would take over with a small slip. + - Risks: few paths with room, merge points, long-lead items on path 1, + hard constraints, work on calendars that do not match the crews. +4. Rank every finding by its consequence to the key dates. Mark each as + "correct before accepting" (makes the dates or float untrustworthy) or + "comment" (improves it). Say why. + +## Ask + +One question at a time: baseline or update, which file to compare with, +whether a constraint or lag is deliberate. + +## Do not + +- Do not change anything or propose fixes on your own. After the write-up + you may offer to propose a fix for one finding. +- Do not soften a finding the numbers support, and do not invent one they + do not. + +## Answer + +- Two lines: would you accept it as it is (or what must change first), and + the finding that matters most. +- Basis: baseline or update, data date, what it was compared with, what + could not be checked. +- Correct before accepting: worst first, one finding per line with the + evidence (Activity ID, name, the number from the tool) and why it matters. +- Comments, the same way. +- What looks sound, in one or two lines. diff --git a/assets/skills/sequence-review.md b/assets/skills/sequence-review.md new file mode 100644 index 0000000..b6a6c3b --- /dev/null +++ b/assets/skills/sequence-review.md @@ -0,0 +1,71 @@ +--- +id: sequence-review +name: Constructability and sequence review +description: Does the sequence match how the work is physically built: access, the predecessors a superintendent expects, trade stacking. +request: Check whether the sequence makes sense in the field. +use_when: The user asks whether the work can be built in this order, about access, trade stacking, missing steps, or whether a superintendent would agree with the sequence. +kind: check +order: 170 +examples: +- Would a superintendent buy this sequence? +- Can we really build it in this order? +- Are trades stacked on top of each other? +tools: +- openxer_inspect +- openxer_load +- openxer_paths +- openxer_lookahead +- openxer_wbs_summary +--- +# Constructability and sequence review + +You walk the sequence as a superintendent would and look for work that +cannot happen in the order shown: missing access, missing steps, trades on +top of each other. Much of this needs the user's knowledge of the site, so +you ask. You only read. + +## Ground rules + +- Every date and float comes from a tool result. Never work one out. +- Field words. Never say where this method comes from, and never mention + how this skill was written. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). Ask which + area to start with; a whole job is reviewed area by area. +2. Read the area: `openxer_wbs_summary` (level 2 or 3) for its span, and + `openxer_load` for its activities and ties (page with offsets). + `openxer_paths` shows whether the area drives the finish. +3. Walk the work in order and check the expected predecessors, for example: + - excavation before foundations, cure before loading, backfill after + inspections; + - steel erected before equipment set on it; equipment set before piping + and conduit connect to it; grout before alignment; + - piping installed before hydrotest, hydrotest before insulation and + paint; + - conduit and cable before termination, termination before loop check; + - demolition before installation in each discipline; + - deliveries before installation; permits and outages before tie-ins. + Where a usual predecessor is missing, say which tie you expected. +4. Stacking: with `openxer_lookahead` over the area's busy weeks, look for + many trades in the same area at the same time. Ask whether the space + allows it. +5. Access: ask what limits access (crane, scaffold, roads, shutdowns) and + whether the schedule shows it. +6. Rank by consequence: impossible order on the critical path first. + +## Ask + +One question at a time, area by area: access limits, crane plan, outage +windows, how the crews really sequence a step. + +## Do not + +Do not add or change ties. Offer the "Change interview" skill for fixes. + +## Answer + +- Two lines: the biggest sequence problem and where. +- Per area: missing predecessors (expected tie), stacking, access questions. +- Questions for the superintendent. diff --git a/assets/skills/time-impact.md b/assets/skills/time-impact.md new file mode 100644 index 0000000..47d1ae8 --- /dev/null +++ b/assets/skills/time-impact.md @@ -0,0 +1,83 @@ +--- +id: time-impact +name: Time impact of a change +description: Inserts a fragment for a change or delay into a copy of the current schedule, reschedules, and measures the effect on a milestone, step by step. +request: Measure the time impact of this change on the schedule. +use_when: The user wants to know how much a change, delay or added work will move a milestone or the finish, before it happens, with the steps documented. +kind: workflow +order: 290 +examples: +- How much will the late steel delivery push the finish? +- What is the time impact of change order 7? +- Measure the effect of this owner delay +tools: +- openxer_inspect +- openxer_load +- openxer_milestones +- openxer_paths +- openxer_apply +- openxer_schedule +- openxer_compare +--- +# Time impact of a change + +You measure, looking forward, what a change or delay does to a milestone: +model it as a small fragment of activities, insert it into a copy of the +current schedule, recalculate, and compare with the unimpacted copy. You +document every step so someone else can repeat it. + +This is a planning aid: it shows the calculated effect on the current plan. +It is not a claim, an entitlement finding or a legal analysis, and it says +nothing about who is responsible. Say so in the answer. + +## Ground rules + +- Every date and move comes from a tool result on calculated copies. Never + estimate the effect yourself. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Every write goes to a NEW file; dry run first and show the change list. + The user's file is never changed. + +## Steps + +1. Settle the current schedule (the latest update), the milestone or + finish to measure, and an output folder. +2. **Unimpacted copy**: run `openxer_schedule` on the current file to a NEW + file, with no option changes, so both copies are calculated the same + way. Record its milestone date with `openxer_milestones`. +3. **Fragment**: with the user, one question at a time: the activities + that represent the change or delay (for example "Wait for revised + drawings", "Fabricate added supports", "Install added supports"), their + durations and the basis for each, and where they tie in: what they + follow and which existing activities they hold back. Record the source + of each number (letter, quote, foreman). +4. **Impacted copy**: one `openxer_apply` batch on the unimpacted copy: + `add_activity`, `set_activity` (`original_duration`, `calendar`), + `relationship` adds with `comments` naming the change, and + `{"op":"schedule"}` at the end. Dry run, show the list, then a NEW file. +5. **Measure**: `openxer_compare` with `input` the impacted copy and + `reference` the unimpacted copy: the milestone move, the finish move, the + biggest moves. `openxer_paths` on the impacted copy: is the fragment on + the path to the milestone now? +6. If the milestone does not move, say why from the results (the fragment + had float to the milestone). + +## Ask + +One question at a time: the milestone, each fragment activity and its +basis, each tie. + +## Do not + +Do not change existing durations or logic in the impacted copy other than +inserting the fragment. Do not assign responsibility. + +## Answer + +- One line: the calculated move of the milestone, and that this is a + planning aid, not a claim. +- The steps: files used and written, the fragment (activities, durations, + bases, ties). +- The result: milestone and finish before and after, from the comparison; + whether the fragment now drives it. diff --git a/assets/skills/update-review.md b/assets/skills/update-review.md new file mode 100644 index 0000000..7cc0b17 --- /dev/null +++ b/assets/skills/update-review.md @@ -0,0 +1,84 @@ +--- +id: update-review +name: Update review +description: What changed since the last update or the baseline: dates, progress, logic, durations, constraints, calendars, and why the key dates moved. +request: Review this update against the last one. +use_when: The user asks what changed since the last update or the baseline, to review an update, why the finish or a milestone moved, whether progress or plan changes moved it, or to compare with last period's file. +kind: check +order: 40 +compare: baseline-or-file +examples: +- What changed since last week? +- Why did the finish move? +- Was the slip progress or changes to the plan? +- Review this update before it goes out +tools: +- openxer_inspect +- openxer_compare +- openxer_paths +- openxer_milestones +- openxer_check_schedule +--- +# Update review + +You tell the user what changed between the last accepted schedule (or the +baseline) and this one, and why the key dates moved, in words a +superintendent understands. You only read. The reference file is only read. + +## Ground rules + +- Every date, count, move and float comes from a tool result. Moves from + `openxer_compare` are calendar days: say so. +- Plain words. Never say where this review method comes from, and never + mention how this skill was written. + +## Steps + +1. Settle the reference, one question at a time: last period's file (an + XER or workspace path the user gives) or a stored baseline of a + workspace project (`baseline` `project` or `primary`). Never look for + files yourself and never pass a path the user did not give. +2. Run `openxer_compare`. If it fails because the reference holds several + projects, run `openxer_inspect` on it and ask which. +3. Lead with the dates: `project_finish` then and now, the data dates, and + `milestones_moved`. +4. Explain why, in this order: + - **Progress**: started and finished since; warning signs: actual dates + rewritten, status gone back, remaining duration up on work in + progress. These question whether the progress is credible. + - **Logic changes**: ties added, removed or changed (type or lag). Each one can move + dates; name the biggest by the activities they touch. + - **Durations**: original durations changed. + - **Constraints and calendars** changed. + - **Activities** added, deleted, renamed. +5. Critical path movement: run `openxer_paths` (no activity) on the current + file and, when the user gave a reference file, on that file too. Say + whether path 1 is the same chain, and which activities joined or left + it. +6. Float erosion: from `biggest_finish_moves`, name the activities whose + float fell the most (`total_float_hours_then` and `_now`). Do not + subtract them yourself; quote both values. +7. Run `openxer_check_schedule` on the current file and mention any new + out-of-sequence progress or invalid dates. +8. Against a baseline, the comparison covers every period since it was set, + not one update. Say so. + +## Ask + +One question at a time: which reference, which project in it. + +## Do not + +Do not say who caused a delay. This is a review of what changed, not a +delay claim. Do not change anything. + +## Answer + +- Lead: what moved and the main reason, for example "Finish unchanged; + the permit milestones slipped 26 days, mostly from late progress." +- Dates: data dates, finish then and now, milestones that moved with + Activity ID, name, dates and the move in calendar days. +- One section per kind of change with its count on the heading line and the + top items: before and after. +- Critical path: same or changed, and float erosion. +- One line naming the kinds with no change. diff --git a/assets/skills/weather-nonwork.md b/assets/skills/weather-nonwork.md new file mode 100644 index 0000000..bbe9f73 --- /dev/null +++ b/assets/skills/weather-nonwork.md @@ -0,0 +1,77 @@ +--- +id: weather-nonwork +name: Weather and non-work planning +description: How weather and seasonal non-work time are carried (calendar days or activities) and whether it is believable for the season. +request: Check how weather and non-work time are carried in this schedule. +use_when: The user asks about weather days, rain days, winter shutdown, holidays, seasonal work limits, or whether the schedule allows for bad weather. +kind: check +order: 180 +examples: +- Did we allow for weather? +- Is the winter shutdown in the schedule? +- How many rain days are carried? +tools: +- openxer_inspect +- openxer_schedule_stats +- openxer_load +- openxer_lookahead +--- +# Weather and non-work planning + +You find how the schedule carries time lost to weather and seasonal +non-work, and whether that looks believable for when and where the work +happens. You only read. + +## Ground rules + +- Every count, date and hour comes from a tool result. Never work one out. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- You do not know the local weather. Ask the user what the site normally + loses and when. + +## Ways schedules carry weather + +- **In calendars**: nonwork days put on the calendar for expected bad + weather or seasonal shutdowns. Visible in the calendar exceptions, and + every activity on the calendar waits through them. +- **As activities**: a weather allowance activity or a contingency + activity before a milestone. Visible, but must be tied correctly to hold + anything back. +- **Inside durations**: padding each duration. Invisible, so hard to + manage and to argue about later. +- **Not at all**. + +## Steps + +1. Settle the file and project (`openxer_inspect` for several). Ask where + the site is, what weather usually stops work there and in which months, + and how the contract treats weather. +2. Run `openxer_schedule_stats`: each calendar's nonwork exception dates + and their range, and the activities on it. +3. Run `openxer_load` and look for activities whose names mention weather, + rain, winter, shutdown, allowance or contingency. +4. Judge: + - Is weather carried at all, and how? + - Do the calendar exceptions cover the whole job (`exceptions_from` to + `exceptions_to` against the project dates)? + - Is weather-sensitive work (earthwork, concrete, steel, roofing, + paving, painting outside) on a calendar that carries weather, or on + one that does not? + - Does weather-sensitive work fall in the bad season? Use + `openxer_lookahead` with `from` at the start of that season to list + what is planned then. +5. Rank by consequence: weather-sensitive critical work in the bad season + with nothing carried first. + +## Do not + +Do not add weather days or change calendars. Do not claim a number of +weather days is right; compare with what the user says the site loses. + +## Answer + +- Two lines: how weather is carried and the biggest gap. +- Calendars: nonwork dates carried and their range. +- Weather-sensitive work in the bad season and how it is protected. +- Questions for the user. diff --git a/assets/skills/what-if.md b/assets/skills/what-if.md new file mode 100644 index 0000000..94bd3b8 --- /dev/null +++ b/assets/skills/what-if.md @@ -0,0 +1,78 @@ +--- +id: what-if +name: What-if options +description: Tries one lever at a time on a copy (logic, durations, calendars, resources) and compares each against the current plan. +request: Show me some what-if options for the finish. +use_when: The user asks "what if" questions, wants to test an idea on the schedule, or wants options to pull a date in without committing to one. +kind: workflow +order: 230 +examples: +- What if we work Saturdays on the steel? +- What if the transformer comes two weeks late? +- Try overlapping the piping and the electrical +tools: +- openxer_paths +- openxer_milestones +- openxer_load +- openxer_apply +- openxer_schedule +- openxer_compare +- openxer_copy_calendar +- openxer_calendar_weekday +--- +# What-if options + +You test ideas on copies of the schedule, one lever at a time, and compare +each with the current plan, so the user sees the effect and the cost of +each before choosing. + +## Ground rules + +- Every date and move comes from a tool result, measured on the calculated + copy. Never estimate an effect yourself. +- Plain words. Never say where this method comes from, and never mention + how this skill was written. +- Every option is a NEW file. The user's file is never changed. Dry run + each batch first and show its change list. +- No lever is free. With each result, say what it costs or risks: + overtime and fatigue, crew stacking, extra cranes, access conflicts, + quality, a risk moved later. + +## Steps + +1. Settle the file, the target (the finish or a milestone) and how many + options the user wants to see. Ask for an output folder or names for + the copies. +2. Read the current plan: `openxer_paths` for the target (what drives it, + how close path 2 is) and `openxer_milestones`. +3. Agree the levers, one per option. Typical levers: + - Logic: start a successor before its predecessor finishes (a start to + start tie with lag instead of finish to start), resequence areas. + - Durations: more crews or longer days on a path 1 activity. + - Calendars: a 6-day week for some work (`openxer_copy_calendar`, then + `openxer_calendar_weekday`, then `set_activity` `calendar`). + - Resources: add a crew, or level a copy to see the cost of a limit. + - Delays: a later delivery or access date to see its effect. + Only levers on path 1 (or the paths within reach of it) can pull the + target in. Say so when the user picks one off the path. +4. For each option: one `openxer_apply` batch with the change and + `{"op":"schedule"}` at the end, dry run, then to its NEW file. Then + `openxer_compare` the copy (`input`) against the current file + (`reference`), and `openxer_paths` on the copy to see if the driver + changed. +5. Keep options separate. Combine levers only when the user asks, as a new + option. + +## Ask + +One question at a time: the target, the levers, output names. + +## Do not + +Do not present any option as a decision. Do not change the user's file. + +## Answer + +- A table: option, what changed, finish and target move (from the + comparison), new driver, cost or risk. +- One line recommending which options deserve a closer look, and why. diff --git a/automation/COVERAGE.md b/automation/COVERAGE.md new file mode 100644 index 0000000..5fcff63 --- /dev/null +++ b/automation/COVERAGE.md @@ -0,0 +1,135 @@ +# What agents can do: the app mapped to the CLI and MCP + +Every app command that changes project or workspace data, or computes something a user reads, with the way an agent does the same through `openxer-cli` and its MCP server. Operations in the **Operation** column run in an `apply` batch (MCP `openxer_apply`) and through `openxer-cli edit` / `call`; the ones with their own command and tool are named in **CLI** and **MCP**. Edits go through the same functions as the app (`xer/src/edit`), so the results are the same. Rows marked **gap** are not available to agents yet. Pure view preferences (layouts, columns, filters, colors, zoom, toolbars, fonts) change no project data and are left out. + +The desktop test `agent_coverage` (in `desktop/src/agent_coverage.rs`) fails when the app draws a command that is not listed in its registry, and `automation/tests/coverage.rs` fails when an operation or tool is missing from this file, the README or `--help`. Add the mapping (or a gap row here) with every new command. + +## Activities, relationships and assignments + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Read activities, relationships, project options | Activities view | `load` | `openxer_load` | | paged; dates, floats, status, linked documents; `fields`, `activities`, `wbs`, `critical` and `sort` keep the answer small | +| Add, delete an activity | Edit > Add, Delete | `add-activity`, `delete-activity` | `openxer_add_activity`, `openxer_delete_activity` | `add_activity`, `delete_activity` | both take the project's Defaults tab values (types, calendar, 5 day duration); without `activity` the ID comes from the auto-numbering defaults, `selected` standing for the app's selection. In the app Add opens the New Activity wizard unless it is turned off; the activity it makes is the same one with the wizard's choices set on it | +| Activity fields (General, Status tabs, table cells, Fill Down, Replace) | Activity Details, table | `set-activity` | `openxer_set_activity` | `set_activity` | every field in README; also the Status tab units and costs (`budgeted_labor_units`, `actual_nonlabor_cost`, `this_period_labor_units`, ...), and At Complete units and costs (`at_completion_labor_units`, `at_completion_labor_cost`: the remaining becomes it less the actual) | +| Relationships (tabs, Assign Predecessors/Successors, Link/Unlink, Gantt and network drag) | Relationships tab, Edit menu | `relationship` | `openxer_relationship` | `relationship` | with lag and comments | +| Resource assignments | Resources tab, Edit > Assign > Resources | `assign`, `unassign`, `set-assignment` | `openxer_assign`, `openxer_unassign`, `openxer_set_assignment` | `assign_resource`, `remove_assignment`, `set_assignment` | units, costs (`budgeted_cost`, `actual_cost`, `remaining_cost`), At Completion (`at_completion_units`, `at_completion_cost`: the remaining takes it less the actual), Rate Source (`rate_source`: resource, role, override), Cost Units Linked (`calculate_costs_from_units`), rates, lags, curve, durations, drive dates, `resource` (replace), `role`, `cost_account`; milestones take none (`milestone_assignment`) | +| Activity codes | Codes tab, Assign > Activity Codes | | | `set_activity_code` | one value per code type; Assign with several values of one type selected takes the first, as `set_activity_code` replaces the value | +| Notebook topics | Notebook tab | | | `set_notebook` | | +| User defined field values | UDF tab; User Defined columns of the WBS, Projects, Resources and Resource Assignments windows and of the Expenses, Issues, Risks and WPs & Docs views | | | `set_udf` | every subject area: activities, resources, assignments, steps, WBS, the project, expenses, issues, risks, documents | +| Steps | Steps tab | `add-step`, `set-step`, `delete-step`, `move-step` | `openxer_add_step`, `openxer_set_step`, `openxer_delete_step`, `openxer_move_step` | `add_step`, `set_step`, `delete_step`, `move_step` | steps drive physical % when the project says so | +| Step templates on an activity | Steps tab: Add from Template, Create Template; Assign > Steps for several activities | `add-steps-from-template`, `create-step-template` | `openxer_add_steps_from_template`, `openxer_create_step_template` | `add_steps_from_template`, `create_step_template` | `after` names the step they go in after (else after the last step); several activities take one operation each in one batch | +| Feedback: notes to resources, review flag | Feedback tab | `set-feedback` | `openxer_set_feedback` | `set_feedback` | resource feedback itself comes from timesheets | +| Expenses | Expenses tab and view | `add-expense`, `set-expense`, `delete-expense` | `openxer_add_expense`, `openxer_set_expense`, `openxer_delete_expense` | `add_expense`, `set_expense`, `delete_expense` | read with `records --kind expenses` | +| Risks on an activity | Risks tab | `assign-risk`, `unassign-risk` | `openxer_assign_risk`, `openxer_unassign_risk` | `assign_risk`, `unassign_risk` | | +| Documents on an activity | WPs & Docs tab | `link-document`, `unlink-document` | `openxer_link_document`, `openxer_unlink_document` | `link_document`, `unlink_document` | | +| Typed period units (Manual curve) | Resource Usage Spreadsheet cells, Fill Down, Fill Across, Range Paste; Resources tab Curve cleared | `set-assignment --field period_remaining_units --value DATE[,DATE]=UNITS` | `openxer_set_assignment` | `set_assignment` field `period_remaining_units` (`curve` null removes the typed values) | **gap**: typed budgeted or actual period units (not observed) | +| Resource curves | Resources tab, Enterprise > Resource Curves | `curves` | `openxer_curves` | `set_assignment` field `curve` | **gap**: adding or editing a curve's points | +| Resource and activity usage (time-phased units and costs) | Activity Usage Profile and Spreadsheet, Resource Usage Profile and Spreadsheet (bottom panes) | `usage` | `openxer_usage` | | read only; same spreads as the views, curves applied | +| Cut and paste activities in their own project (a move to the target's WBS) | Edit > Cut, Paste | `set-activity` | `openxer_set_activity` | `set_activity` field `wbs` | the move keeps the Activity ID, relationships and child rows | +| Copy and paste activities | Edit > Copy, Paste | | | | **gap**: paste with child rows and the Renumber Activity IDs and Duplicates steps that give the copies their IDs (pure, `desktop/src/editing/ops.rs`: `paste_ids`, `paste_conflicts`, `paste_renumbered`); also moving activities to another project (Cut and Paste between open projects in the app) | +| Dissolve | Edit > Dissolve | `dissolve-activity` | `openxer_dissolve_activity` | `dissolve_activity` | `retain_lag` is the app's User Preferences, Calculations, Retain Lag (default off); one activity per operation | +| Renumber Activity IDs | Edit > Renumber | | | `set_activity` field `activity_id` | the numbering plan is a **gap**; stored baselines are not renumbered | +| Assign by role, role only | Edit > Assign > Resources by Role, Roles | | | | **gap** (the setter takes a role) | +| Gantt bar drag | Gantt | | | `set_activity` `start`, `original_duration` | | +| Activity critical path through one activity | View > Activity Critical Path | | | | **gap** (pure, `desktop/src/critical_path.rs`) | +| Summary tab | Activity Details | `load`, `earned-value` | `openxer_load`, `openxer_earned_value` | | | + +## Project, WBS and registers + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Data date, Must Finish By | Project details (Dates tab), F9 | `set-project`, `schedule` | `openxer_set_project`, `openxer_schedule` | `set_project` | the data date goes through `xer::edit::project_dates::set_data_date`, as the Dates tab does, and schedules nothing unless `schedule` is true | +| Project details: General, Defaults, Resources, Settings, Calculations | Projects view | | | `set_project` (a PROJECT column) | values written as given; planned start is `plan_start_date`; the Defaults tab is `def_duration_type`, `def_complete_pct_type`, `def_task_type`, `acct_id`, `clndr_id`, `task_code_prefix`, `task_code_base`, `task_code_step`, `task_code_prefix_flag`; Define Critical Activities on the Settings tab is `critical_path_type` (`CT_TotFloat` or `CT_DrivPath`) and `critical_drtn_hr_cnt` (hours), the desktop writes every tab through the same `xer::edit::tables::set_project_field` | +| Schedule options | Tools > Schedule > Options | `schedule --options` | `openxer_schedule` | `set_schedule_option`, `schedule` | | +| Project funding | Projects view Funding tab | | | `add_project_funding`, `set_project_funding`, `delete_project_funding` | | +| Add WBS elements | WBS view Add | `add-wbs` | `openxer_add_wbs` | `add_wbs` | by code path | +| WBS fields (name, status, manager, dates) | WBS details; WBS table Replace (names); Projects table Fill Down (Project Name: the project node's name) | | | `set_wbs` (a PROJWBS column; `wbs` `""` is the project node) | manager by `obs_id`; the desktop writes the project name through `xer::edit::wbs::set_project_name` | +| WBS earned value techniques | WBS details Earned Value | | | `set_wbs_earned_value` | | +| WBS and project notebooks | WBS details Notebook, Project details Notebook (Add, Delete, Modify with its formatting toolbar) | | | `set_wbs_notebook` | `""` is the project node; the text is HTML as stored, which the app writes with bold, italic, underline and lists | +| Project codes on a project | Project details Codes tab (Assign, Remove) | | | `set_project_code` | one value per code type, as the app assigns them; the Project Codes dictionary itself is a **gap** | +| Move a WBS element | WBS view Shift up/down/left/right | `shift-wbs` | `openxer_shift_wbs` | `shift_wbs` | | +| WBS code | WBS details General | `rename-wbs-code` | `openxer_rename_wbs_code` | `rename_wbs_code` | unique among siblings | +| Cut, copy, paste, delete or merge WBS elements | WBS view | | | | **gap** (pure, `desktop/src/views/wbs.rs`; a copy with its notebook, milestones and documents is `xer::edit::wbs::copy_subtree`; with its activities, Copy WBS Options in `desktop/src/views/wbs_copy.rs`, which needs the activity paste of `desktop/src/editing/ops.rs`, see "Copy and paste activities") | +| Budget log, spending plan, WBS milestones | WBS and project details | | | | **gap** (pure, `desktop/src/views/budget.rs`) | +| Issues | Project > Issues | `records`, `add-issue`, `set-issue`, `delete-issue` | `openxer_records`, `openxer_add_issue`, `openxer_set_issue`, `openxer_delete_issue` | `add_issue`, `set_issue`, `delete_issue` | issue history is read only | +| Risks | Project > Risks | `records`, `add-risk`, `set-risk`, `delete-risk` | `openxer_records`, `openxer_add_risk`, `openxer_set_risk`, `openxer_delete_risk` | `add_risk`, `set_risk`, `delete_risk` | | +| Thresholds | Project > Thresholds | `records`, `add-threshold`, `set-threshold`, `delete-threshold` | `openxer_records`, `openxer_add_threshold`, `openxer_set_threshold`, `openxer_delete_threshold` | `add_threshold`, `set_threshold`, `delete_threshold` | | +| Monitor Thresholds | Tools > Monitor Thresholds, Thresholds view Monitor | `monitor-thresholds` | `openxer_monitor_thresholds` | `monitor_thresholds` | assigned baselines read from the workspace | +| Work products, documents | Project > WPs & Docs | `documents`, `read-document`, `add-document`, `set-document`, `delete-document` | `openxer_documents`, `openxer_read_document`, `openxer_add_document`, `openxer_set_document`, `openxer_delete_document` | `add_document`, `set_document`, `delete_document` | document UDF values through `set_udf` (`document`) | +| Earned value figures | EV columns, WBS and project bands | `earned-value` | `openxer_earned_value` | | planned value follows resource curves as the columns do (`xer/src/ev.rs`) | +| Baselines: list, add (copy or convert), copy, delete, restore, Baseline ID, name and type | Project > Maintain Baselines | `baseline list`, `baseline add`, `baseline convert`, `baseline copy`, `baseline delete`, `baseline restore`, `baseline set` | `openxer_baseline_list`, `openxer_baseline_edit` | | the app's rules (`automation/src/baseline_ops.rs`); delete and restore refuse an assigned baseline; restore files the new project in the owner's EPS folder | +| Assign Baselines (project, primary, secondary, tertiary) | Project > Assign Baselines | `baseline assign` | `openxer_baseline_edit` | | the project baseline is the project's `sum_base_proj_id`; the user baselines live in the workspace | +| Revert Project to Baseline | Project > Revert Project to Baseline | `baseline revert` | `openxer_baseline_edit` | | the project takes the baseline's data and keeps its ID, name and baselines | +| Update a baseline from the project (options, Preview, Update, Last Update Date) | Maintain Baselines > Update... (Update Baseline, Preview Changes) | `baseline update` (`--dry-run true` returns the preview) | `openxer_baseline_update` | | the app's rules (`automation/src/baseline_ops.rs` `update`, engine `interchange/src/baseline_update.rs`); every option of the dialog by name, defaults as the dialog's; activities matched by GUID, then Activity ID; **gap**: a saved filter is evaluated by the app only, the CLI takes the Activity IDs (`activities`); Compare all records and Run optimized are accepted and have no effect | + +## Tools + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Schedule (F9), level resources | Tools > Schedule, Level Resources | `schedule` | `openxer_schedule` | `schedule` | leveling options through `set_schedule_option`; the leveling log is a **gap** | +| Update Progress | Tools > Update Progress | `update-progress` | `openxer_update_progress` | `update_progress` | all or named activities; flagged expenses of what it progresses are spent; **gap**: the spotlight's highlight is the app's (the CLI takes Activity IDs) | +| Apply Actuals | Tools > Apply Actuals | `apply-actuals` | `openxer_apply_actuals` | `apply_actuals` | the shared rules (`xer/src/edit/progress.rs`): activity, resource and expense Auto Compute Actuals flags, assignment units and costs, actual this period; one data date for the project (the app's per-project dates are one call per project) | +| Auto Compute Actuals on an activity | Activities table, General column Auto Compute Actuals (check box) | `set-activity` field `auto_compute_actuals` | `openxer_set_activity` | `set_activity` | the app's cell is the shared activity edit `Edit::AutoComputeActuals` | +| Recalculate actual units and cost when duration % changes | Projects, Calculations tab | `set-project` field `act_pct_link_flag` | **gap**: `openxer_set_project` takes only the data date and must finish | `set_project` | read by every Duration % edit (`xer/src/edit/activity.rs`, so `set-activity` `duration_percent_complete` follows it), on in a new project | +| Recalculate Assignment Costs | Tools > Recalculate Assignment Costs | `recalculate-costs` | `openxer_recalculate_costs` | `recalculate_costs` | the current project | +| Top Down Estimation | Tools > Top Down Estimation | `top-down-estimate` | `openxer_top_down_estimate` | `top_down_estimate` | | +| Store Period Performance | Tools > Store Period Performance | | | | **gap** (pure, `desktop/src/enterprise/ops.rs`) | +| Global Change | Tools > Global Change (Modify Global Change, Global Change Report) | `global-change` | `openxer_global_change` | `global_change` | a definition saved in the workspace input (`name`) or given as `rule`; the same definitions, If evaluation (All or Any, "is under" for WBS and activity codes), Then and Else statements (user defined fields included) and writes as the app (`xer/src/edit/global_change.rs` over the shared field catalog `xer/src/fields/`); a dry run returns the report lines (activity, field, old, new, exception), otherwise the lines without an exception are written and counted. Started from an Activities view, the app changes only the activities its filter shows; an agent puts those activities in the If rows (there is no window filter outside the app). Relative dates in If values (the app's filter keywords) and the table-only columns (baselines, earned value and the other derived columns, notebook topics, relationship details) are a **gap** outside the app | +| Check Schedule | Tools > Check Schedule | `check-schedule` | `openxer_check_schedule` | | the results rows with the default or given hour thresholds, and one row's Activity IDs or relationships; the same rules as the dialog (`xer/src/schedule_check.rs`); Late Activities and BEI compare with the workspace's assigned project baseline (or the project's own dates when there is none); writing the HTML report is a **gap** | +| Project Checker | Tools > Project Checker | | | | **gap** (pure, `desktop/src/reports/checker.rs`) | +| Schedule Comparison | Tools > Schedule Comparison | `compare` | `openxer_compare` | | **gap**: which activities match, were added or deleted, and the logic changes are one shared core (`xer/src/compare.rs`) the app and `compare` both call; the field-by-field changes are still read twice: the app through its column display (every column, per-area choices, report formats), `compare` directly from the project for dates, durations, constraints, calendars, names and progress | +| Float paths into an activity | View > Activity Critical Path | `paths` | `openxer_paths` | | the scheduler's multiple float paths ending at the activity (or the project finish), with the gap behind path 1, merge points and the critical counts | +| Look-ahead | the 3-Week Lookahead filter and layout | `lookahead` | `openxer_lookahead` | | read only; each activity in the window is in progress, ready or waiting, with what on | +| Milestones, schedule statistics, resource loading, WBS rollup | Activities view columns and bands, usage profiles | `milestones`, `schedule-stats`, `resource-loading`, `wbs-summary` | `openxer_milestones`, `openxer_schedule_stats`, `openxer_resource_loading`, `openxer_wbs_summary` | | read only; numbers the agent skills report so an agent never computes them | +| Skills for AI agents | AI Agents > Skills | `skills list`, `skills show`, `skills validate`, `skills new`, `skills path` | `openxer_skills`, `openxer_skill`, MCP prompts | | built-ins from `assets/skills/`, the user's from `\skills\` | +| S-curve export | Tools > Reports > S-Curve | `export-scurve` | `openxer_export_scurve` | | same figures and workbook as the app (`xer/src/scurve.rs`, `interchange/src/scurve_xlsx.rs`); the app can also limit it to the current activity filter | +| Cumulative earned hours export | Tools > Reports > Earned Hours | `export-earned-hours` | `openxer_export_earned_hours` | | same figures and workbook as the app | +| Reports, report wizard, report groups, batch reports | Tools > Reports | | | | **gap**: the report engine runs on desktop lookups; definitions live in the workspace | +| Circular relationship analysis | after F9 | | | `relationship` to fix | the analysis is a **gap** (pure, `desktop/src/loops/analysis.rs`) | +| Print | File > Print | `export-pdf` | `openxer_export_pdf` | | runs the desktop renderer headless | + +## Import, export and the workspace + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Find the user's schedules (the workspace and its projects, a folder's XER files) | File > Recent Projects | `find-schedules` | `openxer_find_schedules` | | read only; for an agent not given a file | +| Inspect a file or workspace | | `inspect` | `openxer_inspect` | | | +| Import XER (new, update, replace, per-type actions) | File > Import | `import` | `openxer_import` | | undo last import is a **gap** | +| Import project XML | File > Import, Project - (XML) | `import` (XML input, `--format`) | `openxer_import` (`format`) | | same actions as XER; read into the same tables, including UDF values, notebook topics and notes, resource codes, OBS, currencies and schedule options; checked against an export of the reference; `inspect` lists the element types and fields it skips | +| Export XER | File > Export | `export` | `openxer_export` | | export with stored baselines is a **gap** | +| Export project XML | File > Export, Project - (XML) | `export --format xml` (or a `.xml` output) | `openxer_export` (`format`) | | writes the structure of the reference's export (root, child order, value forms); not yet opened in the reference; export with stored baselines is a **gap**, as for XER | +| Excel export and import | File > Export, Import | `export-xlsx`, `import-xlsx` | `openxer_export_xlsx`, `openxer_import_xlsx` | | saving export templates is a **gap** | +| Move to a shared workspace dictionary (schema 3), or upgrade an earlier schema 2 | Admin > Share Dictionaries Across Projects (opening upgrades schema 2) | `workspace migrate` | `openxer_workspace_migrate` | | the CLI writes a migrated copy; the app converts in place after a backup | +| List the shared workspace dictionary and its uses | | `workspace dictionary`, `workspace dictionary-usage` | `openxer_workspace_dictionary`, `openxer_workspace_dictionary_usage` | | read only | +| New Activity and New Resource wizards on or off | Edit > User Preferences, Assistance, Add activities through the wizard and Add resources through the wizard; each wizard's own "Skip this wizard next time" | `workspace preference` | `openxer_workspace_preference` | | reads the switches, or writes a copy of the workspace with `new_activity_wizard` or `new_resource_wizard` set; the app reads them at start. The wizards themselves are the app's: agents add activities with `add_activity` and resources with `add_resource`, then set their fields | +| EPS folders, filing, a new project | Enterprise > EPS, File > New, Projects view | `eps list`, `eps ...` | `openxer_eps_list`, `openxer_eps_edit` | | a new project gets an internal project number no workspace project or baseline uses (`baseline_store::next_project_number`), as File > New, Paste and baseline restore do; EPS responsible manager and sibling order are a **gap** | +| Delete an EPS folder with the folders and projects under it (and their baselines) | Enterprise > EPS > Delete, Projects view Delete on a folder row | `eps delete-folder --delete-projects` | `openxer_eps_edit` (`delete_folder`, `delete_projects`) | | a folder holding projects is refused without the flag; `--dry-run` counts what goes; the app's Undo has no CLI counterpart, the untouched input is the way back | +| Copy or delete a project | Projects view | | | | **gap** | + +## Enterprise and admin dictionaries + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Resources: add, fields, parent, calendar, delete, merge | Enterprise > Resources; Resources table Fill Down and Replace (ID, name) | | | `add_resource`, `set_resource`, `delete_resource`, `merge_resources` | copy/paste a resource is a **gap** | +| Resource prices and limits | Resources view Units & Prices | | | `set_resource_limit` | | +| Resource roles and codes | Resources view Roles, Codes tabs | | | | **gap** (pure, `desktop/src/views/resource_edit.rs`) | +| Calendars: work weeks and exceptions | Enterprise > Calendars | `calendar-day`, `calendar-weekday` | `openxer_calendar_day`, `openxer_calendar_weekday` | `calendar_day`, `calendar_weekday` | | +| Calendars: add, copy, rename, default, convert, delete, fields | Enterprise > Calendars | `copy-calendar`, `rename-calendar`, `set-default-calendar`, `convert-calendar` | `openxer_copy_calendar`, `openxer_rename_calendar`, `openxer_set_default_calendar`, `openxer_convert_calendar` | `add_calendar`, `copy_calendar`, `rename_calendar`, `set_default_calendar`, `convert_calendar`, `delete_calendar`, `set_calendar` | `set_calendar` writes hours per period and other columns as given; `delete_calendar` with `replacement` or `default_global` is the Calendars in Use choice (Select Replacement Calendar, Use Default Global Calendar) | +| Activity codes dictionary | Enterprise > Activity Codes; Assign Activity Codes, New... (Add Code Value) | | | `add_code_type`, `add_code_value`, `set_code_value`, `delete_code_value` | renaming, reordering or deleting a code type is a **gap** | +| Project, resource, role and assignment codes | Enterprise menu | | | | **gap** (pure, `desktop/src/dictionaries/ops.rs`) | +| User defined fields dictionary | Enterprise > User Defined Fields | | | | **gap**; values are covered by `set_udf` | +| Roles, OBS, shifts, funding sources, cost accounts, step templates dictionary | Enterprise menu | | | | **gap** (pure, `desktop/src/enterprise/ops.rs`, `dictionaries/ops.rs`, `dictionaries/steps.rs`) | +| Financial periods: delete | Admin > Financial Period Calendars, Delete Period | `apply` | `openxer_apply` | `delete_financial_period` | refused, nothing changed, while stored period performance refers to the period (`xer/src/edit/financial_periods.rs`, shared with the app) | +| Admin categories, currencies, financial period calendars, adding and renaming periods, Batch Create | Admin menu | | | | **gap** (pure) | + +## The Chat window + +| Feature | App | CLI | MCP | Operation | Notes | +| --- | --- | --- | --- | --- | --- | +| Ask about the open project | Chat window (Ask) | `mcp --toolset chat --mode ask` | `openxer_load`, `openxer_records`, `openxer_earned_value`, `openxer_usage`, `openxer_documents`, `openxer_check_schedule`, `openxer_playbook` | | the chat tool set (`automation/src/chat_tools.rs`): the same tools with short descriptions, the snapshot as input, results under 40,000 bytes; hosted agents run through `automation/src/agent_host/` | +| Scheduling methods (build, update, audit, critical path, delay recovery, schedule check) | Chat window | `playbook` | `openxer_playbook` | | step-by-step playbooks the assistant loads when needed (`assets/playbooks/`); the chat's instructions are `chat_prompt::system_prompt`, with the user's own `chat\AGENTS.md` in the data folder | +| Propose edits to the open project | Chat window (Edit) | `mcp --toolset chat --mode edit` | `openxer_apply` (propose only) | any `apply` batch | always a dry run on the snapshot; the app applies an approved batch to the open project with `edit::apply_changes` | + +## Not for agents + +Open, save, close, undo and redo, the clipboard, Refresh, Exit, Select All, Find, Spell Check, Set Default Project, user preferences (except the Assistance switches above), the AI Agents menu and Help belong to the running app (the menu's config work is `openxer-cli connect`, and its Copy Setup Prompt is `connect prompt`): every automation command reads its input and writes a new output, and agents use the edits above. diff --git a/automation/Cargo.toml b/automation/Cargo.toml new file mode 100644 index 0000000..92e9537 --- /dev/null +++ b/automation/Cargo.toml @@ -0,0 +1,30 @@ +[package] +name = "openxer-automation" +version.workspace = true +edition.workspace = true +license.workspace = true +publish.workspace = true + +[[bin]] +name = "openxer-cli" +path = "src/main.rs" + +[dependencies] +openxer-engine = { path = "../engine" } +openxer-xer = { path = "../xer" } +openxer-interchange = { path = "../interchange" } +chrono = { version = "0.4.42", default-features = false, features = ["std", "clock"] } +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +rusqlite = { version = "=0.37.0", features = ["bundled", "backup"] } +tempfile = "3.27" +toml_edit = "=0.25.18" +# Reading the text of document files: docx is a zip of XML (the same +# versions the spreadsheet reader already uses); PDF text page by page. +zip = { version = "9.3.0", default-features = false, features = ["deflate"] } +quick-xml = { version = "0.42.0", features = ["encoding"] } +pdf-extract = "=0.12.1" +encoding_rs = "0.8.35" + +[dev-dependencies] +rust_xlsxwriter = { version = "=0.102.0", default-features = false } diff --git a/automation/README.md b/automation/README.md new file mode 100644 index 0000000..ebd87ba --- /dev/null +++ b/automation/README.md @@ -0,0 +1,670 @@ +# OpenXER automation + +`openxer-cli.exe` gives native scheduling and editing through a command line and an MCP stdio server. Both call the same `openxer-automation` dispatcher, which uses the `openxer-xer` edit layer and the `openxer-engine` scheduler. Edits go through the same setters as the desktop app, so the app, the CLI and MCP always give the same result. No Python runtime and no other scheduling application is needed. + +Inputs are XER files or OpenXER workspace databases (`.db`, `.sqlite`, `.sqlite3`). Reads never change the input. Every command that changes or exports data needs an explicit **new** output path; an existing destination is refused. Output is prepared in the destination folder and published without overwriting another file. + +## Contents + +- [CLI](#cli) +- [Editing: apply and the single edits](#editing-apply-and-the-single-edits) +- [Scheduling](#scheduling) +- [Relationships](#relationships) +- [Import, export, Excel and PDF](#import-export-excel-and-pdf) +- [Documents](#documents) +- [Expenses, issues, risks and thresholds](#expenses-issues-risks-and-thresholds) +- [Earned value](#earned-value) +- [Progress, steps and the Tools edits](#progress-steps-and-the-tools-edits) +- [Global Change](#global-change) +- [Schedule analysis](#schedule-analysis) +- [Skills for AI agents](#skills-for-ai-agents) +- [Coverage map](COVERAGE.md) +- [Project folders (EPS) and rollups](#project-folders-eps-and-rollups) +- [Baselines](#baselines) +- [JSON contract](#json-contract) +- [MCP](#mcp) +- [Chat agent host](#chat-agent-host) +- [In-process use and tests](#in-process-use-and-tests) + +## CLI + +Build from the repository root with `cargo build --release -p openxer-automation`. The Windows release package puts `openxer-cli.exe` beside `OpenXER.exe`. + +```powershell +.\openxer-cli.exe inspect --input C:\Schedules\plan.xer +.\openxer-cli.exe import --input C:\Schedules\plan.xer --output C:\Schedules\workspace.db +.\openxer-cli.exe load --input C:\Schedules\workspace.db --project 101 --offset 0 --limit 200 +.\openxer-cli.exe set-activity --input C:\Schedules\workspace.db --project 101 --activity A1010 --field remaining_duration --value 24 --output C:\Schedules\edited.db +.\openxer-cli.exe apply --input C:\Schedules\edited.db --project 101 --changes C:\Schedules\week-14.json --output C:\Schedules\updated.db +.\openxer-cli.exe schedule --input C:\Schedules\updated.db --project 101 --output C:\Schedules\scheduled.db --data-date "2026-04-06 08:00" --level +.\openxer-cli.exe export --input C:\Schedules\scheduled.db --project 101 --output C:\Schedules\scheduled.xer +.\openxer-cli.exe --help +``` + +Commands: + +| Command | What it does | +| --- | --- | +| `find-schedules` | Names the OpenXER workspace on this PC with its projects, most recently saved first, and with `--folder` the schedule files in one folder (read only; see MCP) | +| `inspect` | Lists the projects in a file (read only); for project XML also the element types read (`xml.elements`), the ones OpenXER has no place for and skipped (`xml.unhandled`) and the fields it does not read (`xml.fields_not_read`) | +| `load` | Pages a project's options, activities and relationships (read only) | +| `curves` | Lists the resource curves an assignment can use, with their points (read only) | +| `usage` | An activity's or a resource's assignments spread per day, week or month: budgeted, actual, remaining and remaining late units or costs, with curves (read only) | +| `import` | Imports XER or project XML projects into a new workspace, or into a copy of an existing one | +| `schedule` | Runs the scheduler, with optional resource leveling | +| `relationship add\|update\|remove` | Edits one relationship; dates are kept until the next `schedule` | +| `apply` | Applies a batch of edits (`openxer-changes/1`), all or nothing | +| `set-activity`, `add-activity`, `delete-activity`, `dissolve-activity`, `assign`, `unassign`, `set-assignment`, `calendar-day`, `calendar-weekday`, `set-project`, `add-wbs`, `add-document`, `set-document`, `delete-document`, `link-document`, `unlink-document`, `add-expense`, `set-expense`, `delete-expense`, `add-issue`, `set-issue`, `delete-issue`, `add-risk`, `set-risk`, `delete-risk`, `assign-risk`, `unassign-risk`, `add-threshold`, `set-threshold`, `delete-threshold`, `monitor-thresholds`, `add-step`, `set-step`, `delete-step`, `move-step`, `add-steps-from-template`, `create-step-template`, `set-feedback`, `update-progress`, `apply-actuals`, `recalculate-costs`, `top-down-estimate`, `shift-wbs`, `rename-wbs-code`, `rename-calendar`, `set-default-calendar`, `convert-calendar`, `copy-calendar` | One edit each, the same operations as `apply` | +| `documents` | Lists a project's work products and documents with their links (read only) | +| `read-document` | Returns the text of the file a document points at, paged (read only) | +| `export` | Writes a new XER, or project XML | +| `export-xlsx` | Writes a new Excel workbook | +| `import-xlsx` | Previews or applies a spreadsheet of changes | +| `export-pdf` | Prints a layout to a new PDF | +| `workspace migrate` | Previews (`--dry-run`) or writes (`--output NEW.db`) a copy of a workspace that keeps shared calendars, resources, codes and the other workspace dictionaries once | +| `workspace dictionary` | Lists a workspace's shared dictionary, each row with the projects that use it (read only) | +| `workspace dictionary-usage` | Says which projects use one dictionary row (read only) | +| `workspace preference` | Reads the User Preferences, Assistance switches kept in a workspace (`new_activity_wizard`, on by default, decides whether Edit > Add opens the New Activity wizard; `new_resource_wizard`, on by default, the same for the Resources view's Add and the New Resource wizard), or with `--name` and `--value` writes a copy (`--output NEW.db`) with one set; `--dry-run` previews | +| `call` | Runs one complete JSON request (the same schema as MCP) | +| `mcp` | Serves MCP over stdio | + +`--project` is the project id (the XER `proj_id`); `--workspace-id` is the OpenXER workspace row id, for when project ids repeat. When several rows match, the command refuses the ambiguity instead of choosing one. XER import takes every project unless `--project` is given. + +### Workspaces and the shared dictionary + +A workspace keeps its dictionaries once for all of its projects: global calendars, resources with their rates, roles, global and EPS activity codes with their values, UDFs, cost accounts, responsible managers, currencies, curves, shifts, funding sources and the admin categories (workspace schema 3). Each project's stored text holds only its own rows (its WBS, activities, relationships, assignments, project calendars and project codes); every command that reads a workspace project adds the shared rows back, so `load`, `schedule`, `apply`, the edits and the exports see one whole project, and every command that writes one merges its shared rows back into the dictionary. An edit of a global calendar or a resource through any command therefore reaches every project of the workspace. An EPS activity code is seen by the projects of its EPS node and of the nodes below it; one that comes with an XER file is filed under the importing project's node. `inspect` reports `workspace_schema` and, for schema 3, the dictionary's revision and row counts. New workspaces (`import` to a new file, `save` of an XER to a new `.db`) share their dictionary from the start; a workspace made by an earlier version (schema 1) keeps each project's whole text and is read and written as before until it is converted. A workspace an earlier version gave a shared dictionary without the EPS codes (schema 2) gives `workspace_needs_migration` until `workspace migrate` upgrades it (the app upgrades it in place, after a backup, when it opens it). + +`workspace migrate --input workspace.db --dry-run` converts a schema 1 workspace, or upgrades a schema 2 one: it reports, as JSON with a plain-text `report`, how the projects would share one workspace dictionary: rows that are the same in several projects become one, a later row whose name is taken by different content is kept as ` ()` and listed with the fields that differ, and ids already taken are renumbered with every reference rewritten. `--output NEW.db` writes the migrated copy; the input is not changed and stays as its backup. Before anything is written every project is checked: hydrated from the new dictionary it must hold all of its rows and schedule, unleveled and leveled, to the same dates and float as before, or the command fails with `migration_failed`. The app's `Admin > Share Dictionaries Across Projects...` does the same in place, after a backup. + +`workspace dictionary --input workspace.db [--table calendar]` lists the dictionary: per table, each row's `id`, `name` and `used_by` (the workspace ids of the projects that use it; calendars add `type` and `default`, code types `scope` and `eps_node`). `workspace dictionary-usage --input workspace.db --table resource (--id N | --name NAME)` answers for one row with the projects' ids and names. `--table` takes `calendar`, `resource`, `role`, `activity_code`, `code_value`, `udf`, `account`, or a table name such as `RSRCRATE`. A schema 1 workspace gives `workspace_needs_migration`. + +`import --workspace` merges each file project's dictionary rows into the workspace's: a row with the same name and content is the workspace's own (importing the same file twice adds nothing), a row whose name the workspace has with different content is added as a copy `_`, and anything else is added. `--dictionary KIND=keep|update|copy,...` chooses otherwise per kind (`calendar=keep,resource=update`): `keep` uses the workspace's row, `update` gives the workspace's row the file's values for every project that uses it. Each project in the result lists these decisions in `dictionary`, with the fields that differ. `export` writes only the dictionary rows its projects use. + +`load` pages activities (`--offset`, `--limit`) and relationships (`--relationship-offset`, `--relationship-limit`) independently. Each limit defaults to 200 and allows 0 to 2000 (0 returns no rows of that kind, only the counts, and no next offset), and the response gives both continuation offsets. To keep an answer small, `--fields` names the activity fields to return (`task_code` is always kept; `wbs`, the code path, and `critical`, by the project's own definition, are given only when named), and `--activities ID,ID`, `--wbs PATH` (the element and everything under it) and `--critical` keep only the matching activities; then the relationships are those with an end among them, `matched_activities` and `matched_relationships` count them, and unknown Activity IDs come back in `not_found`. `--sort FIELD` orders the activities by a field, `-FIELD` descending (`--sort=-early_finish` lists the latest finish first; WBS paths sort element by element, numbers by value; empty values go last, equal values keep the project's order). MCP takes the same as `fields`, `activities` (arrays), `wbs`, `critical` and `sort`. `fields` also names `original_duration_minutes`, `actual_start`, `actual_finish`, `constraint` and `constraint_date`, given only when named. + +`check-schedule` runs Tools > Check Schedule read-only, with the app's own rules (`xer/src/schedule_check.rs`, which the dialog runs too) and its default targets: one row per check (Logic, Negative lags, Positive Lags, Long Lags, Relationship Types, Hard Constraints, Soft Constraints, Large Float, Negative Float, Large Durations, Activities with Invalid progress dates, Resources / Cost, Late Activities, BEI, Out Of Sequence) with `check`, `count`, `of`, `result` (a percent, or the index for BEI), `target`, `pass` and `first` (its first five offenders), and the hour thresholds. `--check NAME` also lists that row's Activity IDs (relationships as `PRED -> SUCC TYPE`), `--limit` of them (default 50, at most 500). Late Activities and BEI compare with the project's own planned finishes: the command reads no project baseline. + +`playbook` lists the scheduling playbooks (`build`, `update`, `audit`, `critical-path`, `delay-recovery`, `schedule-check`) and `--name` returns one: a step-by-step method, written for a working scheduler, that names the chat tools and load options to use at each step. They are compiled in from `assets/playbooks/`. Activity codes are exact and case sensitive. Each activity row lists the documents linked to it (`documents`: `document_id`, `title`, `reference`, `work_product`). + +`call --json ''` or `call --request-file request.json` runs one complete request, the CLI arguments as a JSON object with a `command` field: + +```json +{ + "command": "schedule", + "input": "C:\\Schedules\\workspace.db", + "output": "C:\\Schedules\\scheduled.db", + "project_id": 101, + "options": { "data_date": "2026-04-06 08:00", "level_resources": true } +} +``` + +## Editing: apply and the single edits + +Edits name things the way you see them in the app: + +- activities by Activity ID, resources by short name, calendars by name, code types and user-defined fields by their names, and WBS elements by their code path (`1.2.3`); +- durations and lags in **hours**, dates as project-local `YYYY-MM-DD HH:MM` (or `YYYY-MM-DD`); +- choices as XER codes (`TT_Task`, `CS_ALAP`, `DT_FixedDUR2`) or display names; +- `null` clears a value. + +They run through the desktop's setters, so statuses, durations, units and assignments follow exactly as they would when typed in the app. An edit to a started activity moves its status as the app would, and a duration type decides which of duration, units and units per hour follows a change. + +### apply + +```powershell +.\openxer-cli.exe apply --input C:\Schedules\workspace.db --project 101 --changes C:\Schedules\week-14.json --dry-run +.\openxer-cli.exe apply --input C:\Schedules\workspace.db --project 101 --changes C:\Schedules\week-14.json --output C:\Schedules\updated.db +``` + +A changes file: + +```json +{ + "format": "openxer-changes/1", + "recalculate": true, + "operations": [ + {"op": "set_project", "field": "data_date", "value": "2026-04-06 08:00"}, + {"op": "set_activity", "activity": "A1010", "field": "actual_start", "value": "2026-03-30 08:00", + "meta": {"source": "field update sheet, week 14"}}, + {"op": "set_activity", "activity": "A1010", "field": "remaining_duration", "value": 16}, + {"op": "add_activity", "activity": "A1015", "name": "Weld tie-ins to existing header", "wbs": "1.2"}, + {"op": "relationship", "action": "add", "predecessor": "A1010", "successor": "A1015", "kind": "FS", "lag_hours": 0}, + {"op": "assign_resource", "activity": "A1015", "resource": "PF"}, + {"op": "set_assignment", "activity": "A1015", "resource": "PF", "field": "budgeted_units", "value": 120}, + {"op": "schedule", "level_resources": false} + ] +} +``` + +Operations run in file order, all or nothing: when one fails, nothing is written and the error names the operation. `--dry-run` returns the field diff (old and new values per table and row) without writing. The diff covers every table the operations write: activities, assignments, relationships, WBS, calendars, documents and their links, the project row, schedule options, resources and their limits, code types, code values and activity codes, notebook topics and notebooks, user defined field values, funding, expenses, issues and their history, risks and their activity assignments, thresholds, steps, step templates, notes to resources, feedback and curves. The result lists each operation's outcome, the diff and, for `schedule` operations, how many activities changed. An operation that writes nothing (a `set_notebook` without `text`, a `set_udf` value with no activity or resource) says why in its result, and the report lists it under `warnings`. + +Every operation may carry a `meta` object (provenance such as source, evidence or who wrote it). It is accepted and ignored, never written. Any other unknown field is refused. Other top-level keys of the file (notes, a source) are carried for people and never applied. + +Operations: + +| Operation | Fields | +| --- | --- | +| `set_project` | `field` (`data_date` or `must_finish`), `value`, optional `schedule` (true schedules at the new data date right away) | +| `add_wbs` | `wbs` (code path), optional `name`; adds the elements of the path that do not exist yet | +| `add_activity` | optional `activity`, `selected`, `name`, `wbs`; the new activity takes the project's Defaults tab values as the app's Add does: activity type, duration type, percent complete type and calendar, 5 days of original and remaining duration, named `New Activity` unless `name` is given. Without `activity` its ID comes from the auto-numbering defaults (`task_code_prefix`, `task_code_base`, `task_code_step`, `task_code_prefix_flag`): with the flag `Y` and `selected` naming an activity, that ID plus the increment, stepping past IDs in use; otherwise the highest ID with the prefix plus the increment, or prefix and suffix when there is none. Without `wbs` it goes in the WBS of `selected`, else the project node. It starts at the data date on its calendar (finish = start + duration, kept as its duration or calendar changes), without scheduling the project; it has no late dates or float until `schedule`; the result names the ID it got | +| `delete_activity` | `activity`; its relationships and assignments go with it | +| `dissolve_activity` | `activity` (with at least one predecessor and one successor), optional `retain_lag` (default `false`); as Edit > Dissolve: each predecessor is tied to each successor, the new relationship starting where the predecessor relationship starts and ending where the successor relationship ends (A SS B and B FF D give A SF D); a pair already related keeps its relationship; lag 0, or with `retain_lag` the two lags added; no reschedule | +| `set_activity` | `activity`, `field`, `value`, optional `recalculate` | +| `assign_resource`, `remove_assignment` | `activity`, `resource`; milestones take no assignments (`milestone_assignment`) | +| `set_assignment` | `activity`, `resource`, `field`, `value`, optional `recalculate` | +| `relationship` | `action` (`add`, `edit`, `remove`), `predecessor`, `successor`, `kind` (`FS`, `SS`, `FF`, `SF`), optional `lag_hours`, optional `comments` | +| `calendar_day` | `calendar`, `date`, `shifts` (`[["08:00","12:00"],...]`, `[]` for nonwork, `null` for the weekday pattern) | +| `calendar_weekday` | `calendar`, `weekday` (0 is Sunday), `shifts` (`[]` is nonwork) | +| `schedule` | optional `level_resources` (left out, the loaded setting stays) | +| `set_resource_limit` | `resource`, `from` (date), optional `shift_period`, `max_units_per_hour` (`null` removes the row), `price_per_unit` to `price_per_unit_5` | +| `set_activity_code` | `activity`, `code_type`, `value` (code short name, `null` removes it; left out, nothing changes) | +| `set_project_code` | `code_type` (a project code), `value` (value short name, `null` removes it; left out, nothing changes); one value per code type, a new one replaces the old | +| `add_code_type` | `code_type`, optional `scope` (`project`, `eps`, `global`), optional `max_length` | +| `add_code_value`, `delete_code_value` | `code_type`, `code` | +| `set_code_value` | `code_type`, `code`, `field`, `value` (`parent` by short name, or an ACTVCODE column) | +| `set_notebook` | `activity`, `topic`, `text` (`null` removes it; left out, nothing changes) | +| `set_wbs_notebook` | `wbs`, `topic`, `text` (as `set_notebook`) | +| `set_udf` | `udf` (label), `value`, and one record: `activity`, `resource`, `activity` with `resource` (an assignment), `activity` with `step` (number from 1 or name), `wbs` (path), `project: true` (the open project), `expense`, `issue`, `risk` or `document`; a code-list field takes the code; a batch replaying a stored value whose record is gone reports it and writes nothing, a single `edit` refuses it | +| `add_calendar` | `calendar` | +| `delete_calendar` | `calendar`; a calendar in use needs `replacement` (a global calendar's name) or `default_global: true`, and everything that used it (activities, projects, resources, calendars inheriting from it) moves there before it is deleted; the default global calendar is never deleted | +| `set_calendar` | `calendar`, `field`, `value` (`base_calendar` by name, `project_calendar`, or a CALENDAR column) | +| `add_resource` | `resource` | +| `set_resource` | `resource`, `field`, `value` (`parent` by short name, `calendar` by name, or an RSRC column) | +| `set_wbs` | `wbs`, `field`, `value` (a PROJWBS column) | +| `set_schedule_option` | `field`, `value` (a SCHEDOPTIONS column) | + +`set_project` (fields other than the dates), `set_calendar`, `set_resource`, `set_wbs`, `set_schedule_option` and `set_code_value` write a column as given. The column must be one the file's table holds or one the format defines for that table; another name is refused with the list of fields that can be written, so a misspelling never adds a column to the saved file. Keys and parent keys are refused: `proj_id`, `wbs_id`, `rsrc_id`, `actv_code_id`, `actv_code_type_id`, `schedoptions_id`; `parent_wbs_id` (move the element with `shift_wbs`), `parent_rsrc_id` and `parent_actv_code_id` (use `parent`), and a calendar's `base_clndr_id` and `proj_id` (use `base_calendar` and `project_calendar`). +| `add_project_funding` | `source` (a funding source name), optional `amount`, optional `share` | +| `set_project_funding` | `source`, `field` (`source`, `amount`, `share`), `value` | +| `delete_project_funding` | `source` | +| `delete_resource` | `resource` (no assignments, no child resources) | +| `delete_financial_period` | `period` (its name), optional `calendar` (the financial period calendar's name, when two periods share a name); refused while stored period performance of an activity or assignment refers to it | +| `global_change` | `name` (a definition saved in the workspace input) or `rule` (`match`, `conditions`, `then`, `otherwise`); see [Global Change](#global-change) | +| `merge_resources` | `from` (short names), `into`; assignments, rates, codes, UDF values, role links, child resources and the calendar move to `into` | +| `set_wbs_earned_value` | `wbs`, optional `performance`, `custom_percent`, `estimate_to_complete`, `performance_factor` | +| `add_document`, `set_document`, `delete_document`, `link_document`, `unlink_document` | see [Documents](#documents) | +| `add_expense` | `activity`, optional `name`, optional `fields` | +| `add_issue`, `add_risk` | optional `name`, optional `fields` | +| `add_threshold` | optional `parameter`, optional `fields` | +| `set_expense`, `set_issue`, `set_risk`, `set_threshold` | `expense`, `issue`, `risk` or `threshold` (id, or a unique name), `field`, `value` | +| `delete_expense`, `delete_issue`, `delete_risk`, `delete_threshold` | the record | +| `assign_risk`, `unassign_risk` | `risk`, `activity` | +| `monitor_thresholds` | optional `from`, `to` (one window for every threshold), `today` | +| `update_progress` | `data_date`, optional `activities` (Activity IDs), optional `remaining` (`always`, `duration_type`) | +| `apply_actuals` | `data_date`, optional `remaining` | +| `recalculate_costs` | optional `active_only`, `sync_overtime` | +| `top_down_estimate` | `labor_units`, optional `wbs`, `not_started_only` (default true), `weights` (`{"1.2": 3}`) | +| `add_step` | `activity`, `name`, optional `at` (1 is first) | +| `set_step` | `activity`, `step` (number from 1, or name), `field` (`name`, `complete`, `percent_complete`, `weight`, `description`), `value` | +| `delete_step` | `activity`, `step` | +| `move_step` | `activity`, `step`, `to` | +| `add_steps_from_template` | `activity`, `template` (name), optional `after` (step number or name; the steps go in after it, else after the last step) | +| `create_step_template` | `activity`, `name` | +| `set_feedback` | `activity`, optional `notes` (`null` clears), optional `review_required` | +| `shift_wbs` | `wbs`, `direction` (`up`, `down`, `left`, `right`) | +| `rename_wbs_code` | `wbs`, `code` | +| `copy_calendar` | `calendar` (the new name), optional `source`, optional `kind` (`project`, `global`, `resource`) | +| `rename_calendar` | `calendar`, `name` | +| `set_default_calendar` | `calendar` (global) | +| `convert_calendar` | `calendar`, `to` (`global` for a project calendar; `shared` or `personal` for a resource calendar) | + +`set_activity` fields are the app's column keys: `activity_id`, `activity_name`, `wbs`, `calendar`, `activity_type`, `activity_status`, `duration_type`, `percent_complete_type`, `activity_priority`, `primary_resource`, `original_duration`, `remaining_duration`, `actual_duration`, `at_completion_duration`, `actual_start`, `actual_finish`, `start`, `start_without_constraint`, `finish`, `planned_start`, `planned_finish`, `expected_finish`, `suspend_date`, `resume_date`, `physical_percent_complete`, `duration_percent_complete`, `activity_percent_complete`, `primary_constraint`, `primary_constraint_date`, `secondary_constraint` and `secondary_constraint_date`. + +On an activity that has not started, `start` moves Start and Planned Start to the date (the finish follows by the duration) and holds it there with a Start On or After constraint on that date, as answering Yes in the app does; `start_without_constraint` moves the same dates with no constraint, as answering No does (the next schedule may move it back). `finish` keeps the start and recalculates the Original and Remaining Duration to fit, with no constraint. On a started activity `start` and `start_without_constraint` set the actual start. + +Milestones (`TT_Mile`, `TT_FinMile`) carry no resource or role assignments, in the app as here: `assign_resource` on a milestone is refused with the code `milestone_assignment`, and `set_activity activity_type` to a milestone is refused while the activity has assignments (the message names them; remove them first, then change the type), with `--recalculate false` too. A milestone may have a primary resource (any resource of the file), expenses, documents and work products. When a milestone becomes a task its primary resource is cleared unless it is one of the task's assignments, since a task's primary resource must be assigned. A file that already holds assignments on milestones loads and saves them untouched; the app's Project Checker lists them as "Milestone with resource assignments". + +`set_activity` also takes the Status tab's units and costs, through the same setter as the tab: `budgeted_`, `actual_`, `remaining_`, `at_completion_` or `this_period_` followed by `labor_units`, `nonlabor_units` (hours), `labor_cost`, `nonlabor_cost` or `material_cost`. An At Completion value sets the remaining units (or cost) to it less the actual, so the budget follows only on a not started activity whose project links budget and remaining; a completed activity's At Completion is fixed. As in the app, a cost needs an assignment of that resource type with a price, and units go to the assignments or, without one, to the activity's own quantities. + +`set_assignment` fields: `budgeted_units`, `remaining_units`, `budgeted_units_per_hour`, `remaining_units_per_hour`, `actual_regular_units`, `actual_overtime_units`, `this_period_units`, `budgeted_cost`, `remaining_cost`, `actual_regular_cost`, `actual_overtime_cost`, `this_period_cost`, `at_completion_units`, `at_completion_cost` (the remaining takes the value less the actual), `price_per_unit`, `rate_type`, `rate_source` (`resource` or `role` take that rate, `override` keeps the price to be typed), `overtime_factor`, `lag_hours`, `planned_lag_hours`, `original_duration` and `remaining_duration` (hours), `drive_activity_dates` (true or false), `resource` (another resource's short name: replace it), `role` and `cost_account` (by short name or name; `null` clears) and `curve`. + +`curve` takes a resource curve's name, as `curves` lists it (case ignored), or `null` to clear: `{"op":"set_assignment","activity":"A1015","resource":"PF","field":"curve","value":"Bell, Centered"}`. It works the same with or without `recalculate`. A preset curve is copied into the file's `RSRCCURVDATA` the first time an assignment uses it, with a new `curv_id` and `default_flag` N; later uses, and later loads of the saved file, reuse that row. A number that is not a curve name is taken as a `curv_id` already in the file. The result gives the assignment's `curv_id`. + +### Resource curves + +`openxer-cli curves --input FILE [--project ID]` (MCP `openxer_curves`) lists every curve an assignment can use: the file's own curves in file order, then each OpenXER preset whose name the file does not hold. Each entry has `name`, `curv_id` (null for a preset not in the file yet), `kind` (`file`, `default` or `preset`), `in_file`, `editable`, `assignments` (how many use it), `shape` and `formula` for presets, and `points`: the 21 values `pct_usage_0` to `pct_usage_20`, the percent of the units spent in each 5% step of the duration (point 0 is the start, point k covers (k-1) x 5% to k x 5%), totalling 100. + +The presets are `Even`, `Early Weighted`, `Late Weighted`, `Ramp Up`, `Ramp Down`, `Bell, Centered`, `Bell, Early Peak`, `Bell, Late Peak`, `Two Peaks` and `Steady with Ramps`, each computed from the formula `curves` reports. A file's own curve with a preset's name is the file's and hides that preset. Presets are exported only once an assignment uses one, so an XER sent elsewhere carries no curves it does not need. Curves shape how an assignment's units and costs spread over time (`applied_to_spreading` is true) on Fixed Duration and Units/Time and Fixed Duration and Units activities, and never change dates, float, stored units or leveling. `set_assignment` field `curve` reports `curve_applies`, with a `note` when the activity's duration type ignores curves. `usage` returns the spread period by period; each series has `total`, `per_period` and `unplaced`, the part of the stored quantity no period holds (outside the periods, or with nothing to spread over, such as actual units before an actual start), so `total` + `unplaced` equals the stored quantity. The exact per-period numbers follow OpenXER's reading of the documented behavior and are not yet measured against other software (`usage` reports `verified: false`). + +### Writing values exactly: --recalculate false + +`--recalculate false` (or `"recalculate": false` in the file, or on one `set_activity` or `set_assignment` operation) writes those values exactly into their XER columns, with no duration type, units or cost knock-on, and the project is then re-read from those columns. Use it to replay data that was written outside a scheduler. In that mode the edits also take derived fields such as `remaining_units_per_hour`, costs and raw XER column names. Scheduling still runs normally. The command line flag overrides the file's setting. + +### Single edits + +Each single edit command runs one operation the same way, with the same flags for input, output and mode: + +```powershell +.\openxer-cli.exe set-activity --input C:\Schedules\workspace.db --project 101 --activity A1010 --field actual_finish --value "2026-04-03 17:00" --dry-run +.\openxer-cli.exe assign --input C:\Schedules\workspace.db --project 101 --activity A1015 --resource PF --output C:\Schedules\assigned.db +.\openxer-cli.exe set-assignment --input C:\Schedules\assigned.db --project 101 --activity A1015 --resource PF --field remaining_units --value 80 --output C:\Schedules\units.db +.\openxer-cli.exe calendar-day --input C:\Schedules\workspace.db --project 101 --calendar "Standard 5-day" --date 2026-07-03 --shifts nonwork --output C:\Schedules\holiday.db +.\openxer-cli.exe calendar-weekday --input C:\Schedules\workspace.db --project 101 --calendar "Standard 5-day" --weekday 6 --shifts '[["07:00","11:00"]]' --output C:\Schedules\saturdays.db +.\openxer-cli.exe set-project --input C:\Schedules\workspace.db --project 101 --field data_date --value "2026-04-06 08:00" --output C:\Schedules\dated.db +.\openxer-cli.exe add-wbs --input C:\Schedules\workspace.db --project 101 --wbs 1.4.2 --name "Tie-ins" --output C:\Schedules\wbs.db +``` + +Edit flags: `--input FILE (--output NEW_FILE | --dry-run) [--project ID] [--workspace-id ID] [--recalculate true|false]`. `--value` is the text as typed, so a text field keeps it exactly (`1.10`, `0042` or a 20-digit order number stay as given) and a numeric field reads its number from it; only `null` (clears) and `true` or `false` are taken as JSON. `--value ""` and `--notes ""` give empty text, and a value that starts with `--` is given inline (`--value=--draft--`). `--review-required`, `--active-only`, `--sync-overtime`, `--not-started-only` and `--work-product` mean true on their own, like `--dry-run`. `calendar-day --shifts standard` puts a date back on its weekday pattern. + +## Scheduling + +`schedule --options ''` sets the options below; `--data-date` and `--level [true|false]` are shortcuts, and giving the same option twice is refused. + +| Option | Value | +| --- | --- | +| `data_date` | Project-local date or date and time | +| `must_finish` | Date, or `null` to clear the project finish constraint | +| `retained_logic`, `progress_override` | Booleans; both cannot be true | +| `lag_from_early_start`, `use_expected_finish` | Booleans | +| `level_resources` | Boolean; resource-dependent activities require true | +| `lag_calendar` | `predecessor`, `successor`, `24_hour`, `project` | +| `float_type` | `start`, `finish`, `minimum` | +| `ignore_external_relationships`, `open_ends_critical`, `use_must_finish` | Booleans | +| `multiple_float_paths`, `float_paths_use_total` | Booleans | +| `max_float_paths` | Positive integer when multiple paths are on | +| `float_paths_end_activity` | Numeric task_id of an activity in the project (another id is refused); `null` clears it | + +Options left out keep the loaded settings. Scheduling uses the project's calendars, resource limits, priorities, assignments and options. Workspaces keep the resource leveling toggle; XER has no project field for it, so give `--level` again when scheduling an exported XER. + +The report separates `generated` fields (null before) from `changed` fields (with `before` and `after`). Counts cover every activity; the `changes` list holds at most 200 activities, with `changes_truncated` and `change_limit`. Use `load` on the output to see the full result. Public `remaining_start` and `remaining_finish` are the exported remaining dates. + +## Relationships + +`relationship add|update|remove` identifies a relationship by predecessor, successor and type (`FS`, `SS`, `FF`, `SF`). `update` also takes `--new-type`. `--lag-minutes` takes signed whole working minutes from -6,000,000 to 6,000,000. Cycles, self links, duplicates and ambiguous activity codes are refused. The command keeps stored dates; run `schedule` on its output to recalculate. (The `relationship` operation of `apply` takes its lag in hours, like the other edits.) + +## Import, export, Excel and PDF + +```powershell +.\openxer-cli.exe import --input C:\Inbox\contractor.xer --workspace C:\Schedules\workspace.db --output C:\Schedules\merged.db --action update --config "activities=update,relationships=update+delete,calendars=keep" +.\openxer-cli.exe export --input C:\Schedules\workspace.db --projects 3,4 --version 19.12 --output C:\Schedules\both.xer +.\openxer-cli.exe export-xlsx --input C:\Schedules\workspace.db --project 101 --output C:\Schedules\101.xlsx --unit days +.\openxer-cli.exe export-xlsx --input C:\Schedules\workspace.db --project 101 --output C:\Schedules\101-tables.xlsx --layout tables +.\openxer-cli.exe import-xlsx --input C:\Schedules\workspace.db --project 101 --spreadsheet C:\Schedules\101-edited.xlsx --dry-run +.\openxer-cli.exe import-xlsx --input C:\Schedules\workspace.db --project 101 --spreadsheet C:\Schedules\101-edited.xlsx --output C:\Schedules\updated.db +.\openxer-cli.exe export-pdf --input C:\Schedules\workspace.db --project 101 --layout "Lookahead" --paper Tabloid --orientation landscape --output C:\Schedules\lookahead.pdf +``` + +- **import**: without `--workspace` it writes a new workspace. With `--workspace` it copies that workspace to the output and creates (`--action new`), updates (`update`), replaces (`replace`) or adds into (`add`) a project there; `--target-workspace-id` picks the row. `--config` sets per-type actions for `update`: types `activities`, `relationships`, `wbs`, `assignments`, `calendars`, `resources`, `activity_codes`, `udfs`, `notebooks`; actions `insert`, `keep`, `update`, `skip`, joined with `+`. The workspace records the XER's file name as the project's source, not its full path. The input may be a project XML file (root element `APIBusinessObjects`); it is told from XER by its contents, and `--format xer|xml` refuses a file of the other format. +- **export**: writes a new XER. Unknown tables and other projects of the source document are kept. `--version` sets the header version label (and stamps today as the export date) and keeps the rest of the plain export. `--projects` writes only the listed projects: for a workspace input each id is a workspace id, or a project id when no workspace row has that id. `--format xml`, or an output name ending in `.xml`, writes project XML instead, in the structure a project XML export of the reference format has (root element and namespaces, the order of every element's children, fractions for percents, `1`/`0` flags, hours, nil for empty fields): projects with their schedule options, WBS, activities, relationships, calendars, resources with their codes, assignments, activity codes, user defined fields, expenses, notebook topics with project, WBS and activity notes, the OBS, currencies and the financial period template, plus cost accounts, expense categories, units of measure, roles, rates and baselines where the project has them (baselines in the file as baseline projects). Every other table and column is left out of the XML. Files written this way follow that structure but have not yet been opened in the product that defines the format. +- **export-xlsx**: `--layout modern` (the default) writes typed dates, durations in the stated `--unit`, the WBS outline and Relationships, Resource Assignments and About sheets. `--layout tables` writes the TASK, TASKPRED, TASKRSRC and USERDATA sheets with XER field names in row 1. `--columns` takes column keys such as `activity_id,activity_name,original_duration,remaining_duration,start,finish,total_float` or titles. `--template` runs a saved export template by name from the workspace, or a template `.json` file; it sets columns, filter, sort and options. +- **import-xlsx**: matches rows by Activity ID. `--dry-run` returns the preview without writing: counts, every changed, new, deleted and refused row with old and new values, relationship changes and notes. Without it the same plan is applied to a new output; `--output` with `--dry-run` is refused. Deletes need an explicit `D` flag in the sheet. +- **export-pdf**: prints a layout (table and Gantt, or `--view network` for the Activity Network) to a vector PDF with its saved Page Setup. `--layout` names a saved layout (the current one when left out); `--paper` is Letter, Legal, Tabloid, Executive, A5, A4, A3, B4 (JIS), ANSI C, ANSI D or ANSI E; `--orientation` is `portrait`, `landscape` or `automatic`. Printing uses the desktop's own renderer: the command runs `OpenXER.exe` next to `openxer-cli.exe` (or the program named by `OPENXER_DESKTOP`) in a headless mode, and no window opens. + +## Documents + +A project's work products and documents (the WPs & Docs view: XER tables `DOCUMENT` and `TASKDOC`) are part of what an agent can read and edit. A document is named by its reference number, its title (each exact first, then ignoring case) or its document id. + +```powershell +.\openxer-cli.exe documents --input C:\Schedules\workspace.db --project 101 +.\openxer-cli.exe documents --input C:\Schedules\workspace.db --project 101 --activity A1010 +.\openxer-cli.exe read-document --input C:\Schedules\workspace.db --project 101 --document DS-100 --limit 20000 +.\openxer-cli.exe read-document --input C:\Schedules\workspace.db --project 101 --document "Tie-in drawing" --page 3 --pages 2 +.\openxer-cli.exe link-document --input C:\Schedules\workspace.db --project 101 --document DS-100 --activity A1010 --output C:\Schedules\linked.db +``` + +`documents` (MCP `openxer_documents`) lists every document: `document_id`, `title`, `reference`, `parent`, `deliverable`, `status`, `category`, `author`, `version`, `date`, `private_location`, `public_location`, `description` (plain text), the linked `activities` (Activity ID, name, `work_product`) and the `wbs` elements it is assigned to itself (path, name). `--activity ID` or `--wbs PATH` keeps only the documents linked there. The result also lists the project file's document `statuses` and `categories`. + +`read-document` (MCP `openxer_read_document`) returns the text of the file a document record points at. It is read only and never takes a free path: the file is always the document's `--location private` or `public` (by default the private location when it is set, else the public one). The location must pass the same check as Launch in the WPs & Docs view: an existing regular file named by an absolute path on a local drive (`C:\...`; on other systems an absolute path from `/`). Relative locations are refused, as Launch refuses them, and so are network (UNC) paths, device paths (elsewhere, files under `/dev`, `/proc` and `/sys`), web and other addresses, alternate data streams (Windows), and locations that resolve through a link to something else. Programs and scripts (`.exe .bat .cmd .ps1 .js .vbs .msi .com .scr`) are never read. + +A schedule received from someone else can name any file on this computer in its document rows, and an agent reads without a person clicking Launch. So `read-document` reads only files under the folder of the `--input` file (after links are resolved). To allow other folders, set the environment variable `OPENXER_DOCUMENT_ROOTS` for the `openxer-cli` or MCP server process to those folders, separated by `;` (for example `C:\Projects\Docs;D:\Drawings`; on other systems by `:`, as in `PATH`). A file elsewhere is refused with `location_refused`, and the message says how to allow its folder. + +| Type | Returned as | Paging | +| --- | --- | --- | +| `txt`, `md`, `csv`, `json`, `xml`, `log` | `text` (UTF-8, UTF-16 with a byte order mark, else Windows-1252) | `--offset` and `--limit` characters (default 20000, at most 200000); `next_offset` continues | +| `docx` | `text`, the body paragraphs one per line | as text | +| `pdf` | `pages`: `[{page, text}]`, each page extracted on its own | `--page` (from 1) and `--pages` (default 10, at most 100), the characters capped by `--limit`; `next_page` continues. A page cut by `--limit` carries `truncated: true` and `page_characters`, the result has `truncated: true`, and `next_page` names that page again: read it with a larger `--limit` | + +PDF text comes from the embedded text; a scanned drawing without a text layer returns empty pages. Encrypted PDFs are not read. Files over 64 MB are not read at all. Error codes: `document_not_found`, `no_location`, `location_refused`, `refused_type`, `unsupported_type`, `file_too_large`, `read_failed` and `invalid_arguments` (paging that does not fit the file). + +Edits use the same operations as the WPs & Docs view (`apply` or the single edits, MCP tools of the same names): + +- `{"op":"add_document","title":"Pump datasheet","reference":"DS-100","parent":"DS-000","fields":{"version":"B","public_location":"C:\\Docs\\ds-100.pdf"}}` adds a document after its last sibling, under `parent` or at the top level. The result gives its `document_id`. +- `{"op":"set_document","document":"DS-100","field":"status","value":"Approved"}` sets `title`, `reference`, `deliverable` (yes or no), `status` and `category` (by name, from the file's `DOCSTAT` and `DOCCATG` dictionaries), `author`, `version`, `date` (`YYYY-MM-DD` or `YYYY-MM-DD HH:MM`), `private_location`, `public_location` or `description` (plain text). `null` clears; a title cannot be cleared. +- `{"op":"delete_document","document":"DS-100"}` deletes the document with the documents under it and all their links. +- `{"op":"link_document","document":"DS-100","activity":"A1010","work_product":true}` links it to an activity, or with `"wbs":"1.2"` to a WBS element itself; `{"op":"unlink_document",...}` removes that link. + +Dry runs report the changes under `documents` and `document_links` in the diff. + +## Expenses, issues, risks and thresholds + +The Project menu's registers (XER tables `PROJCOST`, `PROJISSU`, `PROJRISK` or `RISK` with `TASKRISK`, and `PROJTHRS` with its parameters in `THRSPARM`) are read with `records` and edited with the register operations, through the same functions as the Expenses, Issues, Risks and Thresholds views and the Activity Details tabs. + +```powershell +.\openxer-cli.exe records --input C:\Schedules\workspace.db --project 101 --kind issues +.\openxer-cli.exe add-expense --input C:\Schedules\workspace.db --project 101 --activity A1010 --name "Crane rental" --fields '{"budgeted_units":4,"price_per_unit":1250}' --output C:\Schedules\crane.db +.\openxer-cli.exe set-issue --input C:\Schedules\crane.db --project 101 --issue "Late steel" --field status --value Closed --output C:\Schedules\closed.db +.\openxer-cli.exe monitor-thresholds --input C:\Schedules\closed.db --project 101 --dry-run true +``` + +`records --kind expenses|issues|risks|thresholds [--activity ID]` (MCP `openxer_records`) lists each record's `id` and every field below with the value as the edits take it; risks list their `activities`, thresholds come with the `parameters` list. A record is named by its id, or by its name when that names one record (a risk also by its Risk ID). Choices take their code or label, dictionary fields a name from the file's dictionary (or its id), `null` clears. + +| Record | Fields | +| --- | --- | +| expense | `name`, `activity` (moves the item), `category` (`COSTTYPE`), `cost_account` (`ACCOUNT`), `accrual` (`Start of Activity`, `End of Activity`, `Uniform`), `unit_of_measure`, `vendor`, `po_number`, `auto_compute_actuals`, `budgeted_units`, `price_per_unit`, `budgeted_cost`, `actual_cost`, `remaining_cost`, `description` | +| issue | `name`, `responsible_manager` (`OBS`), `priority` (`Top` to `Lowest`), `status` (`Open`, `On Hold`, `Closed`), `identified_on`, `identified_by`, `resolution_date`, `activity` or `wbs` (setting one clears the other), `resource` (short name), `notes`; read only: `threshold_parameter`, `actual_value`, `lower_threshold`, `upper_threshold` | +| risk | `risk_id`, `name`, `category` (`RISKTYPE`), `type` (`Threat`, `Opportunity`), `status` (`Proposed`, `Open`, `Active`, `Rejected`, `Impacted`, `Managed`), `owner` and `identified_by` (resource short names), `identified_on`, `pre_response_probability`, `pre_response_schedule`, `pre_response_cost`, `post_response_probability`, `post_response_schedule`, `post_response_cost`, `response_type`, `response_description`, `description`, `cause`, `effect`, `notes` | +| threshold | `parameter` (name, short name such as `Total Float`, or measured field), `lower_threshold`, `upper_threshold`, `detail_to_monitor` (`Activities`, `WBS`), `wbs`, `responsible_manager`, `priority`, `status` (`Enabled`, `Disabled`), `from_date`, `to_date` | + +The edits follow the views: an expense item's budgeted units times its price is its budgeted cost, and while it has no actual cost its budget is all remaining. New issues are open and new risks proposed threats with the next free `RISK-n`, both identified today; a new threshold is an enabled total float threshold with a lower bound of 0 days until its fields say otherwise. Deleting an issue removes its history, deleting a risk its activity assignments; issues a deleted threshold raised stay. + +`monitor_thresholds` (CLI `monitor-thresholds`, MCP `openxer_monitor_thresholds`) runs Tools > Monitor Thresholds: every enabled threshold is evaluated over the activities or WBS elements of its WBS branch inside its window (or the `from` and `to` given), and an issue is raised for each value below the lower or above the upper bound, or the open issue it raised before is updated. Float and the start and finish variances are in days of the activity's calendar, the variances against the project baseline; the cost and earned value parameters (AV, CV, SV, VAC, CPI, SPI, CVI, SVI, Cost % of Budget, Duration % of Original) are computed as the earned value columns compute them. For a workspace input the project baseline and the primary baseline are the ones assigned in the app, read from the workspace; an XER input, or a project without them, is its own baseline. The result gives `thresholds`, `issues_raised`, `issues_updated`, `skipped` and the `baselines` used. + +## Progress, steps and the Tools edits + +The weekly update runs through the same rules as the Tools menu: + +```powershell +.\openxer-cli.exe update-progress --input C:\Schedules\workspace.db --project 101 --data-date "2026-04-13 08:00" --output C:\Schedules\progressed.db +.\openxer-cli.exe schedule --input C:\Schedules\progressed.db --project 101 --output C:\Schedules\week-15.db +.\openxer-cli.exe set-step --input C:\Schedules\week-15.db --project 101 --activity A1010 --step "Pour" --field complete --value true --dry-run true +``` + +- `update_progress` records progress as if every activity (or only `activities`) ran as scheduled up to the new data date: activities that should have started start on their scheduled start (never before the old data date), those that should have finished finish, and the remaining duration runs to the scheduled finish (`remaining` `always`), or for fixed units types uses up the elapsed working time (`duration_type`). LOE and WBS summary activities are left alone. The data date moves; schedule afterwards. Any data date is accepted: one equal to or earlier than the current data date only sets the data date, with no progress added and none removed (`apply_actuals` also stamps an earlier date as the apply actuals date). + Expenses set to compute actuals (uniform accrual) on the activities it progresses get the budget's share of the worked time as actual cost. +- `apply_actuals` follows the Auto Compute Actuals flags: an activity with the flag, or whose assignments all have resources with it, progresses as above together with all its assignments; flagged resources on only some assignments give just those assignments actuals and leave the activity's dates and duration. An assignment's actual units grow by its budgeted units/time times the working time from its remaining start to the new data date (at most its remaining units), costs follow at its price, and actual this period grows with them when the project links the two. Flagged expenses of started activities accrue as above. A project already at the new data date is left alone. It stamps the project's apply actuals date. +- `recalculate_costs` reprices assignments from their resources' prices and reports `updated`, `unchanged` and the `skipped` assignments with the reason. +- `top_down_estimate` spreads labor units over the receiving activities by the WBS estimation weights, as Tools > Top Down Estimation does. +- Steps keep their order (`seq_num` 1, 2, ...). Setting `percent_complete` to 100 completes a step; `complete` false sets it back to 0. When the project's steps drive percent complete, the activity's physical percent follows every step change, as in the Steps tab. Step templates are the project file's `PROCGROUP` and `PROCITEM` rows. +- `shift_wbs` and `rename_wbs_code` are the WBS view's Shift buttons and code field; the calendar edits are the Calendars dialog's Add (copy), rename, Set As Default and convert. + +## Global Change + +`global_change` (CLI `global-change`, MCP `openxer_global_change`) runs Tools > Global Change on every activity of the project, with the same definitions, evaluation and writes as the app's Global Change dialog and report (`openxer_xer::edit::global_change`). Name a definition saved in a workspace input with `name`, or give one as `rule`: + +```powershell +.\openxer-cli.exe global-change --input C:\Schedules\workspace.db --project 101 --name "Increase Durations" --dry-run +.\openxer-cli.exe global-change --input C:\Schedules\plan.xer --rule '{"match":"all","conditions":[{"column":"WBS","op":"under","value":"PLANT.2"}],"then":[{"column":"Original Duration","value":"Original Duration","operator":"x","value2":"1.5"}]}' --output C:\Schedules\longer.xer +``` + +- `conditions` are the If rows: `column` (a field id such as `activity_status` or `udf:Crew`, or its title), `op` (`eq`, `ne`, `contains`, `not_contains`, `starts_with`, `lt`, `le`, `gt`, `ge`, `within`, `not_within`, or its caption such as `is greater than`), `value` and, for the ranges, `high`. `under` ("is under") holds for the WBS element or activity code value named and every one below it; it is offered for WBS and activity code fields only. `match` `all` (the default) needs every row, `any` one of them. +- `then` rows set a field on the activities that meet the If rows and `otherwise` rows on the others: `column`, `value` (a literal, the title of another field, or text in double quotes) and optionally `operator` (`+`, `-`, `x`, `/`, `&` to join text) with `value2`. Any editable field can be set, user defined fields and activity codes included; a value goes through the same rules as a value typed into the activity table, so a locked field is refused for that activity. +- The result's `rows` are the lines of the Global Change Report: `project`, `wbs`, `activity`, `field`, `field_id`, `old`, `new` and `exception` (why that activity's value cannot change). Durations are hours (`40h`), dates `YYYY-MM-DD HH:MM`. With `--dry-run` nothing is written. Otherwise every line without an exception is written, and `changed` counts them, all in one operation of the batch. +- The app applies a global change only to the activities its Activities filter shows; outside the app there is no window filter, so put the activities you mean in the If rows. +## S-curve and earned hours + +`export-scurve --input FILE --output NEW.xlsx [--measure auto|labor|cost|duration] [--period day|week|month|financial] [--breakdown total|resource|wbs1|wbs2] [--late] [--week-start sunday|monday]` (MCP `openxer_export_scurve`) writes the workbook of Tools > Reports > S-Curve, from the same figures (`xer/src/scurve.rs`) and writer (`interchange/src/scurve_xlsx.rs`): + +- **S-Curve**: one row per period (start, end) with budgeted, actual and remaining values, their running sums and percents of the budget as formulas, the earned value to the data date in the data date's row, a total row and a native chart (period budgeted and actual as columns, cumulative budgeted, actual and actual plus remaining as lines on the secondary axis, earned as a marker). +- **By Resource - Budgeted**, **- Actual**, **- Remaining** (or by WBS level 1 or 2): one row per resource or WBS element, one column per period, total row and column as formulas. Not written with `--breakdown total`. +- **Info**: project, data date, measure and what was found, period, breakdown, where the budget comes from, generation time and warnings. + +`--measure auto` (the default) takes labor units when labor assignments carry budgeted units, else cost (assignments and expenses), else duration: each activity weighs its planned (original) duration in working days on its calendar, spread over its planned working days, actual is that weight times the activity % complete. Budgeted comes from the assigned project baseline (or the primary baseline when the project chooses it), spread over the baseline's own planned dates; else from the current plan. Actual runs to the data date and remaining from it on the early dates; `--late` adds actual plus remaining on the late dates. Weeks start on Sunday by default. The spreads are the usage views' (resource curves included), so the per-period totals equal the Activity Usage Profile's for the same periods. + +`export-earned-hours --input FILE --output NEW.xlsx [--breakdown resource|wbs|activity]` (MCP `openxer_export_earned_hours`) writes cumulative earned labor hours to the data date: **Earned to date** (one row per resource, WBS element or activity: `Budgeted Units`, `Earned Units`, `Actual Units`, `Remaining Units`, `At Completion Units`, `% Earned`, a total row) and **By activity** (one row per labor assignment, sorted by Activity ID then Resource ID). Earned units are the baseline's budgeted units of the assignment (the current budget without a baseline) times the activity's performance % complete, as `earned-value` computes it. Rows and columns keep a stable order, so the period's earned hours are one export's Earned Units minus the last update's. A project without labor hours fails with `no_labor_units` and writes nothing. + +## Earned value + +`earned-value --input FILE [--basis cost|labor_units] [--activity ID]` (MCP `openxer_earned_value`) returns, for each activity and for the project, `budget_at_completion`, `planned_value`, `earned_value`, `actual_cost`, `schedule_variance`, `cost_variance`, `schedule_performance_index`, `cost_performance_index` (null when the divisor is zero), `estimate_to_complete`, `estimate_at_completion` and `variance_at_completion`, with each activity's `performance_percent_complete` and `schedule_percent_complete`. They are the values of the activity table's earned value columns: the WBS elements' earned value techniques apply (`set_wbs_earned_value`), against the baselines described for Monitor Thresholds and the workspace's earned value date choice. Read only. + +## Schedule analysis + +Read-only commands that return the numbers a schedule review needs, so an agent reports them instead of working them out. Each takes `--input FILE` and `--project ID` or `--workspace-id ID`; dates and float are those last scheduled and stored in the file. Lists hold 25 items and count the rest in `more`. + +| Command | MCP | Returns | +| --- | --- | --- | +| `check-schedule [--long-lag-hours N] [--large-float-hours N] [--large-duration-hours N]` | `openxer_check_schedule` | Tools > Check Schedule's 15 checks (the same code as the app): `count`, `out_of`, `value`, `target`, `passed`, `note` and the activities or ties `found`; the late activities and baseline execution index checks use the workspace project's project baseline. `logic_warnings`: without predecessors, without successors, constrained, actuals after the data date, milestones with odd ties, finish milestones fed from another calendar, out-of-sequence ties. | +| `paths [--activity ID] [--count 1-10]` | `openxer_paths` | The scheduler's multiple float paths ending at the activity (the open activity finishing last when omitted): per path its `lowest_total_float_hours`, `behind_path_1_hours`, calendars, what holds its first activity and its activities in order; `merge_points`; `critical_counts` (on the longest path, total float zero or less, negative). | +| `compare (--reference FILE [--reference-project ID] [--reference-workspace-id ID] \| --baseline project\|primary)` | `openxer_compare` | The project against an earlier file or a stored baseline of the workspace project: `project_finish` then, now and moved, a `summary` of counts, and sections (each `items`, `more`, `count`) for milestones moved, biggest finish moves, activities added and deleted, ties added, removed and changed (type or lag), original durations changed, remaining duration up on work in progress, constraints and calendars changed, renamed, and progress (started, finished, actual dates rewritten, status gone back). Activities match by Activity ID and ties by predecessor and successor through the same core as Tools > Schedule Comparison (`xer/src/compare.rs`); moves are calendar days. | +| `lookahead [--weeks 1-26] [--from DATE]` | `openxer_lookahead` | Open work in progress or due in the window from the data date, by WBS: each activity with its `state` (in progress, ready, waiting), `waiting_on` (open predecessors with status and expected finish) and resources. At most 300 activities are listed. | +| `milestones` | `openxer_milestones` | Every milestone in date order with date, float, constraints, the project baseline date and move, and `driven_by` (the driving ties into it). | +| `schedule-stats [--update-period-days N]` | `openxer_schedule_stats` | Activities by type and status; every calendar with its week, hours per working day and exception dates; original durations in working days (median, 90th percentile, spread, longest, zero-duration tasks, longer than two update periods); repeated and one-word names; open work without resources or expenses; activities by WBS level and empty WBS elements. | +| `resource-loading [--interval day\|week\|month]` | `openxer_resource_loading` | Per assigned resource: actual plus remaining units per period (the usage spread), the peak, the limit in units per hour at the data date and the periods over it (units per working hour of the project's default calendar). | +| `wbs-summary [--wbs-level 1-10]` | `openxer_wbs_summary` | The schedule rolled up by WBS element down to the level: activities, completed, start, finish, lowest total float, baseline finish and move, and its milestones. | + +## Skills for AI agents + +A skill is a Markdown file of instructions that teaches any connected agent one way to analyze (`kind: check`, read-only) or build and change (`kind: workflow`) a schedule with these tools. OpenXER ships a library of them, built from `assets/skills/` into the executable. The user's own are `.md` files in `\skills\` (the folder that holds the default workspace; `OPENXER_DATA_DIR` moves it); the app's **AI Agents > Skills** dialog edits them. A user file whose id equals a built-in's replaces it (customized); deleting the file brings the built-in back. A file that does not parse is left out and reported with its line and problem; the others still load. The folder is read on every request, so new and edited skills reach a running MCP server at once. + +```text +--- +id: crew-check # the file name without .md: a-z, 0-9, single hyphens +name: Crew check # at most 40 characters +description: One line, at most 160 characters. +request: Run the crew check. # the sentence a user pastes to the agent +use_when: The user asks about crews. +kind: check # check or workflow +order: 50 # optional, 0 to 999 +examples: # optional +- Are the crews overloaded? +tools: # the OpenXER tools the steps run +- openxer_resource_loading +--- +The instructions, in Markdown. +``` + +`cites:` (a list) is accepted for the author's own notes; it is never sent to an agent. A tool a skill names that the server does not have is a warning. + +| Command | MCP | Does | +| --- | --- | --- | +| `skills list` | `openxer_skills` | Every skill: `id`, `name`, `description`, `use_when`, `request`, `kind`, `source` (`built_in`, `yours`, `customized`), plus the files left out (`problems`) and the folder. | +| `skills show ID` | `openxer_skill` | One skill with its `instructions`, `examples`, `tools` and the file it came from. | +| `skills validate [FILE]` | | One file (error code `invalid_skill` with the line and problem), or every file in the folder. | +| `skills new ID` | | Writes the self-explaining template to `\ID.md`; an existing file is refused. | +| `skills path` | | The skills folder and the data folder. | + +MCP also offers every skill as a prompt (`prompts/list`, `prompts/get`, named by id), for clients with a prompt menu. The server's `instructions` and the skill tools tell the agent to look for a matching skill before analyzing or building a schedule, and never to compute schedule metrics itself. + +## Project folders (EPS) and rollups + +The EPS is the folder tree that files a workspace's projects. XER files do not carry it; it lives in the workspace database, and these commands use the same code as the desktop app (Enterprise > Project Folders, the Projects view and the New Project wizard), so the rules are the same. + +```powershell +.\openxer-cli.exe eps list --input C:\Schedules\workspace.db +.\openxer-cli.exe eps add-folder --input C:\Schedules\workspace.db --output C:\Schedules\w1.db --name "East Region" --eps-id EAST --parent WORKSPACE +.\openxer-cli.exe eps file-project --input C:\Schedules\w1.db --output C:\Schedules\w2.db --workspace-id 3 --folder EAST +.\openxer-cli.exe eps create-project --input C:\Schedules\w2.db --output C:\Schedules\w3.db --folder EAST --project-id TA-27 --name "Turnaround 2027" --planned-start 2027-01-04 --must-finish 2027-03-30 +.\openxer-cli.exe eps rename-folder --input C:\Schedules\w3.db --output C:\Schedules\w4.db --folder EAST --name "Eastern Region" --new-eps-id EASTERN +.\openxer-cli.exe eps move-folder --input C:\Schedules\w4.db --output C:\Schedules\w5.db --folder EASTERN +.\openxer-cli.exe eps delete-folder --input C:\Schedules\w5.db --dry-run --folder EASTERN +.\openxer-cli.exe eps delete-folder --input C:\Schedules\w5.db --output C:\Schedules\w6.db --folder EASTERN --delete-projects +``` + +- On a workspace with a shared dictionary (workspace schema 3) `eps list` adds the dictionary's calendars, resources and codes to each project as the app does; `create-project` takes the responsible managers from the dictionary and stores the new project's calendar there, as the app's wizard does. +- **create-project** gives the new project an internal project number (the XER `proj_id`, returned as `project_number`) that no workspace project or baseline uses, as File > New does; relationships between projects name the other project by this number. +- **eps list** returns `folders` (each with `eps_id`, `name`, `parent`, `depth`, `path`, the workspace ids of the `projects` filed directly in it and a `rollup` over every project under it, child folders included), `projects` (each with `workspace_id`, `project_id`, `name`, `status`, `folder` and its `rollup`) and `rules`. Values are read from the stored projects, so closed projects are always current. +- A **rollup** has `start` and `finish` (the earliest start and latest finish of the activities, actual else early), `late_start`, `late_finish`, `actual_start`, `actual_finish` (only when every activity is completed), `data_date` (a folder shows the latest of its projects), `must_finish_by` (a folder: the latest), `baseline_finish` and `finish_variance_hours` (baseline finish minus finish in working hours; the project baseline, else a stored Primary baseline), `total_float_hours` (the lowest of the unfinished activities; a folder: the lowest of its projects), `schedule_percent_complete`, `labor_units_hours` and `costs` (each `budgeted`, `actual`, `remaining`; labor units count labor resources, costs every assignment plus the expenses; they add up), the counts `activities`, `not_started`, `in_progress`, `completed` and `projects`, and the `working_time_calendar`. +- **schedule_percent_complete** is duration based: (planned span minus remaining span) divided by planned span, times 100. The planned span runs from the earliest start (the earliest actual start once work has begun) to the latest finish; the remaining span from the earliest remaining start of an unfinished activity (the data date when none is stored) to the latest remaining finish. Every activity completed is 100. Spans are measured in working time of the project's default calendar; a folder uses its projects' shared default calendar, else the standard calendar new projects start with (Monday to Friday, 08:00 to 12:00 and 13:00 to 17:00). +- The edits name folders by EPS ID (letter case ignored) and write a copy to `--output` (or preview with `--dry-run`). `add-folder` adds the folder last under `--parent` (the top level when left out); names must be unique among siblings and EPS IDs in the whole tree. `move-folder` without `--parent` moves the folder to the top level; a folder cannot move under itself. `delete-folder` deletes the folder, the folders under it and every project filed in any of them, with those projects' baselines and baseline choices, as the app's Delete does after its one question. A folder that holds projects is refused (error code `refused`, with the count) unless `--delete-projects` is given; `--dry-run` lists what would go (`deleted` folders, `projects_deleted`, `baselines_deleted` and `items`, folders plus projects) without it. The last top-level folder cannot be deleted. The input workspace is never changed, so it stays the way back. `file-project` puts a workspace project in a folder. `create-project` makes an empty project with the New Project wizard's rules: a unique Project ID of up to 20 characters, a name of up to 100 (the ID when left out), a Planned Start (08:00 when no time is given; it is also the data date), an optional Must Finish By (17:00 when no time is given; not before the start), an optional `--manager` (a responsible manager's name or OBS id from the project last open in the app) and `--rate-type` (`COST_PER_QTY` to `COST_PER_QTY5` or a name such as `Price / Unit2`; the default rate type of the project's new assignments). + +## Baselines + +A baseline is a frozen copy of a project kept in the workspace beside it; it is not a project and never appears in the project lists. These commands use the app's own rules (Project > Maintain Baselines, Assign Baselines and Revert Project to Baseline; `automation/src/baseline_ops.rs`). + +```powershell +.\openxer-cli.exe baseline list --input C:\Schedules\workspace.db --workspace-id 3 +.\openxer-cli.exe baseline add --input C:\Schedules\workspace.db --workspace-id 3 --output C:\Schedules\b1.db +.\openxer-cli.exe baseline set --input C:\Schedules\b1.db --workspace-id 3 --output C:\Schedules\b2.db --baseline "TA-27 - B1" --name "Contract plan" --type "Initial Planning Baseline" +.\openxer-cli.exe baseline assign --input C:\Schedules\b2.db --workspace-id 3 --output C:\Schedules\b3.db --project-baseline "Contract plan" --primary "Contract plan" +``` + +- **baseline list** returns `projects`, each with `workspace_id`, `project_id`, `name`, its `baselines` (each `id`, `baseline_id`, `name`, `type`, `data_date`, `date_added`, `last_update_date` and `assigned`: the roles `project`, `primary`, `secondary`, `tertiary` it holds), `assigned` (the Assign Baselines choices: `current`, `none` or a baseline) and the `baseline_types`. +- The edits take `--workspace-id` (the project whose baselines change) and write a copy to `--output` (or preview with `--dry-run`). A baseline (REF) is named by its `id`, its Baseline ID or its name. A refused edit fails with the error code `refused` and writes nothing. +- **add** saves a copy of the project as Baseline ID " - B" and name " - B", n the lowest number no baseline of the project uses; its last update date is the time it was taken. **convert --project N** makes the workspace project N a baseline that keeps its own ID and name, with a blank last update date; the project itself is refused, and so is a project with baselines of its own. **copy** makes another baseline of the project with the next number, the source's data, data date, type and last update date. +- **delete** and **restore** refuse a baseline assigned as the project baseline or as a primary, secondary or tertiary baseline. **restore** makes the baseline a separate project with the same ID and name and an internal project number of its own, filed in the owner's EPS folder; a Project ID already in use is refused. +- **revert** (Revert Project to Baseline) replaces the project's data with the baseline's; the project keeps its ID, name, project baseline and other baselines, and the baseline is not changed. +- **update --baseline REF** runs Maintain Baselines > Update: the baseline takes the project's data by the Update Baseline options and its last update date is set; an assigned baseline may be updated. `--options` is a JSON object of the options by name (omitted ones take the dialog's defaults): General `project_details` (on), `project_udfs`, `risks_issues`, `risk_udfs`, `issue_udfs`, `documents`, `document_udfs`, `wbs_udfs`, `log_to_file` (on) with `log_path` (a log is written only when a path is given), `ignore_last_update` and `run_optimized` (accepted, no effect: every update compares in full); Activities `add_new`, `delete_missing`, `update_existing` (on); Activity `general` (on), `relationships`, `constraints`, `dates`, `wbs` (on), `risks`, `activity_udfs`, `codes` (on), `notebooks` (on), `steps` (on), `step_udfs`, `expenses`, `expense_udfs`, `budget_no_assignments`, `actual_no_assignments`; Resource Assignment `update_assignments`, `update_assignment_budget`, `update_assignment_actual`, `add_assignments` (on), `add_assignment_budget` (on), `add_assignment_actual` (on), `assignment_udfs`, `assignment_codes`. A child option acts only with its parent on. `--activities ID,ID` limits the activities added or updated, as the filters do in the app (the app's `use_filter`, `filters` and `filter_match_all` are kept with the options but evaluated only there; the result echoes the `options` used). Activities are matched by GUID, then by Activity ID, so a renumbered activity is updated rather than deleted and added. The result's `preview` lists `project`, `wbs` and `activities` changes, each `object`, `kind` (`Added`, `Deleted`, `Updated`) and `fields` (`field`, `project`, `baseline`), with the counts; `--dry-run true` returns it and writes nothing. +- **set** changes `--baseline-id`, `--name` and `--type` (a baseline type name, or `none`). **assign** sets `--project-baseline` (`current` or a baseline) and `--primary`, `--secondary`, `--tertiary` (`current`, `none` or a baseline); a slot left out keeps its choice. + +## JSON contract +Every command prints one JSON object on stdout: + +```json +{"schema_version":"1.0","ok":true,"result":{}} +``` + +`apply` (MCP `openxer_apply`) runs an `openxer-changes/1` batch; `openxer-cli.exe --help` lists every operation. Activity codes can be built from nothing: `{"op":"add_code_type","code_type":"Area","scope":"project","max_length":10}` (scope `project`, `eps` or `global`, default `project`; `max_length` 1 to 60, default 60), then `add_code_value` and `set_activity_code`. + +Project funding names its funding source by name (the `FUNDSRC` dictionary, Enterprise > Funding Sources in the app); a project lists each source once. `{"op":"add_project_funding","source":"Capital","amount":250000,"share":40}` adds it (amount and share default to 0; share is a percentage from 0 to 100), `{"op":"set_project_funding","source":"Capital","field":"amount","value":300000}` changes `amount`, `share` or `source` (another source's name), and `{"op":"delete_project_funding","source":"Capital"}` removes it. The rows are `PROJFUND` and export with the project. + +Resources are named by short name (Resource ID). `{"op":"merge_resources","from":["PIPE-2","PIPE.1"],"into":"PIPE"}` merges duplicates (as left by importing XERs from several sources) into one resource: assignments in every project of the file and the activities' primary resource move to `into`; rate rows, role links, resource codes and resource UDF values move unless `into` already has a rate from that date, that role, a value of that code or of that field (then `into` keeps its own); child resources move under `into`, which takes a source calendar only when it has none, and any other table naming the resource is re-pointed. Where `into` and a source are assigned to the same activity the assignments become one: the target's own row stays, budgeted, actual, remaining and this-period units and costs and units per time are summed, start dates take the earliest and finish dates the latest (no actual finish while a combined started assignment is open), the kept row's role, rate type, price and curve stay, and its period rows, assignment codes and assignment UDF values take over the others'. Prices are not recalculated. The resources must be of one type. The result lists what moved (`assignments_moved`, `combined`, `rates`, `roles`, `codes`, `udf_values`, `child_resources`, `calendar_taken`, `other_rows`) and a readable `summary`; run it with `--dry-run` (MCP `dry_run`) to preview. `{"op":"delete_resource","resource":"SPARE"}` deletes a resource with no assignments and no child resources. + +`{"op":"set_wbs_earned_value","wbs":"RB.3","performance":"custom","custom_percent":35,"estimate_to_complete":"pf","performance_factor":1.25}` sets a WBS element's earned value techniques (`wbs` "" is the project node, which elements without their own settings follow). `performance` is `activity_percent`, `wbs_milestones`, `0/100`, `50/50` or `custom` (with `custom_percent` 0 to 100); `estimate_to_complete` is `remaining`, `pf_1`, `pf_cpi`, `pf_cpi_spi` or `pf` (with `performance_factor` above 0). XER codes (`EC_50_50`, `EE_PF_cpi`) are accepted too. They are the `PROJWBS` fields `ev_compute_type`, `ev_user_pct`, `ev_etc_compute_type` and `ev_etc_user_value`, which the earned value columns read and which export with the WBS. + +Errors are `{"schema_version":"1.0","ok":false,"error":{"code":"output_exists","message":"..."}}`. The exit status is 0 for success, 2 for invalid arguments or requests (error code `invalid_arguments` or `invalid_changes`, whether the command line or the request was wrong) and 1 for any other failed command. `--help` and `--version` print plain text. Paths are local to the process; the Windows executable expects Windows paths. + +Dates in results are project-local `YYYY-MM-DD HH:MM` strings or `null`; there is no time zone conversion. In `load`, `schedule` and `relationship` requests and results, durations, lags and floats are whole **working minutes**; the edit operations take hours. + +Error codes: `invalid_arguments`, `not_found`, `refused`, `invalid_changes`, `invalid_source`, `invalid_relationship`, `invalid_spreadsheet`, `project_not_found`, `ambiguous_project`, `relationship_not_found`, `ambiguous_relationship`, `template_not_found`, the document read codes above, `unsupported_schedule`, `schedule_rejected`, `operation_failed`, `milestone_assignment` (an edit would give a milestone a resource or role assignment), `import_rejected`, `export_rejected`, `export_failed`, `output_exists`, `io_error`, `no_baseline` (compare: no stored baseline assigned), `invalid_skill` and `write_failed` (skills). Unknown request fields are refused. A failed edit or schedule leaves the project unchanged. + +## MCP + +Run the same executable with `mcp`. Only newline-delimited JSON-RPC goes to stdout; diagnostics go to stderr. The process exits when stdin closes. Example client configuration: + +```json +{ + "mcpServers": { + "openxer": { + "command": "C:\\Tools\\OpenXER\\openxer-cli.exe", + "args": ["mcp"] + } + } +} +``` + +The release package ships this block as `openxer.mcp.json` with `` in place of the path; put the full path of your copy there, or let `openxer-cli connect` (below) write the entry. + +Tools: + +| Tool | Writes | Same as | +| --- | --- | --- | +| `openxer_find_schedules` | no | `find-schedules` | +| `openxer_inspect` | no | `inspect` | +| `openxer_load` | no | `load` | +| `openxer_check_schedule` | no | `check-schedule` | +| `openxer_playbook` | no | `playbook` | +| `openxer_curves` | no | `curves` | +| `openxer_usage` | no | `usage` | +| `openxer_import` | yes | `import` | +| `openxer_schedule` | yes | `schedule` | +| `openxer_relationship` | yes | `relationship` | +| `openxer_apply` | yes | `apply` (`changes` holds the document itself, or `changes_file` a path) | +| `openxer_set_activity` | yes | `set-activity` | +| `openxer_add_activity` | yes | `add-activity` | +| `openxer_delete_activity` | yes | `delete-activity` | +| `openxer_dissolve_activity` | yes | `dissolve-activity` | +| `openxer_assign` | yes | `assign` | +| `openxer_unassign` | yes | `unassign` | +| `openxer_set_assignment` | yes | `set-assignment` | +| `openxer_calendar_day` | yes | `calendar-day` | +| `openxer_calendar_weekday` | yes | `calendar-weekday` | +| `openxer_set_project` | yes | `set-project` | +| `openxer_add_wbs` | yes | `add-wbs` | +| `openxer_add_document` | yes | `add-document` | +| `openxer_set_document` | yes | `set-document` | +| `openxer_delete_document` | yes | `delete-document` | +| `openxer_link_document` | yes | `link-document` | +| `openxer_unlink_document` | yes | `unlink-document` | +| `openxer_add_expense`, `openxer_set_expense`, `openxer_delete_expense` | yes | `add-expense`, `set-expense`, `delete-expense` | +| `openxer_add_issue`, `openxer_set_issue`, `openxer_delete_issue` | yes | `add-issue`, `set-issue`, `delete-issue` | +| `openxer_add_risk`, `openxer_set_risk`, `openxer_delete_risk`, `openxer_assign_risk`, `openxer_unassign_risk` | yes | `add-risk`, `set-risk`, `delete-risk`, `assign-risk`, `unassign-risk` | +| `openxer_add_threshold`, `openxer_set_threshold`, `openxer_delete_threshold` | yes | `add-threshold`, `set-threshold`, `delete-threshold` | +| `openxer_monitor_thresholds` | yes | `monitor-thresholds` | +| `openxer_update_progress`, `openxer_apply_actuals`, `openxer_recalculate_costs`, `openxer_top_down_estimate` | yes | `update-progress`, `apply-actuals`, `recalculate-costs`, `top-down-estimate` | +| `openxer_add_step`, `openxer_set_step`, `openxer_delete_step`, `openxer_move_step`, `openxer_add_steps_from_template`, `openxer_create_step_template` | yes | `add-step`, `set-step`, `delete-step`, `move-step`, `add-steps-from-template`, `create-step-template` | +| `openxer_set_feedback` | yes | `set-feedback` | +| `openxer_shift_wbs`, `openxer_rename_wbs_code` | yes | `shift-wbs`, `rename-wbs-code` | +| `openxer_global_change` | yes | `global-change` | +| `openxer_copy_calendar`, `openxer_rename_calendar`, `openxer_set_default_calendar`, `openxer_convert_calendar` | yes | `copy-calendar`, `rename-calendar`, `set-default-calendar`, `convert-calendar` | +| `openxer_records` | no | `records` | +| `openxer_earned_value` | no | `earned-value` | +| `openxer_documents` | no | `documents` | +| `openxer_read_document` | no | `read-document` | +| `openxer_export` | yes | `export` | +| `openxer_export_xlsx` | yes | `export-xlsx` | +| `openxer_import_xlsx` | yes | `import-xlsx` | +| `openxer_export_pdf` | yes | `export-pdf` | +| `openxer_export_scurve` | yes | `export-scurve` | +| `openxer_export_earned_hours` | yes | `export-earned-hours` | +| `openxer_eps_list` | no | `eps list` | +| `openxer_eps_edit` | yes | the `eps` edits (`op` is `add_folder`, `rename_folder`, `move_folder`, `delete_folder`, `file_project` or `create_project`, with the edit's fields beside it; `delete_folder` takes `delete_projects`) | +| `openxer_workspace_migrate` | yes | `workspace migrate` | +| `openxer_workspace_dictionary` | no | `workspace dictionary` | +| `openxer_workspace_dictionary_usage` | no | `workspace dictionary-usage` | +| `openxer_workspace_preference` | with `value` | `workspace preference` | +| `openxer_baseline_list` | no | `baseline list` | +| `openxer_baseline_update` | yes | `baseline update` (`workspace_id`, `baseline`, `options`, `activities`, `dry_run`) | +| `openxer_baseline_edit` | yes | the `baseline` edits (`workspace_id`, and `op` is `add`, `convert`, `copy`, `delete`, `restore`, `revert`, `set` or `assign`, with the edit's fields beside it) | +| `openxer_check_schedule`, `openxer_paths`, `openxer_compare`, `openxer_lookahead`, `openxer_milestones` | no | `check-schedule`, `paths`, `compare`, `lookahead`, `milestones` | +| `openxer_schedule_stats`, `openxer_resource_loading`, `openxer_wbs_summary` | no | `schedule-stats`, `resource-loading`, `wbs-summary` | +| `openxer_skills`, `openxer_skill` | no | `skills list`, `skills show` | + +Prompts: one per skill (`prompts/list`, `prompts/get` with the skill id as `name`); the message is the skill's instructions after the rules every skill follows. The list is read from the skill folder on each request. + +A new agent asked "Use OpenXER to inspect my schedule" has no file name. `openxer_find_schedules` (no arguments; the server's instructions say to call it first) answers with the OpenXER workspace on this PC, found by the app's own rule (`OPENXER_DATA_DIR`; an installed copy's `%LOCALAPPDATA%\OpenXER\openxer.db`, on other systems `$XDG_DATA_HOME/OpenXER/openxer.db` or `~/.local/share/OpenXER/openxer.db`; a portable copy's `openxer.db` beside the executables) plus the other kind of copy's workspace when there is one, each with its projects most recently saved first (`workspace_id`, `project_id`, `name`, `source_name`, `saved_utc`; at most 100, with `project_count`). `folder` (an absolute path) also lists the `.xer` files and workspaces directly in that folder, newest first. It only reads: workspaces are opened read-only and nothing is written. The agent then passes the workspace as `input` with a `workspace_id`. + +`tools/list` gives strict JSON schemas and read and write annotations. Arguments are the CLI's JSON request without its `command` field; the edit tools take the operation's fields at the top level next to `input`, `output`, `project_id`, `workspace_id`, `dry_run` and `recalculate`. Results carry the same JSON envelope in both `structuredContent` and the text content. A failed command sets `isError`; malformed arguments return JSON-RPC `-32602`. + +The server implements the [2026-07-28 stdio transport](https://modelcontextprotocol.io/specification/2026-07-28/basic/transports/stdio), including self-contained request metadata, `server/discover` and completed results. A discovery request: + +```json +{"jsonrpc":"2.0","id":1,"method":"server/discover","params":{"_meta":{"io.modelcontextprotocol/protocolVersion":"2026-07-28","io.modelcontextprotocol/clientCapabilities":{}}}} +``` + +`tools/list`, `tools/call`, `prompts/list` and `prompts/get` requests carry the same `_meta` fields on **every request**. An unsupported version returns `-32022` with `requested` and `supported`, as the [protocol schema](https://modelcontextprotocol.io/specification/2026-07-28/schema) specifies. + +### The chat tool set + +`openxer-cli mcp --toolset chat [--snapshot FILE] [--mode ask|edit]` serves the small tool set of OpenXER's Chat window instead of every tool (plain `mcp` is unchanged). Every tool described costs the agent tokens on every turn, so the chat set is seven read tools, `openxer_load`, `openxer_records`, `openxer_earned_value`, `openxer_usage`, `openxer_documents`, `openxer_check_schedule` and `openxer_playbook`, plus `openxer_apply` in Edit mode (Ask, the default, is read-only), with short descriptions and server instructions: about 4 KB for Ask and 6 KB for Edit against about 108 KB for the full set. The tools are built from the same definitions and run through the same dispatcher as the full set: + +- With `--snapshot` every call reads that project file, so the tools take no `input` (nor `project_id`, `workspace_id` or `output`). Without it each call names its `input`. +- `openxer_load` returns `task_code`, `name`, `status`, `early_start`, `early_finish` and `total_float_minutes` for 50 activities (and 50 relationships) a page unless the call asks otherwise. +- `openxer_apply` only proposes: it always runs as a dry run on the snapshot and never writes a file. The result carries the field diff with `"proposed": true`; the app applies the batch when the user approves it. +- A result over 40,000 bytes of JSON is refused with `result_too_large` and a hint to ask for less. +- Results are sent as text only, with no `structuredContent`, so nothing is sent twice. + +The same tools run in-process through `chat_tools::tools`, `chat_tools::call` and `chat_tools::preamble` (see below), so a chat provider that runs tools itself behaves exactly like the MCP server. + +For existing clients the server also supports the [initialize lifecycle](https://modelcontextprotocol.io/specification/2025-11-25/basic/lifecycle) for `2025-11-25`, `2025-06-18` and `2024-11-05`: `initialize`, `notifications/initialized`, then tool requests. No project selection carries over between calls. The server offers synchronous tools and the skill prompts; it has no sampling, elicitation, resource subscriptions, asynchronous tasks or model of its own. The host application chooses the model and talks to the user. + +## Connecting + +`openxer-cli connect` adds this MCP server to an AI client for you; the desktop's **AI Agents** menu runs the same code. Every result uses the JSON envelope above. + +``` +openxer-cli connect status +openxer-cli connect all [--dry-run] +openxer-cli connect claude-desktop [--disconnect] [--dry-run] +openxer-cli connect chatgpt [--disconnect] [--dry-run] (the same as codex) +openxer-cli connect codex [--disconnect] [--dry-run] +openxer-cli connect claude-code +openxer-cli connect prompt +openxer-cli connect test +``` + +- `status` lists each client (`claude-desktop`; `codex`, named "ChatGPT desktop and Codex"; `claude-code`) with `found` (installed on this PC), its config files, the `openxer` entry's `state` and the one `action` to take. States: `connected`; `not_connected`; `other_copy` (the entry runs `mcp` with another `openxer-cli` that exists, with `installed` true when the installer's `openxer.installed` marker is beside it); `stale` (the entry runs a file that no longer exists, or other arguments); `malformed` (the file cannot be parsed). Actions, which the desktop's dialog shows as its one button: `connect` (found, not connected), `connected`, `use_this_copy` (`other_copy`), `repair` (`stale`), `not_installed` (not found and no entry), `fix_file` (`malformed`) and `copy_command` (Claude Code found). `cli_installed` says whether this `openxer-cli` is an installed copy. +- `claude-desktop` edits `claude_desktop_config.json` in `%APPDATA%\Claude\` and, for a Microsoft Store install, in each `%LOCALAPPDATA%\Packages\Claude_*\LocalCache\Roaming\Claude\` (a Store copy that does not exist yet starts from the classic file, so its other servers stay visible). The entry is `"mcpServers": {"openxer": {"command": "", "args": ["mcp"]}}`. Claude Desktop reads it only when it starts: quit it from its tray icon (closing the window is not enough) and open it again. +- `codex` (or `chatgpt`) edits `%USERPROFILE%\.codex\config.toml` (or `%CODEX_HOME%\config.toml`), shared by the Codex app and CLI and, as reported for Windows, by the ChatGPT desktop app: table `[mcp_servers.openxer]` with `command` and `args = ["mcp"]`. The path is written as a TOML literal string (`command = 'C:\...'`) so no backslash is ever read as an escape (a basic string, escaped, only when the path holds a single quote). It counts as found when `.codex` exists, `codex` is on `PATH`, `%LOCALAPPDATA%\OpenAI\Codex` exists or a Store package `OpenAI.ChatGPT*` or `OpenAI.Codex_*` is installed. In the ChatGPT desktop app local tools are reported to work in its Work and Codex modes; plain Chat may not use them. +- `all` connects every app that is found and not connected or needs repair (`connect` and `repair` actions), one after another; one failing does not stop the others. An app connected to another copy of OpenXER is never switched by `all`: run its own command for that. Each result has `client`, `ok`, `message` and `files`. +- Only the `openxer` entry is added, updated (the command and arguments are replaced in place; other fields of the entry such as `env` stay) or removed (`--disconnect`). Every other byte of the file (other servers, settings, comments, spacing, key order, line ends, a byte order mark) is kept as it was. Running `connect` on an app connected to another copy switches it to this copy ("Use this copy"), and on one that needs repair repairs it. +- Before a file changes it is copied to `.openxer-backup-` (UTC). The new text is written atomically, read back and checked (our entry in its new state, everything else unchanged); a failed check puts the original back. Missing folders and files are created. +- A config that cannot be parsed is never written: the command fails with `config_malformed`. A read-only config is never written either (`config_read_only`). Fix the file, or add the entry by hand from the example under MCP. +- `--dry-run` returns each file's new text as `preview` and writes nothing. +- `claude-code` prints the command to run yourself (`claude mcp add --scope user openxer -- "" mcp`); OpenXER never runs it. +- `prompt` prints (as `prompt`) a short setup prompt to paste into any AI tool that can run commands: the quoted path of this `openxer-cli`, to run `--help`, to add an MCP server named `openxer` that runs it with the argument `mcp` (or to call the CLI directly, as every command prints JSON), to check it with `connect test`, the safety rules (inputs never changed, edits go to new files, `--dry-run` to preview) and a first request. The desktop's **Copy Setup Prompt** in Connect AI Agents copies the same text. +- `test` starts `openxer-cli mcp`, initializes a session, lists the tools and stops the server: `"message": "Working: N tools"`. +- After a connect, `message` and `next_step` say what to do in the app and the first thing to ask ("Use OpenXER to inspect my schedule."). The command written is the `openxer-cli` you ran; the desktop uses the copy next to `OpenXER.exe` (or `OPENXER_CLI`). + +Errors: `cli_missing`, `config_malformed`, `config_read_only`, `config_unknown`, `validation_failed`, `test_failed`, `unsupported`, `io_error`, `invalid_arguments`. There is no MCP tool for this: an agent does not rewrite its own client's config. + +## Chat agent host + +`agent_host` is what the desktop's Chat window drives: it starts an AI agent already installed on the PC (Claude Code or Codex) as a child process, which uses its own sign-in. OpenXER holds no key and makes no network calls itself. The agent gets only the chat tool set above: no command-running or file tools, the user's own agent settings, hooks, instruction files and other MCP servers ignored, and in Ask mode no edit tool. + +- Claude Code runs as `claude -p --restricted --strict-mcp-config --disable-slash-commands --tools "" --input-format stream-json --output-format stream-json --include-partial-messages --permission-prompts none --mcp-config --allowedTools --system-prompt `, with `CLAUDE_CODE_DISABLE_CLAUDE_MDS=1` and `CLAUDE_CODE_DISABLE_AUTO_MEMORY=1` so no CLAUDE.md file and no auto memory is read. One process serves the whole conversation (each message is one more stdin line; after a cancel, `--resume `). `--model sonnet` is the lower cost choice. +- Codex runs as `codex exec --json --skip-git-repo-check --ignore-user-config --ignore-rules ... -- -` with `sandbox_mode="read-only"`, `approval_policy="never"`, web search off, `project_doc_max_bytes=0` (no AGENTS.md from the work folder or above it), its command, sub-agent, plugin, app, skill, browser and image features disabled, `model_instructions_file` holding OpenXER's rules in place of its own, and the chat server as `mcp_servers.openxer` (with 30 seconds to start); each later turn is `codex exec resume ... -- -`. `-m gpt-6-luna` with low reasoning effort is the lower cost choice. Codex still reads `AGENTS.override.md` or `AGENTS.md` in its own home folder (`CODEX_HOME`, by default `%USERPROFILE%\.codex`): no documented setting turns that off, so `detect` reports such a file as `user_instructions` for the window to mention. What Codex keeps of its own tools: a script tool that runs JavaScript with no file system or network and only calls other tools (the OpenXER tools, MCP resource listing, the clock and `apply_patch`, whose writes the read-only sandbox with `approval_policy="never"` refuses), and its sub-agent tools, whose agents run with the same settings. +- Messages, the preamble and every other piece of schedule or user text go to the agent on stdin, never on a command line; the command line holds only fixed flags and paths the host makes, and model names (letters, digits and `.-_:/[]`) and ids the agent gave (UUIDs) are checked first. A `.cmd` or `.bat` install is started by the standard library, which quotes for batch files and refuses what it cannot pass safely (error `Failed`, with what to do). +- `Session::start(SessionOptions, Arc)` gives the session and a receiver of `Event`s (`Ready`, `TextDelta`, `Message`, `ToolStarted`, `ToolFinished`, `ProposedChanges`, `TurnFinished` with the turn's own token usage and, for Claude Code, the turn's cost, and `Error`). `send`, `cancel` and `end` never block. `cancel` stops the agent and sends the cancelled `TurnFinished` at once. Every child runs in a Windows job object, so stopping it, ending the session or dropping it ends the agent and every process it started. Tool and proposal ids carry the process they came from, so they are unique in a session. Output is read as bytes; invalid UTF-8 never stops the reading. An `openxer_apply` call the agent makes becomes `ProposedChanges` with the batch and its diff; `chat_tools::apply_proposal(&mut ProjectData, changes)` applies it exactly as it was previewed (the chat apply takes no `recalculate` of its own: only the document's counts). +- Both agents keep their own copy of a conversation, tool results with schedule data included: Claude Code under `%USERPROFILE%\.claude\projects\\`, Codex under `%USERPROFILE%\.codex\sessions\` (both are needed to resume after a cancel or for a later turn). Ending or dropping a session deletes them with the agents' own commands, `claude purge -y ` (only for a work folder the session made itself) and `codex delete --force `, on a background thread (`forget_conversation` runs them on their own), and removes the conversation's files: its work folder when the session made it (with the agent config and a snapshot inside it). `SessionOptions::keep_files` keeps everything. +- `detect` reports whether each agent is installed (its executable on `PATH` from an injected `connect::Env`), its version and whether it is signed in (`claude auth status --json`, `codex login status`). Each check is stopped after 10 seconds, so `detect` may take up to 20 seconds and `detect_all` 40 (normally about a second); `detect_all_in_background` returns at once with a receiver the window polls. `SignIn::start` runs the agent's own sign-in (`claude auth login`, `codex login`), which opens the browser. +- The instructions every assistant gets are `chat_prompt::system_prompt(mode, user)`: a scheduling core of about 1,300 characters (`chat_prompt::CORE`: work from the schedule, think in logic and float, propose the smallest edits and wait for approval, write for the field, load the matching playbook), the user's standing instructions, and the mode line. Claude Code reads them with `--system-prompt-file` and Codex with `model_instructions_file`, from a file in the work folder, never from the command line. The methods are playbooks the assistant fetches with `openxer_playbook` only when it needs one. +- The user's standing instructions live in `chat\AGENTS.md` in the OpenXER data folder (`chat_prompt::data_folder`, the folder of the workspace, so `OPENXER_DATA_DIR` moves it too). `chat_prompt::read_user_instructions(&path)` returns their text without `` comments, at most 4,000 characters with a flag when cut, or none for a missing, empty or comment-only file; UTF-8 with or without a byte order mark and UTF-16 with one are read, anything else leniently. `chat_prompt::create_user_instructions(&path)` writes a short commented starter when the file does not exist and never touches one that does. OpenXER passes this file in on purpose; the agents' own discovery of instruction files stays off. +- `chat_tools::preamble(&ProjectData, &selected)` writes the few lines the first message carries (project, data date, scheduled and must finish dates, counts, the selected activities), so the agent rarely needs a discovery call. +- `edit::apply_changes(&mut ProjectData, changes, recalculate, &EvContext)` applies a changes document to a project in memory through the same parsing and setters as `apply`, all or nothing. + +Process starts go through the `Spawner` trait, so the tests run every path against a scripted fake agent and the parsers against trimmed recordings of real runs on the synthetic sample (`tests/fixtures/agent/`). `tests/agent_live.rs` holds ignored tests that run the real agents on the sample: an answer and a proposed edit over two turns, the stored copies deleted at the end, and no instruction file of the user's read. + +## In-process use and tests + +`dispatch(Command)` runs the same file workflow as the CLI and MCP. `schedule_project(&mut ProjectData, &SchedulePatch)` and `edit_relationship(&mut ProjectData, &RelationshipEdit)` work on a project already in memory; they validate and work on a copy before committing. Writing files is then the caller's job. + +Run `cargo test -p openxer-automation`. The tests cover CLI and native schedule parity, every edit operation in both rules and exact modes, dry runs, `meta`, CLI and MCP building the same edits, cycle refusal, source preservation, workspace and encoding round trips, all-or-nothing batches, completed-date visibility, paging, and MCP through a real child process. diff --git a/automation/build.rs b/automation/build.rs new file mode 100644 index 0000000..68b7d51 --- /dev/null +++ b/automation/build.rs @@ -0,0 +1,39 @@ +//! Embed the version information in `openxer-cli.exe` without requiring a +//! separate rc.exe (`tools/winres.rs` writes the .res file). +use std::{env, fs, io, path::PathBuf}; + +#[path = "../tools/winres.rs"] +mod winres; + +fn main() -> io::Result<()> { + println!("cargo:rerun-if-changed=../tools/winres.rs"); + println!("cargo:rerun-if-changed=../LICENSE-MIT"); + // Other targets, and Windows builds without the MSVC linker, get no + // version resource; the command line works the same without it. + if env::var("CARGO_CFG_TARGET_OS").as_deref() != Ok("windows") + || env::var("CARGO_CFG_TARGET_ENV").as_deref() != Ok("msvc") + { + return Ok(()); + } + let version = env::var("CARGO_PKG_VERSION").expect("Cargo sets CARGO_PKG_VERSION"); + let copyright = winres::copyright_line(&fs::read_to_string("../LICENSE-MIT")?); + let info = winres::version_info( + &version, + &[ + ("FileDescription", "OpenXER command line and MCP server"), + ("FileVersion", &version), + ("InternalName", "openxer-cli"), + ("LegalCopyright", ©right), + ("OriginalFilename", "openxer-cli.exe"), + ("ProductName", "OpenXER"), + ("ProductVersion", &version), + ], + ); + let mut out = winres::new_res(); + winres::resource(&mut out, winres::RT_VERSION, 1, winres::LANG_EN_US, &info); + let path = PathBuf::from(env::var_os("OUT_DIR").expect("Cargo sets OUT_DIR")) + .join("openxer-cli-version.res"); + fs::write(&path, winres::finish_res(out))?; + println!("cargo:rustc-link-arg-bin=openxer-cli={}", path.display()); + Ok(()) +} diff --git a/automation/src/agent_host/claude.rs b/automation/src/agent_host/claude.rs new file mode 100644 index 0000000..8555898 --- /dev/null +++ b/automation/src/agent_host/claude.rs @@ -0,0 +1,296 @@ +//! Claude Code, driven directly: print mode with JSON lines in and out +//! (`--input-format stream-json --output-format stream-json`), one process +//! for the whole conversation (each message is one more stdin line), and +//! `--resume` with its session id when the process had to be stopped. +use super::{ + classify_failure, tool_target, AgentError, Event, ModelChoice, SessionOptions, ToolCall, Usage, +}; +use crate::chat_tools::{self, ChatMode}; +use serde_json::{json, Value}; +use std::collections::BTreeMap; +use std::path::{Path, PathBuf}; +use std::time::Instant; + +/// The prefix Claude Code gives the tools of the OpenXER server. +pub const TOOL_PREFIX: &str = "mcp__openxer__"; + +/// The model alias of the lower cost choice, as `claude --help` names +/// the aliases (fable, opus, sonnet). +pub const LOWER_COST_MODEL: &str = "sonnet"; + +/// The MCP config file of a session: only the OpenXER chat server. +pub fn mcp_config(options: &SessionOptions) -> Value { + json!({"mcpServers":{"openxer":{ + "command": options.cli, + "args": chat_tools::server_arguments(&options.chat_context()), + "env": {"OPENXER_DATA_DIR": options.data_dir} + }}}) +} + +/// The tools the agent may call: exactly the chat tools of the mode. +pub fn allowed_tools(mode: ChatMode) -> Vec { + chat_tools::tools_for(mode, true) + .iter() + .map(|t| format!("{TOOL_PREFIX}{}", t.name)) + .collect() +} + +/// The arguments: no built-in tools, the user's settings, hooks and other +/// MCP servers ignored, only the OpenXER tools allowed, nothing asks for +/// permission, and OpenXER's rules as the whole system prompt. +pub fn arguments( + options: &SessionOptions, + config: &Path, + instructions: &Path, + resume: Option<&str>, +) -> Result, AgentError> { + let mut args: Vec = [ + "-p", + "--verbose", + "--restricted", + "--strict-mcp-config", + "--disable-slash-commands", + "--input-format", + "stream-json", + "--output-format", + "stream-json", + "--include-partial-messages", + "--tools", + "", + "--permission-prompts", + "none", + ] + .iter() + .map(|s| s.to_string()) + .collect(); + args.push("--mcp-config".into()); + args.push(config.display().to_string()); + args.push("--allowedTools".into()); + args.push(allowed_tools(options.mode).join(",")); + // The instructions come from a file: they hold the user's own text, + // which never goes on a command line. + args.push("--system-prompt-file".into()); + args.push(instructions.display().to_string()); + match &options.model { + ModelChoice::AgentDefault => {} + ModelChoice::LowerCost => { + args.push("--model".into()); + args.push(LOWER_COST_MODEL.into()); + } + ModelChoice::Named(name) => { + super::check_model_name(name)?; + args.push("--model".into()); + args.push(name.clone()); + } + } + if let Some(id) = resume { + if !super::codex::valid_thread_id(id) { + return Err(AgentError::Failed { + message: format!("Claude Code gave an unexpected session id {id:?}"), + }); + } + args.push("--resume".into()); + args.push(id.into()); + } + Ok(args) +} + +/// The environment the hosted Claude Code runs with: none of the user's +/// CLAUDE.md files (user, project or parent folders) and no auto memory +/// are loaded (`CLAUDE_CODE_DISABLE_CLAUDE_MDS`, +/// `CLAUDE_CODE_DISABLE_AUTO_MEMORY`, both documented for any mode). +pub const ENVIRONMENT: &[(&str, &str)] = &[ + ("CLAUDE_CODE_DISABLE_CLAUDE_MDS", "1"), + ("CLAUDE_CODE_DISABLE_AUTO_MEMORY", "1"), +]; + +/// One user message as a stdin line. +pub fn user_line(text: &str) -> String { + json!({"type":"user","message":{"role":"user","content":[{"type":"text","text":text}]}}) + .to_string() +} + +/// Where the session writes its MCP config. +pub fn config_path(options: &SessionOptions) -> PathBuf { + options.work_dir.join("openxer-chat-mcp.json") +} + +/// Claude Code's output lines to events. A pure state machine: it holds +/// only what later lines refer to (open tool calls, the session id). +#[derive(Debug, Default)] +pub struct ClaudeParser { + /// The conversation's session id, from the `system` `init` line. + pub session_id: Option, + open: BTreeMap, + cost_so_far: f64, +} + +fn text_of(content: &Value) -> String { + match content { + Value::String(s) => s.clone(), + Value::Array(items) => items + .iter() + .filter_map(|i| i["text"].as_str()) + .collect::>() + .join("\n"), + _ => String::new(), + } +} + +impl ClaudeParser { + pub fn new() -> Self { + Self::default() + } + + /// The events of one output line, `now` being when it arrived. + pub fn parse_line(&mut self, line: &str, now: Instant) -> Vec { + let line = line.trim(); + if line.is_empty() { + return vec![]; + } + let Ok(v) = serde_json::from_str::(line) else { + return vec![Event::Error { + error: AgentError::BadOutput { + line: super::clip(line, 200), + }, + }]; + }; + match v["type"].as_str().unwrap_or("") { + "system" if v["subtype"] == "init" => { + if let Some(id) = v["session_id"].as_str() { + self.session_id = Some(id.to_string()); + } + let mut events = vec![Event::Ready { + model: v["model"].as_str().unwrap_or("").to_string(), + }]; + let server = v["mcp_servers"] + .as_array() + .and_then(|list| list.iter().find(|s| s["name"] == "openxer")); + let status = server + .and_then(|s| s["status"].as_str()) + .unwrap_or("missing"); + if status != "connected" { + events.push(Event::Error { + error: AgentError::Failed { + message: format!("The OpenXER tools did not start ({status})."), + }, + }); + } + events + } + "stream_event" => { + let e = &v["event"]; + if e["type"] == "content_block_delta" && e["delta"]["type"] == "text_delta" { + let text = e["delta"]["text"].as_str().unwrap_or(""); + if !text.is_empty() { + return vec![Event::TextDelta { + text: text.to_string(), + }]; + } + } + vec![] + } + "assistant" => { + let mut events = vec![]; + for block in v["message"]["content"].as_array().into_iter().flatten() { + match block["type"].as_str() { + Some("text") => { + let text = block["text"].as_str().unwrap_or(""); + if !text.trim().is_empty() { + events.push(Event::Message { + text: text.to_string(), + }); + } + } + Some("tool_use") => { + let id = block["id"].as_str().unwrap_or("").to_string(); + let name = block["name"].as_str().unwrap_or(""); + let tool = name.strip_prefix(TOOL_PREFIX).unwrap_or(name).to_string(); + let input = block["input"].clone(); + events.push(Event::ToolStarted { + id: id.clone(), + tool: tool.clone(), + target: tool_target(&tool, &input), + }); + self.open.insert( + id, + ToolCall { + tool, + input, + started: now, + }, + ); + } + _ => {} + } + } + events + } + "user" => { + let mut events = vec![]; + for block in v["message"]["content"].as_array().into_iter().flatten() { + if block["type"] != "tool_result" { + continue; + } + let id = block["tool_use_id"].as_str().unwrap_or("").to_string(); + let call = self.open.remove(&id); + let text = text_of(&block["content"]); + events.extend(super::tool_finished( + id, + call, + block["is_error"] == true, + &text, + now, + )); + } + events + } + "result" => { + let mut events = vec![]; + let failed = v["is_error"] == true + || v["subtype"] + .as_str() + .is_some_and(|s| s != "success" && !s.is_empty()); + if failed { + let message = v["result"] + .as_str() + .filter(|s| !s.is_empty()) + .map(str::to_string) + .or_else(|| v["errors"].as_array().map(|e| text_of(&json!(e)))) + .unwrap_or_else(|| { + format!("The reply failed ({})", v["subtype"].as_str().unwrap_or("")) + }); + events.push(Event::Error { + error: classify_failure(super::Agent::ClaudeCode, &message), + }); + } + let u = &v["usage"]; + let n = |k: &str| u[k].as_u64().unwrap_or(0); + let cached = n("cache_read_input_tokens"); + // total_cost_usd adds up the whole process; the turn's own + // cost is per model since the last result. + let total = v["total_cost_usd"].as_f64(); + let turn = v["model_usage_since_last_result"] + .as_object() + .map(|models| models.values().filter_map(|m| m["costUSD"].as_f64()).sum()) + .or_else(|| total.map(|t| (t - self.cost_so_far).max(0.0))); + if let Some(total) = total { + self.cost_so_far = total; + } + events.push(Event::TurnFinished { + usage: Usage { + input_tokens: n("input_tokens") + n("cache_creation_input_tokens") + cached, + cached_input_tokens: cached, + output_tokens: n("output_tokens"), + }, + cost_usd: turn, + cancelled: false, + }); + // Tools still open when the turn ends never finished. + self.open.clear(); + events + } + _ => vec![], + } + } +} diff --git a/automation/src/agent_host/codex.rs b/automation/src/agent_host/codex.rs new file mode 100644 index 0000000..161110e --- /dev/null +++ b/automation/src/agent_host/codex.rs @@ -0,0 +1,326 @@ +//! Codex, driven directly: `codex exec --json`, one process per turn, and +//! `codex exec resume ` for each later turn of the conversation. +use super::{ + classify_failure, tool_target, Agent, AgentError, Event, ModelChoice, SessionOptions, ToolCall, + Usage, +}; +use crate::chat_tools; +use serde_json::Value; +use std::collections::BTreeMap; +use std::path::PathBuf; +use std::time::Instant; + +/// The lower cost choice: a model `codex debug models` lists as fast and +/// affordable, at low reasoning effort. +pub const LOWER_COST_MODEL: &str = "gpt-6-luna"; +pub const LOWER_COST_EFFORT: &str = "low"; + +/// Built-in tools and extras switched off (`codex features list` names): +/// commands, sub-agents, plugins, apps, skills, browsing, images, hooks +/// and memories. What stays is the model's script tool that only calls +/// other tools (no file system, no network) and the OpenXER server. +pub const DISABLED_FEATURES: &[&str] = &[ + "shell_tool", + "unified_exec", + "multi_agent", + "multi_agent_v2", + "sleep_tool", + "skill_search", + "plugins", + "apps", + "goals", + "hooks", + "memories", + "image_generation", + "view_image", + "browser_use", + "browser_use_external", + "computer_use", + "in_app_browser", + "tool_suggest", +]; + +/// A TOML string for a `-c key=value` override. +fn toml_string(text: &str) -> String { + toml_edit::Value::from(text).decorated("", "").to_string() +} + +/// Where the session writes the chat's instructions, which replace +/// Codex's own (`model_instructions_file`). +pub fn rules_path(options: &SessionOptions) -> PathBuf { + super::instructions_file(options) +} + +/// Whether `id` is a thread id as Codex gives them (a UUID): the only +/// value from the agent's output that goes back on a command line. +pub fn valid_thread_id(id: &str) -> bool { + id.len() == 36 + && id.chars().enumerate().all(|(i, c)| { + if [8, 13, 18, 23].contains(&i) { + c == '-' + } else { + c.is_ascii_hexdigit() + } + }) +} + +/// The arguments of one turn: fixed flags and paths only. The prompt is +/// read from stdin (`-`), after `--` so nothing in it is ever a flag. +/// `resume` is the thread to continue. +pub fn arguments( + options: &SessionOptions, + resume: Option<&str>, +) -> Result, AgentError> { + let mut args: Vec = vec!["exec".into()]; + if let Some(thread) = resume { + if !valid_thread_id(thread) { + return Err(AgentError::Failed { + message: format!("Codex gave an unexpected thread id {thread:?}"), + }); + } + args.push("resume".into()); + } + for a in [ + "--json", + "--skip-git-repo-check", + "--ignore-user-config", + "--ignore-rules", + ] { + args.push(a.into()); + } + let mut config = |key: &str, value: String| { + args.push("-c".into()); + args.push(format!("{key}={value}")); + }; + config("sandbox_mode", toml_string("read-only")); + config("approval_policy", toml_string("never")); + config("web_search", toml_string("disabled")); + config("skills.include_instructions", "false".into()); + config("include_permissions_instructions", "false".into()); + config("include_environment_context", "false".into()); + // No AGENTS.md from the work folder or above it. + config("project_doc_max_bytes", "0".into()); + config( + "model_instructions_file", + toml_string(&rules_path(options).display().to_string()), + ); + config( + "mcp_servers.openxer.command", + toml_string(&options.cli.display().to_string()), + ); + let server_args: Vec = chat_tools::server_arguments(&options.chat_context()) + .iter() + .map(|a| toml_string(a)) + .collect(); + config( + "mcp_servers.openxer.args", + format!("[{}]", server_args.join(", ")), + ); + // Codex's default wait for a server to start is short; a busy PC can + // miss it, and then the chat has no tools at all. + config("mcp_servers.openxer.startup_timeout_sec", "30".into()); + // No answer without the tools: the server must be ready at startup. + config("mcp_servers.openxer.required", "true".into()); + config( + "mcp_servers.openxer.env", + format!( + "{{OPENXER_DATA_DIR={}}}", + toml_string(&options.data_dir.display().to_string()) + ), + ); + match &options.model { + ModelChoice::AgentDefault => {} + ModelChoice::LowerCost => { + config("model_reasoning_effort", toml_string(LOWER_COST_EFFORT)); + args.push("-m".into()); + args.push(LOWER_COST_MODEL.into()); + } + ModelChoice::Named(name) => { + super::check_model_name(name)?; + args.push("-m".into()); + args.push(name.clone()); + } + } + for feature in DISABLED_FEATURES { + args.push("--disable".into()); + args.push((*feature).into()); + } + args.push("--".into()); + if let Some(thread) = resume { + args.push(thread.into()); + } + args.push("-".into()); + Ok(args) +} + +/// Codex's output lines to events. A pure state machine like the Claude +/// parser; `thread_id` is the conversation to resume. +#[derive(Debug, Default)] +pub struct CodexParser { + pub thread_id: Option, + /// The model label `Ready` reports (Codex does not name it). + pub model: String, + open: BTreeMap, +} + +/// A tool call's arguments: an object, or JSON text of one. +fn arguments_of(item: &Value) -> Value { + match &item["arguments"] { + Value::String(s) => serde_json::from_str(s).unwrap_or(Value::Null), + other => other.clone(), + } +} + +fn result_text(item: &Value) -> String { + let result = &item["result"]; + let content = result["content"] + .as_array() + .map(|items| { + items + .iter() + .filter_map(|i| i["text"].as_str()) + .collect::>() + .join("\n") + }) + .unwrap_or_default(); + if !content.is_empty() { + return content; + } + if !result["structured_content"].is_null() { + return result["structured_content"].to_string(); + } + item["error"]["message"] + .as_str() + .map(str::to_string) + .unwrap_or_default() +} + +impl CodexParser { + pub fn new(model: impl Into) -> Self { + CodexParser { + model: model.into(), + ..Default::default() + } + } + + pub fn parse_line(&mut self, line: &str, now: Instant) -> Vec { + let line = line.trim(); + if line.is_empty() { + return vec![]; + } + let Ok(v) = serde_json::from_str::(line) else { + return vec![Event::Error { + error: AgentError::BadOutput { + line: super::clip(line, 200), + }, + }]; + }; + let item = &v["item"]; + match v["type"].as_str().unwrap_or("") { + "thread.started" => { + self.thread_id = v["thread_id"].as_str().map(str::to_string); + vec![Event::Ready { + model: self.model.clone(), + }] + } + "item.started" if item["type"] == "mcp_tool_call" => { + let id = item["id"].as_str().unwrap_or("").to_string(); + let tool = item["tool"].as_str().unwrap_or("").to_string(); + let input = arguments_of(item); + let event = Event::ToolStarted { + id: id.clone(), + tool: tool.clone(), + target: tool_target(&tool, &input), + }; + self.open.insert( + id, + ToolCall { + tool, + input, + started: now, + }, + ); + vec![event] + } + "item.completed" => match item["type"].as_str() { + Some("agent_message") => { + let text = item["text"].as_str().unwrap_or(""); + if text.trim().is_empty() { + vec![] + } else { + vec![Event::Message { + text: text.to_string(), + }] + } + } + Some("mcp_tool_call") => { + let id = item["id"].as_str().unwrap_or("").to_string(); + let mut events = vec![]; + let call = match self.open.remove(&id) { + Some(call) => call, + None => { + // Finished without a start line: report both. + let tool = item["tool"].as_str().unwrap_or("").to_string(); + let input = arguments_of(item); + events.push(Event::ToolStarted { + id: id.clone(), + tool: tool.clone(), + target: tool_target(&tool, &input), + }); + ToolCall { + tool, + input, + started: now, + } + } + }; + let failed = item["status"] != "completed" || !item["error"].is_null(); + events.extend(super::tool_finished( + id, + Some(call), + failed, + &result_text(item), + now, + )); + events + } + Some("error") => vec![Event::Error { + error: classify_failure(Agent::Codex, item["message"].as_str().unwrap_or("")), + }], + _ => vec![], + }, + "turn.completed" => { + let u = &v["usage"]; + let n = |k: &str| u[k].as_u64().unwrap_or(0); + self.open.clear(); + vec![Event::TurnFinished { + usage: Usage { + input_tokens: n("input_tokens"), + cached_input_tokens: n("cached_input_tokens"), + output_tokens: n("output_tokens"), + }, + cost_usd: None, + cancelled: false, + }] + } + "turn.failed" => { + self.open.clear(); + let message = v["error"]["message"].as_str().unwrap_or("The turn failed"); + vec![ + Event::Error { + error: classify_failure(Agent::Codex, message), + }, + Event::TurnFinished { + usage: Usage::default(), + cost_usd: None, + cancelled: false, + }, + ] + } + "error" => vec![Event::Error { + error: classify_failure(Agent::Codex, v["message"].as_str().unwrap_or("")), + }], + _ => vec![], + } + } +} diff --git a/automation/src/agent_host/compat.rs b/automation/src/agent_host/compat.rs new file mode 100644 index 0000000..0a839f2 --- /dev/null +++ b/automation/src/agent_host/compat.rs @@ -0,0 +1,223 @@ +//! What the host knows about the agents' versions and how a session copes +//! with an install it was not tested on, plus changing a session's mode or +//! model between messages. +//! +//! The flags the host passes were checked against [`TESTED`] only. An older +//! version still gets a try (the window shows [`version_notice`]); one that +//! refuses a flag or setting at once is reported by [`launch_problem`] as +//! not supported, with the installed version and the first line of what +//! it said, and a launch that never answers ends after [`READY_TIMEOUT`]. +use super::{ + check_model_name, claude, connect, instructions_file, rules, Agent, AgentError, ModelChoice, + Session, +}; +use crate::chat_tools::ChatMode; +use std::path::PathBuf; +use std::time::Duration; + +/// The versions the launch flags were checked on (the first line of each +/// program's `--version`). +pub const TESTED: &[(Agent, &str)] = &[(Agent::ClaudeCode, "2.1.330"), (Agent::Codex, "0.166.0")]; + +/// How long a starting agent may take to say it is ready (its first line +/// of output) before the launch counts as broken. +pub const READY_TIMEOUT: Duration = Duration::from_secs(20); + +/// The version `agent` was tested on. +pub fn tested_version(agent: Agent) -> &'static str { + TESTED + .iter() + .find(|(a, _)| *a == agent) + .map(|(_, v)| *v) + .unwrap_or("") +} + +/// The first `major.minor.patch` in a `--version` line ("2.1.330 (Claude +/// Code)", "codex-cli 0.166.0"). +pub fn parse_version(text: &str) -> Option<(u64, u64, u64)> { + text.split(|c: char| !(c.is_ascii_digit() || c == '.')) + .filter(|w| w.contains('.')) + .find_map(|w| { + let mut parts = w.split('.').filter(|p| !p.is_empty()); + let major = parts.next()?.parse().ok()?; + let minor = parts.next()?.parse().ok()?; + let patch = parts.next().and_then(|p| p.parse().ok()).unwrap_or(0); + Some((major, minor, patch)) + }) +} + +/// The version as the window names it ("2.1.330"), from a `--version` line. +pub fn short_version(text: &str) -> Option { + parse_version(text).map(|(a, b, c)| format!("{a}.{b}.{c}")) +} + +/// One line for an installed version older than the tested one; `None` +/// when it is the same or newer, or cannot be read. +pub fn version_notice(agent: Agent, version: &str) -> Option { + let found = parse_version(version)?; + let tested = parse_version(tested_version(agent))?; + (found < tested).then(|| { + format!( + "{} {} is older than the version OpenXER was tested with ({}). It may not work; update {} if it does not.", + agent.name(), + short_version(version).unwrap_or_default(), + tested_version(agent), + agent.name() + ) + }) +} + +/// Words of an agent that refused how it was started: an option, a +/// feature name or a setting it does not know. +const LAUNCH_ERRORS: &[&str] = &[ + "unknown option", + "unknown argument", + "unexpected argument", + "unrecognized option", + "unrecognized argument", + "invalid value", + "unknown feature", + "unknown configuration", + "unknown config", + "unknown field", + "invalid config", + "error loading config", + "failed to parse", + "error parsing", + "too many arguments", +]; + +/// When `output` (what a process that stopped printed) shows the agent +/// refused its launch flags or settings: the first such line. +pub fn launch_problem(output: &str) -> Option { + output + .lines() + .map(str::trim) + .find(|line| { + let lower = line.to_ascii_lowercase(); + LAUNCH_ERRORS.iter().any(|k| lower.contains(k)) + }) + .map(|line| super::clip(line, 200)) +} + +/// The status line for an agent version that refused its launch: the +/// installed version, that it is not supported, what to update, and the +/// first line of its error. +pub fn unsupported_message(agent: Agent, version: Option<&str>, problem: &str) -> String { + let version = version + .and_then(short_version) + .map(|v| format!(" {v}")) + .unwrap_or_default(); + format!( + "{}{version} is not supported by this version of OpenXER (tested with {}). Update {}. It said: {problem}", + agent.name(), + tested_version(agent), + agent.name() + ) +} + +/// The status line for a launch that did not answer in time. +pub fn no_answer_message(agent: Agent) -> String { + format!( + "{} did not start within {} seconds. Check that it runs from a command prompt, or update it.", + agent.name(), + READY_TIMEOUT.as_secs() + ) +} + +/// The agent's program on `env`'s `PATH`, as a program can be started: +/// an `.exe` (a native or winget install), or the `.cmd` or `.bat` shim an +/// npm install puts beside a PowerShell one, never the `.ps1` itself. +pub fn find_program(agent: Agent, env: &connect::Env) -> Option { + let path = env.path.as_ref()?; + let names: Vec = if cfg!(windows) { + ["exe", "cmd", "bat"] + .iter() + .map(|e| format!("{}.{e}", agent.command())) + .collect() + } else { + vec![agent.command().to_string()] + }; + std::env::split_paths(path) + .flat_map(|dir| names.iter().map(move |n| dir.join(n))) + .find(|p| p.is_file()) +} + +impl Session { + /// Whether the next message goes to a process that is running now + /// (Claude Code between messages); false when it starts a new one + /// (always for Codex, and after a stop or a change of mode or model). + pub fn has_live_process(&self) -> bool { + self.options.agent == Agent::ClaudeCode && self.process_running() + } + + /// Change the mode or model for the next message, keeping the + /// conversation: the config files are written again and a running + /// Claude Code process is stopped, so the next message resumes the + /// conversation with the new tools and model (Codex starts a process + /// per message anyway). Refused while a reply runs. + pub fn reconfigure(&mut self, mode: ChatMode, model: ModelChoice) -> Result<(), AgentError> { + if self.options.mode == mode && self.options.model == model { + return Ok(()); + } + if let ModelChoice::Named(name) = &model { + check_model_name(name)?; + } + if self.is_busy() { + return Err(AgentError::Busy); + } + self.options.mode = mode; + self.options.model = model; + let mut files = vec![(instructions_file(&self.options), rules(&self.options))]; + if self.options.agent == Agent::ClaudeCode { + files.push(( + claude::config_path(&self.options), + claude::mcp_config(&self.options).to_string(), + )); + } + for (path, text) in files { + std::fs::write(&path, text).map_err(|e| AgentError::Failed { + message: format!("Cannot write {}: {e}", path.display()), + })?; + } + self.stop_process(); + Ok(()) + } +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn versions_are_read_and_compared_with_the_tested_ones() { + assert_eq!(parse_version("2.1.330 (Claude Code)"), Some((2, 1, 330))); + assert_eq!(parse_version("codex-cli 0.166.0"), Some((0, 166, 0))); + assert_eq!(parse_version("no version"), None); + assert!(version_notice(Agent::ClaudeCode, "2.1.330 (Claude Code)").is_none()); + assert!(version_notice(Agent::ClaudeCode, "2.2.0 (Claude Code)").is_none()); + let old = version_notice(Agent::ClaudeCode, "1.0.88 (Claude Code)").unwrap(); + assert!(old.contains("Claude Code 1.0.88 is older"), "{old}"); + assert!(old.contains("2.1.330")); + assert!(version_notice(Agent::Codex, "codex-cli 0.150.2").is_some()); + } + + #[test] + fn a_refused_launch_is_named_by_its_first_line() { + let out = "Usage: claude [options]\nerror: unknown option '--restricted'\n at main.js:12"; + assert_eq!( + launch_problem(out).as_deref(), + Some("error: unknown option '--restricted'") + ); + assert!(launch_problem("Not logged in. Please run /login").is_none()); + let line = unsupported_message( + Agent::Codex, + Some("codex-cli 0.100.0"), + "Error: unknown feature `apps`", + ); + assert_eq!( + line, + "Codex 0.100.0 is not supported by this version of OpenXER (tested with 0.166.0). Update Codex. It said: Error: unknown feature `apps`" + ); + } +} diff --git a/automation/src/agent_host/mod.rs b/automation/src/agent_host/mod.rs new file mode 100644 index 0000000..41325cc --- /dev/null +++ b/automation/src/agent_host/mod.rs @@ -0,0 +1,1282 @@ +//! The agent host of the Chat window: OpenXER starts an AI agent the user +//! already has on this PC (Claude Code or Codex) as a child process, which +//! uses its own sign-in; OpenXER holds no key and sends nothing itself. +//! +//! The agent gets only OpenXER's chat tools (`openxer-cli mcp --toolset +//! chat`, see [`crate::chat_tools`]): no command-running or file tools, +//! the user's own agent settings, hooks and other MCP servers ignored, and +//! in Ask mode only read-only tools. An edit is only proposed: the host +//! turns the agent's `openxer_apply` call into [`Event::ProposedChanges`], +//! and the app applies it on approval ([`crate::edit::apply_changes`]). +//! +//! A [`Session`] is driven from a UI thread without blocking: calls return +//! at once and [`Event`]s arrive on a channel. Processes start through a +//! [`Spawner`], so tests run every path against a fake agent. +pub mod claude; +pub mod codex; +pub mod compat; +pub mod process; + +pub use process::{capture, AgentProcess, Captured, Launch, Spawner, SystemSpawner}; + +use crate::chat_tools::{ChatContext, ChatMode}; +use crate::connect; +use serde::Serialize; +use serde_json::Value; +use std::fmt; +use std::io::{Read, Write}; +use std::path::PathBuf; +use std::sync::mpsc::{self, Receiver, Sender}; +use std::sync::{Arc, Mutex}; +use std::time::{Duration, Instant}; + +/// The agents OpenXER can host. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, Serialize)] +#[serde(rename_all = "snake_case")] +pub enum Agent { + ClaudeCode, + Codex, +} + +impl Agent { + pub const ALL: [Agent; 2] = [Agent::ClaudeCode, Agent::Codex]; + + pub fn name(self) -> &'static str { + match self { + Agent::ClaudeCode => "Claude Code", + Agent::Codex => "Codex", + } + } + /// The command on `PATH`. + pub fn command(self) -> &'static str { + match self { + Agent::ClaudeCode => "claude", + Agent::Codex => "codex", + } + } +} + +/// Which model the agent runs. +#[derive(Clone, Debug, Default, PartialEq, Eq, Serialize)] +#[serde(rename_all = "snake_case")] +pub enum ModelChoice { + /// Whatever the agent uses by default. + #[default] + AgentDefault, + /// A cheaper, faster model ([`claude::LOWER_COST_MODEL`], + /// [`codex::LOWER_COST_MODEL`] at low reasoning effort). + LowerCost, + /// A model the agent knows by this name. + Named(String), +} + +/// The choices a model picker offers for `agent`, with their labels. +pub fn model_choices(agent: Agent) -> Vec<(ModelChoice, String)> { + let cheaper = match agent { + Agent::ClaudeCode => format!("Lower cost ({})", claude::LOWER_COST_MODEL), + Agent::Codex => format!( + "Lower cost ({}, {} reasoning)", + codex::LOWER_COST_MODEL, + codex::LOWER_COST_EFFORT + ), + }; + vec![ + (ModelChoice::AgentDefault, "Agent default".into()), + (ModelChoice::LowerCost, cheaper), + ] +} + +/// Tokens one turn used. `input_tokens` counts every input token, the +/// cached ones included. +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Serialize)] +pub struct Usage { + pub input_tokens: u64, + pub cached_input_tokens: u64, + pub output_tokens: u64, +} + +/// What went wrong. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +#[serde(tag = "kind", rename_all = "snake_case")] +pub enum AgentError { + /// The agent's program is not on this PC. + NotInstalled { agent: Agent }, + /// The agent is installed but not signed in. + NotSignedIn { agent: Agent, message: String }, + /// The agent's process ended in the middle of a reply. + ProcessDied { message: String }, + /// A line of the agent's output was not what the host reads. + BadOutput { line: String }, + /// A reply is still running; cancel it or wait for it. + Busy, + /// Any other failure the agent reported. + Failed { message: String }, +} + +impl fmt::Display for AgentError { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + match self { + AgentError::NotInstalled { agent } => { + write!(f, "{} is not installed on this PC.", agent.name()) + } + AgentError::NotSignedIn { agent, message } => { + write!(f, "{} is not signed in. {message}", agent.name()) + } + AgentError::ProcessDied { message } => write!(f, "{message}"), + AgentError::BadOutput { line } => write!(f, "Unexpected agent output: {line}"), + AgentError::Busy => write!(f, "A reply is still running."), + AgentError::Failed { message } => write!(f, "{message}"), + } + } +} + +impl std::error::Error for AgentError {} + +/// What a session reports, in order. Plain data: any chat provider can +/// produce these for the window. +#[derive(Clone, Debug, PartialEq, Serialize)] +#[serde(tag = "kind", rename_all = "snake_case")] +pub enum Event { + /// The agent started; `model` as it names it (once per session). + Ready { + model: String, + }, + /// A piece of the reply as it is written. + TextDelta { + text: String, + }, + /// One whole message of the reply (the deltas before it, joined). + Message { + text: String, + }, + /// A tool call began. `target` is a few words on what it reads. + ToolStarted { + id: String, + tool: String, + target: String, + }, + /// A tool call ended. + ToolFinished { + id: String, + tool: String, + ok: bool, + error: Option, + duration_ms: u64, + }, + /// The agent proposed edits: the `openxer-changes/1` batch and the + /// field diff of its dry run. Nothing has been changed. + ProposedChanges { + id: String, + changes: Value, + diff: Option, + }, + /// The reply ended (`cancelled` when the user stopped it). + TurnFinished { + usage: Usage, + /// What the agent reports the turn cost, when it does. + cost_usd: Option, + cancelled: bool, + }, + Error { + error: AgentError, + }, +} + +/// A tool call the parser saw start. +#[derive(Clone, Debug)] +pub(crate) struct ToolCall { + pub tool: String, + pub input: Value, + pub started: Instant, +} + +/// `text` cut to `max` characters. +pub(crate) fn clip(text: &str, max: usize) -> String { + if text.chars().count() <= max { + return text.to_string(); + } + let mut cut: String = text.chars().take(max).collect(); + cut.push_str("..."); + cut +} + +/// A few words on what a tool call reads, for the window's tool line. +pub fn tool_target(tool: &str, input: &Value) -> String { + let s = |k: &str| input[k].as_str().map(str::to_string); + match tool { + "openxer_load" => { + let mut parts = vec![]; + if let Some(list) = input["activities"].as_array() { + let ids: Vec<&str> = list.iter().filter_map(Value::as_str).collect(); + let shown = ids.iter().take(5).copied().collect::>().join(", "); + parts.push(if ids.len() > 5 { + format!("{shown} and {} more", ids.len() - 5) + } else { + shown + }); + } + if let Some(w) = s("wbs") { + parts.push(format!("WBS {w}")); + } + if input["critical"] == true { + parts.push("critical activities".into()); + } + if parts.is_empty() { + parts.push(if input["limit"] == 0 { + "project summary".into() + } else { + "activities".into() + }); + } + if let Some(n) = input["offset"].as_u64().filter(|n| *n > 0) { + parts.push(format!("from row {}", n + 1)); + } + parts.join(", ") + } + "openxer_records" => { + let kind = s("kind").unwrap_or_else(|| "records".into()); + match s("activity") { + Some(a) => format!("{kind} of {a}"), + None => kind, + } + } + "openxer_earned_value" | "openxer_usage" => s("activity") + .or_else(|| s("resource")) + .unwrap_or_else(|| "project".into()), + "openxer_documents" => s("activity") + .or_else(|| s("wbs").map(|w| format!("WBS {w}"))) + .unwrap_or_else(|| "all documents".into()), + "openxer_playbook" => s("name") + .map(|n| format!("{n} playbook")) + .unwrap_or_else(|| "playbook list".into()), + "openxer_check_schedule" => s("check").unwrap_or_else(|| "all checks".into()), + "openxer_apply" => { + let n = input["changes"]["operations"] + .as_array() + .map_or(0, Vec::len); + format!("{n} change{}", if n == 1 { "" } else { "s" }) + } + _ => String::new(), + } +} + +/// The events of a finished tool call: `ToolFinished`, and for a +/// successful `openxer_apply` the proposal. +pub(crate) fn tool_finished( + id: String, + call: Option, + failed: bool, + text: &str, + now: Instant, +) -> Vec { + let envelope: Value = serde_json::from_str(text).unwrap_or(Value::Null); + let ok = !failed && envelope["ok"] != false; + let error = (!ok).then(|| { + envelope["error"]["message"] + .as_str() + .map(str::to_string) + .unwrap_or_else(|| clip(text, 300)) + }); + let tool = call.as_ref().map_or(String::new(), |c| c.tool.clone()); + let duration_ms = call.as_ref().map_or(0, |c| { + now.saturating_duration_since(c.started).as_millis() as u64 + }); + let mut events = vec![Event::ToolFinished { + id: id.clone(), + tool: tool.clone(), + ok, + error, + duration_ms, + }]; + if ok && tool == crate::chat_tools::APPLY_TOOL { + if let Some(call) = call { + let diff = envelope["result"]["report"]["diff"].clone(); + events.push(Event::ProposedChanges { + id, + changes: call.input["changes"].clone(), + diff: (!diff.is_null()).then_some(diff), + }); + } + } + events +} + +/// An agent's failure message as an error: sign-in problems apart. +pub fn classify_failure(agent: Agent, message: &str) -> AgentError { + let lower = message.to_ascii_lowercase(); + let sign_in = [ + "not logged in", + "/login", + "please log in", + "please login", + "login required", + "not signed in", + "sign in again", + "401", + "unauthorized", + "invalid api key", + "authentication", + ] + .iter() + .any(|k| lower.contains(k)); + if sign_in { + AgentError::NotSignedIn { + agent, + message: clip(message.trim(), 300), + } + } else { + AgentError::Failed { + message: clip(message.trim(), 500), + } + } +} + +// ------------------------------------------------------------- detection + +/// How long a `--version` or sign-in check may take before it is stopped. +/// [`detect`] runs two checks, so one agent takes at most twice this, and +/// [`detect_all`] (one agent after the other) four times: 40 seconds in +/// the worst case, normally about a second. A UI thread uses +/// [`detect_all_in_background`] instead. +pub const CHECK_TIMEOUT: Duration = Duration::from_secs(10); + +/// Whether an agent is on this PC and ready. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +pub struct AgentStatus { + pub agent: Agent, + pub installed: bool, + pub executable: Option, + pub version: Option, + /// `None` when the agent could not say. + pub signed_in: Option, + /// The user's own instruction file the agent will read in every chat + /// although OpenXER starts it without the user's setup: Codex reads + /// `AGENTS.override.md` or `AGENTS.md` in its home folder, and no + /// documented setting turns that off. The window can say so. + pub user_instructions: Option, +} + +/// Codex's own instruction file in its home folder, when it is not empty +/// (the first of `AGENTS.override.md` and `AGENTS.md`, as Codex reads them). +pub fn codex_user_instructions(env: &connect::Env) -> Option { + let home = env.codex_file()?.parent()?.to_path_buf(); + ["AGENTS.override.md", "AGENTS.md"] + .iter() + .map(|n| home.join(n)) + .find(|p| { + std::fs::read_to_string(p) + .map(|t| !t.trim().is_empty()) + .unwrap_or(false) + }) +} + +/// A model name the host passes on: letters, digits and `.-_:/[]`, not +/// starting with `-`. +pub fn check_model_name(name: &str) -> Result<(), AgentError> { + let ok = !name.is_empty() + && !name.starts_with('-') + && name.len() <= 100 + && name + .chars() + .all(|c| c.is_ascii_alphanumeric() || ".-_:/[]".contains(c)); + if ok { + Ok(()) + } else { + Err(AgentError::Failed { + message: format!("{name:?} is not a model name OpenXER can pass on"), + }) + } +} + +/// The agent's program on `env`'s `PATH`. +pub fn find(agent: Agent, env: &connect::Env) -> Option { + compat::find_program(agent, env) +} + +/// The first line of `--version`. +pub fn version(spawner: &dyn Spawner, executable: &std::path::Path) -> Option { + let out = capture( + spawner, + &Launch { + program: executable.to_path_buf(), + args: vec!["--version".into()], + ..Default::default() + }, + CHECK_TIMEOUT, + )?; + (out.code == 0) + .then(|| out.stdout.lines().next().unwrap_or("").trim().to_string()) + .filter(|s| !s.is_empty()) +} + +/// The command that reports whether the agent is signed in. +pub fn sign_in_status_args(agent: Agent) -> Vec { + match agent { + Agent::ClaudeCode => vec!["auth".into(), "status".into(), "--json".into()], + Agent::Codex => vec!["login".into(), "status".into()], + } +} + +/// Read the sign-in status command's output. Claude Code prints JSON with +/// `loggedIn`; Codex prints "Logged in using ..." or "Not logged in". +pub fn parse_sign_in_status(agent: Agent, out: &Captured) -> Option { + match agent { + Agent::ClaudeCode => { + let v: Value = serde_json::from_str(out.stdout.trim()).ok()?; + v["loggedIn"].as_bool() + } + Agent::Codex => { + let text = format!("{}\n{}", out.stdout, out.stderr).to_ascii_lowercase(); + if text.contains("not logged in") { + Some(false) + } else if text.contains("logged in") && out.code == 0 { + Some(true) + } else if out.code != 0 { + Some(false) + } else { + None + } + } + } +} + +/// Whether the agent is signed in (`None` when it could not say). +pub fn signed_in( + agent: Agent, + spawner: &dyn Spawner, + executable: &std::path::Path, +) -> Option { + let out = capture( + spawner, + &Launch { + program: executable.to_path_buf(), + args: sign_in_status_args(agent), + ..Default::default() + }, + CHECK_TIMEOUT, + )?; + parse_sign_in_status(agent, &out) +} + +/// Whether `agent` is installed, its version and whether it is signed in. +/// Everything comes from `env` and `spawner`: an `Env::default()` finds +/// nothing, so a test never sees the real user profile. +pub fn detect(agent: Agent, env: &connect::Env, spawner: &dyn Spawner) -> AgentStatus { + let user_instructions = match agent { + Agent::Codex => codex_user_instructions(env), + Agent::ClaudeCode => None, + }; + let Some(executable) = find(agent, env) else { + return AgentStatus { + agent, + installed: false, + executable: None, + version: None, + signed_in: None, + user_instructions: None, + }; + }; + AgentStatus { + agent, + installed: true, + version: version(spawner, &executable), + signed_in: signed_in(agent, spawner, &executable), + executable: Some(executable), + user_instructions, + } +} + +/// [`detect`] for every agent, one after the other (it blocks: see +/// [`CHECK_TIMEOUT`]). +pub fn detect_all(env: &connect::Env, spawner: &dyn Spawner) -> Vec { + Agent::ALL + .iter() + .map(|a| detect(*a, env, spawner)) + .collect() +} + +/// [`detect`] for every agent at once on background threads; each status +/// arrives on the receiver when it is known (the channel closes after the +/// last). Returns at once, so a UI thread can poll with `try_recv`. +pub fn detect_all_in_background( + env: connect::Env, + spawner: Arc, +) -> Receiver { + let (send, receive) = mpsc::channel(); + for agent in Agent::ALL { + let (env, spawner, send) = (env.clone(), spawner.clone(), send.clone()); + std::thread::spawn(move || { + let _ = send.send(detect(agent, &env, spawner.as_ref())); + }); + } + receive +} + +// --------------------------------------------------------------- sign-in + +/// The command that starts the agent's own sign-in (it opens the browser). +pub fn sign_in_args(agent: Agent) -> Vec { + match agent { + Agent::ClaudeCode => vec!["auth".into(), "login".into()], + Agent::Codex => vec!["login".into()], + } +} + +/// A running sign-in: the agent's own `login` command, which opens the +/// browser and ends when the user has signed in. OpenXER only starts it. +pub struct SignIn { + process: Option>, + output: Receiver, + lines: Vec, +} + +/// Where a sign-in stands. +#[derive(Clone, Debug, PartialEq, Eq)] +pub enum SignInState { + Running, + Finished { ok: bool }, +} + +fn forward_lines(reader: Option>, send: Sender) { + if let Some(reader) = reader { + std::thread::spawn(move || { + process::for_each_line(reader, |line| { + let _ = send.send(line); + }); + }); + } +} + +impl SignIn { + /// Start `agent`'s sign-in. + pub fn start( + agent: Agent, + executable: &std::path::Path, + spawner: &dyn Spawner, + ) -> Result { + let mut process = spawner + .spawn(&Launch { + program: executable.to_path_buf(), + args: sign_in_args(agent), + ..Default::default() + }) + .map_err(|e| spawn_error(agent, e))?; + let (send, output) = mpsc::channel(); + forward_lines(process.take_stdout(), send.clone()); + forward_lines(process.take_stderr(), send); + Ok(SignIn { + process: Some(process), + output, + lines: vec![], + }) + } + + /// What the command has printed so far (the sign-in link, when the + /// browser did not open). + pub fn output(&mut self) -> &[String] { + while let Ok(line) = self.output.try_recv() { + self.lines.push(line); + } + &self.lines + } + + /// Whether it is still running; never blocks. + pub fn poll(&mut self) -> SignInState { + let Some(process) = self.process.as_mut() else { + return SignInState::Finished { ok: false }; + }; + match process.try_wait() { + Ok(Some(code)) => { + self.process = None; + SignInState::Finished { ok: code == 0 } + } + Ok(None) => SignInState::Running, + Err(_) => SignInState::Finished { ok: false }, + } + } + + /// Stop the sign-in. + pub fn cancel(&mut self) { + if let Some(mut process) = self.process.take() { + let _ = process.kill(); + } + } +} + +impl Drop for SignIn { + fn drop(&mut self) { + self.cancel(); + } +} + +fn spawn_error(agent: Agent, e: std::io::Error) -> AgentError { + if e.kind() == std::io::ErrorKind::NotFound { + AgentError::NotInstalled { agent } + } else if e.kind() == std::io::ErrorKind::InvalidInput { + AgentError::Failed { + message: format!( + "OpenXER cannot start {} safely from this install (a batch file launcher that cannot take one of the arguments). Install {} as a program, or move its work folder to a path without unusual characters.", + agent.name(), + agent.name() + ), + } + } else { + AgentError::Failed { + message: format!("Cannot start {}: {e}", agent.name()), + } + } +} + +// --------------------------------------------------------------- session + +/// What a conversation runs with. +#[derive(Clone, Debug, PartialEq, Eq)] +pub struct SessionOptions { + pub agent: Agent, + /// The agent's program (from [`detect`]). + pub executable: PathBuf, + pub model: ModelChoice, + pub mode: ChatMode, + /// The `openxer-cli` that serves the tools. + pub cli: PathBuf, + /// `OPENXER_DATA_DIR` for the tool server. + pub data_dir: PathBuf, + /// The folder the agent runs in; the host writes its config there. + pub work_dir: PathBuf, + /// The project file every tool reads (a copy of the open project). + pub snapshot: PathBuf, + /// Lines put before the first message ([`crate::chat_tools::preamble`]). + pub preamble: String, + /// Also append the agent's raw output lines to this file. + pub transcript: Option, + /// The user's standing instructions, sent after the scheduling core + /// ([`crate::chat_prompt::read_user_instructions`]); `None` for none. + pub user_instructions: Option, + /// Optional per-project standing rules for this schedule. + pub project_instructions: Option, + /// Optional folder of user-authored `.md` playbooks (`chat/playbooks`). + pub playbooks_dir: Option, + /// Optional JSONL queue file where `openxer_ui` writes live desktop UI actions. + pub ui_actions: Option, + /// Keep the conversation's files when the session ends. By default + /// ending removes them: the work folder (when the session made it, + /// with the agent config and a snapshot inside it), the snapshot when + /// it lies in that folder, and the agent's own stored copy of the + /// conversation ([`forget_conversation`]), which holds schedule data. + pub keep_files: bool, +} + +impl SessionOptions { + pub(crate) fn chat_context(&self) -> ChatContext { + ChatContext { + snapshot: Some(self.snapshot.clone()), + mode: self.mode, + playbooks_dir: self.playbooks_dir.clone(), + ui_actions: self.ui_actions.clone(), + } + } +} + +/// Where a session writes the chat's instructions for its agent. +pub fn instructions_file(options: &SessionOptions) -> PathBuf { + options.work_dir.join("openxer-chat-instructions.md") +} + +/// The whole of the agent's instructions: [`crate::chat_prompt::system_prompt_with`] +/// with the session's mode, user standing instructions and project rules. +pub fn rules(options: &SessionOptions) -> String { + crate::chat_prompt::system_prompt_with( + options.mode, + options.user_instructions.as_deref(), + options.project_instructions.as_deref(), + ) +} + +#[derive(Default)] +struct Shared { + busy: bool, + cancelled: bool, + closed: bool, + ready_sent: bool, + /// Claude's session id or Codex's thread id. + conversation: Option, + /// Bumped for each process; a reader of an older one stays quiet. + generation: u64, + /// The process the running reply is on (0 while it has none yet), so + /// a process that ends after its own reply never ends the next one. + turn_generation: u64, +} + +type Slot = Arc>>>; + +/// One conversation with an agent. Calls never block on the agent; +/// replies arrive as [`Event`]s on the receiver [`Session::start`] gave. +/// Dropping the session stops its process. +pub struct Session { + options: SessionOptions, + spawner: Arc, + events: Sender, + shared: Arc>, + process: Slot, + stdin: Option>, + first: bool, + /// Whether `start` made the work folder (only then is it removed and + /// Claude Code's data for it purged). + created_work_dir: bool, + cleaned: bool, +} + +/// The agent's own command that deletes its stored copy of a conversation: +/// Claude Code keeps it under `~/.claude/projects//` and +/// `claude purge -y ` deletes Claude Code's data for that +/// folder (so the folder must be the session's own); Codex keeps it under +/// `~/.codex/sessions/` and `codex delete --force ` deletes it. +/// `None` when there is nothing to delete. +pub fn forget_arguments( + agent: Agent, + work_dir: &std::path::Path, + conversation: Option<&str>, +) -> Option> { + match agent { + Agent::ClaudeCode => Some(vec![ + "purge".into(), + "-y".into(), + work_dir.display().to_string(), + ]), + Agent::Codex => conversation + .filter(|id| codex::valid_thread_id(id)) + .map(|id| vec!["delete".into(), "--force".into(), id.into()]), + } +} + +/// Delete the agent's stored copy of a conversation ([`forget_arguments`]); +/// blocks for at most [`CHECK_TIMEOUT`]. Whether the command succeeded. +pub fn forget_conversation( + agent: Agent, + executable: &std::path::Path, + spawner: &dyn Spawner, + work_dir: &std::path::Path, + conversation: Option<&str>, +) -> bool { + let Some(args) = forget_arguments(agent, work_dir, conversation) else { + return true; + }; + capture( + spawner, + &Launch { + program: executable.to_path_buf(), + args, + ..Default::default() + }, + CHECK_TIMEOUT, + ) + .is_some_and(|out| out.code == 0) +} + +impl Session { + /// Prepare a conversation: checks the agent's program and writes the + /// config files the agent reads into `work_dir`. The agent starts with + /// the first message. + pub fn start( + options: SessionOptions, + spawner: Arc, + ) -> Result<(Session, Receiver), AgentError> { + if options.executable.as_os_str().is_empty() { + return Err(AgentError::NotInstalled { + agent: options.agent, + }); + } + if let ModelChoice::Named(name) = &options.model { + check_model_name(name)?; + } + let created_work_dir = !options.work_dir.exists(); + let write = |path: PathBuf, text: String| { + std::fs::create_dir_all(&options.work_dir) + .and_then(|()| std::fs::write(&path, text)) + .map_err(|e| AgentError::Failed { + message: format!("Cannot write {}: {e}", path.display()), + }) + }; + write(instructions_file(&options), rules(&options))?; + if options.agent == Agent::ClaudeCode { + write( + claude::config_path(&options), + claude::mcp_config(&options).to_string(), + )?; + } + let (events, receive) = mpsc::channel(); + Ok(( + Session { + options, + spawner, + events, + shared: Arc::default(), + process: Arc::default(), + stdin: None, + first: true, + created_work_dir, + cleaned: false, + }, + receive, + )) + } + + pub fn options(&self) -> &SessionOptions { + &self.options + } + + /// Whether a reply is running. + pub fn is_busy(&self) -> bool { + self.shared.lock().map(|s| s.busy).unwrap_or(false) + } + + /// The conversation id the agent gave (to resume it). + pub fn conversation_id(&self) -> Option { + self.shared.lock().ok().and_then(|s| s.conversation.clone()) + } + + /// Send a user message. `context` (for example the activities now + /// selected) goes before it; the first message also carries the + /// preamble. Returns at once; the reply arrives as events. + pub fn send(&mut self, text: &str, context: Option<&str>) -> Result<(), AgentError> { + { + let mut shared = self.shared.lock().expect("session state"); + if shared.busy { + return Err(AgentError::Busy); + } + shared.busy = true; + shared.cancelled = false; + shared.turn_generation = 0; + } + let mut message = String::new(); + if self.first && !self.options.preamble.trim().is_empty() { + message.push_str(self.options.preamble.trim()); + message.push_str("\n\n"); + } + if let Some(context) = context.filter(|c| !c.trim().is_empty()) { + message.push_str("Context: "); + message.push_str(context.trim()); + message.push_str("\n\n"); + } + message.push_str(text); + let sent = match self.options.agent { + Agent::ClaudeCode => self.send_claude(&message), + Agent::Codex => self.start_codex_turn(&message), + }; + match sent { + Ok(()) => { + self.first = false; + Ok(()) + } + Err(e) => { + if let Ok(mut shared) = self.shared.lock() { + shared.busy = false; + } + Err(e) + } + } + } + + fn process_running(&self) -> bool { + self.process + .lock() + .ok() + .and_then(|mut p| p.as_mut().map(|p| matches!(p.try_wait(), Ok(None)))) + .unwrap_or(false) + } + + fn send_claude(&mut self, message: &str) -> Result<(), AgentError> { + let line = claude::user_line(message); + let running = self.process_running(); + if let Some(stdin) = self.stdin.as_mut().filter(|_| running) { + // The reply runs on the live process. + if let Ok(mut shared) = self.shared.lock() { + shared.turn_generation = shared.generation; + } + if writeln!(stdin, "{line}") + .and_then(|()| stdin.flush()) + .is_ok() + { + return Ok(()); + } + } + // No live process: start one, resuming the conversation when the + // agent has given it an id. + let resume = self.conversation_id(); + let args = claude::arguments( + &self.options, + &claude::config_path(&self.options), + &instructions_file(&self.options), + resume.as_deref(), + )?; + let mut stdin = self.launch(args, true, Parser::Claude(claude::ClaudeParser::new()))?; + let written = stdin + .as_mut() + .map(|s| writeln!(s, "{line}").and_then(|()| s.flush())); + if !matches!(written, Some(Ok(()))) { + self.stop_process(); + return Err(AgentError::ProcessDied { + message: "Claude Code stopped before it read the message.".into(), + }); + } + self.stdin = stdin.take(); + Ok(()) + } + + fn start_codex_turn(&mut self, message: &str) -> Result<(), AgentError> { + let resume = self.conversation_id(); + let args = codex::arguments(&self.options, resume.as_deref())?; + let model = match &self.options.model { + ModelChoice::AgentDefault => "Codex default".to_string(), + ModelChoice::LowerCost => codex::LOWER_COST_MODEL.to_string(), + ModelChoice::Named(n) => n.clone(), + }; + // The prompt goes in on stdin, which is then closed: it is never + // on the command line. + let stdin = self.launch(args, true, Parser::Codex(codex::CodexParser::new(model)))?; + let written = stdin.map(|mut s| s.write_all(message.as_bytes()).and_then(|()| s.flush())); + if !matches!(written, Some(Ok(()))) { + self.stop_process(); + return Err(AgentError::ProcessDied { + message: "Codex stopped before it read the message.".into(), + }); + } + Ok(()) + } + + /// Start the agent's process with a reader thread for its output. + fn launch( + &mut self, + args: Vec, + stdin: bool, + parser: Parser, + ) -> Result>, AgentError> { + // A new generation first, so the old process's reader stays quiet + // when it sees its output end. + let generation = { + let mut shared = self.shared.lock().expect("session state"); + shared.generation += 1; + shared.turn_generation = shared.generation; + shared.generation + }; + self.stop_process(); + let mut env = vec![( + "OPENXER_DATA_DIR".to_string(), + self.options.data_dir.display().to_string(), + )]; + if self.options.agent == Agent::ClaudeCode { + env.extend( + claude::ENVIRONMENT + .iter() + .map(|(k, v)| (k.to_string(), v.to_string())), + ); + } + let launch = Launch { + program: self.options.executable.clone(), + args, + cwd: Some(self.options.work_dir.clone()), + env, + stdin, + }; + let mut process = self + .spawner + .spawn(&launch) + .map_err(|e| spawn_error(self.options.agent, e))?; + let input = process.take_stdin(); + let stdout = process.take_stdout(); + let stderr = process.take_stderr(); + *self.process.lock().expect("process slot") = Some(process); + let tail = Arc::new(Mutex::new(Vec::::new())); + let stderr_done = stderr.map(|stderr| { + let tail = tail.clone(); + let (done, finished) = mpsc::channel::<()>(); + std::thread::spawn(move || { + // Read to the end whatever it holds, so a talkative child + // never blocks on a full pipe. + process::for_each_line(stderr, |line| { + if let Ok(mut t) = tail.lock() { + t.push(line); + if t.len() > 20 { + t.remove(0); + } + } + }); + let _ = done.send(()); + }); + finished + }); + let reader = Reader { + agent: self.options.agent, + events: self.events.clone(), + shared: self.shared.clone(), + process: self.process.clone(), + generation, + parser, + transcript: self.options.transcript.clone(), + tail, + stderr_done, + }; + match stdout { + Some(stdout) => { + std::thread::spawn(move || reader.run(stdout)); + } + None => { + self.stop_process(); + return Err(AgentError::Failed { + message: "The agent's output could not be read.".into(), + }); + } + } + Ok(input) + } + + fn stop_process(&mut self) { + self.stdin = None; + if let Ok(mut slot) = self.process.lock() { + if let Some(mut process) = slot.take() { + let _ = process.kill(); + } + } + } + + /// Stop the running reply: the agent's process (and every process it + /// started) is stopped and the cancelled `TurnFinished` is sent at once, + /// whatever its output does. The conversation goes on with the next + /// message (resumed by its id). + pub fn cancel(&mut self) { + { + let Ok(mut shared) = self.shared.lock() else { + return; + }; + if !shared.busy { + return; + } + // A new generation: nothing more from the stopped process. + shared.generation += 1; + shared.busy = false; + shared.cancelled = true; + let _ = self.events.send(Event::TurnFinished { + usage: Usage::default(), + cost_usd: None, + cancelled: true, + }); + } + self.stop_process(); + } + + /// End the conversation: stop the agent and, unless + /// [`SessionOptions::keep_files`], remove the conversation's files and + /// the agent's stored copy. The returned handle ends when that is done + /// (it never needs to be waited for). + pub fn end(mut self) -> std::thread::JoinHandle<()> { + self.finish() + } + + fn finish(&mut self) -> std::thread::JoinHandle<()> { + if let Ok(mut shared) = self.shared.lock() { + shared.closed = true; + } + self.stop_process(); + if self.cleaned || self.options.keep_files { + self.cleaned = true; + return std::thread::spawn(|| {}); + } + self.cleaned = true; + let options = self.options.clone(); + let spawner = self.spawner.clone(); + let conversation = self.conversation_id(); + let created = self.created_work_dir; + // The files go now (quick), so a later session in the same folder + // never loses its own. + let _ = std::fs::remove_file(claude::config_path(&options)); + let _ = std::fs::remove_file(instructions_file(&options)); + if options.snapshot.starts_with(&options.work_dir) { + let _ = std::fs::remove_file(&options.snapshot); + } + if created { + let _ = std::fs::remove_dir_all(&options.work_dir); + } + // The agent's own delete runs a process: never on the caller's + // thread. Claude Code's purge is by folder: only for a folder this + // session made, so no other data of the user's is touched. + std::thread::spawn(move || { + if options.agent == Agent::Codex || created { + forget_conversation( + options.agent, + &options.executable, + spawner.as_ref(), + &options.work_dir, + conversation.as_deref(), + ); + } + }) + } +} + +impl Drop for Session { + fn drop(&mut self) { + let _ = self.finish(); + } +} + +enum Parser { + Claude(claude::ClaudeParser), + Codex(codex::CodexParser), +} + +impl Parser { + fn parse(&mut self, line: &str, now: Instant) -> Vec { + match self { + Parser::Claude(p) => p.parse_line(line, now), + Parser::Codex(p) => p.parse_line(line, now), + } + } + fn conversation(&self) -> Option<&String> { + match self { + Parser::Claude(p) => p.session_id.as_ref(), + Parser::Codex(p) => p.thread_id.as_ref(), + } + } +} + +struct Reader { + agent: Agent, + events: Sender, + shared: Arc>, + process: Slot, + generation: u64, + parser: Parser, + transcript: Option, + tail: Arc>>, + /// Signals that the error output has been read to its end. + stderr_done: Option>, +} + +impl Reader { + fn current(&self, shared: &Shared) -> bool { + shared.generation == self.generation && !shared.closed + } + + /// Whether a reply is running on this reader's process. + fn owns_turn(&self, shared: &Shared) -> bool { + self.current(shared) && shared.busy && shared.turn_generation == self.generation + } + + fn run(mut self, stdout: Box) { + let mut log = self.transcript.as_ref().and_then(|p| { + std::fs::OpenOptions::new() + .create(true) + .append(true) + .open(p) + .ok() + }); + let mut stale = false; + // Lines are bytes decoded leniently: an invalid UTF-8 byte never + // stops the reading. + process::for_each_line(stdout, |line| { + if stale { + return; + } + if let Some(log) = log.as_mut() { + let _ = writeln!(log, "{line}"); + } + let events = self.parser.parse(&line, Instant::now()); + let mut shared = self.shared.lock().expect("session state"); + if !self.current(&shared) { + // Stopped or replaced: keep draining, say nothing. + stale = true; + return; + } + if let Some(id) = self.parser.conversation() { + shared.conversation = Some(id.clone()); + } + for mut event in events { + match &mut event { + Event::Ready { .. } if shared.ready_sent => continue, + Event::Ready { .. } => shared.ready_sent = true, + Event::TurnFinished { .. } => shared.busy = false, + // Agents number tool calls per process (Codex starts + // at item_0 every turn): ids carry the process, so they + // are unique in the session. + Event::ToolStarted { id, .. } + | Event::ToolFinished { id, .. } + | Event::ProposedChanges { id, .. } => { + *id = format!("{}-{id}", self.generation); + } + _ => {} + } + let _ = self.events.send(event); + } + }); + if stale { + return; + } + // The output ended: the process stopped (or is stopping). Nothing + // to say unless a reply of this process was still running. + { + let shared = self.shared.lock().expect("session state"); + if !self.owns_turn(&shared) { + return; + } + } + let code = self.exit_code(); + if let Some(done) = &self.stderr_done { + let _ = done.recv_timeout(Duration::from_secs(1)); + } + let mut shared = self.shared.lock().expect("session state"); + if !self.owns_turn(&shared) { + return; + } + shared.busy = false; + if shared.cancelled { + let _ = self.events.send(Event::TurnFinished { + usage: Usage::default(), + cost_usd: None, + cancelled: true, + }); + return; + } + let tail = self.tail.lock().map(|t| t.join("\n")).unwrap_or_default(); + let error = match classify_failure(self.agent, &tail) { + e @ AgentError::NotSignedIn { .. } => e, + _ => AgentError::ProcessDied { + message: format!( + "{} stopped before the reply ended{}.{}", + self.agent.name(), + code.map(|c| format!(" (exit code {c})")) + .unwrap_or_default(), + if tail.trim().is_empty() { + String::new() + } else { + format!(" {}", clip(tail.trim(), 500)) + } + ), + }, + }; + let _ = self.events.send(Event::Error { error }); + let _ = self.events.send(Event::TurnFinished { + usage: Usage::default(), + cost_usd: None, + cancelled: false, + }); + } + + /// The process's exit code, waiting a little for it to end. + fn exit_code(&self) -> Option { + let deadline = Instant::now() + Duration::from_secs(2); + loop { + { + let mut slot = self.process.lock().ok()?; + match slot.as_mut().map(|p| p.try_wait()) { + Some(Ok(Some(code))) => return Some(code), + Some(Ok(None)) => {} + _ => return None, + } + } + if Instant::now() >= deadline { + return None; + } + std::thread::sleep(Duration::from_millis(20)); + } + } +} diff --git a/automation/src/agent_host/process.rs b/automation/src/agent_host/process.rs new file mode 100644 index 0000000..dfedebf --- /dev/null +++ b/automation/src/agent_host/process.rs @@ -0,0 +1,330 @@ +//! Starting agent processes, behind a trait so every path of the host can +//! run against a fake agent in tests. +use std::io::{self, Read, Write}; +use std::path::PathBuf; +use std::process::{Command, Stdio}; +use std::sync::mpsc; +use std::time::{Duration, Instant}; + +/// A process to start: program, arguments, folder and extra environment. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct Launch { + pub program: PathBuf, + pub args: Vec, + pub cwd: Option, + /// Added to the inherited environment. + pub env: Vec<(String, String)>, + /// Whether the process gets a stdin pipe (else stdin is null). + pub stdin: bool, +} + +/// A started process. The pipes are taken once each. +pub trait AgentProcess: Send { + fn take_stdin(&mut self) -> Option>; + fn take_stdout(&mut self) -> Option>; + fn take_stderr(&mut self) -> Option>; + /// Stop the process (only ever the one this host started). + fn kill(&mut self) -> io::Result<()>; + /// The exit code once it has ended (-1 when it has none). + fn try_wait(&mut self) -> io::Result>; +} + +/// Starts processes. [`SystemSpawner`] starts real ones. +pub trait Spawner: Send + Sync { + fn spawn(&self, launch: &Launch) -> io::Result>; +} + +/// The real spawner: `std::process`, with no console window on Windows. +/// +/// A `.cmd` or `.bat` install (an npm shim) is started by `std::process` +/// itself, never through `cmd /C` by hand, so the standard library's batch +/// file quoting applies; it refuses an argument it cannot pass safely, and +/// so does [`batch_safe`] for line breaks. Only fixed flags and paths the +/// host generates are ever arguments: messages and schedule text go in on +/// stdin. +/// +/// On Windows every child is put in a job object that kills the whole tree +/// when it is stopped or dropped, so a grandchild (an MCP server, a +/// script) never outlives it holding a pipe open. +#[derive(Clone, Copy, Debug, Default)] +pub struct SystemSpawner; + +/// Whether `program` is a batch file, which `cmd` interprets. +pub fn is_batch(program: &std::path::Path) -> bool { + program + .extension() + .and_then(|e| e.to_str()) + .is_some_and(|e| e.eq_ignore_ascii_case("cmd") || e.eq_ignore_ascii_case("bat")) +} + +/// Whether `arg` can go to a batch file: no line breaks or NUL, which +/// `cmd` cannot take inside an argument at all. +pub fn batch_safe(arg: &str) -> bool { + !arg.contains(['\r', '\n', '\0']) +} + +struct SystemProcess { + child: std::process::Child, + #[cfg(windows)] + job: Option, +} + +impl AgentProcess for SystemProcess { + fn take_stdin(&mut self) -> Option> { + self.child + .stdin + .take() + .map(|s| Box::new(s) as Box) + } + fn take_stdout(&mut self) -> Option> { + self.child + .stdout + .take() + .map(|s| Box::new(s) as Box) + } + fn take_stderr(&mut self) -> Option> { + self.child + .stderr + .take() + .map(|s| Box::new(s) as Box) + } + fn kill(&mut self) -> io::Result<()> { + // The whole tree of this child, whether or not the child itself + // has ended already. + #[cfg(windows)] + if let Some(job) = &self.job { + job.terminate(); + } + if self.child.try_wait()?.is_some() { + return Ok(()); + } + self.child.kill() + } + fn try_wait(&mut self) -> io::Result> { + Ok(self.child.try_wait()?.map(|s| s.code().unwrap_or(-1))) + } +} + +impl Drop for SystemProcess { + fn drop(&mut self) { + // Never leave a child (or its children) running. + let _ = self.kill(); + let _ = self.child.wait(); + } +} + +/// A Windows job object that ends every process in it when it is +/// terminated or closed. Declared here from kernel32 directly: the calls +/// are few and no other crate is needed. +#[cfg(windows)] +mod job { + use std::ffi::c_void; + + type Handle = *mut c_void; + + #[repr(C)] + #[derive(Default)] + struct BasicLimits { + per_process_user_time_limit: i64, + per_job_user_time_limit: i64, + limit_flags: u32, + minimum_working_set_size: usize, + maximum_working_set_size: usize, + active_process_limit: u32, + affinity: usize, + priority_class: u32, + scheduling_class: u32, + } + + #[repr(C)] + #[derive(Default)] + struct IoCounters { + counts: [u64; 6], + } + + #[repr(C)] + #[derive(Default)] + struct ExtendedLimits { + basic: BasicLimits, + io: IoCounters, + process_memory_limit: usize, + job_memory_limit: usize, + peak_process_memory_used: usize, + peak_job_memory_used: usize, + } + + const KILL_ON_JOB_CLOSE: u32 = 0x2000; + const EXTENDED_LIMIT_INFORMATION: i32 = 9; + + #[link(name = "kernel32")] + extern "system" { + fn CreateJobObjectW(attributes: *mut c_void, name: *const u16) -> Handle; + fn SetInformationJobObject(job: Handle, class: i32, info: *mut c_void, len: u32) -> i32; + fn AssignProcessToJobObject(job: Handle, process: Handle) -> i32; + fn TerminateJobObject(job: Handle, code: u32) -> i32; + fn CloseHandle(handle: Handle) -> i32; + } + + /// The job of one child. Owned by that child's handle only. + pub struct Job(Handle); + + // The handle is used only through these calls, which any thread may make. + unsafe impl Send for Job {} + + impl Job { + /// A kill-on-close job holding `child`, or `None` when Windows + /// refuses (the child is then stopped on its own, as before). + pub fn hold(child: &std::process::Child) -> Option { + use std::os::windows::io::AsRawHandle; + // SAFETY: plain Win32 calls on handles this function owns (the + // new job) or borrows for the call (the child's process handle, + // alive as long as `child`); the limits struct is laid out as + // JOBOBJECT_EXTENDED_LIMIT_INFORMATION. + unsafe { + let job = CreateJobObjectW(std::ptr::null_mut(), std::ptr::null()); + if job.is_null() { + return None; + } + let mut limits = ExtendedLimits::default(); + limits.basic.limit_flags = KILL_ON_JOB_CLOSE; + let set = SetInformationJobObject( + job, + EXTENDED_LIMIT_INFORMATION, + &mut limits as *mut ExtendedLimits as *mut c_void, + std::mem::size_of::() as u32, + ); + if set == 0 || AssignProcessToJobObject(job, child.as_raw_handle() as Handle) == 0 { + CloseHandle(job); + return None; + } + Some(Job(job)) + } + } + + /// End every process in the job. + pub fn terminate(&self) { + // SAFETY: the job handle is open until Drop. + unsafe { + TerminateJobObject(self.0, 1); + } + } + } + + impl Drop for Job { + fn drop(&mut self) { + // SAFETY: closes the handle this Job owns; kill-on-close ends + // whatever is still in the job. + unsafe { + CloseHandle(self.0); + } + } + } +} + +impl Spawner for SystemSpawner { + fn spawn(&self, launch: &Launch) -> io::Result> { + if is_batch(&launch.program) && !launch.args.iter().all(|a| batch_safe(a)) { + return Err(io::Error::new( + io::ErrorKind::InvalidInput, + "an argument cannot be passed to a batch file safely", + )); + } + let mut command = Command::new(&launch.program); + command + .args(&launch.args) + .stdin(if launch.stdin { + Stdio::piped() + } else { + Stdio::null() + }) + .stdout(Stdio::piped()) + .stderr(Stdio::piped()); + if let Some(cwd) = &launch.cwd { + command.current_dir(cwd); + } + for (k, v) in &launch.env { + command.env(k, v); + } + #[cfg(windows)] + { + use std::os::windows::process::CommandExt; + const CREATE_NO_WINDOW: u32 = 0x0800_0000; + command.creation_flags(CREATE_NO_WINDOW); + } + let child = command.spawn()?; + Ok(Box::new(SystemProcess { + #[cfg(windows)] + job: job::Job::hold(&child), + child, + })) + } +} + +/// Call `each` with every line `reader` gives until it ends, decoding +/// invalid UTF-8 as U+FFFD instead of stopping, without the line end. +pub fn for_each_line(reader: impl Read, mut each: impl FnMut(String)) { + let mut reader = io::BufReader::new(reader); + let mut bytes = vec![]; + loop { + bytes.clear(); + match io::BufRead::read_until(&mut reader, b'\n', &mut bytes) { + Ok(0) => return, + Ok(_) => { + while matches!(bytes.last(), Some(b'\n' | b'\r')) { + bytes.pop(); + } + each(String::from_utf8_lossy(&bytes).into_owned()); + } + Err(e) if e.kind() == io::ErrorKind::Interrupted => continue, + Err(_) => return, + } + } +} + +/// What a short command printed. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct Captured { + pub code: i32, + pub stdout: String, + pub stderr: String, +} + +fn drain(reader: Option>) -> mpsc::Receiver { + let (send, receive) = mpsc::channel(); + std::thread::spawn(move || { + let mut text = String::new(); + if let Some(mut r) = reader { + let mut bytes = vec![]; + let _ = r.read_to_end(&mut bytes); + text = String::from_utf8_lossy(&bytes).into_owned(); + } + let _ = send.send(text); + }); + receive +} + +/// Run a short command (`--version`, a sign-in status) to its end, or stop +/// it after `timeout`. `None` when it could not start or did not finish. +pub fn capture(spawner: &dyn Spawner, launch: &Launch, timeout: Duration) -> Option { + let mut process = spawner.spawn(launch).ok()?; + drop(process.take_stdin()); + let out = drain(process.take_stdout()); + let err = drain(process.take_stderr()); + let deadline = Instant::now() + timeout; + let code = loop { + match process.try_wait() { + Ok(Some(code)) => break code, + Ok(None) if Instant::now() < deadline => std::thread::sleep(Duration::from_millis(15)), + _ => { + let _ = process.kill(); + return None; + } + } + }; + let left = deadline.saturating_duration_since(Instant::now()) + Duration::from_millis(500); + Some(Captured { + code, + stdout: out.recv_timeout(left).unwrap_or_default(), + stderr: err.recv_timeout(left).unwrap_or_default(), + }) +} diff --git a/automation/src/analysis.rs b/automation/src/analysis.rs new file mode 100644 index 0000000..be7cdfc --- /dev/null +++ b/automation/src/analysis.rs @@ -0,0 +1,1266 @@ +//! Read-only schedule analysis for agents: the numbers the skills need, so +//! an agent never works one out itself. Each answer is built from what the +//! app already computes: Check Schedule (`schedule_check`), the multiple +//! float paths of the scheduler (`openxer_engine::features::activity_paths`), +//! the stored baselines (`baselines`), the usage spread (`usage`) and the +//! stored dates and float of the project. Nothing here changes a file. +use crate::schedule_check::{self as check, CheckParams, Item}; +use crate::{AutomationError, Result}; +use openxer_engine::calendar::DAY; +use openxer_engine::model::{Activity, CstrType, LinkType, StatusType, TaskType}; +use openxer_xer::edit::project_records::wbs_code_path; +use openxer_xer::ev::{displayed_finish, displayed_start}; +use openxer_xer::{date_string, parse_relative, status_label, ProjectData}; +use serde_json::{json, Value}; +use std::collections::{BTreeMap, BTreeSet, HashMap}; + +/// Most items listed per finding; the rest are counted in `more`. +pub const LIST_CAP: usize = 25; + +fn invalid(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +fn round(v: f64) -> f64 { + (v * 100.).round() / 100. + 0. +} + +fn hours(minutes: i64) -> f64 { + round(minutes as f64 / 60.) +} + +/// Average working minutes of a working day on calendar `cal` (a continuous +/// calendar counts every day as 24 hours; 8 hours when the week is empty). +pub fn day_minutes(p: &ProjectData, cal: usize) -> i64 { + let Some(c) = p.model.calendars.get(cal) else { + return 480; + }; + if c.cal.continuous { + return DAY; + } + let days: Vec = c + .cal + .template + .iter() + .map(|s| s.iter().map(|(a, b)| b - a).sum::()) + .filter(|&m| m > 0) + .collect(); + if days.is_empty() { + 480 + } else { + days.iter().sum::() / days.len() as i64 + } +} + +fn days_on(p: &ProjectData, cal: usize, minutes: i64) -> f64 { + round(minutes as f64 / day_minutes(p, cal).max(1) as f64) +} + +fn date(p: &ProjectData, v: Option) -> Value { + v.map_or(Value::Null, |v| { + json!(date_string(p.model.origin_serial, Some(v))) + }) +} + +/// A model minute on one absolute clock, so two projects compare. +fn absolute(p: &ProjectData, v: i64) -> i64 { + v + p.model.origin_serial * DAY +} + +fn calendar_days(minutes: i64) -> f64 { + (minutes as f64 / DAY as f64 * 10.).round() / 10. + 0. +} + +fn name(p: &ProjectData, a: &Activity) -> String { + p.details + .get(&a.task_id) + .map(|d| d.name.clone()) + .unwrap_or_default() +} + +/// A calendar's name (its id when the file gives none). +fn calendar(p: &ProjectData, cal: usize) -> String { + p.calendar_names + .get(cal) + .filter(|n| !n.is_empty()) + .cloned() + .or_else(|| p.model.calendars.get(cal).map(|c| c.id.clone())) + .unwrap_or_default() +} + +/// The WBS elements from the top level down to `id`, below the project +/// node (codes may themselves hold dots, so paths are not split). +fn wbs_chain(p: &ProjectData, id: i64) -> Vec { + let project = openxer_xer::edit::wbs::project_node(p); + let mut out = vec![]; + let mut at = Some(id).filter(|w| *w != 0); + while let Some(w) = at.filter(|w| Some(*w) != project) { + if out.contains(&w) || out.len() > 10_000 { + break; + } + out.push(w); + at = p.wbs.iter().find(|e| e.id == w).and_then(|e| e.parent); + } + out.reverse(); + out +} + +fn wbs_name(p: &ProjectData, id: i64) -> String { + p.wbs + .iter() + .find(|w| w.id == id) + .map_or(String::new(), |w| w.name.clone()) +} + +fn wbs_of(p: &ProjectData, a: &Activity) -> String { + p.details + .get(&a.task_id) + .map(|d| wbs_code_path(p, d.wbs)) + .unwrap_or_default() +} + +pub fn constraint_label(c: CstrType) -> &'static str { + match c { + CstrType::None => "", + CstrType::StartOn => "Start On", + CstrType::StartOnBefore => "Start On or Before", + CstrType::StartOnAfter => "Start On or After", + CstrType::Alap => "As Late As Possible", + CstrType::FinishOn => "Finish On", + CstrType::FinishOnBefore => "Finish On or Before", + CstrType::FinishOnAfter => "Finish On or After", + CstrType::MandatoryStart => "Mandatory Start", + CstrType::MandatoryFinish => "Mandatory Finish", + } +} + +fn type_label(t: TaskType) -> &'static str { + match t { + TaskType::Task => "Task Dependent", + TaskType::Mile => "Start Milestone", + TaskType::FinMile => "Finish Milestone", + TaskType::Loe => "Level of Effort", + TaskType::Wbs => "WBS Summary", + TaskType::Hamwk => "Hammock", + TaskType::Resource => "Resource Dependent", + } +} + +fn link_label(t: LinkType) -> &'static str { + t.as_str().trim_start_matches("PR_") +} + +fn constraints(p: &ProjectData, a: &Activity) -> Vec { + [(a.cstr, a.cstr_date), (a.cstr2, a.cstr_date2)] + .into_iter() + .filter(|(c, _)| *c != CstrType::None) + .map(|(c, d)| json!({"type": constraint_label(c), "date": date(p, d)})) + .collect() +} + +fn leveled(p: &ProjectData) -> bool { + p.model.options.do_level +} + +/// One activity as every analysis lists it. +pub fn activity_row(p: &ProjectData, i: usize) -> Value { + let a = &p.model.activities[i]; + let original = p.details.get(&a.task_id).map_or(0, |d| d.original_duration); + json!({ + "activity": a.task_code, + "name": name(p, a), + "type": type_label(a.task_type), + "status": status_label(a.status), + "wbs": wbs_of(p, a), + "start": date(p, displayed_start(a, leveled(p))), + "finish": date(p, displayed_finish(a, leveled(p))), + "original_duration_hours": hours(original), + "original_duration_days": days_on(p, a.cal, original), + "remaining_duration_hours": hours(a.rem), + "total_float_hours": a.total_float.map(hours), + "total_float_days": a.total_float.map(|f| days_on(p, a.cal, f)), + "calendar": calendar(p, a.cal), + "constraints": constraints(p, a), + }) +} + +fn link_row(p: &ProjectData, l: usize) -> Value { + let link = &p.model.links[l]; + let pred = &p.model.activities[link.pred]; + let succ = &p.model.activities[link.succ]; + json!({ + "predecessor": pred.task_code, + "predecessor_name": name(p, pred), + "successor": succ.task_code, + "successor_name": name(p, succ), + "type": link_label(link.link_type), + "lag_hours": hours(link.lag), + "lag_days": days_on(p, succ.cal, link.lag), + }) +} + +fn capped(items: Vec) -> Value { + let more = items.len().saturating_sub(LIST_CAP); + let list: Vec = items.into_iter().take(LIST_CAP).collect(); + json!({"items": list, "more": more}) +} + +fn basis(p: &ProjectData) -> Value { + json!({ + "project": p.model.project.name, + "data_date": date(p, p.model.project.data_date), + "scheduled_finish": date(p, p.model.project.scd_end), + "must_finish_by": date(p, p.model.project.plan_end), + "leveled": leveled(p), + "dates": "as last scheduled and stored in the file; schedule the project first when it was changed since", + }) +} + +/// The project baseline finish of every activity, or None. +fn baseline_finishes( + p: &ProjectData, + ctx: &crate::baselines::EvContext, +) -> (Option>>, String) { + match &ctx.project { + Some(bl) => ( + Some( + p.model + .activities + .iter() + .map(|a| bl.by_code.get(&a.task_code).and_then(|d| d.finish)) + .collect(), + ), + bl.name.clone(), + ), + None => (None, String::new()), + } +} + +// ------------------------------------------------------------- check schedule + +/// Thresholds a caller may give, in hours. +#[derive(Clone, Debug, Default)] +pub struct Thresholds { + pub long_lag_hours: Option, + pub large_float_hours: Option, + pub large_duration_hours: Option, +} + +fn with_expenses(p: &ProjectData) -> BTreeSet { + p.document + .table("PROJCOST") + .map_or_else(Default::default, |t| { + t.rows + .iter() + .filter_map(|r| t.value(r, "task_id").trim().parse().ok()) + .collect() + }) +} + +/// Check Schedule, as Tools > Check Schedule runs it, with the activities +/// and relationships each check finds, and the logic warnings the schedule +/// log lists. +pub fn check_schedule( + p: &ProjectData, + ctx: &crate::baselines::EvContext, + t: &Thresholds, +) -> Result { + let mut params = CheckParams::default(); + for (value, slot) in [ + (t.long_lag_hours, &mut params.long_lag_hours), + (t.large_float_hours, &mut params.large_float_hours), + (t.large_duration_hours, &mut params.large_duration_hours), + ] { + if let Some(v) = value { + if !(v.is_finite() && v >= 0.) { + return Err(invalid("thresholds are hours of 0 or more")); + } + *slot = v; + } + } + let (finishes, baseline) = baseline_finishes(p, ctx); + let results = check::run_checks_with(&p.model, ¶ms, &with_expenses(p), finishes.as_deref()); + let item = |it: &Item| match *it { + Item::Activity(i) => activity_row(p, i), + Item::Relationship(l) => link_row(p, l), + }; + let mut flagged = 0; + let checks: Vec = results + .iter() + .map(|r| { + if r.passed == Some(false) { + flagged += 1; + } + let items: Vec = r.items.iter().map(item).collect(); + let threshold_hours = match r.check { + check::Check::LongLags => Some(params.long_lag_hours), + check::Check::LargeFloat => Some(params.large_float_hours), + check::Check::LargeDurations => Some(params.large_duration_hours), + _ => None, + }; + json!({ + "check": r.check.name(), + "what": r.check.caption(), + "count": r.items.len(), + "out_of": r.population, + "value": r.value.map(round), + "value_is": if r.check == check::Check::Bei { "index (completed over due by the baseline)" } else if r.check == check::Check::RelationshipTypes { "percent Finish to Start" } else { "percent" }, + "target": r.target, + "target_is": if r.check.target_is_minimum() { "the value must be above it" } else { "the value must be below it" }, + "threshold_hours": threshold_hours, + "passed": r.passed, + "note": r.note, + "found": capped(items), + }) + }) + .collect(); + let list = |ids: Vec| capped(ids.into_iter().map(|i| activity_row(p, i)).collect()); + let links = |ids: Vec| capped(ids.into_iter().map(|l| link_row(p, l)).collect()); + let m = &p.model; + Ok(json!({ + "basis": basis(p), + "baseline": if finishes.is_some() { json!(baseline) } else { Value::Null }, + "summary": {"checks_run": checks.len(), "checks_failed": flagged}, + "checks": checks, + "logic_warnings": { + "without_predecessors": list(check::without_predecessors(m)), + "without_successors": list(check::without_successors(m)), + "constrained": list(check::constrained(m)), + "actuals_after_data_date": list(check::actuals_after_data_date(m)), + "milestones_with_a_duration_or_odd_ties": list(check::atypical_milestones(m)), + "finish_milestones_fed_from_another_calendar": links(check::finish_milestone_calendar_mismatches(m)), + "out_of_sequence_relationships": links(check::out_of_sequence_links(m)), + }, + "thresholds_note": "Targets and hour limits are the commonly used defaults of Check Schedule unless the caller gave others; durations, lags and float count working time on each activity's own calendar (days in the item rows use that calendar's working day).", + "not_checked": ["whether ties describe how the work is really built", "resource limits (see openxer_resource_loading)", "the critical path test of delaying one activity (see openxer_paths)"], + })) +} + +// ---------------------------------------------------------------- paths + +fn is_open_work(a: &Activity) -> bool { + !a.is_completed() && !matches!(a.task_type, TaskType::Loe | TaskType::Wbs) +} + +fn find(p: &ProjectData, code: &str) -> Result { + p.model + .activities + .iter() + .position(|a| a.task_code == code) + .ok_or_else(|| AutomationError::new("not_found", format!("No activity {code:?}"))) +} + +/// The open activity that finishes last: the project finish. +fn finish_activity(p: &ProjectData) -> Option { + let lv = leveled(p); + (0..p.model.activities.len()) + .filter(|&i| is_open_work(&p.model.activities[i])) + .max_by_key(|&i| displayed_finish(&p.model.activities[i], lv).unwrap_or(i64::MIN)) +} + +/// What holds an activity at the head of a path. +fn held_by(p: &ProjectData, i: usize) -> Value { + let a = &p.model.activities[i]; + let c = constraints(p, a); + if !c.is_empty() { + return json!({"by": "constraint", "constraints": c}); + } + if a.act_start.is_some() { + return json!({"by": "progress (started)"}); + } + if a.preds.is_empty() { + return json!({"by": "nothing before it (no predecessor): it starts at the data date or project start"}); + } + json!({"by": "its predecessors (the path ends here because the next tie back carries more float)"}) +} + +/// The paths into `activity` (or the project finish), ranked by float: path +/// 1 drives it, the next ones are the chains closest behind. +pub fn paths(p: &ProjectData, activity: Option<&str>, count: usize) -> Result { + if !(1..=10).contains(&count) { + return Err(invalid("count is 1 to 10")); + } + let target = match activity { + Some(code) => find(p, code)?, + None => finish_activity(p) + .ok_or_else(|| AutomationError::new("not_found", "The project has no open activity"))?, + }; + let found = openxer_engine::features::activity_paths(&p.model, target, false, count) + .map_err(|e| AutomationError::new("schedule_rejected", e))?; + let m = &p.model; + let mut first_float: Option = None; + let mut list = vec![]; + for (n, path) in found.iter().enumerate() { + if path.is_empty() { + continue; + } + let float = path + .iter() + .filter_map(|&i| { + m.activities[i] + .total_float + .filter(|_| is_open_work(&m.activities[i])) + }) + .min(); + if n == 0 { + first_float = float; + } + let gap = float.zip(first_float).map(|(f, g)| f - g); + let activities: Vec = path.iter().map(|&i| activity_row(p, i)).collect(); + let shown = activities.len().min(40); + list.push(json!({ + "path": n + 1, + "lowest_total_float_hours": float.map(hours), + "behind_path_1_hours": gap.map(hours), + "activity_count": path.len(), + "calendars": path.iter().map(|&i| calendar(p, m.activities[i].cal)).collect::>(), + "first_activity_held_by": held_by(p, path[0]), + "activities": activities.into_iter().take(shown).collect::>(), + "more": path.len() - shown, + })); + } + let open: Vec<&Activity> = m.activities.iter().filter(|a| is_open_work(a)).collect(); + let longest = open.iter().filter(|a| a.driving_path).count(); + let zero = open + .iter() + .filter(|a| a.total_float.is_some_and(|f| f <= 0)) + .count(); + let negative = open + .iter() + .filter(|a| a.total_float.is_some_and(|f| f < 0)) + .count(); + let merges: Vec = { + let mut on: HashMap> = HashMap::new(); + for (n, path) in found.iter().enumerate() { + for &i in path { + on.entry(i).or_default().insert(n + 1); + } + } + let mut points: Vec<(usize, Vec)> = on + .into_iter() + .filter(|(i, set)| { + set.len() > 1 || m.activities[*i].preds.len() > 1 && set.contains(&1) + }) + .map(|(i, set)| (i, set.into_iter().collect())) + .filter(|(i, _)| m.activities[*i].preds.len() > 1) + .collect(); + points.sort(); + points + .into_iter() + .take(10) + .map(|(i, set)| json!({"activity": m.activities[i].task_code, "name": name(p, &m.activities[i]), "predecessor_count": m.activities[i].preds.len(), "on_paths": set})) + .collect() + }; + Ok(json!({ + "basis": basis(p), + "target": activity_row(p, target), + "target_is": if activity.is_some() { "the activity asked for" } else { "the project finish (the open activity that finishes last)" }, + "paths": list, + "merge_points": merges, + "critical_counts": { + "open_activities": open.len(), + "on_the_longest_path": longest, + "total_float_zero_or_less": zero, + "negative_total_float": negative, + "note": "Two common ways to call work critical: on the longest path (the chain that drives the finish), or total float at or below a limit (zero here). They differ when a Must Finish By date, constraints or mixed calendars change float without changing the driving chain.", + }, + "method": "Paths are the scheduler's multiple float paths ending at the target, from the stored dates and float: path 1 drives it; each later path is the next chain by float. Float of a path on mixed calendars is approximate.", + })) +} + +// ---------------------------------------------------------------- compare + +/// What a comparison reads besides the current project. +pub struct Reference { + pub name: String, + pub kind: &'static str, + pub project: ProjectData, +} + +struct Side<'a> { + p: &'a ProjectData, +} + +impl<'a> Side<'a> { + fn new(p: &'a ProjectData) -> Self { + Self { p } + } + fn start(&self, i: usize) -> Option { + displayed_start(&self.p.model.activities[i], leveled(self.p)).map(|v| absolute(self.p, v)) + } + fn finish(&self, i: usize) -> Option { + displayed_finish(&self.p.model.activities[i], leveled(self.p)).map(|v| absolute(self.p, v)) + } +} + +fn section(mut items: Vec<(f64, Value)>) -> Value { + items.sort_by(|a, b| b.0.partial_cmp(&a.0).unwrap_or(std::cmp::Ordering::Equal)); + let count = items.len(); + capped(items.into_iter().map(|(_, v)| v).collect()) + .as_object() + .cloned() + .map_or(Value::Null, |mut o| { + o.insert("count".into(), json!(count)); + Value::Object(o) + }) +} + +/// The current project against a reference (a baseline or an earlier file): +/// dates, activities, logic, durations, constraints, calendars, progress. +pub fn compare(p: &ProjectData, r: &Reference) -> Result { + let now = Side::new(p); + let then = Side::new(&r.project); + let mn = &p.model; + let mt = &r.project.model; + let project_finish = |s: &Side| { + (0..s.p.model.activities.len()) + .filter_map(|i| s.finish(i)) + .max() + }; + let (f_then, f_now) = (project_finish(&then), project_finish(&now)); + let mut added = vec![]; + let mut moved = vec![]; + let mut milestones = vec![]; + let mut durations = vec![]; + let mut remaining_up = vec![]; + let mut constraint_changes = vec![]; + let mut calendar_changes = vec![]; + let mut renamed = vec![]; + let mut started = vec![]; + let mut finished = vec![]; + let mut actuals_changed = vec![]; + let mut reverted = vec![]; + let (mut slipped, mut gained) = (0usize, 0usize); + // Which activities match, were added or deleted, and how the logic + // changed: the shared core the app's Schedule Comparison reads too. + let matches = openxer_xer::compare::match_activities(&r.project, p); + for &i in &matches.added { + added.push((0., activity_row(p, i))); + } + for &(j, i) in &matches.pairs { + let a = &mn.activities[i]; + let b = &mt.activities[j]; + let key = || json!({"activity": a.task_code, "name": name(p, a)}); + let mv = |x: Option, y: Option| x.zip(y).map(|(x, y)| calendar_days(y - x)); + let start_move = mv(then.start(j), now.start(i)); + let finish_move = mv(then.finish(j), now.finish(i)); + if let Some(f) = finish_move.filter(|f| *f != 0.) { + if f > 0. { + slipped += 1 + } else { + gained += 1 + } + let mut v = key(); + v["finish_then"] = date(&r.project, displayed_finish(b, leveled(&r.project))); + v["finish_now"] = date(p, displayed_finish(a, leveled(p))); + v["finish_moved_days"] = json!(f); + v["start_moved_days"] = json!(start_move); + v["total_float_hours_then"] = json!(b.total_float.map(hours)); + v["total_float_hours_now"] = json!(a.total_float.map(hours)); + if matches!(a.task_type, TaskType::Mile | TaskType::FinMile) { + milestones.push((f.abs(), v.clone())); + } + moved.push((f.abs(), v)); + } + let od = |pp: &ProjectData, x: &Activity| { + pp.details + .get(&x.task_id) + .map_or(0, |d| d.original_duration) + }; + let (o_then, o_now) = (od(&r.project, b), od(p, a)); + if o_then != o_now { + let mut v = key(); + v["original_hours_then"] = json!(hours(o_then)); + v["original_hours_now"] = json!(hours(o_now)); + durations.push(((o_now - o_then).abs() as f64, v)); + } + if a.status == StatusType::InProgress && b.status == StatusType::InProgress && a.rem > b.rem + { + let mut v = key(); + v["remaining_hours_then"] = json!(hours(b.rem)); + v["remaining_hours_now"] = json!(hours(a.rem)); + remaining_up.push(((a.rem - b.rem) as f64, v)); + } + let cs = |pp: &ProjectData, x: &Activity| constraints(pp, x); + if cs(&r.project, b) != cs(p, a) { + let mut v = key(); + v["then"] = json!(cs(&r.project, b)); + v["now"] = json!(cs(p, a)); + constraint_changes.push((0., v)); + } + if calendar(&r.project, b.cal) != calendar(p, a.cal) { + let mut v = key(); + v["then"] = json!(calendar(&r.project, b.cal)); + v["now"] = json!(calendar(p, a.cal)); + calendar_changes.push((0., v)); + } + if name(&r.project, b) != name(p, a) { + let mut v = key(); + v["name_then"] = json!(name(&r.project, b)); + renamed.push((0., v)); + } + if b.act_start.is_none() && a.act_start.is_some() { + started.push((0., key())); + } + if b.act_finish.is_none() && a.act_finish.is_some() { + finished.push((0., key())); + } + let abs_t = |x: Option| x.map(|v| absolute(&r.project, v)); + let abs_n = |x: Option| x.map(|v| absolute(p, v)); + if (b.act_start.is_some() + && a.act_start.is_some() + && abs_t(b.act_start) != abs_n(a.act_start)) + || (b.act_finish.is_some() + && a.act_finish.is_some() + && abs_t(b.act_finish) != abs_n(a.act_finish)) + { + let mut v = key(); + v["actual_start_then"] = date(&r.project, b.act_start); + v["actual_start_now"] = date(p, a.act_start); + v["actual_finish_then"] = date(&r.project, b.act_finish); + v["actual_finish_now"] = date(p, a.act_finish); + actuals_changed.push((0., v)); + } + let rank = |s: StatusType| match s { + StatusType::NotStarted => 0, + StatusType::InProgress => 1, + StatusType::Completed => 2, + }; + if rank(a.status) < rank(b.status) { + let mut v = key(); + v["status_then"] = json!(status_label(b.status)); + v["status_now"] = json!(status_label(a.status)); + reverted.push((0., v)); + } + } + let deleted: Vec<(f64, Value)> = matches + .deleted + .iter() + .map(|&j| (0., activity_row(&r.project, j))) + .collect(); + let (mut ties_added, mut ties_removed, mut ties_changed) = (vec![], vec![], vec![]); + for c in openxer_xer::compare::tie_changes(&r.project, p) { + let mut v = json!({"predecessor": c.pred, "successor": c.succ}); + if let Some(o) = c.old { + v["type_then"] = json!(link_label(o.link_type)); + v["lag_hours_then"] = json!(hours(o.lag)); + } + if let Some(n) = c.new { + v["type_now"] = json!(link_label(n.link_type)); + v["lag_hours_now"] = json!(hours(n.lag)); + } + match c.change { + openxer_xer::compare::Change::Added => ties_added.push((0., v)), + openxer_xer::compare::Change::Deleted => ties_removed.push((0., v)), + openxer_xer::compare::Change::Changed => ties_changed.push((0., v)), + } + } + let dd = |pp: &ProjectData| pp.model.project.data_date; + let summary = json!({ + "activities_added": added.len(), "activities_deleted": deleted.len(), + "finishes_later": slipped, "finishes_earlier": gained, + "milestones_moved": milestones.len(), + "ties_added": ties_added.len(), "ties_removed": ties_removed.len(), "ties_changed": ties_changed.len(), + "original_durations_changed": durations.len(), "remaining_up_on_work_in_progress": remaining_up.len(), + "constraints_changed": constraint_changes.len(), "calendars_changed": calendar_changes.len(), + "renamed": renamed.len(), "started": started.len(), "finished": finished.len(), + "actual_dates_rewritten": actuals_changed.len(), "status_went_back": reverted.len(), + }); + Ok(json!({ + "reference": {"name": r.name, "kind": r.kind, "data_date": date(&r.project, dd(&r.project))}, + "current": basis(p), + "project_finish": { + "then": f_then.map(|v| date_string(0, Some(v))), + "now": f_now.map(|v| date_string(0, Some(v))), + "moved_days": f_then.zip(f_now).map(|(a, b)| calendar_days(b - a)), + }, + "summary": summary, + "milestones_moved": section(milestones), + "biggest_finish_moves": section(moved), + "activities_added": section(added), + "activities_deleted": section(deleted), + "ties_added": section(ties_added), + "ties_removed": section(ties_removed), + "ties_changed": section(ties_changed), + "original_durations_changed": section(durations), + "remaining_up_on_work_in_progress": section(remaining_up), + "constraints_changed": section(constraint_changes), + "calendars_changed": section(calendar_changes), + "renamed": section(renamed), + "progress": { + "started": section(started), + "finished": section(finished), + "actual_dates_rewritten": section(actuals_changed), + "status_went_back": section(reverted), + }, + "method": "Activities match by Activity ID and ties by predecessor and successor, as Tools > Schedule Comparison matches them (one shared core): between one pair a lag or type change is a changed tie. Moves are calendar days between the dates each file shows (actual, else scheduled). Lists are ranked by size of the change, biggest first.", + })) +} + +// ---------------------------------------------------------------- look-ahead + +/// The work in progress or due to start or finish in the next `weeks` +/// weeks from the data date (or `from`), by WBS, each with whether it is +/// ready to work or waiting, and on what. +pub fn lookahead(p: &ProjectData, weeks: u32, from: Option<&str>) -> Result { + if !(1..=26).contains(&weeks) { + return Err(invalid("weeks is 1 to 26")); + } + let m = &p.model; + let start = match from { + Some(t) => parse_relative(m.origin_serial, t) + .map_err(|e| invalid(format!("from: {e}")))? + .ok_or_else(|| invalid("from is empty"))?, + None => m + .project + .data_date + .ok_or_else(|| invalid("The project has no data date; give from"))?, + }; + let end = start + weeks as i64 * 7 * DAY; + let lv = leveled(p); + let resources = assigned_resources(p); + let mut groups: BTreeMap> = BTreeMap::new(); + let (mut ready, mut waiting, mut going) = (0, 0, 0); + for (i, a) in m.activities.iter().enumerate() { + if !is_open_work(a) { + continue; + } + let (Some(s), Some(f)) = (displayed_start(a, lv), displayed_finish(a, lv)) else { + continue; + }; + if s >= end || f < start { + continue; + } + let mut row = activity_row(p, i); + let blockers: Vec = m + .links + .iter() + .filter(|l| l.succ == i) + .filter(|l| { + let pr = &m.activities[l.pred]; + match l.link_type { + LinkType::SS | LinkType::SF => pr.act_start.is_none(), + _ => !pr.is_completed(), + } + }) + .map(|l| { + let pr = &m.activities[l.pred]; + json!({"activity": pr.task_code, "name": name(p, pr), "status": status_label(pr.status), + "type": link_label(l.link_type), "expected_finish": date(p, displayed_finish(pr, lv))}) + }) + .collect(); + let state = if a.act_start.is_some() { + going += 1; + "in progress" + } else if blockers.is_empty() { + ready += 1; + "ready: nothing before it is open" + } else { + waiting += 1; + "waiting on predecessors" + }; + row["state"] = json!(state); + row["waiting_on"] = json!(blockers); + row["resources"] = json!(resources.get(&a.task_id).cloned().unwrap_or_default()); + groups.entry(wbs_of(p, a)).or_default().push(row); + } + let total: usize = groups.values().map(Vec::len).sum(); + let mut shown = 0; + let areas: Vec = groups + .into_iter() + .map(|(wbs, mut rows)| { + let id = rows + .first() + .and_then(|r| r["activity"].as_str()) + .and_then(|code| p.model.activities.iter().find(|a| a.task_code == code)) + .and_then(|a| p.details.get(&a.task_id)) + .map_or(0, |d| d.wbs); + let wbs_name = wbs_name(p, id); + let count = rows.len(); + let room = 300usize.saturating_sub(shown); + rows.truncate(room); + shown += rows.len(); + json!({"wbs": wbs, "wbs_name": wbs_name, "count": count, "activities": rows}) + }) + .collect(); + Ok(json!({ + "basis": basis(p), + "window": {"from": date(p, Some(start)), "to": date(p, Some(end)), "weeks": weeks}, + "summary": {"activities": total, "in_progress": going, "ready": ready, "waiting": waiting, "listed": shown}, + "areas": areas, + "rule": "An activity is in the window when its start is before the window's end and its finish is not before its start. Ready means every predecessor it waits on is done (started, for start ties). Waiting lists the open predecessors with their expected finish.", + })) +} + +fn assigned_resources(p: &ProjectData) -> HashMap> { + let mut out: HashMap> = HashMap::new(); + let names: HashMap = p.document.table("RSRC").map_or_else(Default::default, |t| { + t.rows + .iter() + .map(|r| { + ( + t.value(r, "rsrc_id").trim().parse().unwrap_or(0), + t.value(r, "rsrc_short_name").to_string(), + ) + }) + .collect() + }); + if let Some(t) = p.document.table("TASKRSRC") { + for r in &t.rows { + let task: i64 = t.value(r, "task_id").trim().parse().unwrap_or(0); + let rsrc: i64 = t.value(r, "rsrc_id").trim().parse().unwrap_or(0); + if let Some(n) = names.get(&rsrc) { + out.entry(task).or_default().push(n.clone()); + } + } + } + out +} + +// ---------------------------------------------------------------- milestones + +/// Every milestone with its date, float, constraint, baseline date and what +/// drives it. +pub fn milestones(p: &ProjectData, ctx: &crate::baselines::EvContext) -> Result { + let m = &p.model; + let lv = leveled(p); + let (finishes, baseline) = baseline_finishes(p, ctx); + // Driving ties as the Relationships tab shows them: the engine's own + // relationship float on the stored dates. + let mut copy = m.clone(); + let scheduler = openxer_engine::scheduler::Scheduler::new(&mut copy); + let driving: Vec> = (0..m.links.len()) + .map(|r| scheduler.relationship_driving(r)) + .collect(); + drop(scheduler); + let mut rows = vec![]; + for (i, a) in m.activities.iter().enumerate() { + if !matches!(a.task_type, TaskType::Mile | TaskType::FinMile) { + continue; + } + let mut row = activity_row(p, i); + let when = if a.task_type == TaskType::Mile { + displayed_start(a, lv) + } else { + displayed_finish(a, lv) + }; + row["date"] = date(p, when); + if let Some(f) = &finishes { + let bl = f[i]; + row["baseline_date"] = date(p, bl); + row["moved_days_since_baseline"] = + json!(bl.zip(when).map(|(b, w)| calendar_days(w - b))); + } + let preds: Vec = (0..m.links.len()) + .filter(|&r| m.links[r].succ == i) + .collect(); + row["driven_by"] = json!(preds + .iter() + .filter(|&&r| driving[r] == Some(true)) + .map(|&r| { + let l = &m.links[r]; + let pr = &m.activities[l.pred]; + json!({"activity": pr.task_code, "name": name(p, pr), "type": link_label(l.link_type), "lag_hours": hours(l.lag), "finish": date(p, displayed_finish(pr, lv))}) + }) + .collect::>()); + row["predecessor_count"] = json!(preds.len()); + rows.push((when.unwrap_or(i64::MAX), row)); + } + rows.sort_by_key(|(w, _)| *w); + Ok(json!({ + "basis": basis(p), + "baseline": if finishes.is_some() { json!(baseline) } else { Value::Null }, + "count": rows.len(), + "milestones": rows.into_iter().map(|(_, r)| r).take(200).collect::>(), + "rule": "driven_by lists the driving ties into the milestone (no relationship float: the predecessor that sets the date), as the Relationships tab shows them. Empty with predecessors means the date is held by a constraint, the data date or a tie with spare time; empty without predecessors means nothing ties it in. Moves are calendar days.", + })) +} + +// ---------------------------------------------------------------- statistics + +fn percentile(sorted: &[f64], q: f64) -> Option { + if sorted.is_empty() { + return None; + } + let k = ((sorted.len() - 1) as f64 * q).round() as usize; + Some(round(sorted[k])) +} + +/// Counts and spreads the duration, calendar, activity and WBS reviews +/// read: activity types, calendars in use, durations in working days, the +/// longest activities, zero-duration tasks, repeated and short names, +/// activities with no resource, and the WBS depth. +pub fn schedule_stats(p: &ProjectData, update_period_days: Option) -> Result { + if update_period_days.is_some_and(|d| !(d.is_finite() && d > 0.)) { + return Err(invalid("update_period_days must be more than 0")); + } + let m = &p.model; + let mut by_type: BTreeMap<&str, usize> = BTreeMap::new(); + let mut by_status: BTreeMap<&str, usize> = BTreeMap::new(); + for a in &m.activities { + *by_type.entry(type_label(a.task_type)).or_default() += 1; + *by_status.entry(status_label(a.status)).or_default() += 1; + } + // Calendars in use. + let mut use_count: BTreeMap = BTreeMap::new(); + for a in &m.activities { + *use_count.entry(a.cal).or_default() += 1; + } + let calendars: Vec = m + .calendars + .iter() + .enumerate() + .map(|(c, cal)| { + let week: Vec = cal + .cal + .template + .iter() + .map(|s| hours(s.iter().map(|(a, b)| b - a).sum())) + .collect(); + let nonwork_dates = cal.cal.exc.values().filter(|s| s.is_empty()).count(); + let changed_dates = cal.cal.exc.values().filter(|s| !s.is_empty()).count(); + let (first, last) = (cal.cal.exc.keys().next(), cal.cal.exc.keys().next_back()); + json!({ + "calendar": calendar(p, c), + "activities": use_count.get(&c).copied().unwrap_or(0), + "continuous": cal.cal.continuous, + "hours_sunday_to_saturday": week, + "working_days_per_week": week.iter().filter(|h| **h > 0.).count(), + "hours_per_week": round(week.iter().sum()), + "hours_per_working_day": hours(day_minutes(p, c)), + "nonwork_exception_dates": nonwork_dates, + "changed_hours_exception_dates": changed_dates, + "exceptions_from": first.map(|d| date_string(*d, Some(0))), + "exceptions_to": last.map(|d| date_string(*d, Some(0))), + }) + }) + .collect(); + // Durations of open work that has one. + let work: Vec = (0..m.activities.len()) + .filter(|&i| { + let a = &m.activities[i]; + matches!(a.task_type, TaskType::Task | TaskType::Resource) + }) + .collect(); + let original = |i: usize| { + p.details + .get(&m.activities[i].task_id) + .map_or(0, |d| d.original_duration) + }; + let mut days: Vec<(f64, usize)> = work + .iter() + .map(|&i| (days_on(p, m.activities[i].cal, original(i)), i)) + .collect(); + days.sort_by(|a, b| a.0.partial_cmp(&b.0).unwrap_or(std::cmp::Ordering::Equal)); + let values: Vec = days.iter().map(|d| d.0).collect(); + let buckets = [ + ("0 days", 0., 0.), + ("under 1 day", 0.000001, 0.999999), + ("1 to 5 days", 1., 5.), + ("over 5 to 10 days", 5.000001, 10.), + ("over 10 to 20 days", 10.000001, 20.), + ("over 20 to 44 days", 20.000001, 44.), + ("over 44 days", 44.000001, f64::MAX), + ]; + let spread: Vec = buckets + .iter() + .map(|(label, lo, hi)| json!({"range": label, "count": values.iter().filter(|v| **v >= *lo && **v <= *hi).count()})) + .collect(); + let longest: Vec = days + .iter() + .rev() + .take(15) + .map(|(_, i)| activity_row(p, *i)) + .collect(); + let zero: Vec = days + .iter() + .filter(|(d, _)| *d == 0.) + .map(|(_, i)| activity_row(p, *i)) + .collect(); + let over_period = update_period_days.map(|period| { + let list: Vec = days + .iter() + .rev() + .filter(|(d, i)| *d > 2. * period && !m.activities[*i].is_completed()) + .map(|(_, i)| activity_row(p, *i)) + .collect(); + json!({"update_period_days": period, "rule": "open activities longer than two update periods", "found": capped(list)}) + }); + // Names. + let mut names: HashMap> = HashMap::new(); + for (i, a) in m.activities.iter().enumerate() { + names + .entry(name(p, a).trim().to_lowercase()) + .or_default() + .push(i); + } + let mut repeated: Vec = names + .iter() + .filter(|(n, v)| v.len() > 1 && !n.is_empty()) + .map(|(_, v)| json!({"name": name(p, &m.activities[v[0]]), "count": v.len(), "activities": v.iter().take(8).map(|&i| m.activities[i].task_code.clone()).collect::>()})) + .collect(); + repeated.sort_by(|a, b| b["count"].as_u64().cmp(&a["count"].as_u64())); + let short: Vec = (0..m.activities.len()) + .filter(|&i| name(p, &m.activities[i]).split_whitespace().count() < 2) + .map(|i| activity_row(p, i)) + .collect(); + let resources = assigned_resources(p); + let expenses = with_expenses(p); + let unresourced: Vec = work + .iter() + .filter(|&&i| { + let a = &m.activities[i]; + !a.is_completed() + && !resources.contains_key(&a.task_id) + && !expenses.contains(&a.task_id) + }) + .map(|&i| activity_row(p, i)) + .collect(); + // WBS depth. + let mut depth: BTreeMap = BTreeMap::new(); + let mut per_element: HashMap = HashMap::new(); + for a in &m.activities { + let w = p.details.get(&a.task_id).map_or(0, |d| d.wbs); + *per_element.entry(w).or_default() += 1; + *depth.entry(wbs_chain(p, w).len()).or_default() += 1; + } + let project_node = openxer_xer::edit::wbs::project_node(p); + let empty: Vec = p + .wbs + .iter() + .filter(|w| Some(w.id) != project_node) + .filter(|w| { + !per_element.contains_key(&w.id) && !p.wbs.iter().any(|c| c.parent == Some(w.id)) + }) + .map(|w| json!({"wbs": wbs_code_path(p, w.id), "name": w.name})) + .collect(); + let biggest = per_element + .iter() + .filter(|(w, _)| **w != 0) + .max_by_key(|(_, n)| **n) + .map(|(w, n)| json!({"wbs": wbs_code_path(p, *w), "activities": n})); + let lags = m.links.iter().filter(|l| l.lag != 0).count(); + Ok(json!({ + "basis": basis(p), + "activities": m.activities.len(), + "relationships": m.links.len(), + "relationships_with_lag": lags, + "by_type": by_type, + "by_status": by_status, + "calendars": calendars, + "durations": { + "of": "Task and Resource Dependent activities, original duration in working days on each one's own calendar", + "count": values.len(), + "shortest": values.first(), + "median": percentile(&values, 0.5), + "ninetieth_percentile": percentile(&values, 0.9), + "longest": values.last(), + "spread": spread, + "longest_activities": longest, + "zero_duration_tasks": capped(zero), + "longer_than_two_update_periods": over_period, + }, + "names": { + "repeated": repeated.into_iter().take(LIST_CAP).collect::>(), + "one_word": capped(short), + }, + "open_work_without_resources_or_expenses": capped(unresourced), + "wbs": { + "elements": p.wbs.len(), + "activities_by_level": depth.into_iter().map(|(l, n)| json!({"level": l, "activities": n})).collect::>(), + "elements_with_no_activities": capped(empty), + "element_with_most_activities": biggest, + }, + })) +} + +// ---------------------------------------------------------------- resources + +/// Each resource's remaining (and actual) units per period, its peak, its +/// limit and the periods over it. +pub fn resource_loading(p: &ProjectData, interval: Option<&str>) -> Result { + let interval = interval.unwrap_or("week"); + let resources: BTreeSet = assigned_resources(p).into_values().flatten().collect(); + let ids: HashMap = p.document.table("RSRC").map_or_else(Default::default, |t| { + t.rows + .iter() + .map(|r| { + ( + t.value(r, "rsrc_short_name").to_string(), + t.value(r, "rsrc_id").trim().parse().unwrap_or(0), + ) + }) + .collect() + }); + let origin = p.model.origin_serial; + let mut out = vec![]; + for short in &resources { + // The units: the usage spread (shared periods and curves). + let spread = crate::usage::usage( + p, + &crate::usage::Request { + activity: None, + resource: Some(short), + interval: Some(interval), + from: None, + to: None, + costs: false, + }, + )?; + let periods: Vec<(String, i64, i64)> = spread["periods"] + .as_array() + .into_iter() + .flatten() + .filter_map(|v| { + let s = parse_relative(origin, v["start"].as_str()?).ok()??; + let f = parse_relative(origin, v["finish"].as_str()?).ok()??; + Some((v["start"].as_str()?.to_string(), s, f)) + }) + .collect(); + let series = |key: &str| -> Vec { + spread["totals"][key]["per_period"] + .as_array() + .map(|a| a.iter().map(|v| v.as_f64().unwrap_or(0.)).collect()) + .unwrap_or_default() + }; + let remaining = series("remaining"); + let actual = series("actual"); + // The limit: the line the Resource Usage Profile draws, from the + // same function (rate rows times working hours on the resource's + // own calendar). + let rsrc = ids.get(short).copied(); + let bounds: Vec<(i64, i64)> = periods.iter().map(|(_, s, f)| (*s, *f)).collect(); + let limits = rsrc.and_then(|id| openxer_xer::limits::per_period(p, id, &bounds)); + let max_per_hour = rsrc.and_then(|id| { + let rates = openxer_xer::limits::rates(p, id); + let at = p.model.project.data_date.unwrap_or(0) + origin * DAY; + openxer_xer::limits::rate_at(&rates, at).map(|r| r.0) + }); + let calendar_name = rsrc + .map(|id| calendar(p, openxer_xer::limits::resource_calendar(p, id))) + .unwrap_or_default(); + let mut rows = vec![]; + let mut over = vec![]; + let mut peak: Option<(f64, String)> = None; + for (k, (label, _, _)) in periods.iter().enumerate() { + let units = + remaining.get(k).copied().unwrap_or(0.) + actual.get(k).copied().unwrap_or(0.); + let limit = limits.as_ref().and_then(|l| l.get(k).copied()); + if peak.as_ref().is_none_or(|(u, _)| units > *u) { + peak = Some((units, label.clone())); + } + if let Some(l) = limit { + if units > l + 1e-9 { + over.push(json!({"period": label, "units": round(units), "limit": round(l), "over_by": round(units - l)})); + } + } + rows.push(json!({"period": label, "units": round(units), "limit": limit.map(round)})); + } + out.push(json!({ + "resource": short, + "calendar": calendar_name, + "limit_units_per_hour": if limits.is_some() { json!(max_per_hour) } else { Value::Null }, + "has_limit": limits.is_some(), + "peak": peak.map(|(u, l)| json!({"period": l, "units": round(u)})), + "total_remaining": spread["totals"]["remaining"]["total"], + "total_actual": spread["totals"]["actual"]["total"], + "periods_over_limit": over.len(), + "over_limit": over.into_iter().take(LIST_CAP).collect::>(), + "per_period": rows, + })); + } + Ok(json!({ + "basis": basis(p), + "interval": interval, + "resources": out, + "rule": "Units per period are actual plus remaining as the usage views spread them. The limit per period is the line the Resource Usage Profile draws: the resource's max units per hour in effect at the period's start times the period's working hours on the resource's own calendar (the project's default calendar when it has none). A resource with no limit row has no limit (has_limit false). Leveling is not run: schedule a copy with level_resources to see what it would move.", + })) +} + +// ---------------------------------------------------------------- WBS summary + +/// The schedule rolled up by WBS element down to `level`: dates, float, +/// counts and baseline finish, for a summary schedule and for checking that +/// the levels agree. +pub fn wbs_summary( + p: &ProjectData, + ctx: &crate::baselines::EvContext, + level: usize, +) -> Result { + if !(1..=10).contains(&level) { + return Err(invalid("level is 1 to 10")); + } + let m = &p.model; + let lv = leveled(p); + let (finishes, baseline) = baseline_finishes(p, ctx); + #[derive(Default)] + struct Roll { + count: usize, + completed: usize, + start: Option, + finish: Option, + float: Option, + baseline: Option, + milestones: Vec, + } + // Keyed by the chain of elements from the top, so the rows come out in + // outline order. + let mut rolls: BTreeMap, Roll> = BTreeMap::new(); + let seq = |id: i64| p.wbs.iter().find(|w| w.id == id).map_or(0, |w| w.sequence); + for (i, a) in m.activities.iter().enumerate() { + let parts: Vec<(i64, i64)> = wbs_chain(p, p.details.get(&a.task_id).map_or(0, |d| d.wbs)) + .into_iter() + .map(|id| (seq(id), id)) + .collect(); + for depth in 1..=parts.len().min(level) { + let key = parts[..depth].to_vec(); + let r = rolls.entry(key).or_default(); + r.count += 1; + if a.is_completed() { + r.completed += 1; + } + if let Some(s) = displayed_start(a, lv) { + r.start = Some(r.start.map_or(s, |x| x.min(s))); + } + if let Some(f) = displayed_finish(a, lv) { + r.finish = Some(r.finish.map_or(f, |x| x.max(f))); + } + if is_open_work(a) { + if let Some(tf) = a.total_float { + r.float = Some(r.float.map_or(tf, |x| x.min(tf))); + } + } + if let Some(b) = finishes.as_ref().and_then(|f| f[i]) { + r.baseline = Some(r.baseline.map_or(b, |x| x.max(b))); + } + if depth == parts.len().min(level) + && matches!(a.task_type, TaskType::Mile | TaskType::FinMile) + && r.milestones.len() < 10 + { + r.milestones.push(json!({"activity": a.task_code, "name": name(p, a), "date": date(p, displayed_finish(a, lv).or(displayed_start(a, lv)))})); + } + } + } + let rows: Vec = rolls + .into_iter() + .map(|(chain, r)| { + let id = chain.last().map_or(0, |(_, id)| *id); + json!({ + "wbs": wbs_code_path(p, id), "level": chain.len(), "name": wbs_name(p, id), + "activities": r.count, "completed": r.completed, + "start": date(p, r.start), "finish": date(p, r.finish), + "lowest_total_float_hours": r.float.map(hours), + "baseline_finish": date(p, r.baseline), + "finish_moved_days_since_baseline": r.baseline.zip(r.finish).map(|(b, f)| calendar_days(f - b)), + "milestones": r.milestones, + }) + }) + .collect(); + Ok(json!({ + "basis": basis(p), + "baseline": if finishes.is_some() { json!(baseline) } else { Value::Null }, + "level": level, + "elements": rows, + "rule": "Each element rolls up every activity below it: earliest start, latest finish, lowest total float of open work, latest baseline finish. A parent's dates always span its children's; an element whose dates do not is a sign of activities filed on the wrong element.", + })) +} diff --git a/automation/src/baseline_cmd.rs b/automation/src/baseline_cmd.rs new file mode 100644 index 0000000..8ff934f --- /dev/null +++ b/automation/src/baseline_cmd.rs @@ -0,0 +1,771 @@ +//! `baseline list` and the `baseline` edits on an OpenXER workspace: +//! Project > Maintain Baselines (add a copy, convert a project, copy, +//! delete, restore, the Baseline ID, Name and Type fields), Project > +//! Assign Baselines and Project > Revert Project to Baseline. The rules are +//! the app's own (`baseline_ops`); an edit works on a copy of the workspace +//! written to `output`. The command line and the MCP tools come from the +//! definitions here. +use crate::baseline_ops::{self as ops, Owner}; +use crate::baseline_store::{self as store, BaselineRow, Choice, UserBaselines}; +use crate::storage::{self, invalid, io, parent}; +use crate::{AutomationError, Result}; +use openxer_interchange::baseline as xb; +use openxer_xer::ProjectData; +use rusqlite::{Connection, OptionalExtension}; +use serde::Deserialize; +use serde_json::{json, Map, Value}; +use std::collections::BTreeMap; +use std::path::{Path, PathBuf}; + +/// One baseline edit. A baseline is named by its row id (from `baseline +/// list`), its Baseline ID or its name. +#[derive(Debug, Clone, Deserialize)] +#[serde(tag = "op", rename_all = "snake_case", deny_unknown_fields)] +pub enum BaselineOperation { + /// Add > Save a copy of the current project. + Add, + /// Add > Convert another project: a closed workspace project (by + /// workspace id) becomes a baseline of this one. + Convert { project: i64 }, + /// Copy: another baseline of the project with the next number. + Copy { baseline: String }, + /// Delete an unassigned baseline. + Delete { baseline: String }, + /// Restore an unassigned baseline as a separate project. + Restore { baseline: String }, + /// Revert Project to Baseline: the project takes the baseline's data. + Revert { baseline: String }, + /// The Baseline ID, Baseline Name and Baseline Type fields. + Set { + baseline: String, + #[serde(default)] + baseline_id: Option, + #[serde(default)] + name: Option, + /// A baseline type name, or "none". + #[serde(default, rename = "type")] + kind: Option, + }, + /// Assign Baselines: each slot "current", "none" (user baselines) or a + /// baseline; an omitted slot keeps its choice. + Assign { + #[serde(default)] + project_baseline: Option, + #[serde(default)] + primary: Option, + #[serde(default)] + secondary: Option, + #[serde(default)] + tertiary: Option, + }, +} + +impl BaselineOperation { + fn name(&self) -> &'static str { + match self { + Self::Add => "add", + Self::Convert { .. } => "convert", + Self::Copy { .. } => "copy", + Self::Delete { .. } => "delete", + Self::Restore { .. } => "restore", + Self::Revert { .. } => "revert", + Self::Set { .. } => "set", + Self::Assign { .. } => "assign", + } + } +} + +fn args(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +fn refusal(e: ops::Error) -> AutomationError { + match e { + ops::Error::Refused(m) => AutomationError::new("refused", m), + ops::Error::Failed(m) => AutomationError::new("failed", m), + } +} + +fn has_table(c: &Connection, name: &str) -> bool { + c.query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name=?1", + [name], + |_| Ok(()), + ) + .optional() + .ok() + .flatten() + .is_some() +} + +/// The baseline `text` names among `rows`: a row id, a Baseline ID or a +/// name. +fn find(rows: &[BaselineRow], text: &str) -> Result { + let text = text.trim(); + if let Ok(id) = text.parse::() { + if rows.iter().any(|r| r.id == id) { + return Ok(id); + } + } + let picks: [fn(&BaselineRow, &str) -> bool; 3] = [ + |r, t| r.short_name == t, + |r, t| r.name == t, + |r, t| r.short_name.eq_ignore_ascii_case(t) || r.name.eq_ignore_ascii_case(t), + ]; + for pick in picks { + let hits: Vec = rows + .iter() + .filter(|r| pick(r, text)) + .map(|r| r.id) + .collect(); + match hits.as_slice() { + [one] => return Ok(*one), + [] => {} + _ => { + return Err(AutomationError::new( + "ambiguous", + format!( + "Several baselines match {text:?}; name it by its id from baseline list" + ), + )) + } + } + } + Err(AutomationError::new( + "not_found", + format!("The project has no baseline {text:?}; see baseline list"), + )) +} + +/// An Assign Baselines slot: "current", "none" or a baseline. +fn choice(rows: &[BaselineRow], text: &str) -> Result { + match text.trim().to_ascii_lowercase().as_str() { + "current" | "" | "current project" => Ok(Choice::Current), + "none" | "" => Ok(Choice::None), + _ => find(rows, text).map(Choice::Baseline), + } +} + +fn choice_json(rows: &[BaselineRow], choice: Choice) -> Value { + match choice { + Choice::None => json!("none"), + Choice::Current => json!("current"), + Choice::Baseline(id) => rows.iter().find(|r| r.id == id).map_or( + json!("none"), + |r| json!({"id": r.id, "baseline_id": r.short_name, "name": r.name}), + ), + } +} + +fn type_name(doc: &openxer_xer::Document, stored: &str) -> String { + let id = ops::type_id(doc, stored); + ops::type_choices(doc) + .into_iter() + .skip(1) + .find(|(k, _)| *k == id) + .map(|(_, n)| n) + .unwrap_or_default() +} + +/// One project's band: its baselines (columns of Maintain Baselines) and +/// its assignments (Assign Baselines). +fn band( + c: &Connection, + id: i64, + title: &str, + doc: &openxer_xer::Document, + key: i64, +) -> Result { + let rows = if has_table(c, "baselines") { + store::list(c, id).map_err(invalid)? + } else { + vec![] + }; + let field = xb::project_value(doc, key, "sum_base_proj_id"); + let users = if has_table(c, "baseline_assign") { + store::user_baselines(c, id) + } else { + UserBaselines::default() + }; + let project = rows + .iter() + .find(|r| field.trim() == r.project_key.to_string()) + .map_or(Choice::Current, |r| Choice::Baseline(r.id)); + let baselines: Vec = rows + .iter() + .map(|r| { + json!({ + "id": r.id, + "baseline_id": r.short_name, + "name": r.name, + "type": type_name(doc, &r.baseline_type), + "data_date": r.data_date, + "date_added": r.added, + "last_update_date": r.updated, + "assigned": ops::assigned_roles(c, r, &field), + }) + }) + .collect(); + Ok(json!({ + "workspace_id": id, + "project_id": title, + "name": xb::project_name(doc, key), + "baselines": baselines, + "assigned": { + "project_baseline": choice_json(&rows, project), + "primary": choice_json(&rows, users.0[0]), + "secondary": choice_json(&rows, users.0[1]), + "tertiary": choice_json(&rows, users.0[2]), + }, + "baseline_types": ops::type_choices(doc).into_iter().skip(1).map(|(_, n)| n).collect::>(), + })) +} + +/// Projects of a workspace with their stored text: (id, title, key, text). +fn projects(c: &Connection) -> Result> { + let mut stmt = c + .prepare("SELECT id,title,project_key,xer_content FROM projects ORDER BY id") + .map_err(invalid)?; + let rows = stmt + .query_map([], |r| Ok((r.get(0)?, r.get(1)?, r.get(2)?, r.get(3)?))) + .map_err(invalid)?; + rows.collect::, _>>() + .map_err(invalid) +} + +/// A project's band as the workspace `c` holds it now. +fn band_of(c: &Connection, id: i64) -> Result { + let p = projects(c)? + .into_iter() + .find(|p| p.0 == id) + .ok_or_else(|| { + AutomationError::new( + "project_not_found", + format!("No workspace project has the id {id}"), + ) + })?; + let mut doc = openxer_xer::Document::parse(&p.3).map_err(invalid)?; + if storage::shared(c)? { + crate::workspace_db::hydrate(c, &mut doc, Some(id)).map_err(invalid)?; + } + band(c, id, &p.1, &doc, p.2) +} + +/// `baseline list`: every workspace project (or one) with its baselines. +/// Baselines are not projects: they never appear in the project lists. +pub fn list(input: &Path, workspace_id: Option) -> Result { + if !storage::is_database(input)? { + return Err(args( + "baseline list needs an OpenXER workspace database (.db)", + )); + } + let c = storage::read_database(input)?; + let mut out = vec![]; + for (id, _, _, _) in projects(&c)? { + if workspace_id.is_some_and(|w| w != id) { + continue; + } + out.push(band_of(&c, id)?); + } + if out.is_empty() { + if let Some(w) = workspace_id { + return Err(AutomationError::new( + "project_not_found", + format!("No workspace project has the id {w}"), + )); + } + } + Ok(json!({"input": input, "projects": out})) +} + +/// Run one baseline edit of workspace project `workspace_id` on a copy of +/// `input` written to `output` (with `dry_run`, only report it). +pub fn edit( + input: &Path, + output: Option, + dry_run: bool, + workspace_id: i64, + op: &BaselineOperation, +) -> Result { + match (&output, dry_run) { + (Some(_), true) => return Err(args("dry_run writes nothing; omit output")), + (None, false) => return Err(args("output is required unless dry_run is true")), + (Some(path), false) => { + storage::check_destination(path)?; + if !storage::is_database_extension(path) { + return Err(args( + "baseline edits write an OpenXER workspace (.db/.sqlite/.sqlite3)", + )); + } + } + (None, true) => {} + } + if !storage::is_database(input)? { + return Err(args( + "baseline edits need an OpenXER workspace database input", + )); + } + let mut loaded = storage::load(input, None, Some(workspace_id))?; + let source = storage::read_database(input)?; + let temp_dir; + let temp = match &output { + Some(path) => tempfile::NamedTempFile::new_in(parent(path)).map_err(io)?, + None => { + temp_dir = std::env::temp_dir(); + tempfile::NamedTempFile::new_in(&temp_dir).map_err(io)? + } + }; + source.backup("main", temp.path(), None).map_err(io)?; + drop(source); + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE;PRAGMA foreign_keys=ON") + .map_err(io)?; + let tx = c.transaction().map_err(io)?; + storage::schema(&tx)?; + store::ensure(&tx).map_err(io)?; + let rows = store::list(&tx, workspace_id).map_err(invalid)?; + let doc = loaded.project.updated_document(); + let pid = loaded.project.model.project.proj_id; + let project_id = loaded.project.model.project.name.clone(); + let name = xb::project_name(&doc, pid); + let owner = Owner { + id: workspace_id, + doc: &doc, + pid, + project_id: &project_id, + name: &name, + windows_encoding: loaded.project.document.windows_encoding, + }; + let stamp = ops::now_stamp(); + let mut reverted = None; + let change = match op { + BaselineOperation::Add => ops::add_copy(&tx, &owner, &stamp), + BaselineOperation::Convert { project } => { + if store::project_row(&tx, *project) + .map_err(invalid)? + .is_none() + { + return Err(AutomationError::new( + "project_not_found", + format!("No workspace project has the id {project}"), + )); + } + let src = if *project == workspace_id { + doc.clone() + } else { + ops::source_document(&tx, *project).map_err(invalid)? + }; + // From the command line the project worked on counts as open. + ops::convert(&tx, &owner, *project, &src, &[workspace_id], &stamp) + } + BaselineOperation::Copy { baseline } => { + ops::copy(&tx, &owner, find(&rows, baseline)?, &stamp) + } + BaselineOperation::Delete { baseline } => ops::delete(&tx, &owner, find(&rows, baseline)?), + BaselineOperation::Restore { baseline } => { + ops::restore(&tx, &owner, find(&rows, baseline)?) + } + BaselineOperation::Set { + baseline, + baseline_id, + name, + kind, + } => { + if baseline_id.is_none() && name.is_none() && kind.is_none() { + return Err(args("set needs baseline_id, name or type")); + } + ops::set( + &tx, + &owner, + find(&rows, baseline)?, + baseline_id.as_deref(), + name.as_deref(), + kind.as_deref(), + ) + } + BaselineOperation::Assign { + project_baseline, + primary, + secondary, + tertiary, + } => { + let (_, mut users) = ops::choices(&tx, &owner); + for (k, slot) in [primary, secondary, tertiary].into_iter().enumerate() { + if let Some(t) = slot { + users.0[k] = choice(&rows, t)?; + } + } + let project = project_baseline + .as_deref() + .map(|t| choice(&rows, t)) + .transpose()?; + if project == Some(Choice::None) { + return Err(args( + "project_baseline is current or a baseline; none is for the user baselines", + )); + } + ops::assign(&tx, &owner, project, users) + } + BaselineOperation::Revert { baseline } => { + let id = find(&rows, baseline)?; + let row = store::get(&tx, id).map_err(invalid)?.expect("listed"); + let doc = ops::reverted(&owner, &row).map_err(invalid)?; + let mut p = ProjectData::from_document(doc, pid, loaded.project.source_name.clone()) + .map_err(invalid)?; + p.model.options.do_level = loaded.project.model.options.do_level; + p.model.validate().map_err(invalid)?; + reverted = Some((row.short_name.clone(), p)); + Ok(ops::Change::default()) + } + } + .map_err(refusal)?; + ops::apply(&tx, &change, true).map_err(io)?; + if let Some((_, after)) = &change.project_baseline { + xb::set_project_value(&mut loaded.project.document, pid, "sum_base_proj_id", after); + storage::store( + &tx, + &loaded.project, + Some(workspace_id), + loaded.mark.as_ref(), + )?; + } + let result = match (op, change.made) { + (BaselineOperation::Restore { .. }, Some(new)) => { + let ws = openxer_xer::workspace::Workspace::from_text( + &tx.query_row( + "SELECT value FROM preferences WHERE key=?1", + [openxer_xer::workspace::KEY], + |r| r.get::<_, String>(0), + ) + .optional() + .map_err(io)? + .unwrap_or_default(), + ); + let row = store::project_row(&tx, new) + .map_err(invalid)? + .expect("restored"); + json!({"workspace_id": new, "project_id": row.title, + "folder": ws.eps_value(ws.node_of(Some(new)), "eps_short_name")}) + } + (_, Some(made)) => { + let row = store::get(&tx, made).map_err(invalid)?.expect("made"); + json!({"id": row.id, "baseline_id": row.short_name, "name": row.name}) + } + (BaselineOperation::Revert { .. }, None) => { + let (from, p) = reverted.expect("reverted"); + let activities = p.model.activities.len(); + storage::store(&tx, &p, Some(workspace_id), loaded.mark.as_ref())?; + json!({"reverted_to": from, "activities": activities}) + } + (_, None) => json!({"changed": !change.is_empty()}), + }; + let band = band_of(&tx, workspace_id)?; + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + if let Some(path) = &output { + storage::publish(temp, path)?; + } + Ok( + json!({"output": output, "dry_run": dry_run, "op": op.name(), "result": result, "project": band}), + ) +} + +/// The preview as JSON: the Project, WBS and Activities groups, each change +/// with its fields (project value, baseline value). +fn preview_json(p: &openxer_interchange::baseline_update::Preview) -> Value { + let (added, deleted, updated) = p.counts(); + json!({ + "activities_added": added, + "activities_deleted": deleted, + "activities_updated": updated, + "project": p.project, + "wbs": p.wbs, + "activities": p.activities, + }) +} + +/// `baseline update`: Maintain Baselines > Update of baseline `baseline` of +/// workspace project `workspace_id` with `options` (the Update Baseline +/// options; omitted ones take the dialog's defaults). `activities` limits +/// the activities added or updated to those Activity IDs, as a filter does +/// in the app. With `dry_run` it returns the preview and writes nothing; +/// otherwise the updated workspace goes to `output`, and the log to the +/// options' `log_path` when `log_to_file` is on and a path is given. +pub fn update( + input: &Path, + output: Option, + dry_run: bool, + workspace_id: i64, + baseline: &str, + options: &openxer_interchange::baseline_update::UpdateOptions, + activities: Option<&[String]>, +) -> Result { + match (&output, dry_run) { + (Some(_), true) => return Err(args("dry_run writes nothing; omit output")), + (None, false) => return Err(args("output is required unless dry_run is true")), + (Some(path), false) => { + storage::check_destination(path)?; + if !storage::is_database_extension(path) { + return Err(args( + "baseline update writes an OpenXER workspace (.db/.sqlite/.sqlite3)", + )); + } + } + (None, true) => {} + } + if !storage::is_database(input)? { + return Err(args( + "baseline update needs an OpenXER workspace database input", + )); + } + if options.use_filter { + return Err(args( + "filters (use_filter, filters, filter_match_all) are evaluated by the app; pass the Activity IDs in activities instead", + )); + } + let loaded = storage::load(input, None, Some(workspace_id))?; + let source = storage::read_database(input)?; + let temp_dir; + let temp = match &output { + Some(path) => tempfile::NamedTempFile::new_in(parent(path)).map_err(io)?, + None => { + temp_dir = std::env::temp_dir(); + tempfile::NamedTempFile::new_in(&temp_dir).map_err(io)? + } + }; + source.backup("main", temp.path(), None).map_err(io)?; + drop(source); + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE;PRAGMA foreign_keys=ON") + .map_err(io)?; + let tx = c.transaction().map_err(io)?; + storage::schema(&tx)?; + store::ensure(&tx).map_err(io)?; + let rows = store::list(&tx, workspace_id).map_err(invalid)?; + let id = find(&rows, baseline)?; + let doc = loaded.project.updated_document(); + let pid = loaded.project.model.project.proj_id; + let project_id = loaded.project.model.project.name.clone(); + let name = xb::project_name(&doc, pid); + let owner = Owner { + id: workspace_id, + doc: &doc, + pid, + project_id: &project_id, + name: &name, + windows_encoding: loaded.project.document.windows_encoding, + }; + let only: Option> = + activities.map(|a| a.iter().map(|s| s.trim().to_string()).collect()); + let stamp = ops::now_stamp(); + let (change, preview) = + ops::update(&tx, &owner, id, options, only.as_ref(), &stamp).map_err(refusal)?; + let row = rows.iter().find(|r| r.id == id).expect("found"); + let mut log = None; + if !dry_run { + ops::apply(&tx, &change, true).map_err(io)?; + if options.log_to_file && !options.log_path.trim().is_empty() { + let path = PathBuf::from(options.log_path.trim()); + std::fs::write( + &path, + ops::update_log(&owner, row, options, &preview, &stamp), + ) + .map_err(io)?; + log = Some(path); + } + } + let band = band_of(&tx, workspace_id)?; + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + if let Some(path) = &output { + storage::publish(temp, path)?; + } + Ok(json!({ + "output": output, + "dry_run": dry_run, + "op": "update", + "result": { + "baseline": {"id": row.id, "baseline_id": row.short_name, "name": row.name}, + "last_update_date": if dry_run { row.updated.clone() } else { stamp }, + "log": log, + "options": options.effective(), + "preview": preview_json(&preview), + }, + "project": band, + })) +} + +/// The `baseline` command line: `list` and the edits. Returns the request +/// for the shared dispatcher. +pub fn parse_cli( + args_in: &[String], + flags: impl Fn(&[String], &[&str]) -> Result>, +) -> Result { + let sub = args_in.first().map(String::as_str).unwrap_or(""); + let rest = args_in.get(1..).unwrap_or(&[]); + let (op, own, required): (&str, &[&str], &[&str]) = match sub { + "list" => ("", &[], &[]), + "add" => ("add", &[], &[]), + "convert" => ("convert", &["project"], &["project"]), + "copy" | "delete" | "restore" | "revert" => (sub, &["baseline"], &["baseline"]), + "set" => ( + "set", + &["baseline", "baseline-id", "name", "type"], + &["baseline"], + ), + "assign" => ( + "assign", + &["project-baseline", "primary", "secondary", "tertiary"], + &[], + ), + "update" => ("update", &["baseline", "options", "activities"], &["baseline"]), + _ => return Err(args( + "baseline requires list, add, convert, copy, delete, restore, revert, set, assign or update", + )), + }; + let common: &[&str] = if sub == "list" { + &["input", "workspace-id"] + } else { + &["input", "workspace-id", "output", "dry-run"] + }; + let allowed: Vec<&str> = common.iter().chain(own).copied().collect(); + let fields = flags(rest, &allowed)?; + for flag in ["input"] + .iter() + .chain(if sub == "list" { + &[][..] + } else { + &["workspace-id"][..] + }) + .chain(required) + { + if !fields.contains_key(*flag) { + return Err(args(format!("baseline {sub} requires --{flag}"))); + } + } + let integer = |name: &str, text: &str| -> Result { + text.parse::() + .map(Value::from) + .map_err(|_| args(format!("--{name} {text:?} is not an integer"))) + }; + let mut request = Map::new(); + let mut operation = Map::new(); + for (name, value) in &fields { + match name.as_str() { + "input" | "output" => { + request.insert(name.clone(), Value::from(value.as_str())); + } + "workspace-id" => { + request.insert("workspace_id".into(), integer(name, value)?); + } + "dry-run" => { + let flag = value + .parse::() + .map_err(|_| args("--dry-run accepts true or false"))?; + request.insert("dry_run".into(), Value::Bool(flag)); + } + "project" => { + operation.insert("project".into(), integer(name, value)?); + } + "options" if sub == "update" => { + let parsed: Value = serde_json::from_str(value) + .map_err(|e| args(format!("--options is not a JSON object: {e}")))?; + if !parsed.is_object() { + return Err(args( + "--options is a JSON object of Update Baseline options", + )); + } + request.insert("options".into(), parsed); + } + "activities" if sub == "update" => { + let ids: Vec = value + .split(',') + .map(str::trim) + .filter(|s| !s.is_empty()) + .map(Value::from) + .collect(); + request.insert("activities".into(), Value::Array(ids)); + } + "baseline" if sub == "update" => { + request.insert("baseline".into(), Value::from(value.as_str())); + } + _ => { + operation.insert(name.replace('-', "_"), Value::from(value.as_str())); + } + } + } + if sub == "list" { + request.insert("command".into(), Value::from("baseline_list")); + } else if sub == "update" { + request.insert("command".into(), Value::from("baseline_update")); + } else { + operation.insert("op".into(), Value::from(op)); + request.insert("command".into(), Value::from("baseline")); + request.insert("operation".into(), Value::Object(operation)); + } + Ok(Value::Object(request)) +} + +/// `openxer_baseline_edit` takes the operation's fields at the top; they go +/// into the `operation` of a `baseline` command. +pub fn mcp_arguments(args: Map) -> Map { + let mut top = Map::new(); + let mut operation = Map::new(); + for (k, v) in args { + if matches!(k.as_str(), "input" | "output" | "dry_run" | "workspace_id") { + top.insert(k, v); + } else { + operation.insert(k, v); + } + } + top.insert("operation".into(), Value::Object(operation)); + top +} + +/// The MCP tool name of each `baseline` command. +pub const TOOLS: &[(&str, &str)] = &[ + ("openxer_baseline_list", "baseline_list"), + ("openxer_baseline_edit", "baseline"), + ("openxer_baseline_update", "baseline_update"), +]; + +/// The MCP tool definitions of the `baseline` commands. +pub fn tool_definitions() -> Vec { + let output = json!({"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}); + let input = json!({"type":"string","minLength":1,"description":"OpenXER workspace database path; read-only"}); + let text = json!({"type":"string","minLength":1}); + vec![ + json!({"name":"openxer_baseline_list", + "description":"List the stored baselines of each workspace project (or of workspace_id) as Project > Maintain Baselines shows them: id, Baseline ID, name, type, data date, date added, last update date and what each is assigned as; with the project's Assign Baselines choices (project baseline, primary, secondary, tertiary) and the baseline types. Baselines are not projects and never appear in the project lists. Read-only.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{"input":input,"workspace_id":{"type":"integer"}},"required":["input"]}, + "outputSchema":output, + "annotations":{"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}}), + json!({"name":"openxer_baseline_edit", + "description":"Change the baselines of workspace project workspace_id on a copy written to output (or dry_run), with the app's rules: add (a copy of the project named \" - B\" / \" - B\", n the lowest free number), convert (project: the workspace id of a closed project; it becomes a baseline keeping its ID and name, last update date blank), copy (another baseline with the next number, the source's last update date), delete and restore (refused while the baseline is assigned as project, primary, secondary or tertiary baseline; restore makes it a separate project with its ID and name in the owner's EPS folder), revert (Revert Project to Baseline: the project takes the baseline's data and keeps its ID, name and baselines), set (baseline_id, name, type: a baseline type name or none) and assign (project_baseline: current or a baseline; primary, secondary, tertiary: current, none or a baseline; omitted slots keep their choice). A baseline is named by its id from openxer_baseline_list, its Baseline ID or its name. A refused edit fails with the code refused and writes nothing.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{ + "input":input, + "output":{"type":"string","minLength":1,"description":"New workspace path; existing files are refused. Omit with dry_run"}, + "dry_run":{"type":"boolean","default":false}, + "workspace_id":{"type":"integer","description":"The project whose baselines change"}, + "op":{"type":"string","enum":["add","convert","copy","delete","restore","revert","set","assign"]}, + "project":{"type":"integer","description":"convert: the workspace id of the project to convert"}, + "baseline":text,"baseline_id":text,"name":text,"type":text, + "project_baseline":text,"primary":text,"secondary":text,"tertiary":text + },"required":["input","workspace_id","op"]}, + "outputSchema":output, + "annotations":{"readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false}}), + json!({"name":"openxer_baseline_update", + "description":"Maintain Baselines > Update: carry data from workspace project workspace_id into its baseline (id from openxer_baseline_list, Baseline ID or name) by the Update Baseline options, with the app's rules; an assigned baseline may be updated and Last Update Date is set. options holds any of the dialog's options (omitted ones take its defaults): General project_details (on), project_udfs, risks_issues, risk_udfs, issue_udfs, documents, document_udfs, wbs_udfs, log_to_file (on) with log_path (a log is written only when a path is given), ignore_last_update and run_optimized (accepted, no effect); Activities add_new, delete_missing, update_existing (on); Activity general (on), relationships, constraints, dates, wbs (on), risks, activity_udfs, codes (on), notebooks (on), steps (on), step_udfs, expenses, expense_udfs, budget_no_assignments, actual_no_assignments; Resource Assignment update_assignments, update_assignment_budget, update_assignment_actual, add_assignments (on), add_assignment_budget (on), add_assignment_actual (on), assignment_udfs, assignment_codes. activities limits the activities added or updated to those Activity IDs (the app's filter). Activities are matched by GUID, then Activity ID. dry_run returns the preview (each changed project, WBS element and activity as Added, Deleted or Updated with field, project value and baseline value) and writes nothing; otherwise the result goes to output with the same preview.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{ + "input":input, + "output":{"type":"string","minLength":1,"description":"New workspace path; existing files are refused. Omit with dry_run"}, + "dry_run":{"type":"boolean","default":false}, + "workspace_id":{"type":"integer","description":"The project whose baseline is updated"}, + "baseline":text, + "options":{"type":"object","description":"Update Baseline options by name; omitted ones take the dialog's defaults"}, + "activities":{"type":"array","items":{"type":"string"},"description":"Only these Activity IDs are added or updated"} + },"required":["input","workspace_id","baseline"]}, + "outputSchema":output, + "annotations":{"readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false}}), + ] +} diff --git a/automation/src/baseline_ops.rs b/automation/src/baseline_ops.rs new file mode 100644 index 0000000..6b5e415 --- /dev/null +++ b/automation/src/baseline_ops.rs @@ -0,0 +1,774 @@ +//! Maintain Baselines and Assign Baselines: what each command does to the +//! workspace, worked out once for the app and for `openxer-cli` and MCP. +//! +//! A command returns a [`Change`]: every workspace row it touches, as it was +//! and as it will be. The app keeps the change as its undo step; the CLI +//! writes it to a copy of the workspace. [`apply`] writes one side of it. +//! +//! The rules follow the observed behaviour of the scheduler users know: +//! - Add (save a copy) names the copy " - B" and +//! " - B", n the lowest number not in use; the copy keeps +//! the project's data date, and its last update date is the time it was +//! taken. +//! - Add (convert) turns a closed workspace project into a baseline that +//! keeps its own ID and name, with a blank last update date; an open +//! project is refused. +//! - Copy makes another baseline of the same project with the next number, +//! keeping the source's data date, type and last update date. +//! - Restore detaches a baseline into a separate project with the same ID +//! and name, filed in the owner's EPS folder. +//! - Delete and Restore refuse a baseline that is assigned (project +//! baseline, or primary, secondary or tertiary user baseline). +//! - Revert Project to Baseline (an OpenXER command of its own) replaces +//! the open project's data with a baseline's; the baseline stays. +//! - Update carries the project's data into a baseline by the Update +//! Baseline options (`openxer_interchange::baseline_update`), with no +//! question first, and sets its last update date; an assigned baseline +//! may be updated. Its preview is the same call's list of changes. +use crate::baseline_store::{self as store, BaselineRow, Choice, ProjectRow, UserBaselines}; +use openxer_interchange::baseline as xb; +use openxer_interchange::baseline_update as xu; +use openxer_xer::workspace::{Workspace, KEY}; +use openxer_xer::{Document, ProjectData}; +use rusqlite::{params, Connection, OptionalExtension}; + +/// Convert: the picked project is open. +pub const OPEN_REFUSED: &str = + "A project that is open cannot become a baseline. Close the project first, then try again."; +/// Convert: the picked project has baselines of its own. +pub const HAS_BASELINES_REFUSED: &str = + "This project has baselines of its own, so it cannot become a baseline."; +/// Delete of an assigned baseline. +pub const DELETE_ASSIGNED: &str = "The selected baseline is in use as the project baseline or as a primary, secondary or tertiary baseline. A baseline in use cannot be deleted."; +/// Restore of an assigned baseline. +pub const RESTORE_ASSIGNED: &str = "The selected baseline is in use as the project baseline or as a primary, secondary or tertiary baseline. A baseline in use cannot be restored."; +pub const DELETE_CONFIRM: &str = "Delete the selected baseline?"; +pub const DELETED: &str = "The baseline was deleted."; +pub const RESTORE_CONFIRM: &str = + "Detach the selected baseline from the current project and make it a separate project?"; +pub const REVERT_CONFIRM: &str = "Replace the data of the current project with the selected baseline? The project keeps its ID, name and baselines, and the baseline stays in the list."; + +/// Why a command did not run: `Refused` is a rule the user meets (shown +/// with OK only), `Failed` something that went wrong. +#[derive(Clone, Debug, PartialEq, Eq)] +pub enum Error { + Refused(String), + Failed(String), +} + +impl Error { + pub fn message(&self) -> &str { + match self { + Error::Refused(m) | Error::Failed(m) => m, + } + } +} + +impl std::fmt::Display for Error { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + f.write_str(self.message()) + } +} + +impl From for Error { + fn from(e: String) -> Self { + Error::Failed(e) + } +} + +impl From<&str> for Error { + fn from(e: &str) -> Self { + Error::Failed(e.into()) + } +} + +fn refused(message: impl Into) -> Error { + Error::Refused(message.into()) +} + +pub type Rows = Vec<(i64, Option, Option)>; +pub type Projects = Vec<(i64, Option, Option)>; + +/// One baseline command's effect on the workspace (`None` is absent). +#[derive(Clone, Debug, Default)] +pub struct Change { + /// The workspace project whose baselines change. + pub parent: i64, + pub rows: Rows, + pub projects: Projects, + pub users: Option<(UserBaselines, UserBaselines)>, + /// The parent's `sum_base_proj_id` before and after. [`apply`] leaves + /// it to the caller, which holds the parent's document. + pub project_baseline: Option<(String, String)>, + /// The workspace EPS and portfolio text before and after. + pub workspace: Option<(String, String)>, + /// The baseline row (or, for Restore, the workspace project) made. + pub made: Option, +} + +impl Change { + pub fn is_empty(&self) -> bool { + self.rows.is_empty() + && self.projects.is_empty() + && self.users.is_none() + && self.project_baseline.is_none() + && self.workspace.is_none() + } +} + +/// The project whose baselines a command works on, as it is now. +pub struct Owner<'a> { + /// Its workspace row. + pub id: i64, + /// Its document, with the workspace dictionary (calendars, resources, + /// baseline types) added back. + pub doc: &'a Document, + pub pid: i64, + /// Project ID and name. + pub project_id: &'a str, + pub name: &'a str, + pub windows_encoding: bool, +} + +impl Owner<'_> { + /// The project baseline field (`sum_base_proj_id`). + pub fn project_baseline(&self) -> String { + xb::project_value(self.doc, self.pid, "sum_base_proj_id") + } +} + +/// The time a baseline is taken or updated, as the file stores dates. +pub fn now_stamp() -> String { + chrono::Local::now().format("%Y-%m-%d %H:%M").to_string() +} + +/// A baseline's document. +pub fn parse(row: &BaselineRow) -> Result { + let mut doc = Document::parse(&row.xer)?; + doc.windows_encoding = row.windows_encoding; + Ok(doc) +} + +/// The next free row id of `table`. +pub fn next_id(c: &Connection, table: &str) -> Result { + c.query_row( + &format!("SELECT COALESCE(MAX(id),0)+1 FROM {table}"), + [], + |r| r.get(0), + ) + .map_err(|e| e.to_string()) +} + +/// A baseline project id unused by the owner's file, its baselines and the +/// id its project baseline field names. +pub fn next_key(doc: &Document, pid: i64, rows: &[BaselineRow]) -> i64 { + doc.projects() + .into_iter() + .map(|(id, _)| id) + .chain(rows.iter().map(|r| r.project_key)) + .chain([ + xb::project_value(doc, pid, "sum_base_proj_id") + .trim() + .parse() + .unwrap_or(0), + pid, + ]) + .max() + .unwrap_or(0) + + 1 +} + +/// The lowest n for which no baseline of the project has the ID +/// " - B". +pub fn next_number(project_id: &str, rows: &[BaselineRow]) -> usize { + (1..) + .find(|n| { + let id = format!("{project_id} - B{n}"); + !rows.iter().any(|r| r.short_name == id) + }) + .expect("a free number") +} + +/// What a baseline is assigned as: "project", "primary", "secondary", +/// "tertiary" (empty when it is free). +pub fn assigned_roles(c: &Connection, row: &BaselineRow, project_field: &str) -> Vec<&'static str> { + let mut out = vec![]; + if project_field.trim() == row.project_key.to_string() { + out.push("project"); + } + let users = store::user_baselines(c, row.parent); + for (k, role) in ["primary", "secondary", "tertiary"].into_iter().enumerate() { + if users.0[k] == Choice::Baseline(row.id) { + out.push(role); + } + } + out +} + +/// The baseline type stored as `stored` (an id; an older workspace kept the +/// name) as the id of a row of the document's BASETYPE table, or "". +pub fn type_id(doc: &Document, stored: &str) -> String { + let stored = stored.trim(); + if stored.is_empty() { + return String::new(); + } + let Some(t) = doc.table("BASETYPE") else { + return String::new(); + }; + let id = |r: &[String]| t.value(r, "base_type_id").trim().to_string(); + t.rows + .iter() + .find(|r| id(r) == stored) + .or_else(|| t.rows.iter().find(|r| t.value(r, "base_type") == stored)) + .map_or(String::new(), |r| id(r)) +} + +/// The Baseline Type choices: "" first, then the types by name, as +/// (id, name). +pub fn type_choices(doc: &Document) -> Vec<(String, String)> { + let mut types: Vec<(String, String)> = doc + .table("BASETYPE") + .map(|t| { + t.rows + .iter() + .map(|r| { + ( + t.value(r, "base_type_id").trim().to_string(), + t.value(r, "base_type").to_string(), + ) + }) + .collect() + }) + .unwrap_or_default(); + types.sort_by(|a, b| { + a.1.to_lowercase() + .cmp(&b.1.to_lowercase()) + .then(a.1.cmp(&b.1)) + }); + let mut out = vec![(String::new(), "".to_string())]; + out.extend(types); + out +} + +/// A type named by id or name ("" or "" is no type). +fn type_ref(doc: &Document, text: &str) -> Result { + let text = text.trim(); + if text.is_empty() || text.eq_ignore_ascii_case("") || text.eq_ignore_ascii_case("none") { + return Ok(String::new()); + } + type_choices(doc) + .into_iter() + .skip(1) + .find(|(id, name)| id == text || name.eq_ignore_ascii_case(text)) + .map(|(id, _)| id) + .ok_or_else(|| refused(format!("No baseline type is named {text:?}."))) +} + +fn clean(s: &str) -> String { + s.trim().chars().filter(|c| !c.is_control()).collect() +} + +fn get(c: &Connection, id: i64) -> Result { + store::get(c, id)?.ok_or_else(|| Error::Failed("The baseline no longer exists".into())) +} + +/// A stored workspace project's document as the app opens it: on a +/// workspace with a shared dictionary its calendars, resources and codes +/// are added back. +pub fn source_document(c: &Connection, id: i64) -> Result { + let row = store::project_row(c, id)?.ok_or("The project no longer exists")?; + let mut doc = Document::parse(&row.xer)?; + doc.windows_encoding = row.windows_encoding; + if crate::workspace_db::schema(c)? >= crate::workspace_db::DICTIONARY_SCHEMA { + crate::workspace_db::hydrate(c, &mut doc, Some(id))?; + } + Ok(doc) +} + +/// Maintain Baselines > Add > Save a copy of the current project. +pub fn add_copy(c: &Connection, o: &Owner, stamp: &str) -> Result { + store::ensure(c)?; + let rows = store::list(c, o.id)?; + let key = next_key(o.doc, o.pid, &rows); + let n = next_number(o.project_id, &rows); + let short = format!("{} - B{n}", o.project_id); + let name = format!("{} - B{n}", o.name); + let copy = xb::copy_as_baseline(o.doc, o.pid, key, &short, &name, stamp); + let info = xb::baseline_info(©, key); + let id = next_id(c, "baselines")?; + let row = BaselineRow { + id, + parent: o.id, + project_key: key, + short_name: short, + name, + baseline_type: String::new(), + data_date: info.data_date, + added: stamp.into(), + updated: stamp.into(), + xer: copy.text(), + windows_encoding: o.windows_encoding, + import_batch: None, + }; + Ok(Change { + parent: o.id, + rows: vec![(id, None, Some(row))], + made: Some(id), + ..Default::default() + }) +} + +/// Maintain Baselines > Add > Convert another project: workspace project +/// `source` (its document `source_doc` as [`source_document`] reads it) +/// becomes a baseline of the owner and leaves the project lists. `open` are +/// the workspace ids of the open projects, which are refused. +pub fn convert( + c: &Connection, + o: &Owner, + source: i64, + source_doc: &Document, + open: &[i64], + stamp: &str, +) -> Result { + if source == o.id || open.contains(&source) { + return Err(refused(OPEN_REFUSED)); + } + store::ensure(c)?; + if store::count(c, source) > 0 { + return Err(refused(HAS_BASELINES_REFUSED)); + } + let src = store::project_row(c, source)?.ok_or("The project no longer exists")?; + let rows = store::list(c, o.id)?; + let key = next_key(o.doc, o.pid, &rows); + let mut copy = xb::extract_project(source_doc, src.project_key); + let key = xb::renumber_project(&mut copy, src.project_key, &[o.doc], Some(key)); + // It keeps its own ID and name. + let short = xb::project_value(©, key, "proj_short_name"); + let name = xb::project_name(©, key); + xb::mark_baseline(&mut copy, key, o.pid, &short, &name, stamp); + // Never updated as a baseline yet. + xb::set_project_value(&mut copy, key, "last_baseline_update_date", ""); + ProjectData::from_document(copy.clone(), key, String::new())?; + let info = xb::baseline_info(©, key); + let id = next_id(c, "baselines")?; + let row = BaselineRow { + id, + parent: o.id, + project_key: key, + short_name: short, + name, + baseline_type: String::new(), + data_date: info.data_date, + added: stamp.into(), + updated: String::new(), + xer: copy.text(), + windows_encoding: src.windows_encoding, + import_batch: None, + }; + Ok(Change { + parent: o.id, + rows: vec![(id, None, Some(row))], + projects: vec![(source, Some(src), None)], + made: Some(id), + ..Default::default() + }) +} + +/// Maintain Baselines > Copy: another baseline of the same project with the +/// next number, the source's data, data date, type and last update date. +pub fn copy(c: &Connection, o: &Owner, id: i64, stamp: &str) -> Result { + store::ensure(c)?; + let src = get(c, id)?; + if src.parent != o.id { + return Err("The baseline belongs to another project".into()); + } + let rows = store::list(c, o.id)?; + let key = next_key(o.doc, o.pid, &rows); + let bl = parse(&src)?; + let mut doc = xb::extract_project(&bl, src.project_key); + let key = xb::renumber_project(&mut doc, src.project_key, &[o.doc, &bl], Some(key)); + let n = next_number(o.project_id, &rows); + let short = format!("{} - B{n}", o.project_id); + let name = format!("{} - B{n}", o.name); + xb::mark_baseline(&mut doc, key, o.pid, &short, &name, stamp); + xb::set_project_value(&mut doc, key, "last_baseline_update_date", &src.updated); + let new = next_id(c, "baselines")?; + let row = BaselineRow { + id: new, + parent: o.id, + project_key: key, + short_name: short, + name, + baseline_type: src.baseline_type.clone(), + data_date: src.data_date.clone(), + added: stamp.into(), + updated: src.updated.clone(), + xer: doc.text(), + windows_encoding: src.windows_encoding, + import_batch: None, + }; + Ok(Change { + parent: o.id, + rows: vec![(new, None, Some(row))], + made: Some(new), + ..Default::default() + }) +} + +/// Maintain Baselines > Delete. A baseline in use is refused. +pub fn delete(c: &Connection, o: &Owner, id: i64) -> Result { + store::ensure(c)?; + let row = get(c, id)?; + if !assigned_roles(c, &row, &o.project_baseline()).is_empty() { + return Err(refused(DELETE_ASSIGNED)); + } + Ok(Change { + parent: row.parent, + rows: vec![(id, Some(row), None)], + ..Default::default() + }) +} + +/// The workspace's EPS text as stored ("" when it has none yet). +fn workspace_text(c: &Connection) -> Result { + let has: bool = c + .query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name='preferences'", + [], + |_| Ok(()), + ) + .optional() + .map_err(|e| e.to_string())? + .is_some(); + if !has { + return Ok(String::new()); + } + c.query_row("SELECT value FROM preferences WHERE key=?1", [KEY], |r| { + r.get::<_, String>(0) + }) + .optional() + .map(Option::unwrap_or_default) + .map_err(|e| e.to_string()) +} + +/// Maintain Baselines > Restore: the baseline leaves the list and becomes a +/// separate workspace project with its own ID and name, filed in the +/// owner's EPS folder. A baseline in use is refused, and so is one whose ID +/// another workspace project already has. +pub fn restore(c: &Connection, o: &Owner, id: i64) -> Result { + store::ensure(c)?; + let row = get(c, id)?; + if !assigned_roles(c, &row, &o.project_baseline()).is_empty() { + return Err(refused(RESTORE_ASSIGNED)); + } + let mut doc = parse(&row)?; + xb::set_project_value(&mut doc, row.project_key, "orig_proj_id", ""); + // The new project gets an internal number of its own: the baseline's + // number is unique only among its owner's baselines. + let key = store::next_project_number(c, &openxer_xer::workspace::numbering::in_document(&doc))?; + openxer_xer::workspace::numbering::renumber(&mut doc, row.project_key, key); + let p = ProjectData::from_document(doc.clone(), key, String::new())?; + let title = p.model.project.name.clone(); + let taken = c + .query_row( + "SELECT 1 FROM projects WHERE title=?1", + [&title], + |_| Ok(()), + ) + .optional() + .map_err(|e| e.to_string())? + .is_some(); + if taken { + return Err(refused(format!( + "A project with the ID {title} already exists. Give the baseline another Baseline ID first." + ))); + } + let new = next_id(c, "projects")?; + let project = ProjectRow { + id: new, + source_name: store::unique_source(c, &title, key), + project_key: key, + title, + xer: doc.text(), + windows_encoding: row.windows_encoding, + level_resources: false, + }; + let before = workspace_text(c)?; + let mut ws = Workspace::from_text(&before); + let workspace = if ws.eps().is_empty() { + None + } else { + let node = ws.node_of(Some(o.id)); + ws.place(new, node)?; + Some((before, ws.to_text())) + }; + Ok(Change { + parent: row.parent, + rows: vec![(id, Some(row), None)], + projects: vec![(new, None, Some(project))], + workspace, + made: Some(new), + ..Default::default() + }) +} + +/// The Maintain Baselines fields under the list: Baseline ID, Baseline Name +/// and Baseline Type (`None` leaves a field as it is). An unchanged +/// baseline gives an empty change. +pub fn set( + c: &Connection, + o: &Owner, + id: i64, + baseline_id: Option<&str>, + name: Option<&str>, + kind: Option<&str>, +) -> Result { + store::ensure(c)?; + let before = get(c, id)?; + let short = baseline_id.map_or_else(|| before.short_name.clone(), clean); + let name = name.map_or_else(|| before.name.clone(), clean); + let kind = match kind { + Some(t) => type_ref(o.doc, t)?, + None => type_id(o.doc, &before.baseline_type), + }; + if short == before.short_name + && name == before.name + && kind == type_id(o.doc, &before.baseline_type) + { + return Ok(Change { + parent: before.parent, + ..Default::default() + }); + } + if short.is_empty() { + return Err(refused("A baseline needs a Baseline ID.")); + } + if name.is_empty() { + return Err(refused("A baseline needs a name.")); + } + let mut doc = parse(&before)?; + xb::set_project_names(&mut doc, before.project_key, &short, &name); + let after = BaselineRow { + short_name: short, + name, + baseline_type: kind, + xer: doc.text(), + ..before.clone() + }; + Ok(Change { + parent: before.parent, + rows: vec![(id, Some(before), Some(after))], + ..Default::default() + }) +} + +/// The owner's baseline choices: project baseline, then the user baselines. +pub fn choices(c: &Connection, o: &Owner) -> (Choice, UserBaselines) { + let field = o.project_baseline(); + let project = store::list(c, o.id) + .unwrap_or_default() + .iter() + .find(|r| field.trim() == r.project_key.to_string()) + .map_or(Choice::Current, |r| Choice::Baseline(r.id)); + (project, store::user_baselines(c, o.id)) +} + +/// Assign Baselines > OK. `project` `None` leaves the project baseline as it +/// is; `Choice::None` there means the current project. +pub fn assign( + c: &Connection, + o: &Owner, + project: Option, + users: UserBaselines, +) -> Result { + store::ensure(c)?; + let rows = store::list(c, o.id)?; + let known = |choice: Choice| match choice { + Choice::Baseline(id) => rows.iter().any(|r| r.id == id), + _ => true, + }; + if !users.0.iter().all(|u| known(*u)) || !project.is_none_or(known) { + return Err("The baseline no longer exists".into()); + } + let (old_project, old_users) = choices(c, o); + let mut change = Change { + parent: o.id, + ..Default::default() + }; + if users != old_users { + change.users = Some((old_users, users)); + } + let project = project.map(|p| match p { + Choice::None => Choice::Current, + p => p, + }); + if let Some(choice) = project.filter(|p| *p != old_project) { + let value = match choice { + Choice::Baseline(id) => rows + .iter() + .find(|r| r.id == id) + .map(|r| r.project_key.to_string()) + .unwrap_or_default(), + _ => String::new(), + }; + change.project_baseline = Some((o.project_baseline(), value)); + } + Ok(change) +} + +/// Revert Project to Baseline: the owner's document with its own project +/// rows replaced by baseline `row`'s. The project keeps its id, ID, name, +/// project baseline and dates added; the baseline is not changed. +pub fn reverted(o: &Owner, row: &BaselineRow) -> Result { + let bl = parse(row)?; + let current = o.doc; + let pid = o.pid; + let mut out = current.clone(); + xb::remove_project_rows(&mut out, pid); + let mut copy = xb::extract_project(&bl, row.project_key); + xb::renumber_project(&mut copy, row.project_key, &[current], Some(pid)); + xb::set_project_value(&mut copy, pid, "orig_proj_id", ""); + xb::set_project_names(&mut copy, pid, o.project_id, o.name); + for field in [ + "sum_base_proj_id", + "add_date", + "last_baseline_update_date", + "base_type_id", + ] { + let v = xb::project_value(current, pid, field); + xb::set_project_value(&mut copy, pid, field, &v); + } + xb::append_project(&mut out, ©, pid); + out.windows_encoding = current.windows_encoding; + Ok(out) +} + +/// Maintain Baselines > Update: baseline `id` of the owner updated from the +/// owner's document by `options`, for the activities in `only` (Activity +/// IDs, the filter) or all. Returns the change (the baseline row before and +/// after, its Last Update Date set to `stamp`) and the list of changes it +/// holds. The Preview window and a dry run show that list; Update stores +/// the change. An assigned baseline may be updated. +pub fn update( + c: &Connection, + o: &Owner, + id: i64, + options: &xu::UpdateOptions, + only: Option<&std::collections::BTreeSet>, + stamp: &str, +) -> Result<(Change, xu::Preview), Error> { + store::ensure(c)?; + let before = get(c, id)?; + if before.parent != o.id { + return Err("The baseline belongs to another project".into()); + } + let doc = parse(&before)?; + let key = before.project_key; + let (mut merged, preview) = xu::update_baseline(&doc, key, o.doc, o.pid, options, only)?; + xb::mark_baseline( + &mut merged, + key, + o.pid, + &before.short_name, + &before.name, + &before.added, + ); + xb::set_project_value(&mut merged, key, "last_baseline_update_date", stamp); + let check = ProjectData::from_document(merged.clone(), key, String::new()) + .map_err(|e| format!("The updated baseline would not load: {e}"))?; + check + .model + .validate() + .map_err(|e| format!("The updated baseline is not valid: {e}"))?; + let info = xb::baseline_info(&merged, key); + let after = BaselineRow { + xer: merged.text(), + updated: stamp.into(), + data_date: info.data_date, + ..before.clone() + }; + Ok(( + Change { + parent: before.parent, + rows: vec![(id, Some(before), Some(after))], + ..Default::default() + }, + preview, + )) +} + +/// The text of the update log: when, which baseline from which project, +/// the options that were on, and every change. +pub fn update_log( + o: &Owner, + row: &BaselineRow, + options: &xu::UpdateOptions, + preview: &xu::Preview, + stamp: &str, +) -> String { + let (added, deleted, updated) = preview.counts(); + let mut lines = vec![ + "Update Baseline log".to_string(), + format!("Run: {stamp}"), + format!("Project: {} {}", o.project_id, o.name), + format!("Baseline: {} {}", row.short_name, row.name), + format!( + "Activities: {added} added, {deleted} deleted, {updated} updated; WBS elements changed: {}; project changed: {}", + preview.wbs.len(), + if preview.project.is_empty() { "no" } else { "yes" } + ), + String::new(), + "Options:".to_string(), + ]; + if let Ok(serde_json::Value::Object(map)) = serde_json::to_value(options.effective()) { + for (k, v) in map { + if k != "log_path" { + lines.push(format!(" {k}: {v}")); + } + } + } + lines.push(String::new()); + lines.push("Changes:".to_string()); + lines.extend(preview.lines()); + lines.push(String::new()); + lines.join("\r\n") +} + +/// Write one side of a change (`forward`: the state after) to the +/// workspace: projects, baselines, user baselines and the EPS text. The +/// project baseline field is the caller's, which holds the document. +pub fn apply(c: &Connection, ch: &Change, forward: bool) -> Result<(), String> { + for (id, before, after) in &ch.projects { + let image = if forward { after } else { before }; + store::put_project_row(c, *id, image.as_ref())?; + } + for (id, before, after) in &ch.rows { + match if forward { after } else { before } { + Some(row) => { + store::put(c, row)?; + } + None => store::delete(c, *id)?, + } + } + if let Some((before, after)) = ch.users { + // A deleted project takes its user baseline choices with it (the + // row cascades), so there is nothing to write then. + if store::project_row(c, ch.parent)?.is_some() { + store::set_user_baselines(c, ch.parent, if forward { after } else { before })?; + } + } + if let Some((before, after)) = &ch.workspace { + let text = if forward { after } else { before }; + c.execute( + "CREATE TABLE IF NOT EXISTS preferences(key TEXT PRIMARY KEY,value TEXT NOT NULL)", + [], + ) + .map_err(|e| e.to_string())?; + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO UPDATE SET value=excluded.value", + params![KEY, text], + ) + .map_err(|e| e.to_string())?; + } + Ok(()) +} diff --git a/automation/src/baseline_store.rs b/automation/src/baseline_store.rs new file mode 100644 index 0000000..749cde5 --- /dev/null +++ b/automation/src/baseline_store.rs @@ -0,0 +1,333 @@ +//! Workspace storage of baselines. A baseline is a frozen copy of a project, +//! kept as its own row in the `baselines` table and linked to its parent +//! workspace project, so it never shows in project lists. Deleting the parent +//! deletes its baselines. The user baseline choices (Primary, Secondary, +//! Tertiary) live in `baseline_assign`; the project baseline is the parent's +//! own `sum_base_proj_id`, as in the file. +use rusqlite::{params, Connection, OptionalExtension}; + +const SCHEMA: &str = " +CREATE TABLE IF NOT EXISTS baselines( + id INTEGER PRIMARY KEY, + parent INTEGER NOT NULL REFERENCES projects(id) ON DELETE CASCADE, + project_key INTEGER NOT NULL, + short_name TEXT NOT NULL, + name TEXT NOT NULL, + baseline_type TEXT NOT NULL DEFAULT '', + data_date TEXT NOT NULL DEFAULT '', + added_at TEXT NOT NULL DEFAULT '', + updated_at TEXT NOT NULL DEFAULT '', + xer_content TEXT NOT NULL, + source_windows_encoding INTEGER NOT NULL DEFAULT 0, + import_batch INTEGER); +CREATE INDEX IF NOT EXISTS baselines_parent ON baselines(parent); +CREATE TABLE IF NOT EXISTS baseline_assign( + parent INTEGER PRIMARY KEY REFERENCES projects(id) ON DELETE CASCADE, + primary_bl TEXT NOT NULL DEFAULT 'current', + secondary_bl TEXT NOT NULL DEFAULT '', + tertiary_bl TEXT NOT NULL DEFAULT ''); +DELETE FROM baselines WHERE parent NOT IN (SELECT id FROM projects); +DELETE FROM baseline_assign WHERE parent NOT IN (SELECT id FROM projects);"; + +/// Create the baseline tables and drop rows whose parent is gone (a tool that +/// opened the workspace without foreign keys may have removed it). +pub fn ensure(c: &Connection) -> Result<(), String> { + c.execute_batch(SCHEMA).map_err(|e| e.to_string()) +} + +/// One stored baseline. `xer` is empty in listings. +#[derive(Clone, Debug, Default, PartialEq)] +pub struct BaselineRow { + pub id: i64, + pub parent: i64, + /// The baseline's project id inside its document. + pub project_key: i64, + /// Baseline ID (the copy's project ID). + pub short_name: String, + pub name: String, + pub baseline_type: String, + /// `YYYY-MM-DD HH:MM`, as the file stores dates. + pub data_date: String, + pub added: String, + pub updated: String, + pub xer: String, + pub windows_encoding: bool, + pub import_batch: Option, +} + +const COLUMNS: &str = "id,parent,project_key,short_name,name,baseline_type,data_date,added_at,updated_at,xer_content,source_windows_encoding,import_batch"; + +fn row(r: &rusqlite::Row) -> rusqlite::Result { + Ok(BaselineRow { + id: r.get(0)?, + parent: r.get(1)?, + project_key: r.get(2)?, + short_name: r.get(3)?, + name: r.get(4)?, + baseline_type: r.get(5)?, + data_date: r.get(6)?, + added: r.get(7)?, + updated: r.get(8)?, + xer: r.get(9)?, + windows_encoding: r.get(10)?, + import_batch: r.get(11)?, + }) +} + +/// Baselines of a workspace project in the order they were added, without +/// their content. +pub fn list(c: &Connection, parent: i64) -> Result, String> { + let sql = format!( + "SELECT {} FROM baselines WHERE parent=?1 ORDER BY id", + COLUMNS.replace("xer_content", "''") + ); + let mut stmt = c.prepare(&sql).map_err(|e| e.to_string())?; + let rows = stmt.query_map([parent], row).map_err(|e| e.to_string())?; + rows.collect::, _>>() + .map_err(|e| e.to_string()) +} + +pub fn count(c: &Connection, parent: i64) -> usize { + c.query_row( + "SELECT COUNT(*) FROM baselines WHERE parent=?1", + [parent], + |r| r.get::<_, i64>(0), + ) + .map_or(0, |n| n as usize) +} + +/// One baseline with its content. +pub fn get(c: &Connection, id: i64) -> Result, String> { + c.query_row( + &format!("SELECT {COLUMNS} FROM baselines WHERE id=?1"), + [id], + row, + ) + .optional() + .map_err(|e| e.to_string()) +} + +/// Write a baseline: insert when `row.id` is 0 (a new id) or absent, else +/// replace it. Returns its id. +pub fn put(c: &Connection, b: &BaselineRow) -> Result { + let id = (b.id > 0).then_some(b.id); + c.execute( + &format!("INSERT OR REPLACE INTO baselines({COLUMNS}) VALUES(?1,?2,?3,?4,?5,?6,?7,?8,?9,?10,?11,?12)"), + params![ + id, + b.parent, + b.project_key, + b.short_name, + b.name, + b.baseline_type, + b.data_date, + b.added, + b.updated, + b.xer, + b.windows_encoding, + b.import_batch + ], + ) + .map_err(|e| e.to_string())?; + Ok(id.unwrap_or_else(|| c.last_insert_rowid())) +} + +pub fn delete(c: &Connection, id: i64) -> Result<(), String> { + c.execute("DELETE FROM baselines WHERE id=?1", [id]) + .map(|_| ()) + .map_err(|e| e.to_string()) +} + +/// Remove the baselines an import added (Undo Last Import). +pub fn delete_import(c: &Connection, batch: i64) -> Result<(), String> { + c.execute("DELETE FROM baselines WHERE import_batch=?1", [batch]) + .map(|_| ()) + .map_err(|e| e.to_string()) +} + +/// What a user baseline slot shows. +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Hash)] +pub enum Choice { + #[default] + None, + /// The open project stands in for a baseline (its planned dates). + Current, + /// A stored baseline (row id). + Baseline(i64), +} +impl Choice { + fn key(self) -> String { + match self { + Choice::None => String::new(), + Choice::Current => "current".into(), + Choice::Baseline(id) => id.to_string(), + } + } + fn from_key(s: &str) -> Self { + match s.trim() { + "" => Choice::None, + "current" => Choice::Current, + s => s.parse().map_or(Choice::None, Choice::Baseline), + } + } +} + +/// Primary, Secondary and Tertiary user baselines of one project. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)] +pub struct UserBaselines(pub [Choice; 3]); +impl Default for UserBaselines { + /// A new project compares against itself as primary, nothing else. + fn default() -> Self { + UserBaselines([Choice::Current, Choice::None, Choice::None]) + } +} + +pub fn user_baselines(c: &Connection, parent: i64) -> UserBaselines { + c.query_row( + "SELECT primary_bl,secondary_bl,tertiary_bl FROM baseline_assign WHERE parent=?1", + [parent], + |r| { + Ok(UserBaselines([ + Choice::from_key(&r.get::<_, String>(0)?), + Choice::from_key(&r.get::<_, String>(1)?), + Choice::from_key(&r.get::<_, String>(2)?), + ])) + }, + ) + .unwrap_or_default() +} + +pub fn set_user_baselines(c: &Connection, parent: i64, u: UserBaselines) -> Result<(), String> { + c.execute( + "INSERT INTO baseline_assign(parent,primary_bl,secondary_bl,tertiary_bl) VALUES(?1,?2,?3,?4) \ + ON CONFLICT(parent) DO UPDATE SET primary_bl=excluded.primary_bl,secondary_bl=excluded.secondary_bl,tertiary_bl=excluded.tertiary_bl", + params![parent, u.0[0].key(), u.0[1].key(), u.0[2].key()], + ) + .map(|_| ()) + .map_err(|e| e.to_string()) +} + +/// The workspace row of a project. +pub fn parent_row(c: &Connection, source: &str, key: i64) -> Option { + c.query_row( + "SELECT id FROM projects WHERE source_name=?1 AND project_key=?2", + params![source, key], + |r| r.get(0), + ) + .optional() + .ok() + .flatten() +} + +/// A whole workspace project row, kept so converting a project into a +/// baseline (or copying a baseline out as a project) can be undone. +#[derive(Clone, Debug, PartialEq)] +pub struct ProjectRow { + pub id: i64, + pub source_name: String, + pub project_key: i64, + pub title: String, + pub xer: String, + pub windows_encoding: bool, + pub level_resources: bool, +} + +pub fn project_row(c: &Connection, id: i64) -> Result, String> { + c.query_row( + "SELECT id,source_name,project_key,title,xer_content,source_windows_encoding,level_resources FROM projects WHERE id=?1", + [id], + |r| { + Ok(ProjectRow { + id: r.get(0)?, + source_name: r.get(1)?, + project_key: r.get(2)?, + title: r.get(3)?, + xer: r.get(4)?, + windows_encoding: r.get(5)?, + level_resources: r.get(6)?, + }) + }, + ) + .optional() + .map_err(|e| e.to_string()) +} + +/// Put a project row back (insert with its id) or remove it. An existing row +/// is updated in place so its baselines stay attached. +pub fn put_project_row(c: &Connection, id: i64, p: Option<&ProjectRow>) -> Result<(), String> { + match p { + None => c + .execute("DELETE FROM projects WHERE id=?1", [id]) + .map(|_| ()), + Some(p) => { + let updated = c.execute( + "UPDATE projects SET source_name=?1,project_key=?2,title=?3,xer_content=?4,source_windows_encoding=?5,level_resources=?6,updated_at=CURRENT_TIMESTAMP WHERE id=?7", + params![p.source_name, p.project_key, p.title, p.xer, p.windows_encoding, p.level_resources, id], + ); + match updated { + Ok(0) => c + .execute( + "INSERT INTO projects(id,source_name,project_key,title,xer_content,source_windows_encoding,level_resources) VALUES(?1,?2,?3,?4,?5,?6,?7)", + params![id, p.source_name, p.project_key, p.title, p.xer, p.windows_encoding, p.level_resources], + ) + .map(|_| ()), + Ok(_) => Ok(()), + Err(e) => Err(e), + } + } + } + .map_err(|e| e.to_string()) +} + +/// An internal project number no workspace project, no stored baseline and +/// none of `also` uses, for a project the workspace makes (File > New, +/// `eps create-project`, a pasted copy, a restored baseline): +/// `openxer_xer::workspace::numbering::next` over all of them. +pub fn next_project_number(c: &Connection, also: &[i64]) -> Result { + let has = |table: &str| -> Result { + c.query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name=?1", + [table], + |_| Ok(()), + ) + .optional() + .map(|r| r.is_some()) + .map_err(|e| e.to_string()) + }; + let mut taken = also.to_vec(); + for table in ["projects", "baselines"] { + if !has(table)? { + continue; + } + let high: Option = c + .query_row(&format!("SELECT MAX(project_key) FROM {table}"), [], |r| { + r.get(0) + }) + .map_err(|e| e.to_string())?; + taken.extend(high); + } + Ok(openxer_xer::workspace::numbering::next(taken)) +} + +/// A source name no workspace project uses with `key`, for a project copied +/// out of a baseline. +pub fn unique_source(c: &Connection, base: &str, key: i64) -> String { + let taken = |name: &str| { + c.query_row( + "SELECT 1 FROM projects WHERE source_name=?1 AND project_key=?2", + params![name, key], + |_| Ok(()), + ) + .optional() + .ok() + .flatten() + .is_some() + }; + if !taken(base) { + return base.to_string(); + } + (2..) + .map(|n| format!("{base} ({n})")) + .find(|s| !taken(s)) + .expect("an unused name") +} diff --git a/automation/src/baselines.rs b/automation/src/baselines.rs new file mode 100644 index 0000000..86cd461 --- /dev/null +++ b/automation/src/baselines.rs @@ -0,0 +1,193 @@ +//! The stored baselines earned value and Monitor Thresholds read, from an +//! OpenXER workspace (read only): the project baseline (the project's +//! `sum_base_proj_id` names one of its stored baselines), the primary user +//! baseline (`baseline_assign`) and the workspace's earned value date choice. +//! An XER input, or a workspace project without them, stands in as its own +//! baseline, as the app does. +use crate::{AutomationError, Result}; +use openxer_xer::ev::{self, DateBasis, Loaded}; +use openxer_xer::{Document, ProjectData}; +use rusqlite::{Connection, OpenFlags, OptionalExtension}; +use std::path::Path; +use std::sync::Arc; + +/// What earned value reads besides the project itself. +#[derive(Clone, Debug, Default)] +pub struct EvContext { + pub project: Option>, + pub primary: Option>, + pub basis: DateBasis, + /// Baselines assigned but not readable; the project stands in for them. + pub warnings: Vec, +} + +impl EvContext { + pub fn calculator<'a>(&self, p: &'a ProjectData) -> ev::Calculator<'a> { + ev::Calculator::new(p, self.project.clone(), self.primary.clone(), self.basis) + } + /// The names of the baselines in use, for reports. + pub fn describe(&self) -> serde_json::Value { + let name = |b: &Option>| { + b.as_ref() + .map_or("Current Project".to_string(), |l| l.name.clone()) + }; + let mut out = serde_json::json!({"project_baseline":name(&self.project),"primary_baseline":name(&self.primary), + "earned_value_dates":self.basis.key()}); + if !self.warnings.is_empty() { + out["warnings"] = serde_json::json!(self.warnings); + } + out + } +} + +fn invalid(e: impl std::fmt::Display) -> AutomationError { + AutomationError::new("invalid_source", e.to_string()) +} + +fn has_table(c: &Connection, name: &str) -> bool { + c.query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name=?1", + [name], + |_| Ok(()), + ) + .optional() + .ok() + .flatten() + .is_some() +} + +/// The baselines of workspace row `workspace_id` in `input`; the default +/// (the project as its own baseline) for an XER input. +pub fn context(input: &Path, workspace_id: Option, p: &ProjectData) -> Result { + let Some(parent) = workspace_id else { + return Ok(EvContext::default()); + }; + let c = + Connection::open_with_flags(input, OpenFlags::SQLITE_OPEN_READ_ONLY).map_err(invalid)?; + let mut out = EvContext::default(); + if has_table(&c, "preferences") { + let basis: Option = c + .query_row( + "SELECT value FROM preferences WHERE key='earned_value_baseline_dates'", + [], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + out.basis = DateBasis::from_key(basis.as_deref().unwrap_or("")); + } + if !has_table(&c, "baselines") { + return Ok(out); + } + let origin = p.model.origin_serial; + // A stored baseline that cannot be read leaves the current project in + // its place, as the app does, and says so. + let load = |id: i64, warnings: &mut Vec| -> Result>> { + let Some((name, key, doc)) = read_row(&c, id, parent)? else { + return Ok(None); + }; + match ev::load(&name, doc, key, origin) { + Ok(loaded) => Ok(Some(Arc::new(loaded))), + Err(e) => { + warnings.push(format!( + "Baseline {name:?} could not be read ({e}); the current project stands in for it." + )); + Ok(None) + } + } + }; + let (project, primary) = assigned_ids(&c, parent, p)?; + if let Some(id) = project { + out.project = load(id, &mut out.warnings)?; + } + if let Some(id) = primary { + out.primary = load(id, &mut out.warnings)?; + } + Ok(out) +} + +/// The stored baseline row `id` of workspace row `parent`: its name, +/// project key and document. +fn read_row(c: &Connection, id: i64, parent: i64) -> Result> { + let row: Option<(String, i64, String, bool)> = c + .query_row( + "SELECT name,project_key,xer_content,source_windows_encoding FROM baselines WHERE id=?1 AND parent=?2", + [id, parent], + |r| Ok((r.get(0)?, r.get(1)?, r.get(2)?, r.get(3)?)), + ) + .optional() + .map_err(invalid)?; + let Some((name, key, text, legacy)) = row else { + return Ok(None); + }; + let mut doc = Document::parse(&text).map_err(invalid)?; + doc.windows_encoding = legacy; + Ok(Some((name, key, doc))) +} + +/// The ids of the project baseline (the project's `sum_base_proj_id` names +/// one of its stored baselines) and the primary user baseline. +fn assigned_ids( + c: &Connection, + parent: i64, + p: &ProjectData, +) -> Result<(Option, Option)> { + let mut project = None; + let field = openxer_interchange::baseline::project_value( + &p.document, + p.model.project.proj_id, + "sum_base_proj_id", + ); + if let Ok(key) = field.trim().parse::() { + project = c + .query_row( + "SELECT id FROM baselines WHERE parent=?1 AND project_key=?2 ORDER BY id", + [parent, key], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + } + let mut primary = None; + if has_table(c, "baseline_assign") { + let text: Option = c + .query_row( + "SELECT primary_bl FROM baseline_assign WHERE parent=?1", + [parent], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + primary = text.and_then(|s| s.trim().parse::().ok()); + } + Ok((project, primary)) +} + +/// A stored baseline of workspace row `workspace_id` read as a whole +/// project, for comparisons: `primary` false is the project baseline, true +/// the primary user baseline. None for an XER input or when none is +/// assigned. +pub fn stored_project( + input: &Path, + workspace_id: Option, + p: &ProjectData, + primary: bool, +) -> Result> { + let Some(parent) = workspace_id else { + return Ok(None); + }; + let c = + Connection::open_with_flags(input, OpenFlags::SQLITE_OPEN_READ_ONLY).map_err(invalid)?; + if !has_table(&c, "baselines") { + return Ok(None); + } + let (project, user) = assigned_ids(&c, parent, p)?; + let Some(id) = (if primary { user } else { project }) else { + return Ok(None); + }; + let Some((name, key, doc)) = read_row(&c, id, parent)? else { + return Ok(None); + }; + let project = ProjectData::from_document(doc, key, String::new()).map_err(invalid)?; + Ok(Some((name, project))) +} diff --git a/automation/src/chat_prompt.rs b/automation/src/chat_prompt.rs new file mode 100644 index 0000000..f274bf7 --- /dev/null +++ b/automation/src/chat_prompt.rs @@ -0,0 +1,199 @@ +//! The instructions every chat assistant gets, whichever agent or model +//! answers: one scheduling core, the user's own standing instructions when +//! there are any, and the mode. The methods for a build, an update, an +//! audit and the rest are playbooks the assistant loads when it needs one +//! (`openxer_playbook`), so they cost nothing up front. +use crate::chat_tools::ChatMode; +use std::path::{Path, PathBuf}; + +/// The core, sent with every chat. Kept short on purpose: every character +/// is paid for on every turn. +pub const CORE: &str = "You are a senior CPM scheduler working inside OpenXER on the user's open schedule. You build, update and analyze schedules for construction and industrial projects. +Work from the schedule, not from memory: read the data with the tools before you state a date, duration, float value or logic tie. Never invent an activity, a date or a number. If the data does not answer the question, say so. +Think like a scheduler: logic drives dates. Look at the driving path, float, constraints, calendars, open ends, lags and out-of-sequence progress before you explain why something moved. Separate what the schedule says from your opinion of it. +When asked to change the schedule, propose the smallest set of edits that does it, explain the effect on the finish date and float, and wait for approval. Never change logic or durations just to hit a date without saying that is what you are doing. +Write for people in the field: plain words, Activity IDs with names, dates as the project shows them. Be brief. For a build, an update, an audit or a schedule check, load the matching playbook first with openxer_playbook. +Use only the OpenXER tools; they read the open project, so never pass a file. In openxer_load pick fields, filters and sort, and keep pages small. When asked to filter, group, sort, show columns, select, zoom, trace paths, switch views, open a dialog or export, call openxer_ui directly. When a request is ambiguous or has choices, call openxer_ask_user with short options and wait."; + +/// The line for each mode. +pub fn mode_line(mode: ChatMode) -> &'static str { + match mode { + ChatMode::Ask => "Ask mode: read only. If asked to change the schedule, say the chat can be switched to Edit.", + ChatMode::Edit => "Edit mode: propose changes with one openxer_apply call. It changes nothing until the user approves it in OpenXER, so never say it is done.", + } +} + +/// The complete instructions of a chat: the core, the user's standing +/// instructions (from [`read_user_instructions`]) and the mode line. Both +/// hosted agents and an in-process provider send exactly this. +pub fn system_prompt(mode: ChatMode, user: Option<&str>) -> String { + system_prompt_with(mode, user, None) +} + +/// Most characters of per-project standing instructions sent. +pub const PROJECT_LIMIT: usize = 2000; + +/// The complete instructions of a chat with optional per-project rules: +/// core, global user standing instructions, project-specific instructions, +/// and the mode line. +pub fn system_prompt_with(mode: ChatMode, user: Option<&str>, project: Option<&str>) -> String { + let mut text = String::from(CORE); + if let Some(user) = user.map(str::trim).filter(|u| !u.is_empty()) { + text.push_str("\nThe user's standing instructions (follow them unless they conflict with the above):\n"); + text.push_str(user); + } + if let Some(project) = project.map(str::trim).filter(|p| !p.is_empty()) { + let trimmed: String = project.chars().take(PROJECT_LIMIT).collect(); + text.push_str("\nProject-specific rules for this schedule (follow them unless they conflict with the above):\n"); + text.push_str(&trimmed); + } + text.push('\n'); + text.push_str(mode_line(mode)); + text +} + +/// Decode UTF-8/UTF-16 text, strip HTML comments and normalize CRLF to LF. +pub(crate) fn clean_markdown(bytes: &[u8]) -> String { + without_comments(&decode(bytes)).replace("\r\n", "\n") +} + +/// The most characters of the user's file that are sent. +pub const USER_LIMIT: usize = 4000; + +/// The user's standing instructions as read. +#[derive(Clone, Debug, PartialEq, Eq)] +pub struct UserInstructions { + pub text: String, + /// The file was longer than [`USER_LIMIT`] and was cut there. + pub cut: bool, + pub path: PathBuf, +} + +/// The OpenXER data folder: where the workspace is (`OPENXER_DATA_DIR`, +/// else as `locate::default_workspace_in` decides for a program in +/// `exe_dir`). +pub fn data_folder_in( + exe_dir: Option<&Path>, + data_dir: Option, + local_appdata: Option, +) -> PathBuf { + let workspace = crate::locate::default_workspace_in(exe_dir, data_dir, local_appdata); + workspace + .parent() + .map(Path::to_path_buf) + .unwrap_or_else(|| PathBuf::from(".")) +} + +/// [`data_folder_in`] for this process. +pub fn data_folder() -> PathBuf { + let exe = std::env::current_exe().ok(); + data_folder_in( + exe.as_deref().and_then(Path::parent), + std::env::var_os(crate::locate::DATA_DIR_VAR), + std::env::var_os("LOCALAPPDATA"), + ) +} + +/// The user's instructions file in `data_folder`: `chat\AGENTS.md`. +pub fn instructions_path(data_folder: &Path) -> PathBuf { + data_folder.join("chat").join("AGENTS.md") +} + +/// Text in UTF-8 (with or without a byte order mark) or UTF-16 with its +/// mark; anything else is read as UTF-8 with bad bytes replaced. +fn decode(bytes: &[u8]) -> String { + let utf16 = |little: bool| { + let units: Vec = bytes[2..] + .as_chunks::<2>() + .0 + .iter() + .map(|c| { + if little { + u16::from_le_bytes([c[0], c[1]]) + } else { + u16::from_be_bytes([c[0], c[1]]) + } + }) + .collect(); + String::from_utf16_lossy(&units) + }; + match bytes { + [0xEF, 0xBB, 0xBF, rest @ ..] => String::from_utf8_lossy(rest).into_owned(), + [0xFF, 0xFE, ..] => utf16(true), + [0xFE, 0xFF, ..] => utf16(false), + _ => String::from_utf8_lossy(bytes).into_owned(), + } +} + +/// `text` without `` comments (an unclosed one runs to the end). +fn without_comments(text: &str) -> String { + let mut out = String::new(); + let mut rest = text; + while let Some(start) = rest.find("") { + Some(end) => rest = &rest[start + end + 3..], + None => { + rest = ""; + break; + } + } + } + out.push_str(rest); + out +} + +/// The user's standing instructions in the file at `path` (see +/// [`instructions_path`]), comments left out, at most [`USER_LIMIT`] +/// characters. `None` when the file is missing, unreadable or holds +/// nothing but comments and blank lines. +pub fn read_user_instructions(path: &Path) -> Option { + let bytes = std::fs::read(path).ok()?; + let text = without_comments(&decode(&bytes)).replace("\r\n", "\n"); + let text = text.trim(); + if text.is_empty() { + return None; + } + let cut = text.chars().count() > USER_LIMIT; + let text: String = text.chars().take(USER_LIMIT).collect(); + Some(UserInstructions { + text, + cut, + path: path.to_path_buf(), + }) +} + +/// What a new instructions file holds: only comments, so it sends nothing +/// until the user writes their own lines. +pub const STARTER: &str = " +"; + +/// Create the instructions file at `path` with [`STARTER`] if it does not +/// exist yet (an existing file is never changed); returns its path. +pub fn create_user_instructions(path: &Path) -> std::io::Result { + if let Some(dir) = path.parent() { + std::fs::create_dir_all(dir)?; + } + match std::fs::OpenOptions::new() + .write(true) + .create_new(true) + .open(path) + { + Ok(mut file) => { + use std::io::Write; + file.write_all(STARTER.as_bytes())?; + } + Err(e) if e.kind() == std::io::ErrorKind::AlreadyExists => {} + Err(e) => return Err(e), + } + Ok(path.to_path_buf()) +} diff --git a/automation/src/chat_tools.rs b/automation/src/chat_tools.rs new file mode 100644 index 0000000..4b38498 --- /dev/null +++ b/automation/src/chat_tools.rs @@ -0,0 +1,681 @@ +//! The small tool set of OpenXER's Chat window. +//! +//! An agent answering questions about the project open in the app needs a +//! handful of read tools and one way to propose edits, not the full MCP +//! catalog: every tool described costs tokens on every turn. This set is +//! built from the full tool definitions (`mcp::tool_definitions`) and runs +//! through the same command dispatcher, so the chat and every other +//! client behave the same; only the descriptions are shorter, the +//! arguments that name files are filled in from the snapshot, results are +//! kept under [`RESULT_LIMIT`], and `openxer_apply` only ever proposes: +//! it runs as a dry run on the snapshot and writes nothing. +//! +//! The same functions serve `openxer-cli mcp --toolset chat` and callers +//! that run the tools in-process ([`tools`], [`call`]). +use crate::{dispatch, mcp, parse_command, response, AutomationError}; +use openxer_xer::ProjectData; +use serde::Serialize; +use serde_json::{json, Value}; +use std::path::PathBuf; + +/// What the agent may do: Ask reads only; Edit may also propose changes. +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, Serialize)] +#[serde(rename_all = "snake_case")] +pub enum ChatMode { + #[default] + Ask, + Edit, +} + +impl ChatMode { + pub fn id(self) -> &'static str { + match self { + ChatMode::Ask => "ask", + ChatMode::Edit => "edit", + } + } + pub fn parse(text: &str) -> Option { + match text { + "ask" => Some(ChatMode::Ask), + "edit" => Some(ChatMode::Edit), + _ => None, + } + } +} + +/// Where the chat tools read from and what they may do. With a snapshot +/// the tools take no `input`; without one each call names its file. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct ChatContext { + pub snapshot: Option, + pub mode: ChatMode, + /// Optional folder of user-authored `.md` playbooks (`chat/playbooks`). + pub playbooks_dir: Option, + /// Optional JSONL queue file where `openxer_ui` writes live desktop UI + /// commands (filters, views, grouping, columns, dialogs, exports) for the + /// open OpenXER window to execute on the next frame. + pub ui_actions: Option, +} + +/// The live desktop UI control tool, available whenever `ui_actions` is set. +pub const UI_TOOL: &str = "openxer_ui"; + +/// One chat tool as an agent sees it. +#[derive(Clone, Debug, PartialEq, Serialize)] +pub struct ChatTool { + pub name: &'static str, + pub description: String, + pub input_schema: Value, +} + +/// One tool call's answer: the response envelope (`schema_version`, `ok`, +/// `result` or `error`) and its text, which is what the agent reads. +#[derive(Clone, Debug, PartialEq)] +pub struct ChatResult { + pub envelope: Value, + pub text: String, + pub is_error: bool, +} + +/// The longest tool result handed to an agent, in bytes of JSON text. A +/// larger one is refused with `result_too_large` and a hint to narrow it. +pub const RESULT_LIMIT: usize = 40_000; + +/// Activity fields `openxer_load` returns in the chat when none are named. +pub const DEFAULT_LOAD_FIELDS: &[&str] = &[ + "task_code", + "name", + "status", + "early_start", + "early_finish", + "total_float_minutes", +]; +/// Page size of `openxer_load` in the chat when none is given. +pub const DEFAULT_LOAD_LIMIT: usize = 50; + +/// The propose-only edit tool. +pub const APPLY_TOOL: &str = "openxer_apply"; + +/// Interactive clarifying-question tool shown as a card with clickable options +/// and an Other / context input in the Chat window. +pub const ASK_USER_TOOL: &str = "openxer_ask_user"; + +/// The chat tools: name, short description, whether only Edit mode has it. +const TOOLS: &[(&str, &str, bool)] = &[ + ("openxer_load", "Read the open project: its options, activities and relationships. Default fields task_code, name, status, early_start, early_finish, total_float_minutes; 50 rows a page (offset pages on). Narrow with fields, activities (Activity IDs), wbs (code path) or critical; then the relationships are those touching the matched activities. sort orders them (-early_finish: latest first). limit 0 gives counts only. Floats and durations are working minutes.", false), + ("openxer_records", "List the expense items, issues, risks or thresholds (kind), optionally of one activity.", false), + ("openxer_earned_value", "Earned value per activity and for the project (BAC, PV, EV, AC, SV, CV, SPI, CPI, ETC, EAC, VAC), by cost or labor_units; activity keeps one row.", false), + ("openxer_usage", "Budgeted, actual and remaining units (or costs) per day, week or month of one activity's or one resource's assignments.", false), + ("openxer_documents", "The project's work products and documents, optionally only those linked to an activity or a WBS path.", false), + ("openxer_read_document", "Read the text of a local text, Word or PDF document linked in the project (by reference number, title or document id from openxer_documents).", false), + ("openxer_curves", "List the available resource curves (file curves and OpenXER presets) with their 21 distribution points.", false), + ("openxer_check_schedule", "Check Schedule: the app's 15 health checks, one row each (count, of, result, target, pass, and the first five offenders). check (a row name) lists all its Activity IDs, up to limit.", false), + ("openxer_playbook", "Scheduling methods. No name: the list. With name: that playbook. Load the matching one first for a build, update, audit or health check.", false), + (APPLY_TOOL, "", true), +]; + +/// Operations the apply description spells out with their fields. +const SPELLED: &[&str] = &[ + "set_activity", + "add_activity", + "delete_activity", + "dissolve_activity", + "assign_resource", + "remove_assignment", + "set_assignment", + "set_project", + "add_wbs", + "add_step", + "set_step", + "update_progress", +]; + +/// Short descriptions of the arguments that need one in the chat. +const ARGUMENT_HELP: &[(&str, &str)] = &[ + ("fields", "Activity fields to return"), + ("activities", "Only these Activity IDs"), + ("wbs", "WBS code path, e.g. 1.2"), + ("critical", "Only critical activities"), + ("sort", "Field to order by; -field descending"), + ("limit", "Rows per page; 0 counts only"), + ( + "relationship_limit", + "Relationships per page; 0 counts only", + ), + ("activity", "Activity ID"), + ("resource", "Resource short name"), + ( + "changes", + "{\"format\":\"openxer-changes/1\",\"operations\":[{\"op\":...},...]}", + ), +]; + +/// Arguments the chat fills in or never takes. +const HIDDEN: &[&str] = &[ + "output", + "project_id", + "workspace_id", + "dry_run", + "changes_file", + // A proposal is applied as the user saw it: only the changes document + // (with its own recalculate) travels, so nothing outside it may change + // the preview. + "recalculate", +]; + +/// The `openxer_apply` description in the chat: proposal only, with the +/// common operations' fields taken from the single edit tools. +fn apply_description() -> String { + let fields = |op: &str| -> String { + let list: Vec = mcp::edit_tool_fields(op) + .iter() + .map(|(f, required)| { + if *required { + (*f).to_string() + } else { + format!("{f}?") + } + }) + .collect(); + format!("{op}({})", list.join(", ")) + }; + let spelled: Vec = SPELLED.iter().map(|op| fields(op)).collect(); + let others: Vec<&str> = crate::edit::OPERATIONS + .iter() + .copied() + .filter(|op| !SPELLED.contains(op) && !matches!(*op, "relationship" | "schedule")) + .collect(); + format!( + "Propose changes to the open project as an openxer-changes/1 batch. Nothing is changed: it returns the field diff, and the user approves it in OpenXER. Operations: {}, relationship(action add|edit|remove, predecessor, successor, kind FS|SS|FF|SF, lag_hours?), schedule(level_resources?). Also: {}. set_activity fields include activity_name, original_duration, remaining_duration, start, finish, actual_start, actual_finish, physical_percent_complete, calendar, wbs, primary_constraint, primary_constraint_date. Activities by Activity ID, resources by short name, WBS by code path; durations and lags in hours; dates YYYY-MM-DD HH:MM; null clears.", + spelled.join(", "), + others.join(", ") + ) +} + +/// `schema` without hidden arguments (and `input` when the snapshot fills +/// it), its property descriptions shortened or dropped. +fn chat_schema(schema: &Value, with_input: bool) -> Value { + let mut schema = schema.clone(); + if let Some(props) = schema["properties"].as_object_mut() { + props.retain(|k, _| !HIDDEN.contains(&k.as_str()) && (with_input || k != "input")); + for (key, prop) in props.iter_mut() { + if let Some(map) = prop.as_object_mut() { + map.remove("description"); + if let Some((_, help)) = ARGUMENT_HELP.iter().find(|(k, _)| k == key) { + map.insert("description".into(), json!(help)); + } + if key == "input" { + map.insert("description".into(), json!("XER or workspace path")); + } + } + } + } + if let Some(required) = schema["required"].as_array_mut() { + required.retain(|r| { + r.as_str() + .is_some_and(|r| !HIDDEN.contains(&r) && (with_input || r != "input")) + }); + } + if schema["required"].as_array().is_some_and(Vec::is_empty) { + schema.as_object_mut().map(|m| m.remove("required")); + } + schema +} + +/// The chat tools of `mode`. With `snapshot` true the snapshot names the +/// project and the tools take no `input`. +pub fn tools_for(mode: ChatMode, snapshot: bool) -> Vec { + let full = mcp::tool_definitions(); + TOOLS + .iter() + .filter(|(_, _, edit)| !*edit || mode == ChatMode::Edit) + .map(|(name, description, _)| { + let definition = full + .iter() + .find(|t| t["name"] == *name) + .expect("every chat tool is an MCP tool"); + ChatTool { + name, + description: if *name == APPLY_TOOL { + apply_description() + } else { + (*description).to_string() + }, + input_schema: chat_schema(&definition["inputSchema"], !snapshot), + } + }) + .collect() +} + +/// The live UI control tool definition (added whenever a desktop window is attached). +fn ui_tool() -> ChatTool { + ChatTool { + name: UI_TOOL, + description: "Control the live OpenXER app window directly (safe in Ask and Edit modes; changes view state only, never edits schedule data). Actions: filter (standard name like Critical/Longest Path/Negative Float/In Progress/Milestone, Check Schedule name like Logic/Out of Sequence Activities, saved filter name, activities list, or criteria [{column,op,value,high?}] with optional match_all/highlight/save_as), clear_filter, group_sort (group_by, to_level, sort_by [{column,descending?}], show_group_totals, show_summaries_only, hide_if_empty, expand_all, collapse_all), columns (add, remove, set, reset), select (activities list), critical_path (activity?, direction backward|forward|both|off, paths?, group?), view (main, top, bottom, detail_tab), gantt (zoom fit|in|out, relationships?, scroll_to?), open_dialog (dialog name), export (format xlsx|scurve|earned_hours|pdf|xer|xml, path?), undo, redo.".into(), + input_schema: json!({ + "type": "object", + "additionalProperties": false, + "required": ["action"], + "properties": { + "action": { + "type": "string", + "enum": [ + "filter", "clear_filter", "group_sort", "columns", + "select", "critical_path", "view", "gantt", + "open_dialog", "export", "undo", "redo" + ] + }, + "filter": {"type": "string", "description": "Standard, Check Schedule or saved filter name"}, + "activities": {"type": "array", "items": {"type": "string"}, "description": "Activity IDs to filter or select"}, + "criteria": { + "type": "array", + "items": { + "type": "object", + "required": ["column", "op"], + "properties": { + "column": {"type": "string"}, + "op": {"type": "string"}, + "value": {"type": "string"}, + "high": {"type": "string"} + } + }, + "description": "Custom filter rows (op: equals, not_equals, contains, not_contains, greater_than, less_than, between, is_under, ...)" + }, + "match_all": {"type": "boolean"}, + "highlight": {"type": "boolean"}, + "save_as": {"type": "string", "description": "Optional name to save a custom filter"}, + "group_by": {"type": "array", "items": {"type": "string"}}, + "to_level": {"type": "integer", "minimum": 1}, + "sort_by": { + "type": "array", + "items": { + "type": "object", + "required": ["column"], + "properties": { + "column": {"type": "string"}, + "descending": {"type": "boolean"} + } + } + }, + "show_group_totals": {"type": "boolean"}, + "show_summaries_only": {"type": "boolean"}, + "hide_if_empty": {"type": "boolean"}, + "expand_all": {"type": "boolean"}, + "collapse_all": {"type": "boolean"}, + "add": {"type": "array", "items": {"type": "string"}}, + "remove": {"type": "array", "items": {"type": "string"}}, + "set": {"type": "array", "items": {"type": "string"}}, + "reset": {"type": "boolean"}, + "activity": {"type": "string"}, + "direction": {"type": "string", "enum": ["backward", "forward", "both", "off"]}, + "paths": {"type": "integer", "minimum": 1, "maximum": 50}, + "group": {"type": "boolean"}, + "main": {"type": "string"}, + "top": {"type": "string"}, + "bottom": {"type": "string"}, + "detail_tab": {"type": "string"}, + "zoom": {"type": "string", "enum": ["fit", "in", "out"]}, + "relationships": {"type": "boolean"}, + "scroll_to": {"type": "string"}, + "dialog": {"type": "string"}, + "format": {"type": "string", "enum": ["xlsx", "scurve", "earned_hours", "pdf", "xer", "xml"]}, + "path": {"type": "string"} + } + }), + } +} + +fn ask_user_tool() -> ChatTool { + ChatTool { + name: ASK_USER_TOOL, + description: "Ask the user one or more clarifying questions in Chat with clickable suggested options and an optional free-text context box. Use this when a request is ambiguous or has meaningful choices, then stop and wait for the user's reply.".to_string(), + input_schema: json!({ + "type": "object", + "additionalProperties": false, + "required": ["questions"], + "properties": { + "title": { + "type": "string", + "description": "Optional short heading for the question card." + }, + "questions": { + "type": "array", + "minItems": 1, + "items": { + "type": "object", + "additionalProperties": false, + "required": ["question", "options"], + "properties": { + "question": { + "type": "string", + "description": "The question to ask the user." + }, + "multi_select": { + "type": "boolean", + "description": "Allow picking more than one option." + }, + "options": { + "type": "array", + "minItems": 1, + "items": { + "type": "object", + "additionalProperties": false, + "required": ["label"], + "properties": { + "label": { + "type": "string", + "description": "Short clickable option label." + }, + "description": { + "type": "string", + "description": "Optional brief explanation." + } + } + } + } + } + } + } + } + }), + } +} + +/// The chat tools of `context`. +pub fn tools(context: &ChatContext) -> Vec { + let mut list = tools_for(context.mode, context.snapshot.is_some()); + if let Some(dir) = &context.playbooks_dir { + let all = crate::playbooks::all_playbooks(Some(dir)); + let names: Vec = all.into_iter().map(|p| p.name).collect(); + if let Some(pb) = list.iter_mut().find(|t| t.name == "openxer_playbook") { + pb.input_schema["properties"]["name"]["enum"] = json!(names); + } + } + if context.ui_actions.is_some() { + list.push(ui_tool()); + list.push(ask_user_tool()); + } + list +} + +/// The tools as MCP `tools/list` entries. +pub fn tool_list(context: &ChatContext) -> Vec { + tools(context) + .into_iter() + .map(|t| { + json!({"name":t.name,"description":t.description,"inputSchema":t.input_schema, + "annotations":{"readOnlyHint":true,"destructiveHint":false,"openWorldHint":false}}) + }) + .collect() +} + +/// The MCP server instructions in the chat. +pub fn instructions(mode: ChatMode) -> String { + let mut text = String::from("OpenXER tools for the project open in the OpenXER app. Read it with openxer_load in small pages, choosing fields and filters. Name activities by Activity ID. Dates are project-local."); + if mode == ChatMode::Edit { + text.push_str(" To change the project call openxer_apply: it only proposes the batch, and the user approves it in OpenXER."); + } + text +} + +fn refuse(code: &str, message: impl Into) -> ChatResult { + finish(response(Err(AutomationError::new(code, message)))) +} + +fn finish(envelope: Value) -> ChatResult { + let text = envelope.to_string(); + let is_error = envelope["ok"] != true; + ChatResult { + envelope, + text, + is_error, + } +} + +/// Run chat tool `name` with `arguments` (a JSON object), as the chat MCP +/// server does. Never panics on bad input; every failure is an error +/// envelope. +pub fn call(context: &ChatContext, name: &str, arguments: Value) -> ChatResult { + call_limited(context, name, arguments, RESULT_LIMIT) +} + +/// [`call`] with another result size limit in bytes. +pub fn call_limited( + context: &ChatContext, + name: &str, + arguments: Value, + limit: usize, +) -> ChatResult { + let Some(tool) = tools(context).into_iter().find(|t| t.name == name) else { + return refuse( + "unknown_tool", + format!( + "{name} is not a chat tool{}", + if name == APPLY_TOOL { + " in Ask mode; switch the chat to Edit to propose changes" + } else { + "" + } + ), + ); + }; + let Value::Object(mut args) = arguments else { + return refuse("invalid_arguments", "Tool arguments must be an object"); + }; + if let Err(message) = mcp::validate_arguments( + &Value::Object(args.clone()), + &tool.input_schema, + "arguments", + ) { + return refuse("invalid_arguments", message); + } + // The snapshot is the input of every tool that reads the project. + let reads_project = mcp::tool_definitions() + .iter() + .find(|t| t["name"] == name) + .is_some_and(|t| t["inputSchema"]["properties"].get("input").is_some()); + if let Some(snapshot) = context.snapshot.as_ref().filter(|_| reads_project) { + args.insert("input".into(), json!(snapshot)); + } + if name == "openxer_load" { + args.entry("fields").or_insert(json!(DEFAULT_LOAD_FIELDS)); + args.entry("limit").or_insert(json!(DEFAULT_LOAD_LIMIT)); + args.entry("relationship_limit") + .or_insert(json!(DEFAULT_LOAD_LIMIT)); + } + if name == APPLY_TOOL { + // A proposal: always the dry run, never a file. + args.insert("dry_run".into(), json!(true)); + args.remove("output"); + } + if name == UI_TOOL || name == ASK_USER_TOOL { + let Some(queue) = context.ui_actions.as_ref() else { + return refuse( + "unavailable", + format!("{name} requires a live OpenXER desktop window"), + ); + }; + if let Some(parent) = queue.parent() { + let _ = std::fs::create_dir_all(parent); + } + let mut payload = Value::Object(args.clone()); + if name == ASK_USER_TOOL { + if let Some(obj) = payload.as_object_mut() { + obj.insert("action".into(), json!("ask_user")); + } + } + let line = format!("{payload}\n"); + use std::io::Write; + let write = std::fs::OpenOptions::new() + .create(true) + .append(true) + .open(queue) + .and_then(|mut f| f.write_all(line.as_bytes())); + if let Err(e) = write { + return refuse("io_error", format!("Cannot queue UI action: {e}")); + } + if name == ASK_USER_TOOL { + return finish(response(Ok(json!({ + "shown": true, + "note": "The question card is shown to the user in Chat with clickable options and an Other context box. End your turn and wait for the user's answer." + })))); + } + let action = payload["action"].as_str().unwrap_or(""); + return finish(response(Ok(json!({ + "applied": true, + "action": action, + "note": "Queued for the live OpenXER window to execute immediately." + })))); + } + if name == "openxer_playbook" { + let pb_name = args.get("name").and_then(Value::as_str); + let envelope = response(crate::playbooks::playbook_in( + pb_name, + context.playbooks_dir.as_deref(), + )); + let done = finish(envelope); + if done.text.len() > limit { + return refuse( + "result_too_large", + format!( + "The result is {} bytes, over the chat limit of {limit}.", + done.text.len() + ), + ); + } + return done; + } + let command = mcp::tool_command(name).expect("chat tools are MCP tools"); + args.insert("command".into(), json!(command)); + let mut envelope = response(parse_command(Value::Object(args)).and_then(dispatch)); + if name == APPLY_TOOL && envelope["ok"] == true { + let result = &mut envelope["result"]; + if let Some(map) = result.as_object_mut() { + map.remove("output"); + map.remove("dry_run"); + } + result["proposed"] = json!(true); + result["note"] = + json!("Not applied. The user reviews this diff and approves it in OpenXER."); + } + let done = finish(envelope); + if done.text.len() > limit { + return refuse( + "result_too_large", + format!( + "The result is {} bytes, over the chat limit of {limit}. Ask for less: fewer fields, a smaller limit, or filter by activities, wbs or critical.", + done.text.len() + ), + ); + } + done +} + +/// Apply an approved proposal (the `changes` of a proposed-changes event) +/// to the project open in the app, exactly as its preview ran: the same +/// document, the document's own `recalculate`, and no stored baselines +/// (the preview read an XER snapshot, which has none; a proposal holding +/// `monitor_thresholds` therefore measures against the project itself). +/// Returns the same report, field diff included; on `Err` the project is +/// unchanged. Previewed and applied on the same project, the two diffs are +/// equal. +pub fn apply_proposal(project: &mut ProjectData, changes: Value) -> crate::Result { + crate::edit::apply_changes(project, changes, None, &Default::default()) +} + +/// A few lines about `project` for the start of a chat, so the agent +/// rarely needs a discovery call: the project, its dates and counts and +/// the activities selected in the app (by Activity ID; at most 20 named). +pub fn preamble(project: &ProjectData, selected: &[String]) -> String { + let p = &project.model.project; + let date = |v: Option| { + let text = openxer_xer::date_string(project.model.origin_serial, v); + if text.is_empty() { + "none".to_string() + } else { + text + } + }; + // The Project ID is the short name; the project's name is that of its + // WBS project node. + let pid = p.proj_id.to_string(); + let title = project + .document + .table("PROJWBS") + .and_then(|t| { + t.rows + .iter() + .find(|r| t.value(r, "proj_id") == pid && t.value(r, "proj_node_flag") == "Y") + .map(|r| t.value(r, "wbs_name").to_string()) + }) + .filter(|s| !s.is_empty() && *s != p.name); + let mut lines = vec![ + match title { + Some(title) => format!("Open project: {} \"{title}\".", p.name), + None => format!("Open project: {}.", p.name), + }, + format!( + "Data date {}; scheduled finish {}; must finish {}.", + date(p.data_date), + date(p.scd_end), + date(p.plan_end) + ), + format!( + "{} activities, {} relationships.", + project.model.activities.len(), + project.model.links.len() + ), + ]; + if !selected.is_empty() { + let named: Vec = selected + .iter() + .take(20) + .map(|code| { + let name = project + .model + .activities + .iter() + .find(|a| &a.task_code == code) + .and_then(|a| project.details.get(&a.task_id)) + .map_or("", |d| d.name.as_str()); + if name.is_empty() { + code.clone() + } else { + format!("{code} {name}") + } + }) + .collect(); + let more = selected.len().saturating_sub(20); + lines.push(format!( + "Selected: {}{}.", + named.join("; "), + if more > 0 { + format!("; and {more} more") + } else { + String::new() + } + )); + } + lines.join("\n") +} + +/// Arguments for the MCP server of a chat: `mcp --toolset chat`, the +/// snapshot, the mode and optional custom playbooks folder. +pub fn server_arguments(context: &ChatContext) -> Vec { + let mut args = vec!["mcp".to_string(), "--toolset".into(), "chat".into()]; + if let Some(snapshot) = &context.snapshot { + args.push("--snapshot".into()); + args.push(snapshot.display().to_string()); + } + args.push("--mode".into()); + args.push(context.mode.id().into()); + if let Some(dir) = &context.playbooks_dir { + args.push("--playbooks-dir".into()); + args.push(dir.display().to_string()); + } + if let Some(ui_actions) = &context.ui_actions { + args.push("--ui-actions".into()); + args.push(ui_actions.display().to_string()); + } + args +} diff --git a/automation/src/checks.rs b/automation/src/checks.rs new file mode 100644 index 0000000..7dc3a69 --- /dev/null +++ b/automation/src/checks.rs @@ -0,0 +1,174 @@ +//! `check_schedule`: Tools > Check Schedule for agents. The rules are the +//! app's own (`openxer_xer::schedule_check`, which the dialog runs too); +//! this only puts the results rows into JSON. +use crate::{AutomationError, Result}; +use openxer_xer::schedule_check::{self as check, CheckParams, CheckResult, Item, CHECKS}; +use openxer_xer::ProjectData; +use serde_json::{json, Value}; + +/// Most Activity IDs or relationships one row lists. +pub const MAX_ITEMS: usize = 500; +/// Listed when the request does not say. +pub const DEFAULT_ITEMS: usize = 50; +/// The offenders every row names (`first`), before a `check` lists more. +pub const ROW_SAMPLE: usize = 5; + +fn round(v: f64) -> f64 { + (v * 100.0).round() / 100.0 +} + +/// The results rows for `p`, as the dialog shows them with its default +/// targets: name, count, of (the population), result (a percent, or the +/// index for BEI), target and pass. With `row` (a check's name, any case) +/// that row also lists its Activity IDs or relationships, up to `limit`. +/// Late Activities and BEI compare with the project's own planned dates when +/// no workspace project baseline is provided. +pub fn check_schedule(p: &ProjectData, row: Option<&str>, limit: Option) -> Result { + check_schedule_with(p, None, row, limit, &crate::analysis::Thresholds::default()) +} + +/// Like [`check_schedule`], with optional threshold overrides and an optional +/// workspace baseline context for Late Activities and BEI. +pub fn check_schedule_with( + p: &ProjectData, + ctx: Option<&crate::baselines::EvContext>, + row: Option<&str>, + limit: Option, + thresholds: &crate::analysis::Thresholds, +) -> Result { + let limit = limit.unwrap_or(DEFAULT_ITEMS); + if !(1..=MAX_ITEMS).contains(&limit) { + return Err(AutomationError::new( + "invalid_arguments", + format!("limit must be 1..{MAX_ITEMS}"), + )); + } + let wanted = match row { + Some(name) => Some( + CHECKS + .iter() + .copied() + .find(|c| c.name().eq_ignore_ascii_case(name.trim())) + .ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!( + "No check named {name:?}; checks are {}", + CHECKS + .iter() + .map(|c| c.name()) + .collect::>() + .join(", ") + ), + ) + })?, + ), + None => None, + }; + let mut params = CheckParams::default(); + for (value, slot) in [ + (thresholds.long_lag_hours, &mut params.long_lag_hours), + (thresholds.large_float_hours, &mut params.large_float_hours), + ( + thresholds.large_duration_hours, + &mut params.large_duration_hours, + ), + ] { + if let Some(v) = value { + if !(v.is_finite() && v >= 0.0) { + return Err(AutomationError::new( + "invalid_arguments", + "thresholds are hours of 0 or more", + )); + } + *slot = v; + } + } + let (finishes, baseline_label) = match ctx.and_then(|c| c.project.as_ref()) { + Some(bl) => ( + p.model + .activities + .iter() + .map(|a| bl.by_code.get(&a.task_code).and_then(|d| d.finish)) + .collect::>(), + bl.name.clone(), + ), + None => ( + check::current_finishes(p), + "the current project (no project baseline in this input)".to_string(), + ), + }; + let results = + check::run_checks_with(&p.model, ¶ms, &check::expense_tasks(p), Some(&finishes)); + let failed = results.iter().filter(|r| r.passed == Some(false)).count(); + // Each row with offenders names its first few, so one call usually + // answers without a call per row. + let rows: Vec = results + .iter() + .map(|r| { + let mut v = row_json(r); + if !r.items.is_empty() { + v["first"] = json!(r + .items + .iter() + .take(ROW_SAMPLE) + .map(|i| item_text(p, *i)) + .collect::>()); + } + v + }) + .collect(); + let mut out = json!({ + "summary": {"checks_run": rows.len(), "checks_failed": failed}, + "rows": rows, + "thresholds_hours": {"long_lag": params.long_lag_hours, "large_float": params.large_float_hours, "large_duration": params.large_duration_hours}, + "baseline": baseline_label, + }); + if let Some(c) = wanted { + let r = results + .iter() + .find(|r| r.check == c) + .expect("every check runs"); + let items: Vec = r + .items + .iter() + .take(limit) + .map(|i| item_text(p, *i)) + .collect(); + out["check"] = json!(c.name()); + out["items"] = json!(items); + out["items_total"] = json!(r.items.len()); + } + Ok(out) +} + +fn row_json(r: &CheckResult) -> Value { + let mut v = json!({ + "check": r.check.name(), + "count": r.items.len(), + "of": r.population, + "result": r.value.map(round), + "target": r.target, + "pass": r.passed, + }); + if let Some(note) = r.note { + v["note"] = json!(note); + } + v +} + +/// An activity by its Activity ID; a relationship as `PRED -> SUCC TYPE`. +fn item_text(p: &ProjectData, item: Item) -> String { + match item { + Item::Activity(i) => p.model.activities[i].task_code.clone(), + Item::Relationship(l) => { + let link = &p.model.links[l]; + format!( + "{} -> {} {}", + p.model.activities[link.pred].task_code, + p.model.activities[link.succ].task_code, + link.link_type.as_str().trim_start_matches("PR_") + ) + } + } +} diff --git a/automation/src/cli.rs b/automation/src/cli.rs new file mode 100644 index 0000000..94a866e --- /dev/null +++ b/automation/src/cli.rs @@ -0,0 +1,1449 @@ +//! CLI argument parsing; execution uses the same dispatcher as MCP. +use crate::{parse_command, AutomationError, Command, Result}; +use serde_json::{Map, Value}; +use std::collections::BTreeMap; + +pub const HELP: &str = r#"OpenXER native automation + +Usage: + openxer-cli inspect --input FILE + openxer-cli workspace migrate --input WORKSPACE.db (--output NEW.db | --dry-run) + openxer-cli workspace dictionary --input WORKSPACE.db [--table KIND] + openxer-cli workspace dictionary-usage --input WORKSPACE.db --table KIND + (--id N | --name NAME) + openxer-cli workspace preference --input WORKSPACE.db + [--name new_activity_wizard|new_resource_wizard + --value true|false (--output NEW.db | --dry-run)] + openxer-cli import --input FILE.xer|FILE.xml --output NEW.db [--project ID] + [--format xer|xml] + [--workspace EXISTING.db [--action new|update|replace|add] + [--target-workspace-id ID] [--config TYPE=ACTION,...] + [--dictionary KIND=copy|keep|update,...]] + openxer-cli load --input FILE [--project ID | --workspace-id ID] + [--offset N] [--limit N] + [--relationship-offset N] [--relationship-limit N] + [--fields KEY,KEY] [--activities ID,ID] [--wbs PATH] + [--critical [true|false]] [--sort [-]FIELD] + openxer-cli check-schedule --input FILE [--check NAME [--limit N]] + [--project ID | --workspace-id ID] + openxer-cli playbook [--name NAME] + openxer-cli curves --input FILE [--project ID | --workspace-id ID] + openxer-cli usage --input FILE (--activity ID | --resource SHORT_NAME) + [--interval day|week|month] [--from DATE] [--to DATE] + [--costs [true|false]] [--project ID | --workspace-id ID] + openxer-cli schedule --input FILE --output NEW_FILE [--project ID] + [--workspace-id ID] [--options JSON] + [--data-date "YYYY-MM-DD HH:MM"] [--level [true|false]] + openxer-cli relationship add|update|remove --input FILE --output NEW_FILE + --predecessor CODE --successor CODE --type FS|SS|FF|SF + [--lag-minutes N] [--new-type FS|SS|FF|SF] + [--project ID] [--workspace-id ID] + openxer-cli export --input FILE --output NEW.xer|NEW.xml [--project ID] + [--workspace-id ID] [--version 19.12] [--projects ID,ID] + [--format xer|xml] + openxer-cli export-xlsx --input FILE --output NEW.xlsx [--project ID] + [--workspace-id ID] [--layout modern|tables] [--unit days|hours] + [--columns KEY,KEY | --template NAME|FILE.json] + openxer-cli export-pdf --input FILE --output NEW.pdf [--project ID] + [--workspace-id ID] [--layout NAME] [--view gantt|network] + [--paper NAME] [--orientation portrait|landscape|automatic] + openxer-cli export-scurve --input FILE --output NEW.xlsx [--project ID] + [--workspace-id ID] [--measure auto|labor|cost|duration] + [--period day|week|month|financial] + [--breakdown total|resource|wbs1|wbs2] [--late [true|false]] + [--week-start sunday|monday] + openxer-cli export-earned-hours --input FILE --output NEW.xlsx [--project ID] + [--workspace-id ID] [--breakdown resource|wbs|activity] + openxer-cli import-xlsx --input FILE --spreadsheet FILE.xlsx + (--output NEW_FILE | --dry-run) [--project ID] + [--workspace-id ID] + openxer-cli apply --input FILE --changes CHANGES.json + (--output NEW_FILE | --dry-run) [--project ID] + [--workspace-id ID] [--recalculate true|false] + openxer-cli set-activity --activity ID --field KEY --value VALUE [edit flags] + openxer-cli add-activity [--activity ID] [--name TEXT] [--wbs PATH] + [--selected ID] [edit flags] + openxer-cli delete-activity --activity ID [edit flags] + openxer-cli dissolve-activity --activity ID [--retain-lag true|false] [edit flags] + openxer-cli assign --activity ID --resource SHORT_NAME [edit flags] + openxer-cli unassign --activity ID --resource SHORT_NAME [edit flags] + openxer-cli set-assignment --activity ID --resource SHORT_NAME + --field KEY --value VALUE [edit flags] + openxer-cli calendar-day --calendar NAME --date YYYY-MM-DD + --shifts '[["08:00","12:00"],...]'|nonwork|standard [edit flags] + openxer-cli calendar-weekday --calendar NAME --weekday 0-6 (0 = Sunday) + --shifts '[["08:00","12:00"],...]'|nonwork [edit flags] + openxer-cli set-project --field data_date|must_finish --value DATE [edit flags] + openxer-cli add-wbs --wbs PATH [--name TEXT] [edit flags] + openxer-cli add-document --title TEXT [--parent DOC] [--reference TEXT] [edit flags] + openxer-cli set-document --document DOC --field KEY --value VALUE [edit flags] + openxer-cli delete-document --document DOC [edit flags] + openxer-cli link-document --document DOC (--activity ID | --wbs PATH) + [--work-product true|false] [edit flags] + openxer-cli unlink-document --document DOC (--activity ID | --wbs PATH) [edit flags] + openxer-cli add-expense --activity ID [--name TEXT] [--fields JSON] [edit flags] + openxer-cli add-issue|add-risk [--name TEXT] [--fields JSON] [edit flags] + openxer-cli add-threshold [--parameter NAME] [--fields JSON] [edit flags] + openxer-cli set-expense|set-issue|set-risk|set-threshold + --expense|--issue|--risk|--threshold REF + --field KEY --value VALUE [edit flags] + openxer-cli delete-expense|delete-issue|delete-risk|delete-threshold + --expense|--issue|--risk|--threshold REF [edit flags] + openxer-cli assign-risk|unassign-risk --risk REF --activity ID [edit flags] + openxer-cli monitor-thresholds [--from DATE] [--to DATE] [--today DATE] [edit flags] + openxer-cli update-progress --data-date DATE [--activities ID,ID] + [--remaining always|duration_type] [edit flags] + openxer-cli apply-actuals --data-date DATE [--remaining always|duration_type] [edit flags] + openxer-cli recalculate-costs [--active-only true] [--sync-overtime true] [edit flags] + openxer-cli add-step --activity ID --name TEXT [--at N] [edit flags] + openxer-cli set-step --activity ID --step N|NAME --field KEY --value VALUE [edit flags] + openxer-cli delete-step --activity ID --step N|NAME [edit flags] + openxer-cli move-step --activity ID --step N|NAME --to N [edit flags] + openxer-cli add-steps-from-template --activity ID --template NAME [--after N|NAME] + [edit flags] + openxer-cli create-step-template --activity ID --name TEXT [edit flags] + openxer-cli set-feedback --activity ID [--notes TEXT] [--review-required true|false] + [edit flags] + openxer-cli top-down-estimate --labor-units N [--wbs PATH] [--not-started-only true|false] + [--weights '{"PATH":WEIGHT,...}'] [edit flags] + openxer-cli shift-wbs --wbs PATH --direction up|down|left|right [edit flags] + openxer-cli rename-wbs-code --wbs PATH --code TEXT [edit flags] + openxer-cli copy-calendar --calendar NAME [--source NAME] [--kind project|global|resource] + [edit flags] + openxer-cli rename-calendar --calendar NAME --name TEXT [edit flags] + openxer-cli set-default-calendar --calendar NAME [edit flags] + openxer-cli convert-calendar --calendar NAME --to global|shared|personal [edit flags] + openxer-cli global-change (--name SAVED_NAME | --rule JSON) [edit flags] + edit flags: --input FILE (--output NEW_FILE | --dry-run) [--project ID] + [--workspace-id ID] [--recalculate true|false] + openxer-cli eps list --input WORKSPACE.db + openxer-cli eps add-folder --name TEXT [--eps-id ID] [--parent EPS_ID] [eps flags] + openxer-cli eps rename-folder --folder EPS_ID [--name TEXT] [--new-eps-id ID] [eps flags] + openxer-cli eps move-folder --folder EPS_ID [--parent EPS_ID] [eps flags] + openxer-cli eps delete-folder --folder EPS_ID [--delete-projects] [eps flags] + openxer-cli eps file-project --workspace-id N --folder EPS_ID [eps flags] + openxer-cli eps create-project --folder EPS_ID --project-id ID + --planned-start DATE [--name TEXT] [--must-finish DATE] + [--manager NAME] [--rate-type COST_PER_QTY..COST_PER_QTY5] [eps flags] + eps flags: --input WORKSPACE.db (--output NEW.db | --dry-run) + openxer-cli baseline list --input WORKSPACE.db [--workspace-id N] + openxer-cli baseline add [baseline flags] + openxer-cli baseline convert --project N [baseline flags] + openxer-cli baseline copy|delete|restore|revert --baseline REF [baseline flags] + openxer-cli baseline set --baseline REF [--baseline-id ID] [--name TEXT] + [--type NAME|none] [baseline flags] + openxer-cli baseline assign [--project-baseline current|REF] + [--primary|--secondary|--tertiary current|none|REF] [baseline flags] + openxer-cli baseline update --baseline REF [--options JSON] [--activities ID,ID] + [baseline flags] + baseline flags: --input WORKSPACE.db --workspace-id N (--output NEW.db | --dry-run) + openxer-cli documents --input FILE [--project ID] [--workspace-id ID] + [--activity ID | --wbs PATH] + openxer-cli read-document --input FILE --document DOC [--project ID] + [--workspace-id ID] [--location private|public] + [--offset N] [--limit N] [--page N] [--pages N] + openxer-cli records --input FILE --kind expenses|issues|risks|thresholds + [--project ID] [--workspace-id ID] [--activity ID] + openxer-cli earned-value --input FILE [--basis cost|labor_units] + [--project ID] [--workspace-id ID] [--activity ID] + openxer-cli check-schedule --input FILE [--long-lag-hours N] + [--large-float-hours N] [--large-duration-hours N] [read flags] + openxer-cli paths --input FILE [--activity ID] [--count 1-10] [read flags] + openxer-cli compare --input FILE (--reference FILE [--reference-project ID] + [--reference-workspace-id ID] | --baseline project|primary) + [read flags] + openxer-cli lookahead --input FILE [--weeks 1-26] [--from DATE] [read flags] + openxer-cli milestones --input FILE [read flags] + openxer-cli schedule-stats --input FILE [--update-period-days N] [read flags] + openxer-cli resource-loading --input FILE [--interval day|week|month] [read flags] + openxer-cli wbs-summary --input FILE [--wbs-level 1-10] [read flags] + read flags: [--project ID | --workspace-id ID] + openxer-cli skills list | show ID | validate [FILE] | new ID | path + openxer-cli call --json JSON + openxer-cli call --request-file REQUEST.json + openxer-cli connect status + openxer-cli connect all [--dry-run] + openxer-cli connect claude-desktop|chatgpt|codex [--disconnect] [--dry-run] + openxer-cli connect claude-code + openxer-cli connect prompt + openxer-cli connect test + openxer-cli find-schedules [--folder DIR] + openxer-cli mcp [--toolset chat [--snapshot FILE] [--mode ask|edit]] + openxer-cli --help | --version + +Commands read the source without changing it and refuse existing output files. +Choose --project for a project ID (the XER proj_id), or --workspace-id for an OpenXER saved row. +A workspace keeps its global calendars, resources, roles, global and EPS codes, +UDFs, cost accounts and the other dictionaries once for all of its projects +(workspace schema 3): commands that read a workspace project add them back, +commands that write one merge them back, so an edit of a global calendar or a +resource reaches every project. An exported XER holds the dictionary rows its +projects use. workspace dictionary lists the dictionary with the projects +using each row; workspace dictionary-usage answers for one row (KIND: +calendar, resource, role, activity_code, code_value, udf, account or a table +name). A workspace made by an earlier version (schema 1) is read and written +as before; workspace migrate converts a copy of it (--dry-run first). +workspace preference reads the app's User Preferences, Assistance switches +kept in a workspace: new_activity_wizard (on by default; Edit > Add opens the +New Activity wizard, off inserts the row at once) and new_resource_wizard +(on by default; the Resources view's Add opens the New Resource wizard). +With --name and --value it writes a copy with the switch set. +import --workspace matches the file's dictionary rows to the workspace's by +name: the same content is reused, other values are added as _ unless +--dictionary says keep (use the workspace's) or update (the workspace's takes +the file's values); each project lists these decisions in "dictionary". +import --config sets per-type actions for --action update, for example +activities=update+delete,relationships=update,calendars=keep. Types: activities, +relationships, wbs, assignments, calendars, resources, activity_codes, udfs, +notebooks. Actions: insert, keep, update, skip. export-xlsx --template runs a saved +export template (columns, filter, sort and options) by its name in the workspace +input, or from a template .json file; it replaces --columns and --unit. import-xlsx --dry-run prints the +preview (changed cells, new rows, deletes, errors) without writing anything. +curves lists the resource curves an assignment can use, read-only: the file's +own curves and OpenXER's preset curves ("Even", "Early Weighted", "Late +Weighted", "Ramp Up", "Ramp Down", "Bell, Centered", "Bell, Early Peak", +"Bell, Late Peak", "Two Peaks", "Steady with Ramps"), each with its 21 points. set_assignment field curve +takes a curve name (or null to clear); a preset is copied into the file the +first time an assignment uses it. Curves shape how an assignment's units and +costs spread over time (usage views, planned value, usage) on Fixed Duration +activities; the exact numbers follow OpenXER's reading of the documented +behavior and are not yet measured against other software. +usage reads an activity's or a resource's assignments period by period +(read-only): budgeted, actual, remaining and remaining late units (or costs +with --costs true) per day, week (from Monday, the default) or month, each +assignment's windows, curve and whether it shapes the spread, and the totals. +Each series gives total, per_period and unplaced, the part of the stored +quantity no period holds (outside the periods, or nothing to spread over): +total + unplaced = stored. +export-scurve writes the S-curve workbook of Tools > Reports > S-Curve: per +period the budgeted (from the assigned project or primary baseline, else the +current plan), actual (to the data date) and remaining values, running sums and +percents as formulas, earned to the data date and a native chart, the +breakdown matrices and an Info sheet. --measure auto (the default) takes labor +hours when labor assignments carry budgeted units, else cost (assignments and +expenses), else duration (each activity weighs its planned working days); +--period week (from Sunday) and --breakdown resource (total for duration) are +the defaults; --late adds actual plus remaining on the late dates. +export-earned-hours writes cumulative earned labor hours to the data date: +baseline budgeted units x performance % complete per labor assignment, with +actual, remaining and at completion, by resource (default), wbs or activity, +rows sorted by ID so two exports subtract in Excel; a project without labor +hours fails with no_labor_units and writes nothing. +export-pdf prints with the desktop's renderer: it runs the OpenXER executable +next to openxer-cli (or OPENXER_DESKTOP) headless and uses the layout's Page +Setup. +apply runs an openxer-changes/1 file: {"format":"openxer-changes/1", +"recalculate":true, "operations":[{"op":"set_activity",...},...]}. Operations run +in file order, all or nothing; nothing is written when one fails. Operations: +set_project, add_wbs, add_activity, delete_activity, dissolve_activity +(activity, retain_lag; needs a predecessor and a successor), set_activity, +assign_resource, remove_assignment, set_assignment, relationship (add, edit or +remove, with lag_hours and comments), calendar_day, calendar_weekday, schedule, +and the record edits set_resource_limit, set_activity_code, set_project_code +(code_type, value: the project's value of a project code), add_code_type +(code_type, scope project|eps|global, max_length), add_code_value, set_code_value, +delete_code_value, set_notebook, set_wbs_notebook, set_udf, add_calendar, +set_calendar, delete_calendar, add_resource, set_resource, set_wbs, +set_schedule_option, add_project_funding (source, amount, share), +set_project_funding (source, field source|amount|share, value), +delete_project_funding (source), delete_resource (resource), +delete_financial_period (period, calendar; refused while stored period +performance refers to the period), global_change (Tools > Global Change on every +activity: name of a definition saved in a workspace, or rule {match all|any, +conditions, then, otherwise}; the result lists the report lines, activity, +field, old, new and exception, and changed counts the values written; durations +in hours), merge_resources +(from: [short names], into: short name; assignments, rates, codes, UDF values, +role links, child resources and the calendar move to into, assignments of one +activity are combined, then from is removed; --dry-run previews it) and +set_wbs_earned_value (wbs, performance activity_percent|wbs_milestones|0/100| +50/50|custom, custom_percent, estimate_to_complete remaining|pf_1|pf_cpi| +pf_cpi_spi|pf, performance_factor), and the document edits add_document (title, +parent, reference, fields {...}), set_document (document, field title|reference| +deliverable|status|category|author|version|date|private_location|public_location| +description, value), delete_document (document; the documents under it and their +links go too), link_document and unlink_document (document, activity or wbs, +work_product), and the register edits add_expense (activity, name, fields), +set_expense, delete_expense, add_issue, set_issue, delete_issue, add_risk, +set_risk, delete_risk, assign_risk, unassign_risk, add_threshold (parameter, +fields), set_threshold, delete_threshold and monitor_thresholds (from, to, +today), the Tools edits update_progress (data_date, activities, remaining +always|duration_type), apply_actuals (data_date, remaining), +recalculate_costs (active_only, sync_overtime) and top_down_estimate +(labor_units, wbs, not_started_only, weights {path: weight}), the step edits +add_step (activity, name, at), set_step (activity, step, field name|complete| +percent_complete|weight|description, value), delete_step, move_step (to), +add_steps_from_template (template, after), create_step_template (name), +set_feedback (activity, notes, review_required), shift_wbs (wbs, direction +up|down|left|right), rename_wbs_code (wbs, code), copy_calendar (calendar, +source, kind project|global|resource), rename_calendar (calendar, name), +set_default_calendar and convert_calendar (to global|shared|personal). +set_activity also takes the Status tab units and costs: budgeted_, actual_, +remaining_, at_completion_ or this_period_ with labor_units, +nonlabor_units, labor_cost, nonlabor_cost or material_cost; set_assignment also takes +original_duration, remaining_duration (hours), drive_activity_dates, +resource (replace), role and cost_account (by name; null clears). Any +operation may carry a "meta" object +(provenance such as source or evidence) that apply ignores. Activities are named by +Activity ID, resources by short name, calendars by name and WBS elements by +their code path (1.2.3). Durations and lags are hours, dates project-local +"YYYY-MM-DD HH:MM", choices take XER codes (TT_Task, CS_ALAP, DT_FixedDUR2) or +display names, and a null value clears. Edits use the desktop's setters, so +statuses, durations and assignments follow the same rules. --recalculate false +(or "recalculate": false, also per operation) writes set_activity and +set_assignment values exactly into their XER columns with no duration type, +units or cost knock-on; that mode also takes derived fields such as +remaining_units_per_hour, costs and raw XER column names. The single edit +commands run one operation the same way; --dry-run returns the field diff +without writing. --value is the text typed (1.10 stays 1.10; numeric fields +read the number from it), except null (clears) and true or false; --value "" +and --notes "" give empty text, and a value starting with -- is given inline +(--value=--x). --review-required, --active-only, --sync-overtime, +--not-started-only, --work-product and --costs mean true on their own. +eps list reads an OpenXER workspace and returns its EPS folders (EPS ID, name, +parent, path, projects filed directly in each) and every project, each with its +rollup: start and finish (earliest start and latest finish, actual else early), +late start and finish, data date (a folder shows the latest), Must Finish By, +baseline finish and finish_variance_hours (baseline finish minus finish in +working hours), total_float_hours (the lowest of the unfinished activities; a +folder the lowest of its projects), schedule_percent_complete (duration based: +planned span minus remaining span over planned span, in working time), +labor_units_hours and costs (budgeted, actual, remaining; they add up) and the +activity counts. Values come from the stored projects, so closed projects are +current. The eps edits work on a copy written to --output: move-folder without +--parent moves the folder to the top level; delete-folder deletes the folder, +the folders under it and every project filed in them with their baselines (a +folder that holds projects needs --delete-projects; --dry-run lists what would +go without it) and refuses to delete the last top-level folder; create-project uses the New Project +wizard's rules (Project ID unique, up to 20 characters; Planned Start required; +a date without a time takes 08:00, Must Finish By 17:00) and the responsible +managers of the project last open in the app. +baseline list shows each workspace project's stored baselines as Project > +Maintain Baselines lists them (id, Baseline ID, name, type, data date, date +added, last update date, what each is assigned as) and its Assign Baselines +choices. The baseline edits work on a copy written to --output with the app's +rules: add saves a copy of the project as " - B" / +" - B" (n the lowest free number); convert makes the closed +workspace project --project a baseline that keeps its own ID and name, with a +blank last update date; copy makes another baseline with the next number and +the source's last update date; delete and restore refuse a baseline assigned +as project, primary, secondary or tertiary baseline (error code refused); +restore makes the baseline a separate project with the same ID and name in +the owner's EPS folder; revert (Revert Project to Baseline) gives the project +the baseline's data and keeps its ID, name and baselines; set changes the +Baseline ID, name or type; assign sets the project baseline (current or a +baseline) and the primary, secondary and tertiary baselines (current, none +or a baseline). REF is a baseline's id from baseline list, its Baseline ID or +its name. update (Maintain Baselines > Update) carries the project's data +into the baseline by the Update Baseline options: --options is a JSON object +of them by name (omitted ones take the dialog's defaults; see +openxer_baseline_update), --activities limits the activities added or updated +to those Activity IDs; --dry-run true returns the preview (each changed +project, WBS element and activity: Added, Deleted or Updated, with field, +project value and baseline value) and writes nothing; the update sets Last +Update Date and writes a log to the options' log_path when one is given. +documents lists the project's work products and documents (title, reference, +version, status, category, locations, description, linked activities and WBS +elements), or only those linked to --activity or --wbs; load lists each +activity's linked documents too. A document (DOC) is named by its reference +number, title or document id. read-document returns the text of the file a +document points at (--location private or public; by default private when set): +only an existing file on a local drive named by an absolute path, as Launch in +the WPs & Docs view opens, under the input file's folder or a folder listed in +the environment variable OPENXER_DOCUMENT_ROOTS (separated by ; on Windows, : +elsewhere); relative, network (UNC) and web locations are +refused, and so are programs and scripts (.exe .bat .cmd .ps1 .js .vbs .msi .com +.scr). txt, md, csv, json, xml and log files come back as text and docx as its +body text, paged by --offset and --limit characters (default 20000, at most +200000); PDF text is extracted page by page, --page (from 1) and --pages (default +10, at most 100). Files over 64 MB are not read. Error codes: document_not_found, +no_location, location_refused, refused_type, unsupported_type, file_too_large, +read_failed. +records lists the project's expense items, issues, risks or thresholds with +every field the set_ edits take (choices by label, activities by Activity ID, +WBS elements by path, resources by short name); a record (REF) is named by its +id, or by its name (a risk also by its Risk ID) when that is unique. +set_expense keeps budgeted units x price = budgeted cost and an item without +actuals all remaining; set_issue activity and wbs clear each other. Issue +fields Monitor Thresholds sets (threshold_parameter, actual_value, +lower_threshold, upper_threshold) are read-only. monitor-thresholds +evaluates every enabled threshold as Tools > Monitor Thresholds does, against +the workspace's assigned project and primary baselines (an XER input is its +own baseline), and raises or updates issues; --from and --to replace every +threshold's own window. earned-value returns BAC, PV, EV, AC, SV, CV, SPI, +CPI, ETC, EAC and VAC per activity and for the project, as the earned value +columns compute them (planned value follows resource curves the same way). +The analysis commands only read and give the numbers schedule reviews need: +check-schedule runs Check Schedule with the items each check finds; +paths ranks the chains of work into an activity (the project finish by +default) by float; compare sets the project against an earlier file or a +stored baseline (moves in calendar days); lookahead lists the work of the +next weeks by WBS, ready or waiting and on what; milestones lists every +milestone with float, baseline move and its driving ties; schedule-stats +counts activities, durations, calendars, names and WBS levels; +resource-loading gives each resource's units per period against its limit; +wbs-summary rolls the schedule up by WBS to a level. +skills manages the instructions agents follow to analyze and build +schedules: list (built-in, yours and customized, and the files left out +with their error), show ID (the instructions), validate (one file, or every +file in the folder), new ID (a file from the template in the folder) and +path (the folder: skills in the OpenXER data folder, which OPENXER_DATA_DIR +moves). A file whose id equals a built-in's replaces it; deleting the file +brings the built-in back. +JSON responses use schema_version, ok, and result or error. Exit codes: +0 success, 1 command failure, 2 invalid command-line/request arguments. +load returns every activity field unless --fields names some (task_code is +always kept; wbs, the code path, and critical, by the project's own +definition, come only when named); --activities, --wbs (the element and +everything under it) and --critical keep only the matching activities, and +then only the relationships with an end among them, with matched_activities +and matched_relationships counted and unknown Activity IDs in not_found. +--sort orders the activities by one of those fields (documents aside), with a +- first for descending (--sort=-early_finish lists the latest finish first); +WBS paths sort element by element (1.2 before 1.10); empty values go last, +and equal values keep the project's order. +--limit 0 or --relationship-limit 0 returns no rows of that kind (counts only, +with no next offset). +load --fields also names original_duration_minutes, actual_start, +actual_finish, constraint and constraint_date, given only when named. +check-schedule runs Tools > Check Schedule read-only with the app's own rules +and default targets: one row per check (Logic, Negative lags, Positive Lags, +Long Lags, Relationship Types, Hard Constraints, Soft Constraints, Large +Float, Negative Float, Large Durations, Activities with Invalid progress +dates, Resources / Cost, Late Activities, BEI, Out Of Sequence) with check, +count, of, result (a percent, or the index for BEI), target, pass and the first +five offenders; --check +NAME also lists that row's Activity IDs (relationships as PRED -> SUCC TYPE), +--limit of them (default 50, at most 500). Late Activities and BEI compare +with the project's own planned finishes. playbook lists the scheduling +playbooks (build, update, audit, critical-path, delay-recovery, +schedule-check), and --name returns one: step-by-step methods that name the +chat tools to use, for an agent to load when it needs one. +The mcp subcommand serves JSON-RPC over stdin/stdout without opening a UI. +mcp --toolset chat serves the small tool set of OpenXER's Chat window: load, +records, earned_value, usage, documents, check_schedule and playbook for +reading, and with --mode edit +(ask is the default, read-only) apply as a proposal only: it always runs as a +dry run on the snapshot and never writes a file, so the user approves the +change in the app. --snapshot names the project file every call reads, so +the tools take no input; results over the chat size limit are refused with +result_too_large and a hint to narrow the request. +connect adds OpenXER's MCP server (this openxer-cli with the argument mcp) to an +AI client's config: status reports each client with its state and the one +action to take (connect, connected, use_this_copy, repair, not_installed, +fix_file, copy_command), claude-desktop and codex (chatgpt is the same: the +ChatGPT desktop app and Codex share one config) merge only the "openxer" entry +into the client's config (backed up first as FILE.openxer-backup-TIMESTAMP, +written atomically and checked; every other byte is kept), which also repairs +an entry or switches one that runs another copy of OpenXER to this copy, +--disconnect removes only that entry, --dry-run shows the new text without +writing, all connects every found app that is not connected or needs repair +(never one connected to another copy), claude-code prints the command to run +in a terminal, prompt prints a setup prompt to paste into any AI tool that can +run commands, and test starts the MCP server and lists its tools. A config +that cannot be parsed, or a read-only one, is never changed. +find-schedules (read-only) tells an agent where the user's schedules are: the +OpenXER workspace this copy opens (and the other copy's, installed or +portable, when it has one) with its projects, most recently saved first, each +with the file it came from; --folder also lists the XER and workspace files in +one folder (not its subfolders). Pass a workspace as --input with +--workspace-id, or an XER file as --input, to the other commands. +"#; + +#[derive(Debug)] +pub enum Invocation { + Help, + Version, + Mcp, + /// `mcp --toolset chat`: the Chat window's tool set. + ChatMcp(crate::chat_tools::ChatContext), + Connect(crate::connect::Request), + Run(Box), +} + +fn invalid(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +/// Flags that mean true on their own and take an optional true or false. +const BARE_TRUE: &[&str] = &[ + "level", + "dry-run", + "recalculate", + "review-required", + "active-only", + "sync-overtime", + "not-started-only", + "work-product", + "costs", + "late", + "critical", + "delete-projects", +]; + +fn flags(args: &[String], allowed: &[&str]) -> Result> { + let mut result = BTreeMap::new(); + let mut position = 0; + while position < args.len() { + let argument = &args[position]; + let name_value = argument.strip_prefix("--").ok_or_else(|| { + invalid(format!( + "Unexpected argument {argument:?}; use named --flags" + )) + })?; + let (name, inline) = name_value + .split_once('=') + .map_or((name_value, None), |(name, value)| (name, Some(value))); + if !allowed.contains(&name) { + return Err(invalid(format!("Unknown flag --{name}"))); + } + if result.contains_key(name) { + return Err(invalid(format!("Duplicate flag --{name}"))); + } + // Text that may be cleared takes an empty value; a value that starts + // with -- is given inline (--value=--x). + let empty_ok = matches!(name, "value" | "notes"); + let value = if let Some(value) = inline { + if value.is_empty() && !empty_ok { + return Err(invalid(format!("--{name} requires a value"))); + } + value.to_owned() + } else if BARE_TRUE.contains(&name) { + if args + .get(position + 1) + .is_some_and(|next| next == "true" || next == "false") + { + position += 1; + args[position].clone() + } else { + "true".into() + } + } else { + position += 1; + let value = args + .get(position) + .filter(|value| (empty_ok || !value.is_empty()) && !value.starts_with("--")) + .ok_or_else(|| invalid(format!("--{name} requires a value")))?; + value.clone() + }; + result.insert(name.to_owned(), value); + position += 1; + } + Ok(result) +} + +fn json(text: &str, label: &str) -> Result { + serde_json::from_str(text).map_err(|error| invalid(format!("Invalid {label} JSON: {error}"))) +} + +fn put_integer(object: &mut Map, key: &str, text: &str, signed: bool) -> Result<()> { + let number = if signed { + Value::from( + text.parse::() + .map_err(|_| invalid(format!("{key} must be a signed integer")))?, + ) + } else { + Value::from( + text.parse::() + .map_err(|_| invalid(format!("{key} must be a nonnegative integer")))?, + ) + }; + object.insert(key.into(), number); + Ok(()) +} + +/// `connect status | all | claude-desktop | chatgpt | codex | claude-code | +/// prompt | test`, with `--disconnect` and `--dry-run` for the config-editing +/// clients (`chatgpt` is `codex`: they share one config) and `--dry-run` +/// for `all`. +fn parse_connect(args: &[String]) -> Result { + use crate::connect::{Client, Request}; + let what = args.first().ok_or_else(|| { + invalid("connect requires status, all, claude-desktop, chatgpt, codex, claude-code, prompt or test") + })?; + let mut disconnect = false; + let mut dry_run = false; + for flag in &args[1..] { + match flag.as_str() { + "--disconnect" if !disconnect => disconnect = true, + "--dry-run" if !dry_run => dry_run = true, + other => { + return Err(invalid(format!( + "Unexpected argument {other:?} for connect {what}" + ))) + } + } + } + let plain = |request: Request| { + if disconnect || dry_run { + Err(invalid(format!("connect {what} takes no flags"))) + } else { + Ok(request) + } + }; + match what.as_str() { + "status" => plain(Request::Status), + "test" => plain(Request::Test), + "claude-code" => plain(Request::ClaudeCode), + "prompt" => plain(Request::Prompt), + "all" if !disconnect => Ok(Request::All { dry_run }), + "all" => Err(invalid("connect all takes only --dry-run")), + id => match Client::parse(id) { + Some(client) => Ok(Request::Apply { + client, + disconnect, + dry_run, + }), + None => Err(invalid(format!( + "Unknown connect target {id:?}; use status, all, claude-desktop, chatgpt, codex, claude-code, prompt or test" + ))), + }, + } +} + +/// `mcp --toolset chat [--snapshot FILE] [--mode ask|edit] [--playbooks-dir DIR] [--ui-actions FILE]`. +fn parse_chat_mcp(args: &[String]) -> Result { + use crate::chat_tools::{ChatContext, ChatMode}; + let fields = flags( + args, + &["toolset", "snapshot", "mode", "playbooks-dir", "ui-actions"], + )?; + match fields.get("toolset").map(String::as_str) { + Some("chat") => {} + Some(other) => { + return Err(invalid(format!( + "Unknown toolset {other:?}; the only one is chat (omit --toolset for every tool)" + ))) + } + None => return Err(invalid("--snapshot and --mode need --toolset chat")), + } + let mode = match fields.get("mode") { + Some(text) => ChatMode::parse(text).ok_or_else(|| invalid("--mode accepts ask or edit"))?, + None => ChatMode::Ask, + }; + Ok(ChatContext { + snapshot: fields.get("snapshot").map(std::path::PathBuf::from), + mode, + playbooks_dir: fields.get("playbooks-dir").map(std::path::PathBuf::from), + ui_actions: fields.get("ui-actions").map(std::path::PathBuf::from), + }) +} + +/// Parse arguments excluding the executable name. No scheduler, GUI, or output +/// publication runs here. `call --request-file` only reads its JSON request. +pub fn parse(args: I) -> Result +where + I: IntoIterator, + S: Into, +{ + let args: Vec = args.into_iter().map(Into::into).collect(); + let Some(command) = args.first().map(String::as_str) else { + return Ok(Invocation::Help); + }; + if command == "mcp" && args.len() > 1 { + return parse_chat_mcp(&args[1..]).map(Invocation::ChatMcp); + } + if matches!( + command, + "--help" | "-h" | "help" | "--version" | "-V" | "version" | "mcp" + ) { + if args.len() != 1 { + return Err(invalid(format!( + "{command} does not accept additional arguments" + ))); + } + return Ok(match command { + "mcp" => Invocation::Mcp, + "--version" | "-V" | "version" => Invocation::Version, + _ => Invocation::Help, + }); + } + if command == "connect" { + return parse_connect(&args[1..]).map(Invocation::Connect); + } + if command == "eps" { + if args.len() >= 2 && args[1..].iter().all(|a| a == "--help" || a == "-h") { + return Ok(Invocation::Help); + } + if args.len() == 3 && matches!(args[2].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + return parse_eps(&args[1..]).map(|c| Invocation::Run(Box::new(c))); + } + if command == "baseline" { + if args.len() == 3 && matches!(args[2].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + let request = crate::baseline_cmd::parse_cli(&args[1..], flags)?; + return parse_command(request).map(|c| Invocation::Run(Box::new(c))); + } + if command == "skills" { + return parse_skills(&args[1..]); + } + if command == "workspace" { + if args.len() == 3 && matches!(args[2].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + let request = crate::workspace_cmd::parse_cli(&args[1..], flags)?; + return parse_command(request).map(|c| Invocation::Run(Box::new(c))); + } + if !matches!( + command, + "inspect" + | "find-schedules" + | "import" + | "load" + | "check-schedule" + | "playbook" + | "curves" + | "usage" + | "schedule" + | "relationship" + | "export" + | "export-xlsx" + | "export-pdf" + | "export-scurve" + | "export-earned-hours" + | "import-xlsx" + | "documents" + | "read-document" + | "records" + | "earned-value" + | "paths" + | "compare" + | "lookahead" + | "milestones" + | "schedule-stats" + | "resource-loading" + | "wbs-summary" + | "call" + | "apply" + ) && edit_command(command).is_none() + { + return Err(invalid(format!("Unknown command {command:?}; use --help"))); + } + if args.len() == 2 && matches!(args[1].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + if command == "call" { + let fields = flags(&args[1..], &["json", "request-file"])?; + if fields.len() != 1 { + return Err(invalid( + "call requires exactly one of --json or --request-file", + )); + } + let request = if let Some(text) = fields.get("json") { + json(text, "request")? + } else { + let path = &fields["request-file"]; + let text = std::fs::read_to_string(path) + .map_err(|error| invalid(format!("Cannot read request file {path:?}: {error}")))?; + json(&text, "request")? + }; + return parse_command(request).map(|command| Invocation::Run(Box::new(command))); + } + if command == "apply" || edit_command(command).is_some() { + return parse_edit(command, &args[1..]).map(|c| Invocation::Run(Box::new(c))); + } + let mut edit = Map::new(); + let start = if command == "relationship" { + let action = args + .get(1) + .map(String::as_str) + .filter(|action| matches!(*action, "add" | "update" | "remove")) + .ok_or_else(|| invalid("relationship requires add, update, or remove"))?; + if args.len() == 3 && matches!(args[2].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + edit.insert("action".into(), Value::from(action)); + 2 + } else { + 1 + }; + let allowed: &[&str] = match command { + "inspect" => &["input"], + "find-schedules" => &["folder"], + "curves" => &["input", "project", "workspace-id"], + "check-schedule" => &[ + "input", + "project", + "workspace-id", + "check", + "limit", + "long-lag-hours", + "large-float-hours", + "large-duration-hours", + ], + "playbook" => &["name"], + "usage" => &[ + "input", + "project", + "workspace-id", + "activity", + "resource", + "interval", + "from", + "to", + "costs", + ], + "import" => &[ + "input", + "output", + "project", + "workspace", + "action", + "target-workspace-id", + "config", + "dictionary", + "format", + ], + "load" => &[ + "input", + "project", + "workspace-id", + "offset", + "limit", + "relationship-offset", + "relationship-limit", + "fields", + "activities", + "wbs", + "critical", + "sort", + ], + "schedule" => &[ + "input", + "output", + "project", + "workspace-id", + "options", + "data-date", + "level", + ], + "relationship" => &[ + "input", + "output", + "project", + "workspace-id", + "predecessor", + "successor", + "type", + "lag-minutes", + "new-type", + ], + "export" => &[ + "input", + "output", + "project", + "workspace-id", + "version", + "projects", + "format", + ], + "export-xlsx" => &[ + "input", + "output", + "project", + "workspace-id", + "layout", + "unit", + "columns", + "template", + ], + "export-pdf" => &[ + "input", + "output", + "project", + "workspace-id", + "layout", + "view", + "paper", + "orientation", + ], + "export-scurve" => &[ + "input", + "output", + "project", + "workspace-id", + "measure", + "period", + "breakdown", + "late", + "week-start", + ], + "export-earned-hours" => &["input", "output", "project", "workspace-id", "breakdown"], + "import-xlsx" => &[ + "input", + "spreadsheet", + "output", + "project", + "workspace-id", + "dry-run", + ], + "documents" => &["input", "project", "workspace-id", "activity", "wbs"], + "records" => &["input", "project", "workspace-id", "kind", "activity"], + "earned-value" => &["input", "project", "workspace-id", "basis", "activity"], + "paths" => &["input", "project", "workspace-id", "activity", "count"], + "compare" => &[ + "input", + "project", + "workspace-id", + "reference", + "reference-project", + "reference-workspace-id", + "baseline", + ], + "lookahead" => &["input", "project", "workspace-id", "weeks", "from"], + "milestones" => &["input", "project", "workspace-id"], + "schedule-stats" => &["input", "project", "workspace-id", "update-period-days"], + "resource-loading" => &["input", "project", "workspace-id", "interval"], + "wbs-summary" => &["input", "project", "workspace-id", "wbs-level"], + "read-document" => &[ + "input", + "project", + "workspace-id", + "document", + "location", + "offset", + "limit", + "page", + "pages", + ], + _ => unreachable!(), + }; + let fields = flags(&args[start..], allowed)?; + if command == "read-document" && !fields.contains_key("document") { + return Err(invalid("read-document requires --document")); + } + if fields.contains_key("project") && fields.contains_key("workspace-id") { + return Err(invalid("Choose --project or --workspace-id, not both")); + } + let mut request = Map::new(); + request.insert("command".into(), Value::from(command.replace('-', "_"))); + let mut options = if let Some(value) = fields.get("options") { + json(value, "schedule options")? + .as_object() + .cloned() + .ok_or_else(|| invalid("--options must contain a JSON object"))? + } else { + Map::new() + }; + for (name, value) in fields { + match name.as_str() { + "input" | "output" | "workspace" | "action" | "config" | "dictionary" | "version" + | "projects" | "spreadsheet" | "layout" | "unit" | "columns" | "template" | "view" + | "paper" | "orientation" | "activity" | "wbs" | "document" | "location" | "kind" + | "basis" | "resource" | "interval" | "from" | "to" | "measure" | "period" + | "breakdown" | "folder" | "sort" | "check" | "name" | "format" | "reference" + | "baseline" => { + request.insert(name, Value::from(value)); + } + "long-lag-hours" + | "large-float-hours" + | "large-duration-hours" + | "update-period-days" => { + let number = value + .parse::() + .ok() + .filter(|v| v.is_finite()) + .ok_or_else(|| invalid(format!("--{name} must be a number")))?; + request.insert(name.replace('-', "_"), Value::from(number)); + } + "count" | "weeks" => put_integer(&mut request, &name, &value, false)?, + // wbs-summary's level is a WBS depth (--level is schedule's + // leveling switch). + "wbs-level" => put_integer(&mut request, "level", &value, false)?, + "reference-project" => put_integer(&mut request, "reference_project_id", &value, true)?, + "reference-workspace-id" => { + put_integer(&mut request, "reference_workspace_id", &value, true)? + } + "week-start" => { + request.insert("week_start".into(), Value::from(value)); + } + // Load's comma separated lists. + "fields" | "activities" => { + let list: Vec = value + .split(',') + .map(|s| Value::from(s.trim())) + .filter(|v| v.as_str() != Some("")) + .collect(); + request.insert(name, Value::Array(list)); + } + "critical" => { + request.insert( + "critical".into(), + Value::Bool( + value + .parse::() + .map_err(|_| invalid("--critical accepts true or false"))?, + ), + ); + } + "late" => { + request.insert( + "late".into(), + Value::Bool( + value + .parse::() + .map_err(|_| invalid("--late accepts true or false"))?, + ), + ); + } + "costs" => { + request.insert( + "costs".into(), + Value::Bool( + value + .parse::() + .map_err(|_| invalid("--costs accepts true or false"))?, + ), + ); + } + "target-workspace-id" => { + put_integer(&mut request, "target_workspace_id", &value, true)? + } + "dry-run" => { + request.insert( + "dry_run".into(), + Value::Bool( + value + .parse::() + .map_err(|_| invalid("--dry-run accepts true or false"))?, + ), + ); + } + "project" => put_integer(&mut request, "project_id", &value, true)?, + "workspace-id" => put_integer(&mut request, "workspace_id", &value, true)?, + "offset" + | "limit" + | "relationship-offset" + | "relationship-limit" + | "page" + | "pages" => put_integer(&mut request, &name.replace('-', "_"), &value, false)?, + "predecessor" | "successor" => { + edit.insert(name, Value::from(value)); + } + "type" => { + edit.insert( + "relationship_type".into(), + Value::from(value.to_ascii_uppercase()), + ); + } + "new-type" => { + edit.insert("new_type".into(), Value::from(value.to_ascii_uppercase())); + } + "lag-minutes" => put_integer(&mut edit, "lag_minutes", &value, true)?, + "options" => {} + "data-date" | "level" => { + let key = if name == "level" { + "level_resources" + } else { + "data_date" + }; + if options.contains_key(key) { + return Err(invalid(format!("--{name} duplicates {key} in --options"))); + } + let value = if name == "level" { + Value::Bool( + value + .parse::() + .map_err(|_| invalid("--level accepts true or false"))?, + ) + } else { + Value::from(value) + }; + options.insert(key.into(), value); + } + _ => unreachable!(), + } + } + if command == "schedule" { + request.insert("options".into(), Value::Object(options)); + } + if command == "relationship" { + request.insert("edit".into(), Value::Object(edit)); + } + parse_command(Value::Object(request)).map(|command| Invocation::Run(Box::new(command))) +} + +/// `skills list | show ID | validate [FILE] | new ID | path`. +fn parse_skills(args: &[String]) -> Result { + let what = args + .first() + .map(String::as_str) + .ok_or_else(|| invalid("skills requires list, show, validate, new or path"))?; + if args.len() == 2 && matches!(args[1].as_str(), "--help" | "-h") { + return Ok(Invocation::Help); + } + let rest = &args[1..]; + let one = |label: &str| -> Result { + match rest { + [value] if !value.starts_with("--") => Ok(value.clone()), + _ => Err(invalid(format!("skills {what} takes one {label}"))), + } + }; + let none = || { + if rest.is_empty() { + Ok(()) + } else { + Err(invalid(format!("skills {what} takes no arguments"))) + } + }; + let request = match what { + "list" => { + none()?; + serde_json::json!({"command":"skills"}) + } + "path" => { + none()?; + serde_json::json!({"command":"skills_path"}) + } + "show" => serde_json::json!({"command":"skill","id":one("skill id")?}), + "new" => serde_json::json!({"command":"skill_new","id":one("skill id")?}), + "validate" => match rest { + [] => serde_json::json!({"command":"skill_validate"}), + _ => serde_json::json!({"command":"skill_validate","file":one("file")?}), + }, + other => { + return Err(invalid(format!( + "Unknown skills command {other:?}; use list, show, validate, new or path" + ))) + } + }; + parse_command(request).map(|c| Invocation::Run(Box::new(c))) +} + +/// Single edit commands: the operation each runs and its own flags. +fn edit_command(command: &str) -> Option<(&'static str, &'static [&'static str])> { + Some(match command { + "set-activity" => ("set_activity", &["activity", "field", "value"]), + "add-activity" => ("add_activity", &["activity", "selected", "name", "wbs"]), + "delete-activity" => ("delete_activity", &["activity"]), + "dissolve-activity" => ("dissolve_activity", &["activity", "retain-lag"]), + "assign" => ("assign_resource", &["activity", "resource"]), + "unassign" => ("remove_assignment", &["activity", "resource"]), + "set-assignment" => ( + "set_assignment", + &["activity", "resource", "field", "value"], + ), + "calendar-day" => ("calendar_day", &["calendar", "date", "shifts"]), + "calendar-weekday" => ("calendar_weekday", &["calendar", "weekday", "shifts"]), + "set-project" => ("set_project", &["field", "value"]), + "add-wbs" => ("add_wbs", &["wbs", "name"]), + "add-document" => ("add_document", &["title", "parent", "reference"]), + "set-document" => ("set_document", &["document", "field", "value"]), + "delete-document" => ("delete_document", &["document"]), + "link-document" => ( + "link_document", + &["document", "activity", "wbs", "work-product"], + ), + "unlink-document" => ("unlink_document", &["document", "activity", "wbs"]), + "add-expense" => ("add_expense", &["activity", "name", "fields"]), + "set-expense" => ("set_expense", &["expense", "field", "value"]), + "delete-expense" => ("delete_expense", &["expense"]), + "add-issue" => ("add_issue", &["name", "fields"]), + "set-issue" => ("set_issue", &["issue", "field", "value"]), + "delete-issue" => ("delete_issue", &["issue"]), + "add-risk" => ("add_risk", &["name", "fields"]), + "set-risk" => ("set_risk", &["risk", "field", "value"]), + "delete-risk" => ("delete_risk", &["risk"]), + "assign-risk" => ("assign_risk", &["risk", "activity"]), + "unassign-risk" => ("unassign_risk", &["risk", "activity"]), + "add-threshold" => ("add_threshold", &["parameter", "fields"]), + "set-threshold" => ("set_threshold", &["threshold", "field", "value"]), + "delete-threshold" => ("delete_threshold", &["threshold"]), + "monitor-thresholds" => ("monitor_thresholds", &["from", "to", "today"]), + "add-step" => ("add_step", &["activity", "name", "at"]), + "set-step" => ("set_step", &["activity", "step", "field", "value"]), + "delete-step" => ("delete_step", &["activity", "step"]), + "move-step" => ("move_step", &["activity", "step", "to"]), + "add-steps-from-template" => ( + "add_steps_from_template", + &["activity", "template", "after"], + ), + "create-step-template" => ("create_step_template", &["activity", "name"]), + "set-feedback" => ("set_feedback", &["activity", "notes", "review-required"]), + "update-progress" => ("update_progress", &["data-date", "activities", "remaining"]), + "apply-actuals" => ("apply_actuals", &["data-date", "remaining"]), + "recalculate-costs" => ("recalculate_costs", &["active-only", "sync-overtime"]), + "top-down-estimate" => ( + "top_down_estimate", + &["labor-units", "wbs", "not-started-only", "weights"], + ), + "shift-wbs" => ("shift_wbs", &["wbs", "direction"]), + "rename-wbs-code" => ("rename_wbs_code", &["wbs", "code"]), + "rename-calendar" => ("rename_calendar", &["calendar", "name"]), + "set-default-calendar" => ("set_default_calendar", &["calendar"]), + "convert-calendar" => ("convert_calendar", &["calendar", "to"]), + "copy-calendar" => ("copy_calendar", &["calendar", "source", "kind"]), + "global-change" => ("global_change", &["name", "rule"]), + _ => return None, + }) +} + +/// A `--value` is the text typed, so a text field keeps it exactly (`1.10`, +/// `0042`, a 20-digit number); numeric fields read their number from it. +/// Only `null` (clear) and `true` or `false` are taken as JSON. +fn loose_value(text: &str) -> Value { + match text { + "null" => Value::Null, + "true" => Value::Bool(true), + "false" => Value::Bool(false), + _ => Value::from(text), + } +} + +fn shifts_value(text: &str, weekday: bool) -> Result { + match text.trim() { + "nonwork" => Ok(Value::Array(vec![])), + "standard" if !weekday => Ok(Value::Null), + other => json(other, "shifts"), + } +} + +/// `apply` and the single edit commands. They build the same requests as +/// `call` with an `apply` or `edit` command. +fn parse_edit(command: &str, args: &[String]) -> Result { + let common = [ + "input", + "output", + "project", + "workspace-id", + "dry-run", + "recalculate", + ]; + let own: &[&str] = match edit_command(command) { + Some((_, own)) => own, + None => &["changes"], + }; + let allowed: Vec<&str> = common.iter().chain(own).copied().collect(); + let fields = flags(args, &allowed)?; + if fields.contains_key("project") && fields.contains_key("workspace-id") { + return Err(invalid("Choose --project or --workspace-id, not both")); + } + let mut request = Map::new(); + let mut operation = Map::new(); + for (name, value) in &fields { + match name.as_str() { + "input" | "output" => { + request.insert(name.clone(), Value::from(value.as_str())); + } + "project" => put_integer(&mut request, "project_id", value, true)?, + "workspace-id" => put_integer(&mut request, "workspace_id", value, true)?, + "dry-run" | "recalculate" => { + let flag = value + .parse::() + .map_err(|_| invalid(format!("--{name} accepts true or false")))?; + request.insert(name.replace('-', "_"), Value::Bool(flag)); + } + "changes" => { + request.insert("changes_file".into(), Value::from(value.as_str())); + } + "value" => { + operation.insert("value".into(), loose_value(value)); + } + "weekday" => put_integer(&mut operation, "weekday", value, false)?, + "at" | "to" if command.ends_with("-step") => { + put_integer(&mut operation, name, value, false)? + } + "labor-units" => { + let n = value + .parse::() + .map_err(|_| invalid("--labor-units must be a number"))?; + operation.insert("labor_units".into(), Value::from(n)); + } + "review-required" | "active-only" | "sync-overtime" | "not-started-only" + | "retain-lag" => { + let flag = value + .parse::() + .map_err(|_| invalid(format!("--{name} accepts true or false")))?; + operation.insert(name.replace('-', "_"), Value::Bool(flag)); + } + "activities" => { + let list: Vec = value + .split(',') + .map(|s| Value::from(s.trim())) + .filter(|v| v.as_str() != Some("")) + .collect(); + operation.insert("activities".into(), Value::Array(list)); + } + "weights" => { + let object = json(value, "weights")?; + if !object.is_object() { + return Err(invalid("--weights must contain a JSON object")); + } + operation.insert("weights".into(), object); + } + "data-date" => { + operation.insert("data_date".into(), Value::from(value.as_str())); + } + "rule" => { + let object = json(value, "rule")?; + if !object.is_object() { + return Err(invalid("--rule must contain a JSON object")); + } + operation.insert("rule".into(), object); + } + "fields" => { + let object = json(value, "fields")?; + if !object.is_object() { + return Err(invalid("--fields must contain a JSON object")); + } + operation.insert("fields".into(), object); + } + "work-product" => { + let flag = value + .parse::() + .map_err(|_| invalid("--work-product accepts true or false"))?; + operation.insert("work_product".into(), Value::Bool(flag)); + } + "shifts" => { + operation.insert( + "shifts".into(), + shifts_value(value, command == "calendar-weekday")?, + ); + } + _ => { + operation.insert(name.clone(), Value::from(value.as_str())); + } + } + } + match edit_command(command) { + Some((op, own)) => { + for flag in own { + let optional = (command == "add-wbs" && *flag == "name") + || command == "add-activity" + || (command == "calendar-day" && *flag == "shifts") + || (command == "add-document" && matches!(*flag, "parent" | "reference")) + || (command.ends_with("link-document") + && matches!(*flag, "activity" | "wbs" | "work-product")) + || matches!(*flag, "fields" | "from" | "to" | "today") + || (matches!( + command, + "add-expense" | "add-issue" | "add-risk" | "add-threshold" + ) && matches!(*flag, "name" | "parameter")) + || matches!( + (command, *flag), + ("add-step", "at") + | ("set-feedback", "notes" | "review-required") + | ("dissolve-activity", "retain-lag") + | ("update-progress", "activities" | "remaining") + | ("apply-actuals", "remaining") + | ("recalculate-costs", _) + | ("top-down-estimate", "wbs" | "not-started-only" | "weights") + | ("copy-calendar", "source" | "kind") + | ("global-change", _) + ); + if !optional && !fields.contains_key(*flag) { + return Err(invalid(format!("{command} requires --{flag}"))); + } + } + operation.insert("op".into(), Value::from(op)); + request.insert("command".into(), Value::from("edit")); + request.insert("operation".into(), Value::Object(operation)); + } + None => { + if !fields.contains_key("changes") { + return Err(invalid("apply requires --changes")); + } + request.insert("command".into(), Value::from("apply")); + } + } + if !fields.contains_key("input") { + return Err(invalid(format!("{command} requires --input"))); + } + parse_command(Value::Object(request)) +} + +/// `eps list` and the EPS edits. +fn parse_eps(args: &[String]) -> Result { + let sub = args.first().map(String::as_str).ok_or_else(|| { + invalid("eps requires list, add-folder, rename-folder, move-folder, delete-folder, file-project or create-project") + })?; + let (op, own, required): (&str, &[&str], &[&str]) = match sub { + "list" => ("", &[], &[]), + "add-folder" => ("add_folder", &["name", "eps-id", "parent"], &["name"]), + "rename-folder" => ( + "rename_folder", + &["folder", "name", "new-eps-id"], + &["folder"], + ), + "move-folder" => ("move_folder", &["folder", "parent"], &["folder"]), + "delete-folder" => ( + "delete_folder", + &["folder", "delete-projects"], + &["folder"], + ), + "file-project" => ( + "file_project", + &["workspace-id", "folder"], + &["workspace-id", "folder"], + ), + "create-project" => ( + "create_project", + &[ + "folder", + "project-id", + "name", + "planned-start", + "must-finish", + "manager", + "rate-type", + ], + &["folder", "project-id", "planned-start"], + ), + other => { + return Err(invalid(format!( + "Unknown eps command {other:?}; use list, add-folder, rename-folder, move-folder, delete-folder, file-project or create-project" + ))) + } + }; + let common: &[&str] = if sub == "list" { + &["input"] + } else { + &["input", "output", "dry-run"] + }; + let allowed: Vec<&str> = common.iter().chain(own).copied().collect(); + let fields = flags(&args[1..], &allowed)?; + if !fields.contains_key("input") { + return Err(invalid(format!("eps {sub} requires --input"))); + } + for flag in required { + if !fields.contains_key(*flag) { + return Err(invalid(format!("eps {sub} requires --{flag}"))); + } + } + let mut request = Map::new(); + let mut operation = Map::new(); + for (name, value) in &fields { + match name.as_str() { + "input" | "output" => { + request.insert(name.clone(), Value::from(value.as_str())); + } + "dry-run" => { + let flag = value + .parse::() + .map_err(|_| invalid("--dry-run accepts true or false"))?; + request.insert("dry_run".into(), Value::Bool(flag)); + } + "workspace-id" => put_integer(&mut operation, "workspace_id", value, true)?, + "delete-projects" => { + let flag = value + .parse::() + .map_err(|_| invalid("--delete-projects accepts true or false"))?; + operation.insert("delete_projects".into(), Value::Bool(flag)); + } + _ => { + operation.insert(name.replace('-', "_"), Value::from(value.as_str())); + } + } + } + if sub == "list" { + request.insert("command".into(), Value::from("eps_list")); + } else { + operation.insert("op".into(), Value::from(op)); + request.insert("command".into(), Value::from("eps")); + request.insert("operation".into(), Value::Object(operation)); + } + parse_command(Value::Object(request)) +} diff --git a/automation/src/connect.rs b/automation/src/connect.rs new file mode 100644 index 0000000..0e40b51 --- /dev/null +++ b/automation/src/connect.rs @@ -0,0 +1,1786 @@ +//! Connecting MCP clients (Claude Desktop, ChatGPT desktop and Codex, Claude +//! Code) to `openxer-cli mcp`. The CLI (`openxer-cli connect ...`) and the +//! desktop's AI Agents menu share this module. +//! +//! The first half is pure functions over config text: read the `openxer` +//! entry's state, merge it in, take it out. They never touch the file +//! system, so every case is unit tested on strings. The second half is a +//! thin file layer over an injected [`Env`]: it finds the config files, +//! backs a file up before changing it, writes atomically, re-reads and +//! validates, and puts the original back when validation fails. Only the +//! `openxer` entry is ever added, changed or removed. +use crate::{AutomationError, Result}; +use serde::Serialize; +use serde_json::{json, Value}; +use std::{ + ffi::OsString, + io::{BufRead, BufReader, Write}, + path::{Path, PathBuf}, + process::{Command, Stdio}, + sync::mpsc, + time::{Duration, SystemTime, UNIX_EPOCH}, +}; + +/// The server name every client config uses for OpenXER. +pub const SERVER: &str = "openxer"; +/// The CLI executable's file name. +pub const CLI_NAME: &str = if cfg!(windows) { + "openxer-cli.exe" +} else { + "openxer-cli" +}; +/// Claude Desktop's config file name. +pub const CLAUDE_DESKTOP_FILE: &str = "claude_desktop_config.json"; +/// How long Test Connection waits for the server. +pub const TEST_TIMEOUT: Duration = Duration::from_secs(15); + +/// The file an installer puts beside the executables of an installed copy +/// (a portable copy has none). Keep in step with the desktop's workspace +/// rule, which uses the same marker. +pub const INSTALLED_MARKER: &str = "openxer.installed"; +/// The first request to try in a newly connected app. +pub const FIRST_PROMPT: &str = "Use OpenXER to inspect my schedule."; + +/// The clients this module knows. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, Serialize)] +#[serde(rename_all = "kebab-case")] +pub enum Client { + ClaudeDesktop, + /// The ChatGPT desktop app and Codex (its app and CLI): they share one + /// config file, `%USERPROFILE%\.codex\config.toml`. + Codex, + ClaudeCode, +} + +impl Client { + pub const ALL: [Client; 3] = [Client::ClaudeDesktop, Client::Codex, Client::ClaudeCode]; + + /// The id the CLI takes (`claude-desktop`, `codex`, `claude-code`). + pub fn id(self) -> &'static str { + match self { + Client::ClaudeDesktop => "claude-desktop", + Client::Codex => "codex", + Client::ClaudeCode => "claude-code", + } + } + + /// The app's display name. + pub fn name(self) -> &'static str { + match self { + Client::ClaudeDesktop => "Claude Desktop", + Client::Codex => "ChatGPT desktop and Codex", + Client::ClaudeCode => "Claude Code", + } + } + + /// The client a CLI id names; `chatgpt` is another name for `codex`. + pub fn parse(id: &str) -> Option { + if id == "chatgpt" { + return Some(Client::Codex); + } + Client::ALL.into_iter().find(|c| c.id() == id) + } + + /// What to do in the app after it is connected, in plain words, with + /// the first thing to ask. + pub fn next_step(self) -> String { + match self { + Client::ClaudeDesktop => format!( + "Quit Claude Desktop from its tray icon (closing the window is not enough), open it again, then ask: \"{FIRST_PROMPT}\"" + ), + Client::Codex => format!( + "Restart the app, then ask: \"{FIRST_PROMPT}\" In ChatGPT desktop use Work or Codex mode: for now, plain Chat may not use tools on this PC." + ), + Client::ClaudeCode => format!( + "Paste the command into a terminal, restart Claude Code, then ask: \"{FIRST_PROMPT}\"" + ), + } + } + + /// Claude Code is connected by its own command, never by editing files. + pub fn edits_config(self) -> bool { + self != Client::ClaudeCode + } +} + +/// The state of the `openxer` entry in one config. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +#[serde(tag = "state", rename_all = "snake_case")] +pub enum Entry { + /// No `openxer` entry (or no file). + NotConnected, + /// The entry runs this OpenXER's `openxer-cli mcp`. + Connected, + /// The entry runs `mcp` with another executable that exists: another + /// copy of OpenXER (`installed` when the installer's marker is beside + /// it). It works, so nothing repoints it unless asked ("Use this copy"). + OtherCopy { command: String, installed: bool }, + /// The entry runs an executable that no longer exists, or other + /// arguments: it cannot work and needs repair. + Stale { command: String }, + /// The config cannot be read as JSON or TOML; nothing is written to it. + Malformed { message: String }, +} + +impl Entry { + /// Ranks entries so the worst of several files names a client's state. + fn rank(&self) -> u8 { + match self { + Entry::Connected => 0, + Entry::NotConnected => 1, + Entry::OtherCopy { .. } => 2, + Entry::Stale { .. } => 3, + Entry::Malformed { .. } => 4, + } + } + + /// The short words a status column shows. + pub fn label(&self) -> &'static str { + match self { + Entry::NotConnected => "Not connected", + Entry::Connected => "Connected", + Entry::OtherCopy { .. } => "Connected to another copy of OpenXER", + Entry::Stale { .. } => "Needs repair", + Entry::Malformed { .. } => "Its settings file cannot be read", + } + } + + /// Whether the app can reach an OpenXER server through this entry. + pub fn works(&self) -> bool { + matches!(self, Entry::Connected | Entry::OtherCopy { .. }) + } +} + +/// The one thing the Connect dialog offers for an app, worked out from its +/// state. The CLI reports it too, so both say the same. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize)] +#[serde(rename_all = "snake_case")] +pub enum Action { + /// Found and not connected: Connect. + Connect, + /// Connected to this copy: nothing to do (Test, Disconnect). + Connected, + /// Connected to another copy that exists: Use This Copy switches it. + UseThisCopy, + /// The entry points at a missing file or runs other arguments: Repair. + Repair, + /// The app is not on this PC and has no entry: plain text, no button. + NotInstalled, + /// Its settings file cannot be read: OpenXER leaves it alone. + FixFile, + /// Claude Code: copy its own command. + CopyCommand, +} + +impl Action { + /// Whether "Connect all found apps" connects an app in this state: + /// never one that works, so a working connection is not repointed. + pub fn in_connect_all(self) -> bool { + matches!(self, Action::Connect | Action::Repair) + } +} + +// ------------------------------------------------------------ pure: paths + +/// Whether a config's `command` names `cli`: separators and, on Windows, +/// letter case are not significant; surrounding quotes are ignored. +pub fn same_path(command: &str, cli: &Path) -> bool { + let norm = |s: &str| { + let s = s.trim().trim_matches('"'); + if cfg!(windows) { + s.replace('/', "\\").to_lowercase() + } else { + s.to_string() + } + }; + norm(command) == norm(&cli.display().to_string()) +} + +fn classify( + command: Option<&str>, + args: Option>, + cli: &Path, + exists: &dyn Fn(&Path) -> bool, +) -> Entry { + let command_text = command.unwrap_or_default().to_string(); + let runs_mcp = args.as_deref() == Some(&["mcp".to_string()][..]); + match command { + Some(c) if same_path(c, cli) && exists(cli) && runs_mcp => Entry::Connected, + Some(c) if runs_mcp && !same_path(c, cli) => { + let other = PathBuf::from(c.trim().trim_matches('"')); + if other.is_absolute() && exists(&other) { + Entry::OtherCopy { + command: command_text, + installed: is_installed_copy(&other, exists), + } + } else { + Entry::Stale { + command: command_text, + } + } + } + _ => Entry::Stale { + command: command_text, + }, + } +} + +/// Whether `cli` belongs to an installed copy: the installer's marker file +/// is beside it. +pub fn is_installed_copy(cli: &Path, exists: &dyn Fn(&Path) -> bool) -> bool { + cli.parent() + .is_some_and(|dir| exists(&dir.join(INSTALLED_MARKER))) +} + +/// The command a user pastes into a terminal to add OpenXER to Claude Code. +/// The path is always quoted, so spaces in it are safe. +pub fn claude_code_command(cli: &Path) -> String { + format!( + "claude mcp add --scope user {SERVER} -- \"{}\" mcp", + cli.display() + ) +} + +/// A prompt a user pastes into any AI tool that can run commands, so it +/// sets itself up with this copy of OpenXER: where `openxer-cli` is (quoted, +/// as in [`claude_code_command`]), how to learn its commands, the MCP +/// server to add or the CLI to call, a real command that proves it works +/// (`connect test`), the safety rules and a first request. The desktop's +/// Copy Setup Prompt and `openxer-cli connect prompt` both print this. +pub fn setup_prompt(cli: &Path) -> String { + let cli = format!("\"{}\"", cli.display()); + format!( + "Set yourself up to work with OpenXER, a CPM scheduler on this PC, through its command-line tool: +{cli} + +1. Run it with --help to see its commands. +2. If you can use MCP servers, add one named {SERVER} that runs that file with the single argument mcp. Otherwise call the file directly: every command prints JSON. +3. Check that it works: run it with the arguments connect test. It starts the MCP server, lists its tools and prints \"Working: N tools\". + +Rules: OpenXER never changes an input file; every edit is written to a new file (--output). Use --dry-run to preview an edit before anything is written, and show me the changes first. + +Then: {FIRST_PROMPT} +" + ) +} + +/// The generic MCP JSON setup most clients accept. +pub fn setup_snippet(cli: &Path) -> String { + let value = + json!({"mcpServers": {SERVER: {"command": cli.display().to_string(), "args": ["mcp"]}}}); + serde_json::to_string_pretty(&value).expect("JSON value serializes") + "\n" +} + +// ------------------------------------------------------- pure: JSON configs + +/// A JSON value that keeps its keys in file order, so a rewritten config +/// differs from the original only where the `openxer` entry is. +#[derive(Clone, Debug, PartialEq)] +enum J { + Null, + Bool(bool), + Number(serde_json::Number), + String(String), + Array(Vec), + Object(Vec<(String, J)>), +} + +impl<'de> serde::Deserialize<'de> for J { + fn deserialize>(d: D) -> std::result::Result { + struct V; + impl<'de> serde::de::Visitor<'de> for V { + type Value = J; + fn expecting(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + f.write_str("a JSON value") + } + fn visit_unit(self) -> std::result::Result { + Ok(J::Null) + } + fn visit_none(self) -> std::result::Result { + Ok(J::Null) + } + fn visit_bool(self, v: bool) -> std::result::Result { + Ok(J::Bool(v)) + } + fn visit_i64(self, v: i64) -> std::result::Result { + Ok(J::Number(v.into())) + } + fn visit_u64(self, v: u64) -> std::result::Result { + Ok(J::Number(v.into())) + } + fn visit_f64(self, v: f64) -> std::result::Result { + serde_json::Number::from_f64(v) + .map(J::Number) + .ok_or_else(|| E::custom("number out of range")) + } + fn visit_str(self, v: &str) -> std::result::Result { + Ok(J::String(v.to_string())) + } + fn visit_string(self, v: String) -> std::result::Result { + Ok(J::String(v)) + } + fn visit_seq>( + self, + mut a: A, + ) -> std::result::Result { + let mut out = vec![]; + while let Some(v) = a.next_element()? { + out.push(v); + } + Ok(J::Array(out)) + } + fn visit_map>( + self, + mut a: A, + ) -> std::result::Result { + let mut out: Vec<(String, J)> = vec![]; + while let Some((k, v)) = a.next_entry::()? { + out.push((k, v)); + } + Ok(J::Object(out)) + } + } + d.deserialize_any(V) + } +} + +impl Serialize for J { + fn serialize(&self, s: S) -> std::result::Result { + use serde::ser::{SerializeMap, SerializeSeq}; + match self { + J::Null => s.serialize_unit(), + J::Bool(b) => s.serialize_bool(*b), + J::Number(n) => n.serialize(s), + J::String(t) => s.serialize_str(t), + J::Array(items) => { + let mut seq = s.serialize_seq(Some(items.len()))?; + for item in items { + seq.serialize_element(item)?; + } + seq.end() + } + J::Object(fields) => { + let mut map = s.serialize_map(Some(fields.len()))?; + for (k, v) in fields { + map.serialize_entry(k, v)?; + } + map.end() + } + } + } +} + +impl J { + fn get(&self, key: &str) -> Option<&J> { + match self { + J::Object(fields) => fields.iter().find(|(k, _)| k == key).map(|(_, v)| v), + _ => None, + } + } + fn get_mut(&mut self, key: &str) -> Option<&mut J> { + match self { + J::Object(fields) => fields.iter_mut().find(|(k, _)| k == key).map(|(_, v)| v), + _ => None, + } + } + fn remove(&mut self, key: &str) -> bool { + if let J::Object(fields) = self { + let before = fields.len(); + fields.retain(|(k, _)| k != key); + return fields.len() != before; + } + false + } + fn str(&self) -> Option<&str> { + match self { + J::String(s) => Some(s), + _ => None, + } + } + fn strings(&self) -> Option> { + match self { + J::Array(items) => items.iter().map(|i| i.str().map(str::to_string)).collect(), + _ => None, + } + } +} + +const JSON_SERVERS: &str = "mcpServers"; + +fn strip_bom(text: &str) -> &str { + text.strip_prefix('\u{feff}').unwrap_or(text) +} + +/// Parses a JSON config: empty text is an empty object; anything that is +/// not an object whose `mcpServers` (when present) is an object is refused. +fn json_root(text: &str) -> std::result::Result { + let text = strip_bom(text); + if text.trim().is_empty() { + return Ok(J::Object(vec![])); + } + let root: J = serde_json::from_str(text).map_err(|e| format!("not valid JSON ({e})"))?; + if !matches!(root, J::Object(_)) { + return Err("the file is not a JSON object".into()); + } + if root + .get(JSON_SERVERS) + .is_some_and(|s| !matches!(s, J::Object(_))) + { + return Err(format!("\"{JSON_SERVERS}\" is not an object")); + } + Ok(root) +} + +/// The `openxer` entry's state in a JSON (`mcpServers`) config. +pub fn json_entry(text: &str, cli: &Path, exists: &dyn Fn(&Path) -> bool) -> Entry { + let root = match json_root(text) { + Ok(root) => root, + Err(message) => return Entry::Malformed { message }, + }; + match root.get(JSON_SERVERS).and_then(|s| s.get(SERVER)) { + None => Entry::NotConnected, + Some(entry) => classify( + entry.get("command").and_then(J::str), + entry.get("args").and_then(J::strings), + cli, + exists, + ), + } +} + +// The JSON configs are edited as text: the parsed value says what to +// change, and byte ranges found by a small scanner say where, so every byte +// outside the `openxer` entry (other servers, settings, spacing, key order) +// stays exactly as the file had it. + +/// One `"key": value` of a JSON object, as byte offsets into the text. +struct Member { + key: String, + key_start: usize, + key_end: usize, + value: (usize, usize), +} + +/// A JSON object's braces and members, as byte offsets into the text. +struct Obj { + open: usize, + close: usize, + members: Vec, +} + +impl Obj { + fn member(&self, key: &str) -> Option<&Member> { + self.members.iter().find(|m| m.key == key) + } +} + +fn skip_ws(b: &[u8], mut i: usize) -> usize { + while i < b.len() && matches!(b[i], b' ' | b'\t' | b'\r' | b'\n') { + i += 1; + } + i +} + +/// The end (exclusive) of the string starting at `i` (its opening quote). +fn string_end(b: &[u8], mut i: usize) -> Option { + i += 1; + while i < b.len() { + match b[i] { + b'\\' => i += 2, + b'"' => return Some(i + 1), + _ => i += 1, + } + } + None +} + +/// The end (exclusive) of the value starting at `i`. +fn value_end(b: &[u8], i: usize) -> Option { + match *b.get(i)? { + b'"' => string_end(b, i), + b'{' | b'[' => { + let mut depth = 0usize; + let mut j = i; + while j < b.len() { + match b[j] { + b'"' => { + j = string_end(b, j)?; + continue; + } + b'{' | b'[' => depth += 1, + b'}' | b']' => { + depth -= 1; + if depth == 0 { + return Some(j + 1); + } + } + _ => {} + } + j += 1; + } + None + } + _ => { + let mut j = i; + while j < b.len() && !matches!(b[j], b',' | b'}' | b']' | b' ' | b'\t' | b'\r' | b'\n') + { + j += 1; + } + Some(j) + } + } +} + +/// The object whose `{` is at `open` (text already validated as JSON). +fn object_at(text: &str, open: usize) -> Option { + let b = text.as_bytes(); + let mut members = vec![]; + let mut i = skip_ws(b, open + 1); + loop { + match *b.get(i)? { + b'}' => { + return Some(Obj { + open, + close: i, + members, + }) + } + b'"' => { + let key_end = string_end(b, i)?; + let key: String = serde_json::from_str(&text[i..key_end]).ok()?; + let colon = skip_ws(b, key_end); + let start = skip_ws(b, colon + 1); + let end = value_end(b, start)?; + members.push(Member { + key, + key_start: i, + key_end, + value: (start, end), + }); + i = skip_ws(b, end); + if b.get(i) == Some(&b',') { + i = skip_ws(b, i + 1); + } + } + _ => return None, + } + } +} + +/// How the file lays out JSON: one indent step (None: all on one line). +fn json_style(text: &str, root: &Obj) -> Option { + if !text.contains('\n') && !root.members.is_empty() { + return None; + } + let unit = root + .members + .first() + .and_then(|m| { + let before = &text[root.open + 1..m.key_start]; + before.rfind('\n').map(|n| before[n + 1..].to_string()) + }) + .filter(|u| !u.is_empty() && u.chars().all(|c| c == ' ' || c == '\t')) + .unwrap_or_else(|| " ".into()); + Some(unit) +} + +/// The spaces at the start of the line holding byte `at`. +fn line_indent(text: &str, at: usize) -> String { + let start = text[..at].rfind('\n').map_or(0, |n| n + 1); + text[start..] + .chars() + .take_while(|c| *c == ' ' || *c == '\t') + .collect() +} + +/// A JSON string literal for `s`. +fn json_string(s: &str) -> String { + serde_json::to_string(s).expect("a string serializes") +} + +/// Our entry's object text with its members at `indent` + one step (or on +/// one line). +fn json_entry_text(cli: &Path, style: Option<&str>, indent: &str) -> String { + let command = json_string(&cli.display().to_string()); + match style { + None => format!("{{\"command\":{command},\"args\":[\"mcp\"]}}"), + Some(unit) => format!( + "{{\n{indent}{unit}\"command\": {command},\n{indent}{unit}\"args\": [\n{indent}{unit}{unit}\"mcp\"\n{indent}{unit}]\n{indent}}}" + ), + } +} + +/// The edit that adds `"key": value` as the last member of `obj`; `value` +/// is made for the member indent it is given. +fn insert_member( + text: &str, + obj: &Obj, + key: &str, + style: Option<&str>, + value: impl Fn(&str) -> String, +) -> (usize, usize, String) { + let key = json_string(key); + match obj.members.last() { + Some(last) => { + let b = text.as_bytes(); + let mut sep_start = last.key_start; + while sep_start > 0 && matches!(b[sep_start - 1], b' ' | b'\t' | b'\r' | b'\n') { + sep_start -= 1; + } + let sep = &text[sep_start..last.key_start]; + let colon = &text[last.key_end..last.value.0]; + let indent = sep.rfind('\n').map_or("", |n| &sep[n + 1..]); + let at = last.value.1; + (at, at, format!(",{sep}{key}{colon}{}", value(indent))) + } + None => { + let outer = line_indent(text, obj.open); + let body = match style { + None => format!("{key}:{}", value("")), + Some(unit) => { + let indent = format!("{outer}{unit}"); + format!("\n{indent}{key}: {}\n{outer}", value(&indent)) + } + }; + (obj.open + 1, obj.close, body) + } + } +} + +/// Applies non-overlapping edits (start, end, new text) to `text`. +fn apply_edits(text: &str, mut edits: Vec<(usize, usize, String)>) -> String { + edits.sort_by_key(|e| std::cmp::Reverse(e.0)); + let mut out = text.to_string(); + for (start, end, new) in edits { + out.replace_range(start..end, &new); + } + out +} + +/// The BOM (if any) and the JSON text after it. +fn split_bom(text: &str) -> (&str, &str) { + match text.strip_prefix('\u{feff}') { + Some(rest) => ("\u{feff}", rest), + None => ("", text), + } +} + +fn scan_root(body: &str) -> std::result::Result { + let open = skip_ws(body.as_bytes(), 0); + object_at(body, open).ok_or_else(|| "the file could not be scanned as JSON".to_string()) +} + +/// One edit at a time: the text after it, with offsets rescanned by the +/// caller. In a file with Windows line ends the new text gets them too. +fn edit_once(text: &str, mut edit: (usize, usize, String)) -> String { + if text.contains("\r\n") { + edit.2 = edit.2.replace("\r\n", "\n").replace('\n', "\r\n"); + } + apply_edits(text, vec![edit]) +} + +/// The object a member's value is. +fn member_object(text: &str, root: &Obj, key: &str) -> Option { + let m = root.member(key)?; + (text.as_bytes().get(m.value.0) == Some(&b'{')) + .then(|| object_at(text, m.value.0)) + .flatten() +} + +/// `text` with the `openxer` entry set to run `cli mcp`. Everything else in +/// the file, other fields of an existing `openxer` entry (such as `env`) +/// included, is kept byte for byte. Err is why the text was refused. +pub fn json_connect(text: &str, cli: &Path) -> std::result::Result { + json_root(text)?; + let (bom, body) = split_bom(text); + if body.trim().is_empty() { + let value = json!({JSON_SERVERS: {SERVER: {"command": cli.display().to_string(), "args": ["mcp"]}}}); + return Ok(format!( + "{bom}{}\n", + serde_json::to_string_pretty(&value).expect("JSON value serializes") + )); + } + let unscannable = || "the file could not be scanned as JSON".to_string(); + let style = json_style(body, &scan_root(body)?); + let style = style.as_deref(); + let entry = |indent: &str| json_entry_text(cli, style, indent); + let command = json_string(&cli.display().to_string()); + let mut out = body.to_string(); + // 1. An `mcpServers` object to put the entry in. + let root = scan_root(&out)?; + if root.member(JSON_SERVERS).is_none() { + let edit = insert_member(&out, &root, JSON_SERVERS, style, |_| "{}".into()); + out = edit_once(&out, edit); + } + let root = scan_root(&out)?; + let servers = member_object(&out, &root, JSON_SERVERS).ok_or_else(unscannable)?; + match servers.member(SERVER) { + // 2. No entry: add ours as the last server. + None => { + let edit = insert_member(&out, &servers, SERVER, style, entry); + out = edit_once(&out, edit); + } + // 3. An entry that is not an object: replace it whole. + Some(ours) if out.as_bytes()[ours.value.0] != b'{' => { + let indent = line_indent(&out, ours.key_start); + let edit = (ours.value.0, ours.value.1, entry(&indent)); + out = edit_once(&out, edit); + } + // 4. An entry object: set its command and args in place, keeping + // its other fields. + Some(_) => { + let wanted = [ + ("command", command, json!(cli.display().to_string())), + ("args", "[\"mcp\"]".to_string(), json!(["mcp"])), + ]; + for (key, value, parsed) in wanted { + let root = scan_root(&out)?; + let servers = member_object(&out, &root, JSON_SERVERS).ok_or_else(unscannable)?; + let ours = member_object(&out, &servers, SERVER).ok_or_else(unscannable)?; + let edit = match ours.member(key) { + // Already right, however it is laid out: left alone. + Some(m) + if serde_json::from_str::(&out[m.value.0..m.value.1]).ok() + == Some(parsed) => + { + continue + } + Some(m) => (m.value.0, m.value.1, value), + None => insert_member(&out, &ours, key, style, |_| value.clone()), + }; + out = edit_once(&out, edit); + } + } + } + Ok(format!("{bom}{out}")) +} + +/// `text` without the `openxer` entry; every other byte is kept. Text +/// without one is returned as is. +pub fn json_disconnect(text: &str) -> std::result::Result { + json_root(text)?; + let (bom, body) = split_bom(text); + if body.trim().is_empty() { + return Ok(text.to_string()); + } + let root = scan_root(body)?; + let Some(servers) = member_object(body, &root, JSON_SERVERS) else { + return Ok(text.to_string()); + }; + let Some(index) = servers.members.iter().position(|m| m.key == SERVER) else { + return Ok(text.to_string()); + }; + let members = &servers.members; + let ours = &members[index]; + let span = if index > 0 { + // From the end of the server before ours: its comma goes with ours. + (members[index - 1].value.1, ours.value.1) + } else if let Some(next) = members.get(1) { + (ours.key_start, next.key_start) + } else { + (servers.open + 1, servers.close) + }; + Ok(format!( + "{bom}{}", + apply_edits(body, vec![(span.0, span.1, String::new())]) + )) +} + +/// Everything but the `openxer` entry (and an `mcpServers` left empty), for +/// checking a rewrite changed nothing else. +fn json_rest(text: &str) -> Option { + let mut root = json_root(text).ok()?; + if let Some(servers) = root.get_mut(JSON_SERVERS) { + servers.remove(SERVER); + if matches!(servers, J::Object(f) if f.is_empty()) { + root.remove(JSON_SERVERS); + } + } + Some(root) +} + +// ------------------------------------------------------- pure: TOML configs + +const TOML_SERVERS: &str = "mcp_servers"; + +fn toml_doc(text: &str) -> std::result::Result { + let doc: toml_edit::DocumentMut = strip_bom(text) + .parse() + .map_err(|e: toml_edit::TomlError| format!("not valid TOML ({})", e.message()))?; + if doc.get(TOML_SERVERS).is_some_and(|s| !s.is_table_like()) { + return Err(format!("\"{TOML_SERVERS}\" is not a table")); + } + Ok(doc) +} + +/// The `openxer` entry's state in a Codex (`[mcp_servers.openxer]`) config. +pub fn toml_entry(text: &str, cli: &Path, exists: &dyn Fn(&Path) -> bool) -> Entry { + let doc = match toml_doc(text) { + Ok(doc) => doc, + Err(message) => return Entry::Malformed { message }, + }; + let Some(entry) = doc + .get(TOML_SERVERS) + .and_then(|s| s.as_table_like()) + .and_then(|s| s.get(SERVER)) + else { + return Entry::NotConnected; + }; + let Some(entry) = entry.as_table_like() else { + return Entry::Stale { + command: String::new(), + }; + }; + let args = entry.get("args").and_then(|a| a.as_array()).and_then(|a| { + a.iter() + .map(|v| v.as_str().map(str::to_string)) + .collect::>>() + }); + classify( + entry.get("command").and_then(|c| c.as_str()), + args, + cli, + exists, + ) +} + +/// `text` with `[mcp_servers.openxer]` set to run `cli mcp`. Comments, +/// formatting and every other table and key are kept as written. +pub fn toml_connect(text: &str, cli: &Path) -> std::result::Result { + use toml_edit::{value, Array, InlineTable, Item, Table}; + let mut doc = toml_doc(text)?; + let root = doc.as_table_mut(); + if !root.contains_key(TOML_SERVERS) { + let mut servers = Table::new(); + servers.set_implicit(true); + root.insert(TOML_SERVERS, Item::Table(servers)); + } + let servers_item = root.get_mut(TOML_SERVERS).expect("servers table"); + let inline = servers_item.is_inline_table(); + let servers = servers_item.as_table_like_mut().expect("validated table"); + let command = toml_path(&cli.display().to_string()); + let args = Array::from_iter(["mcp"]); + match servers.get_mut(SERVER).and_then(|e| e.as_table_like_mut()) { + Some(entry) => { + set_keeping_decor(entry, "command", command); + set_keeping_decor(entry, "args", args.into()); + } + None => { + servers.remove(SERVER); + if inline { + let mut entry = InlineTable::new(); + entry.insert("command", command); + entry.insert("args", args.into()); + servers.insert(SERVER, value(entry)); + } else { + let mut entry = Table::new(); + entry.insert("command", value(command)); + entry.insert("args", value(args)); + servers.insert(SERVER, Item::Table(entry)); + } + } + } + let mut out = doc.to_string(); + if !out.ends_with('\n') { + out.push('\n'); + } + Ok(out) +} + +/// A path as a TOML string. A literal string (single quotes) keeps every +/// backslash as written, so no escape in it can ever be wrong; a path with +/// a single quote or a control character is a basic string escaped by +/// `toml_edit` instead. +pub fn toml_path(path: &str) -> toml_edit::Value { + let literal_ok = !path.contains('\'') && path.chars().all(|c| c == '\t' || !c.is_control()); + if literal_ok { + if let Ok(mut value) = format!("'{path}'").parse::() { + // The default spacing around it, as for any new value. + value.decor_mut().clear(); + if value.as_str() == Some(path) { + return value; + } + } + } + toml_edit::Value::from(path) +} + +/// Sets `key` in `table`; an existing value is replaced in place, so the +/// key's comments and the value's spacing stay. +fn set_keeping_decor(table: &mut dyn toml_edit::TableLike, key: &str, mut new: toml_edit::Value) { + match table.get_mut(key).and_then(|item| item.as_value_mut()) { + Some(old) => { + *new.decor_mut() = old.decor().clone(); + *old = new; + } + None => { + table.insert(key, toml_edit::Item::Value(new)); + } + } +} + +/// `text` without `[mcp_servers.openxer]`. Text without one is returned as +/// is. +pub fn toml_disconnect(text: &str) -> std::result::Result { + let mut doc = toml_doc(text)?; + let removed = doc + .get_mut(TOML_SERVERS) + .and_then(|s| s.as_table_like_mut()) + .is_some_and(|s| s.remove(SERVER).is_some()); + Ok(if removed { + doc.to_string() + } else { + text.to_string() + }) +} + +fn toml_value(item: &toml_edit::Item) -> Value { + use toml_edit::Item; + match item { + Item::None => Value::Null, + Item::Value(v) => toml_plain(v), + Item::Table(t) => Value::Object( + t.iter() + .map(|(k, v)| (k.to_string(), toml_value(v))) + .collect(), + ), + Item::ArrayOfTables(a) => Value::Array( + a.iter() + .map(|t| { + Value::Object( + t.iter() + .map(|(k, v)| (k.to_string(), toml_value(v))) + .collect(), + ) + }) + .collect(), + ), + } +} + +fn toml_plain(v: &toml_edit::Value) -> Value { + use toml_edit::Value as T; + match v { + T::String(s) => json!(s.value()), + T::Integer(i) => json!(i.value()), + T::Float(f) => json!(f.value().to_string()), + T::Boolean(b) => json!(b.value()), + T::Datetime(d) => json!(d.value().to_string()), + T::Array(a) => Value::Array(a.iter().map(toml_plain).collect()), + T::InlineTable(t) => Value::Object( + t.iter() + .map(|(k, v)| (k.to_string(), toml_plain(v))) + .collect(), + ), + } +} + +/// Everything but the `openxer` entry, as plain values, for checking a +/// rewrite changed nothing else. +fn toml_rest(text: &str) -> Option { + let mut value = toml_value(toml_doc(text).ok()?.as_item()); + if let Some(servers) = value.get_mut(TOML_SERVERS).and_then(Value::as_object_mut) { + servers.remove(SERVER); + if servers.is_empty() { + value.as_object_mut()?.remove(TOML_SERVERS); + } + } + Some(value) +} + +/// The config format of a client's files. +#[derive(Clone, Copy, Debug, PartialEq, Eq)] +pub enum Format { + Json, + Toml, +} + +impl Format { + pub fn entry(self, text: &str, cli: &Path, exists: &dyn Fn(&Path) -> bool) -> Entry { + match self { + Format::Json => json_entry(text, cli, exists), + Format::Toml => toml_entry(text, cli, exists), + } + } + /// The new text for a connect (or disconnect); Err is why the existing + /// text was refused. + pub fn rewrite( + self, + text: &str, + cli: &Path, + disconnect: bool, + ) -> std::result::Result { + match (self, disconnect) { + (Format::Json, false) => json_connect(text, cli), + (Format::Json, true) => json_disconnect(text), + (Format::Toml, false) => toml_connect(text, cli), + (Format::Toml, true) => toml_disconnect(text), + } + } + /// True when `after` differs from `before` only in the `openxer` entry. + pub fn only_entry_changed(self, before: &str, after: &str) -> bool { + match self { + Format::Json => json_rest(before).is_some() && json_rest(before) == json_rest(after), + Format::Toml => toml_rest(before).is_some() && toml_rest(before) == toml_rest(after), + } + } +} + +// --------------------------------------------------------------- file layer + +/// Where to look for clients. Every path is injected: the CLI and the app +/// fill it from the process environment, tests from temporary folders. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct Env { + /// `%APPDATA%` (roaming). + pub appdata: Option, + /// `%LOCALAPPDATA%`. + pub local_appdata: Option, + /// `%USERPROFILE%` (or `HOME`). + pub home: Option, + /// `CODEX_HOME`, when set; else `\.codex`. + pub codex_home: Option, + /// The `PATH` searched for `claude` and `codex`. + pub path: Option, + /// The `openxer-cli` executable clients should run. + pub cli: Option, +} + +impl Env { + /// The process environment, with `cli` as the executable to connect. + pub fn from_process(cli: Option) -> Env { + let var = |name: &str| { + std::env::var_os(name) + .filter(|v| !v.is_empty()) + .map(PathBuf::from) + }; + Env { + appdata: var("APPDATA"), + local_appdata: var("LOCALAPPDATA"), + home: var("USERPROFILE").or_else(|| var("HOME")), + codex_home: var("CODEX_HOME"), + path: std::env::var_os("PATH"), + cli, + } + } + + /// The executable, or the error every connect action reports without it. + pub fn cli(&self) -> Result<&Path> { + self.cli.as_deref().filter(|p| p.is_file()).ok_or_else(|| { + AutomationError::new( + "cli_missing", + format!( + "{CLI_NAME} was not found{}. It ships next to OpenXER.exe; reinstall or copy it there.", + self.cli + .as_ref() + .map(|p| format!(" at {}", p.display())) + .unwrap_or_default() + ), + ) + }) + } + + /// The Microsoft Store packages' folders whose names start with one of + /// `prefixes` (`%LOCALAPPDATA%\Packages\`). + fn packages(&self, prefixes: &[&str]) -> Vec { + let Some(local) = &self.local_appdata else { + return vec![]; + }; + let mut found: Vec = std::fs::read_dir(local.join("Packages")) + .map(|dir| { + dir.filter_map(|e| e.ok()) + .filter(|e| { + let name = e.file_name().to_string_lossy().to_string(); + prefixes.iter().any(|p| name.starts_with(p)) + }) + .map(|e| e.path()) + .filter(|p| p.is_dir()) + .collect() + }) + .unwrap_or_default(); + found.sort(); + found + } + + /// The Microsoft Store installs' Claude folders (`Packages\Claude_*`). + fn claude_packages(&self) -> Vec { + self.packages(&["Claude_"]) + } + + /// Whether the ChatGPT desktop app or the Codex app is installed: a + /// Store package (`OpenAI.ChatGPT*`, `OpenAI.Codex_*`; the Codex + /// runtime packages are not the app) or `%LOCALAPPDATA%\OpenAI\Codex`. + fn openai_app_installed(&self) -> bool { + !self + .packages(&["OpenAI.ChatGPT", "OpenAI.Codex_"]) + .is_empty() + || self + .local_appdata + .as_ref() + .is_some_and(|l| l.join("OpenAI").join("Codex").is_dir()) + } + + fn claude_classic_dir(&self) -> Option { + self.appdata.as_ref().map(|a| a.join("Claude")) + } + + fn claude_classic_installed(&self) -> bool { + self.claude_classic_dir().is_some_and(|d| d.is_dir()) + || self + .local_appdata + .as_ref() + .is_some_and(|l| l.join("AnthropicClaude").is_dir()) + } + + /// The Claude Desktop config files to keep in step: each Store install's + /// own copy, and the classic `%APPDATA%\Claude` file when that install + /// is present or nothing else is. + pub fn claude_desktop_files(&self) -> Vec { + let mut files: Vec = self + .claude_packages() + .into_iter() + .map(|p| { + p.join("LocalCache") + .join("Roaming") + .join("Claude") + .join(CLAUDE_DESKTOP_FILE) + }) + .collect(); + if self.claude_classic_installed() || files.is_empty() { + if let Some(dir) = self.claude_classic_dir() { + files.push(dir.join(CLAUDE_DESKTOP_FILE)); + } + } + files + } + + /// Codex's config, shared by the Codex app and CLI and, as reported, by + /// the ChatGPT desktop app. + pub fn codex_file(&self) -> Option { + self.codex_home + .clone() + .or_else(|| self.home.as_ref().map(|h| h.join(".codex"))) + .map(|d| d.join("config.toml")) + } + + /// The first `name` executable on `PATH`. + pub fn on_path(&self, name: &str) -> Option { + let path = self.path.as_ref()?; + let names: Vec = if cfg!(windows) { + ["exe", "cmd", "bat", "ps1"] + .iter() + .map(|e| format!("{name}.{e}")) + .collect() + } else { + vec![name.to_string()] + }; + std::env::split_paths(path) + .flat_map(|dir| names.iter().map(move |n| dir.join(n))) + .find(|p| p.is_file()) + } + + /// Whether `client` looks installed on this PC. + pub fn found(&self, client: Client) -> bool { + match client { + Client::ClaudeDesktop => { + self.claude_classic_installed() || !self.claude_packages().is_empty() + } + Client::Codex => { + self.codex_file() + .and_then(|f| f.parent().map(Path::is_dir)) + .unwrap_or(false) + || self.openai_app_installed() + || self.on_path("codex").is_some() + } + Client::ClaudeCode => self.on_path("claude").is_some(), + } + } + + /// The config files and format of a client that is connected by editing + /// files. + pub fn files(&self, client: Client) -> (Format, Vec) { + match client { + Client::ClaudeDesktop => (Format::Json, self.claude_desktop_files()), + Client::Codex => (Format::Toml, self.codex_file().into_iter().collect()), + Client::ClaudeCode => (Format::Json, vec![]), + } + } +} + +/// One config file's state. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +pub struct FileStatus { + pub path: PathBuf, + pub exists: bool, + pub entry: Entry, +} + +/// One client's state. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +pub struct ClientStatus { + pub client: Client, + pub name: &'static str, + pub found: bool, + /// The worst state of its files (Claude Code: always not connected, + /// since its own command does the connecting). + pub entry: Entry, + /// The one thing to offer for it (the dialog's button). + pub action: Action, + pub files: Vec, + /// Claude Code's command, when the executable is known. + #[serde(skip_serializing_if = "Option::is_none")] + pub command: Option, +} + +/// The one thing to offer for a client in `entry` state. +pub fn action(client: Client, found: bool, entry: &Entry) -> Action { + if !client.edits_config() { + return if found { + Action::CopyCommand + } else { + Action::NotInstalled + }; + } + match entry { + Entry::Connected => Action::Connected, + Entry::OtherCopy { .. } => Action::UseThisCopy, + Entry::Stale { .. } => Action::Repair, + Entry::Malformed { .. } => Action::FixFile, + Entry::NotConnected if found => Action::Connect, + Entry::NotConnected => Action::NotInstalled, + } +} + +fn read_config(path: &Path) -> Result> { + match std::fs::read(path) { + Ok(bytes) => String::from_utf8(bytes).map(Some).map_err(|_| { + AutomationError::new( + "config_malformed", + format!("{} is not UTF-8 text", path.display()), + ) + }), + Err(e) if e.kind() == std::io::ErrorKind::NotFound => Ok(None), + Err(e) => Err(io_error(path, "read", e)), + } +} + +fn io_error(path: &Path, what: &str, e: std::io::Error) -> AutomationError { + AutomationError::new("io_error", format!("Cannot {what} {}: {e}", path.display())) +} + +/// The state of one client. +pub fn client_status(env: &Env, client: Client) -> ClientStatus { + let cli = env.cli.clone().unwrap_or_default(); + let exists = |p: &Path| p.is_file(); + let (format, paths) = env.files(client); + let files: Vec = paths + .into_iter() + .map(|path| { + let (exists_now, entry) = match read_config(&path) { + Ok(None) => (false, Entry::NotConnected), + Ok(Some(text)) => (true, format.entry(&text, &cli, &exists)), + Err(e) => (true, Entry::Malformed { message: e.message }), + }; + FileStatus { + path, + exists: exists_now, + entry, + } + }) + .collect(); + let entry = files + .iter() + .map(|f| f.entry.clone()) + .max_by_key(Entry::rank) + .unwrap_or(Entry::NotConnected); + let found = env.found(client); + ClientStatus { + client, + name: client.name(), + found, + action: action(client, found, &entry), + entry, + files, + command: (client == Client::ClaudeCode) + .then(|| env.cli.as_deref().map(claude_code_command)) + .flatten(), + } +} + +/// The state of every client. +pub fn status(env: &Env) -> Vec { + Client::ALL.iter().map(|c| client_status(env, *c)).collect() +} + +/// What a connect or disconnect did (or, in a dry run, would do) to one file. +#[derive(Clone, Debug, PartialEq, Eq, Serialize)] +pub struct Change { + pub path: PathBuf, + /// The file is new. + pub created: bool, + /// The text changes. + pub changed: bool, + /// The copy made before the change. + #[serde(skip_serializing_if = "Option::is_none")] + pub backup: Option, + pub before: Entry, + pub after: Entry, + /// The new text (dry run only). + #[serde(skip_serializing_if = "Option::is_none")] + pub preview: Option, +} + +/// `YYYYMMDD-HHMMSS` in UTC. +pub fn timestamp(at: SystemTime) -> String { + let secs = at + .duration_since(UNIX_EPOCH) + .map(|d| d.as_secs()) + .unwrap_or(0) as i64; + let (days, rem) = (secs.div_euclid(86_400), secs.rem_euclid(86_400)); + // Civil date from days since 1970-01-01 (Howard Hinnant's algorithm). + let z = days + 719_468; + let era = z.div_euclid(146_097); + let doe = z - era * 146_097; + let yoe = (doe - doe / 1_460 + doe / 36_524 - doe / 146_096) / 365; + let doy = doe - (365 * yoe + yoe / 4 - yoe / 100); + let mp = (5 * doy + 2) / 153; + let day = doy - (153 * mp + 2) / 5 + 1; + let month = if mp < 10 { mp + 3 } else { mp - 9 }; + let year = yoe + era * 400 + i64::from(month <= 2); + format!( + "{year:04}{month:02}{day:02}-{:02}{:02}{:02}", + rem / 3600, + rem % 3600 / 60, + rem % 60 + ) +} + +/// The backup path for `file` at `stamp`, numbered when that name is taken. +pub fn backup_path(file: &Path, stamp: &str) -> PathBuf { + let base = format!("{}.openxer-backup-{stamp}", file.display()); + let mut candidate = PathBuf::from(&base); + let mut n = 2; + while candidate.exists() { + candidate = PathBuf::from(format!("{base}-{n}")); + n += 1; + } + candidate +} + +/// Writes `text` to `path` through a temporary file in the same folder, so +/// a reader never sees half a file. +fn write_atomic(path: &Path, text: &str) -> Result<()> { + let dir = path.parent().ok_or_else(|| { + AutomationError::new("io_error", format!("{} has no folder", path.display())) + })?; + std::fs::create_dir_all(dir).map_err(|e| io_error(dir, "create", e))?; + let mut tmp = tempfile::Builder::new() + .prefix(".openxer-") + .suffix(".tmp") + .tempfile_in(dir) + .map_err(|e| io_error(dir, "write in", e))?; + tmp.write_all(text.as_bytes()) + .and_then(|()| tmp.as_file().sync_all()) + .map_err(|e| io_error(path, "write", e))?; + tmp.persist(path) + .map_err(|e| io_error(path, "replace", e.error))?; + Ok(()) +} + +/// Connects (or with `disconnect`, disconnects) `client` by editing its +/// config files. Every file is read and its new text worked out before any +/// is written, so a malformed file stops the whole change. Each changed +/// file is backed up first, written atomically, re-read and checked: the +/// entry must be in its new state and everything else unchanged, or the +/// original is put back. `dry_run` returns the changes and new text without +/// writing anything. +pub fn apply(env: &Env, client: Client, disconnect: bool, dry_run: bool) -> Result> { + if !client.edits_config() { + return Err(AutomationError::new( + "unsupported", + "Claude Code is connected with its own command; run `openxer-cli connect claude-code` to print it", + )); + } + let cli = env.cli()?.to_path_buf(); + let exists = |p: &Path| p.is_file(); + let (format, paths) = env.files(client); + if paths.is_empty() { + return Err(AutomationError::new( + "config_unknown", + format!("No config location is known for {}", client.name()), + )); + } + // A Store install that has no config of its own yet sees the classic + // file through its virtual AppData; its new copy starts from that one, + // so the other servers listed there are not hidden. + let classic = env + .claude_classic_dir() + .map(|d| d.join(CLAUDE_DESKTOP_FILE)); + let classic_text = match (&classic, client) { + (Some(path), Client::ClaudeDesktop) => read_config(path)?, + _ => None, + }; + let mut plans = vec![]; + for path in paths { + let current = read_config(&path)?; + let base = match (¤t, &classic_text) { + (Some(text), _) => text.clone(), + (None, Some(text)) if Some(&path) != classic.as_ref() => text.clone(), + (None, _) => String::new(), + }; + let before = match ¤t { + Some(text) => format.entry(text, &cli, &exists), + None => Entry::NotConnected, + }; + let new_text = format.rewrite(&base, &cli, disconnect).map_err(|message| { + AutomationError::new( + "config_malformed", + format!( + "{} was not changed: {message}. Fix the file by hand, or use Copy Setup and add the entry yourself.", + path.display() + ), + ) + })?; + let after = if disconnect { + Entry::NotConnected + } else { + Entry::Connected + }; + // An entry already in its wanted state is left alone, so a file + // formatted by hand is not rewritten for nothing. + let changed = before != after && !(current.is_none() && disconnect); + let read_only = + current.is_some() && std::fs::metadata(&path).is_ok_and(|m| m.permissions().readonly()); + if changed && read_only && !dry_run { + return Err(AutomationError::new( + "config_read_only", + format!( + "{} is read-only, so nothing was changed. Clear Read-only in the file's Properties, then try again.", + path.display() + ), + )); + } + plans.push((path, current, base, new_text, before, after, changed)); + } + let stamp = timestamp(SystemTime::now()); + let mut changes = vec![]; + for (path, current, base, new_text, before, after, changed) in plans { + let mut change = Change { + path: path.clone(), + created: current.is_none() && changed, + changed, + backup: None, + before, + after: after.clone(), + preview: None, + }; + if dry_run { + change.preview = changed.then(|| new_text.clone()); + changes.push(change); + continue; + } + if !changed { + changes.push(change); + continue; + } + if current.is_some() { + let backup = backup_path(&path, &stamp); + std::fs::copy(&path, &backup).map_err(|e| io_error(&backup, "back up to", e))?; + change.backup = Some(backup); + } + write_atomic(&path, &new_text)?; + let reread = read_config(&path)?.unwrap_or_default(); + let entry_ok = format.entry(&reread, &cli, &exists) == after; + if !(entry_ok && format.only_entry_changed(&base, &reread)) { + let restored = match ¤t { + Some(text) => write_atomic(&path, text), + None => std::fs::remove_file(&path).map_err(|e| io_error(&path, "remove", e)), + }; + return Err(AutomationError::new( + "validation_failed", + format!( + "{} did not read back as expected after the change; the original was {}", + path.display(), + if restored.is_ok() { + "put back" + } else { + "kept in the backup" + } + ), + )); + } + changes.push(change); + } + Ok(changes) +} + +/// The message a connect or disconnect ends with. +pub fn finish_message( + client: Client, + disconnect: bool, + changes: &[Change], + dry_run: bool, +) -> String { + if dry_run { + return "Dry run: nothing was written.".into(); + } + if !changes.iter().any(|c| c.changed) { + return if disconnect { + format!("{} was not connected.", client.name()) + } else { + format!("{} is already connected.", client.name()) + }; + } + if disconnect { + format!("Disconnected. Restart {} to finish.", client.name()) + } else { + format!("Connected. {}", client.next_step()) + } +} + +/// What "Connect all found apps" did for one client. +#[derive(Clone, Debug, Serialize)] +pub struct AllResult { + pub client: Client, + pub ok: bool, + pub message: String, + #[serde(skip_serializing_if = "Vec::is_empty")] + pub files: Vec, +} + +/// The clients "Connect all found apps" connects: found, config-editing, +/// and not working (Connect or Repair). One that works, even through +/// another copy of OpenXER, is never repointed. +pub fn connect_all_targets(statuses: &[ClientStatus]) -> Vec { + statuses + .iter() + .filter(|s| s.found && s.action.in_connect_all()) + .map(|s| s.client) + .collect() +} + +/// Connects every client [`connect_all_targets`] names; one failing does +/// not stop the others. +pub fn connect_all(env: &Env, dry_run: bool) -> Vec { + connect_all_targets(&status(env)) + .into_iter() + .map(|client| match apply(env, client, false, dry_run) { + Ok(files) => AllResult { + client, + ok: true, + message: finish_message(client, false, &files, dry_run), + files, + }, + Err(e) => AllResult { + client, + ok: false, + message: e.message, + files: vec![], + }, + }) + .collect() +} + +/// The `openxer-cli` next to `exe` (a test runner's `deps` folder also looks +/// one folder up). `OPENXER_CLI` overrides it. +pub fn resolve_cli(exe: Option<&Path>) -> Option { + if let Some(path) = std::env::var_os("OPENXER_CLI").filter(|v| !v.is_empty()) { + let path = PathBuf::from(path); + return Some(std::path::absolute(&path).unwrap_or(path)); + } + let dir = exe?.parent()?; + let beside = dir.join(CLI_NAME); + if beside.is_file() || dir.file_name().is_none_or(|n| n != "deps") { + return Some(beside); + } + Some(dir.parent()?.join(CLI_NAME)) +} + +/// Starts `cli mcp`, initializes a session and lists its tools; returns how +/// many there are. The process is always stopped before this returns. +pub fn test_connection(cli: &Path, timeout: Duration) -> Result { + if !cli.is_file() { + return Err(AutomationError::new( + "cli_missing", + format!("{} was not found", cli.display()), + )); + } + let mut command = Command::new(cli); + command + .arg("mcp") + .stdin(Stdio::piped()) + .stdout(Stdio::piped()) + .stderr(Stdio::null()); + #[cfg(windows)] + { + use std::os::windows::process::CommandExt; + const CREATE_NO_WINDOW: u32 = 0x0800_0000; + command.creation_flags(CREATE_NO_WINDOW); + } + let mut child = command.spawn().map_err(|e| { + AutomationError::new( + "test_failed", + format!("Cannot start {}: {e}", cli.display()), + ) + })?; + let result = (|| { + let mut stdin = child.stdin.take().expect("piped stdin"); + let stdout = child.stdout.take().expect("piped stdout"); + let (send, receive) = mpsc::channel(); + std::thread::spawn(move || { + for line in BufReader::new(stdout).lines() { + let Ok(line) = line else { break }; + if send.send(line).is_err() { + break; + } + } + }); + let requests = [ + json!({"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"openxer-connect-test","version":crate::VERSION}}}), + json!({"jsonrpc":"2.0","method":"notifications/initialized"}), + json!({"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}), + ]; + for request in requests { + writeln!(stdin, "{request}") + .and_then(|()| stdin.flush()) + .map_err(|e| { + AutomationError::new("test_failed", format!("The server stopped: {e}")) + })?; + } + let deadline = std::time::Instant::now() + timeout; + loop { + let left = deadline.saturating_duration_since(std::time::Instant::now()); + let line = receive.recv_timeout(left).map_err(|e| { + AutomationError::new( + "test_failed", + match e { + mpsc::RecvTimeoutError::Timeout => { + format!("No answer within {} seconds", timeout.as_secs()) + } + mpsc::RecvTimeoutError::Disconnected => { + "The server stopped without answering".into() + } + }, + ) + })?; + let Ok(reply) = serde_json::from_str::(&line) else { + continue; + }; + if let Some(error) = reply.get("error") { + return Err(AutomationError::new( + "test_failed", + format!( + "The server refused the request: {}", + error["message"].as_str().unwrap_or("error") + ), + )); + } + if reply["id"] == json!(2) { + return reply["result"]["tools"] + .as_array() + .map(Vec::len) + .ok_or_else(|| { + AutomationError::new("test_failed", "The tool list was missing") + }); + } + } + })(); + let _ = child.kill(); + let _ = child.wait(); + result +} + +// ---------------------------------------------------------------- CLI glue + +/// What `openxer-cli connect` was asked to do. +#[derive(Clone, Debug, PartialEq, Eq)] +pub enum Request { + Status, + Apply { + client: Client, + disconnect: bool, + dry_run: bool, + }, + /// Connect every found app that is not connected (or needs repair). + All { + dry_run: bool, + }, + ClaudeCode, + Test, + /// The setup prompt for any AI tool that can run commands. + Prompt, +} + +/// Runs a connect request; the result goes in the CLI's JSON envelope. +pub fn run(request: &Request, env: &Env) -> Result { + match request { + Request::Status => Ok(json!({ + "cli": env.cli, + "cli_found": env.cli.as_deref().is_some_and(Path::is_file), + "cli_installed": env.cli.as_deref().is_some_and(|c| is_installed_copy(c, &|p: &Path| p.is_file())), + "clients": status(env), + })), + Request::All { dry_run } => { + env.cli()?; + let results = connect_all(env, *dry_run); + let message = if results.is_empty() { + "Nothing to connect: every app found is already connected, or none was found." + .to_string() + } else { + results + .iter() + .map(|r| format!("{}: {}", r.client.name(), r.message)) + .collect::>() + .join("\n") + }; + Ok(json!({ + "action": "connect_all", + "dry_run": dry_run, + "ok": results.iter().all(|r| r.ok), + "clients": results, + "message": message, + })) + } + Request::Apply { + client, + disconnect, + dry_run, + } => { + let changes = apply(env, *client, *disconnect, *dry_run)?; + Ok(json!({ + "client": client, + "action": if *disconnect { "disconnect" } else { "connect" }, + "dry_run": dry_run, + "changed": changes.iter().any(|c| c.changed), + "files": changes, + "message": finish_message(*client, *disconnect, &changes, *dry_run), + "next_step": (!*disconnect).then(|| client.next_step()), + })) + } + Request::ClaudeCode => { + let cli = env.cli()?; + Ok(json!({ + "client": Client::ClaudeCode, + "found": env.found(Client::ClaudeCode), + "command": claude_code_command(cli), + "message": "Run this command in a terminal; OpenXER does not run it for you.", + })) + } + Request::Prompt => { + let cli = env.cli()?; + Ok(json!({ + "cli": cli, + "prompt": setup_prompt(cli), + "message": "Paste this prompt into an AI tool that can run commands.", + })) + } + Request::Test => { + let cli = env.cli()?; + let tools = test_connection(cli, TEST_TIMEOUT)?; + Ok(json!({"cli": cli, "tools": tools, "message": format!("Working: {tools} tools")})) + } + } +} + +#[cfg(test)] +mod tests; diff --git a/automation/src/connect/tests.rs b/automation/src/connect/tests.rs new file mode 100644 index 0000000..98f8424 --- /dev/null +++ b/automation/src/connect/tests.rs @@ -0,0 +1,1155 @@ +//! Unit tests of the connect module: pure text functions on strings, and +//! the file layer on temporary folders only (never a real client config). +use super::*; +use std::fs; + +fn yes(_: &Path) -> bool { + true +} +fn no(_: &Path) -> bool { + false +} + +fn cli() -> PathBuf { + PathBuf::from(r"C:\Program Files\OpenXER\openxer-cli.exe") +} + +fn parse(text: &str) -> Value { + serde_json::from_str(text.trim_start_matches('\u{feff}')).unwrap() +} + +// ------------------------------------------------------------------- JSON + +#[test] +fn json_connect_into_missing_or_empty_config() { + for text in ["", " \n", "{}", "\u{feff}{}"] { + let out = json_connect(text, &cli()).unwrap(); + assert_eq!( + parse(&out), + json!({"mcpServers":{"openxer":{"command":r"C:\Program Files\OpenXER\openxer-cli.exe","args":["mcp"]}}}), + "{text:?}" + ); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::Connected); + // A blank file gets a whole new text; an object keeps its own end. + assert_eq!(out.ends_with('\n'), text.trim().is_empty(), "{text:?}"); + assert_eq!(out.starts_with('\u{feff}'), text.starts_with('\u{feff}')); + } +} + +/// Every byte outside the `openxer` entry stays as the file had it, in +/// every layout: one line, two or four spaces, tabs, Windows line ends. +#[test] +fn json_connect_and_disconnect_keep_every_other_byte() { + let layouts = [ + r#"{"mcpServers":{"zeta":{"command":"z.exe","args":["-x"]}},"theme":"dark"}"#.to_string(), + "{\n \"mcpServers\": {\n \"zeta\": {\n \"command\": \"z.exe\"\n }\n },\n \"globalShortcut\": \"\"\n}\n".to_string(), + "{\n \"x\": [1,2, 3],\n \"mcpServers\": {\"a\": {}, \"b\": {\"command\": \"b\"}}\n}".to_string(), + "{\n\t\"mcpServers\": {\n\t\t\"zeta\": {\"command\": \"z\"}\n\t}\n}\n".to_string(), + "{\r\n \"mcpServers\": {\r\n \"zeta\": {\"command\": \"z\"}\r\n }\r\n}\r\n".to_string(), + "\u{feff}{ \"mcpServers\" : { \"zeta\" : { } } }".to_string(), + ]; + for text in layouts { + let out = json_connect(&text, &cli()).unwrap(); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::Connected, "{out}"); + assert!(Format::Json.only_entry_changed(&text, &out)); + // Taking the entry out again gives the original back, byte for byte. + assert_eq!(json_disconnect(&out).unwrap(), text, "{out}"); + // The new entry follows the file's line ends. + if text.contains("\r\n") { + assert!(!out.replace("\r\n", "").contains('\n'), "{out:?}"); + } + // Connecting again changes nothing. + assert_eq!(json_connect(&out, &cli()).unwrap(), out); + } + // A two-space file gets a two-space entry, as Claude Desktop writes it. + let pretty = + "{\n \"mcpServers\": {\n \"zeta\": {\n \"command\": \"z.exe\"\n }\n }\n}\n"; + let out = json_connect(pretty, &cli()).unwrap(); + let expected = format!( + "{{\n \"mcpServers\": {{\n \"zeta\": {{\n \"command\": \"z.exe\"\n }},\n \"openxer\": {{\n \"command\": {},\n \"args\": [\n \"mcp\"\n ]\n }}\n }}\n}}\n", + json!(cli().display().to_string()) + ); + assert_eq!(out, expected); + // A file with no servers yet keeps its settings as written. + let settings = "{\n \"theme\": \"dark\",\n \"x\": {\"y\": 1}\n}\n"; + let out = json_connect(settings, &cli()).unwrap(); + assert!(out.starts_with("{\n \"theme\": \"dark\",\n \"x\": {\"y\": 1},\n \"mcpServers\": {\n \"openxer\": {"), "{out}"); + assert!(Format::Json.only_entry_changed(settings, &out)); +} + +#[test] +fn json_disconnect_of_the_first_or_only_server() { + let first = + r#"{"mcpServers":{"openxer":{"command":"x","args":["mcp"]},"other":{"command":"o"}}}"#; + assert_eq!( + json_disconnect(first).unwrap(), + r#"{"mcpServers":{"other":{"command":"o"}}}"# + ); + let only = "{\n \"mcpServers\": {\n \"openxer\": {\"command\": \"x\"}\n }\n}\n"; + assert_eq!( + json_disconnect(only).unwrap(), + "{\n \"mcpServers\": {}\n}\n" + ); + // An entry that is not an object is replaced whole on connect. + let odd = r#"{"mcpServers":{"openxer":5,"b":true}}"#; + let out = json_connect(odd, &cli()).unwrap(); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::Connected); + assert!(out.ends_with(r#","b":true}}"#), "{out}"); + // An entry missing args gets them after its last field. + let partial = format!( + r#"{{"mcpServers":{{"openxer":{{"command":{},"env":{{"A":"1"}}}}}}}}"#, + json!(cli().display().to_string()) + ); + let out = json_connect(&partial, &cli()).unwrap(); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::Connected); + assert!(out.contains(r#""env":{"A":"1"},"args":["mcp"]"#), "{out}"); +} + +/// Paths that are hard to quote read back exactly from both formats; the +/// TOML side writes a literal string whenever the path has no single quote, +/// so no backslash is ever an escape. +#[test] +fn hard_paths_read_back_exactly_from_json_and_toml() { + let paths = [ + r"C:\Program Files\OpenXER\openxer-cli.exe", + r"C:\Users\Zoë Müller\Plant Ünit 2 (Zürich)\openxer-cli.exe", + r"C:\odd\name\", + r"C:\Users\O'Brien\OpenXER\openxer-cli.exe", + r"\\server\share\x\u0041\n\t\openxer-cli.exe", + "C:\\Tab\there\\openxer-cli.exe", + ]; + for path in paths { + let cli = PathBuf::from(path); + let toml = toml_connect(CODEX, &cli).unwrap(); + let doc: toml_edit::DocumentMut = toml.parse().unwrap(); + assert_eq!( + doc["mcp_servers"]["openxer"]["command"].as_str(), + Some(path), + "{toml}" + ); + // TOML literal strings may hold a tab, never a single quote. + let literal = !path.contains('\''); + assert_eq!( + toml.contains(&format!("command = '{path}'")), + literal, + "{toml}" + ); + assert_eq!(toml_entry(&toml, &cli, &yes), Entry::Connected); + for base in ["", "{}", "{\n \"a\": 1\n}\n"] { + let json = json_connect(base, &cli).unwrap(); + assert_eq!( + parse(&json)["mcpServers"]["openxer"]["command"].as_str(), + Some(path) + ); + assert_eq!(json_entry(&json, &cli, &yes), Entry::Connected); + } + } +} + +#[test] +fn another_copy_is_told_apart_from_a_missing_file() { + // An absolute path on this system (a relative one is always stale). + #[cfg(windows)] + let other = r"D:\Portable OpenXER\openxer-cli.exe"; + #[cfg(not(windows))] + let other = "/opt/Portable OpenXER/openxer-cli"; + let text = format!( + r#"{{"mcpServers":{{"openxer":{{"command":{},"args":["mcp"]}}}}}}"#, + json!(other) + ); + // The other copy exists, without the installer's marker: portable. + let exists_no_marker = |p: &Path| !p.ends_with(INSTALLED_MARKER); + assert_eq!( + json_entry(&text, &cli(), &exists_no_marker), + Entry::OtherCopy { + command: other.into(), + installed: false + } + ); + assert_eq!( + json_entry(&text, &cli(), &yes), + Entry::OtherCopy { + command: other.into(), + installed: true + } + ); + // It no longer exists: repair. + let only_ours = |p: &Path| p == cli(); + assert_eq!( + json_entry(&text, &cli(), &only_ours), + Entry::Stale { + command: other.into() + } + ); + // Another copy with other arguments, or a bare name: repair. + let serve = text.replace("[\"mcp\"]", "[\"serve\"]"); + assert!(matches!( + json_entry(&serve, &cli(), &yes), + Entry::Stale { .. } + )); + let bare = r#"{"mcpServers":{"openxer":{"command":"openxer-cli","args":["mcp"]}}}"#; + assert!(matches!( + json_entry(bare, &cli(), &yes), + Entry::Stale { .. } + )); + assert!(Entry::OtherCopy { + command: String::new(), + installed: false + } + .works()); + assert!(!Entry::Stale { + command: String::new() + } + .works()); +} + +#[test] +fn each_state_offers_one_action() { + use Action::*; + let stale = Entry::Stale { + command: "x".into(), + }; + let other = Entry::OtherCopy { + command: "x".into(), + installed: false, + }; + let bad = Entry::Malformed { + message: "m".into(), + }; + for (client, found, entry, expected) in [ + (Client::ClaudeDesktop, true, Entry::NotConnected, Connect), + ( + Client::ClaudeDesktop, + false, + Entry::NotConnected, + NotInstalled, + ), + (Client::ClaudeDesktop, true, Entry::Connected, Connected), + (Client::ClaudeDesktop, false, Entry::Connected, Connected), + (Client::Codex, true, other.clone(), UseThisCopy), + (Client::Codex, true, stale.clone(), Repair), + (Client::Codex, false, stale.clone(), Repair), + (Client::Codex, true, bad.clone(), FixFile), + (Client::ClaudeCode, true, Entry::NotConnected, CopyCommand), + (Client::ClaudeCode, false, Entry::NotConnected, NotInstalled), + ] { + assert_eq!( + action(client, found, &entry), + expected, + "{client:?} {entry:?}" + ); + } + assert!(Connect.in_connect_all() && Repair.in_connect_all()); + for a in [Connected, UseThisCopy, NotInstalled, FixFile, CopyCommand] { + assert!(!a.in_connect_all(), "{a:?}"); + } +} + +#[test] +fn chatgpt_is_another_name_for_the_codex_config() { + assert_eq!(Client::parse("chatgpt"), Some(Client::Codex)); + assert_eq!(Client::parse("codex"), Some(Client::Codex)); + assert_eq!(Client::Codex.name(), "ChatGPT desktop and Codex"); + assert_eq!(Client::Codex.id(), "codex"); + assert_eq!( + Client::ALL[1], + Client::Codex, + "listed right after Claude Desktop" + ); + assert!(Client::ClaudeDesktop + .next_step() + .starts_with("Quit Claude Desktop from its tray icon")); + assert!(Client::ClaudeDesktop + .next_step() + .ends_with("\"Use OpenXER to inspect my schedule.\"")); + let codex = Client::Codex.next_step(); + assert!(codex.starts_with("Restart the app"), "{codex}"); + assert!(codex.contains("Work or Codex mode") && codex.contains("plain Chat may not use tools")); + for c in Client::ALL { + let s = c.next_step(); + assert!(!s.contains('\u{2014}') && !s.contains('\u{2013}')); + } +} + +#[test] +fn json_connect_keeps_other_servers_settings_and_order() { + let text = r#"{ + "theme": "dark", + "mcpServers": { + "zeta": {"command": "z.exe", "args": ["--fast"], "env": {"K": "1"}}, + "alpha": {"command": "a.exe"} + }, + "globalShortcut": "Ctrl+Space", + "nested": {"b": 2, "a": [1, 2.5, null, true]} +}"#; + let out = json_connect(text, &cli()).unwrap(); + let value = parse(&out); + assert_eq!(value["theme"], "dark"); + assert_eq!(value["globalShortcut"], "Ctrl+Space"); + assert_eq!( + value["nested"], + parse(r#"{"b": 2, "a": [1, 2.5, null, true]}"#) + ); + assert_eq!( + value["mcpServers"]["zeta"], + parse(r#"{"command": "z.exe", "args": ["--fast"], "env": {"K": "1"}}"#) + ); + assert_eq!( + value["mcpServers"]["alpha"], + parse(r#"{"command": "a.exe"}"#) + ); + // File order is kept: keys appear in the text in their original order, + // ours last. + let at = |k: &str| out.find(k).unwrap(); + assert!(at("\"theme\"") < at("\"mcpServers\"")); + assert!(at("\"mcpServers\"") < at("\"globalShortcut\"")); + assert!(at("\"zeta\"") < at("\"alpha\"")); + assert!(at("\"alpha\"") < at("\"openxer\"")); + assert!(at("\"b\"") < at("\"a\": [")); + assert!(Format::Json.only_entry_changed(text, &out)); +} + +#[test] +fn json_reconnect_updates_a_stale_path_and_keeps_extra_fields() { + let text = r#"{"mcpServers":{"openxer":{"command":"D:\\old\\openxer-cli.exe","args":["mcp"],"env":{"X":"1"}},"other":{"command":"o"}}}"#; + assert_eq!( + json_entry(text, &cli(), &|p: &Path| p == cli()), + Entry::Stale { + command: r"D:\old\openxer-cli.exe".into() + } + ); + let out = json_connect(text, &cli()).unwrap(); + let value = parse(&out); + assert_eq!( + value["mcpServers"]["openxer"]["command"], + cli().display().to_string() + ); + assert_eq!(value["mcpServers"]["openxer"]["env"], json!({"X":"1"})); + assert_eq!(value["mcpServers"]["other"], json!({"command":"o"})); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::Connected); +} + +#[test] +fn json_disconnect_removes_only_ours() { + let text = r#"{"a":1,"mcpServers":{"other":{"command":"o"},"openxer":{"command":"x","args":["mcp"]}}}"#; + let out = json_disconnect(text).unwrap(); + assert_eq!( + parse(&out), + json!({"a":1,"mcpServers":{"other":{"command":"o"}}}) + ); + assert_eq!(json_entry(&out, &cli(), &yes), Entry::NotConnected); + assert!(Format::Json.only_entry_changed(text, &out)); + // Nothing to remove: the text comes back byte for byte. + let plain = "{ \"a\" : 1 }"; + assert_eq!(json_disconnect(plain).unwrap(), plain); +} + +#[test] +fn json_malformed_input_is_refused() { + for (text, why) in [ + ("{\"mcpServers\": {", "not valid JSON"), + ("[1, 2]", "not a JSON object"), + ("{\"mcpServers\": []}", "is not an object"), + ("// comment\n{}", "not valid JSON"), + ] { + let error = json_connect(text, &cli()).unwrap_err(); + assert!(error.contains(why), "{text:?}: {error}"); + assert!(json_disconnect(text).is_err()); + assert!(matches!( + json_entry(text, &cli(), &yes), + Entry::Malformed { .. } + )); + } +} + +#[test] +fn json_status_detection() { + let entry = |command: &str, args: &str| { + format!( + r#"{{"mcpServers":{{"openxer":{{"command":{},"args":{args}}}}}}}"#, + json!(command) + ) + }; + let ours = cli().display().to_string(); + assert_eq!(json_entry("{}", &cli(), &yes), Entry::NotConnected); + assert_eq!( + json_entry(&entry(&ours, r#"["mcp"]"#), &cli(), &yes), + Entry::Connected + ); + // Case and separators do not matter on Windows. + if cfg!(windows) { + let other_case = ours.to_uppercase().replace('\\', "/"); + assert_eq!( + json_entry(&entry(&other_case, r#"["mcp"]"#), &cli(), &yes), + Entry::Connected + ); + } + // Our path, but the executable is missing: out of date. + assert!(matches!( + json_entry(&entry(&ours, r#"["mcp"]"#), &cli(), &no), + Entry::Stale { .. } + )); + // Other arguments: out of date. + assert!(matches!( + json_entry(&entry(&ours, r#"["serve"]"#), &cli(), &yes), + Entry::Stale { .. } + )); + assert!(matches!( + json_entry(&entry(&ours, "[]"), &cli(), &yes), + Entry::Stale { .. } + )); + assert!(matches!( + json_entry(r#"{"mcpServers":{"openxer":5}}"#, &cli(), &yes), + Entry::Stale { .. } + )); +} + +// ------------------------------------------------------------------- TOML + +const CODEX: &str = r#"# My Codex settings +model = "gpt-x" # inline comment +approval_policy = "on-request" + +[profiles.fast] +model = "small" + +# servers below +[mcp_servers.docs] +command = "npx" +args = ["-y", "docs-server"] # keep me +"#; + +#[test] +fn toml_connect_into_missing_or_empty_config() { + for text in ["", "\n"] { + let out = toml_connect(text, &cli()).unwrap(); + assert!(out.contains("[mcp_servers.openxer]"), "{out}"); + assert_eq!(toml_entry(&out, &cli(), &yes), Entry::Connected); + assert!( + !out.contains("[mcp_servers]\n"), + "no empty parent header: {out}" + ); + } +} + +#[test] +fn toml_connect_preserves_comments_and_formatting() { + let out = toml_connect(CODEX, &cli()).unwrap(); + assert!( + out.starts_with(CODEX), + "everything already there is kept byte for byte:\n{out}" + ); + let added = &out[CODEX.len()..]; + assert!(added.contains("[mcp_servers.openxer]"), "{added}"); + assert!(added.contains("command = "), "{added}"); + assert!(added.contains(r#"args = ["mcp"]"#), "{added}"); + assert_eq!(toml_entry(&out, &cli(), &yes), Entry::Connected); + assert!(Format::Toml.only_entry_changed(CODEX, &out)); + // The command reads back as the exact path. + let doc: toml_edit::DocumentMut = out.parse().unwrap(); + assert_eq!( + doc["mcp_servers"]["openxer"]["command"].as_str(), + Some(cli().display().to_string().as_str()) + ); +} + +#[test] +fn toml_reconnect_updates_a_stale_path_in_place() { + let text = format!( + "{CODEX}\n[mcp_servers.openxer]\n# ours\ncommand = 'D:\\old\\openxer-cli.exe'\nargs = [\"mcp\"]\nstartup_timeout_sec = 30\n\n[after]\nx = 1\n" + ); + assert_eq!( + toml_entry(&text, &cli(), &|p: &Path| p == cli()), + Entry::Stale { + command: r"D:\old\openxer-cli.exe".into() + } + ); + let out = toml_connect(&text, &cli()).unwrap(); + assert_eq!(toml_entry(&out, &cli(), &yes), Entry::Connected); + assert!(out.contains("# ours")); + assert!(out.contains("startup_timeout_sec = 30")); + assert!(out.starts_with(CODEX)); + assert!(out.find("[mcp_servers.openxer]").unwrap() < out.find("[after]").unwrap()); + assert!(Format::Toml.only_entry_changed(&text, &out)); +} + +#[test] +fn toml_disconnect_removes_only_ours() { + let connected = toml_connect(CODEX, &cli()).unwrap(); + let out = toml_disconnect(&connected).unwrap(); + assert_eq!(toml_entry(&out, &cli(), &yes), Entry::NotConnected); + assert!(out.contains("[mcp_servers.docs]")); + assert!(out.contains("# keep me")); + assert!(out.contains("# My Codex settings")); + assert_eq!(out.trim_end(), CODEX.trim_end()); + assert_eq!(toml_disconnect(CODEX).unwrap(), CODEX, "nothing to remove"); +} + +#[test] +fn toml_inline_server_table() { + let text = "mcp_servers = { docs = { command = \"npx\" } }\n"; + let out = toml_connect(text, &cli()).unwrap(); + assert_eq!(toml_entry(&out, &cli(), &yes), Entry::Connected); + assert!(out.contains("docs = { command = \"npx\" }"), "{out}"); + let back = toml_disconnect(&out).unwrap(); + assert_eq!(toml_entry(&back, &cli(), &yes), Entry::NotConnected); + assert!(back.contains("docs")); +} + +#[test] +fn toml_malformed_input_is_refused() { + for (text, why) in [ + ("model = \n", "not valid TOML"), + ("[a\nb = 1", "not valid TOML"), + ("mcp_servers = 3\n", "is not a table"), + ] { + let error = toml_connect(text, &cli()).unwrap_err(); + assert!(error.contains(why), "{text:?}: {error}"); + assert!(toml_disconnect(text).is_err()); + assert!(matches!( + toml_entry(text, &cli(), &yes), + Entry::Malformed { .. } + )); + } +} + +// ------------------------------------------------------------ commands + +#[test] +fn claude_code_command_quotes_paths_with_spaces() { + assert_eq!( + claude_code_command(&cli()), + r#"claude mcp add --scope user openxer -- "C:\Program Files\OpenXER\openxer-cli.exe" mcp"# + ); + assert_eq!( + claude_code_command(Path::new(r"C:\x\openxer-cli.exe")), + r#"claude mcp add --scope user openxer -- "C:\x\openxer-cli.exe" mcp"# + ); +} + +#[test] +fn setup_snippet_is_generic_mcp_json() { + let value = parse(&setup_snippet(&cli())); + assert_eq!( + value, + json!({"mcpServers":{"openxer":{"command":cli().display().to_string(),"args":["mcp"]}}}) + ); +} + +#[test] +fn timestamps_are_utc_civil_dates() { + assert_eq!(timestamp(UNIX_EPOCH), "19700101-000000"); + // 2026-11-07 18:15:02 UTC. + assert_eq!( + timestamp(UNIX_EPOCH + Duration::from_secs(1_794_075_302)), + "20261107-181502" + ); + assert_eq!( + timestamp(UNIX_EPOCH + Duration::from_secs(951_782_400)), + "20000229-000000" + ); +} + +// ---------------------------------------------------------- file layer + +/// A fake user profile in a temporary folder: APPDATA, LOCALAPPDATA, home +/// and PATH all inside it, and a stand-in openxer-cli.exe. +struct Fake { + _dir: tempfile::TempDir, + root: PathBuf, + env: Env, +} + +fn fake() -> Fake { + let dir = tempfile::tempdir().unwrap(); + let root = dir.path().to_path_buf(); + for sub in ["Roaming", "Local", "home", "bin", "app"] { + fs::create_dir_all(root.join(sub)).unwrap(); + } + let cli = root.join("app").join(CLI_NAME); + fs::write(&cli, b"stand-in").unwrap(); + let env = Env { + appdata: Some(root.join("Roaming")), + local_appdata: Some(root.join("Local")), + home: Some(root.join("home")), + codex_home: None, + path: Some(root.join("bin").into_os_string()), + cli: Some(cli), + }; + Fake { + _dir: dir, + root, + env, + } +} + +fn backups(dir: &Path) -> Vec { + fs::read_dir(dir) + .unwrap() + .filter_map(|e| e.ok().map(|e| e.path())) + .filter(|p| p.to_string_lossy().contains(".openxer-backup-")) + .collect() +} + +#[test] +fn nothing_installed_is_not_found_and_not_connected() { + let f = fake(); + for s in status(&f.env) { + assert!(!s.found, "{:?}", s.client); + assert_eq!(s.entry, Entry::NotConnected); + } + // Claude Desktop still has a place to write: the classic folder. + assert_eq!( + f.env.claude_desktop_files(), + vec![f + .root + .join("Roaming") + .join("Claude") + .join(CLAUDE_DESKTOP_FILE)] + ); + assert_eq!( + f.env.codex_file(), + Some(f.root.join("home").join(".codex").join("config.toml")) + ); +} + +#[test] +fn claude_desktop_round_trip_with_backup() { + let f = fake(); + let dir = f.root.join("Roaming").join("Claude"); + fs::create_dir_all(&dir).unwrap(); + let file = dir.join(CLAUDE_DESKTOP_FILE); + let original = + "{\n \"mcpServers\": {\n \"other\": {\"command\": \"o.exe\"}\n },\n \"x\": true\n}\n"; + fs::write(&file, original).unwrap(); + assert!(f.env.found(Client::ClaudeDesktop)); + + let changes = apply(&f.env, Client::ClaudeDesktop, false, false).unwrap(); + assert_eq!(changes.len(), 1); + assert!(changes[0].changed && !changes[0].created); + let backup = changes[0].backup.clone().expect("backup written"); + assert_eq!(fs::read_to_string(&backup).unwrap(), original); + assert!(backup + .file_name() + .unwrap() + .to_string_lossy() + .starts_with("claude_desktop_config.json.openxer-backup-")); + assert_eq!( + client_status(&f.env, Client::ClaudeDesktop).entry, + Entry::Connected + ); + let written = parse(&fs::read_to_string(&file).unwrap()); + assert_eq!(written["mcpServers"]["other"], json!({"command":"o.exe"})); + assert_eq!(written["x"], true); + assert_eq!( + finish_message(Client::ClaudeDesktop, false, &changes, false), + format!("Connected. {}", Client::ClaudeDesktop.next_step()) + ); + // The file differs from the original only by the added entry. + let written_text = fs::read_to_string(&file).unwrap(); + assert!( + written_text.starts_with( + "{\n \"mcpServers\": {\n \"other\": {\"command\": \"o.exe\"},\n \"openxer\": {" + ), + "{written_text}" + ); + assert!( + written_text.ends_with("\n },\n \"x\": true\n}\n"), + "{written_text}" + ); + // No temporary files are left behind. + let leftovers: Vec<_> = fs::read_dir(&dir) + .unwrap() + .filter_map(|e| e.ok()) + .filter(|e| e.file_name().to_string_lossy().ends_with(".tmp")) + .collect(); + assert!(leftovers.is_empty()); + + // Connecting again changes nothing and makes no second backup. + let again = apply(&f.env, Client::ClaudeDesktop, false, false).unwrap(); + assert!(!again[0].changed && again[0].backup.is_none()); + assert_eq!(backups(&dir).len(), 1); + + let removed = apply(&f.env, Client::ClaudeDesktop, true, false).unwrap(); + assert!(removed[0].changed && removed[0].backup.is_some()); + assert_eq!(backups(&dir).len(), 2); + assert_eq!( + client_status(&f.env, Client::ClaudeDesktop).entry, + Entry::NotConnected + ); + assert_eq!( + fs::read_to_string(&file).unwrap(), + original, + "byte for byte" + ); +} + +#[test] +fn connect_creates_a_missing_folder_and_file() { + let f = fake(); + let changes = apply(&f.env, Client::Codex, false, false).unwrap(); + let file = f.root.join("home").join(".codex").join("config.toml"); + assert_eq!(changes[0].path, file); + assert!(changes[0].created && changes[0].backup.is_none()); + assert_eq!(client_status(&f.env, Client::Codex).entry, Entry::Connected); + // Disconnecting a client with no file writes nothing. + let none = apply(&f.env, Client::ClaudeDesktop, true, false).unwrap(); + assert!(!none[0].changed); + assert!(!f.root.join("Roaming").join("Claude").exists()); +} + +#[test] +fn codex_home_overrides_the_profile_folder() { + let mut f = fake(); + let home = f.root.join("codex-elsewhere"); + fs::create_dir_all(&home).unwrap(); + f.env.codex_home = Some(home.clone()); + assert!(f.env.found(Client::Codex)); + assert_eq!(f.env.codex_file(), Some(home.join("config.toml"))); +} + +#[test] +fn malformed_config_is_refused_and_left_unchanged() { + let f = fake(); + let dir = f.root.join("home").join(".codex"); + fs::create_dir_all(&dir).unwrap(); + let file = dir.join("config.toml"); + let broken = "model = \"x\"\n[mcp_servers\n"; + fs::write(&file, broken).unwrap(); + assert!(matches!( + client_status(&f.env, Client::Codex).entry, + Entry::Malformed { .. } + )); + for disconnect in [false, true] { + let error = apply(&f.env, Client::Codex, disconnect, false).unwrap_err(); + assert_eq!(error.code, "config_malformed"); + assert!(error.message.contains("Copy Setup"), "{}", error.message); + } + assert_eq!(fs::read_to_string(&file).unwrap(), broken); + assert!( + backups(&dir).is_empty(), + "no backup of a file that was not changed" + ); +} + +#[test] +fn dry_run_writes_nothing() { + let f = fake(); + let changes = apply(&f.env, Client::Codex, false, true).unwrap(); + assert!(changes[0].changed); + assert!(changes[0] + .preview + .as_deref() + .unwrap() + .contains("[mcp_servers.openxer]")); + assert!(!f.root.join("home").join(".codex").exists()); + assert_eq!( + finish_message(Client::Codex, false, &changes, true), + "Dry run: nothing was written." + ); +} + +#[test] +fn missing_cli_is_a_clear_error() { + let mut f = fake(); + f.env.cli = Some(f.root.join("nowhere").join(CLI_NAME)); + let error = apply(&f.env, Client::Codex, false, false).unwrap_err(); + assert_eq!(error.code, "cli_missing"); + assert!(error.message.contains("nowhere")); + assert!(!f.root.join("home").join(".codex").exists()); + let error = test_connection(&f.root.join("nowhere").join(CLI_NAME), TEST_TIMEOUT).unwrap_err(); + assert_eq!(error.code, "cli_missing"); +} + +#[test] +fn store_install_is_detected_and_kept_in_step() { + let f = fake(); + let package = f + .root + .join("Local") + .join("Packages") + .join("Claude_pzs8sxrjxfjjc"); + fs::create_dir_all(&package).unwrap(); + // An unrelated package is ignored. + fs::create_dir_all( + f.root + .join("Local") + .join("Packages") + .join("ClaudeLike.Other_1"), + ) + .unwrap(); + assert!(f.env.found(Client::ClaudeDesktop)); + let store_file = package + .join("LocalCache") + .join("Roaming") + .join("Claude") + .join(CLAUDE_DESKTOP_FILE); + // Only the Store install: only its copy. + assert_eq!(f.env.claude_desktop_files(), vec![store_file.clone()]); + + // With the classic install too, both files, and a Store copy that does + // not exist yet starts from the classic file's servers. + let classic_dir = f.root.join("Roaming").join("Claude"); + fs::create_dir_all(&classic_dir).unwrap(); + let classic = classic_dir.join(CLAUDE_DESKTOP_FILE); + fs::write(&classic, r#"{"mcpServers":{"other":{"command":"o"}}}"#).unwrap(); + assert_eq!( + f.env.claude_desktop_files(), + vec![store_file.clone(), classic.clone()] + ); + let changes = apply(&f.env, Client::ClaudeDesktop, false, false).unwrap(); + assert_eq!(changes.len(), 2); + assert!(changes[0].created); + let store_value = parse(&fs::read_to_string(&store_file).unwrap()); + assert_eq!(store_value["mcpServers"]["other"], json!({"command":"o"})); + assert_eq!( + client_status(&f.env, Client::ClaudeDesktop).entry, + Entry::Connected + ); + + // One file out of date makes the client out of date. + fs::write( + &store_file, + r#"{"mcpServers":{"openxer":{"command":"old.exe","args":["mcp"]}}}"#, + ) + .unwrap(); + assert!(matches!( + client_status(&f.env, Client::ClaudeDesktop).entry, + Entry::Stale { .. } + )); +} + +#[test] +fn claude_code_is_found_on_path_and_never_edited() { + let f = fake(); + assert!(!f.env.found(Client::ClaudeCode)); + let name = if cfg!(windows) { + "claude.cmd" + } else { + "claude" + }; + fs::write(f.root.join("bin").join(name), b"").unwrap(); + assert!(f.env.found(Client::ClaudeCode)); + let s = client_status(&f.env, Client::ClaudeCode); + assert!(s.files.is_empty()); + assert!(s + .command + .unwrap() + .starts_with("claude mcp add --scope user openxer -- \"")); + assert_eq!( + apply(&f.env, Client::ClaudeCode, false, false) + .unwrap_err() + .code, + "unsupported" + ); +} + +#[test] +fn backup_names_do_not_collide() { + let dir = tempfile::tempdir().unwrap(); + let file = dir.path().join("config.toml"); + let first = backup_path(&file, "20261107-000000"); + fs::write(&first, "").unwrap(); + let second = backup_path(&file, "20261107-000000"); + assert_ne!(first, second); + assert!(second.to_string_lossy().ends_with("-2")); +} + +#[test] +fn resolve_cli_beside_the_executable() { + if std::env::var_os("OPENXER_CLI").is_some() { + return; + } + let dir = tempfile::tempdir().unwrap(); + let exe = dir.path().join("OpenXER.exe"); + assert_eq!(resolve_cli(Some(&exe)), Some(dir.path().join(CLI_NAME))); + let deps = dir.path().join("deps"); + fs::create_dir_all(&deps).unwrap(); + assert_eq!( + resolve_cli(Some(&deps.join("runner.exe"))), + Some(dir.path().join(CLI_NAME)), + "a test runner in deps looks one folder up" + ); + assert_eq!(resolve_cli(None), None); +} + +// ------------------------------------------- a fresh install, end to end + +/// A second copy of OpenXER inside the fake profile; `installed` puts the +/// installer's marker beside it. +fn other_copy(f: &Fake, name: &str, installed: bool) -> PathBuf { + let dir = f.root.join(name); + fs::create_dir_all(&dir).unwrap(); + let cli = dir.join(CLI_NAME); + fs::write(&cli, b"another copy").unwrap(); + if installed { + fs::write(dir.join(INSTALLED_MARKER), b"").unwrap(); + } + cli +} + +fn claude_classic(f: &Fake) -> PathBuf { + let dir = f.root.join("Roaming").join("Claude"); + fs::create_dir_all(&dir).unwrap(); + dir.join(CLAUDE_DESKTOP_FILE) +} + +fn codex_config(f: &Fake) -> PathBuf { + let dir = f.root.join("home").join(".codex"); + fs::create_dir_all(&dir).unwrap(); + dir.join("config.toml") +} + +#[test] +fn an_empty_existing_config_is_connected_and_backed_up() { + let f = fake(); + for (client, file) in [ + (Client::ClaudeDesktop, claude_classic(&f)), + (Client::Codex, codex_config(&f)), + ] { + fs::write(&file, "").unwrap(); + let s = client_status(&f.env, client); + assert_eq!((s.entry, s.action), (Entry::NotConnected, Action::Connect)); + let changes = apply(&f.env, client, false, false).unwrap(); + assert!(changes[0].changed && !changes[0].created); + let backup = changes[0] + .backup + .clone() + .expect("a backup, even of an empty file"); + assert_eq!(fs::read_to_string(backup).unwrap(), ""); + assert_eq!(client_status(&f.env, client).action, Action::Connected); + } +} + +#[test] +fn a_read_only_config_is_refused_and_left_alone() { + let f = fake(); + let file = claude_classic(&f); + let original = r#"{"mcpServers":{"other":{"command":"o"}}}"#; + fs::write(&file, original).unwrap(); + let mut perms = fs::metadata(&file).unwrap().permissions(); + perms.set_readonly(true); + fs::set_permissions(&file, perms.clone()).unwrap(); + let error = apply(&f.env, Client::ClaudeDesktop, false, false).unwrap_err(); + assert_eq!(error.code, "config_read_only"); + assert!(error.message.contains("read-only"), "{}", error.message); + assert_eq!(fs::read_to_string(&file).unwrap(), original); + assert!(backups(file.parent().unwrap()).is_empty()); + // A dry run still shows what would change. + assert!(apply(&f.env, Client::ClaudeDesktop, false, true).unwrap()[0].changed); + #[allow(clippy::permissions_set_readonly_false)] + perms.set_readonly(false); + fs::set_permissions(&file, perms).unwrap(); +} + +#[test] +fn use_this_copy_and_repair_repoint_the_entry() { + let f = fake(); + let portable = other_copy(&f, "portable", false); + let file = claude_classic(&f); + let text = format!( + "{{\n \"mcpServers\": {{\n \"openxer\": {{\n \"command\": {},\n \"args\": [\"mcp\"],\n \"env\": {{\"K\": \"v\"}}\n }}\n }}\n}}\n", + json!(portable.display().to_string()) + ); + fs::write(&file, &text).unwrap(); + let s = client_status(&f.env, Client::ClaudeDesktop); + assert_eq!( + s.entry, + Entry::OtherCopy { + command: portable.display().to_string(), + installed: false + } + ); + assert_eq!(s.action, Action::UseThisCopy); + // Use this copy: only the command changes; env stays. + apply(&f.env, Client::ClaudeDesktop, false, false).unwrap(); + let after = fs::read_to_string(&file).unwrap(); + assert_eq!( + after, + text.replace( + &json!(portable.display().to_string()).to_string(), + &json!(f.env.cli.as_ref().unwrap().display().to_string()).to_string() + ) + ); + assert_eq!( + client_status(&f.env, Client::ClaudeDesktop).action, + Action::Connected + ); + + // The other copy is removed while Codex points at it: repair. + let installed = other_copy(&f, "installed", true); + let codex = codex_config(&f); + fs::write( + &codex, + format!( + "[mcp_servers.openxer]\ncommand = '{}'\nargs = [\"mcp\"]\n", + installed.display() + ), + ) + .unwrap(); + assert!(matches!( + client_status(&f.env, Client::Codex).entry, + Entry::OtherCopy { + installed: true, + .. + } + )); + fs::remove_file(&installed).unwrap(); + let s = client_status(&f.env, Client::Codex); + assert_eq!(s.action, Action::Repair); + apply(&f.env, Client::Codex, false, false).unwrap(); + assert_eq!( + client_status(&f.env, Client::Codex).action, + Action::Connected + ); + let text = fs::read_to_string(&codex).unwrap(); + assert!( + text.contains(&format!( + "command = '{}'", + f.env.cli.as_ref().unwrap().display() + )), + "a literal string: {text}" + ); +} + +#[test] +fn connect_all_connects_the_unconnected_and_never_repoints_a_working_one() { + let f = fake(); + // Claude Desktop found (classic), nothing connected. + let claude = claude_classic(&f); + // Codex found, connected to another copy that works. + let other = other_copy(&f, "installed", true); + let codex = codex_config(&f); + let codex_text = format!( + "# mine\n[mcp_servers.openxer]\ncommand = '{}'\nargs = [\"mcp\"]\n", + other.display() + ); + fs::write(&codex, &codex_text).unwrap(); + assert_eq!( + connect_all_targets(&status(&f.env)), + vec![Client::ClaudeDesktop] + ); + let dry = connect_all(&f.env, true); + assert_eq!(dry.len(), 1); + assert!(!claude.exists(), "a dry run writes nothing"); + let results = connect_all(&f.env, false); + assert_eq!(results.len(), 1); + assert!(results[0].ok, "{}", results[0].message); + assert!( + results[0].message.contains("tray icon"), + "{}", + results[0].message + ); + assert_eq!( + client_status(&f.env, Client::ClaudeDesktop).action, + Action::Connected + ); + assert_eq!(fs::read_to_string(&codex).unwrap(), codex_text, "untouched"); + // Everything done: nothing left to connect. + assert!(connect_all(&f.env, false).is_empty()); + + // One failing (unreadable Claude config) does not stop another. + fs::write(&claude, "{ broken").unwrap(); + fs::write(&codex, "").unwrap(); + let results = connect_all(&f.env, false); + assert_eq!(results.len(), 1, "a malformed file is not a target"); + assert_eq!(results[0].client, Client::Codex); + assert_eq!(fs::read_to_string(&claude).unwrap(), "{ broken"); +} + +#[test] +fn the_chatgpt_and_codex_apps_are_found_by_their_store_packages() { + let f = fake(); + let packages = f.root.join("Local").join("Packages"); + // The runtime package alone is not the app. + fs::create_dir_all(packages.join("OpenAI.CodexPrimaryRuntime.v26-1_3k8")).unwrap(); + assert!(!f.env.found(Client::Codex)); + for name in [ + "OpenAI.ChatGPT-Desktop_2p2nqsd0c76g0", + "OpenAI.Codex_2p2nqsd0c76g0", + ] { + fs::create_dir_all(packages.join(name)).unwrap(); + assert!(f.env.found(Client::Codex), "{name}"); + fs::remove_dir_all(packages.join(name)).unwrap(); + } + fs::create_dir_all(f.root.join("Local").join("OpenAI").join("Codex")).unwrap(); + assert!(f.env.found(Client::Codex)); + // Found, so Connect, and the config is the shared one. + let s = client_status(&f.env, Client::Codex); + assert_eq!(s.action, Action::Connect); + assert_eq!( + s.files[0].path, + f.root.join("home").join(".codex").join("config.toml") + ); +} + +#[test] +fn both_claude_installs_with_other_servers_keep_them() { + let f = fake(); + let package = f + .root + .join("Local") + .join("Packages") + .join("Claude_pzs8sxrjxfjjc"); + let store_dir = package.join("LocalCache").join("Roaming").join("Claude"); + fs::create_dir_all(&store_dir).unwrap(); + let store = store_dir.join(CLAUDE_DESKTOP_FILE); + let store_text = "{\n \"mcpServers\": {\n \"files\": {\"command\": \"f.exe\"}\n },\n \"preferences\": {\"a\": 1}\n}\n"; + fs::write(&store, store_text).unwrap(); + let classic = claude_classic(&f); + let classic_text = "{\"mcpServers\":{\"other\":{\"command\":\"o\"}}}"; + fs::write(&classic, classic_text).unwrap(); + let changes = apply(&f.env, Client::ClaudeDesktop, false, false).unwrap(); + assert_eq!(changes.len(), 2); + assert!(changes.iter().all(|c| c.backup.is_some())); + for (file, original) in [(&store, store_text), (&classic, classic_text)] { + let now = fs::read_to_string(file).unwrap(); + assert_eq!( + json_disconnect(&now).unwrap(), + original, + "byte for byte apart from ours" + ); + } +} + +#[test] +fn the_setup_prompt_names_this_copy_and_only_real_commands() { + let prompt = setup_prompt(&cli()); + // The same quoted path as the Claude Code command. + let quoted = format!("\"{}\"", cli().display()); + assert!(claude_code_command(&cli()).contains("ed)); + assert!(prompt.contains("ed), "{prompt}"); + for part in [ + "--help", + "named openxer", + "single argument mcp", + "every command prints JSON", + "connect test", + "Working: N tools", + "never changes an input file", + "--output", + "--dry-run", + FIRST_PROMPT, + ] { + assert!(prompt.contains(part), "{part} in {prompt}"); + } + // The cited flags and commands exist in --help. + for command in ["connect test", "--dry-run", "--output", "mcp"] { + assert!(crate::cli::HELP.contains(command), "{command} in --help"); + } + assert!(!prompt.contains('\u{2014}') && !prompt.contains('\u{2013}')); + // The CLI prints the same text. + let dir = tempfile::tempdir().unwrap(); + let exe = dir.path().join(CLI_NAME); + fs::write(&exe, b"").unwrap(); + let env = Env { + cli: Some(exe.clone()), + ..Env::default() + }; + let out = run(&Request::Prompt, &env).unwrap(); + assert_eq!(out["prompt"], setup_prompt(&exe)); + assert!( + run(&Request::Prompt, &Env::default()).is_err(), + "no CLI, no prompt" + ); +} diff --git a/automation/src/documents.rs b/automation/src/documents.rs new file mode 100644 index 0000000..c972300 --- /dev/null +++ b/automation/src/documents.rs @@ -0,0 +1,527 @@ +//! Documents for agents: the `documents` command lists a project's work +//! products and documents with their links, and `read_document` returns the +//! text of the file a document record points at. Both are read-only. +//! +//! A file is only ever addressed through a document of the project, never by +//! a free path. Its location passes the same check as the WPs & Docs view's +//! Launch (`openxer_xer::edit::documents::local_file`): an existing regular +//! file named by an absolute local path (on a drive letter on Windows, from +//! `/` elsewhere); relative, network, +//! device and web locations are refused. Programs and scripts are refused by +//! type. Plain text formats are returned as text, PDF text is extracted page +//! by page, and Word (.docx) text is read from its XML. Large files are paged. +//! +//! A schedule received from someone else can name any local file in its +//! document rows, and an agent reads without a person clicking Launch. So a +//! file is read only from under the input file's own folder, or a folder +//! named in [`ROOTS_VAR`]. +use crate::{AutomationError, Result}; +use openxer_xer::edit::documents::{self as docs, Doc}; +use openxer_xer::ProjectData; +use serde_json::{json, Value}; +use std::collections::BTreeMap; +use std::io::Read; +use std::path::{Path, PathBuf}; + +/// The environment variable naming more folders (separated as in `PATH`: +/// `;` on Windows, `:` elsewhere) whose files `read_document` may read, +/// besides the input file's own folder. +pub const ROOTS_VAR: &str = "OPENXER_DOCUMENT_ROOTS"; + +/// The separator between the folders in [`ROOTS_VAR`], as +/// `std::env::split_paths` reads them. +const ROOTS_SEPARATOR: char = if cfg!(windows) { ';' } else { ':' }; + +/// A folder or file as its canonical path (on Windows a drive path without +/// the `\\?\` prefix), as `local_file` reports the document's file. +fn canonical(path: &Path) -> Option { + let full = std::fs::canonicalize(path).ok()?; + let text = full.to_string_lossy(); + Some(match text.strip_prefix("\\\\?\\") { + Some(rest) => PathBuf::from(rest), + None => full, + }) +} + +/// The folders documents may be read from: the input file's folder and +/// every folder in [`ROOTS_VAR`]. +fn allowed_roots(input: &Path) -> Vec { + let folder = input + .parent() + .filter(|p| !p.as_os_str().is_empty()) + .unwrap_or(Path::new(".")); + let mut roots: Vec = canonical(folder).into_iter().collect(); + if let Some(extra) = std::env::var_os(ROOTS_VAR) { + roots.extend( + std::env::split_paths(&extra) + .filter(|p| !p.as_os_str().is_empty()) + .filter_map(|p| canonical(&p)), + ); + } + roots +} + +/// Largest file read at all. +pub const MAX_FILE_BYTES: u64 = 64 * 1024 * 1024; +/// Characters returned by default, and at most, per call. +pub const DEFAULT_LIMIT: usize = 20_000; +pub const MAX_LIMIT: usize = 200_000; +/// PDF pages returned by default, and at most, per call. +pub const DEFAULT_PAGES: usize = 10; +pub const MAX_PAGES: usize = 100; + +/// Types read as text. +pub const TEXT_TYPES: [&str; 6] = ["txt", "md", "csv", "json", "xml", "log"]; +/// Programs and scripts: never read. +pub const REFUSED_TYPES: [&str; 9] = ["exe", "bat", "cmd", "ps1", "js", "vbs", "msi", "com", "scr"]; + +fn err(code: &str, message: impl Into) -> AutomationError { + AutomationError::new(code, message) +} + +/// A WBS element's path and name. +fn wbs_json(p: &ProjectData, id: i64) -> Value { + let name = p + .wbs + .iter() + .find(|w| w.id == id) + .map_or("", |w| w.name.as_str()); + json!({"wbs":docs::wbs_path(p, id),"name":name}) +} + +fn activity_of(p: &ProjectData, task_id: i64) -> Option<(String, String)> { + let a = p.model.activities.iter().find(|a| a.task_id == task_id)?; + let name = p.details.get(&task_id).map_or("", |d| d.name.as_str()); + Some((a.task_code.clone(), name.to_string())) +} + +fn document_json(p: &ProjectData, d: &Doc, all: &[Doc]) -> Value { + let mut activities = vec![]; + let mut wbs = vec![]; + for l in docs::links(p, d.id) { + if l.task_id != 0 { + if let Some((code, name)) = activity_of(p, l.task_id) { + activities.push(json!({"activity":code,"name":name,"work_product":l.work_product})); + } + } else if l.wbs_id != 0 { + let mut w = wbs_json(p, l.wbs_id); + w["work_product"] = json!(l.work_product); + wbs.push(w); + } + } + let parent = d + .parent + .and_then(|id| all.iter().find(|x| x.id == id)) + .map(|x| json!({"document_id":x.id,"title":x.title,"reference":x.reference})); + json!({ + "document_id": d.id, + "title": d.title, + "reference": d.reference, + "parent": parent, + "deliverable": d.deliverable, + "status": d.status, + "category": d.category, + "author": d.author, + "version": d.version, + "date": d.date, + "private_location": d.private_loc, + "public_location": d.public_loc, + "description": d.description, + "activities": activities, + "wbs": wbs, + }) +} + +/// The project's documents, or only those linked to `activity` (Activity +/// ID) or to the WBS element `wbs` (path) itself. +pub fn list(p: &ProjectData, activity: Option<&str>, wbs: Option<&str>) -> Result { + let all = docs::list(p); + let task = match activity { + Some(code) => Some( + p.model + .activities + .iter() + .find(|a| a.task_code == code) + .map(|a| a.task_id) + .ok_or_else(|| err("not_found", format!("No activity {code:?}.")))?, + ), + None => None, + }; + let element = match wbs { + Some(path) => Some( + openxer_xer::edit::wbs::find_path(p, path) + .ok_or_else(|| err("not_found", format!("No WBS element {path:?}.")))?, + ), + None => None, + }; + let shown: Vec = all + .iter() + .filter(|d| { + let links = docs::links(p, d.id); + task.is_none_or(|t| links.iter().any(|l| l.task_id == t)) + && element.is_none_or(|w| links.iter().any(|l| l.task_id == 0 && l.wbs_id == w)) + }) + .map(|d| document_json(p, d, &all)) + .collect(); + Ok( + json!({"count":shown.len(),"total_documents":all.len(),"documents":shown, + "statuses":docs::statuses(p).into_iter().map(|(_, n)| n).collect::>(), + "categories":docs::categories(p).into_iter().map(|(_, n)| n).collect::>()}), + ) +} + +/// Linked documents by activity, for the activity rows of `load`: +/// task id to `[{document_id, title, reference, work_product}]`. +pub fn by_activity(p: &ProjectData) -> BTreeMap> { + let mut out: BTreeMap> = BTreeMap::new(); + for d in docs::list(p) { + for l in docs::links(p, d.id).into_iter().filter(|l| l.task_id != 0) { + out.entry(l.task_id).or_default().push(json!({ + "document_id": d.id, "title": d.title, "reference": d.reference, + "work_product": l.work_product, + })); + } + } + out +} + +/// How a file's text is read. +#[derive(Clone, Copy, Debug, PartialEq, Eq)] +enum Kind { + Text, + Pdf, + Docx, +} + +fn kind_of(path: &str) -> std::result::Result { + let ext = docs::extension(path).unwrap_or_default(); + if REFUSED_TYPES.contains(&ext.as_str()) { + return Err(( + "refused_type".into(), + format!("Programs and scripts (.{ext}) are never read."), + )); + } + if TEXT_TYPES.contains(&ext.as_str()) { + return Ok(Kind::Text); + } + match ext.as_str() { + "pdf" => Ok(Kind::Pdf), + "docx" => Ok(Kind::Docx), + "" => Err(( + "unsupported_type".into(), + "The file has no type (extension); only txt, md, csv, json, xml, log, pdf and docx are read.".into(), + )), + other => Err(( + "unsupported_type".into(), + format!( + "Files of type .{other} are not read; only txt, md, csv, json, xml, log, pdf and docx are." + ), + )), + } +} + +/// Paging asked for: characters for text, pages for PDF. +#[derive(Clone, Copy, Debug, Default)] +pub struct Paging { + pub offset: Option, + pub limit: Option, + pub page: Option, + pub pages: Option, +} + +/// The text of document `document`'s linked file (`location`: private or +/// public; by default the private location when it is set, else the public +/// one). +pub fn read( + p: &ProjectData, + input: &Path, + document: &str, + location: Option<&str>, + paging: Paging, +) -> Result { + let id = docs::find(p, document).map_err(|e| err("document_not_found", e))?; + let all = docs::list(p); + let d = all.iter().find(|d| d.id == id).expect("found above"); + let (which, stored) = match location.map(str::to_ascii_lowercase).as_deref() { + Some("private") => ("private", d.private_loc.clone()), + Some("public") => ("public", d.public_loc.clone()), + None if !d.private_loc.trim().is_empty() => ("private", d.private_loc.clone()), + None => ("public", d.public_loc.clone()), + Some(other) => { + return Err(err( + "invalid_arguments", + format!("location is private or public, not {other:?}"), + )) + } + }; + if stored.trim().is_empty() { + return Err(err( + "no_location", + format!("Document {:?} has no {which} location.", d.title), + )); + } + let limit = paging.limit.unwrap_or(DEFAULT_LIMIT); + if !(1..=MAX_LIMIT).contains(&limit) { + return Err(err( + "invalid_arguments", + format!("limit must be 1..{MAX_LIMIT} characters"), + )); + } + // The type is checked before the location, so a program is refused as + // a program whatever its location. + let kind = kind_of(stored.trim()).map_err(|(c, m)| err(&c, m))?; + let allowed = |path: &str| kind_of(path).map(|_| ()).map_err(|(_, m)| m); + let path = docs::local_file(&stored, &allowed).map_err(|why| { + err( + "location_refused", + format!("The {which} location {stored:?} is not read: {why}"), + ) + })?; + // The resolved file must be of the same kind (a link to another type). + if kind_of(&path).ok() != Some(kind) { + return Err(err( + "location_refused", + "The location resolves to a file of another type.", + )); + } + let roots = allowed_roots(input); + if !roots.iter().any(|root| Path::new(&path).starts_with(root)) { + let folder = roots + .first() + .map_or_else(|| "?".into(), |r| r.display().to_string()); + return Err(err( + "location_refused", + format!( + "The {which} location {path:?} is outside the input file's folder ({folder}); documents are read only from there. To allow another folder, set the environment variable {ROOTS_VAR} to it (several folders separated by {ROOTS_SEPARATOR}) for the openxer-cli or MCP server process." + ), + )); + } + let size = std::fs::metadata(&path) + .map_err(|e| err("read_failed", e.to_string()))? + .len(); + if size > MAX_FILE_BYTES { + return Err(err( + "file_too_large", + format!("The file is {size} bytes; files over {MAX_FILE_BYTES} bytes are not read."), + )); + } + let bytes = std::fs::read(&path).map_err(|e| err("read_failed", e.to_string()))?; + let head = json!({"document_id":d.id,"title":d.title,"reference":d.reference}); + match kind { + Kind::Text | Kind::Docx => { + if paging.page.is_some() || paging.pages.is_some() { + return Err(err( + "invalid_arguments", + "page and pages are for PDF files; use offset and limit", + )); + } + let text = if kind == Kind::Text { + decode(&bytes) + } else { + docx_text(&bytes)? + }; + let chars: Vec = text.chars().collect(); + let offset = paging.offset.unwrap_or(0); + if offset > chars.len() { + return Err(err( + "invalid_arguments", + format!( + "offset {offset} is past the end ({} characters)", + chars.len() + ), + )); + } + let end = offset.saturating_add(limit).min(chars.len()); + let slice: String = chars[offset..end].iter().collect(); + Ok(json!({"document":head,"location":which,"path":path, + "format":if kind == Kind::Text { "text" } else { "docx" }, + "bytes":size,"total_characters":chars.len(),"offset":offset, + "next_offset":(end < chars.len()).then_some(end),"text":slice})) + } + Kind::Pdf => { + if paging.offset.is_some() { + return Err(err( + "invalid_arguments", + "offset is for text files; use page and pages for PDF", + )); + } + pdf_pages(&bytes, paging, limit).map(|mut v| { + v["document"] = head; + v["location"] = json!(which); + v["path"] = json!(path); + v["bytes"] = json!(size); + v + }) + } + } +} + +/// Text from UTF-8 (with or without a byte order mark) or UTF-16 with a +/// byte order mark; anything else as Windows-1252. +fn decode(bytes: &[u8]) -> String { + if let Some(rest) = bytes.strip_prefix(&[0xEF, 0xBB, 0xBF]) { + return String::from_utf8_lossy(rest).into_owned(); + } + let utf16 = |rest: &[u8], le: bool| { + let units: Vec = rest + .as_chunks::<2>() + .0 + .iter() + .map(|&c| { + if le { + u16::from_le_bytes(c) + } else { + u16::from_be_bytes(c) + } + }) + .collect(); + String::from_utf16_lossy(&units) + }; + if let Some(rest) = bytes.strip_prefix(&[0xFF, 0xFE]) { + return utf16(rest, true); + } + if let Some(rest) = bytes.strip_prefix(&[0xFE, 0xFF]) { + return utf16(rest, false); + } + match std::str::from_utf8(bytes) { + Ok(s) => s.to_string(), + Err(_) => encoding_rs::WINDOWS_1252.decode(bytes).0.into_owned(), + } +} + +/// The body text of a Word document: `word/document.xml`, one line per +/// paragraph, tabs and breaks kept. +fn docx_text(bytes: &[u8]) -> Result { + use quick_xml::events::Event; + let bad = |e: String| err("read_failed", format!("The .docx cannot be read: {e}")); + let mut zip = + zip::ZipArchive::new(std::io::Cursor::new(bytes)).map_err(|e| bad(e.to_string()))?; + let mut entry = zip + .by_name("word/document.xml") + .map_err(|e| bad(e.to_string()))?; + // The XML is bounded too: a small zip can inflate to a huge part. + let mut xml = String::new(); + entry + .by_ref() + .take(MAX_FILE_BYTES * 4) + .read_to_string(&mut xml) + .map_err(|e| bad(e.to_string()))?; + let mut reader = quick_xml::Reader::from_str(&xml); + let mut out = String::new(); + let mut in_text = false; + loop { + match reader.read_event() { + Ok(Event::Start(e)) if e.local_name().into_inner() == "t" => in_text = true, + Ok(Event::End(e)) => match e.local_name().into_inner() { + "t" => in_text = false, + "p" => out.push('\n'), + _ => {} + }, + Ok(Event::Empty(e)) => match e.local_name().into_inner() { + "tab" => out.push('\t'), + "br" | "cr" => out.push('\n'), + "p" => out.push('\n'), + _ => {} + }, + Ok(Event::Text(t)) if in_text => out.push_str(&t.xml10_content()), + Ok(Event::GeneralRef(r)) if in_text => { + if let Ok(Some(c)) = r.resolve_char_ref() { + out.push(c); + } else { + out.push_str(match r.xml10_content().as_ref() { + "amp" => "&", + "lt" => "<", + "gt" => ">", + "quot" => "\"", + "apos" => "'", + _ => "", + }); + } + } + Ok(Event::Eof) => break, + Err(e) => return Err(bad(e.to_string())), + _ => {} + } + } + Ok(out) +} + +/// Pages `page..page + pages` (1-based) of a PDF, each extracted on its +/// own, stopping early at `limit` characters. +fn pdf_pages(bytes: &[u8], paging: Paging, limit: usize) -> Result { + let first = paging.page.unwrap_or(1); + let count = paging.pages.unwrap_or(DEFAULT_PAGES); + if first == 0 || !(1..=MAX_PAGES).contains(&count) { + return Err(err( + "invalid_arguments", + format!("page starts at 1 and pages must be 1..{MAX_PAGES}"), + )); + } + // The extractor is not hardened against every malformed file; a panic + // in it is a read failure, not a crash of the server. + let bytes = bytes.to_vec(); + let run = std::panic::catch_unwind(move || -> std::result::Result { + let doc = pdf_extract::Document::load_mem(&bytes).map_err(|e| e.to_string())?; + if doc.is_encrypted() { + return Err("the PDF is encrypted".into()); + } + let numbers: Vec = doc.get_pages().keys().copied().collect(); + let total = numbers.len(); + let mut pages = vec![]; + let mut used = 0; + let mut next = None; + let mut truncated = false; + for (k, n) in numbers.iter().enumerate().skip(first - 1).take(count) { + if used >= limit { + next = Some(k + 1); + break; + } + let mut text = String::new(); + { + let mut out = pdf_extract::PlainTextOutput::new(&mut text); + pdf_extract::output_doc_page(&doc, &mut out, *n).map_err(|e| e.to_string())?; + } + let room = limit - used; + let whole = text.chars().count(); + let text: String = text.chars().take(room).collect(); + used += text.chars().count(); + if whole > room { + // The rest of this page is not returned: say so, and + // continue at this page (a larger limit reads it whole). + pages.push(json!({"page":k + 1,"text":text,"truncated":true, + "page_characters":whole})); + truncated = true; + next = Some(k + 1); + break; + } + pages.push(json!({"page":k + 1,"text":text})); + } + let last = first - 1 + pages.len(); + if next.is_none() && last < total { + next = Some(last + 1); + } + Ok( + json!({"format":"pdf","page_count":total,"page":first,"pages":pages, + "next_page":next,"characters":used,"truncated":truncated}), + ) + }); + match run { + Ok(Ok(v)) => { + if first > v["page_count"].as_u64().unwrap_or(0) as usize && first != 1 { + return Err(err( + "invalid_arguments", + format!("page {first} is past the last page ({})", v["page_count"]), + )); + } + Ok(v) + } + Ok(Err(e)) => Err(err( + "read_failed", + format!("The PDF text cannot be extracted: {e}"), + )), + Err(_) => Err(err( + "read_failed", + "The PDF text cannot be extracted (the file is malformed or uses a feature the reader does not handle).", + )), + } +} diff --git a/automation/src/edit.rs b/automation/src/edit.rs new file mode 100644 index 0000000..e96d758 --- /dev/null +++ b/automation/src/edit.rs @@ -0,0 +1,3545 @@ +//! Typed edit operations for `openxer-cli apply`, the single-operation edit +//! commands and their MCP tools (format `openxer-changes/1`). +//! +//! Operations name things the way an agent sees them: Activity ID, resource +//! short name, calendar name and WBS path. Durations are hours, dates are +//! project-local `YYYY-MM-DD HH:MM`, and enum values accept XER codes +//! (`TT_Task`, `CS_ALAP`, `DT_FixedDUR2`) or display names. +//! +//! Every edit goes through `openxer_xer::edit`, the same setters the desktop +//! uses, so the command line, MCP and the app cannot behave differently. A +//! batch runs on a copy of the project in file order; the first failure +//! leaves the caller's project unchanged. +//! +//! With `recalculate` false ("apply exactly") `set_activity` and +//! `set_assignment` write each value into its XER column as given, with no +//! duration type, units or cost knock-on; the project is then re-read from +//! those columns. Scheduling still runs normally. +use crate::{schedule_project, AutomationError, Result, SchedulePatch}; +use openxer_engine::model::LinkType; +use openxer_xer::assignments::AssignmentEdit as AE; +use openxer_xer::calendar_data::Shift; +use openxer_xer::edit::activity::{self as act, Edit}; +use openxer_xer::edit::project_records::{self, Kind}; +use openxer_xer::edit::tables::{self, serde_like::Value as Cell}; +use openxer_xer::edit::{ + calendars, curves, documents, earned_value, funding, progress, records, relationships, + resources, steps, thresholds, wbs, +}; +use openxer_xer::{parse_relative, Document, ProjectData}; +use serde::Deserialize; +use serde_json::{json, Map, Value}; +use std::collections::{BTreeMap, BTreeSet}; + +pub const FORMAT: &str = "openxer-changes/1"; +/// Largest batch one apply takes. +pub const MAX_OPERATIONS: usize = 100_000; + +/// A changes file. Other top-level keys (`source`, `expect`, notes) are +/// carried for people and checks and never applied. +#[derive(Debug, Clone, Deserialize)] +pub struct Changes { + pub format: String, + /// Default for every operation: true runs the setters' rules, false + /// writes values exactly. + #[serde(default)] + pub recalculate: Option, + #[serde(deserialize_with = "operations")] + pub operations: Vec, +} + +/// Each operation may carry a free-form `meta` object (provenance: source, +/// evidence, written_by, basis...). It is kept out of the operation itself; +/// every other unknown field is refused. +pub fn operation(mut value: Value) -> std::result::Result { + if let Some(map) = value.as_object_mut() { + if let Some(meta) = map.remove("meta") { + if !meta.is_object() { + return Err("meta must be an object".into()); + } + } + } + serde_json::from_value(value).map_err(|e| e.to_string()) +} + +fn operations<'de, D>(d: D) -> std::result::Result, D::Error> +where + D: serde::Deserializer<'de>, +{ + let list = Vec::::deserialize(d)?; + list.into_iter() + .enumerate() + .map(|(n, v)| { + operation(v).map_err(|e| serde::de::Error::custom(format!("operation {}: {e}", n + 1))) + }) + .collect() +} + +/// Absent stays `None`; a present value, null included, is `Some`. +fn present<'de, D>(d: D) -> std::result::Result, D::Error> +where + D: serde::Deserializer<'de>, +{ + Value::deserialize(d).map(Some) +} + +/// Every operation name, in the order of [`Operation`] (the MCP +/// `openxer_apply` description lists them; a test checks the two agree). +pub const OPERATIONS: &[&str] = &[ + "set_project", + "add_wbs", + "add_activity", + "delete_activity", + "dissolve_activity", + "set_activity", + "assign_resource", + "remove_assignment", + "set_assignment", + "relationship", + "calendar_day", + "calendar_weekday", + "schedule", + "set_resource_limit", + "set_activity_code", + "set_project_code", + "add_code_type", + "add_code_value", + "set_code_value", + "delete_code_value", + "set_notebook", + "set_wbs_notebook", + "set_udf", + "add_calendar", + "set_calendar", + "delete_calendar", + "add_resource", + "set_resource", + "set_wbs", + "set_schedule_option", + "add_project_funding", + "set_project_funding", + "delete_project_funding", + "delete_resource", + "merge_resources", + "set_wbs_earned_value", + "add_document", + "set_document", + "delete_document", + "link_document", + "unlink_document", + "add_expense", + "set_expense", + "delete_expense", + "add_issue", + "set_issue", + "delete_issue", + "add_risk", + "set_risk", + "delete_risk", + "assign_risk", + "unassign_risk", + "add_threshold", + "set_threshold", + "delete_threshold", + "monitor_thresholds", + "update_progress", + "top_down_estimate", + "shift_wbs", + "rename_wbs_code", + "rename_calendar", + "set_default_calendar", + "convert_calendar", + "copy_calendar", + "add_step", + "set_step", + "delete_step", + "move_step", + "add_steps_from_template", + "create_step_template", + "set_feedback", + "apply_actuals", + "recalculate_costs", + "delete_financial_period", + "global_change", +]; + +/// One edit. New kinds of edits (activity codes, UDF values, notebook +/// topics, resource limits) are new variants here and in [`apply_one`], +/// named the same way: resource short name, code type name and value, +/// topic name. +#[derive(Debug, Clone, Deserialize)] +#[serde(tag = "op", rename_all = "snake_case", deny_unknown_fields)] +pub enum Operation { + /// `data_date` stores the new data date; `schedule: true` also schedules + /// at it right away (as a schedule run before progress is entered). + SetProject { + field: String, + value: Value, + #[serde(default)] + schedule: Option, + }, + AddWbs { + wbs: String, + #[serde(default)] + name: Option, + }, + /// Without `wbs` the activity goes under the WBS element of `selected`, + /// else the project's first WBS element until a `set_activity wbs` + /// moves it. Without `activity` its ID comes from the project's + /// auto-numbering defaults, `selected` standing for the activity + /// selected in the app. + AddActivity { + #[serde(default)] + activity: Option, + #[serde(default)] + selected: Option, + #[serde(default)] + name: Option, + #[serde(default)] + wbs: Option, + }, + DeleteActivity { + activity: String, + }, + /// Edit > Dissolve: remove the activity and tie each predecessor to each + /// successor (`openxer_xer::edit::dissolve`). `retain_lag` (default + /// false) gives the new relationships the two old lags added. + DissolveActivity { + activity: String, + #[serde(default)] + retain_lag: Option, + }, + SetActivity { + activity: String, + field: String, + value: Value, + #[serde(default)] + recalculate: Option, + }, + AssignResource { + activity: String, + resource: String, + }, + RemoveAssignment { + activity: String, + resource: String, + }, + SetAssignment { + activity: String, + resource: String, + field: String, + value: Value, + #[serde(default)] + recalculate: Option, + }, + Relationship { + action: String, + predecessor: String, + successor: String, + kind: String, + #[serde(default)] + lag_hours: Option, + #[serde(default)] + comments: Option, + }, + /// `shifts` null puts the date back on its weekday pattern; `[]` makes + /// it nonwork. + CalendarDay { + calendar: String, + date: String, + #[serde(default)] + shifts: Option>, + }, + /// `weekday` 0 is Sunday. + CalendarWeekday { + calendar: String, + weekday: usize, + shifts: Vec<[String; 2]>, + }, + /// `level_resources` left out keeps the loaded setting. + Schedule { + #[serde(default)] + level_resources: Option, + }, + /// One resource rate row: the limit and prices from a date. + /// `max_units_per_hour: null` removes the row. + SetResourceLimit { + resource: String, + from: String, + #[serde(default)] + shift_period: Option, + #[serde(default, deserialize_with = "present")] + max_units_per_hour: Option, + #[serde(default, deserialize_with = "present")] + price_per_unit: Option, + #[serde(default, deserialize_with = "present")] + price_per_unit_2: Option, + #[serde(default, deserialize_with = "present")] + price_per_unit_3: Option, + #[serde(default, deserialize_with = "present")] + price_per_unit_4: Option, + #[serde(default, deserialize_with = "present")] + price_per_unit_5: Option, + }, + /// The value (short name) of a code type on an activity; null removes + /// it and a missing value changes nothing. + SetActivityCode { + activity: String, + code_type: String, + #[serde(default, deserialize_with = "present")] + value: Option, + }, + /// The value (short name) of a project code type on the project; null + /// removes it and a missing value changes nothing. + SetProjectCode { + code_type: String, + #[serde(default, deserialize_with = "present")] + value: Option, + }, + /// A new activity code type; scope is "project" (default), "eps" or + /// "global". + AddCodeType { + code_type: String, + #[serde(default)] + scope: Option, + #[serde(default)] + max_length: Option, + }, + AddCodeValue { + code_type: String, + code: String, + }, + /// An ACTVCODE column (`parent` by short name). + SetCodeValue { + code_type: String, + code: String, + field: String, + value: Value, + }, + DeleteCodeValue { + code_type: String, + code: String, + }, + /// A notebook topic's text (HTML as stored); null removes it and a + /// missing text changes nothing. + SetNotebook { + activity: String, + topic: String, + #[serde(default, deserialize_with = "present")] + text: Option, + }, + SetWbsNotebook { + wbs: String, + topic: String, + #[serde(default, deserialize_with = "present")] + text: Option, + }, + /// A user defined field value by label, on one record: an activity, a + /// resource, a resource assignment (activity and resource), an activity + /// step (activity and step), a WBS element, the project, an expense, an + /// issue, a risk or a work product or document. + SetUdf { + #[serde(default)] + activity: Option, + #[serde(default)] + resource: Option, + #[serde(default)] + step: Option, + #[serde(default)] + wbs: Option, + /// The open project's own value (`true`). + #[serde(default)] + project: Option, + #[serde(default)] + expense: Option, + #[serde(default)] + issue: Option, + #[serde(default)] + risk: Option, + #[serde(default)] + document: Option, + udf: String, + value: Value, + }, + AddCalendar { + calendar: String, + }, + /// A CALENDAR column, `base_calendar` (a name) or `project_calendar`. + SetCalendar { + calendar: String, + field: String, + value: Value, + }, + /// Without `replacement` or `default_global` only a calendar nothing + /// uses is deleted. With `replacement` (a global calendar's name) or + /// `default_global`, everything that uses it moves there first. + DeleteCalendar { + calendar: String, + #[serde(default)] + replacement: Option, + #[serde(default)] + default_global: bool, + }, + AddResource { + resource: String, + }, + /// An RSRC column, `parent` (short name) or `calendar` (name). + SetResource { + resource: String, + field: String, + value: Value, + }, + /// A PROJWBS column of the element at a WBS path. + SetWbs { + wbs: String, + field: String, + value: Value, + }, + /// A SCHEDOPTIONS column. + SetScheduleOption { + field: String, + value: Value, + }, + /// Funding of the project from a funding source (by name, from the + /// FUNDSRC dictionary), with an amount and a fund share (percent). + AddProjectFunding { + source: String, + #[serde(default)] + amount: Option, + #[serde(default)] + share: Option, + }, + /// `field` is `source` (another funding source's name), `amount` or + /// `share`. + SetProjectFunding { + source: String, + field: String, + value: Value, + }, + DeleteProjectFunding { + source: String, + }, + /// Delete a resource (short name) that has no assignments and no child + /// resources. + DeleteResource { + resource: String, + }, + /// Merge the resources `from` (short names) into `into`: assignments in + /// every project, rates, codes, user defined field values, role links, + /// child resources and the calendar move to `into` (assignments of one + /// activity are combined), then the `from` resources are removed. + MergeResources { + from: Vec, + into: String, + }, + /// Earned value techniques of a WBS element (`wbs` path; "" is the + /// project node). `performance`: activity_percent, wbs_milestones, + /// 0/100, 50/50 or custom; `estimate_to_complete`: remaining, pf_1, + /// pf_cpi, pf_cpi_spi or pf. + SetWbsEarnedValue { + wbs: String, + #[serde(default)] + performance: Option, + #[serde(default)] + custom_percent: Option, + #[serde(default)] + estimate_to_complete: Option, + #[serde(default)] + performance_factor: Option, + }, + /// A work product or document (the WPs & Docs view), titled `title`, + /// under the document `parent` (reference number, title or id) or at + /// the top level, with any other fields given. + AddDocument { + title: String, + #[serde(default)] + parent: Option, + #[serde(default)] + reference: Option, + #[serde(default)] + fields: Option>, + }, + /// One field of a document: title, reference, deliverable, status, + /// category, author, version, date, private_location, public_location + /// or description. + SetDocument { + document: String, + field: String, + value: Value, + }, + /// Delete a document with the documents under it and their links. + DeleteDocument { + document: String, + }, + /// Link a document to an activity (Activity ID) or a WBS element (path). + LinkDocument { + document: String, + #[serde(default)] + activity: Option, + #[serde(default)] + wbs: Option, + #[serde(default)] + work_product: Option, + }, + UnlinkDocument { + document: String, + #[serde(default)] + activity: Option, + #[serde(default)] + wbs: Option, + }, + // ------------------------------------------------ project registers + /// An expense item on an activity, with any fields given (`name`, + /// `category`, `budgeted_cost`, ...; see `set_expense`). + AddExpense { + activity: String, + #[serde(default)] + name: Option, + #[serde(default)] + fields: Option>, + }, + /// One field of an expense item (named by id or name). + SetExpense { + expense: String, + field: String, + value: Value, + }, + DeleteExpense { + expense: String, + }, + /// An open issue identified today (or `fields.identified_on`). + AddIssue { + #[serde(default)] + name: Option, + #[serde(default)] + fields: Option>, + }, + SetIssue { + issue: String, + field: String, + value: Value, + }, + /// Delete an issue with its history. + DeleteIssue { + issue: String, + }, + /// A proposed threat identified today, with the next free Risk ID. + AddRisk { + #[serde(default)] + name: Option, + #[serde(default)] + fields: Option>, + }, + SetRisk { + risk: String, + field: String, + value: Value, + }, + /// Delete a risk with its activity assignments. + DeleteRisk { + risk: String, + }, + AssignRisk { + risk: String, + activity: String, + }, + UnassignRisk { + risk: String, + activity: String, + }, + /// An enabled threshold (total float below zero days unless `parameter` + /// and `fields` say otherwise). + AddThreshold { + #[serde(default)] + parameter: Option, + #[serde(default)] + fields: Option>, + }, + SetThreshold { + threshold: String, + field: String, + value: Value, + }, + /// Delete a threshold; the issues it raised stay. + DeleteThreshold { + threshold: String, + }, + /// A step on an activity, named `name`, at position `at` (1 is first; + /// the end when omitted). + AddStep { + activity: String, + name: String, + #[serde(default)] + at: Option, + }, + /// One field of a step (by number from 1, or name): `name`, `complete`, + /// `percent_complete`, `weight` or `description`. + SetStep { + activity: String, + step: Value, + field: String, + value: Value, + }, + DeleteStep { + activity: String, + step: Value, + }, + /// Move a step to position `to` (1 is first). + MoveStep { + activity: String, + step: Value, + to: usize, + }, + /// Add a step template's steps after the activity's step `after` (by + /// number from 1, or name), or after its last step (Add from Template, + /// Assign > Steps). + AddStepsFromTemplate { + activity: String, + template: String, + #[serde(default)] + after: Option, + }, + /// A new step template named `name` from the activity's steps (Create + /// Template). + CreateStepTemplate { + activity: String, + name: String, + }, + /// The Feedback tab: notes to resources (`null` clears) and whether + /// feedback needs review. + SetFeedback { + activity: String, + #[serde(default, deserialize_with = "present")] + notes: Option, + #[serde(default)] + review_required: Option, + }, + /// Tools > Top Down Estimation: spread `labor_units` over the not started + /// Task and Resource Dependent activities below `wbs` (the whole project + /// when omitted) by the WBS estimation weights (`weights`, by WBS path, + /// are stored first). + TopDownEstimate { + labor_units: f64, + #[serde(default)] + wbs: Option, + #[serde(default)] + not_started_only: Option, + #[serde(default)] + weights: Option>, + }, + /// Move a WBS element: `up` or `down` among its siblings, `left` (out to + /// its parent's level) or `right` (into the sibling above). + ShiftWbs { + wbs: String, + direction: String, + }, + /// Change a WBS element's own code (unique among its siblings). + RenameWbsCode { + wbs: String, + code: String, + }, + /// Rename a calendar. + RenameCalendar { + calendar: String, + name: String, + }, + /// Make a global calendar the default for new projects and resources. + SetDefaultCalendar { + calendar: String, + }, + /// Convert a project calendar to `global`, or a resource calendar to + /// `shared` or `personal`. + ConvertCalendar { + calendar: String, + to: String, + }, + /// A new calendar of `kind` (`project` default, `global`, `resource`), + /// a copy of `source` when given (a standard 5-day week otherwise), + /// named `calendar`. + CopyCalendar { + calendar: String, + #[serde(default)] + source: Option, + #[serde(default)] + kind: Option, + }, + /// Update Progress: record progress as scheduled up to the new data date + /// (every activity, or only `activities`), then move the data date. + /// `remaining` is `always` (default: remaining work to the scheduled + /// finish) or `duration_type` (fixed units types use up elapsed time). + UpdateProgress { + data_date: String, + #[serde(default)] + activities: Option>, + #[serde(default)] + remaining: Option, + }, + /// Apply Actuals: Update Progress for the activities set to compute + /// actuals; stamps the project's apply actuals date. + ApplyActuals { + data_date: String, + #[serde(default)] + remaining: Option, + }, + /// Recalculate Assignment Costs from the resources' prices. + RecalculateCosts { + #[serde(default)] + active_only: bool, + #[serde(default)] + sync_overtime: bool, + }, + /// Monitor Thresholds: evaluate every enabled threshold and raise or + /// update issues. `from` and `to` replace every threshold's own window. + MonitorThresholds { + #[serde(default)] + from: Option, + #[serde(default)] + to: Option, + /// The date new issues are identified on (default today). + #[serde(default)] + today: Option, + }, + /// Delete a financial period (by name; `calendar` names its financial + /// period calendar when two share the name). Refused while stored period + /// performance refers to it, as in the app. + DeleteFinancialPeriod { + period: String, + #[serde(default)] + calendar: Option, + }, + /// Tools > Global Change on every activity of the project: a definition + /// saved in the workspace input by `name`, or `rule` given inline (the + /// saved form: `conditions`, `then`, `otherwise`; `match` all or any). + /// The result lists the report's lines (activity, field, old and new + /// value, and why a line cannot change); the lines without an error + /// are written. A dry run returns the lines and writes nothing. + GlobalChange { + #[serde(default)] + name: Option, + #[serde(default)] + rule: Option, + }, +} + +impl Operation { + /// What a record edit names, for messages. + fn subject(&self) -> String { + match self { + Operation::SetResourceLimit { resource, from, .. } => format!("{resource} {from}"), + Operation::SetActivityCode { + activity, + code_type, + .. + } => format!("{activity} {code_type}"), + Operation::SetProjectCode { code_type, .. } => code_type.clone(), + Operation::AddCodeType { code_type, .. } => code_type.clone(), + Operation::AddCodeValue { code_type, code } + | Operation::DeleteCodeValue { code_type, code } => format!("{code_type} {code}"), + Operation::SetCodeValue { + code_type, + code, + field, + .. + } => format!("{code_type} {code} {field}"), + Operation::SetNotebook { + activity, topic, .. + } => format!("{activity} {topic}"), + Operation::SetWbsNotebook { wbs, topic, .. } => format!("{wbs} {topic}"), + Operation::SetUdf { + activity, + resource, + wbs, + expense, + issue, + risk, + document, + project, + udf, + .. + } => format!( + "{} {udf}", + [activity, resource, wbs, expense, issue, risk, document] + .into_iter() + .find_map(|o| o.as_deref()) + .or((*project == Some(true)).then_some("project")) + .unwrap_or("") + ), + Operation::AddCalendar { calendar } | Operation::DeleteCalendar { calendar, .. } => { + calendar.clone() + } + Operation::SetCalendar { + calendar, field, .. + } => format!("{calendar} {field}"), + Operation::AddResource { resource } => resource.clone(), + Operation::SetResource { + resource, field, .. + } => format!("{resource} {field}"), + Operation::SetWbs { wbs, field, .. } => format!("{wbs} {field}"), + Operation::SetScheduleOption { field, .. } => field.clone(), + Operation::SetProject { field, .. } => field.clone(), + Operation::AddProjectFunding { source, .. } + | Operation::DeleteProjectFunding { source } => source.clone(), + Operation::SetProjectFunding { source, field, .. } => format!("{source} {field}"), + Operation::DeleteResource { resource } => resource.clone(), + Operation::DeleteFinancialPeriod { period, .. } => period.clone(), + Operation::GlobalChange { name, .. } => name.clone().unwrap_or_default(), + Operation::MergeResources { from, into } => format!("{} into {into}", from.join(", ")), + Operation::SetWbsEarnedValue { wbs, .. } => wbs.clone(), + Operation::AddDocument { title, .. } => title.clone(), + Operation::SetDocument { + document, field, .. + } => format!("{document} {field}"), + Operation::DeleteDocument { document } => document.clone(), + Operation::LinkDocument { + document, + activity, + wbs, + .. + } + | Operation::UnlinkDocument { + document, + activity, + wbs, + } => format!( + "{document} {}", + activity.as_deref().or(wbs.as_deref()).unwrap_or("") + ), + Operation::AddExpense { activity, .. } => activity.clone(), + Operation::AddStep { activity, name, .. } => format!("{activity} {name}"), + Operation::SetStep { + activity, + step, + field, + .. + } => format!("{activity} {step} {field}"), + Operation::DeleteStep { activity, step } + | Operation::MoveStep { activity, step, .. } => { + format!("{activity} {step}") + } + Operation::AddStepsFromTemplate { + activity, + template, + after: _, + } => format!("{activity} {template}"), + Operation::CreateStepTemplate { activity, name } => format!("{activity} {name}"), + Operation::SetFeedback { activity, .. } => activity.clone(), + Operation::TopDownEstimate { wbs, .. } => wbs.clone().unwrap_or_default(), + Operation::ShiftWbs { wbs, direction } => format!("{wbs} {direction}"), + Operation::RenameWbsCode { wbs, code } => format!("{wbs} {code}"), + Operation::RenameCalendar { calendar, .. } + | Operation::SetDefaultCalendar { calendar } + | Operation::ConvertCalendar { calendar, .. } + | Operation::CopyCalendar { calendar, .. } => calendar.clone(), + Operation::SetExpense { + expense: r, field, .. + } + | Operation::SetIssue { + issue: r, field, .. + } + | Operation::SetRisk { risk: r, field, .. } + | Operation::SetThreshold { + threshold: r, + field, + .. + } => format!("{r} {field}"), + Operation::DeleteExpense { expense: r } + | Operation::DeleteIssue { issue: r } + | Operation::DeleteRisk { risk: r } + | Operation::DeleteThreshold { threshold: r } => r.clone(), + Operation::AddIssue { name, .. } | Operation::AddRisk { name, .. } => { + name.clone().unwrap_or_default() + } + Operation::AddThreshold { parameter, .. } => parameter.clone().unwrap_or_default(), + Operation::AssignRisk { risk, activity } + | Operation::UnassignRisk { risk, activity } => { + format!("{risk} {activity}") + } + _ => String::new(), + } + } + pub fn name(&self) -> &'static str { + match self { + Operation::SetProject { .. } => "set_project", + Operation::AddWbs { .. } => "add_wbs", + Operation::AddActivity { .. } => "add_activity", + Operation::DeleteActivity { .. } => "delete_activity", + Operation::DissolveActivity { .. } => "dissolve_activity", + Operation::SetActivity { .. } => "set_activity", + Operation::AssignResource { .. } => "assign_resource", + Operation::RemoveAssignment { .. } => "remove_assignment", + Operation::SetAssignment { .. } => "set_assignment", + Operation::Relationship { .. } => "relationship", + Operation::CalendarDay { .. } => "calendar_day", + Operation::CalendarWeekday { .. } => "calendar_weekday", + Operation::Schedule { .. } => "schedule", + Operation::SetResourceLimit { .. } => "set_resource_limit", + Operation::SetActivityCode { .. } => "set_activity_code", + Operation::SetProjectCode { .. } => "set_project_code", + Operation::AddCodeType { .. } => "add_code_type", + Operation::AddCodeValue { .. } => "add_code_value", + Operation::SetCodeValue { .. } => "set_code_value", + Operation::DeleteCodeValue { .. } => "delete_code_value", + Operation::SetNotebook { .. } => "set_notebook", + Operation::SetWbsNotebook { .. } => "set_wbs_notebook", + Operation::SetUdf { .. } => "set_udf", + Operation::AddCalendar { .. } => "add_calendar", + Operation::SetCalendar { .. } => "set_calendar", + Operation::DeleteCalendar { .. } => "delete_calendar", + Operation::AddResource { .. } => "add_resource", + Operation::SetResource { .. } => "set_resource", + Operation::SetWbs { .. } => "set_wbs", + Operation::SetScheduleOption { .. } => "set_schedule_option", + Operation::AddProjectFunding { .. } => "add_project_funding", + Operation::SetProjectFunding { .. } => "set_project_funding", + Operation::DeleteProjectFunding { .. } => "delete_project_funding", + Operation::DeleteResource { .. } => "delete_resource", + Operation::MergeResources { .. } => "merge_resources", + Operation::SetWbsEarnedValue { .. } => "set_wbs_earned_value", + Operation::AddDocument { .. } => "add_document", + Operation::SetDocument { .. } => "set_document", + Operation::DeleteDocument { .. } => "delete_document", + Operation::LinkDocument { .. } => "link_document", + Operation::UnlinkDocument { .. } => "unlink_document", + Operation::AddExpense { .. } => "add_expense", + Operation::SetExpense { .. } => "set_expense", + Operation::DeleteExpense { .. } => "delete_expense", + Operation::AddIssue { .. } => "add_issue", + Operation::SetIssue { .. } => "set_issue", + Operation::DeleteIssue { .. } => "delete_issue", + Operation::AddRisk { .. } => "add_risk", + Operation::SetRisk { .. } => "set_risk", + Operation::DeleteRisk { .. } => "delete_risk", + Operation::AssignRisk { .. } => "assign_risk", + Operation::UnassignRisk { .. } => "unassign_risk", + Operation::AddThreshold { .. } => "add_threshold", + Operation::SetThreshold { .. } => "set_threshold", + Operation::DeleteThreshold { .. } => "delete_threshold", + Operation::MonitorThresholds { .. } => "monitor_thresholds", + Operation::UpdateProgress { .. } => "update_progress", + Operation::TopDownEstimate { .. } => "top_down_estimate", + Operation::ShiftWbs { .. } => "shift_wbs", + Operation::RenameWbsCode { .. } => "rename_wbs_code", + Operation::RenameCalendar { .. } => "rename_calendar", + Operation::SetDefaultCalendar { .. } => "set_default_calendar", + Operation::ConvertCalendar { .. } => "convert_calendar", + Operation::CopyCalendar { .. } => "copy_calendar", + Operation::AddStep { .. } => "add_step", + Operation::SetStep { .. } => "set_step", + Operation::DeleteStep { .. } => "delete_step", + Operation::MoveStep { .. } => "move_step", + Operation::AddStepsFromTemplate { .. } => "add_steps_from_template", + Operation::CreateStepTemplate { .. } => "create_step_template", + Operation::SetFeedback { .. } => "set_feedback", + Operation::ApplyActuals { .. } => "apply_actuals", + Operation::RecalculateCosts { .. } => "recalculate_costs", + Operation::DeleteFinancialPeriod { .. } => "delete_financial_period", + Operation::GlobalChange { .. } => "global_change", + } + } + /// Record edits written to the document as given. + fn is_record(&self) -> bool { + matches!( + self, + Operation::SetResourceLimit { .. } + | Operation::SetActivityCode { .. } + | Operation::SetProjectCode { .. } + | Operation::AddCodeType { .. } + | Operation::AddCodeValue { .. } + | Operation::SetCodeValue { .. } + | Operation::DeleteCodeValue { .. } + | Operation::SetNotebook { .. } + | Operation::SetWbsNotebook { .. } + | Operation::SetUdf { .. } + | Operation::AddCalendar { .. } + | Operation::SetCalendar { .. } + | Operation::DeleteCalendar { .. } + | Operation::AddResource { .. } + | Operation::SetResource { .. } + | Operation::SetWbs { .. } + | Operation::SetScheduleOption { .. } + | Operation::AddProjectFunding { .. } + | Operation::SetProjectFunding { .. } + | Operation::DeleteProjectFunding { .. } + | Operation::DeleteResource { .. } + | Operation::MergeResources { .. } + | Operation::SetWbsEarnedValue { .. } + | Operation::AddDocument { .. } + | Operation::SetDocument { .. } + | Operation::DeleteDocument { .. } + | Operation::LinkDocument { .. } + | Operation::UnlinkDocument { .. } + | Operation::AddExpense { .. } + | Operation::SetExpense { .. } + | Operation::DeleteExpense { .. } + | Operation::AddIssue { .. } + | Operation::SetIssue { .. } + | Operation::DeleteIssue { .. } + | Operation::AddRisk { .. } + | Operation::SetRisk { .. } + | Operation::DeleteRisk { .. } + | Operation::AssignRisk { .. } + | Operation::UnassignRisk { .. } + | Operation::AddThreshold { .. } + | Operation::SetThreshold { .. } + | Operation::DeleteThreshold { .. } + | Operation::RecalculateCosts { .. } + | Operation::CreateStepTemplate { .. } + | Operation::SetFeedback { .. } + | Operation::DeleteFinancialPeriod { .. } + ) || matches!(self, Operation::SetProject { field, .. } if !matches!(field.as_str(), "data_date" | "must_finish" | "must_finish_by")) + } + /// A short readable description for messages. + fn describe(&self) -> String { + match self { + Operation::SetProject { field, .. } => format!("set_project {field}"), + Operation::AddWbs { wbs, .. } => format!("add_wbs {wbs}"), + Operation::AddActivity { activity, .. } => { + format!( + "add_activity {}", + activity.as_deref().unwrap_or("(next ID)") + ) + } + Operation::DeleteActivity { activity } => format!("delete_activity {activity}"), + Operation::DissolveActivity { activity, .. } => format!("dissolve_activity {activity}"), + Operation::SetActivity { + activity, field, .. + } => format!("set_activity {activity} {field}"), + Operation::AssignResource { activity, resource } => { + format!("assign_resource {activity} {resource}") + } + Operation::RemoveAssignment { activity, resource } => { + format!("remove_assignment {activity} {resource}") + } + Operation::SetAssignment { + activity, + resource, + field, + .. + } => format!("set_assignment {activity} {resource} {field}"), + Operation::Relationship { + action, + predecessor, + successor, + kind, + .. + } => format!("relationship {action} {predecessor} {kind} {successor}"), + Operation::CalendarDay { calendar, date, .. } => { + format!("calendar_day {calendar} {date}") + } + Operation::CalendarWeekday { + calendar, weekday, .. + } => format!("calendar_weekday {calendar} {weekday}"), + Operation::Schedule { .. } => "schedule".into(), + other => format!("{} {}", other.name(), other.subject()), + } + } +} + +/// Parse a changes document. +pub fn parse_changes(value: Value) -> Result { + let changes: Changes = serde_json::from_value(value) + .map_err(|e| AutomationError::new("invalid_changes", e.to_string()))?; + if changes.format != FORMAT { + return Err(AutomationError::new( + "invalid_changes", + format!("format must be {FORMAT:?}"), + )); + } + if changes.operations.is_empty() || changes.operations.len() > MAX_OPERATIONS { + return Err(AutomationError::new( + "invalid_changes", + format!("operations must hold 1 to {MAX_OPERATIONS} operations"), + )); + } + Ok(changes) +} + +/// The order operations run in: file order, except that a primary resource +/// set before the batch assigns that resource runs right after the +/// assignment (a primary resource must be assigned first). +fn order(operations: &[Operation]) -> Vec { + let mut order: Vec = (0..operations.len()).collect(); + for (k, op) in operations.iter().enumerate() { + let Operation::SetActivity { + activity, + field, + value, + .. + } = op + else { + continue; + }; + let Some(name) = value.as_str().filter(|_| field == "primary_resource") else { + continue; + }; + let later = operations.iter().enumerate().skip(k + 1).find(|(_, o)| { + matches!(o, Operation::AssignResource { activity: a, resource: r } if a == activity && r == name) + }); + if let Some((j, _)) = later { + order.retain(|&x| x != k); + let at = order + .iter() + .position(|&x| x == j) + .expect("assignment is ordered") + + 1; + order.insert(at, k); + } + } + order +} + +/// The activity an operation edits a field of, when it names one. +fn edited_activity(op: &Operation) -> Option<&str> { + match op { + Operation::SetActivity { activity, .. } + | Operation::SetAssignment { activity, .. } + | Operation::SetActivityCode { activity, .. } + | Operation::SetNotebook { activity, .. } + | Operation::AssignResource { activity, .. } => Some(activity), + Operation::SetUdf { activity, .. } => activity.as_deref(), + _ => None, + } +} + +/// Within a run of field edits, new activities and new assignments are +/// created at the start of the run, so the project is not re-read between +/// each one and its fields. An addition never moves past an operation on +/// the same activity, so every edit still sees what it saw in file order. +fn hoist(operations: &[Operation], order: Vec) -> Vec { + let structural = |op: &Operation| { + matches!( + op, + Operation::AddActivity { .. } | Operation::AssignResource { .. } + ) + }; + let in_run = |op: &Operation| { + structural(op) + || op.is_record() + || matches!( + op, + Operation::SetActivity { .. } | Operation::SetAssignment { .. } + ) + }; + // An assignment reads the resource dictionary (by short name, priced from + // its rates); a new activity reads the WBS paths. + let depends = |op: &Operation, prev: &Operation| match op { + Operation::AssignResource { .. } => matches!( + prev, + Operation::AddResource { .. } + | Operation::SetResource { .. } + | Operation::DeleteResource { .. } + | Operation::MergeResources { .. } + | Operation::SetResourceLimit { .. } + ), + // ... and the project's defaults for new activities. + Operation::AddActivity { .. } => { + matches!( + prev, + Operation::SetWbs { .. } | Operation::SetProject { .. } + ) + } + _ => false, + }; + let mut out: Vec = Vec::with_capacity(order.len()); + let mut run_start = 0; + for n in order { + let op = &operations[n]; + if !in_run(op) { + out.push(n); + run_start = out.len(); + continue; + } + if !structural(op) { + out.push(n); + continue; + } + // A new activity numbered from the defaults takes the IDs in use + // where it stands, so it stays there and nothing moves past it. + if matches!(op, Operation::AddActivity { activity: None, .. }) { + out.push(n); + run_start = out.len(); + continue; + } + let name = match op { + Operation::AddActivity { activity, .. } => activity.as_deref().unwrap_or(""), + Operation::AssignResource { activity, .. } => activity.as_str(), + _ => unreachable!(), + }; + // Move up past field edits of other activities, behind the run's + // earlier additions and any edit of what the addition names (its + // resource, or the WBS element it goes under). + let mut at = out.len(); + while at > run_start { + let prev = &operations[out[at - 1]]; + if structural(prev) || edited_activity(prev) == Some(name) || depends(op, prev) { + break; + } + at -= 1; + } + out.insert(at, n); + } + out +} + +/// Apply `operations` to `project` in order, all or nothing. `recalculate` +/// is the batch default. Returns the report (operation results and the +/// field differences). On `Err` `project` is unchanged. +pub fn apply( + project: &mut ProjectData, + operations: &[Operation], + recalculate: bool, +) -> Result { + apply_with(project, operations, recalculate, &Default::default()) +} + +/// Apply an `openxer-changes/1` document (as `openxer_apply` takes it) to a +/// project held in memory, such as the one open in the app: the same +/// parsing and the same setters as the file-based apply, all or nothing. +/// `recalculate` overrides the document's own default (true when neither +/// says). `ev` holds the stored baselines `monitor_thresholds` reads +/// (`Default` when the caller has none). Returns the same report the +/// apply command gives (operation results and the field diff); on `Err` +/// `project` is unchanged. +pub fn apply_changes( + project: &mut ProjectData, + changes: Value, + recalculate: Option, + ev: &crate::baselines::EvContext, +) -> Result { + let changes = parse_changes(changes)?; + let recalculate = recalculate.or(changes.recalculate).unwrap_or(true); + apply_with(project, &changes.operations, recalculate, ev) +} + +/// [`apply`] with the stored baselines earned value reads (`monitor_thresholds`). +pub fn apply_with( + project: &mut ProjectData, + operations: &[Operation], + recalculate: bool, + ev: &crate::baselines::EvContext, +) -> Result { + project + .model + .validate() + .map_err(|e| AutomationError::new("invalid_source", e))?; + let before = project.updated_document(); + let mut next = project.clone(); + let mut state = State { + raw: false, + ev: ev.clone(), + schedules: vec![], + comments: vec![], + }; + let mut results = vec![]; + let mut warnings = vec![]; + for n in hoist(operations, order(operations)) { + let op = &operations[n]; + let fail = |e: String| { + // A milestone refuses assignments everywhere; agents get a code. + let code = if e.contains(openxer_xer::assignments::MILESTONE_RULE) { + "milestone_assignment" + } else { + "operation_failed" + }; + AutomationError::new( + code, + format!("Operation {} ({}): {e}", n + 1, op.describe()), + ) + }; + let result = apply_one(&mut next, op, recalculate, &mut state).map_err(fail)?; + // An operation that wrote nothing says why; the report lists it so + // a batch that succeeds is not taken for one that changed things. + if let Some(why) = result.get("reason").and_then(Value::as_str) { + warnings.push(json!(format!( + "Operation {} ({}) wrote nothing: {why}", + n + 1, + op.describe() + ))); + } + results.push(result); + } + if !state.comments.is_empty() { + state.begin_raw(&mut next); + } + state.settle(&mut next).map_err(|e| { + AutomationError::new("operation_failed", format!("Re-reading exact values: {e}")) + })?; + next.model + .validate() + .map_err(|e| AutomationError::new("operation_failed", e))?; + let after = next.updated_document(); + let diff = diff(&before, &after, next.model.project.proj_id); + *project = next; + let mut report = json!({"operations":operations.len(),"results":results,"diff":diff}); + if !state.schedules.is_empty() { + report["schedule"] = Value::Array(state.schedules); + } + if !warnings.is_empty() { + report["warnings"] = Value::Array(warnings); + } + Ok(report) +} + +struct State { + /// Exact writes went to the document; the project must be re-read. + raw: bool, + /// The baselines earned value reads (Monitor Thresholds). + ev: crate::baselines::EvContext, + schedules: Vec, + /// Relationship comments waiting for their rows: (predecessor task id, + /// successor task id, PR_ type, text). + comments: Vec<(i64, i64, String, String)>, +} + +impl State { + /// Before an exact write: put the model into the document. + fn begin_raw(&mut self, p: &mut ProjectData) { + if !self.raw { + p.document = p.updated_document(); + self.raw = true; + } + for (a, b, kind, text) in std::mem::take(&mut self.comments) { + // A relationship removed again later in the batch has no row. + let _ = tables::set_relationship_comments(p, a, b, &kind, &text); + } + } + /// After exact writes: re-read the project from its document. + fn settle(&mut self, p: &mut ProjectData) -> std::result::Result<(), String> { + if !self.raw { + return Ok(()); + } + self.begin_raw(p); + self.raw = false; + let warnings = p.warnings.clone(); + let mut fresh = ProjectData::from_document( + p.document.clone(), + p.model.project.proj_id, + p.source_name.clone(), + )?; + fresh.warnings = warnings; + *p = fresh; + Ok(()) + } +} + +fn apply_one( + p: &mut ProjectData, + op: &Operation, + batch_recalculate: bool, + state: &mut State, +) -> std::result::Result { + let exact = match op { + Operation::SetActivity { recalculate, .. } + | Operation::SetAssignment { recalculate, .. } => !recalculate.unwrap_or(batch_recalculate), + other => other.is_record(), + }; + if exact { + state.begin_raw(p); + } else { + state.settle(p)?; + } + if op.is_record() { + return record(p, op); + } + match op { + Operation::SetProject { + field, + value, + schedule, + } => { + let origin = p.model.origin_serial; + match field.as_str() { + "data_date" => { + let d = date(origin, value)?.ok_or("A data date is required.")?; + // The same rule as Project Details, Dates tab: nothing + // is scheduled unless `schedule` asks for it. + openxer_xer::edit::project_dates::set_data_date(p, Some(d))?; + if schedule.unwrap_or(false) { + let report = schedule_project(p, &SchedulePatch::default()) + .map_err(|e| e.message)?; + state.schedules.push(json!({ + "at": "data_date", + "changed_activity_count": report["changed_activity_count"], + })); + } + } + "must_finish" | "must_finish_by" => p.model.project.plan_end = date(origin, value)?, + _ => { + return Err(format!( + "Unknown project field {field:?}; use data_date or must_finish." + )) + } + } + Ok(json!({"op":"set_project","field":field})) + } + Operation::AddWbs { wbs: path, name } => { + let (id, added) = wbs::ensure_path(p, path, name.as_deref())?; + Ok(json!({"op":"add_wbs","wbs":path,"wbs_id":id,"added":added})) + } + Operation::AddActivity { + activity, + selected, + name, + wbs: path, + } => { + if let Some(activity) = activity { + if find_activity(p, activity).is_ok() { + return Err(format!("Activity {activity} already exists.")); + } + } + let selected = selected + .as_deref() + .map(|code| find_activity(p, code)) + .transpose()?; + let selected_wbs = + selected.and_then(|i| p.details.get(&p.model.activities[i].task_id).map(|d| d.wbs)); + let w = match path { + Some(path) => { + wbs::find_path(p, path).ok_or_else(|| format!("No WBS element {path:?}."))? + } + None => selected_wbs + .or_else(|| wbs::project_node(p)) + .or_else(|| p.wbs.first().map(|w| w.id)) + .ok_or("The project has no WBS element for a new activity.")?, + }; + let i = openxer_xer::edit::new_activity::add_activity(p, w, selected); + if let Some(activity) = activity { + act::set_activity_id(p, i, activity)?; + } + if let Some(name) = name { + act::set_activity_name(p, i, name)?; + } + let a = &p.model.activities[i]; + Ok(json!({"op":"add_activity","activity":a.task_code,"task_id":a.task_id})) + } + Operation::DeleteActivity { activity } => { + let i = find_activity(p, activity)?; + let task_id = p.model.activities[i].task_id; + p.delete_activities(&[task_id])?; + Ok(json!({"op":"delete_activity","activity":activity})) + } + Operation::DissolveActivity { + activity, + retain_lag, + } => { + let i = find_activity(p, activity)?; + let task_id = p.model.activities[i].task_id; + let retain_lag = retain_lag.unwrap_or(false); + let done = openxer_xer::edit::dissolve::dissolve(p, &[task_id], retain_lag)?; + Ok( + json!({"op":"dissolve_activity","activity":activity,"retain_lag":retain_lag, + "relationships_added":done.added,"relationships_kept":done.kept}), + ) + } + Operation::SetActivity { + activity, + field, + value, + .. + } => { + let i = find_activity(p, activity)?; + if exact { + state.begin_raw(p); + let column = set_task_exact(p, i, field, value)?; + return Ok( + json!({"op":"set_activity","activity":activity,"field":field,"exact":column}), + ); + } + let changed = set_activity(p, i, field, value)?; + Ok( + json!({"op":"set_activity","activity":activity,"field":field,"changed":changed.0,"warning":changed.1}), + ) + } + Operation::AssignResource { activity, resource } => { + let i = find_activity(p, activity)?; + let task_id = p.model.activities[i].task_id; + let rsrc = find_resource(p, resource)?; + if assignment_row(p, task_id, rsrc).is_ok() { + return Err(format!("{resource} is already assigned to {activity}.")); + } + p.add_assignment_with(task_id, Some(rsrc), None, false)?; + Ok(json!({"op":"assign_resource","activity":activity,"resource":resource})) + } + Operation::RemoveAssignment { activity, resource } => { + let i = find_activity(p, activity)?; + let task_id = p.model.activities[i].task_id; + let row = assignment_row(p, task_id, find_resource(p, resource)?)?; + p.remove_assignment_with(row, false)?; + Ok(json!({"op":"remove_assignment","activity":activity,"resource":resource})) + } + Operation::SetAssignment { + activity, + resource, + field, + value, + .. + } => { + let i = find_activity(p, activity)?; + let task_id = p.model.activities[i].task_id; + let rsrc = find_resource(p, resource)?; + // The curve is a document value in both modes: named by curve + // name (a preset is copied into the file when first used). + if field == "curve" { + state.begin_raw(p); + let row = assignment_row(p, task_id, rsrc)?; + let name = text(value); + let changed = curves::set_assignment_curve(&mut p.document, row, name.as_deref())?; + // A curve is accepted on any activity (as the desktop picker + // does) but shapes the spread only on the Fixed Duration + // types; the result says whether it does here. + let pid = p.model.project.proj_id; + let kind = openxer_xer::edit::records::task_value( + &p.document, + task_id, + pid, + "duration_type", + ); + let applies = openxer_xer::spread::curve_applies(&kind); + let mut out = json!({"op":"set_assignment","activity":activity,"resource":resource,"field":field,"curve":name,"changed":changed,"curv_id":curves::of_assignment(&p.document, row),"curve_applies":applies}); + if !applies && name.is_some() { + out["note"] = json!("This activity's duration type ignores resource curves, so its units spread evenly. Curves shape the spread only on Fixed Duration and Units/Time (DT_FixedDrtn) and Fixed Duration and Units (DT_FixedDUR2) activities."); + } + return Ok(out); + } + // Typed period units, as in the usage spreadsheet: the same + // edit in both modes. + if field == "period_remaining_units" { + let row = assignment_row(p, task_id, rsrc)?; + let (period, units) = period_value(p, value)?; + p.set_period_units(row, period, units)?; + let runs = records::get(&p.document, "TASKRSRC", row, "remain_crv"); + return Ok( + json!({"op":"set_assignment","activity":activity,"resource":resource,"field":field,"remain_crv":runs,"remaining_units":records::get(&p.document, "TASKRSRC", row, "remain_qty")}), + ); + } + if exact { + state.begin_raw(p); + let row = assignment_row(p, task_id, rsrc)?; + let column = set_assignment_exact(p, row, field, value)?; + return Ok( + json!({"op":"set_assignment","activity":activity,"resource":resource,"field":field,"exact":column}), + ); + } + let row = assignment_row(p, task_id, rsrc)?; + // A value the assignment already holds is no change: nothing is + // recalculated (an equal price keeps its source) and a locked + // field accepts it. + if !assignment_holds(p, row, field, value) { + p.edit_assignment(row, assignment_edit_in(p, field, value)?)?; + } + Ok(json!({"op":"set_assignment","activity":activity,"resource":resource,"field":field})) + } + Operation::Relationship { + action, + predecessor, + successor, + kind, + lag_hours, + comments, + } => { + let pred = find_activity(p, predecessor)?; + let succ = find_activity(p, successor)?; + let kind = link_type(kind)?; + if lag_hours.is_some_and(|l| !l.is_finite() || !(-100_000.0..=100_000.0).contains(&l)) { + return Err("lag_hours must be from -100000 to 100000.".into()); + } + let index = p + .model + .links + .iter() + .position(|l| l.pred == pred && l.succ == succ && l.link_type == kind); + match action.as_str() { + // Replaying stored data keeps a relationship that closes a + // loop; the schedule decides. + "add" if !batch_recalculate => relationships::add_keeping_loops( + &mut p.model, + pred, + succ, + kind, + (lag_hours.unwrap_or(0.) * 60.).round() as i64, + )?, + "add" => relationships::add( + &mut p.model, + pred, + succ, + kind, + (lag_hours.unwrap_or(0.) * 60.).round() as i64, + )?, + "edit" | "update" => { + let index = index.ok_or("Relationship not found.")?; + let lag = lag_hours.unwrap_or(p.model.links[index].lag as f64 / 60.); + relationships::edit(&mut p.model, index, kind, lag)? + } + "remove" | "delete" => { + relationships::remove(&mut p.model, index.ok_or("Relationship not found.")?)? + } + other => { + return Err(format!( + "Unknown relationship action {other:?}; use add, edit or remove." + )) + } + } + if let (Some(text), false) = (comments, matches!(action.as_str(), "remove" | "delete")) + { + let (a, b) = ( + p.model.activities[pred].task_id, + p.model.activities[succ].task_id, + ); + state + .comments + .push((a, b, kind.as_str().to_string(), text.clone())); + } + Ok(json!({"op":"relationship","action":action})) + } + Operation::CalendarDay { + calendar, + date: day, + shifts, + } => { + let id = calendar_id(p, calendar)?; + let relative = parse_relative(p.model.origin_serial, day)? + .ok_or("A calendar date is required.")?; + let serial = p.model.origin_serial + relative.div_euclid(openxer_engine::calendar::DAY); + let mut data = calendars::data(&p.document, &id)?; + match shifts { + None => data.set_standard(serial), + Some(list) => data.set_day(serial, parse_shifts(list)?), + } + let hours = calendars::hours(&p.document, &id); + let changed = calendars::commit(p, &id, &data, hours, &calendars::now_stamp())?; + Ok(json!({"op":"calendar_day","calendar":calendar,"date":day,"changed":changed})) + } + Operation::CalendarWeekday { + calendar, + weekday, + shifts, + } => { + if *weekday > 6 { + return Err("weekday must be 0 (Sunday) through 6 (Saturday).".into()); + } + let id = calendar_id(p, calendar)?; + let mut data = calendars::data(&p.document, &id)?; + data.week[*weekday] = parse_shifts(shifts)?; + let hours = calendars::hours(&p.document, &id); + let changed = calendars::commit(p, &id, &data, hours, &calendars::now_stamp())?; + Ok( + json!({"op":"calendar_weekday","calendar":calendar,"weekday":weekday,"changed":changed}), + ) + } + Operation::AddStep { activity, name, at } => { + let t = p.model.activities[find_activity(p, activity)?].task_id; + let n = steps::add_step(p, t, name, *at); + Ok(json!({"op":"add_step","activity":activity,"step":n})) + } + Operation::SetStep { + activity, + step, + field, + value, + } => { + let t = p.model.activities[find_activity(p, activity)?].task_id; + let r = steps::find_step(p, t, &text(step).unwrap_or_default())?; + steps::set_step(p, t, r, field, &text(value).unwrap_or_default())?; + Ok(json!({"op":"set_step","activity":activity,"step":step,"field":field})) + } + Operation::DeleteStep { activity, step } => { + let t = p.model.activities[find_activity(p, activity)?].task_id; + let r = steps::find_step(p, t, &text(step).unwrap_or_default())?; + steps::delete_step(p, t, r); + Ok(json!({"op":"delete_step","activity":activity,"step":step})) + } + Operation::MoveStep { activity, step, to } => { + let t = p.model.activities[find_activity(p, activity)?].task_id; + let r = steps::find_step(p, t, &text(step).unwrap_or_default())?; + if *to == 0 { + return Err("to is a step position from 1.".into()); + } + steps::move_step(p, t, r, *to); + Ok(json!({"op":"move_step","activity":activity,"step":step,"to":to})) + } + Operation::AddStepsFromTemplate { + activity, + template, + after, + } => { + let t = p.model.activities[find_activity(p, activity)?].task_id; + let list = steps::templates(&p.document); + let found: Vec = list + .iter() + .filter(|x| { + x.name.eq_ignore_ascii_case(template.trim()) + || x.id.to_string() == template.trim() + }) + .map(|x| x.id) + .collect(); + let group = match found.as_slice() { + [g] => *g, + [] => return Err(format!("No step template {template:?}.")), + _ => return Err(format!("Step template {template:?} is not unique.")), + }; + let pid = p.model.project.proj_id; + let after = match after.as_ref().and_then(text) { + Some(step) => Some(steps::step_id(&p.document, steps::find_step(p, t, &step)?)), + None => None, + }; + let added = steps::apply_template_after(&mut p.document, group, t, pid, after); + steps::after_steps_change(p, t); + Ok(json!({"op":"add_steps_from_template","activity":activity,"added":added})) + } + Operation::TopDownEstimate { + labor_units, + wbs: root, + not_started_only, + weights, + } => { + let root = match root { + Some(path) => Some( + wbs::find_path(p, path).ok_or_else(|| format!("No WBS element {path:?}."))?, + ), + None => None, + }; + let mut by_id = std::collections::HashMap::new(); + for (path, w) in weights.iter().flatten() { + if !w.is_finite() || *w < 0. { + return Err(format!("The weight of {path:?} must be 0 or more.")); + } + let id = + wbs::find_path(p, path).ok_or_else(|| format!("No WBS element {path:?}."))?; + by_id.insert(id, *w); + } + if !labor_units.is_finite() || *labor_units <= 0. { + return Err("labor_units must be more than 0.".into()); + } + let lines = p.top_down_distribution( + *labor_units, + root, + not_started_only.unwrap_or(true), + &by_id, + ); + if lines.is_empty() { + return Err("No activities can take labor units here: only not started Task Dependent and Resource Dependent activities receive them.".into()); + } + for (&id, &w) in &by_id { + p.set_wbs_estimation_weight(id, w); + } + let changed = p.apply_labor_estimate(&lines); + Ok(json!({"op":"top_down_estimate","activities":lines.len(),"changed":changed})) + } + Operation::ShiftWbs { + wbs: path, + direction, + } => { + let id = wbs::find_path(p, path).ok_or_else(|| format!("No WBS element {path:?}."))?; + match direction.trim().to_ascii_lowercase().as_str() { + "up" => wbs::shift_up(p, id)?, + "down" => wbs::shift_down(p, id)?, + "left" => wbs::shift_left(p, id)?, + "right" => wbs::shift_right(p, id)?, + other => { + return Err(format!( + "direction is up, down, left or right, not {other:?}." + )) + } + } + Ok(json!({"op":"shift_wbs","wbs_id":id,"path":project_records::wbs_code_path(p, id)})) + } + Operation::RenameWbsCode { wbs: path, code } => { + let id = wbs::find_path(p, path).ok_or_else(|| format!("No WBS element {path:?}."))?; + wbs::rename_code(p, id, code)?; + Ok( + json!({"op":"rename_wbs_code","wbs_id":id,"path":project_records::wbs_code_path(p, id)}), + ) + } + Operation::RenameCalendar { calendar, name } => { + let id = calendar_id(p, calendar)?; + calendars::rename(p, &id, name)?; + Ok(json!({"op":"rename_calendar","clndr_id":id})) + } + Operation::SetDefaultCalendar { calendar } => { + let id = calendar_id(p, calendar)?; + calendars::set_default(p, &id)?; + Ok(json!({"op":"set_default_calendar","clndr_id":id})) + } + Operation::ConvertCalendar { calendar, to } => { + let id = calendar_id(p, calendar)?; + let to = match to.trim().to_ascii_lowercase().as_str() { + "global" => calendars::Convert::ToGlobal, + "shared" => calendars::Convert::Shared, + "personal" => calendars::Convert::Personal, + other => return Err(format!("to is global, shared or personal, not {other:?}.")), + }; + calendars::convert(p, &id, to, &calendars::now_stamp())?; + Ok(json!({"op":"convert_calendar","clndr_id":id})) + } + Operation::CopyCalendar { + calendar, + source, + kind, + } => { + let kind = match kind + .as_deref() + .unwrap_or("project") + .trim() + .to_ascii_lowercase() + .as_str() + { + "project" => calendars::Kind::Project, + "global" => calendars::Kind::Global, + "resource" => calendars::Kind::Resource, + other => { + return Err(format!( + "kind is project, global or resource, not {other:?}." + )) + } + }; + let source = match source { + Some(name) => Some(calendar_id(p, name)?), + None => None, + }; + let id = calendars::add(p, kind, source.as_deref(), &calendars::now_stamp())?; + calendars::rename(p, &id, calendar)?; + Ok(json!({"op":"copy_calendar","clndr_id":id})) + } + Operation::UpdateProgress { + data_date, + activities, + remaining, + } => progress_op( + p, + op, + data_date, + activities.as_deref(), + remaining.as_deref(), + ), + Operation::ApplyActuals { + data_date, + remaining, + } => progress_op(p, op, data_date, None, remaining.as_deref()), + Operation::MonitorThresholds { from, to, today } => { + // Read the model as the batch left it, then write issues to + // the document like the other record edits. + state.begin_raw(p); + let origin = p.model.origin_serial; + let bound = |v: &Option| -> std::result::Result, String> { + v.as_deref().map_or(Ok(None), |t| parse_relative(origin, t)) + }; + let window = if from.is_some() || to.is_some() { + Some((bound(from)?, bound(to)?)) + } else { + None + }; + let today = match today { + Some(t) => { + let day = openxer_engine::calendar::DAY; + let at = parse_relative(origin, t)?.ok_or("today needs a date.")?; + openxer_xer::date_string(origin, Some(at.div_euclid(day) * day)) + } + None => project_records::today(), + }; + let (baseline, figures) = { + let calc = state.ev.calculator(p); + thresholds::inputs(p, &calc) + }; + let result = thresholds::monitor(p, &baseline, &figures, window, &today, &|p, id| { + project_records::wbs_code_path(p, id) + }); + Ok( + json!({"op":"monitor_thresholds","thresholds":result.thresholds, + "issues_raised":result.created,"issues_updated":result.updated, + "skipped":result.skipped,"baselines":state.ev.describe()}), + ) + } + Operation::Schedule { level_resources } => { + let patch = SchedulePatch { + level_resources: *level_resources, + ..SchedulePatch::default() + }; + let report = schedule_project(p, &patch).map_err(|e| e.message)?; + let level_resources = p.model.options.do_level; + state.schedules.push(json!({ + "changed_activity_count": report["changed_activity_count"], + "generated_field_count": report["generated_field_count"], + "changed_field_count": report["changed_field_count"], + })); + Ok(json!({"op":"schedule","level_resources":level_resources})) + } + Operation::GlobalChange { name, rule } => global_change(p, name.as_deref(), rule.as_ref()), + other => record(p, other), + } +} + +/// Tools > Global Change on every activity: work out the report's lines on +/// a copy (the shared run the app's report shows), then write the lines +/// that carry no error. Durations show in hours and dates as +/// `YYYY-MM-DD HH:MM`. +fn global_change( + p: &mut ProjectData, + name: Option<&str>, + rule: Option<&Value>, +) -> std::result::Result { + use openxer_xer::edit::global_change::{self as gc, ProjectHost}; + let rule = rule.cloned().ok_or_else(|| match name { + Some(name) => format!( + "No saved global change named {name:?}; saved global changes are read from an \ + OpenXER workspace input, or give the definition as rule." + ), + None => "global_change needs name or rule.".to_string(), + })?; + let mut g = gc::from_value(rule)?; + if let Some(name) = name { + g.name = name.to_string(); + } + let everything = vec![true; p.model.activities.len()]; + let lines = { + let mut scratch = p.clone(); + let mut host = ProjectHost::new(&mut scratch); + gc::preview(&mut host, &g, &everything) + }; + let (changed, failed) = { + let mut host = ProjectHost::new(p); + gc::commit(&mut host, &lines) + }; + let rows: Vec = lines + .iter() + .map(|c| { + json!({"project":c.project,"wbs":c.wbs,"activity":c.activity,"field":c.title, + "field_id":c.column,"old":c.old,"new":c.new,"exception":c.error}) + }) + .collect(); + let refused = lines.iter().filter(|c| c.error.is_some()).count(); + Ok(json!({"op":"global_change","name":g.name,"rows":rows, + "changed":changed,"refused":refused + failed})) +} + +/// Update Progress or Apply Actuals: model edits, like the data date. +fn progress_op( + p: &mut ProjectData, + op: &Operation, + data_date: &str, + activities: Option<&[String]>, + remaining: Option<&str>, +) -> std::result::Result { + let rule = match remaining.unwrap_or("always") { + "always" => progress::RemainingRule::Always, + "duration_type" => progress::RemainingRule::DurationType, + other => { + return Err(format!( + "remaining is always or duration_type, not {other:?}." + )) + } + }; + let origin = p.model.origin_serial; + let dd = parse_relative(origin, data_date)?.ok_or("A new data date is required.")?; + let changed = if matches!(op, Operation::ApplyActuals { .. }) { + progress::apply_actuals(p, dd, rule)? + } else { + match activities { + Some(list) => { + let set = list + .iter() + .map(|a| find_activity(p, a)) + .collect::, String>>()?; + progress::apply_progress(p, dd, progress::ProgressScope::Selected(&set), rule)? + } + None => progress::apply_progress(p, dd, progress::ProgressScope::All, rule)?, + } + }; + Ok(json!({"op":op.name(),"data_date":data_date,"changed_activities":changed})) +} + +// ------------------------------------------------------------ identifiers + +/// What a document link names: exactly one of an activity or a WBS path. +fn document_target( + p: &ProjectData, + activity: &Option, + wbs: &Option, +) -> std::result::Result<(Option, Option), String> { + match (activity, wbs) { + (Some(a), None) => { + let i = find_activity(p, a)?; + Ok((Some(p.model.activities[i].task_id), None)) + } + (None, Some(w)) => { + let id = wbs::find_path(p, w).ok_or_else(|| format!("No WBS element {w:?}."))?; + Ok((None, Some(id))) + } + _ => Err("Name exactly one of activity or wbs.".into()), + } +} + +fn find_activity(p: &ProjectData, code: &str) -> std::result::Result { + let found: Vec = p + .model + .activities + .iter() + .enumerate() + .filter(|(_, a)| a.task_code == code) + .map(|(i, _)| i) + .collect(); + match found.as_slice() { + [i] => Ok(*i), + [] => Err(format!("No activity {code:?}.")), + _ => Err(format!("Activity ID {code:?} is not unique.")), + } +} + +fn find_resource(p: &ProjectData, name: &str) -> std::result::Result { + let t = p + .document + .table("RSRC") + .ok_or("The project has no resources.")?; + let ids = |exact: bool| -> Vec { + t.rows + .iter() + .filter(|r| { + let short = t.value(r, "rsrc_short_name"); + if exact { + short == name + } else { + short.eq_ignore_ascii_case(name.trim()) + } + }) + .map(|r| records::num(t.value(r, "rsrc_id"))) + .collect() + }; + let mut found = ids(true); + if found.is_empty() { + found = ids(false); + } + match found.as_slice() { + [id] => Ok(*id), + [] => Err(format!("No resource with short name {name:?}.")), + _ => Err(format!("Resource short name {name:?} is not unique.")), + } +} + +fn assignment_row(p: &ProjectData, task_id: i64, rsrc: i64) -> std::result::Result { + let pid = p.model.project.proj_id; + let rows: Vec = records::rows_for(&p.document, "TASKRSRC", task_id, pid) + .into_iter() + .filter(|&r| records::num(&records::get(&p.document, "TASKRSRC", r, "rsrc_id")) == rsrc) + .collect(); + match rows.as_slice() { + [r] => Ok(*r), + [] => Err("The resource is not assigned to the activity.".into()), + _ => Err("The resource is assigned to the activity more than once.".into()), + } +} + +/// The CALENDAR row id for a calendar name (" [project]", " [global]" or +/// " [resource]" tell two of the same name apart). +fn calendar_id(p: &ProjectData, name: &str) -> std::result::Result { + tables::calendar_id(p, name) +} + +/// The model calendar an activity can be assigned, by name. +fn calendar_index(p: &ProjectData, i: usize, name: &str) -> std::result::Result { + let id = calendar_id(p, name)?; + let current = p.model.activities[i].cal; + calendars::assignable(p, current) + .into_iter() + .find(|&c| p.model.calendars[c].id == id) + .ok_or_else(|| format!("Calendar {name:?} cannot be assigned in this project.")) +} + +fn link_type(kind: &str) -> std::result::Result { + Ok( + match kind.trim().to_ascii_uppercase().trim_start_matches("PR_") { + "FS" => LinkType::FS, + "SS" => LinkType::SS, + "FF" => LinkType::FF, + "SF" => LinkType::SF, + _ => { + return Err(format!( + "Unknown relationship type {kind:?}; use FS, SS, FF or SF." + )) + } + }, + ) +} + +fn parse_time(text: &str) -> std::result::Result { + let (h, m) = text + .trim() + .split_once(':') + .ok_or_else(|| format!("Shift time {text:?} must be HH:MM."))?; + let (h, m): (i64, i64) = ( + h.parse() + .map_err(|_| format!("Shift time {text:?} must be HH:MM."))?, + m.parse() + .map_err(|_| format!("Shift time {text:?} must be HH:MM."))?, + ); + if !(0..=24).contains(&h) || !(0..60).contains(&m) || (h == 24 && m != 0) { + return Err(format!("Shift time {text:?} is not a time of day.")); + } + Ok(h * 60 + m) +} + +/// Shifts as `[["08:00","12:00"],...]`: ordered, not overlapping; a finish +/// at or before its start (`00:00`, or `07:00` after `19:00`) runs past +/// midnight. +fn parse_shifts(list: &[[String; 2]]) -> std::result::Result, String> { + if list.len() > 10 { + return Err("At most ten shifts per day.".into()); + } + let mut out = vec![]; + let mut previous = 0; + for [start, finish] in list { + let s = parse_time(start)?; + let mut f = parse_time(finish)?; + // A finish at or before the start runs past midnight. + if f <= s { + f += 1440; + } + if s < previous || s >= 1440 || f - s > 1440 { + return Err("Shifts must be ordered, non-overlapping periods within the day.".into()); + } + previous = f; + out.push((s, f)); + } + Ok(out) +} + +// ----------------------------------------------------------------- values + +fn text(value: &Value) -> Option { + match value { + Value::Null => None, + Value::String(s) => Some(s.clone()), + other => Some(other.to_string()), + } +} + +fn number(value: &Value, what: &str) -> std::result::Result { + let n = match value { + Value::Number(n) => n.as_f64(), + Value::String(s) => s.trim().parse::().ok(), + _ => None, + }; + n.filter(|n| n.is_finite()) + .ok_or_else(|| format!("{what} must be a number.")) +} + +fn hours(value: &Value, what: &str) -> std::result::Result { + Ok((number(value, what)? * 60.).round() as i64) +} + +fn date(origin: i64, value: &Value) -> std::result::Result, String> { + match text(value) { + None => Ok(None), + Some(s) => parse_relative(origin, &s), + } +} + +fn needed(origin: i64, value: &Value, what: &str) -> std::result::Result { + date(origin, value)?.ok_or_else(|| format!("{what} needs a date.")) +} + +/// The activity fields `set_activity` takes, by OpenXER column key. +pub const ACTIVITY_FIELDS: &[&str] = &[ + "activity_id", + "activity_name", + "wbs", + "calendar", + "activity_type", + "activity_status", + "duration_type", + "percent_complete_type", + "activity_priority", + "primary_resource", + "original_duration", + "remaining_duration", + "actual_duration", + "at_completion_duration", + "actual_start", + "actual_finish", + "start", + "start_without_constraint", + "finish", + "planned_start", + "planned_finish", + "expected_finish", + "suspend_date", + "resume_date", + "physical_percent_complete", + "duration_percent_complete", + "activity_percent_complete", + "primary_constraint", + "primary_constraint_date", + "secondary_constraint", + "secondary_constraint_date", +]; + +/// One activity field through the shared setters. Returns whether it +/// changed and any follow-up warning. +fn set_activity( + p: &mut ProjectData, + i: usize, + field: &str, + value: &Value, +) -> std::result::Result<(bool, Option), String> { + let origin = p.model.origin_serial; + let choice = |what: &str| -> std::result::Result { + text(value).ok_or_else(|| format!("{what} needs a value.")) + }; + let edit = match field { + "activity_id" => return Ok((act::set_activity_id(p, i, &choice("Activity ID")?)?, None)), + "activity_name" => { + return Ok(( + act::set_activity_name(p, i, &records::clean(&text(value).unwrap_or_default()))?, + None, + )) + } + "wbs" => { + let path = choice("WBS")?; + Edit::Wbs(wbs::find_path(p, &path).ok_or_else(|| format!("No WBS element {path:?}."))?) + } + "calendar" => Edit::Calendar(calendar_index(p, i, &choice("Calendar")?)?), + "activity_type" => { + let t = choice("Activity Type")?; + Edit::ActivityType( + act::parse_task_type(&t) + .ok_or_else(|| format!("{t:?} is not an activity type."))?, + ) + } + "activity_status" => { + let t = choice("Activity Status")?; + Edit::Status( + act::parse_status(&t).ok_or_else(|| format!("{t:?} is not an activity status."))?, + ) + } + "duration_type" => { + let t = choice("Duration Type")?; + Edit::DurationType( + act::duration_type_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a duration type."))?, + ) + } + "percent_complete_type" => { + let t = choice("% Complete Type")?; + Edit::PercentType( + act::percent_type_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a percent complete type."))?, + ) + } + "activity_priority" => { + let t = choice("Activity Leveling Priority")?; + Edit::Priority( + act::priority_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a leveling priority."))?, + ) + } + "primary_resource" => match text(value).filter(|t| !t.trim().is_empty()) { + None => Edit::PrimaryResource(0), + Some(name) => Edit::PrimaryResource(find_resource(p, &name)?), + }, + "original_duration" => Edit::OriginalDuration(hours(value, "Original Duration")?), + "remaining_duration" => Edit::RemainingDuration(hours(value, "Remaining Duration")?), + "actual_duration" => Edit::ActualDuration(hours(value, "Actual Duration")?), + "at_completion_duration" => { + Edit::AtCompletionDuration(hours(value, "At Completion Duration")?) + } + "actual_start" => Edit::ActualStart(date(origin, value)?), + "actual_finish" => Edit::ActualFinish(date(origin, value)?), + "start" => Edit::Start(needed(origin, value, "Start")?), + "start_without_constraint" => Edit::StartUnheld(needed(origin, value, "Start")?), + "finish" => Edit::Finish(needed(origin, value, "Finish")?), + "planned_start" => Edit::PlannedStart(needed(origin, value, "Planned Start")?), + "planned_finish" => Edit::PlannedFinish(needed(origin, value, "Planned Finish")?), + "expected_finish" => Edit::ExpectedFinish(date(origin, value)?), + "suspend_date" => Edit::SuspendDate(date(origin, value)?), + "resume_date" => Edit::ResumeDate(date(origin, value)?), + "physical_percent_complete" => Edit::PhysicalPercent(number(value, "Physical % Complete")?), + "duration_percent_complete" => Edit::DurationPercent(number(value, "Duration % Complete")?), + "activity_percent_complete" => Edit::ActivityPercent(number(value, "Activity % Complete")?), + "primary_constraint" | "secondary_constraint" => { + let t = text(value).unwrap_or_default(); + Edit::Constraint { + secondary: field == "secondary_constraint", + kind: act::parse_constraint(&t) + .ok_or_else(|| format!("{t:?} is not a constraint type."))?, + } + } + "primary_constraint_date" | "secondary_constraint_date" => Edit::ConstraintDate { + secondary: field == "secondary_constraint_date", + date: date(origin, value)?, + }, + other => match figure_field(other) { + Some((None, measure)) => Edit::ThisPeriod { + measure, + value: number(value, other)?, + }, + Some((Some(phase), measure)) => Edit::Figure { + measure, + phase, + value: number(value, other)?, + }, + None => { + return Err(format!( + "Unknown activity field {other:?}; fields: {}, and the units and costs (budgeted_, actual_, remaining_, at_completion_ or this_period_ with labor_units, nonlabor_units, labor_cost, nonlabor_cost or material_cost).", + ACTIVITY_FIELDS.join(", ") + )) + } + }, + }; + match act::edit_activity(p, i, edit.clone()) { + Ok(outcome) => Ok((outcome.changed, outcome.warning)), + // A value the field already holds is no change, even where the + // field is locked (Remaining Duration 0 on a finished activity). + Err(_) if holds(p, i, &edit) => Ok((false, None)), + Err(e) => Err(e), + } +} + +/// A units or cost field of the Status tab: `budgeted_labor_units`, +/// `actual_labor_cost`, `this_period_nonlabor_units` (phase `None`)... +/// Units are hours for labor and nonlabor resources. +fn figure_field(field: &str) -> Option<(Option, act::Measure)> { + let (phase, rest) = if let Some(rest) = field.strip_prefix("this_period_") { + (None, rest) + } else { + let phase = act::Phase::ALL + .into_iter() + .find(|ph| field.starts_with(&format!("{}_", ph.key())))?; + (Some(phase), &field[phase.key().len() + 1..]) + }; + let measure = act::Measure::ALL + .into_iter() + .find(|m| m.key() == rest && m.editable())?; + Some((phase, measure)) +} + +/// Whether activity `i` already holds the value `edit` would set. +fn holds(p: &ProjectData, i: usize, edit: &Edit) -> bool { + let a = &p.model.activities[i]; + let d = p.details.get(&a.task_id); + match edit { + Edit::RemainingDuration(m) => a.rem == *m, + Edit::OriginalDuration(m) => d.is_some_and(|d| d.original_duration == *m), + Edit::ActualStart(v) => a.act_start == *v, + Edit::ActualFinish(v) => a.act_finish == *v, + Edit::ExpectedFinish(v) => a.expect_end == *v, + Edit::ResumeDate(v) => a.resume == *v, + Edit::PhysicalPercent(v) => d.is_some_and(|d| (d.percent - v).abs() < 1e-9), + Edit::ConstraintDate { + secondary: false, + date, + } => a.cstr_date == *date, + Edit::ConstraintDate { + secondary: true, + date, + } => a.cstr_date2 == *date, + _ => false, + } +} + +/// Whether assignment row `row` already holds `value` in `field`. +fn assignment_holds(p: &ProjectData, row: usize, field: &str, value: &Value) -> bool { + let Ok(column) = column_for(TASKRSRC_COLUMNS, &p.document, "TASKRSRC", field) else { + return false; + }; + let now = records::get(&p.document, "TASKRSRC", row, column); + if field == "rate_type" { + let wanted = text(value).and_then(|t| rate_type_code(&t)); + let now = if now.is_empty() { + "COST_PER_QTY".to_string() + } else { + now + }; + return wanted.as_deref() == Some(now.as_str()); + } + match (now.trim().parse::(), number(value, field)) { + (Ok(a), Ok(b)) => (a - b).abs() < 1e-9, + (Err(_), Ok(b)) => now.trim().is_empty() && b == 0., + _ => false, + } +} + +/// How `period_remaining_units` is written. +const PERIOD_FORM: &str = "period_remaining_units takes DATE=UNITS (one day), \ + START,FINISH=UNITS (those days, the units spread evenly over their working time) \ + or {\"start\", \"finish\", \"units\"}."; + +/// The value of `period_remaining_units`: the period (model minutes, from +/// the first day's start to the end of the last) and its units. +fn period_value(p: &ProjectData, value: &Value) -> std::result::Result<((i64, i64), f64), String> { + const DAY: i64 = 24 * 60; + let origin = p.model.origin_serial; + let (start, finish, units) = match value { + Value::Object(o) => { + let start = o.get("start").and_then(text).ok_or(PERIOD_FORM)?; + let finish = o.get("finish").and_then(text); + let units = number(o.get("units").ok_or(PERIOD_FORM)?, "Units")?; + (start, finish, units) + } + other => { + let t = text(other).ok_or(PERIOD_FORM)?; + let (dates, units) = t.rsplit_once('=').ok_or(PERIOD_FORM)?; + let (start, finish) = match dates.split_once(',') { + Some((s, f)) => (s.trim().to_string(), Some(f.trim().to_string())), + None => (dates.trim().to_string(), None), + }; + (start, finish, number(&Value::from(units.trim()), "Units")?) + } + }; + let day = |t: &str| -> std::result::Result { + let at = parse_relative(origin, t)?.ok_or_else(|| format!("{t:?} is not a date."))?; + Ok(at.div_euclid(DAY) * DAY) + }; + let first = day(&start)?; + let last = match finish { + Some(f) => day(&f)?, + None => first, + }; + if last < first { + return Err("The period's last day is before its first.".into()); + } + Ok(((first, last + DAY), units)) +} + +/// The assignment fields `set_assignment` takes. +pub const ASSIGNMENT_FIELDS: &[&str] = &[ + "lag_hours", + "planned_lag_hours", + "rate_type", + "rate_source", + "price_per_unit", + "at_completion_units", + "at_completion_cost", + "budgeted_units", + "remaining_units", + "budgeted_units_per_hour", + "remaining_units_per_hour", + "actual_regular_units", + "actual_overtime_units", + "budgeted_cost", + "remaining_cost", + "actual_regular_cost", + "actual_overtime_cost", + "actual_cost", + "this_period_units", + "this_period_cost", + "calculate_costs_from_units", + "overtime_factor", + "original_duration", + "remaining_duration", + "drive_activity_dates", + "resource", + "role", + "cost_account", + "curve", + "period_remaining_units", +]; + +/// An id from a dictionary table by name (or short name, or id). +fn dictionary_id( + p: &ProjectData, + table: &str, + key: &str, + names: &[&str], + value: &str, + what: &str, +) -> std::result::Result { + let t = p + .document + .table(table) + .ok_or_else(|| format!("The file has no {what}s."))?; + let wanted = value.trim(); + for exact in [true, false] { + let found: Vec = t + .rows + .iter() + .filter(|r| { + names.iter().any(|n| { + let v = t.value(r, n).trim(); + if exact { + v == wanted + } else { + v.eq_ignore_ascii_case(wanted) + } + }) + }) + .map(|r| records::num(t.value(r, key))) + .collect(); + match found.as_slice() { + [id] => return Ok(*id), + [] => {} + _ => return Err(format!("{what} {wanted:?} is not unique.")), + } + } + t.rows + .iter() + .map(|r| records::num(t.value(r, key))) + .find(|id| id.to_string() == wanted) + .ok_or_else(|| format!("No {what} {wanted:?}.")) +} + +/// The assignment edits that name records: `resource` (replace the +/// resource), `role` and `cost_account` (null clears); the rest as +/// [`assignment_edit`]. +fn assignment_edit_in( + p: &ProjectData, + field: &str, + value: &Value, +) -> std::result::Result { + let named = text(value).filter(|t| !t.trim().is_empty()); + Ok(match field { + "resource" => AE::Resource(find_resource(p, &named.ok_or("A resource is required.")?)?), + "role" => AE::Role(match named { + Some(n) => Some(dictionary_id( + p, + "ROLES", + "role_id", + &["role_short_name", "role_name"], + &n, + "role", + )?), + None => None, + }), + "cost_account" => AE::CostAccount(match named { + Some(n) => Some(dictionary_id( + p, + "ACCOUNT", + "acct_id", + &["acct_short_name", "acct_name"], + &n, + "cost account", + )?), + None => None, + }), + _ => assignment_edit(field, value)?, + }) +} + +/// A yes or no value: `true`, or the text true, y, yes or 1. +fn flag(value: &Value) -> bool { + match value { + Value::Bool(b) => *b, + other => matches!( + text(other) + .unwrap_or_default() + .to_ascii_lowercase() + .as_str(), + "true" | "y" | "yes" | "1" + ), + } +} + +fn assignment_edit(field: &str, value: &Value) -> std::result::Result { + let n = |what: &str| number(value, what); + Ok(match field { + "lag_hours" => AE::Lag(hours(value, "Lag")?), + "planned_lag_hours" => AE::PlannedLag(hours(value, "Planned Lag")?), + "rate_type" => { + let t = text(value).ok_or("Rate type needs a value.")?; + AE::RateType(rate_type_code(&t).ok_or_else(|| format!("{t:?} is not a rate type."))?) + } + "rate_source" => { + let t = text(value).ok_or("Rate source needs a value.")?; + let code = match t.trim().to_ascii_lowercase().as_str() { + "resource" | "st_rsrc" => "ST_Rsrc", + "role" | "st_role" => "ST_Role", + "override" | "st_custom" => "ST_Custom", + _ => return Err(format!("{t:?} is not a rate source.")), + }; + AE::RateSource(code.into()) + } + "price_per_unit" => AE::PricePerUnit(n("Price / Unit")?), + "at_completion_units" => AE::AtCompletionUnits(n("At Completion Units")?), + "at_completion_cost" => AE::AtCompletionCost(n("At Completion Cost")?), + "budgeted_units" => AE::BudgetedUnits(n("Budgeted Units")?), + "remaining_units" => AE::RemainingUnits(n("Remaining Units")?), + "budgeted_units_per_hour" => AE::BudgetedUnitsPerTime(n("Budgeted Units / Time")?), + "remaining_units_per_hour" => AE::RemainingUnitsPerTime(n("Remaining Units / Time")?), + "actual_regular_units" => AE::ActualRegularUnits(n("Actual Regular Units")?), + "actual_overtime_units" => AE::ActualOvertimeUnits(n("Actual Overtime Units")?), + "budgeted_cost" => AE::BudgetedCost(n("Budgeted Cost")?), + "remaining_cost" => AE::RemainingCost(n("Remaining Cost")?), + "actual_regular_cost" => AE::ActualRegularCost(n("Actual Regular Cost")?), + "actual_overtime_cost" => AE::ActualOvertimeCost(n("Actual Overtime Cost")?), + "this_period_units" => AE::ThisPeriodUnits(n("Actual This Period Units")?), + "this_period_cost" => AE::ThisPeriodCost(n("Actual This Period Cost")?), + "actual_cost" => AE::ActualCost(n("Actual Cost")?), + "overtime_factor" => AE::OvertimeFactor(n("Overtime Factor")?), + "original_duration" => AE::OriginalDuration(hours(value, "Original Duration")?), + "remaining_duration" => AE::RemainingDuration(hours(value, "Remaining Duration")?), + "drive_activity_dates" => AE::DriveActivityDates(flag(value)), + "calculate_costs_from_units" => AE::CostUnitsLinked(flag(value)), + other => { + return Err(format!( + "Unknown assignment field {other:?}; fields: {}.", + ASSIGNMENT_FIELDS.join(", ") + )) + } + }) +} + +fn rate_type_code(text: &str) -> Option { + let t = text.trim(); + let upper = t.to_ascii_uppercase(); + if let Some(n) = upper.strip_prefix("COST_PER_QTY") { + return matches!(n, "" | "2" | "3" | "4" | "5").then(|| upper.clone()); + } + let compact: String = t + .chars() + .filter(|c| !c.is_whitespace()) + .collect::() + .to_ascii_lowercase(); + Some( + match compact.as_str() { + "price/unit" => "COST_PER_QTY", + "price/unit2" => "COST_PER_QTY2", + "price/unit3" => "COST_PER_QTY3", + "price/unit4" => "COST_PER_QTY4", + "price/unit5" => "COST_PER_QTY5", + _ => return None, + } + .into(), + ) +} + +// ------------------------------------------------------- exact writes + +/// OpenXER activity keys and the TASK column each writes in exact mode. +const TASK_COLUMNS: &[(&str, &str)] = &[ + ("activity_name", "task_name"), + ("wbs", "wbs_id"), + ("calendar", "clndr_id"), + ("activity_type", "task_type"), + ("activity_status", "status_code"), + ("status", "status_code"), + ("planned_start", "target_start_date"), + ("planned_finish", "target_end_date"), + ("estimated_weight", "est_wt"), + ("lock_planned", "lock_plan_flag"), + ("review_required", "rev_fdbk_flag"), + ("auto_compute_actuals", "auto_compute_act_flag"), + ("actual_this_period_labor_units", "act_this_per_work_qty"), + ( + "actual_this_period_nonlabor_units", + "act_this_per_equip_qty", + ), + ("external_early_start", "external_early_start_date"), + ("external_late_finish", "external_late_end_date"), + ("location", "location_id"), + ("duration_type", "duration_type"), + ("percent_complete_type", "complete_pct_type"), + ("activity_priority", "priority_type"), + ("primary_resource", "rsrc_id"), + ("original_duration", "target_drtn_hr_cnt"), + ("remaining_duration", "remain_drtn_hr_cnt"), + ("actual_start", "act_start_date"), + ("actual_finish", "act_end_date"), + ("expected_finish", "expect_end_date"), + ("suspend_date", "suspend_date"), + ("resume_date", "resume_date"), + ("physical_percent_complete", "phys_complete_pct"), + ("primary_constraint", "cstr_type"), + ("primary_constraint_date", "cstr_date"), + ("secondary_constraint", "cstr_type2"), + ("secondary_constraint_date", "cstr_date2"), + ("budgeted_labor_units", "target_work_qty"), + ("actual_labor_units", "act_work_qty"), + ("remaining_labor_units", "remain_work_qty"), + ("budgeted_nonlabor_units", "target_equip_qty"), + ("actual_nonlabor_units", "act_equip_qty"), + ("remaining_nonlabor_units", "remain_equip_qty"), +]; + +/// OpenXER assignment keys and the TASKRSRC column each writes in exact mode. +const TASKRSRC_COLUMNS: &[(&str, &str)] = &[ + ("lag_hours", "target_lag_drtn_hr_cnt"), + ("planned_lag_hours", "target_lag_drtn_hr_cnt"), + ("remaining_lag_hours", "relag_drtn_hr_cnt"), + ("rate_type", "rate_type"), + ("price_per_unit", "cost_per_qty"), + ("budgeted_units", "target_qty"), + ("remaining_units", "remain_qty"), + ("budgeted_units_per_hour", "target_qty_per_hr"), + ("remaining_units_per_hour", "remain_qty_per_hr"), + ("actual_regular_units", "act_reg_qty"), + ("actual_overtime_units", "act_ot_qty"), + ("budgeted_cost", "target_cost"), + ("remaining_cost", "remain_cost"), + ("actual_regular_cost", "act_reg_cost"), + ("actual_overtime_cost", "act_ot_cost"), + ("overtime_factor", "ot_factor"), + ("actual_start", "act_start_date"), + ("actual_finish", "act_end_date"), + ("actual_this_period_units", "act_this_per_qty"), + ("actual_this_period_cost", "act_this_per_cost"), + ("calculate_costs_from_units", "cost_qty_link_flag"), + ("skill_level", "skill_level"), + ("drive_activity_dates", "rollup_dates_flag"), + ("budgeted_curve", "target_crv"), + ("remaining_curve", "remain_crv"), + ("actual_curve", "actual_crv"), + ("timesheet_pending_finish", "ts_pend_act_end_flag"), + ("curve", "curv_id"), + ("resource_type", "rsrc_type"), + ("rate_source", "cost_per_qty_source_type"), + ("has_resource_hours", "has_rsrchours"), +]; + +/// The cell text for an exact write: numbers as given, text as given. +fn exact_text(value: &Value) -> String { + match value { + Value::Null => String::new(), + Value::String(s) => records::clean(s), + other => other.to_string(), + } +} + +fn column_for<'a>( + map: &'a [(&'a str, &'a str)], + doc: &Document, + table: &str, + field: &'a str, +) -> std::result::Result<&'a str, String> { + if let Some((_, c)) = map.iter().find(|(k, _)| *k == field) { + return Ok(c); + } + let raw = openxer_xer::standard_fields(table).is_some_and(|f| f.contains(&field)) + || doc.table(table).is_some_and(|t| t.field(field).is_some()); + let protected = ["task_id", "proj_id", "taskrsrc_id", "task_code", "guid"]; + if raw && !protected.contains(&field) { + Ok(field) + } else { + Err(format!( + "{field:?} is not a {table} field that can be written exactly." + )) + } +} + +fn set_task_exact( + p: &mut ProjectData, + i: usize, + field: &str, + value: &Value, +) -> std::result::Result { + let column = column_for(TASK_COLUMNS, &p.document, "TASK", field)?.to_string(); + let t = text(value).unwrap_or_default(); + let task_id = p.model.activities[i].task_id; + let pid = p.model.project.proj_id; + // Identifiers and choices become the stored ids and codes. + let cell = match column.as_str() { + // Exact writes keep the milestone rule like every other path. + "task_type" => { + let to = act::parse_task_type(&t) + .ok_or_else(|| format!("{t:?} is not an activity type."))?; + let now = |c: &str| records::task_value(&p.document, task_id, pid, c); + let from = + act::parse_task_type(&now("task_type")).unwrap_or(p.model.activities[i].task_type); + let clear = openxer_xer::assignments::milestone_type_change( + p, + task_id, + &now("task_code"), + from, + to, + )?; + if clear { + records::set_task_value(&mut p.document, task_id, pid, "rsrc_id", String::new()); + } + to.as_str().into() + } + "wbs_id" => wbs::find_path(p, &t) + .ok_or_else(|| format!("No WBS element {t:?}."))? + .to_string(), + "clndr_id" => calendar_id(p, &t)?, + "rsrc_id" if !t.trim().is_empty() => find_resource(p, &t)?.to_string(), + "duration_type" => act::duration_type_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a duration type."))? + .into(), + "complete_pct_type" => act::percent_type_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a percent complete type."))? + .into(), + "priority_type" => act::priority_code(t.trim()) + .ok_or_else(|| format!("{t:?} is not a leveling priority."))? + .into(), + "cstr_type" | "cstr_type2" => openxer_xer::constraint_code( + act::parse_constraint(&t).ok_or_else(|| format!("{t:?} is not a constraint type."))?, + ) + .into(), + "status_code" if !t.starts_with("TK_") => match act::parse_status(&t) { + Some(openxer_engine::model::StatusType::NotStarted) => "TK_NotStart".into(), + Some(openxer_engine::model::StatusType::InProgress) => "TK_Active".into(), + Some(openxer_engine::model::StatusType::Completed) => "TK_Complete".into(), + None => return Err(format!("{t:?} is not an activity status.")), + }, + _ => exact_text(value), + }; + records::set_task_value(&mut p.document, task_id, pid, &column, cell); + Ok(column) +} + +fn set_assignment_exact( + p: &mut ProjectData, + row: usize, + field: &str, + value: &Value, +) -> std::result::Result { + let column = column_for(TASKRSRC_COLUMNS, &p.document, "TASKRSRC", field)?.to_string(); + let cell = match column.as_str() { + "rate_type" => { + let t = text(value).unwrap_or_default(); + rate_type_code(&t).ok_or_else(|| format!("{t:?} is not a rate type."))? + } + _ => exact_text(value), + }; + records::set(&mut p.document, "TASKRSRC", row, &column, cell); + Ok(column) +} + +// ------------------------------------------------------------------ diff + +/// The tables the edit operations write, as the diff reports them: table, +/// label and the columns a row is known by (activities by Activity ID and +/// resources by short name). The first seven have their own keys. +const DIFF_TABLES: &[(&str, &str, &[&str])] = &[ + ("TASK", "activities", &[]), + ("TASKRSRC", "assignments", &[]), + ("TASKPRED", "relationships", &[]), + ("PROJWBS", "wbs", &[]), + ("CALENDAR", "calendars", &[]), + ("DOCUMENT", "documents", &[]), + ("TASKDOC", "document_links", &[]), + ("PROJECT", "project", &["proj_id"]), + ("SCHEDOPTIONS", "schedule_options", &["schedoptions_id"]), + ("RSRC", "resources", &["rsrc_id"]), + ( + "RSRCRATE", + "resource_limits", + &["rsrc_id", "start_date", "shift_period_id"], + ), + ("ACTVTYPE", "code_types", &["actv_code_type_id"]), + ("ACTVCODE", "code_values", &["actv_code_id"]), + ( + "TASKACTV", + "activity_codes", + &["task_id", "actv_code_type_id"], + ), + ( + "PROJPCAT", + "project_codes", + &["proj_id", "proj_catg_type_id"], + ), + ("MEMOTYPE", "notebook_topics", &["memo_type_id"]), + ("TASKMEMO", "notebooks", &["task_id", "memo_type_id"]), + ("WBSMEMO", "wbs_notebooks", &["wbs_id", "memo_type_id"]), + ("UDFVALUE", "udf_values", &["udf_type_id", "fk_id"]), + ("PROJFUND", "funding", &["proj_fund_id"]), + ("PROJCOST", "expenses", &["cost_item_id"]), + ("PROJISSU", "issues", &["issue_id"]), + ("ISSUHIST", "issue_history", &["issue_id"]), + ("RISK", "risks", &["risk_id"]), + ("PROJRISK", "risks", &["risk_id"]), + ("TASKRISK", "risk_assignments", &["risk_id", "task_id"]), + ("PROJTHRS", "thresholds", &["thresh_id"]), + ("TASKPROC", "steps", &["proc_id"]), + ("PROCGROUP", "step_templates", &["proc_group_id"]), + ("PROCITEM", "step_template_steps", &["proc_item_id"]), + ("TASKNOTE", "notes_to_resources", &["task_id"]), + ("TASKFDBK", "feedback", &["task_id"]), + ("RSRCCURVDATA", "curves", &["curv_id"]), +]; + +/// Changed fields between two documents for the edited project, keyed the +/// way operations name things. +pub fn diff(before: &Document, after: &Document, pid: i64) -> Value { + let codes = |doc: &Document| -> BTreeMap { + doc.table("TASK") + .map(|t| { + t.rows + .iter() + .map(|r| { + ( + t.value(r, "task_id").to_string(), + t.value(r, "task_code").to_string(), + ) + }) + .collect() + }) + .unwrap_or_default() + }; + let resources = |doc: &Document| -> BTreeMap { + doc.table("RSRC") + .map(|t| { + t.rows + .iter() + .map(|r| { + ( + t.value(r, "rsrc_id").to_string(), + t.value(r, "rsrc_short_name").to_string(), + ) + }) + .collect() + }) + .unwrap_or_default() + }; + let (code_a, code_b) = (codes(before), codes(after)); + let (res_a, res_b) = (resources(before), resources(after)); + let pid = pid.to_string(); + type Keyed = BTreeMap>; + let keyed = |doc: &Document, + table: &str, + keys: &[&str], + code: &BTreeMap, + res: &BTreeMap| + -> Keyed { + let Some(t) = doc.table(table) else { + return Keyed::new(); + }; + let has_project = t.field("proj_id").is_some(); + // Rows of this project, and rows of no project (global calendars, + // code types, resource values). + t.rows + .iter() + .filter(|r| { + let owner = t.value(r, "proj_id"); + !has_project || owner == pid || owner.is_empty() || table == "CALENDAR" + }) + .map(|r| { + let c = |k: &str| code.get(t.value(r, k)).cloned().unwrap_or_default(); + let key = match table { + "TASK" => t.value(r, "task_code").to_string(), + "TASKRSRC" => format!( + "{}|{}", + c("task_id"), + res.get(t.value(r, "rsrc_id")).cloned().unwrap_or_default() + ), + "TASKPRED" => format!( + "{}|{}|{}", + c("pred_task_id"), + c("task_id"), + t.value(r, "pred_type") + ), + "CALENDAR" => t.value(r, "clndr_name").to_string(), + "DOCUMENT" => t.value(r, "doc_id").to_string(), + "TASKDOC" => match c("task_id") { + a if !a.is_empty() => format!("{}|{a}", t.value(r, "doc_id")), + _ => format!("{}|wbs {}", t.value(r, "doc_id"), t.value(r, "wbs_id")), + }, + "PROJWBS" => t.value(r, "wbs_id").to_string(), + // Activities by Activity ID, resources by short name, + // anything else by its stored id. + _ => keys + .iter() + .map(|k| match *k { + "task_id" => c(k), + "rsrc_id" => res.get(t.value(r, k)).cloned().unwrap_or_default(), + _ => t.value(r, k).to_string(), + }) + .collect::>() + .join("|"), + }; + let fields = t + .fields + .iter() + .zip(r.iter()) + .filter(|(f, _)| !matches!(f.as_str(), "update_date" | "update_user")) + .map(|(f, v)| (f.clone(), v.clone())) + .collect(); + (key, fields) + }) + .collect() + }; + let mut out = Map::new(); + let mut total = 0usize; + for &(table, label, keys) in DIFF_TABLES { + let a = keyed(before, table, keys, &code_a, &res_a); + let b = keyed(after, table, keys, &code_b, &res_b); + let keys: BTreeSet<&String> = a.keys().chain(b.keys()).collect(); + let mut added = vec![]; + let mut removed = vec![]; + let mut changed = Map::new(); + for k in keys { + match (a.get(k), b.get(k)) { + (None, Some(_)) => added.push(json!(k)), + (Some(_), None) => removed.push(json!(k)), + (Some(x), Some(y)) if x != y => { + let mut fields = Map::new(); + let names: BTreeSet<&String> = x.keys().chain(y.keys()).collect(); + for f in names { + let (old, new) = (x.get(f), y.get(f)); + if old.map_or("", String::as_str) != new.map_or("", String::as_str) { + fields.insert(f.clone(), json!({"before":old,"after":new})); + } + } + if !fields.is_empty() { + total += fields.len(); + changed.insert(k.clone(), Value::Object(fields)); + } + } + _ => {} + } + } + total += added.len() + removed.len(); + if !(added.is_empty() && removed.is_empty() && changed.is_empty()) { + // RISK and PROJRISK share a label (a file holds one or the + // other); should both change, neither hides the other. + let label = if out.contains_key(label) { + format!("{label}_{}", table.to_ascii_lowercase()) + } else { + label.to_string() + }; + out.insert( + label, + json!({"added":added,"removed":removed,"changed":changed}), + ); + } + } + out.insert("changed_field_count".into(), json!(total)); + Value::Object(out) +} + +/// A JSON value as a record cell: text as given, numbers as written, null +/// blank. +fn cell(value: &Value) -> Cell { + match value { + Value::Null => Cell::Null, + Value::String(t) => Cell::Text(t.clone()), + Value::Bool(b) => Cell::Text(if *b { "Y" } else { "N" }.into()), + other => Cell::Text(other.to_string()), + } +} + +/// Record edits: written into the document as given (the batch re-reads +/// the project before the next model edit or the schedule). +/// The JSON report of `merge_resources`: what moved where and what was +/// combined, plus the same lines the desktop preview shows. +fn merge_report(r: &resources::MergeReport) -> Value { + let pair = |moved: usize, dropped: usize| json!({"moved":moved,"dropped":dropped}); + let assignments: Vec = r + .assignments + .iter() + .map(|(c, n)| json!({"resource":c,"count":n})) + .collect(); + let combined: Vec = r + .combined + .iter() + .map(|c| json!({"activity":c.activity,"proj_id":c.proj_id,"assignments":c.rows})) + .collect(); + let other: Vec = r + .other + .iter() + .map(|(t, n)| json!({"table":t,"rows":n})) + .collect(); + json!({ + "op": "merge_resources", + "into": r.into_code, + "from": r.from.iter().map(|(_, c)| c.clone()).collect::>(), + "assignments_moved": assignments, + "combined": combined, + "primary_resource": r.primary, + "rates": pair(r.rates_moved, r.rates_kept), + "roles": pair(r.roles_moved, r.roles_kept), + "codes": pair(r.codes_moved, r.codes_kept), + "udf_values": pair(r.udfs_moved, r.udfs_kept), + "child_resources": r.children, + "calendar_taken": r.calendar, + "other_rows": other, + "summary": r.lines(), + }) +} + +fn record(p: &mut ProjectData, op: &Operation) -> std::result::Result { + let task = |p: &ProjectData, code: &str| -> std::result::Result { + find_activity(p, code).map(|i| p.model.activities[i].task_id) + }; + match op { + Operation::SetProject { field, value, .. } => { + tables::set_project_field(p, field, &cell(value))? + } + Operation::SetScheduleOption { field, value } => { + tables::set_schedule_option(p, field, &cell(value))? + } + Operation::SetResourceLimit { + resource, + from, + shift_period, + max_units_per_hour, + price_per_unit, + price_per_unit_2, + price_per_unit_3, + price_per_unit_4, + price_per_unit_5, + } => { + let remove = matches!(max_units_per_hour, Some(Value::Null)); + let values: Vec<(&str, Cell)> = [ + ("max_qty_per_hr", max_units_per_hour), + ("cost_per_qty", price_per_unit), + ("cost_per_qty2", price_per_unit_2), + ("cost_per_qty3", price_per_unit_3), + ("cost_per_qty4", price_per_unit_4), + ("cost_per_qty5", price_per_unit_5), + ] + .into_iter() + .filter_map(|(c, v)| v.as_ref().map(|v| (c, cell(v)))) + .collect(); + tables::set_resource_limit(p, resource, from, shift_period.as_deref(), &values, remove)? + } + Operation::SetActivityCode { + activity, + code_type, + value, + } => { + let id = task(p, activity)?; + let Some(value) = value else { + return Ok(unchanged(op, "value")); + }; + tables::set_activity_code(p, id, code_type, text(value).as_deref())? + } + Operation::SetProjectCode { code_type, value } => { + let Some(value) = value else { + return Ok(unchanged(op, "value")); + }; + openxer_xer::edit::project_codes::set_project_code( + p, + code_type, + text(value).as_deref(), + )? + } + Operation::AddCodeType { + code_type, + scope, + max_length, + } => tables::add_code_type( + p, + code_type, + scope.as_deref().unwrap_or("project"), + *max_length, + )?, + Operation::AddCodeValue { code_type, code } => tables::add_code_value(p, code_type, code)?, + Operation::SetCodeValue { + code_type, + code, + field, + value, + } => tables::set_code_value(p, code_type, code, field, &cell(value))?, + Operation::DeleteCodeValue { code_type, code } => { + tables::delete_code_value(p, code_type, code)? + } + Operation::SetNotebook { + activity, + topic, + text: given, + } => { + let id = task(p, activity)?; + let Some(given) = given else { + return Ok(unchanged(op, "text")); + }; + tables::set_notebook(p, id, topic, text(given).as_deref())? + } + Operation::SetWbsNotebook { + wbs, + topic, + text: given, + } => { + let Some(given) = given else { + return Ok(unchanged(op, "text")); + }; + tables::set_wbs_notebook(p, wbs, topic, text(given).as_deref())? + } + Operation::SetUdf { + activity, + resource, + step, + wbs, + project, + expense, + issue, + risk, + document, + udf, + value, + } => { + let named = [ + wbs.is_some(), + *project == Some(true), + expense.is_some(), + issue.is_some(), + risk.is_some(), + document.is_some(), + ]; + let others = named.iter().filter(|r| **r).count(); + let task_owner = activity.is_some() || resource.is_some(); + if others > 1 || (others == 1 && task_owner) { + return Err(UDF_OWNER.into()); + } + let (table, id) = match (activity, resource, step) { + (Some(a), Some(r), None) => { + let task_id = task(p, a)?; + let rsrc = tables::resource_id(p, r)?; + let row = assignment_row(p, task_id, rsrc)?; + let id = records::get(&p.document, "TASKRSRC", row, "taskrsrc_id"); + ("TASKRSRC", records::num(&id)) + } + (Some(a), None, Some(st)) => { + let task_id = task(p, a)?; + let row = steps::find_step(p, task_id, &text(st).unwrap_or_default())?; + let id = records::get(&p.document, "TASKPROC", row, "proc_id"); + ("TASKPROC", records::num(&id)) + } + (Some(a), None, None) => ("TASK", task(p, a)?), + (None, Some(r), None) => ("RSRC", tables::resource_id(p, r)?), + (None, None, None) if others == 1 => { + if let Some(w) = wbs { + ("PROJWBS", earned_value::wbs_id(p, w)?) + } else if let Some(e) = expense { + ("PROJCOST", project_records::find(p, Kind::Expense, e)?) + } else if let Some(i) = issue { + ("PROJISSU", project_records::find(p, Kind::Issue, i)?) + } else if let Some(r) = risk { + ("PROJRISK", project_records::find(p, Kind::Risk, r)?) + } else if let Some(d) = document { + ("DOCUMENT", documents::find(p, d)?) + } else { + ("PROJECT", p.model.project.proj_id) + } + } + // A stored value whose owner is not in the file (an orphan + // row) has no record to write to; it is reported, not written. + (None, None, None) => { + return Ok(json!({"op":"set_udf","udf":udf,"written":false, + "reason":"no record named; orphan values are not written"})) + } + _ => return Err(UDF_OWNER.into()), + }; + tables::set_udf(p, table, id, udf, &cell(value))? + } + Operation::AddCalendar { calendar } => tables::add_calendar(p, calendar)?, + Operation::SetCalendar { + calendar, + field, + value, + } => { + let written = tables::set_calendar(p, calendar, field, &cell(value))?; + return Ok( + json!({"op":"set_calendar","calendar":calendar,"field":field,"written":written}), + ); + } + Operation::DeleteCalendar { + calendar, + replacement, + default_global, + } => { + if replacement.is_none() && !*default_global { + tables::delete_calendar(p, calendar)? + } else if replacement.is_some() && *default_global { + return Err("Name a replacement or default_global, not both.".into()); + } else { + let moved = tables::delete_calendar_replacing(p, calendar, replacement.as_deref())?; + return Ok(json!({"op":"delete_calendar","calendar":calendar, + "replacement":replacement,"activities_moved":moved})); + } + } + Operation::AddResource { resource } => tables::add_resource(p, resource)?, + Operation::SetResource { + resource, + field, + value, + } => tables::set_resource(p, resource, field, &cell(value))?, + Operation::SetWbs { wbs, field, value } => { + tables::set_wbs_field(p, wbs, field, &cell(value))? + } + Operation::AddProjectFunding { + source, + amount, + share, + } => { + let text = + |v: &Option| v.as_ref().filter(|v| !v.is_null()).map(|v| cell(v).text()); + funding::add_by_source(p, source, text(amount).as_deref(), text(share).as_deref())? + } + Operation::SetProjectFunding { + source, + field, + value, + } => { + let field = funding::Field::parse(field)?; + let row = funding::row_by_source(p, source)?; + funding::set(p, row, field, &cell(value).text())? + } + Operation::DeleteProjectFunding { source } => { + let row = funding::row_by_source(p, source)?; + funding::delete(p, row)? + } + Operation::DeleteResource { resource } => { + let id = resources::find(&p.document, resource)?; + resources::delete(&mut p.document, id)? + } + Operation::MergeResources { from, into } => { + // A document edit: the batch re-reads the project afterwards. + let target = resources::find(&p.document, into)?; + let sources = from + .iter() + .map(|c| resources::find(&p.document, c)) + .collect::, String>>()?; + let report = resources::merge(&mut p.document, &sources, target)?; + return Ok(merge_report(&report)); + } + Operation::SetWbsEarnedValue { + wbs, + performance, + custom_percent, + estimate_to_complete, + performance_factor, + } => { + let id = earned_value::wbs_id(p, wbs)?; + let text = |v: &Option| v.as_ref().map(|v| cell(v).text()); + let changed = earned_value::set( + p, + id, + performance.as_deref(), + text(custom_percent).as_deref(), + estimate_to_complete.as_deref(), + text(performance_factor).as_deref(), + )?; + let t = earned_value::get(p, id)?; + return Ok( + json!({"op":"set_wbs_earned_value","wbs":wbs,"changed":changed, + "performance":t.performance,"custom_percent":t.custom_percent, + "estimate_to_complete":t.to_complete,"performance_factor":t.factor}), + ); + } + Operation::AddDocument { + title, + parent, + reference, + fields, + } => { + let parent = match parent.as_deref().filter(|t| !t.trim().is_empty()) { + Some(name) => Some(documents::find(p, name)?), + None => None, + }; + let id = documents::add(p, parent); + documents::set(p, id, documents::Field::Title, title)?; + if let Some(r) = reference { + documents::set(p, id, documents::Field::Reference, r)?; + } + for (name, value) in fields.iter().flatten() { + let field = documents::Field::parse(name)?; + documents::set(p, id, field, &cell(value).text())?; + } + return Ok(json!({"op":"add_document","document_id":id,"title":title})); + } + Operation::SetDocument { + document, + field, + value, + } => { + let id = documents::find(p, document)?; + let field = documents::Field::parse(field)?; + let changed = documents::set(p, id, field, &cell(value).text())?; + return Ok(json!({"op":"set_document","document_id":id,"changed":changed})); + } + Operation::DeleteDocument { document } => { + let id = documents::find(p, document)?; + let count = documents::delete(p, id); + return Ok(json!({"op":"delete_document","document_id":id,"deleted":count})); + } + Operation::LinkDocument { + document, + activity, + wbs, + work_product, + } => { + let id = documents::find(p, document)?; + let (t, w) = document_target(p, activity, wbs)?; + let added = documents::link(p, id, t, w); + if let Some(on) = work_product { + if let Some(row) = documents::link_row(p, id, t, w) { + documents::set_work_product(p, row, *on); + } + } + return Ok(json!({"op":"link_document","document_id":id,"added":added})); + } + Operation::UnlinkDocument { + document, + activity, + wbs, + } => { + let id = documents::find(p, document)?; + let (t, w) = document_target(p, activity, wbs)?; + if !documents::unlink(p, id, t, w) { + return Err(format!("Document {document:?} is not linked there.")); + } + } + Operation::AddExpense { + activity, + name, + fields, + } => { + let t = task(p, activity)?; + return add_register(p, op, Kind::Expense, Some(t), name, fields); + } + Operation::AddIssue { name, fields } => { + return add_register(p, op, Kind::Issue, None, name, fields) + } + Operation::AddRisk { name, fields } => { + return add_register(p, op, Kind::Risk, None, name, fields) + } + Operation::AddThreshold { parameter, fields } => { + let mut all = Map::new(); + if let Some(q) = parameter { + all.insert("parameter".into(), Value::String(q.clone())); + } + all.extend(fields.clone().unwrap_or_default()); + return add_register(p, op, Kind::Threshold, None, &None, &Some(all)); + } + Operation::SetExpense { + expense: r, + field, + value, + } + | Operation::SetIssue { + issue: r, + field, + value, + } + | Operation::SetRisk { + risk: r, + field, + value, + } + | Operation::SetThreshold { + threshold: r, + field, + value, + } => { + let kind = register_kind(op); + let id = project_records::find(p, kind, r)?; + let text = text(value); + let changed = project_records::set_field(p, kind, id, field, text.as_deref())?; + return Ok(json!({"op":op.name(),"id":id,"field":field,"changed":changed})); + } + Operation::DeleteExpense { expense: r } + | Operation::DeleteIssue { issue: r } + | Operation::DeleteRisk { risk: r } + | Operation::DeleteThreshold { threshold: r } => { + let kind = register_kind(op); + let id = project_records::find(p, kind, r)?; + project_records::delete(p, kind, id)?; + return Ok(json!({"op":op.name(),"id":id})); + } + Operation::CreateStepTemplate { activity, name } => { + let t = task(p, activity)?; + let pid = p.model.project.proj_id; + let id = steps::template_from_activity(&mut p.document, name, t, pid)?; + return Ok(json!({"op":"create_step_template","template_id":id, + "name":steps::templates(&p.document).into_iter().find(|x| x.id == id).map(|x| x.name)})); + } + Operation::SetFeedback { + activity, + notes, + review_required, + } => { + let t = task(p, activity)?; + let pid = p.model.project.proj_id; + if let Some(v) = notes { + let text = text(v).unwrap_or_default(); + let html = if records::looks_like_html(&text) || text.is_empty() { + text + } else { + records::text_to_memo(&text) + }; + project_records::set_notes_to_resources(&mut p.document, t, pid, html); + } + if let Some(on) = review_required { + project_records::set_review_required(&mut p.document, t, pid, *on); + } + } + Operation::RecalculateCosts { + active_only, + sync_overtime, + } => { + let pid = p.model.project.proj_id; + let r = progress::recalculate_assignment_costs( + &mut p.document, + pid, + *active_only, + *sync_overtime, + ); + return Ok(json!({"op":"recalculate_costs","updated":r.updated, + "unchanged":r.unchanged,"skipped":r.skipped})); + } + Operation::AssignRisk { risk, activity } | Operation::UnassignRisk { risk, activity } => { + let id = project_records::find(p, Kind::Risk, risk)?; + let t = task(p, activity)?; + let assign = matches!(op, Operation::AssignRisk { .. }); + let changed = project_records::set_risk_activity(p, id, t, assign); + if !changed && !assign { + return Err(format!("Risk {risk:?} is not assigned to {activity}.")); + } + return Ok(json!({"op":op.name(),"id":id,"changed":changed})); + } + Operation::DeleteFinancialPeriod { period, calendar } => { + openxer_xer::edit::financial_periods::delete_by_name(p, period, calendar.as_deref())? + } + _ => unreachable!("not a record edit"), + } + Ok(json!({"op":op.name(),"subject":op.subject()})) +} + +/// The result of an edit given nothing to write: a missing key changes +/// nothing (only an explicit null removes). +fn unchanged(op: &Operation, key: &str) -> Value { + json!({"op":op.name(),"subject":op.subject(),"changed":false, + "reason":format!("no {key} given; null removes it")}) +} + +/// What `set_udf` says when it names no one record. +const UDF_OWNER: &str = "set_udf names one record: activity, resource, activity and resource (an assignment), activity and step, wbs, project, expense, issue, risk or document."; + +fn register_kind(op: &Operation) -> Kind { + match op { + Operation::AddExpense { .. } + | Operation::SetExpense { .. } + | Operation::DeleteExpense { .. } => Kind::Expense, + Operation::AddIssue { .. } | Operation::SetIssue { .. } | Operation::DeleteIssue { .. } => { + Kind::Issue + } + Operation::AddThreshold { .. } + | Operation::SetThreshold { .. } + | Operation::DeleteThreshold { .. } => Kind::Threshold, + _ => Kind::Risk, + } +} + +/// Add a register record and set its name and fields; the id is reported. +fn add_register( + p: &mut ProjectData, + op: &Operation, + kind: Kind, + task_id: Option, + name: &Option, + fields: &Option>, +) -> std::result::Result { + let id = project_records::add(p, kind, task_id, &project_records::today())?; + if let Some(n) = name { + project_records::set_field(p, kind, id, "name", Some(n))?; + } + for (field, value) in fields.iter().flatten() { + project_records::set_field(p, kind, id, field, text(value).as_deref())?; + } + Ok(json!({"op":op.name(),"id":id,"record":register_json(p, kind, id)})) +} + +/// One register record as `records` lists it. +pub fn register_json(p: &ProjectData, kind: Kind, id: i64) -> Value { + let mut map = Map::new(); + map.insert("id".into(), json!(id)); + for (name, value) in project_records::record_values(p, kind, id) { + map.insert(name.into(), Value::String(value)); + } + if kind == Kind::Risk { + let pid = p.model.project.proj_id; + let acts: Vec = project_records::risk_activities(&p.document, pid, id) + .into_iter() + .map(|t| project_records::activity_label(p, t).0) + .collect(); + map.insert("activities".into(), json!(acts)); + } + Value::Object(map) +} diff --git a/automation/src/eps.rs b/automation/src/eps.rs new file mode 100644 index 0000000..481bbad --- /dev/null +++ b/automation/src/eps.rs @@ -0,0 +1,617 @@ +//! `eps list` and `eps` edits: the workspace EPS (project folders) with each +//! project's and folder's rollups, and folder and project filing edits. +//! Every rule comes from `openxer_xer::workspace`, the code the desktop app +//! uses, so a folder deleted here takes its folders and projects exactly as +//! the app does and a project created here passes the New Project wizard's +//! checks. +use crate::storage::{self, invalid, io, parent}; +use crate::{AutomationError, Result}; +use openxer_xer::workspace::new_project::{self, Entry}; +use openxer_xer::workspace::rollup::{self, Rollup}; +use openxer_xer::workspace::{Workspace, KEY}; +use openxer_xer::{date_string, parse_absolute, Document}; +use rusqlite::{params, Connection, OptionalExtension}; +use serde::Deserialize; +use serde_json::{json, Value}; +use std::collections::BTreeMap; +use std::path::{Path, PathBuf}; + +/// One EPS edit. +#[derive(Debug, Clone, Deserialize)] +#[serde(tag = "op", rename_all = "snake_case", deny_unknown_fields)] +pub enum EpsOperation { + /// Add a folder under `parent` (an EPS ID; the top level when omitted). + AddFolder { + name: String, + #[serde(default)] + eps_id: Option, + #[serde(default)] + parent: Option, + }, + /// Rename a folder or change its EPS ID. + RenameFolder { + folder: String, + #[serde(default)] + name: Option, + #[serde(default)] + new_eps_id: Option, + }, + /// Move a folder under `parent` (the top level when omitted). + MoveFolder { + folder: String, + #[serde(default)] + parent: Option, + }, + /// Delete a folder with the folders under it and every project filed in + /// them, with those projects' baselines. A folder that holds projects + /// is deleted only with `delete_projects` true (a dry run reports what + /// would go without it). + DeleteFolder { + folder: String, + #[serde(default)] + delete_projects: bool, + }, + /// File a workspace project under a folder. + FileProject { workspace_id: i64, folder: String }, + /// Create an empty project in a folder with the New Project wizard's + /// rules. + CreateProject { + folder: String, + project_id: String, + #[serde(default)] + name: Option, + planned_start: String, + #[serde(default)] + must_finish: Option, + /// Responsible manager: an OBS name or id. + #[serde(default)] + manager: Option, + /// COST_PER_QTY .. COST_PER_QTY5, or a label such as "Price / Unit2". + #[serde(default)] + rate_type: Option, + }, +} + +fn args(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +fn not_found(message: impl Into) -> AutomationError { + AutomationError::new("not_found", message) +} + +fn has_table(c: &Connection, name: &str) -> bool { + c.query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name=?1", + [name], + |_| Ok(()), + ) + .optional() + .ok() + .flatten() + .is_some() +} + +fn read_workspace(c: &Connection) -> Result { + if !has_table(c, "preferences") { + return Ok(Workspace::default()); + } + let text: Option = c + .query_row("SELECT value FROM preferences WHERE key=?1", [KEY], |r| { + r.get(0) + }) + .optional() + .map_err(invalid)?; + Ok(Workspace::from_text(&text.unwrap_or_default())) +} + +/// A workspace project row as `eps list` reads it. +struct Stored { + id: i64, + key: i64, + title: String, + text: String, +} + +fn stored_projects(c: &Connection) -> Result> { + let mut stmt = c + .prepare("SELECT id,project_key,title,xer_content FROM projects ORDER BY id") + .map_err(invalid)?; + let rows = stmt + .query_map([], |r| { + Ok(Stored { + id: r.get(0)?, + key: r.get(1)?, + title: r.get(2)?, + text: r.get(3)?, + }) + }) + .map_err(invalid)?; + rows.collect::, _>>() + .map_err(invalid) +} + +/// Baseline (start, finish) of workspace project `id`, chosen as the app +/// chooses: its project baseline, else a stored Primary baseline. +fn baseline_dates( + c: &Connection, + id: i64, + doc: &Document, + key: i64, +) -> Option<(Option, Option)> { + if !has_table(c, "baselines") { + return None; + } + let mut stmt = c + .prepare("SELECT id,project_key FROM baselines WHERE parent=?1 ORDER BY id") + .ok()?; + let pairs: Vec<(i64, i64)> = stmt + .query_map([id], |r| Ok((r.get(0)?, r.get(1)?))) + .ok()? + .filter_map(|r| r.ok()) + .collect(); + if pairs.is_empty() { + return None; + } + let primary = has_table(c, "baseline_assign") + .then(|| { + c.query_row( + "SELECT primary_bl FROM baseline_assign WHERE parent=?1", + [id], + |r| r.get::<_, String>(0), + ) + .ok() + }) + .flatten() + .and_then(|s| s.trim().parse::().ok()); + let pick = rollup::pick_baseline(rollup::assigned_baseline(doc, key), &pairs, primary)?; + let (text, bkey): (String, i64) = c + .query_row( + "SELECT xer_content,project_key FROM baselines WHERE id=?1", + [pick], + |r| Ok((r.get(0)?, r.get(1)?)), + ) + .ok()?; + let bl = Document::parse(&text).ok()?; + rollup::of_document(&bl, bkey).map(|r| (r.start, r.finish)) +} + +fn date(v: Option) -> Value { + v.map_or(Value::Null, |v| json!(date_string(0, Some(v)))) +} + +fn hours(v: Option) -> Value { + v.map_or(Value::Null, |m| json!(m as f64 / 60.)) +} + +fn round(v: f64, places: i32) -> f64 { + let k = 10f64.powi(places); + (v * k).round() / k +} + +fn amounts(a: &rollup::Amounts) -> Value { + json!({"budgeted": round(a.budgeted, 4), "actual": round(a.actual, 4), "remaining": round(a.remaining, 4)}) +} + +/// The rollup as JSON: dates `YYYY-MM-DD HH:MM`, float and variance in +/// working hours, the percent with two decimals. +pub fn rollup_json(r: &Rollup) -> Value { + json!({ + "start": date(r.start), + "finish": date(r.finish), + "late_start": date(r.late_start), + "late_finish": date(r.late_finish), + "actual_start": date(r.actual_start), + "actual_finish": date(r.actual_finish), + "data_date": date(r.data_date), + "must_finish_by": date(r.must_finish), + "baseline_finish": date(r.baseline_finish), + "finish_variance_hours": hours(r.finish_variance()), + "total_float_hours": hours(r.total_float), + "schedule_percent_complete": r.schedule_percent().map(|v| round(v, 2)), + "labor_units_hours": amounts(&r.labor_units), + "costs": amounts(&r.costs), + "activities": r.activities, + "not_started": r.not_started, + "in_progress": r.in_progress, + "completed": r.completed, + "projects": r.projects, + "working_time_calendar": if r.mixed_calendars { json!(null) } else { r.calendar.as_ref().map(|c| json!(c.name)).unwrap_or(Value::Null) }, + }) +} + +const RULES: &str = "Dates are the earliest start and latest finish (actual, else early) of the activities; a folder shows its projects' earliest start, latest finish, latest data date and latest Must Finish By. Total float is the lowest of the unfinished activities (a folder: the lowest of its projects). Units and costs add up; labor units count labor resources, costs every assignment plus expenses. Schedule percent complete is duration based: (planned span - remaining span) / planned span, in working time of the shared default calendar (else the standard calendar). Values are read from the stored projects; nothing needs summarizing first."; + +/// The EPS tree of a workspace with every project and folder rollup. +pub fn list(input: &Path) -> Result { + if !storage::is_database(input)? { + return Err(args("eps list needs an OpenXER workspace database (.db)")); + } + let c = storage::read_database(input)?; + let ws = read_workspace(&c)?; + let mut rollups: BTreeMap = BTreeMap::new(); + let mut projects = vec![]; + // A schema 3 workspace keeps the shared calendars, resources and codes + // in its dictionary; each project gets them back, as the app opens it. + let shared = crate::storage::shared(&c)?; + for p in stored_projects(&c)? { + let Ok(mut doc) = Document::parse(&p.text) else { + continue; + }; + if shared { + crate::workspace_db::hydrate(&c, &mut doc, Some(p.id)).map_err(invalid)?; + } + let mut r = rollup::of_document(&doc, p.key).unwrap_or_default(); + if let Some((s, f)) = baseline_dates(&c, p.id, &doc, p.key) { + r.set_baseline(s, f); + } + let node = doc.table("PROJWBS").and_then(|t| { + t.rows + .iter() + .find(|row| { + t.value(row, "proj_id").trim() == p.key.to_string() + && t.value(row, "proj_node_flag") == "Y" + }) + .map(|row| { + ( + t.value(row, "wbs_name").to_string(), + t.value(row, "status_code").to_string(), + ) + }) + }); + let folder = ws.node_of(Some(p.id)); + projects.push(json!({ + "workspace_id": p.id, + "project_id": p.title, + "project_key": p.key, + "name": node.as_ref().map(|n| n.0.clone()).filter(|n| !n.is_empty()).unwrap_or_else(|| p.title.clone()), + "status": node.as_ref().map(|n| n.1.clone()).unwrap_or_default(), + "folder": ws.eps_value(folder, "eps_short_name"), + "rollup": rollup_json(&r), + })); + rollups.insert(p.id, r); + } + let ids: Vec = rollups.keys().copied().collect(); + let nodes = ws.eps(); + let folders: Vec = nodes + .iter() + .map(|n| { + let mut total = Rollup::default(); + for id in ws.projects_under(n.id, &ids) { + total.add(&rollups[&id]); + } + let own: Vec = ids + .iter() + .copied() + .filter(|id| ws.node_of(Some(*id)) == n.id) + .collect(); + json!({ + "eps_id": ws.eps_value(n.id, "eps_short_name"), + "name": ws.eps_value(n.id, "eps_name"), + "parent": n.parent.map(|p| ws.eps_value(p, "eps_short_name")), + "depth": n.depth, + "path": ws.path(n.id), + "projects": own, + "rollup": rollup_json(&total), + }) + }) + .collect(); + Ok(json!({"input": input, "folders": folders, "projects": projects, "rules": RULES})) +} + +/// Rows of `table` whose `parent` is workspace project `id` (0 when the +/// table does not exist). +fn count_rows(c: &Connection, table: &str, id: i64) -> Result { + if !has_table(c, table) { + return Ok(0); + } + c.query_row( + &format!("SELECT COUNT(*) FROM {table} WHERE parent=?1"), + [id], + |r| r.get(0), + ) + .map_err(invalid) +} + +/// Remove workspace project `id` with its baselines and Assign Baselines +/// choices, as the app's project delete does. +fn remove_project(c: &Connection, id: i64) -> Result<()> { + for table in ["baselines", "baseline_assign"] { + if has_table(c, table) { + c.execute(&format!("DELETE FROM {table} WHERE parent=?1"), [id]) + .map_err(io)?; + } + } + c.execute("DELETE FROM projects WHERE id=?1", [id]) + .map_err(io)?; + Ok(()) +} + +fn folder(ws: &Workspace, code: &str) -> Result { + ws.find(code).ok_or_else(|| { + not_found(format!( + "No EPS folder has the EPS ID {code:?}; see eps list" + )) + }) +} + +fn folder_opt(ws: &Workspace, code: Option<&str>) -> Result> { + code.map(|c| folder(ws, c)).transpose() +} + +/// An OBS id from a name or id in `obs`. +fn manager_id(obs: Option<&openxer_xer::Table>, text: &str) -> Result { + let t = obs.ok_or_else(|| { + not_found("The workspace has no responsible managers (OBS) to choose from") + })?; + t.rows + .iter() + .find(|r| { + t.value(r, "obs_id").trim() == text.trim() + || t.value(r, "obs_name") + .trim() + .eq_ignore_ascii_case(text.trim()) + }) + .map(|r| t.value(r, "obs_id").trim().to_string()) + .ok_or_else(|| not_found(format!("No responsible manager is named {text:?}"))) +} + +/// Run one EPS edit on a copy of `input` written to `output` (or, with +/// `dry_run`, only report what it would do). +pub fn edit( + input: &Path, + output: Option, + dry_run: bool, + op: &EpsOperation, +) -> Result { + match (&output, dry_run) { + (Some(_), true) => return Err(args("dry_run writes nothing; omit output")), + (None, false) => return Err(args("output is required unless dry_run is true")), + (Some(path), false) => { + storage::check_destination(path)?; + if !storage::is_database_extension(path) { + return Err(args( + "eps edits write an OpenXER workspace (.db/.sqlite/.sqlite3)", + )); + } + } + (None, true) => {} + } + if !storage::is_database(input)? { + return Err(args("eps edits need an OpenXER workspace database input")); + } + let source = storage::read_database(input)?; + let temp_dir; + let temp = match &output { + Some(path) => tempfile::NamedTempFile::new_in(parent(path)).map_err(io)?, + None => { + temp_dir = std::env::temp_dir(); + tempfile::NamedTempFile::new_in(&temp_dir).map_err(io)? + } + }; + source.backup("main", temp.path(), None).map_err(io)?; + drop(source); + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE").map_err(io)?; + let tx = c.transaction().map_err(io)?; + storage::schema(&tx)?; + let mut ws = read_workspace(&tx)?; + let ids: Vec = stored_projects(&tx)?.iter().map(|p| p.id).collect(); + let fail = |e: String| AutomationError::new("refused", e); + let result = match op { + EpsOperation::AddFolder { + name, + eps_id, + parent, + } => { + let parent = folder_opt(&ws, parent.as_deref())?; + let id = ws + .add_folder(parent, name, eps_id.as_deref()) + .map_err(fail)?; + json!({"added": ws.eps_value(id, "eps_short_name"), "path": ws.path(id)}) + } + EpsOperation::RenameFolder { + folder: f, + name, + new_eps_id, + } => { + if name.is_none() && new_eps_id.is_none() { + return Err(args("rename_folder needs name or new_eps_id")); + } + let id = folder(&ws, f)?; + let changed = ws + .rename_folder(id, name.as_deref(), new_eps_id.as_deref()) + .map_err(fail)?; + json!({"folder": ws.eps_value(id, "eps_short_name"), "path": ws.path(id), "changed": changed}) + } + EpsOperation::MoveFolder { folder: f, parent } => { + let id = folder(&ws, f)?; + let to = folder_opt(&ws, parent.as_deref())?; + let changed = ws.move_folder(id, to).map_err(fail)?; + json!({"folder": ws.eps_value(id, "eps_short_name"), "path": ws.path(id), "changed": changed}) + } + EpsOperation::DeleteFolder { + folder: f, + delete_projects, + } => { + let id = folder(&ws, f)?; + let (nodes, going) = ws.folder_contents(id, &ids); + let gone: Vec = nodes + .iter() + .map(|n| ws.eps_value(*n, "eps_short_name")) + .collect(); + let titles = stored_projects(&tx)?; + let projects: Vec = going + .iter() + .map(|p| { + let title = titles + .iter() + .find(|s| s.id == *p) + .map_or("", |s| s.title.as_str()); + json!({"workspace_id": p, "project_id": title}) + }) + .collect(); + let baselines = going + .iter() + .map(|p| count_rows(&tx, "baselines", *p)) + .sum::>()?; + if !going.is_empty() && !delete_projects && !dry_run { + return Err(AutomationError::new( + "refused", + format!( + "Folder {f} holds {} project(s) ({} item(s) with its folders); deleting it deletes them with their {baselines} baseline(s). Pass delete_projects true (--delete-projects) to delete them, or file them elsewhere first.", + going.len(), + nodes.len() + going.len() + ), + )); + } + ws.delete_eps(id, &ids).map_err(fail)?; + for p in &going { + remove_project(&tx, *p)?; + } + json!({"deleted": gone, "projects_deleted": projects, + "baselines_deleted": baselines, + "items": nodes.len() + going.len()}) + } + EpsOperation::FileProject { + workspace_id, + folder: f, + } => { + if !ids.contains(workspace_id) { + return Err(not_found(format!( + "No workspace project has the id {workspace_id}" + ))); + } + let id = folder(&ws, f)?; + let changed = ws.place(*workspace_id, id).map_err(fail)?; + json!({"workspace_id": workspace_id, "folder": ws.eps_value(id, "eps_short_name"), "changed": changed}) + } + EpsOperation::CreateProject { + folder: f, + project_id, + name, + planned_start, + must_finish, + manager, + rate_type, + } => { + let shared = storage::shared(&tx)?; + let eps = folder(&ws, f)?; + let origin = new_project::origin(); + let at = |text: &str, hour: i64| -> Result> { + if text.trim().is_empty() { + return Ok(None); + } + let has_time = text.trim().contains(':'); + let v = parse_absolute(text).ok_or_else(|| { + args(format!( + "{text:?} is not a date; use YYYY-MM-DD or YYYY-MM-DD HH:MM" + )) + })?; + Ok(Some( + v - origin * openxer_engine::calendar::DAY + + if has_time { 0 } else { hour * 60 }, + )) + }; + let start = at(planned_start, new_project::START_HOUR)?; + let finish = must_finish + .as_deref() + .map(|t| at(t, new_project::FINISH_HOUR)) + .transpose()? + .flatten(); + let titles: Vec = stored_projects(&tx)?.into_iter().map(|p| p.title).collect(); + // The managers the app's wizard offers: those of the project + // last open in the app, else of the first project. + let last: Option = tx + .query_row( + "SELECT value FROM preferences WHERE key='last_project'", + [], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + // With a shared dictionary the managers are in it. + let dictionary = if shared { + crate::workspace_db::read_dictionary(&tx) + .map_err(invalid)? + .0 + .table("OBS") + .cloned() + } else { + last.and_then(|v| v.parse::().ok()) + .or_else(|| ids.first().copied()) + .and_then(|id| { + tx.query_row("SELECT xer_content FROM projects WHERE id=?1", [id], |r| { + r.get::<_, String>(0) + }) + .ok() + }) + .and_then(|text| Document::parse(&text).ok()) + .and_then(|d| d.table("OBS").cloned()) + }; + let manager = match manager { + Some(m) => manager_id(dictionary.as_ref(), m)?, + None => String::new(), + }; + let nodes: Vec = ws.eps().iter().map(|n| n.id).collect(); + let spec = new_project::check( + &Entry { + eps, + project_id, + name: name.as_deref().unwrap_or(""), + planned_start: start, + must_finish: finish, + manager: &manager, + rate_type: rate_type.as_deref().unwrap_or(""), + }, + &titles, + &nodes, + ) + .map_err(fail)?; + // An internal number of its own, as File > New gives. + let number = crate::baseline_store::next_project_number(&tx, &[]).map_err(invalid)?; + let mut p = new_project::build(&spec, dictionary.as_ref(), number).map_err(fail)?; + let key = p.model.project.proj_id; + let mut source = spec.project_id.clone(); + let mut n = 2; + while tx + .query_row( + "SELECT 1 FROM projects WHERE source_name=?1 AND project_key=?2", + params![source, key], + |_| Ok(()), + ) + .optional() + .map_err(io)? + .is_some() + { + source = format!("{} ({n})", spec.project_id); + n += 1; + } + p.source_name = source; + let id = storage::store(&tx, &p, None, None)?; + ws.place(id, eps).map_err(fail)?; + json!({"workspace_id": id, "project_id": spec.project_id, "name": spec.name, + "project_number": p.model.project.proj_id, + "folder": ws.eps_value(eps, "eps_short_name"), + "planned_start": date_string(p.model.origin_serial, Some(spec.planned_start)), + "must_finish_by": spec.must_finish.map(|f| date_string(p.model.origin_serial, Some(f))), + "rate_type": spec.rate_type}) + } + }; + tx.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO UPDATE SET value=excluded.value", + params![KEY, ws.to_text()], + ) + .map_err(io)?; + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + let summary: Vec = ws + .eps() + .iter() + .map(|n| json!({"eps_id": ws.eps_value(n.id, "eps_short_name"), "name": ws.eps_value(n.id, "eps_name"), "depth": n.depth})) + .collect(); + if let Some(path) = &output { + storage::publish(temp, path)?; + } + Ok(json!({"output": output, "dry_run": dry_run, "result": result, "folders": summary})) +} diff --git a/automation/src/global_change.rs b/automation/src/global_change.rs new file mode 100644 index 0000000..7d21c4d --- /dev/null +++ b/automation/src/global_change.rs @@ -0,0 +1,91 @@ +//! Global Change definitions saved in a workspace: the app keeps them in the +//! `preferences` row `openxer_xer::edit::global_change::PREFERENCE_KEY`, and +//! a `global_change` edit that names one runs that definition. +use crate::edit::Operation; +use crate::storage::{self, invalid}; +use crate::{AutomationError, Result}; +use openxer_xer::edit::global_change::{self as gc, GlobalChange}; +use rusqlite::OptionalExtension; +use std::path::Path; + +/// The definitions saved in workspace `input`; none for an XER input or a +/// workspace without any. +pub fn saved(input: &Path) -> Result> { + if !storage::is_database(input)? { + return Ok(vec![]); + } + let c = storage::read_database(input)?; + let has_table = c + .query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name='preferences'", + [], + |_| Ok(()), + ) + .optional() + .map_err(invalid)? + .is_some(); + if !has_table { + return Ok(vec![]); + } + let text: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [gc::PREFERENCE_KEY], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + match text { + None => Ok(vec![]), + Some(text) => gc::from_json(&text).map_err(|e| { + AutomationError::new( + "invalid_source", + format!("The workspace's saved global changes cannot be read: {e}"), + ) + }), + } +} + +/// `operations` with every `global_change` that names a saved definition +/// (and gives no rule) carrying that definition as its rule. A name that is +/// not saved is refused with the saved names. +pub fn resolve(input: &Path, operations: &[Operation]) -> Result> { + let named = |op: &Operation| match op { + Operation::GlobalChange { name, rule: None } => name.clone(), + _ => None, + }; + if !operations.iter().any(|op| named(op).is_some()) { + return Ok(operations.to_vec()); + } + let list = saved(input)?; + let mut out = vec![]; + for op in operations { + let Some(name) = named(op) else { + out.push(op.clone()); + continue; + }; + let wanted = name.trim(); + let Some(g) = list.iter().find(|g| g.name.eq_ignore_ascii_case(wanted)) else { + let names: Vec<&str> = list.iter().map(|g| g.name.as_str()).collect(); + let message = if names.is_empty() { + format!( + "No saved global change named {name:?}: the input has none (they are \ + saved in an OpenXER workspace); give rule instead" + ) + } else { + format!( + "No saved global change named {name:?}; saved: {}", + names.join(", ") + ) + }; + return Err(AutomationError::new("invalid_arguments", message)); + }; + let rule = serde_json::to_value(g) + .map_err(|e| AutomationError::new("invalid_source", e.to_string()))?; + out.push(Operation::GlobalChange { + name: Some(g.name.clone()), + rule: Some(rule), + }); + } + Ok(out) +} diff --git a/automation/src/interchange.rs b/automation/src/interchange.rs new file mode 100644 index 0000000..7dcbaa4 --- /dev/null +++ b/automation/src/interchange.rs @@ -0,0 +1,532 @@ +//! Spreadsheet export/import and XER import actions for the shared dispatcher. +//! Outputs follow the crate rule: always a new file, published without overwriting. +use crate::storage::{self, invalid, io, parent, publish}; +use crate::{project_json, AutomationError, Result}; +use openxer_interchange::columns::{Column, DurationUnit, Lookup}; +use openxer_interchange::export_template::{self, ExportTemplate}; +use openxer_interchange::xer_export::export_document; +use openxer_interchange::xer_merge::{merge_project, ImportConfig}; +use openxer_interchange::xlsx_export::{modern_workbook, tables_workbook, ExportOptions}; +use openxer_interchange::xlsx_import as xi; +use openxer_xer::{Document, ProjectData}; +use rusqlite::{params, Connection, OptionalExtension}; +use serde_json::{json, Value}; +use std::path::Path; + +fn args(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +pub(crate) fn check_new_output(path: &Path, extensions: &[&str]) -> Result<()> { + if path.as_os_str().is_empty() { + return Err(args("output path cannot be empty")); + } + if std::fs::symlink_metadata(path).is_ok() { + return Err(AutomationError::new( + "output_exists", + format!("Destination already exists: {}", path.display()), + )); + } + let ok = path + .extension() + .and_then(|e| e.to_str()) + .is_some_and(|e| extensions.iter().any(|x| x.eq_ignore_ascii_case(e))); + if !ok { + return Err(args(format!( + "Output must end in .{}", + extensions.join(", .") + ))); + } + if !parent(path).is_dir() { + return Err(io("Output parent directory does not exist")); + } + Ok(()) +} + +fn unit(text: Option<&str>) -> Result { + match text { + None => Ok(DurationUnit::Days), + Some(t) => DurationUnit::parse(t).ok_or_else(|| args("unit must be days or hours")), + } +} + +/// A saved export template: a `.json` file, else a name saved in the +/// workspace database `input`. +fn load_template(input: &Path, spec: &str) -> Result { + let path = Path::new(spec); + if spec.to_ascii_lowercase().ends_with(".json") || path.is_file() { + let text = std::fs::read_to_string(path) + .map_err(|e| args(format!("Cannot read the template file {spec:?}: {e}")))?; + return export_template::parse_one(&text).map_err(invalid); + } + if !storage::is_database(input)? { + return Err(args( + "Template names are saved in a workspace; give a workspace input or a template .json file", + )); + } + let c = storage::read_database(input)?; + let text: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [export_template::PREFERENCE_KEY], + |r| r.get(0), + ) + .optional() + .map_err(io)?; + let (list, rejected) = export_template::parse_list(&text.unwrap_or_default()); + export_template::find(&list, spec).cloned().ok_or_else(|| { + let mut message = format!("No saved export template is named {spec:?}"); + if list.is_empty() { + message.push_str(" (the workspace has none)"); + } else { + let names: Vec<&str> = list.iter().map(|t| t.name.as_str()).collect(); + message.push_str(&format!("; saved templates: {}", names.join(", "))); + } + for r in rejected { + message.push_str(&format!(". {r}")); + } + AutomationError::new("template_not_found", message) + }) +} + +/// `export-xlsx`: modern (default) or tables-layout spreadsheet of one project. +#[allow(clippy::too_many_arguments)] +pub(crate) fn export_xlsx( + input: &Path, + output: &Path, + project_id: Option, + workspace_id: Option, + layout: Option<&str>, + unit_text: Option<&str>, + columns: Option<&str>, + template: Option<&str>, +) -> Result { + check_new_output(output, &["xlsx"])?; + if template.is_some() && (columns.is_some() || unit_text.is_some()) { + return Err(args( + "A template sets the columns and the unit; leave out columns and unit", + )); + } + if template.is_some() && layout.is_some_and(|l| l != "modern") { + return Err(args("A template applies to the modern layout")); + } + let template = template + .map(|spec| load_template(input, spec)) + .transpose()?; + let loaded = storage::load(input, project_id, workspace_id)?; + let p = &loaded.project; + let unit = unit(unit_text)?; + let lookup = Lookup::new(p); + // "p6" is the old name of the tables layout, still accepted from old + // scripts; the result always reports "tables". + let layout = match layout.unwrap_or("modern") { + "p6" => "tables", + other => other, + }; + let (mut workbook, summary) = match layout { + "modern" if template.is_some() => { + let t = template.as_ref().expect("checked"); + let options = t.options(p).map_err(invalid)?; + modern_workbook(p, &options).map_err(invalid)? + } + "modern" => { + let mut options = ExportOptions { + unit, + ..Default::default() + }; + if let Some(list) = columns { + options.columns = list + .split(',') + .map(str::trim) + .filter(|s| !s.is_empty()) + .map(|key| { + Column::from_key(key) + .or_else(|| openxer_interchange::columns::match_header(key, &lookup)) + .ok_or_else(|| args(format!("Unknown column {key:?}"))) + }) + .collect::>>()?; + } + modern_workbook(p, &options).map_err(invalid)? + } + "tables" => tables_workbook(p, unit).map_err(invalid)?, + _ => return Err(args("layout must be modern or tables")), + }; + let temp = tempfile::Builder::new() + .suffix(".xlsx") + .tempfile_in(parent(output)) + .map_err(io)?; + workbook.save(temp.path()).map_err(io)?; + publish(temp, output)?; + Ok(json!({"output":output,"layout":layout,"unit":unit.label(), + "activities":summary.activities,"relationships":summary.relationships, + "assignments":summary.assignments,"wbs_bands":summary.bands, + "project":project_json(p)})) +} + +/// `import-xlsx`: plan (and unless `dry_run`, apply) a spreadsheet to a project. +pub(crate) fn import_xlsx( + input: &Path, + spreadsheet: &Path, + output: Option<&Path>, + project_id: Option, + workspace_id: Option, + dry_run: bool, +) -> Result { + match (output, dry_run) { + (Some(_), true) => return Err(args("dry_run writes nothing; omit output")), + (None, false) => return Err(args("output is required unless dry_run is true")), + (Some(output), false) => storage::check_destination(output)?, + (None, true) => {} + } + let mut loaded = storage::load(input, project_id, workspace_id)?; + let (_, detected, _, plan) = xi::plan_file(spreadsheet, &loaded.project) + .map_err(|e| AutomationError::new("invalid_spreadsheet", e))?; + let counts = plan.counts(); + let rows: Vec<&xi::RowPlan> = plan + .rows + .iter() + .filter(|r| !matches!(r.kind, xi::RowKind::Unchanged | xi::RowKind::Skipped)) + .collect(); + let links: Vec<&xi::LinkPlan> = plan + .links + .iter() + .filter(|l| !matches!(l.kind, xi::RowKind::Unchanged | xi::RowKind::Skipped)) + .collect(); + let mut result = json!({"format":detected.format,"settings":detected.settings,"counts":counts, + "rows":rows,"relationships":links,"notes":plan.notes,"dry_run":dry_run}); + if dry_run { + return Ok(result); + } + let output = output.expect("checked above"); + let report = xi::apply(&plan, &mut loaded.project) + .map_err(|e| AutomationError::new("import_rejected", e))?; + storage::save(input, output, &loaded)?; + result["output"] = json!(output); + result["applied"] = json!(report); + result["project"] = project_json(&loaded.project); + Ok(result) +} + +/// XER import into an existing workspace (copied to `output`): create new, +/// replace, or update a workspace project with per-type import actions. +#[allow(clippy::too_many_arguments)] +pub(crate) fn import_into_workspace( + input: &Path, + workspace: &Path, + output: &Path, + project_id: Option, + action: &str, + target: Option, + config: Option<&str>, + dictionary: Option<&str>, +) -> Result { + storage::check_destination(output)?; + // A workspace with a shared dictionary: what a calendar, resource or + // code whose name the workspace has with other values does. + let choices = dictionary + .map(crate::workspace_cmd::parse_choices) + .transpose()? + .unwrap_or_default(); + if !storage::is_database_extension(output) { + return Err(args( + "import requires a database output (.db/.sqlite/.sqlite3)", + )); + } + if !matches!(action, "new" | "update" | "replace" | "add") { + return Err(args("action must be new, update, replace or add")); + } + if !storage::is_database(workspace)? { + return Err(args("workspace must be an OpenXER workspace database")); + } + let config = match config { + Some(text) => ImportConfig::parse(text).map_err(args)?, + None => ImportConfig::default(), + }; + let doc = openxer_interchange::project_xml::read_file(input).map_err(invalid)?; + let selected: Vec = doc + .projects() + .into_iter() + .map(|(id, _)| id) + .filter(|id| project_id.is_none_or(|p| p == *id)) + .collect(); + if selected.is_empty() { + return Err(AutomationError::new( + "project_not_found", + "No XER project matches the selector", + )); + } + if action != "new" && selected.len() != 1 { + return Err(args( + "update, replace and add need exactly one XER project; pass project_id", + )); + } + // The workspace keeps the file name, as a plain import does, not the + // full local path. + let source_name = input + .file_name() + .unwrap_or_default() + .to_string_lossy() + .into_owned(); + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + let source = storage::read_database(workspace)?; + let shared = storage::shared(&source)?; + source.backup("main", temp.path(), None).map_err(io)?; + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE").map_err(io)?; + let tx = c.transaction().map_err(io)?; + storage::schema(&tx)?; + let mut summaries = vec![]; + for pid in selected { + match action { + "new" => { + let mut p = ProjectData::from_document(doc.clone(), pid, source_name.clone()) + .map_err(invalid)?; + p.model.validate().map_err(invalid)?; + let mut source = p.source_name.clone(); + let mut n = 2; + while tx + .query_row( + "SELECT 1 FROM projects WHERE source_name=?1 AND project_key=?2", + params![source, pid], + |_| Ok(()), + ) + .optional() + .map_err(io)? + .is_some() + { + source = format!("{} ({n})", p.source_name); + n += 1; + } + p.source_name = source; + let (id, events) = storage::store_with(&tx, &p, None, None, &choices)?; + summaries.push(json!({"action":"new","workspace_id":id,"project":project_json(&p),"warnings":p.warnings, + "dictionary":crate::workspace_db::import_report(&events)})); + } + "update" | "replace" | "add" => { + let rows = storage::rows(&tx)?; + let id = match target { + Some(id) => id, + None => { + let matching: Vec = rows + .iter() + .filter(|r| r["project_id"] == pid) + .filter_map(|r| r["workspace_id"].as_i64()) + .collect(); + if matching.len() != 1 { + return Err(args("pass target_workspace_id; the project id does not identify one workspace project")); + } + matching[0] + } + }; + let (source, key, text, legacy, level): (String, i64, String, bool, bool) = tx + .query_row( + "SELECT source_name,project_key,xer_content,source_windows_encoding,level_resources FROM projects WHERE id=?1", + [id], + |r| Ok((r.get(0)?, r.get(1)?, r.get(2)?, r.get(3)?, r.get(4)?)), + ) + .optional() + .map_err(io)? + .ok_or_else(|| AutomationError::new("project_not_found", format!("Workspace row {id} does not exist")))?; + let mut target_doc = Document::parse(&text).map_err(invalid)?; + target_doc.windows_encoding = legacy; + // The target's shared rows come back from the dictionary + // before the file is merged into it. + let mark = if shared { + Some( + crate::workspace_db::hydrate(&tx, &mut target_doc, Some(id)) + .map_err(invalid)?, + ) + } else { + None + }; + let (mut p, report) = if action == "update" || action == "add" { + let merged = if action == "add" { + openxer_interchange::xer_merge::add_into_project( + &target_doc, + key, + &doc, + pid, + &config, + ) + } else { + merge_project(&target_doc, key, &doc, pid, &config) + }; + let (merged, report) = + merged.map_err(|e| AutomationError::new("import_rejected", e))?; + let mut p = + ProjectData::from_document(merged, key, source.clone()).map_err(invalid)?; + p.document.windows_encoding = legacy; + (p, json!(report)) + } else { + let p = ProjectData::from_document(doc.clone(), pid, source.clone()) + .map_err(invalid)?; + (p, Value::Null) + }; + p.model.options.do_level = level; + p.model.validate().map_err(invalid)?; + // Replace reads the project whole from the file: none of its + // dictionary rows are the ones the target read. + let mark = mark.filter(|_| action != "replace"); + tx.execute( + "UPDATE projects SET project_key=?1 WHERE id=?2", + params![p.model.project.proj_id, id], + ) + .map_err(io)?; + let (_, events) = storage::store_with(&tx, &p, Some(id), mark.as_ref(), &choices)?; + summaries.push(json!({"action":action,"workspace_id":id,"project":project_json(&p),"report":report,"warnings":p.warnings, + "dictionary":crate::workspace_db::import_report(&events)})); + } + _ => return Err(args("action must be new, update, replace or add")), + } + } + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + publish(temp, output)?; + Ok(json!({"output":output,"workspace":workspace,"projects":summaries})) +} + +/// Whether an export writes project XML: `format` when given (`xer` or +/// `xml`), else an output that ends in `.xml`. +pub(crate) fn writes_xml(format: Option<&str>, output: &Path) -> Result { + match format.map(|f| f.trim().to_ascii_lowercase()).as_deref() { + Some("xml") => Ok(true), + Some("xer") => Ok(false), + Some(other) => Err(args(format!("format must be xer or xml, not {other:?}"))), + None => Ok(output + .extension() + .is_some_and(|e| e.eq_ignore_ascii_case("xml"))), + } +} + +/// With `format`, refuse an input file that is not in that format (the +/// import tells XER from XML by the file's contents). +pub(crate) fn check_input_format(input: &Path, format: Option<&str>) -> Result<()> { + let Some(format) = format else { + return Ok(()); + }; + let want_xml = match format.trim().to_ascii_lowercase().as_str() { + "xml" => true, + "xer" => false, + other => return Err(args(format!("format must be xer or xml, not {other:?}"))), + }; + let mut head = [0u8; 64]; + let n = std::fs::File::open(input) + .and_then(|mut f| std::io::Read::read(&mut f, &mut head)) + .map_err(io)?; + if openxer_interchange::project_xml::is_xml(&head[..n]) != want_xml { + return Err(AutomationError::new( + "invalid_input", + format!( + "The input is not a {} file", + format.trim().to_ascii_uppercase() + ), + )); + } + Ok(()) +} + +/// Write an export document as XER or as project XML. +fn write_export(doc: &Document, xml: bool, path: &Path) -> Result<()> { + if xml { + openxer_interchange::project_xml::write_file(doc, path) + .map_err(|e| AutomationError::new("export_rejected", e)) + } else { + doc.write(path).map_err(io) + } +} + +/// The plain export (the loaded project's document, other projects and +/// unknown tables kept) with the header version label `version` and today's +/// export date. `xml` writes it as project XML instead of XER. +pub(crate) fn export_with_version( + input: &Path, + output: &Path, + project_id: Option, + workspace_id: Option, + version: &str, + xml: bool, +) -> Result { + if storage::is_database_extension(output) { + return Err(args("export requires an .xer or .xml output")); + } + storage::check_destination_as(output, xml)?; + let loaded = storage::load(input, project_id, workspace_id)?; + // XML carries no unknown tables, so from a shared workspace dictionary + // it takes only the rows the project uses, as the plain export does. + let mut doc = if xml { + storage::export_document(&loaded) + } else { + loaded.project.updated_document() + }; + let today = openxer_xer::edit::project_records::today(); + doc.header = openxer_interchange::xer_export::with_version(&doc.header, version, &today[..10]); + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + write_export(&doc, xml, temp.path())?; + publish(temp, output)?; + Ok( + json!({"output":output,"format":if xml { "xml" } else { "xer" }, + "version":openxer_interchange::xer_export::header_version(&doc.header), + "project":project_json(&loaded.project),"warnings":loaded.project.warnings}), + ) +} + +/// XER (or, with `xml`, project XML) export of one or several projects +/// with an explicit version label. +pub(crate) fn export_projects( + input: &Path, + output: &Path, + projects: &str, + version: &str, + xml: bool, +) -> Result { + if storage::is_database_extension(output) { + return Err(args("export requires an .xer or .xml output")); + } + storage::check_destination_as(output, xml)?; + let mut loaded = vec![]; + for part in projects.split(',').map(str::trim).filter(|s| !s.is_empty()) { + let id: i64 = part + .parse() + .map_err(|_| args(format!("project {part:?} is not an integer")))?; + // A workspace id first (as documented); a project id only when no + // workspace row has that id. Any other failure is reported. + let p = if storage::is_database(input)? { + match storage::load(input, None, Some(id)) { + Err(e) if e.code == "project_not_found" => storage::load(input, Some(id), None) + .map_err(|e| { + if e.code == "project_not_found" { + AutomationError::new( + "project_not_found", + format!("No workspace row or project has the id {id}"), + ) + } else { + e + } + })?, + other => other?, + } + } else { + storage::load(input, Some(id), None)? + }; + loaded.push(p); + } + if loaded.is_empty() { + return Err(args("projects must list at least one id")); + } + let refs: Vec<&ProjectData> = loaded.iter().map(|l| &l.project).collect(); + let mut doc = + export_document(&refs, version).map_err(|e| AutomationError::new("export_rejected", e))?; + // From a shared workspace dictionary: only the rows these projects use. + if loaded.iter().any(|l| l.mark.is_some()) { + let pids: Vec = refs.iter().map(|p| p.model.project.proj_id).collect(); + doc = openxer_xer::workspace_scope::used_subset_of(&doc, &pids); + } + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + write_export(&doc, xml, temp.path())?; + publish(temp, output)?; + Ok( + json!({"output":output,"format":if xml { "xml" } else { "xer" }, + "version":openxer_interchange::xer_export::header_version(&doc.header), + "projects":refs.iter().map(|p| project_json(p)).collect::>()}), + ) +} diff --git a/automation/src/lib.rs b/automation/src/lib.rs new file mode 100644 index 0000000..f77dc51 --- /dev/null +++ b/automation/src/lib.rs @@ -0,0 +1,1842 @@ +//! Shared native command layer for CLI, MCP, and future in-process chat. +//! The desktop currently calls the same engine directly. + +pub const VERSION: &str = env!("CARGO_PKG_VERSION"); +pub const SCHEMA_VERSION: &str = "1.0"; + +pub mod agent_host; +pub mod analysis; +pub mod baseline_cmd; +pub mod baseline_ops; +pub mod baseline_store; +pub mod baselines; +pub mod chat_prompt; +pub mod chat_tools; +pub mod checks; +pub mod cli; +pub mod connect; +pub mod documents; +pub mod edit; +pub mod eps; +pub mod global_change; +mod interchange; +pub mod load; +pub mod locate; +pub mod mcp; +pub mod pdf; +pub mod playbooks; +mod registers; +pub mod reports; +pub mod schedule_check; +pub mod skills; +mod storage; +pub mod usage; +pub mod user_prefs; +pub mod workspace_cmd; +pub mod workspace_db; + +use openxer_engine::{ + model::{Activity, Link, LinkType}, + options::{FloatType, LagCalendar, OutOfSequence}, + scheduler, +}; +use openxer_xer::{date_string, parse_relative, ProjectData}; +use serde::{Deserialize, Serialize}; +use serde_json::{json, Map, Value}; +use std::{fmt, path::PathBuf}; + +#[derive(Debug, Clone, Serialize)] +pub struct AutomationError { + pub code: String, + pub message: String, +} +impl AutomationError { + pub fn new(code: &str, message: impl Into) -> Self { + Self { + code: code.into(), + message: message.into(), + } + } +} +impl fmt::Display for AutomationError { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + write!(f, "{}: {}", self.code, self.message) + } +} +impl std::error::Error for AutomationError {} +pub type Result = std::result::Result; + +fn nullable<'de, D, T>(d: D) -> std::result::Result>, D::Error> +where + D: serde::Deserializer<'de>, + T: Deserialize<'de>, +{ + Option::::deserialize(d).map(Some) +} + +#[derive(Debug, Clone, Default, Deserialize)] +#[serde(default, deny_unknown_fields)] +pub struct SchedulePatch { + pub data_date: Option, + #[serde(deserialize_with = "nullable")] + pub must_finish: Option>, + pub retained_logic: Option, + pub progress_override: Option, + pub lag_from_early_start: Option, + pub use_expected_finish: Option, + pub level_resources: Option, + pub lag_calendar: Option, + pub float_type: Option, + pub ignore_external_relationships: Option, + pub open_ends_critical: Option, + pub use_must_finish: Option, + pub multiple_float_paths: Option, + pub float_paths_use_total: Option, + pub max_float_paths: Option, + #[serde(deserialize_with = "nullable")] + pub float_paths_end_activity: Option>, +} + +#[derive(Debug, Clone, Deserialize)] +#[serde(tag = "command", rename_all = "snake_case", deny_unknown_fields)] +pub enum Command { + Inspect { + input: PathBuf, + }, + /// Where the user's schedules are: the workspace this copy opens with + /// its projects, and the schedule files in `folder`; read-only. + FindSchedules { + #[serde(default)] + folder: Option, + }, + /// Move a workspace to a shared workspace dictionary (schema 3): a dry + /// run reports the plan, otherwise the migrated copy goes to `output`. + WorkspaceMigrate { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + dry_run: bool, + }, + /// The shared workspace dictionary's rows (of one table when given), + /// with the projects that use each. + WorkspaceDictionary { + input: PathBuf, + #[serde(default)] + table: Option, + }, + /// The projects that use one row of the shared workspace dictionary. + WorkspaceDictionaryUsage { + input: PathBuf, + table: String, + #[serde(default)] + id: Option, + #[serde(default)] + name: Option, + }, + /// The workspace's Assistance preferences (whether Add opens the New + /// Activity wizard), or one of them set in a copy written to `output`. + WorkspacePreference { + input: PathBuf, + #[serde(default)] + name: Option, + #[serde(default)] + value: Option, + #[serde(default)] + output: Option, + #[serde(default)] + dry_run: bool, + }, + Import { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + /// Existing workspace to import into (copied to `output`). + #[serde(default)] + workspace: Option, + /// `new` (default), `update`, `replace` or `add` (Add Into Existing + /// Project). + #[serde(default)] + action: Option, + #[serde(default)] + target_workspace_id: Option, + /// Per-type actions, for example `activities=update+delete,calendars=keep`. + #[serde(default)] + config: Option, + /// A workspace with a shared dictionary: what a dictionary row whose + /// name the workspace has with other values does, per kind, for + /// example `calendar=keep,resource=update` (default copy). + #[serde(default)] + dictionary: Option, + /// `xer` or `xml`: the format the input must be in. Without it the + /// format is told from the file's contents. + #[serde(default)] + format: Option, + }, + Load { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + offset: usize, + #[serde(default = "default_limit")] + limit: usize, + #[serde(default)] + relationship_offset: usize, + #[serde(default = "default_limit")] + relationship_limit: usize, + /// Only these activity fields (`task_code` is always kept); every + /// field when omitted. + #[serde(default)] + fields: Option>, + /// Only these Activity IDs. + #[serde(default)] + activities: Option>, + /// Only the activities under this WBS element (code path), at any + /// depth. + #[serde(default)] + wbs: Option, + /// Only the critical activities, by the project's own definition. + #[serde(default)] + critical: bool, + /// Order the activities by this field, `-` first for descending. + #[serde(default)] + sort: Option, + }, + /// Tools > Check Schedule: the results rows, and one row's activities + /// or relationships; read-only. + CheckSchedule { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// A check's name: also list its Activity IDs or relationships. + #[serde(default)] + check: Option, + /// Most items listed (default 50, at most 500). + #[serde(default)] + limit: Option, + #[serde(default)] + long_lag_hours: Option, + #[serde(default)] + large_float_hours: Option, + #[serde(default)] + large_duration_hours: Option, + }, + /// The scheduling playbooks: the list, or one by name. + Playbook { + #[serde(default)] + name: Option, + }, + /// The resource curves an assignment can use: the file's own and the + /// presets, each with its 21 points. + Curves { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + }, + /// Time-phased units (or costs) of an activity's or a resource's + /// assignments by day, week or month, spread as the usage views spread + /// them (resource curves included); read-only. + Usage { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// Only this activity's assignments (Activity ID). + #[serde(default)] + activity: Option, + /// Only this resource's assignments (short name). + #[serde(default)] + resource: Option, + /// `day`, `week` (default, from Monday) or `month`. + #[serde(default)] + interval: Option, + /// Project-local date range; by default every assignment window. + #[serde(default)] + from: Option, + #[serde(default)] + to: Option, + /// Costs instead of units. + #[serde(default)] + costs: bool, + }, + Schedule { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + options: SchedulePatch, + }, + Relationship { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + edit: RelationshipEdit, + }, + Export { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// Version label for the XER header, for example `19.12`. + #[serde(default)] + version: Option, + /// Comma separated project ids (workspace ids for a workspace input) to + /// export together; only these projects are written. + #[serde(default)] + projects: Option, + /// `xer` or `xml`; without it an output ending in `.xml` is XML and + /// any other is XER. + #[serde(default)] + format: Option, + }, + ExportXlsx { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// `modern` (default) or `tables`. + #[serde(default)] + layout: Option, + /// `days` (default) or `hours`. + #[serde(default)] + unit: Option, + /// Comma separated column keys or titles for the modern layout. + #[serde(default)] + columns: Option, + /// A saved export template: its name in the workspace, or the path of + /// a template `.json` file. Sets the columns, rows and options. + #[serde(default)] + template: Option, + }, + /// Print the project's layout to a new PDF with the desktop renderer. + ExportPdf { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// Saved layout name; the workspace's current layout when omitted. + #[serde(default)] + layout: Option, + /// `gantt` or `network` on top. + #[serde(default)] + view: Option, + #[serde(default)] + paper: Option, + /// `portrait` or `landscape`. + #[serde(default)] + orientation: Option, + }, + /// Apply an `openxer-changes/1` batch, all or nothing, to a new file. + Apply { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// The changes document itself. + #[serde(default)] + changes: Option, + /// A changes `.json` file. + #[serde(default)] + changes_file: Option, + #[serde(default)] + dry_run: bool, + /// Overrides the file's `recalculate` (false writes values exactly). + #[serde(default)] + recalculate: Option, + }, + /// One edit operation (the same operations as `apply`) to a new file. + Edit { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + operation: Value, + #[serde(default)] + dry_run: bool, + #[serde(default)] + recalculate: Option, + }, + /// The workspace EPS with every project's and folder's rollups. + EpsList { + input: PathBuf, + }, + /// One EPS edit (folders, filing, a new project) to a new workspace. + Eps { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + dry_run: bool, + operation: eps::EpsOperation, + }, + /// The stored baselines of each workspace project (or one) with the + /// Assign Baselines choices; read-only. + BaselineList { + input: PathBuf, + #[serde(default)] + workspace_id: Option, + }, + /// One Maintain / Assign Baselines or Revert Project to Baseline edit + /// of a workspace project, to a new workspace. + Baseline { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + dry_run: bool, + workspace_id: i64, + operation: baseline_cmd::BaselineOperation, + }, + /// Maintain Baselines > Update of one baseline by the Update Baseline + /// options, to a new workspace; a dry run returns the preview. + BaselineUpdate { + input: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + dry_run: bool, + workspace_id: i64, + baseline: String, + #[serde(default)] + options: openxer_interchange::baseline_update::UpdateOptions, + #[serde(default)] + activities: Option>, + }, + /// The project's work products and documents with their links to + /// activities and WBS elements; read-only. + Documents { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// Only the documents linked to this activity (Activity ID). + #[serde(default)] + activity: Option, + /// Only the documents linked to this WBS element (path) itself. + #[serde(default)] + wbs: Option, + }, + /// The text of a document's linked file, paged; read-only. + ReadDocument { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// Reference number, title or document id. + document: String, + /// `private` or `public`. + #[serde(default)] + location: Option, + #[serde(default)] + offset: Option, + #[serde(default)] + limit: Option, + #[serde(default)] + page: Option, + #[serde(default)] + pages: Option, + }, + /// The project's expense items, issues, risks or thresholds with their + /// fields; read-only. + Records { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// `expenses`, `issues`, `risks` or `thresholds`. + kind: String, + /// Only the records of this activity (Activity ID). + #[serde(default)] + activity: Option, + }, + /// Earned value per activity and for the project, as the earned value + /// columns compute it; read-only. + EarnedValue { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// `cost` (default) or `labor_units`. + #[serde(default)] + basis: Option, + #[serde(default)] + activity: Option, + }, + /// The S-curve workbook (Tools > Reports > S-Curve): time-phased + /// budgeted, actual and remaining per period with a native chart, the + /// breakdown matrices and an Info sheet, to a new .xlsx. + ExportScurve { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// `auto` (default), `labor`, `cost` or `duration`. + #[serde(default)] + measure: Option, + /// `day`, `week` (default), `month` or `financial`. + #[serde(default)] + period: Option, + /// `total`, `resource` (default when there are resources), `wbs1` + /// or `wbs2`. + #[serde(default)] + breakdown: Option, + /// Add the late dates curve. + #[serde(default)] + late: bool, + /// `sunday` (default) or `monday`. + #[serde(default)] + week_start: Option, + }, + /// Cumulative earned hours to the data date (Tools > Reports > Earned + /// Hours), to a new .xlsx. + ExportEarnedHours { + input: PathBuf, + output: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// `resource` (default), `wbs` or `activity`. + #[serde(default)] + breakdown: Option, + }, + ImportXlsx { + input: PathBuf, + spreadsheet: PathBuf, + #[serde(default)] + output: Option, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + dry_run: bool, + }, + /// The float paths into an activity or the project finish; read-only. + Paths { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + activity: Option, + #[serde(default = "default_paths")] + count: usize, + }, + /// The project against a baseline or an earlier file; read-only. + Compare { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + /// An earlier XER or workspace to compare with. + #[serde(default)] + reference: Option, + #[serde(default)] + reference_project_id: Option, + #[serde(default)] + reference_workspace_id: Option, + /// `project` or `primary`: a stored baseline of a workspace project. + #[serde(default)] + baseline: Option, + }, + /// The work in the next weeks by WBS, ready or waiting; read-only. + Lookahead { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default = "default_weeks")] + weeks: u32, + #[serde(default)] + from: Option, + }, + /// Every milestone with date, float, baseline and driver; read-only. + Milestones { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + }, + /// Counts and spreads of activities, durations, calendars, names and + /// WBS; read-only. + ScheduleStats { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + update_period_days: Option, + }, + /// Each resource's units per period against its limit; read-only. + ResourceLoading { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default)] + interval: Option, + }, + /// The schedule rolled up by WBS to a level; read-only. + WbsSummary { + input: PathBuf, + #[serde(default)] + project_id: Option, + #[serde(default)] + workspace_id: Option, + #[serde(default = "default_level")] + level: usize, + }, + /// The skill catalog: built-ins and the user's skills. + Skills {}, + /// One skill's instructions by id. + Skill { + id: String, + }, + /// Check a skill file (or every user skill when no file is given). + SkillValidate { + #[serde(default)] + file: Option, + }, + /// Write a new skill file from the template into the user's folder. + SkillNew { + id: String, + }, + /// The user's skill folder. + SkillsPath {}, +} +fn default_paths() -> usize { + 5 +} +fn default_weeks() -> u32 { + 3 +} +fn default_level() -> usize { + 2 +} +fn default_limit() -> usize { + 200 +} + +#[derive(Debug, Clone, Deserialize)] +#[serde(deny_unknown_fields)] +pub struct RelationshipEdit { + pub action: EditAction, + pub predecessor: String, + pub successor: String, + pub relationship_type: RelationshipType, + #[serde(default)] + pub lag_minutes: Option, + #[serde(default)] + pub new_type: Option, +} +#[derive(Debug, Clone, Copy, Deserialize, PartialEq, Eq)] +#[serde(rename_all = "snake_case")] +pub enum EditAction { + Add, + Update, + Remove, +} +#[derive(Debug, Clone, Copy, Deserialize)] +pub enum RelationshipType { + FS, + SS, + FF, + SF, +} +impl From for LinkType { + fn from(t: RelationshipType) -> Self { + match t { + RelationshipType::FS => Self::FS, + RelationshipType::SS => Self::SS, + RelationshipType::FF => Self::FF, + RelationshipType::SF => Self::SF, + } + } +} + +pub fn parse_command(value: Value) -> Result { + serde_json::from_value(value) + .map_err(|e| AutomationError::new("invalid_arguments", e.to_string())) +} +pub fn response(result: Result) -> Value { + match result { + Ok(result) => json!({"schema_version":SCHEMA_VERSION,"ok":true,"result":result}), + Err(error) => json!({"schema_version":SCHEMA_VERSION,"ok":false,"error":error}), + } +} + +/// Shared dispatcher. All source reads are read-only; output publication is atomic +/// and refuses an existing destination. There is no process-global project state. +pub fn dispatch(command: Command) -> Result { + match command { + Command::Inspect { input } => storage::inspect(&input), + Command::FindSchedules { folder } => locate::find(folder.as_deref()), + Command::EpsList { input } => eps::list(&input), + Command::Records { + input, + project_id, + workspace_id, + kind, + activity, + } => registers::records(&input, project_id, workspace_id, &kind, activity.as_deref()), + Command::EarnedValue { + input, + project_id, + workspace_id, + basis, + activity, + } => registers::earned_value( + &input, + project_id, + workspace_id, + basis.as_deref(), + activity.as_deref(), + ), + Command::Eps { + input, + output, + dry_run, + operation, + } => eps::edit(&input, output, dry_run, &operation), + Command::BaselineList { + input, + workspace_id, + } => baseline_cmd::list(&input, workspace_id), + Command::Baseline { + input, + output, + dry_run, + workspace_id, + operation, + } => baseline_cmd::edit(&input, output, dry_run, workspace_id, &operation), + Command::BaselineUpdate { + input, + output, + dry_run, + workspace_id, + baseline, + options, + activities, + } => baseline_cmd::update( + &input, + output, + dry_run, + workspace_id, + &baseline, + &options, + activities.as_deref(), + ), + Command::WorkspaceMigrate { + input, + output, + dry_run, + } => storage::workspace_migrate(&input, output.as_deref(), dry_run), + Command::WorkspaceDictionary { input, table } => { + workspace_cmd::dictionary(&input, table.as_deref()) + } + Command::WorkspaceDictionaryUsage { + input, + table, + id, + name, + } => workspace_cmd::dictionary_usage(&input, &table, id, name.as_deref()), + Command::WorkspacePreference { + input, + name, + value, + output, + dry_run, + } => user_prefs::preference(&input, name.as_deref(), value, output, dry_run), + Command::Import { + input, + output, + project_id, + workspace, + action, + target_workspace_id, + config, + dictionary, + format, + } => { + interchange::check_input_format(&input, format.as_deref())?; + match workspace { + Some(workspace) => interchange::import_into_workspace( + &input, + &workspace, + &output, + project_id, + action.as_deref().unwrap_or("new"), + target_workspace_id, + config.as_deref(), + dictionary.as_deref(), + ), + None => { + if action.as_deref().is_some_and(|a| a != "new") + || target_workspace_id.is_some() + || config.is_some() + || dictionary.is_some() + { + return Err(AutomationError::new( + "invalid_arguments", + "action, target_workspace_id, config and dictionary need workspace", + )); + } + storage::import(&input, &output, project_id) + } + } + } + Command::Load { + input, + project_id, + workspace_id, + offset, + limit, + relationship_offset, + relationship_limit, + fields, + activities, + wbs, + critical, + sort, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let mut value = load::load( + &loaded.project, + &load::Request { + offset, + limit, + relationship_offset, + relationship_limit, + fields: fields.as_deref(), + activities: activities.as_deref(), + wbs: wbs.as_deref(), + critical, + sort: sort.as_deref(), + }, + )?; + value["workspace_id"] = json!(loaded.workspace_id); + Ok(value) + } + Command::CheckSchedule { + input, + project_id, + workspace_id, + check, + limit, + long_lag_hours, + large_float_hours, + large_duration_hours, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let ctx = baselines::context(&input, loaded.workspace_id, &loaded.project)?; + checks::check_schedule_with( + &loaded.project, + Some(&ctx), + check.as_deref(), + limit, + &analysis::Thresholds { + long_lag_hours, + large_float_hours, + large_duration_hours, + }, + ) + } + Command::Playbook { name } => playbooks::playbook(name.as_deref()), + Command::Curves { + input, + project_id, + workspace_id, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + Ok(curves_json(&loaded.project.document)) + } + Command::Usage { + input, + project_id, + workspace_id, + activity, + resource, + interval, + from, + to, + costs, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + usage::usage( + &loaded.project, + &usage::Request { + activity: activity.as_deref(), + resource: resource.as_deref(), + interval: interval.as_deref(), + from: from.as_deref(), + to: to.as_deref(), + costs, + }, + ) + } + Command::Schedule { + input, + output, + project_id, + workspace_id, + options, + } => { + storage::check_destination(&output)?; + let mut loaded = storage::load(&input, project_id, workspace_id)?; + let report = schedule_project(&mut loaded.project, &options)?; + storage::save(&input, &output, &loaded)?; + Ok( + json!({"output":output,"project":project_json(&loaded.project),"schedule":report,"warnings":loaded.project.warnings}), + ) + } + Command::Relationship { + input, + output, + project_id, + workspace_id, + edit, + } => { + storage::check_destination(&output)?; + let mut loaded = storage::load(&input, project_id, workspace_id)?; + let report = edit_relationship(&mut loaded.project, &edit)?; + storage::save(&input, &output, &loaded)?; + Ok( + json!({"output":output,"project":project_json(&loaded.project),"relationship":report, + "schedule_recalculated":false,"stored_dates":"unchanged; schedule the new output to recalculate"}), + ) + } + Command::Apply { + input, + output, + project_id, + workspace_id, + changes, + changes_file, + dry_run, + recalculate, + } => { + let document = match (changes, changes_file) { + (Some(value), None) => value, + (None, Some(path)) => { + let text = std::fs::read_to_string(&path).map_err(|e| { + AutomationError::new( + "invalid_arguments", + format!("Cannot read changes file {}: {e}", path.display()), + ) + })?; + serde_json::from_str(text.trim_start_matches('\u{feff}')).map_err(|e| { + AutomationError::new( + "invalid_changes", + format!("Invalid changes JSON: {e}"), + ) + })? + } + _ => { + return Err(AutomationError::new( + "invalid_arguments", + "apply needs exactly one of changes or changes_file", + )) + } + }; + let changes = edit::parse_changes(document)?; + let recalculate = recalculate.or(changes.recalculate).unwrap_or(true); + run_edits( + &input, + output, + project_id, + workspace_id, + &changes.operations, + dry_run, + recalculate, + ) + } + Command::Edit { + input, + output, + project_id, + workspace_id, + operation, + dry_run, + recalculate, + } => { + let op = edit::operation(operation) + .map_err(|e| AutomationError::new("invalid_arguments", e))?; + // A batch replaying stored rows may carry a value whose owner is + // gone (reported, not written); one edit on its own needs one. + if let edit::Operation::SetUdf { + activity: None, + resource: None, + wbs: None, + expense: None, + issue: None, + risk: None, + document: None, + project, + .. + } = &op + { + if *project != Some(true) { + return Err(AutomationError::new( + "invalid_arguments", + "set_udf needs an activity or a resource", + )); + } + } + run_edits( + &input, + output, + project_id, + workspace_id, + std::slice::from_ref(&op), + dry_run, + recalculate.unwrap_or(true), + ) + } + Command::Export { + input, + output, + project_id, + workspace_id, + version, + projects, + format, + } if version.is_some() + || projects.is_some() + || interchange::writes_xml(format.as_deref(), &output)? => + { + let xml = interchange::writes_xml(format.as_deref(), &output)?; + let projects = match projects { + Some(list) => { + if project_id.is_some() || workspace_id.is_some() { + return Err(AutomationError::new( + "invalid_arguments", + "Use projects or project_id/workspace_id, not both", + )); + } + list + } + None => { + // Only a version label: the export is the plain one (other + // projects and unknown tables of the source are kept) with + // that header version. + return interchange::export_with_version( + &input, + &output, + project_id, + workspace_id, + version.as_deref().unwrap_or(""), + xml, + ); + } + }; + interchange::export_projects( + &input, + &output, + &projects, + version.as_deref().unwrap_or(""), + xml, + ) + } + Command::ExportXlsx { + input, + output, + project_id, + workspace_id, + layout, + unit, + columns, + template, + } => interchange::export_xlsx( + &input, + &output, + project_id, + workspace_id, + layout.as_deref(), + unit.as_deref(), + columns.as_deref(), + template.as_deref(), + ), + Command::ExportScurve { + input, + output, + project_id, + workspace_id, + measure, + period, + breakdown, + late, + week_start, + } => reports::export_scurve( + &input, + &output, + project_id, + workspace_id, + &reports::CurveRequest { + measure: measure.as_deref(), + period: period.as_deref(), + breakdown: breakdown.as_deref(), + late, + week_start: week_start.as_deref(), + }, + ), + Command::ExportEarnedHours { + input, + output, + project_id, + workspace_id, + breakdown, + } => reports::export_earned_hours( + &input, + &output, + project_id, + workspace_id, + breakdown.as_deref(), + ), + Command::ExportPdf { + input, + output, + project_id, + workspace_id, + layout, + view, + paper, + orientation, + } => pdf::export_pdf( + &input, + &output, + project_id, + workspace_id, + layout.as_deref(), + view.as_deref(), + paper.as_deref(), + orientation.as_deref(), + ), + Command::Documents { + input, + project_id, + workspace_id, + activity, + wbs, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + documents::list(&loaded.project, activity.as_deref(), wbs.as_deref()) + } + Command::ReadDocument { + input, + project_id, + workspace_id, + document, + location, + offset, + limit, + page, + pages, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let paging = documents::Paging { + offset, + limit, + page, + pages, + }; + documents::read( + &loaded.project, + &input, + &document, + location.as_deref(), + paging, + ) + } + Command::ImportXlsx { + input, + spreadsheet, + output, + project_id, + workspace_id, + dry_run, + } => interchange::import_xlsx( + &input, + &spreadsheet, + output.as_deref(), + project_id, + workspace_id, + dry_run, + ), + Command::Paths { + input, + project_id, + workspace_id, + activity, + count, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + analysis::paths(&loaded.project, activity.as_deref(), count) + } + Command::Compare { + input, + project_id, + workspace_id, + reference, + reference_project_id, + reference_workspace_id, + baseline, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let reference = match (reference, baseline.as_deref()) { + (Some(path), None) => { + let r = storage::load(&path, reference_project_id, reference_workspace_id)?; + analysis::Reference { + name: path.display().to_string(), + kind: "file", + project: r.project, + } + } + (None, Some(which @ ("project" | "primary"))) => { + if reference_project_id.is_some() || reference_workspace_id.is_some() { + return Err(AutomationError::new( + "invalid_arguments", + "reference_project_id and reference_workspace_id go with reference", + )); + } + let primary = which == "primary"; + let (name, project) = baselines::stored_project( + &input, + loaded.workspace_id, + &loaded.project, + primary, + )? + .ok_or_else(|| { + AutomationError::new( + "no_baseline", + format!("The project has no {which} baseline assigned in this workspace; give reference, an earlier file, instead"), + ) + })?; + analysis::Reference { + name, + kind: if primary { + "primary baseline" + } else { + "project baseline" + }, + project, + } + } + _ => { + return Err(AutomationError::new( + "invalid_arguments", + "compare needs exactly one of reference (a file) or baseline (project or primary)", + )) + } + }; + analysis::compare(&loaded.project, &reference) + } + Command::Lookahead { + input, + project_id, + workspace_id, + weeks, + from, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + analysis::lookahead(&loaded.project, weeks, from.as_deref()) + } + Command::Milestones { + input, + project_id, + workspace_id, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let ctx = baselines::context(&input, loaded.workspace_id, &loaded.project)?; + analysis::milestones(&loaded.project, &ctx) + } + Command::ScheduleStats { + input, + project_id, + workspace_id, + update_period_days, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + analysis::schedule_stats(&loaded.project, update_period_days) + } + Command::ResourceLoading { + input, + project_id, + workspace_id, + interval, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + analysis::resource_loading(&loaded.project, interval.as_deref()) + } + Command::WbsSummary { + input, + project_id, + workspace_id, + level, + } => { + let loaded = storage::load(&input, project_id, workspace_id)?; + let ctx = baselines::context(&input, loaded.workspace_id, &loaded.project)?; + analysis::wbs_summary(&loaded.project, &ctx, level) + } + Command::Skills {} => { + let dir = skills::user_dir(); + Ok(skills::catalog_json( + &skills::catalog_in(Some(&dir)), + Some(&dir), + )) + } + Command::Skill { id } => { + let catalog = skills::catalog(); + let entry = catalog.get(&id).ok_or_else(|| { + AutomationError::new( + "not_found", + format!("No skill {id:?}; openxer_skills lists them"), + ) + })?; + let mut v = skills::detail_json(entry); + v["rules"] = json!(skills::RULES); + Ok(v) + } + Command::SkillValidate { file } => skills_validate(file), + Command::SkillNew { id } => { + let dir = skills::user_dir(); + let text = skills::template(&id); + skills::parse(&text, Some(&id)).map_err(|e| { + AutomationError::new("invalid_arguments", format!("id {id:?}: {e}")) + })?; + let path = skills::write_user(&dir, &id, &text, false) + .map_err(|e| AutomationError::new("write_failed", e.to_string()))?; + Ok( + json!({"id": id, "path": path, "built_in_replaced": skills::BUILT_IN.iter().any(|(b, _)| *b == id)}), + ) + } + Command::SkillsPath {} => { + let dir = skills::user_dir(); + Ok(json!({"folder": dir, "exists": dir.is_dir(), "data_folder": locate::data_folder()})) + } + Command::Export { + input, + output, + project_id, + workspace_id, + .. + } => { + if storage::is_database_extension(&output) { + return Err(AutomationError::new( + "invalid_arguments", + "export requires an .xer or .xml output", + )); + } + storage::check_destination(&output)?; + let loaded = storage::load(&input, project_id, workspace_id)?; + storage::save(&input, &output, &loaded)?; + Ok( + json!({"output":output,"project":project_json(&loaded.project),"warnings":loaded.project.warnings}), + ) + } + } +} + +/// `skills validate`: one file, or every user skill and the folder's +/// problems. +fn skills_validate(file: Option) -> Result { + let Some(path) = file else { + let dir = skills::user_dir(); + let catalog = skills::catalog_in(Some(&dir)); + let mine: Vec = catalog + .entries + .iter() + .filter(|e| e.source != skills::Source::BuiltIn) + .map(|e| json!({"id": e.skill.id, "path": e.path, "source": e.source.key(), "valid": true, "warnings": e.warnings})) + .collect(); + let bad: Vec = catalog + .problems + .iter() + .map(|p| json!({"path": p.path, "valid": false, "error": p.error})) + .collect(); + return Ok( + json!({"folder": dir, "valid": bad.is_empty(), "skills": mine, "problems": bad}), + ); + }; + let text = std::fs::read_to_string(&path).map_err(|e| { + AutomationError::new( + "invalid_arguments", + format!("Cannot read {}: {e}", path.display()), + ) + })?; + let stem = path.file_stem().map(|s| s.to_string_lossy().into_owned()); + match skills::validate(&text, stem.as_deref()) { + Ok((skill, warnings)) => Ok(json!({"path": path, "valid": true, "id": skill.id, + "kind": skill.kind.key(), "warnings": warnings})), + Err(e) => Err(AutomationError::new("invalid_skill", e.to_string())), + } +} + +/// Load, apply edit operations all or nothing, and write a new file unless +/// this is a dry run. A failure writes nothing. +fn run_edits( + input: &std::path::Path, + output: Option, + project_id: Option, + workspace_id: Option, + operations: &[edit::Operation], + dry_run: bool, + recalculate: bool, +) -> Result { + match (&output, dry_run) { + (Some(_), true) => { + return Err(AutomationError::new( + "invalid_arguments", + "dry_run writes nothing; omit output", + )) + } + (None, false) => { + return Err(AutomationError::new( + "invalid_arguments", + "output is required unless dry_run is true", + )) + } + (Some(path), false) => storage::check_destination(path)?, + (None, true) => {} + } + // A global change named by its saved name runs that definition. + let operations = &global_change::resolve(input, operations)?; + let mut loaded = storage::load(input, project_id, workspace_id)?; + // Monitor Thresholds reads the workspace's stored baselines. + let ev = if operations + .iter() + .any(|o| matches!(o, edit::Operation::MonitorThresholds { .. })) + { + baselines::context(input, loaded.workspace_id, &loaded.project)? + } else { + Default::default() + }; + let report = edit::apply_with(&mut loaded.project, operations, recalculate, &ev)?; + if let Some(path) = &output { + storage::save(input, path, &loaded)?; + } + Ok( + json!({"output":output,"dry_run":dry_run,"recalculate":recalculate, + "project":project_json(&loaded.project),"report":report, + "warnings":loaded.project.warnings}), + ) +} + +/// In-process entrypoint for a future desktop chat. Failure leaves `project` +/// unchanged; scheduling itself is implemented entirely by openxer-engine. +pub fn schedule_project(project: &mut ProjectData, patch: &SchedulePatch) -> Result { + project + .model + .validate() + .map_err(|e| AutomationError::new("invalid_source", e))?; + let mut next = project.clone(); + let before: Vec<_> = next + .model + .activities + .iter() + .map(|a| calculated_json(&next, a)) + .collect(); + let origin = next.model.origin_serial; + if let Some(date) = &patch.data_date { + next.model.project.data_date = Some( + parse_relative(origin, date) + .map_err(|e| AutomationError::new("invalid_arguments", e))? + .ok_or_else(|| { + AutomationError::new("invalid_arguments", "data_date cannot be empty") + })?, + ); + } + if let Some(date) = &patch.must_finish { + next.model.project.plan_end = match date { + Some(value) => Some( + parse_relative(origin, value) + .map_err(|e| AutomationError::new("invalid_arguments", e))? + .ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + "must_finish must be a date or null", + ) + })?, + ), + None => None, + }; + } + if let Some(Some(id)) = patch.float_paths_end_activity { + if !next.model.activities.iter().any(|a| a.task_id == id) { + return Err(AutomationError::new( + "invalid_arguments", + format!( + "float_paths_end_activity {id} is not the task_id of an activity in the project" + ), + )); + } + } + let o = &mut next.model.options; + macro_rules! set { + ($field:ident, $patch:ident) => { + if let Some(value) = patch.$patch { + o.$field = value; + } + }; + } + set!(retained_logic, retained_logic); + set!(progress_override, progress_override); + set!(lag_from_early_start, lag_from_early_start); + set!(use_expected_finish, use_expected_finish); + set!(do_level, level_resources); + set!(open_end_uses_early, open_ends_critical); + set!(use_must_finish, use_must_finish); + set!(multiple_float_paths, multiple_float_paths); + set!(float_paths_use_total, float_paths_use_total); + set!(max_float_paths, max_float_paths); + set!(float_paths_end_activity, float_paths_end_activity); + if patch.max_float_paths == Some(0) { + return Err(AutomationError::new( + "invalid_arguments", + "max_float_paths must be a positive integer", + )); + } + if o.retained_logic && o.progress_override { + return Err(AutomationError::new( + "invalid_arguments", + "retained_logic and progress_override cannot both be true", + )); + } + if let Some(ignore) = patch.ignore_external_relationships { + o.out_of_sequence = if ignore { + OutOfSequence::None + } else { + OutOfSequence::Both + }; + } + if let Some(value) = patch.lag_calendar.as_deref() { + o.lag_calendar = match value { + "predecessor" => LagCalendar::PredCal, + "successor" => LagCalendar::SuccCal, + "24_hour" => LagCalendar::Hour24, + "project" => LagCalendar::ProjCal, + _ => { + return Err(AutomationError::new( + "invalid_arguments", + "lag_calendar must be predecessor, successor, 24_hour, or project", + )) + } + }; + } + if let Some(value) = patch.float_type.as_deref() { + o.float_type = match value { + "start" => FloatType::Start, + "finish" => FloatType::Finish, + "minimum" => FloatType::Min, + _ => { + return Err(AutomationError::new( + "invalid_arguments", + "float_type must be start, finish, or minimum", + )) + } + }; + } + if !o.do_level + && next + .model + .activities + .iter() + .any(|a| a.task_type == openxer_engine::model::TaskType::Resource) + { + return Err(AutomationError::new("unsupported_schedule", "Resource-dependent activities require level_resources=true; nonleveled resource-calendar scheduling is not yet supported")); + } + next.refresh_derived_durations(); + scheduler::schedule_with_resources(&mut next.model, &next.resources) + .map_err(|e| AutomationError::new("schedule_rejected", e))?; + // Exported assignments carry the new dates (xer::assignments). + next.write_assignment_schedule(); + let mut changes = vec![]; + let mut activity_count = 0; + let mut generated_count = 0; + let mut changed_count = 0; + for (a, old) in next.model.activities.iter().zip(before) { + let after = calculated_json(&next, a); + let mut generated = Map::new(); + let mut changed = Map::new(); + for (field, value) in after.as_object().expect("calculated fields are an object") { + let prior = &old[field]; + if prior != value { + if prior.is_null() && !value.is_null() { + generated.insert(field.clone(), value.clone()); + generated_count += 1; + } else { + changed.insert(field.clone(), json!({"before":prior,"after":value})); + changed_count += 1; + } + } + } + if !generated.is_empty() || !changed.is_empty() { + activity_count += 1; + if changes.len() < 200 { + changes.push(json!({"task_id":a.task_id,"task_code":a.task_code,"generated":generated,"changed":changed})); + } + } + } + let report = json!({"changed_activity_count":activity_count,"changes_truncated":activity_count > changes.len(),"change_limit":200,"generated_field_count":generated_count, + "changed_field_count":changed_count,"changes":changes}); + *project = next; + Ok(report) +} + +/// Validates endpoints, duplicate identity and acyclicity before changing the +/// caller's project. It does not implicitly schedule or change stored dates. +pub fn edit_relationship(project: &mut ProjectData, edit: &RelationshipEdit) -> Result { + project + .model + .validate() + .map_err(|e| AutomationError::new("invalid_source", e))?; + if edit + .lag_minutes + .is_some_and(|lag| !(-6_000_000..=6_000_000).contains(&lag)) + { + return Err(AutomationError::new( + "invalid_arguments", + "lag_minutes must be between -6000000 and 6000000", + )); + } + let mut next = project.clone(); + let find = |code: &str| -> Result { + let matches: Vec<_> = next + .model + .activities + .iter() + .enumerate() + .filter(|(_, a)| a.task_code == code) + .map(|(i, _)| i) + .collect(); + if matches.len() != 1 { + return Err(AutomationError::new( + "invalid_relationship", + format!("Activity code {code:?} must identify exactly one activity"), + )); + } + Ok(matches[0]) + }; + let pred = find(&edit.predecessor)?; + let succ = find(&edit.successor)?; + if pred == succ { + return Err(AutomationError::new( + "invalid_relationship", + "An activity cannot depend on itself", + )); + } + let kind = LinkType::from(edit.relationship_type); + let found: Vec<_> = next + .model + .links + .iter() + .enumerate() + .filter(|(_, l)| l.pred == pred && l.succ == succ && l.link_type == kind) + .map(|(i, _)| i) + .collect(); + if found.len() > 1 { + return Err(AutomationError::new( + "ambiguous_relationship", + "Multiple links share the requested endpoints and type", + )); + } + let before = found + .first() + .map(|&i| link_json(&next, &next.model.links[i])); + match edit.action { + EditAction::Add => { + if !found.is_empty() || edit.new_type.is_some() { + return Err(AutomationError::new( + "invalid_relationship", + "Add requires a new endpoint/type combination and no new_type", + )); + } + next.model.links.push(Link { + pred, + succ, + link_type: kind, + lag: edit.lag_minutes.unwrap_or(0), + driving_path: false, + }); + } + EditAction::Update => { + let index = *found.first().ok_or_else(|| { + AutomationError::new( + "relationship_not_found", + "Relationship to update does not exist", + ) + })?; + let kind = edit.new_type.map(LinkType::from).unwrap_or(kind); + if next + .model + .links + .iter() + .enumerate() + .any(|(i, l)| i != index && l.pred == pred && l.succ == succ && l.link_type == kind) + { + return Err(AutomationError::new( + "invalid_relationship", + "Updated relationship would duplicate an existing type", + )); + } + next.model.links[index].link_type = kind; + if let Some(lag) = edit.lag_minutes { + next.model.links[index].lag = lag; + } + } + EditAction::Remove => { + if edit.lag_minutes.is_some() || edit.new_type.is_some() { + return Err(AutomationError::new( + "invalid_arguments", + "Remove does not accept lag_minutes or new_type", + )); + } + let index = *found.first().ok_or_else(|| { + AutomationError::new( + "relationship_not_found", + "Relationship to remove does not exist", + ) + })?; + next.model.links.remove(index); + } + } + next.model + .rebuild_links() + .map_err(|e| AutomationError::new("invalid_relationship", e))?; + next.model + .validate() + .map_err(|e| AutomationError::new("invalid_relationship", e))?; + let after = if edit.action == EditAction::Remove { + None + } else { + next.model + .links + .iter() + .find(|l| { + l.pred == pred + && l.succ == succ + && l.link_type == edit.new_type.map(LinkType::from).unwrap_or(kind) + }) + .map(|l| link_json(&next, l)) + }; + *project = next; + Ok(json!({"before":before,"after":after})) +} + +fn date(p: &ProjectData, value: Option) -> Value { + value.map_or(Value::Null, |v| { + json!(date_string(p.model.origin_serial, Some(v))) + }) +} +pub fn calculated_json(p: &ProjectData, a: &Activity) -> Value { + json!({"early_start":date(p,a.early_start),"early_finish":date(p,a.early_finish), + "late_start":date(p,a.late_start),"late_finish":date(p,a.late_finish), + "remaining_start":date(p,a.restart),"remaining_finish":date(p,a.reend), + "remaining_duration_minutes":a.rem,"total_float_minutes":a.total_float,"free_float_minutes":a.free_float, + "driving_path":a.driving_path,"float_path":a.float_path,"float_path_order":a.float_path_order}) +} +fn activity_json(p: &ProjectData, a: &Activity) -> Value { + let mut value = calculated_json(p, a); + let map = value.as_object_mut().expect("activity JSON is an object"); + map.insert("task_id".into(), json!(a.task_id)); + map.insert("task_code".into(), json!(a.task_code)); + map.insert( + "name".into(), + json!(p + .details + .get(&a.task_id) + .map(|d| d.name.as_str()) + .unwrap_or("")), + ); + map.insert("task_type".into(), json!(a.task_type.as_str())); + map.insert("status".into(), json!(openxer_xer::status_label(a.status))); + map.insert("calendar_id".into(), json!(p.model.calendars[a.cal].id)); + value +} +fn link_json(p: &ProjectData, l: &Link) -> Value { + json!({"predecessor":p.model.activities[l.pred].task_code,"successor":p.model.activities[l.succ].task_code, + "relationship_type":l.link_type.as_str().trim_start_matches("PR_"),"lag_minutes":l.lag}) +} +/// The curve list of `curves`: file curves, then presets not in the file. +pub fn curves_json(doc: &openxer_xer::Document) -> Value { + use openxer_xer::edit::curves::{self, Kind}; + let list: Vec = curves::list(doc) + .into_iter() + .map(|c| { + let preset = curves::preset(&c.name).filter(|_| c.kind == Kind::Preset); + json!({ + "name": c.name, + "curv_id": c.id, + "kind": match c.kind { Kind::File => "file", Kind::Default => "default", Kind::Preset => "preset" }, + "in_file": c.id.is_some(), + "editable": !c.locked(), + "assignments": c.id.map_or(0, |id| curves::uses(doc, id)), + "shape": preset.map(|p| p.shape), + "formula": preset.map(|p| p.formula), + "points": c.points, + }) + }) + .collect(); + json!({ + "points_meaning": "pct_usage_0..pct_usage_20: percent of the assignment's units spent in each 5% step of its duration; point 0 is the start, point k covers (k-1)*5% to k*5%", + "applied_to_spreading": true, + "applies_to": "assignments on activities with duration type DT_FixedDrtn (Fixed Duration and Units/Time) or DT_FixedDUR2 (Fixed Duration and Units); other types spread evenly", + "spreading_rules": "budgeted and remaining units and costs follow the curve over the assignment's own dates (with its lag); actuals follow it from the actual start to the data date; point 0 counts only for actuals; segments are positions in working time. OpenXER's reading of the documented behavior, not yet measured against other software. See the usage command.", + "curves": list, + }) +} + +pub fn project_json(p: &ProjectData) -> Value { + let o = &p.model.options; + json!({"project_id":p.model.project.proj_id,"name":p.model.project.name,"data_date":date(p,p.model.project.data_date), + "scheduled_finish":date(p,p.model.project.scd_end),"must_finish":date(p,p.model.project.plan_end), + "activity_count":p.model.activities.len(),"relationship_count":p.model.links.len(), + "units":{"durations":"integer working minutes","dates":"project-local YYYY-MM-DD HH:MM; no timezone conversion"}, + "options":{"retained_logic":o.retained_logic,"progress_override":o.progress_override, + "level_resources":o.do_level,"lag_from_early_start":o.lag_from_early_start,"use_expected_finish":o.use_expected_finish, + "lag_calendar":match o.lag_calendar { LagCalendar::PredCal=>"predecessor",LagCalendar::SuccCal=>"successor",LagCalendar::Hour24=>"24_hour",LagCalendar::ProjCal=>"project" }, + "float_type":match o.float_type { FloatType::Start=>"start",FloatType::Finish=>"finish",FloatType::Min=>"minimum" }, + "ignore_external_relationships":o.out_of_sequence==OutOfSequence::None,"open_ends_critical":o.open_end_uses_early, + "use_must_finish":o.use_must_finish,"multiple_float_paths":o.multiple_float_paths, + "float_paths_use_total":o.float_paths_use_total,"max_float_paths":o.max_float_paths, + "float_paths_end_activity":o.float_paths_end_activity}}) +} diff --git a/automation/src/load.rs b/automation/src/load.rs new file mode 100644 index 0000000..afcab1a --- /dev/null +++ b/automation/src/load.rs @@ -0,0 +1,343 @@ +//! `load`: project options and paged activity and relationship rows, +//! without scheduling. Fields, Activity IDs, a WBS element and critical +//! only keep an answer small when an agent needs only a few things, and a +//! sort field answers "which is latest" in one page. +use crate::{activity_json, documents, link_json, project_json, AutomationError, Result}; +use openxer_xer::ProjectData; +use serde_json::{json, Value}; +use std::collections::BTreeSet; + +/// Largest page of activities or relationships. +pub const MAX_LIMIT: usize = 2000; + +/// The activity fields `fields` can name. The fields in [`ON_REQUEST`] are +/// only given when named. +pub const FIELDS: &[&str] = &[ + "task_id", + "task_code", + "name", + "task_type", + "status", + "calendar_id", + "wbs", + "critical", + "early_start", + "early_finish", + "late_start", + "late_finish", + "remaining_start", + "remaining_finish", + "remaining_duration_minutes", + "total_float_minutes", + "free_float_minutes", + "driving_path", + "float_path", + "float_path_order", + "documents", + "original_duration_minutes", + "actual_start", + "actual_finish", + "constraint", + "constraint_date", +]; + +/// Fields given only when `fields` names them: the WBS code path, critical +/// by the project's own definition, the original duration in working +/// minutes, the actual dates and the primary constraint with its date. +pub const ON_REQUEST: &[&str] = &[ + "wbs", + "critical", + "original_duration_minutes", + "actual_start", + "actual_finish", + "constraint", + "constraint_date", +]; + +/// The value of an [`ON_REQUEST`] field. +fn on_request( + p: &ProjectData, + a: &openxer_engine::model::Activity, + field: &str, + definition: openxer_xer::critical::CriticalDefinition, +) -> Value { + let date = |v: Option| { + v.map_or(Value::Null, |v| { + json!(openxer_xer::date_string(p.model.origin_serial, Some(v))) + }) + }; + match field { + "wbs" => json!(p.details.get(&a.task_id).map_or(String::new(), |d| { + openxer_xer::edit::documents::wbs_path(p, d.wbs) + })), + "critical" => json!(openxer_xer::critical::is_critical(a, definition)), + "original_duration_minutes" => { + json!(p.details.get(&a.task_id).map(|d| d.original_duration)) + } + "actual_start" => date(a.act_start), + "actual_finish" => date(a.act_finish), + "constraint" => match a.cstr { + openxer_engine::model::CstrType::None => Value::Null, + c => json!(openxer_xer::constraint_label(c)), + }, + "constraint_date" => date(a.cstr_date), + _ => Value::Null, + } +} + +/// What to load. A limit of 0 returns no rows of that kind (counts only). +#[derive(Debug, Clone, Default)] +pub struct Request<'a> { + pub offset: usize, + pub limit: usize, + pub relationship_offset: usize, + pub relationship_limit: usize, + pub fields: Option<&'a [String]>, + pub activities: Option<&'a [String]>, + pub wbs: Option<&'a str>, + pub critical: bool, + /// Order the activities by this field (`-` first for descending); + /// empty values go last either way. Project order when omitted. + pub sort: Option<&'a str>, +} + +/// Order two WBS code paths element by element: numbers by value where +/// both codes are numbers (`1.2` before `1.10`), else by their text. +pub fn compare_wbs_paths(a: &str, b: &str) -> std::cmp::Ordering { + let mut left = a.split('.'); + let mut right = b.split('.'); + loop { + match (left.next(), right.next()) { + (None, None) => return std::cmp::Ordering::Equal, + (None, Some(_)) => return std::cmp::Ordering::Less, + (Some(_), None) => return std::cmp::Ordering::Greater, + (Some(x), Some(y)) => { + let order = match (x.parse::(), y.parse::()) { + (Ok(m), Ok(n)) => m.cmp(&n).then_with(|| x.cmp(y)), + _ => x.cmp(y), + }; + if order != std::cmp::Ordering::Equal { + return order; + } + } + } + } +} + +/// Order two field values: numbers by value, text by its characters +/// (dates are `YYYY-MM-DD HH:MM`, so they sort as dates); empty last. +fn compare(a: &Value, b: &Value, descending: bool) -> std::cmp::Ordering { + use std::cmp::Ordering::*; + let empty = |v: &Value| v.is_null() || v.as_str() == Some(""); + match (empty(a), empty(b)) { + (true, true) => return Equal, + (true, false) => return Greater, + (false, true) => return Less, + _ => {} + } + let order = match (a.as_f64(), b.as_f64()) { + (Some(x), Some(y)) => x.partial_cmp(&y).unwrap_or(Equal), + _ => match (a.as_bool(), b.as_bool()) { + (Some(x), Some(y)) => x.cmp(&y), + _ => a.to_string().cmp(&b.to_string()), + }, + }; + if descending { + order.reverse() + } else { + order + } +} + +fn invalid(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +/// The `load` result for `p` (without `workspace_id`, which the caller +/// knows). With an activity filter (activities, wbs or critical) the +/// activities are the matching ones, and the relationships those with an +/// end among them; `matched_activities` and `matched_relationships` count +/// them, while the totals stay the project's. +pub fn load(p: &ProjectData, request: &Request) -> Result { + if request.limit > MAX_LIMIT || request.relationship_limit > MAX_LIMIT { + return Err(invalid(format!( + "limit and relationship_limit must be 0..{MAX_LIMIT}; use offsets to page" + ))); + } + if let Some(fields) = request.fields { + let unknown: Vec<&str> = fields + .iter() + .map(String::as_str) + .filter(|f| !FIELDS.contains(f)) + .collect(); + if !unknown.is_empty() { + return Err(invalid(format!( + "Unknown field {}; fields are {}", + unknown.join(", "), + FIELDS.join(", ") + ))); + } + } + let wbs_target = match request.wbs { + Some(path) => Some( + openxer_xer::edit::wbs::find_path(p, path) + .ok_or_else(|| invalid(format!("No WBS element has the code path {path:?}")))?, + ), + None => None, + }; + let wanted: Option> = request + .activities + .map(|list| list.iter().map(String::as_str).collect()); + let not_found: Vec<&str> = wanted + .iter() + .flatten() + .copied() + .filter(|code| !p.model.activities.iter().any(|a| a.task_code == *code)) + .collect(); + let definition = openxer_xer::critical::critical_definition(p); + let under = |mut wbs: i64, target: i64| { + for _ in 0..=p.wbs.len() { + if wbs == target { + return true; + } + match p.wbs.iter().find(|w| w.id == wbs).and_then(|w| w.parent) { + Some(parent) => wbs = parent, + None => return false, + } + } + false + }; + let sort = match request.sort { + Some(text) => { + let (field, descending) = match text.strip_prefix('-') { + Some(field) => (field, true), + None => (text, false), + }; + if !FIELDS.contains(&field) || field == "documents" { + return Err(invalid(format!( + "Cannot sort by {field:?}; sort takes one of {} (- first for descending)", + FIELDS + .iter() + .filter(|f| **f != "documents") + .copied() + .collect::>() + .join(", ") + ))); + } + Some((field, descending)) + } + None => None, + }; + let filtered = wanted.is_some() || wbs_target.is_some() || request.critical; + let mut matched: Vec = (0..p.model.activities.len()) + .filter(|&i| { + let a = &p.model.activities[i]; + wanted + .as_ref() + .is_none_or(|w| w.contains(a.task_code.as_str())) + && wbs_target.is_none_or(|target| { + p.details + .get(&a.task_id) + .is_some_and(|d| under(d.wbs, target)) + }) + && (!request.critical || openxer_xer::critical::is_critical(a, definition)) + }) + .collect(); + if let Some((field, descending)) = sort { + let key = |i: usize| -> Value { + let a = &p.model.activities[i]; + if ON_REQUEST.contains(&field) { + on_request(p, a, field, definition) + } else { + activity_json(p, a)[field].clone() + } + }; + let mut keyed: Vec<(Value, usize)> = matched.iter().map(|&i| (key(i), i)).collect(); + // Stable: equal values keep the project's order. + if field == "wbs" { + keyed.sort_by(|a, b| { + let order = + compare_wbs_paths(a.0.as_str().unwrap_or(""), b.0.as_str().unwrap_or("")); + if descending { + order.reverse() + } else { + order + } + }); + } else { + keyed.sort_by(|a, b| compare(&a.0, &b.0, descending)); + } + matched = keyed.into_iter().map(|(_, i)| i).collect(); + } + let links: Vec = if filtered { + let set: BTreeSet = matched.iter().copied().collect(); + (0..p.model.links.len()) + .filter(|&i| { + let l = &p.model.links[i]; + set.contains(&l.pred) || set.contains(&l.succ) + }) + .collect() + } else { + (0..p.model.links.len()).collect() + }; + if request.offset > matched.len() || request.relationship_offset > links.len() { + return Err(invalid( + "offset exceeds the corresponding activity or relationship count", + )); + } + let end = request + .offset + .saturating_add(request.limit) + .min(matched.len()); + let keep: Option> = request + .fields + .map(|f| f.iter().map(String::as_str).chain(["task_code"]).collect()); + let wants = |field: &str| keep.as_ref().is_some_and(|k| k.contains(field)); + // Each activity lists the documents linked to it. + let mut linked = if keep.is_none() || wants("documents") { + documents::by_activity(p) + } else { + Default::default() + }; + let activities: Vec = matched[request.offset..end] + .iter() + .map(|&i| { + let a = &p.model.activities[i]; + let mut v = activity_json(p, a); + v["documents"] = Value::Array(linked.remove(&a.task_id).unwrap_or_default()); + if let Some(keep) = &keep { + for field in ON_REQUEST { + if keep.contains(field) { + v[*field] = on_request(p, a, field, definition); + } + } + if let Some(map) = v.as_object_mut() { + map.retain(|k, _| keep.contains(k.as_str())); + } + } + v + }) + .collect(); + let relationship_end = request + .relationship_offset + .saturating_add(request.relationship_limit) + .min(links.len()); + let relationships: Vec = links[request.relationship_offset..relationship_end] + .iter() + .map(|&i| link_json(p, &p.model.links[i])) + .collect(); + let mut value = json!({"project": project_json(p), + "activities":activities,"relationships":relationships,"offset":request.offset, + "next_offset":(request.limit > 0 && end < matched.len()).then_some(end),"total_activities":p.model.activities.len(), + "relationship_offset":request.relationship_offset, + "next_relationship_offset":(request.relationship_limit > 0 && relationship_end < links.len()).then_some(relationship_end), + "total_relationships":p.model.links.len(),"warnings":p.warnings}); + if filtered { + value["matched_activities"] = json!(matched.len()); + value["matched_relationships"] = json!(links.len()); + } + if !not_found.is_empty() { + value["not_found"] = json!(not_found); + } + Ok(value) +} diff --git a/automation/src/locate.rs b/automation/src/locate.rs new file mode 100644 index 0000000..7e4c1cc --- /dev/null +++ b/automation/src/locate.rs @@ -0,0 +1,537 @@ +//! Where OpenXER keeps its workspace, and `find_schedules`: where the user's +//! schedules are, for an agent that was asked "Use OpenXER to inspect my +//! schedule" and was not given a file. The workspace rule +//! ([`default_workspace_in`]) is the one the desktop opens by +//! (`Store::default_path_in` calls it), so the app and the agent always +//! agree. `find_schedules` names that workspace (and the other copy's, when +//! an installed and a portable copy each have one) with its projects, most +//! recently saved first, and can list the schedule files in one folder. It +//! only reads: workspaces are opened read-only, and the one file it writes +//! is the app's own write check, removed at once. +use crate::{storage, AutomationError, Result}; +use rusqlite::Connection; +use serde_json::{json, Value}; +use std::{ + ffi::OsString, + path::{Path, PathBuf}, +}; + +/// The workspace file name. +pub const WORKSPACE_NAME: &str = "openxer.db"; +/// Moves the data folder (tests, managed deployments). +pub const DATA_DIR_VAR: &str = "OPENXER_DATA_DIR"; +/// The file the installer puts beside the executables of an installed copy. +pub use crate::connect::INSTALLED_MARKER; +/// Most projects listed per workspace, and most files per folder. +const LIMIT: usize = 100; + +/// The data folder `OPENXER_DATA_DIR` names (`value`), made absolute; None +/// when it is unset or empty. +pub fn data_dir_override(value: Option) -> Option { + let dir = PathBuf::from(value.filter(|v| !v.is_empty())?); + Some(std::path::absolute(&dir).unwrap_or(dir)) +} + +/// The per-user base folder OpenXER's data folder is made in, for this +/// process: `%LOCALAPPDATA%` on Windows; elsewhere the XDG data folder +/// ([`xdg_data_home`] of `$XDG_DATA_HOME` and `$HOME`). None when it is +/// not known. Callers pass it on as the `user_base` of +/// [`default_workspace_in`], [`candidates`] and [`find_in`]. +pub fn user_data_base() -> Option { + #[cfg(windows)] + { + std::env::var_os("LOCALAPPDATA") + } + #[cfg(not(windows))] + { + xdg_data_home(std::env::var_os("XDG_DATA_HOME"), std::env::var_os("HOME")) + } +} + +/// The XDG data folder, given the values of `$XDG_DATA_HOME` (`xdg`) and +/// `$HOME` (`home`): `xdg` when it is set and absolute (the XDG rule +/// ignores a relative one), else `/.local/share` when `home` is set +/// and absolute; None otherwise. Used on systems other than Windows. +pub fn xdg_data_home(xdg: Option, home: Option) -> Option { + // Absolute in the Unix sense (it starts with `/`), so the rule reads + // the same on any system. + let absolute = |v: Option| v.filter(|v| v.as_encoded_bytes().first() == Some(&b'/')); + absolute(xdg).or_else(|| { + absolute(home).map(|h| { + PathBuf::from(h) + .join(".local") + .join("share") + .into_os_string() + }) + }) +} + +/// `/OpenXER/openxer.db` in the per-user base folder +/// ([`user_data_base`]; `.` when it is unknown). +fn per_user_workspace(user_base: Option) -> PathBuf { + PathBuf::from( + user_base + .filter(|v| !v.is_empty()) + .unwrap_or_else(|| ".".into()), + ) + .join("OpenXER") + .join(WORKSPACE_NAME) +} + +/// The workspace a program in `exe_dir` opens, with `data_dir` the value +/// of `OPENXER_DATA_DIR` and `user_base` the per-user base folder +/// ([`user_data_base`]: `%LOCALAPPDATA%` on Windows, the XDG data folder +/// elsewhere): +/// - `OPENXER_DATA_DIR` set: `openxer.db` in that folder; +/// - an installed copy (the installer's marker file beside the EXE): +/// `/OpenXER/openxer.db`, never the program folder, which +/// an upgrade or uninstall replaces. A workspace a portable copy left +/// beside the EXE is still used while the per-user one does not exist, so +/// it never drops out of sight; +/// - a portable copy: `openxer.db` beside the EXE when that folder can be +/// written (a test file is made and removed), else +/// `/OpenXER/openxer.db`. +pub fn default_workspace_in( + exe_dir: Option<&Path>, + data_dir: Option, + user_base: Option, +) -> PathBuf { + if let Some(dir) = data_dir_override(data_dir) { + return dir.join(WORKSPACE_NAME); + } + let adjacent = exe_dir + .map(Path::to_path_buf) + .unwrap_or_else(|| PathBuf::from(".")); + if adjacent.join(INSTALLED_MARKER).is_file() { + let data = per_user_workspace(user_base); + let left = adjacent.join(WORKSPACE_NAME); + if !data.exists() && left.is_file() { + return left; + } + return data; + } + let marker = adjacent.join(format!(".openxer-write-check-{}", std::process::id())); + if std::fs::OpenOptions::new() + .write(true) + .create_new(true) + .open(&marker) + .is_ok() + { + let _ = std::fs::remove_file(marker); + return adjacent.join(WORKSPACE_NAME); + } + per_user_workspace(user_base) +} + +/// One place a workspace may be. +#[derive(Clone, Debug, PartialEq, Eq)] +pub struct Candidate { + pub path: PathBuf, + /// What makes it a candidate, in words. + pub why: &'static str, + /// The workspace the copy in `exe_dir` opens. + pub opened: bool, +} + +/// The places a workspace may be for the copy in `exe_dir`: first the one +/// it opens ([`default_workspace_in`]), then the other place (beside the EXE +/// or the per-user data folder), so a workspace the other kind of copy uses +/// is found too. With `OPENXER_DATA_DIR` set, only that one. +pub fn candidates( + exe_dir: Option<&Path>, + data_dir: Option, + user_base: Option, +) -> Vec { + let installed = exe_dir.is_some_and(|d| d.join(INSTALLED_MARKER).is_file()); + let why = |path: &Path| { + if data_dir_override(data_dir.clone()).is_some() { + "the data folder OPENXER_DATA_DIR names" + } else if exe_dir.is_some_and(|d| path == d.join(WORKSPACE_NAME)) { + if installed { + "left beside this installed copy by an earlier portable copy" + } else { + "beside this portable copy" + } + } else { + "the per-user data folder (installed copies, and portable copies in a folder they cannot write)" + } + }; + let opened = default_workspace_in(exe_dir, data_dir.clone(), user_base.clone()); + let mut out = vec![Candidate { + why: why(&opened), + path: opened, + opened: true, + }]; + if data_dir_override(data_dir.clone()).is_some() { + return out; + } + let others = [ + exe_dir.map(|d| d.join(WORKSPACE_NAME)), + user_base + .filter(|v| !v.is_empty()) + .map(|l| per_user_workspace(Some(l))), + ]; + for path in others.into_iter().flatten() { + if out.iter().all(|c| c.path != path) { + out.push(Candidate { + why: why(&path), + path, + opened: false, + }); + } + } + out +} + +/// A workspace's projects, most recently saved first. +fn projects(c: &Connection) -> Result<(Vec, usize)> { + let count: i64 = c + .query_row("SELECT COUNT(*) FROM projects", [], |r| r.get(0)) + .map_err(storage::invalid)?; + let mut stmt = c + .prepare( + "SELECT id,project_key,title,source_name,COALESCE(updated_at,'') FROM projects ORDER BY updated_at DESC,id DESC LIMIT ?1", + ) + .map_err(storage::invalid)?; + let rows = stmt + .query_map([LIMIT as i64], |r| { + Ok(json!({ + "workspace_id": r.get::<_, i64>(0)?, + "project_id": r.get::<_, i64>(1)?, + "name": r.get::<_, String>(2)?, + "source_name": r.get::<_, String>(3)?, + "saved_utc": r.get::<_, String>(4)?, + })) + }) + .map_err(storage::invalid)?; + let rows = rows + .collect::, _>>() + .map_err(storage::invalid)?; + Ok((rows, count.max(0) as usize)) +} + +/// `YYYY-MM-DD HH:MM` (UTC) of a file's last change. +fn modified(meta: &std::fs::Metadata) -> String { + let stamp = meta + .modified() + .map(crate::connect::timestamp) + .unwrap_or_default(); + match stamp.len() { + 15 => format!( + "{}-{}-{} {}:{}", + &stamp[0..4], + &stamp[4..6], + &stamp[6..8], + &stamp[9..11], + &stamp[11..13] + ), + _ => stamp, + } +} + +/// The XER files and workspaces directly in `folder`, newest first. +fn folder_files(folder: &Path) -> Result { + if !folder.is_absolute() { + return Err(AutomationError::new( + "invalid_arguments", + "folder must be an absolute path, such as C:\\Users\\you\\Documents", + )); + } + let entries = std::fs::read_dir(folder).map_err(|e| { + AutomationError::new( + "not_found", + format!("Cannot list {}: {e}", folder.display()), + ) + })?; + let mut files: Vec<(std::time::SystemTime, Value)> = entries + .filter_map(|e| e.ok()) + .filter_map(|e| { + let path = e.path(); + let meta = e.metadata().ok().filter(|m| m.is_file())?; + let kind = if path + .extension() + .is_some_and(|x| x.eq_ignore_ascii_case("xer")) + { + "xer" + } else if storage::is_database_extension(&path) + && storage::is_database(&path).unwrap_or(false) + { + "workspace" + } else { + return None; + }; + let at = meta.modified().unwrap_or(std::time::UNIX_EPOCH); + Some(( + at, + json!({"path": path, "kind": kind, "bytes": meta.len(), "modified_utc": modified(&meta)}), + )) + }) + .collect(); + files.sort_by_key(|f| std::cmp::Reverse(f.0)); + let total = files.len(); + Ok(json!({ + "path": folder, + "files": files.into_iter().take(LIMIT).map(|(_, v)| v).collect::>(), + "file_count": total, + })) +} + +/// The answer for the copy in `exe_dir`, with the environment given. +pub fn find_in( + exe_dir: Option<&Path>, + data_dir: Option, + user_base: Option, + folder: Option<&Path>, +) -> Result { + let mut workspaces = vec![]; + for c in candidates(exe_dir, data_dir, user_base) { + if !c.path.is_file() { + continue; + } + let mut entry = json!({ + "path": c.path, + "opened_by_openxer": c.opened, + "why": c.why, + }); + match storage::read_database(&c.path).and_then(|db| projects(&db)) { + Ok((list, count)) => { + entry["project_count"] = json!(count); + entry["projects"] = json!(list); + } + Err(e) => entry["error"] = json!(e.message), + } + workspaces.push(entry); + } + let folder = folder.map(folder_files).transpose()?; + let next = if workspaces.is_empty() && folder.is_none() { + "No OpenXER workspace was found on this PC. Ask the user for their XER file's path, or call again with folder set to the folder it is in." + } else { + "Pass a workspace path as input with a workspace_id from its projects (or an XER file path as input) to openxer_load, openxer_inspect, openxer_eps_list and the other tools. When several projects are listed and the user did not name one, ask which, or start with the most recently saved." + }; + let mut out = json!({ "workspaces": workspaces, "next": next }); + if let Some(folder) = folder { + out["folder"] = folder; + } + Ok(out) +} + +/// The folder of this process's executable. +fn exe_dir() -> Option { + std::env::current_exe() + .ok() + .and_then(|p| p.parent().map(Path::to_path_buf)) +} + +/// The workspace this process opens by default ([`default_workspace_in`] +/// for this executable's folder and the process environment). +pub fn default_workspace() -> PathBuf { + default_workspace_in( + exe_dir().as_deref(), + std::env::var_os(DATA_DIR_VAR), + std::env::var_os("LOCALAPPDATA"), + ) +} + +/// This process's data folder: the folder that holds its default +/// workspace (and the user's `skills`). +pub fn data_folder() -> PathBuf { + default_workspace() + .parent() + .map(Path::to_path_buf) + .unwrap_or_else(|| PathBuf::from(".")) +} + +/// The answer for this process: the copy is the one this executable is in. +pub fn find(folder: Option<&Path>) -> Result { + find_in( + exe_dir().as_deref(), + std::env::var_os(DATA_DIR_VAR), + user_data_base(), + folder, + ) +} + +#[cfg(test)] +mod tests { + use super::*; + use std::fs; + + fn os(p: &Path) -> Option { + Some(p.as_os_str().to_owned()) + } + + #[test] + fn the_xdg_data_folder_is_xdg_data_home_when_absolute_else_under_home() { + let s = |v: &str| Some(OsString::from(v)); + let base = |xdg, home| xdg_data_home(xdg, home).map(PathBuf::from); + let share = PathBuf::from("/home/ann").join(".local").join("share"); + // An absolute $XDG_DATA_HOME wins. + assert_eq!( + base(s("/srv/ann-data"), s("/home/ann")), + Some(PathBuf::from("/srv/ann-data")) + ); + // Unset, empty or relative: $HOME/.local/share. + assert_eq!(base(None, s("/home/ann")), Some(share.clone())); + assert_eq!(base(s(""), s("/home/ann")), Some(share.clone())); + assert_eq!(base(s("data"), s("/home/ann")), Some(share.clone())); + // No usable home either: unknown (the caller falls back to `.`). + assert_eq!(base(None, None), None); + assert_eq!(base(None, s("")), None); + assert_eq!(base(s("rel"), s("rel-home")), None); + // The workspace is /OpenXER/openxer.db. + assert_eq!( + per_user_workspace(xdg_data_home(None, s("/home/ann"))), + share.join("OpenXER").join(WORKSPACE_NAME) + ); + } + + /// This process's base is `%LOCALAPPDATA%` on Windows and the XDG rule + /// elsewhere. + #[test] + fn the_per_user_base_follows_the_system() { + #[cfg(windows)] + assert_eq!(user_data_base(), std::env::var_os("LOCALAPPDATA")); + #[cfg(not(windows))] + assert_eq!( + user_data_base(), + xdg_data_home(std::env::var_os("XDG_DATA_HOME"), std::env::var_os("HOME")) + ); + } + + #[test] + fn candidates_follow_the_desktop_rule() { + let dir = tempfile::tempdir().unwrap(); + let program = dir.path().join("Programs").join("OpenXER"); + let local = dir.path().join("Local"); + fs::create_dir_all(&program).unwrap(); + let per_user = local.join("OpenXER").join(WORKSPACE_NAME); + let beside = program.join(WORKSPACE_NAME); + + // Portable, nothing yet: beside the EXE first, the per-user one too. + let c = candidates(Some(&program), None, os(&local)); + assert_eq!(c[0].path, beside); + assert!(c[0].opened && !c[1].opened); + assert_eq!(c[1].path, per_user); + // Portable in a folder it can write: beside the EXE, even when a + // per-user workspace exists (that one is listed second). + fs::create_dir_all(per_user.parent().unwrap()).unwrap(); + fs::write(&per_user, b"").unwrap(); + let c = candidates(Some(&program), None, os(&local)); + assert_eq!((c[0].path.clone(), c[0].opened), (beside.clone(), true)); + assert_eq!((c[1].path.clone(), c[1].opened), (per_user.clone(), false)); + // The first entry is always the desktop's own answer, and the write + // check leaves nothing behind. + assert_eq!( + c[0].path, + default_workspace_in(Some(&program), None, os(&local)) + ); + assert!(fs::read_dir(&program).unwrap().next().is_none()); + // Installed: the per-user one, even with one left beside the EXE. + fs::write(program.join(crate::connect::INSTALLED_MARKER), b"").unwrap(); + fs::write(&beside, b"").unwrap(); + let c = candidates(Some(&program), None, os(&local)); + assert_eq!((c[0].path.clone(), c[0].opened), (per_user.clone(), true)); + assert_eq!(c[1].path, beside); + // Installed and the per-user one does not exist yet: the left one. + fs::remove_file(&per_user).unwrap(); + let c = candidates(Some(&program), None, os(&local)); + assert_eq!(c[0].path, beside); + // The override wins; an empty one is no override. + let moved = dir.path().join("Data"); + let c = candidates(Some(&program), os(&moved), os(&local)); + assert_eq!(c.len(), 1); + assert_eq!(c[0].path, moved.join(WORKSPACE_NAME)); + let c = candidates(Some(&program), Some(OsString::new()), os(&local)); + assert_eq!(c.len(), 2); + } + + #[test] + fn find_lists_workspace_projects_newest_first_and_folder_files() { + let dir = tempfile::tempdir().unwrap(); + let program = dir.path().join("app"); + let local = dir.path().join("Local"); + fs::create_dir_all(&program).unwrap(); + // Nothing yet: the agent is told to ask. + let out = find_in(Some(&program), None, os(&local), None).unwrap(); + assert_eq!(out["workspaces"], json!([])); + assert!(out["next"].as_str().unwrap().contains("Ask the user")); + + let db = program.join(WORKSPACE_NAME); + let c = Connection::open(&db).unwrap(); + c.execute_batch( + "CREATE TABLE projects(id INTEGER PRIMARY KEY,source_name TEXT NOT NULL,project_key INTEGER NOT NULL,title TEXT NOT NULL,xer_content TEXT NOT NULL,updated_at TEXT DEFAULT CURRENT_TIMESTAMP,UNIQUE(source_name,project_key)); + INSERT INTO projects VALUES(1,'C:\\jobs\\Old job.xer',10,'Old job','', '2026-01-02 08:00:00'); + INSERT INTO projects VALUES(2,'C:\\jobs\\Plant Ünit 2.xer',20,'Plant Unit 2','', '2026-11-09 17:30:00');", + ) + .unwrap(); + drop(c); + let before = fs::read(&db).unwrap(); + let out = find_in(Some(&program), None, os(&local), None).unwrap(); + let ws = &out["workspaces"][0]; + assert_eq!(ws["path"], json!(db)); + assert_eq!(ws["opened_by_openxer"], true); + assert_eq!(ws["project_count"], 2); + assert_eq!(ws["projects"][0]["name"], "Plant Unit 2", "newest first"); + assert_eq!(ws["projects"][0]["workspace_id"], 2); + assert_eq!( + ws["projects"][0]["source_name"], + "C:\\jobs\\Plant Ünit 2.xer" + ); + assert_eq!(ws["projects"][1]["project_id"], 10); + assert!(out["next"].as_str().unwrap().contains("workspace_id")); + assert_eq!(fs::read(&db).unwrap(), before, "read-only"); + let names: Vec<_> = fs::read_dir(&program) + .unwrap() + .map(|e| e.unwrap().file_name()) + .collect(); + assert_eq!( + names, + vec![OsString::from(WORKSPACE_NAME)], + "nothing written" + ); + + // A folder: XER files and workspaces only, not subfolders. + let folder = dir.path().join("Schedules"); + fs::create_dir_all(folder.join("sub")).unwrap(); + fs::write(folder.join("Week 14.XER"), b"ERMHDR").unwrap(); + fs::write(folder.join("notes.txt"), b"").unwrap(); + fs::write(folder.join("fake.db"), b"not sqlite").unwrap(); + fs::write(folder.join("sub").join("deep.xer"), b"").unwrap(); + fs::copy(&db, folder.join("copy.db")).unwrap(); + let out = find_in(Some(&program), None, os(&local), Some(&folder)).unwrap(); + let mut found: Vec<(String, String)> = out["folder"]["files"] + .as_array() + .unwrap() + .iter() + .map(|f| { + ( + Path::new(f["path"].as_str().unwrap()) + .file_name() + .unwrap() + .to_string_lossy() + .to_string(), + f["kind"].as_str().unwrap().to_string(), + ) + }) + .collect(); + found.sort(); + assert_eq!( + found, + vec![ + ("Week 14.XER".to_string(), "xer".to_string()), + ("copy.db".to_string(), "workspace".to_string()) + ] + ); + assert_eq!( + find_in( + Some(&program), + None, + os(&local), + Some(Path::new("relative")) + ) + .unwrap_err() + .code, + "invalid_arguments" + ); + } +} diff --git a/automation/src/main.rs b/automation/src/main.rs new file mode 100644 index 0000000..61427fc --- /dev/null +++ b/automation/src/main.rs @@ -0,0 +1,87 @@ +use openxer_automation::{ + cli::{self, Invocation}, + connect, dispatch, response, AutomationError, +}; +use std::{ + io::{self, Write}, + process::ExitCode, +}; + +fn emit(value: serde_json::Value, exit: u8) -> ExitCode { + let mut stdout = io::stdout().lock(); + let written = serde_json::to_writer(&mut stdout, &value) + .map_err(io::Error::other) + .and_then(|()| writeln!(stdout)); + if let Err(error) = written { + eprintln!("Cannot write command response: {error}"); + return ExitCode::from(1); + } + ExitCode::from(exit) +} + +/// The documented exit codes: 0 success, 2 invalid command-line or request +/// arguments (wherever they are found), 1 any other failure. +fn exit_code(result: &openxer_automation::Result) -> u8 { + match result { + Ok(_) => 0, + Err(e) if matches!(e.code.as_str(), "invalid_arguments" | "invalid_changes") => 2, + Err(_) => 1, + } +} + +fn main() -> ExitCode { + let arguments = std::env::args_os() + .skip(1) + .map(|value| { + value.into_string().map_err(|_| { + AutomationError::new("invalid_arguments", "Arguments must be valid Unicode") + }) + }) + .collect::>>(); + match arguments.and_then(cli::parse) { + Ok(Invocation::Help) => { + // A reader that closes the pipe early is not an error. + let _ = io::stdout().lock().write_all(cli::HELP.as_bytes()); + ExitCode::SUCCESS + } + Ok(Invocation::Version) => { + let _ = writeln!( + io::stdout().lock(), + "openxer-cli {}", + openxer_automation::VERSION + ); + ExitCode::SUCCESS + } + Ok(Invocation::Mcp) => match openxer_automation::mcp::run_stdio() { + Ok(()) => ExitCode::SUCCESS, + Err(error) => { + eprintln!("MCP transport error: {error}"); + ExitCode::from(1) + } + }, + Ok(Invocation::ChatMcp(context)) => { + match openxer_automation::mcp::run_stdio_with(openxer_automation::mcp::Server::chat( + context, + )) { + Ok(()) => ExitCode::SUCCESS, + Err(error) => { + eprintln!("MCP transport error: {error}"); + ExitCode::from(1) + } + } + } + Ok(Invocation::Connect(request)) => { + let exe = std::env::current_exe().ok(); + let env = connect::Env::from_process(exe); + let result = connect::run(&request, &env); + let exit = exit_code(&result); + emit(response(result), exit) + } + Ok(Invocation::Run(command)) => { + let result = dispatch(*command); + let exit = exit_code(&result); + emit(response(result), exit) + } + Err(error) => emit(response(Err(error)), 2), + } +} diff --git a/automation/src/mcp.rs b/automation/src/mcp.rs new file mode 100644 index 0000000..d851f9b --- /dev/null +++ b/automation/src/mcp.rs @@ -0,0 +1,995 @@ +//! Newline-delimited JSON-RPC transport for MCP. +use crate::{dispatch, parse_command, response, VERSION}; +use serde_json::{json, Map, Value}; +use std::io::{self, BufRead, Write}; + +pub const PROTOCOL_VERSION: &str = "2026-07-28"; +const LEGACY: &[&str] = &["2025-11-25", "2025-06-18", "2024-11-05"]; +const VERSION_KEY: &str = "io.modelcontextprotocol/protocolVersion"; +const CAPS_KEY: &str = "io.modelcontextprotocol/clientCapabilities"; +const INSTRUCTIONS: &str = "Native OpenXER scheduling. 1. When the user has not named a file (\"inspect my schedule\"), call openxer_find_schedules first: it lists the OpenXER workspace on this PC with its projects, most recently saved first; then pass that workspace as input with a workspace_id. 2. Before you analyze, build or change a schedule, call openxer_skills and follow the skill whose use_when matches (openxer_skill gets it; the user may also pick one from this server's prompts). 3. Never compute schedule numbers yourself: every count, date, float and percent comes from a tool result (openxer_check_schedule, openxer_paths, openxer_compare, openxer_lookahead, openxer_milestones, openxer_schedule_stats, openxer_resource_loading, openxer_wbs_summary and the others). Find_schedules, inspect, load, curves, usage, documents, read_document and the analysis tools are read-only; read_document returns the text of a project document's linked local file, addressed by the document, never by a path. Every mutation requires a new explicit output path; existing files are never overwritten; try it with dry_run first. Dates are project-local; durations and lags are integer working minutes in load and schedule, hours in the edit tools. Relationship editing does not implicitly recalculate. Edit tools (openxer_apply and the single-operation tools) name activities by Activity ID, resources by short name, calendars by name and WBS elements by code path; they use the desktop app's setters and run all or nothing. No other scheduling application or Python runtime is used."; + +#[derive(Default)] +pub struct Server { + initialized: bool, + ready: bool, + /// The Chat window's tool set (`mcp --toolset chat`) instead of the + /// full catalog. + chat: Option, +} + +impl Server { + /// A server of the chat tool set. + pub fn chat(context: crate::chat_tools::ChatContext) -> Server { + Server { + chat: Some(context), + ..Server::default() + } + } + + fn instructions(&self) -> String { + match &self.chat { + Some(chat) => crate::chat_tools::instructions(chat.mode), + None => INSTRUCTIONS.to_string(), + } + } + + fn tool_list(&self) -> Vec { + match &self.chat { + Some(chat) => crate::chat_tools::tool_list(chat), + None => tool_definitions(), + } + } + + fn server_capabilities(&self) -> Value { + if self.chat.is_some() { + json!({"tools":{}}) + } else { + capabilities() + } + } +} +fn rpc_error(id: Value, code: i64, message: &str, data: Option) -> Value { + let mut error = json!({"code":code,"message":message}); + if let Some(data) = data { + error["data"] = data; + } + json!({"jsonrpc":"2.0","id":id,"error":error}) +} +fn result(id: Value, mut value: Value, modern: bool) -> Value { + if modern { + value["resultType"] = json!("complete"); + value["_meta"] = + json!({"io.modelcontextprotocol/serverInfo":{"name":"openxer","version":VERSION}}); + } + json!({"jsonrpc":"2.0","id":id,"result":value}) +} +fn has_only(params: &Map, fields: &[&str]) -> bool { + params + .keys() + .all(|k| k == "_meta" || fields.contains(&k.as_str())) +} + +impl Server { + /// Handles one request. Modern requests are self-contained; legacy sessions + /// retain only handshake state, never an implicit current project. + pub fn handle(&mut self, request: Value) -> Option { + let Some(object) = request.as_object() else { + return Some(rpc_error( + Value::Null, + -32600, + "Expected one JSON-RPC request object", + None, + )); + }; + let id = object.get("id").cloned(); + let valid_id = id + .as_ref() + .is_none_or(|v| v.is_string() || v.as_i64().is_some() || v.as_u64().is_some()); + if object.get("jsonrpc") != Some(&json!("2.0")) + || object.get("method").and_then(Value::as_str).is_none() + || !valid_id + { + return Some(rpc_error( + if valid_id { + id.unwrap_or(Value::Null) + } else { + Value::Null + }, + -32600, + "Invalid JSON-RPC request", + None, + )); + } + let method = object["method"].as_str().expect("validated method"); + if id.is_none() { + if method == "notifications/initialized" && self.initialized { + self.ready = true; + } + // Never execute a mutating tool in a notification: no result could + // tell the caller whether its requested file was actually created. + return None; + } + let id = id.expect("request id"); + let empty = Map::new(); + let params = match object.get("params") { + None => &empty, + Some(Value::Object(v)) => v, + _ => return Some(rpc_error(id, -32602, "params must be an object", None)), + }; + if params.get("_meta").is_some_and(|value| !value.is_object()) { + return Some(rpc_error( + id, + -32602, + "params._meta must be an object", + None, + )); + } + let meta = params.get("_meta").and_then(Value::as_object); + let modern = method == "server/discover" + || meta.is_some_and(|m| m.contains_key(VERSION_KEY) || m.contains_key(CAPS_KEY)); + if modern { + let version = meta + .and_then(|m| m.get(VERSION_KEY)) + .and_then(Value::as_str); + let caps = meta + .and_then(|m| m.get(CAPS_KEY)) + .and_then(Value::as_object); + if version.is_none() || caps.is_none() { + return Some(rpc_error(id,-32602,"Modern requests require protocolVersion and clientCapabilities in params._meta",None)); + } + if version != Some(PROTOCOL_VERSION) { + return Some(rpc_error( + id, + -32022, + "Unsupported protocol version", + Some(json!({"requested":version,"supported":[PROTOCOL_VERSION]})), + )); + } + } + if method == "initialize" && !modern { + if !has_only(params, &["protocolVersion", "capabilities", "clientInfo"]) + || params + .get("protocolVersion") + .and_then(Value::as_str) + .is_none() + || !params.get("capabilities").is_some_and(Value::is_object) + || !params.get("clientInfo").is_some_and(|v| { + v.get("name").is_some_and(Value::is_string) + && v.get("version").is_some_and(Value::is_string) + }) + { + return Some(rpc_error( + id, + -32602, + "initialize requires protocolVersion, capabilities and clientInfo", + None, + )); + } + if self.initialized { + return Some(rpc_error( + id, + -32600, + "Session is already initialized", + None, + )); + } + let requested = params["protocolVersion"] + .as_str() + .expect("validated version"); + let negotiated = if LEGACY.contains(&requested) { + requested + } else { + LEGACY[0] + }; + self.initialized = true; + return Some(result( + id, + json!({"protocolVersion":negotiated,"capabilities":self.server_capabilities(),"serverInfo":{"name":"openxer","version":VERSION},"instructions":self.instructions()}), + false, + )); + } + if !modern && !self.ready && method != "ping" { + return Some(rpc_error( + id, + -32600, + "Initialize the legacy session or supply per-request MCP metadata", + None, + )); + } + let value = match method { + "ping" if has_only(params, &[]) => json!({}), + "server/discover" if modern && has_only(params, &[]) => { + json!({"supportedVersions":[PROTOCOL_VERSION],"capabilities":self.server_capabilities(),"instructions":self.instructions(),"ttlMs":3600000,"cacheScope":"public"}) + } + "tools/list" if has_only(params, &["cursor"]) => { + if params.get("cursor").is_some_and(|v| !v.is_null()) { + return Some(rpc_error( + id, + -32602, + "This server has a single tool page; omit cursor", + None, + )); + } + let mut list = json!({"tools":self.tool_list()}); + if modern { + list["ttlMs"] = json!(3600000); + list["cacheScope"] = json!("public"); + } + list + } + "tools/call" if has_only(params, &["name", "arguments"]) => { + let Some(name) = params.get("name").and_then(Value::as_str) else { + return Some(rpc_error(id, -32602, "Tool name must be a string", None)); + }; + if let Some(chat) = &self.chat { + let Some(args) = params.get("arguments").filter(|v| v.is_object()) else { + return Some(rpc_error( + id, + -32602, + "Tool arguments must be an object", + None, + )); + }; + if !crate::chat_tools::tools(chat) + .iter() + .any(|t| t.name == name) + { + return Some(rpc_error(id, -32602, "Unknown OpenXER tool", None)); + } + // Text only: the chat tools publish no output schema, so + // the result is not sent twice. + let done = crate::chat_tools::call(chat, name, args.clone()); + let value = json!({"content":[{"type":"text","text":done.text}],"isError":done.is_error}); + return Some(result(id, value, modern)); + } + let Some(command) = tool_command(name) else { + return Some(rpc_error(id, -32602, "Unknown OpenXER tool", None)); + }; + let Some(mut args) = params.get("arguments").and_then(Value::as_object).cloned() + else { + return Some(rpc_error( + id, + -32602, + "Tool arguments must be an object", + None, + )); + }; + if args.contains_key("command") { + return Some(rpc_error( + id, + -32602, + "Tool arguments must not contain command", + None, + )); + } + // "p6" is the old name of the tables layout; old scripts still + // send it, so it is accepted without being published. + if command == "export_xlsx" + && args.get("layout").and_then(Value::as_str) == Some("p6") + { + args.insert("layout".into(), json!("tables")); + } + let schema = tool_definitions() + .into_iter() + .find(|t| t["name"] == name) + .expect("known tool has schema"); + if let Err(message) = validate_arguments( + &Value::Object(args.clone()), + &schema["inputSchema"], + "arguments", + ) { + return Some(rpc_error(id, -32602, &message, None)); + } + if let Some(op) = edit_tool(name) { + args = edit_arguments(op, args); + } + if name == "openxer_eps_edit" { + args = eps_arguments(args); + } + if name == "openxer_baseline_edit" { + args = crate::baseline_cmd::mcp_arguments(args); + } + args.insert("command".into(), json!(command)); + let command = match parse_command(Value::Object(args)) { + Ok(c) => c, + Err(e) => return Some(rpc_error(id, -32602, &e.message, None)), + }; + let execution = dispatch(command); + let failed = execution.is_err(); + let envelope = response(execution); + json!({"content":[{"type":"text","text":envelope.to_string()}],"structuredContent":envelope,"isError":failed}) + } + // One prompt per skill, read from the skill folder on every + // request, so an edited or new skill shows up without a restart. + "prompts/list" if has_only(params, &["cursor"]) => { + if params.get("cursor").is_some_and(|v| !v.is_null()) { + return Some(rpc_error( + id, + -32602, + "This server has a single prompt page; omit cursor", + None, + )); + } + json!({"prompts": prompt_list()}) + } + "prompts/get" if has_only(params, &["name", "arguments"]) => { + let Some(name) = params.get("name").and_then(Value::as_str) else { + return Some(rpc_error(id, -32602, "Prompt name must be a string", None)); + }; + if params + .get("arguments") + .is_some_and(|v| !v.is_null() && !v.is_object()) + { + return Some(rpc_error( + id, + -32602, + "Prompt arguments must be an object", + None, + )); + } + let catalog = crate::skills::catalog(); + let Some(entry) = catalog.get(name) else { + return Some(rpc_error(id, -32602, "Unknown prompt", None)); + }; + json!({"description": entry.skill.description, + "messages":[{"role":"user","content":{"type":"text","text":crate::skills::prompt_text(&entry.skill)}}]}) + } + "ping" | "server/discover" | "tools/list" | "tools/call" | "prompts/list" + | "prompts/get" => { + return Some(rpc_error(id, -32602, "Invalid method parameters", None)) + } + _ => return Some(rpc_error(id, -32601, "Method not found", None)), + }; + Some(result(id, value, modern)) + } +} + +/// The command an MCP tool runs. +pub(crate) fn tool_command(name: &str) -> Option<&'static str> { + Some(match name { + "openxer_inspect" => "inspect", + "openxer_find_schedules" => "find_schedules", + "openxer_import" => "import", + "openxer_load" => "load", + "openxer_check_schedule" => "check_schedule", + "openxer_playbook" => "playbook", + "openxer_curves" => "curves", + "openxer_usage" => "usage", + "openxer_schedule" => "schedule", + "openxer_relationship" => "relationship", + "openxer_export" => "export", + "openxer_export_xlsx" => "export_xlsx", + "openxer_export_pdf" => "export_pdf", + "openxer_export_scurve" => "export_scurve", + "openxer_export_earned_hours" => "export_earned_hours", + "openxer_import_xlsx" => "import_xlsx", + "openxer_documents" => "documents", + "openxer_records" => "records", + "openxer_earned_value" => "earned_value", + "openxer_read_document" => "read_document", + "openxer_apply" => "apply", + "openxer_eps_list" => "eps_list", + "openxer_eps_edit" => "eps", + "openxer_baseline_list" => "baseline_list", + "openxer_baseline_edit" => "baseline", + "openxer_baseline_update" => "baseline_update", + "openxer_paths" => "paths", + "openxer_compare" => "compare", + "openxer_lookahead" => "lookahead", + "openxer_milestones" => "milestones", + "openxer_schedule_stats" => "schedule_stats", + "openxer_resource_loading" => "resource_loading", + "openxer_wbs_summary" => "wbs_summary", + "openxer_skills" => "skills", + "openxer_skill" => "skill", + other => { + if let Some((_, c)) = crate::workspace_cmd::TOOLS + .iter() + .find(|(t, _)| *t == other) + { + c + } else if edit_tool(other).is_some() { + "edit" + } else { + return None; + } + } + }) +} + +/// The fields of edit operation `op` as its single edit tool takes them: +/// (field, required). Empty for an operation without its own tool. +pub(crate) fn edit_tool_fields(op: &str) -> Vec<(&'static str, bool)> { + EDIT_TOOLS + .iter() + .find(|t| t.1 == op) + .map(|t| t.3.iter().map(|(f, _, required)| (*f, *required)).collect()) + .unwrap_or_default() +} + +// Validate the vocabulary used by our published schemas before serde conversion; +// optional does not imply nullable, and integer bounds apply before execution. +pub(crate) fn validate_arguments(value: &Value, schema: &Value, path: &str) -> Result<(), String> { + let matches_type = |kind: &str| match kind { + "object" => value.is_object(), + "string" => value.is_string(), + "boolean" => value.is_boolean(), + "integer" => value.as_i64().is_some() || value.as_u64().is_some(), + "null" => value.is_null(), + "number" => value.is_number(), + "array" => value.is_array(), + _ => false, + }; + let valid_type = match &schema["type"] { + Value::String(kind) => matches_type(kind), + Value::Array(kinds) => kinds.iter().filter_map(Value::as_str).any(matches_type), + _ => true, + }; + if !valid_type { + return Err(format!("{path} has the wrong JSON type")); + } + if let Some(values) = schema["enum"].as_array().filter(|v| !v.contains(value)) { + let names: Vec<&str> = values.iter().filter_map(Value::as_str).collect(); + return Err(if names.len() == values.len() && names.len() <= 20 { + format!( + "{path} is not an allowed value; use one of {}", + names.join(", ") + ) + } else { + format!("{path} is not an allowed value") + }); + } + if let Some(number) = value.as_i64() { + if schema["minimum"].as_i64().is_some_and(|min| number < min) + || schema["maximum"].as_i64().is_some_and(|max| number > max) + { + return Err(format!("{path} is outside the allowed range")); + } + } else if let Some(number) = value.as_u64() { + if schema["maximum"].as_u64().is_some_and(|max| number > max) { + return Err(format!("{path} is outside the allowed range")); + } + } + if let Some(text) = value.as_str() { + if schema["minLength"] + .as_u64() + .is_some_and(|min| (text.chars().count() as u64) < min) + { + return Err(format!("{path} is too short")); + } + } + if let Some(object) = value.as_object() { + if let Some(required) = schema["required"].as_array() { + for field in required.iter().filter_map(Value::as_str) { + if !object.contains_key(field) { + return Err(format!("{path}.{field} is required")); + } + } + } + for (field, child) in object { + if let Some(child_schema) = schema["properties"].get(field) { + validate_arguments(child, child_schema, &format!("{path}.{field}"))?; + } else if schema["additionalProperties"] == false { + return Err(format!("Unknown field {path}.{field}")); + } + } + } + Ok(()) +} + +pub fn run_stdio() -> io::Result<()> { + run_stdio_with(Server::default()) +} + +/// Serve `server` over stdin and stdout until stdin closes. +pub fn run_stdio_with(mut server: Server) -> io::Result<()> { + let stdin = io::stdin(); + let stdout = io::stdout(); + let mut output = stdout.lock(); + for line in stdin.lock().lines() { + let line = line?; + if line.trim().is_empty() { + continue; + } + let reply = match serde_json::from_str(&line) { + Ok(value) => server.handle(value), + Err(_) => Some(rpc_error(Value::Null, -32700, "Parse error", None)), + }; + if let Some(reply) = reply { + serde_json::to_writer(&mut output, &reply)?; + output.write_all(b"\n")?; + output.flush()?; + } + } + Ok(()) +} + +/// The single-operation edit tools: tool name, operation, description and +/// the operation's own fields (name, schema, required). +type EditTool = ( + &'static str, + &'static str, + &'static str, + &'static [(&'static str, &'static str, bool)], +); +const EDIT_TOOLS: &[EditTool] = &[ + ("openxer_set_activity", "set_activity", "Set one activity field through the desktop's setters (status, durations and assignments follow the same rules). Fields are OpenXER column keys such as remaining_duration, actual_start, physical_percent_complete, calendar, duration_type.", &[("activity", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_add_activity", "add_activity", "Add an activity with the project's defaults for new activities (types, calendar, 5 day duration). Without an Activity ID it takes the next ID from the project's auto-numbering; selected names the activity to increment from, as the app's selection does.", &[("activity", "text", false), ("selected", "text", false), ("name", "text", false), ("wbs", "text", false)]), + ("openxer_delete_activity", "delete_activity", "Delete an activity with its relationships and assignments.", &[("activity", "text", true)]), + ("openxer_dissolve_activity", "dissolve_activity", "Edit > Dissolve: remove an activity that has at least one predecessor and one successor, and tie each predecessor to each successor. The new relationship starts where the predecessor relationship starts and ends where the successor relationship ends; a pair already related keeps its relationship. Lag is 0, or with retain_lag the two lags added. Nothing is rescheduled.", &[("activity", "text", true), ("retain_lag", "boolean", false)]), + ("openxer_assign", "assign_resource", "Assign a resource (by short name) to an activity.", &[("activity", "text", true), ("resource", "text", true)]), + ("openxer_unassign", "remove_assignment", "Remove a resource assignment.", &[("activity", "text", true), ("resource", "text", true)]), + ("openxer_set_assignment", "set_assignment", "Set one assignment field (budgeted_units, remaining_units, actual_regular_units, price_per_unit, rate_type, lag_hours and more) with the duration type rules. period_remaining_units with DATE=UNITS or START,FINISH=UNITS types the remaining units of those days, as in the usage spreadsheet (the curve becomes Manual; curve null removes the typed values).", &[("activity", "text", true), ("resource", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_calendar_day", "calendar_day", "Set one date of a calendar: shifts [[\"08:00\",\"12:00\"],...], [] for nonwork, or null for the weekday pattern.", &[("calendar", "text", true), ("date", "text", true), ("shifts", "shifts_or_null", false)]), + ("openxer_calendar_weekday", "calendar_weekday", "Set a calendar's work periods for one weekday (0 = Sunday); [] is nonwork.", &[("calendar", "text", true), ("weekday", "weekday", true), ("shifts", "shifts", true)]), + ("openxer_set_project", "set_project", "Set the data date or must finish date (project-local YYYY-MM-DD HH:MM).", &[("field", "project_field", true), ("value", "value", true), ("schedule", "boolean", false)]), + ("openxer_add_wbs", "add_wbs", "Add the WBS elements of a code path (1.2.3) that do not exist yet.", &[("wbs", "text", true), ("name", "text", false)]), + ("openxer_add_document", "add_document", "Add a work product or document titled title, under the document parent (reference number, title or id) or at the top level; fields sets more of its fields at once.", &[("title", "text", true), ("parent", "text", false), ("reference", "text", false), ("fields", "object", false)]), + ("openxer_set_document", "set_document", "Set one field of a document (named by reference number, title or document id): title, reference, deliverable, status, category (by name), author, version, date (YYYY-MM-DD[ HH:MM]), private_location, public_location or description; null clears.", &[("document", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_document", "delete_document", "Delete a document with the documents under it and their links to activities and WBS elements.", &[("document", "text", true)]), + ("openxer_link_document", "link_document", "Link a document to an activity (Activity ID) or to a WBS element itself (path); work_product marks the link as a work product.", &[("document", "text", true), ("activity", "text", false), ("wbs", "text", false), ("work_product", "boolean", false)]), + ("openxer_unlink_document", "unlink_document", "Remove a document's link to an activity or a WBS element.", &[("document", "text", true), ("activity", "text", false), ("wbs", "text", false)]), + ("openxer_add_expense", "add_expense", "Add an expense item to an activity, with name and any fields (category, cost_account, accrual, unit_of_measure, vendor, po_number, auto_compute_actuals, budgeted_units, price_per_unit, budgeted_cost, actual_cost, remaining_cost, description).", &[("activity", "text", true), ("name", "text", false), ("fields", "fields", false)]), + ("openxer_set_expense", "set_expense", "Set one field of an expense item (by id or name) as the Expenses view does: budgeted units x price is the budgeted cost, and an item without actuals keeps its budget remaining. activity moves it.", &[("expense", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_expense", "delete_expense", "Delete an expense item (by id or name).", &[("expense", "text", true)]), + ("openxer_add_issue", "add_issue", "Add an open issue identified today, with name and any fields (responsible_manager, priority, status, identified_on, identified_by, resolution_date, activity or wbs, resource, notes).", &[("name", "text", false), ("fields", "fields", false)]), + ("openxer_set_issue", "set_issue", "Set one field of an issue (by id or name); activity and wbs are exclusive (setting one clears the other).", &[("issue", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_issue", "delete_issue", "Delete an issue with its history.", &[("issue", "text", true)]), + ("openxer_add_risk", "add_risk", "Add a proposed threat identified today with the next free Risk ID, with name and any fields (risk_id, category, type, status, owner, identified_by, identified_on, pre/post response probability, schedule and cost, response_type, response_description, description, cause, effect, notes).", &[("name", "text", false), ("fields", "fields", false)]), + ("openxer_set_risk", "set_risk", "Set one field of a risk (by id, Risk ID or name).", &[("risk", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_risk", "delete_risk", "Delete a risk with its activity assignments.", &[("risk", "text", true)]), + ("openxer_assign_risk", "assign_risk", "Assign a risk to an activity.", &[("risk", "text", true), ("activity", "text", true)]), + ("openxer_unassign_risk", "unassign_risk", "Remove a risk's assignment to an activity.", &[("risk", "text", true), ("activity", "text", true)]), + ("openxer_add_threshold", "add_threshold", "Add an enabled threshold (total float, lower 0, activities) or one on parameter (name or measured field, see openxer_records kind thresholds) with any fields (lower_threshold, upper_threshold, detail_to_monitor, wbs, responsible_manager, priority, status, from_date, to_date).", &[("parameter", "text", false), ("fields", "fields", false)]), + ("openxer_set_threshold", "set_threshold", "Set one field of a threshold (by id).", &[("threshold", "text", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_threshold", "delete_threshold", "Delete a threshold; the issues it raised stay.", &[("threshold", "text", true)]), + ("openxer_update_progress", "update_progress", "Tools > Update Progress: record progress as scheduled up to the new data_date for every activity (or only activities, a list of Activity IDs), spend flagged expenses of the activities it progresses, then move the data date. remaining is always (remaining work to the scheduled finish) or duration_type. Schedule afterwards.", &[("data_date", "text", true), ("activities", "list", false), ("remaining", "remaining", false)]), + ("openxer_apply_actuals", "apply_actuals", "Tools > Apply Actuals: progress what is set to compute actuals up to the new data_date. The activity flag, or every assignment's resource flag, progresses the activity and all its assignments; flagged resources on some assignments give only those actuals (units/time x working time since their remaining start); a flagged expense of a started activity accrues uniformly. A project already at data_date is left alone. Stamps the apply actuals date.", &[("data_date", "text", true), ("remaining", "remaining", false)]), + ("openxer_recalculate_costs", "recalculate_costs", "Tools > Recalculate Assignment Costs from the resources' prices; assignments priced from a role or an override, with costs not linked to units, or with a price change during the assignment are skipped and listed.", &[("active_only", "boolean", false), ("sync_overtime", "boolean", false)]), + ("openxer_add_step", "add_step", "Add a step to an activity, at position at (1 is first; the end when omitted).", &[("activity", "text", true), ("name", "text", true), ("at", "count", false)]), + ("openxer_set_step", "set_step", "Set one field of an activity step (step by number from 1, or name): name, complete, percent_complete (100 completes it), weight or description. When the project's steps drive percent complete the activity's physical percent follows.", &[("activity", "text", true), ("step", "step", true), ("field", "text", true), ("value", "value", true)]), + ("openxer_delete_step", "delete_step", "Delete an activity step (by number or name).", &[("activity", "text", true), ("step", "step", true)]), + ("openxer_move_step", "move_step", "Move an activity step to position to (1 is first).", &[("activity", "text", true), ("step", "step", true), ("to", "count", true)]), + ("openxer_add_steps_from_template", "add_steps_from_template", "Add a step template's steps (by name) after the activity's step after (number or name), or after its last step.", &[("activity", "text", true), ("template", "text", true), ("after", "value", false)]), + ("openxer_create_step_template", "create_step_template", "Create a step template named name from the activity's steps.", &[("activity", "text", true), ("name", "text", true)]), + ("openxer_set_feedback", "set_feedback", "Set an activity's notes to resources (null clears) and whether its feedback needs review.", &[("activity", "text", true), ("notes", "value", false), ("review_required", "boolean", false)]), + ("openxer_top_down_estimate", "top_down_estimate", "Tools > Top Down Estimation: spread labor_units over the not started Task and Resource Dependent activities below wbs (the whole project when omitted) by the WBS estimation weights; weights {path: weight} are stored first.", &[("labor_units", "number", true), ("wbs", "text", false), ("not_started_only", "boolean", false), ("weights", "fields", false)]), + ("openxer_shift_wbs", "shift_wbs", "Move a WBS element up or down among its siblings, left out to its parent's level or right into the sibling above.", &[("wbs", "text", true), ("direction", "direction", true)]), + ("openxer_rename_wbs_code", "rename_wbs_code", "Change a WBS element's own code (unique among its siblings).", &[("wbs", "text", true), ("code", "text", true)]), + ("openxer_copy_calendar", "copy_calendar", "Add a calendar named calendar of kind project (default), global or resource, copied from source (a standard 5-day week without one).", &[("calendar", "text", true), ("source", "text", false), ("kind", "calendar_kind", false)]), + ("openxer_rename_calendar", "rename_calendar", "Rename a calendar.", &[("calendar", "text", true), ("name", "text", true)]), + ("openxer_set_default_calendar", "set_default_calendar", "Make a global calendar the default.", &[("calendar", "text", true)]), + ("openxer_convert_calendar", "convert_calendar", "Convert a project calendar to global, or a resource calendar to shared or personal.", &[("calendar", "text", true), ("to", "calendar_to", true)]), + ("openxer_global_change", "global_change", "Tools > Global Change on every activity of the project: run a global change saved in the workspace input (name) or one given as rule {\"match\":\"all\"|\"any\",\"conditions\":[{\"column\",\"op\",\"value\",\"high\"}],\"then\":[{\"column\",\"value\",\"operator\",\"value2\"}],\"otherwise\":[...]}. Columns are field ids or titles (user defined fields and activity codes included); op is a key (eq, ne, contains, not_contains, starts_with, lt, le, gt, ge, within, not_within, under) or its caption, under (is under) for WBS and activity codes; operator is +, -, x, / or & with value2; a value is a literal, a field title or a quoted text. dry_run returns the report lines (activity, field, old, new, exception) the app shows, durations in hours; otherwise the lines without an exception are written and changed counts them.", &[("name", "text", false), ("rule", "rule", false)]), + ("openxer_monitor_thresholds", "monitor_thresholds", "Monitor Thresholds: evaluate every enabled threshold as the app does (float and date variances in days, duration and cost percents, earned value amounts and indexes against the assigned baselines) and raise an issue for each activity or WBS element outside its bounds, or update the open issue raised before. from and to replace every threshold's own window; today dates new issues (default today).", &[("from", "text", false), ("to", "text", false), ("today", "text", false)]), +]; + +/// The operation an edit tool runs. +fn edit_tool(name: &str) -> Option<&'static str> { + EDIT_TOOLS.iter().find(|t| t.0 == name).map(|t| t.1) +} + +/// Move an edit tool's operation fields into the `operation` of an `edit` +/// command; the file and mode arguments stay at the top. +fn edit_arguments(op: &str, args: Map) -> Map { + let mut top = Map::new(); + let mut operation = Map::new(); + operation.insert("op".into(), json!(op)); + for (k, v) in args { + if matches!( + k.as_str(), + "input" | "output" | "project_id" | "workspace_id" | "dry_run" | "recalculate" + ) { + top.insert(k, v); + } else { + operation.insert(k, v); + } + } + top.insert("operation".into(), Value::Object(operation)); + top +} + +fn edit_schema(kind: &str) -> Value { + let shifts = json!({"type":"array","items":{"type":"array"},"description":"[[\"HH:MM\",\"HH:MM\"],...]"}); + match kind { + "text" => json!({"type":"string","minLength":1}), + "value" => { + json!({"type":["string","number","boolean","null"],"description":"Hours for durations, YYYY-MM-DD HH:MM for dates, codes or names for choices, true or false for yes/no fields; null clears"}) + } + "shifts" => shifts, + "shifts_or_null" => { + json!({"type":["array","null"],"description":"[[\"HH:MM\",\"HH:MM\"],...]; [] nonwork; null the weekday pattern"}) + } + "weekday" => json!({"type":"integer","minimum":0,"maximum":6}), + "boolean" => json!({"type":"boolean"}), + "object" => { + json!({"type":"object","description":"Document fields and values, as for set_document"}) + } + "fields" => { + json!({"type":"object","description":"Field names and values, as for the matching set_ operation"}) + } + "list" => json!({"type":"array","items":{"type":"string","minLength":1}}), + "count" => json!({"type":"integer","minimum":1}), + "number" => json!({"type":"number"}), + "project_field" => json!({"type":"string","enum":["data_date","must_finish"]}), + "step" => { + json!({"type":["string","integer"],"description":"Step number from 1, or the step's name"}) + } + "direction" => json!({"type":"string","enum":["up","down","left","right"]}), + "calendar_to" => json!({"type":"string","enum":["global","shared","personal"]}), + "calendar_kind" => json!({"type":"string","enum":["project","global","resource"]}), + "remaining" => json!({"type":"string","enum":["always","duration_type"]}), + "rule" => { + json!({"type":"object","description":"A global change: match, conditions, then, otherwise (see the tool description)"}) + } + _ => json!({}), + } +} + +/// Input, output and mode arguments every edit tool takes. +fn edit_common(p: &mut Map) { + p.insert("input".into(),json!({"type":"string","minLength":1,"description":"Local XER or OpenXER workspace path; read-only"})); + p.insert("output".into(),json!({"type":"string","minLength":1,"description":"New destination path; existing files are refused. Omit with dry_run"})); + p.insert( + "project_id".into(), + json!({"type":"integer","description":"Project id (the XER proj_id) returned by inspect"}), + ); + p.insert( + "workspace_id".into(), + json!({"type":"integer","description":"Workspace row id, useful when project ids repeat"}), + ); + p.insert("dry_run".into(),json!({"type":"boolean","default":false,"description":"Return the field diff without writing"})); + p.insert("recalculate".into(),json!({"type":"boolean","description":"false writes set_activity and set_assignment values exactly, with no duration type, units or cost knock-on"})); +} + +/// The `openxer_apply` description: what it does and every operation, from +/// the one list the edit format has. +fn apply_description() -> String { + format!( + "Apply an openxer-changes/1 batch in order, all or nothing, to a new file (dry_run returns the field diff). Operations: {}. Each operation may carry a meta object that is ignored; see the single edit tools for each operation's fields.", + crate::edit::OPERATIONS.join(", ") + ) +} + +fn edit_tool_definitions() -> Vec { + let output = json!({"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}); + let annotations = json!({"readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false}); + let mut tools = vec![]; + let mut p = Map::new(); + edit_common(&mut p); + p.insert("changes".into(),json!({"type":"object","description":"An openxer-changes/1 document: {\"format\":\"openxer-changes/1\",\"recalculate\":true,\"operations\":[...]}"})); + p.insert("changes_file".into(),json!({"type":"string","minLength":1,"description":"Path of an openxer-changes/1 .json file, instead of changes"})); + tools.push(json!({"name":"openxer_apply","description":apply_description(), + "inputSchema":object(Value::Object(p),&["input"]),"outputSchema":output,"annotations":annotations})); + for (name, _, description, fields) in EDIT_TOOLS { + let mut p = Map::new(); + edit_common(&mut p); + let mut required = vec!["input"]; + for (field, kind, needed) in fields.iter() { + p.insert((*field).into(), edit_schema(kind)); + if *needed { + required.push(field); + } + } + tools.push(json!({"name":name,"description":description,"inputSchema":object(Value::Object(p),&required),"outputSchema":output,"annotations":annotations})); + } + tools +} + +fn object(properties: Value, required: &[&str]) -> Value { + json!({"type":"object","properties":properties,"required":required,"additionalProperties":false}) +} +fn options_schema() -> Value { + let mut p = Map::new(); + for field in [ + "retained_logic", + "progress_override", + "lag_from_early_start", + "use_expected_finish", + "level_resources", + "ignore_external_relationships", + "open_ends_critical", + "use_must_finish", + "multiple_float_paths", + "float_paths_use_total", + ] { + p.insert(field.into(), json!({"type":"boolean"})); + } + p.insert( + "data_date".into(), + json!({"type":"string","description":"Project-local YYYY-MM-DD or YYYY-MM-DD HH:MM"}), + ); + p.insert( + "must_finish".into(), + json!({"type":["string","null"],"description":"Project-local date, or null to clear"}), + ); + p.insert( + "lag_calendar".into(), + json!({"type":"string","enum":["predecessor","successor","24_hour","project"]}), + ); + p.insert( + "float_type".into(), + json!({"type":"string","enum":["start","finish","minimum"]}), + ); + p.insert( + "max_float_paths".into(), + json!({"type":"integer","minimum":1}), + ); + p.insert( + "float_paths_end_activity".into(), + json!({"type":["integer","null"]}), + ); + object(Value::Object(p), &[]) +} +pub fn tool_definitions() -> Vec { + let mut tools = vec![json!({"name":"openxer_find_schedules", + "description":"Start here when the user has not named a file. Lists the OpenXER workspace on this PC (the one the OpenXER app opens, and another copy's when there is one) with its projects, most recently saved first: workspace_id, project_id, name and the XER file each came from. Pass the workspace path as input with a workspace_id to the other tools. With folder (an absolute path), also lists the XER files and workspaces directly in that folder. Read-only; needs no arguments.", + "inputSchema":object(json!({"folder":{"type":"string","minLength":1,"description":"Absolute path of a folder to list schedule files in (not its subfolders), such as the user's Downloads"}}),&[]), + "outputSchema":{"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}, + "annotations":{"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}})]; + let playbooks: Vec<&str> = crate::playbooks::PLAYBOOKS + .iter() + .map(|(n, _, _)| *n) + .collect(); + tools.push(json!({"name":"openxer_playbook", + "description":"Scheduling playbooks: step-by-step methods that name the tools to use. Without name, the list; with name, one playbook. Load the matching one before a build, an update, an audit or a health check.", + "inputSchema":object(json!({"name":{"type":"string","enum":playbooks}}),&[]), + "outputSchema":{"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}, + "annotations":{"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}})); + for (name,description,write) in [ + ("inspect","Inspect XER tables or list projects in an OpenXER workspace without modifying it. Do not know the file? Call openxer_find_schedules first.",false), + ("import","Import selected or all XER projects into a new desktop-compatible OpenXER workspace. The input may also be a project XML file (root element APIBusinessObjects); the format is told from the contents.",true), + ("load","Load project options and independently paged activity/relationship data without scheduling. fields, activities, wbs and critical keep the answer small and sort orders it; with an activity filter the relationships are those touching the matched activities.",false), + ("check_schedule","Tools > Check Schedule, read-only: the app's 15 schedule health checks with its default targets, one row each (check, count, of, result as a percent or the BEI index, target, pass, and the first five offenders). check (a row's name) also lists that row's Activity IDs or relationships, up to limit. Late Activities and BEI compare with the project's own planned finishes.",false), + ("curves","List the resource curves an assignment can use (the file's own and OpenXER's presets) with their 21 points, read-only. Set one with set_assignment field curve and the curve name.",false), + ("usage","Time-phased units (or costs) of an activity's or a resource's assignments per day, week or month, read-only: budgeted, actual, remaining and remaining late per period, spread as the desktop usage views spread them, so resource curves shape it on Fixed Duration activities. Also each assignment's windows, curve and whether it applies.",false), + ("schedule","Run the native scheduler and optional resource leveling; write a new XER/workspace and report up to 200 changed activities.",true), + ("relationship","Add, update, or remove a validated relationship; write a new file. Does not implicitly schedule.",true), + ("export","Export selected workspace/XER project state to a new XER, retaining other tables and projects in its source document. With projects, writes only those projects; version sets the header version label. format xml (or an output ending in .xml) writes project XML instead: projects, WBS, activities, relationships, calendars, resources, roles, assignments, codes, UDFs, expenses and baselines in the file.",true), + ("export_xlsx","Export one project to a new .xlsx: the modern layout (real dates, durations in a stated unit, WBS outline, Relationships and About sheets) or the tables layout (TASK, TASKPRED and TASKRSRC sheets with XER field names).",true), + ("export_pdf","Print one project's activity layout (table and Gantt, or Activity Network) to a new vector PDF with its saved Page Setup, using the desktop renderer headless.",true), + ("export_scurve","Write a project's S-curve to a new .xlsx, as Tools > Reports > S-Curve does: per period (week from Sunday by default) the budgeted (from the assigned baseline, else the current plan), actual (to the data date) and remaining values with running sums and percents as formulas, earned to the data date and a native chart; one sheet each for budgeted, actual and remaining by resource or WBS level; an Info sheet with the data date, baseline, detection and warnings. measure auto picks labor hours when labor assignments carry budgeted units, else cost, else duration (each activity weighs its planned working days).",true), + ("export_earned_hours","Write cumulative earned labor hours to the data date to a new .xlsx, as Tools > Reports > Earned Hours does: Earned to date (one row per resource, WBS element or activity: budgeted, earned, actual, remaining, at completion, % earned) and By activity (one row per labor assignment, by Activity ID then resource). Earned = baseline budgeted units x performance % complete, as earned value computes it; rows and columns keep a stable order so two exports subtract in Excel. Error no_labor_units when the project has no labor hours.",true), + ("import_xlsx","Preview (dry_run) or apply a spreadsheet of activity and relationship changes to a project; writes a new file. Rows match by Activity ID; deletes need an explicit D flag.",true), + ("records","List the project's expense items, issues, risks or thresholds (kind) with every field as the edits name it: choices by label, activities by Activity ID, WBS elements by code path, resources by short name; thresholds come with the parameter list. activity keeps only that activity's records. Read-only.",false), + ("earned_value","Earned value per activity and for the project, as the earned value columns compute it (BAC, PV, EV, AC, SV, CV, SPI, CPI, ETC, EAC, VAC, performance and schedule percent complete) in cost or labor_units, against the workspace's assigned project or primary baseline (the project itself when none). Read-only.",false), + ("documents","List a project's work products and documents: title, reference, version, status, category, author, date, private and public file locations, description, and the activities and WBS elements each is linked to. activity or wbs keeps only the documents linked there.",false), + ("read_document","Read the text of the file a project document points at (named by reference number, title or document id; never a free path). Only existing files on a local drive by absolute path, under the input file's folder or a folder in the OPENXER_DOCUMENT_ROOTS environment variable of the server; relative, network and web locations, programs and scripts are refused. A PDF page cut by limit is marked truncated. txt, md, csv, json, xml, log and docx come back as text paged by offset and limit characters; PDF text page by page with page and pages. Read-only.",false), + ] { + let mut p = Map::new(); + p.insert("input".into(),json!({"type":"string","minLength":1,"description":"Local XER or OpenXER workspace path; read-only"})); + if name != "inspect" { p.insert("project_id".into(),json!({"type":"integer","description":"Project id (the XER proj_id) returned by inspect"})); } + if !["inspect","import"].contains(&name) { p.insert("workspace_id".into(),json!({"type":"integer","description":"Workspace row id, useful when project ids repeat"})); } + if write { p.insert("output".into(),json!({"type":"string","minLength":1,"description":"New destination path; existing files are refused"})); } + if name == "load" { + for field in ["offset","relationship_offset"] { p.insert(field.into(),json!({"type":"integer","minimum":0,"default":0})); } + for field in ["limit","relationship_limit"] { p.insert(field.into(),json!({"type":"integer","minimum":0,"maximum":2000,"default":200,"description":"0 returns counts only"})); } + p.insert("fields".into(),json!({"type":"array","items":{"type":"string","enum":crate::load::FIELDS},"description":"Only these activity fields (task_code is always kept)"})); + p.insert("activities".into(),json!({"type":"array","items":{"type":"string","minLength":1},"description":"Only these Activity IDs"})); + p.insert("wbs".into(),json!({"type":"string","minLength":1,"description":"Only activities under this WBS code path (1.2.3)"})); + p.insert("critical".into(),json!({"type":"boolean","default":false,"description":"Only critical activities (the project's definition)"})); + p.insert("sort".into(),json!({"type":"string","minLength":1,"description":"Order activities by a field, - first for descending (-early_finish: latest first)"})); + } + if name == "schedule" { p.insert("options".into(),options_schema()); } + if name == "check_schedule" { + let names: Vec<&str> = openxer_xer::schedule_check::CHECKS.iter().map(|c| c.name()).collect(); + p.insert("check".into(),json!({"type":"string","enum":names,"description":"Also list this row's Activity IDs or relationships"})); + p.insert("limit".into(),json!({"type":"integer","minimum":1,"maximum":crate::checks::MAX_ITEMS,"default":crate::checks::DEFAULT_ITEMS,"description":"Most items listed"})); + p.insert("long_lag_hours".into(),json!({"type":"number","minimum":0,"description":"Long lag limit in hours (default 352)"})); + p.insert("large_float_hours".into(),json!({"type":"number","minimum":0,"description":"Large float limit in hours (default 352)"})); + p.insert("large_duration_hours".into(),json!({"type":"number","minimum":0,"description":"Large duration limit in hours (default 352)"})); + } + if name == "import" { + p.insert("workspace".into(),json!({"type":"string","minLength":1,"description":"Existing OpenXER workspace to import into; it is copied to output and not modified"})); + p.insert("action".into(),json!({"type":"string","enum":["new","update","replace","add"],"description":"Import action for the XER project when workspace is given (add: Add Into Existing Project)"})); + p.insert("target_workspace_id".into(),json!({"type":"integer","description":"Workspace row to update or replace"})); + p.insert("config".into(),json!({"type":"string","description":"Per-type actions, e.g. activities=update+delete,calendars=keep"})); + p.insert("dictionary".into(),json!({"type":"string","description":"A workspace with a shared dictionary: what a calendar, resource, code or other dictionary row whose name the workspace has with other values does, per kind, e.g. calendar=keep,resource=update (default copy: added as _)"})); + p.insert("format".into(),json!({"type":"string","enum":["xer","xml"],"description":"Refuse the input unless it is in this format; without it the format is told from the contents"})); + } + if name == "export" { + p.insert("version".into(),json!({"type":"string","minLength":1,"description":"XER header version label, e.g. 19.12"})); + p.insert("projects".into(),json!({"type":"string","minLength":1,"description":"Comma separated project ids (workspace ids for a workspace input) to export together"})); + p.insert("format".into(),json!({"type":"string","enum":["xer","xml"],"description":"File format; without it an output ending in .xml is project XML and any other is XER"})); + } + if name == "export_xlsx" { + p.insert("layout".into(),json!({"type":"string","enum":["modern","tables"],"default":"modern"})); + p.insert("unit".into(),json!({"type":"string","enum":["days","hours"],"default":"days"})); + p.insert("columns".into(),json!({"type":"string","description":"Comma separated column keys or titles for the modern layout"})); + p.insert("template".into(),json!({"type":"string","description":"Saved export template name (from the workspace input) or the path of a template .json file; sets columns, filter, sort and options"})); + } + if name == "export_pdf" { + p.insert("layout".into(),json!({"type":"string","minLength":1,"description":"Saved layout name; the workspace's current layout when omitted"})); + p.insert("view".into(),json!({"type":"string","enum":["gantt","network"]})); + p.insert("paper".into(),json!({"type":"string","description":"Letter, Legal, Tabloid, Executive, A5, A4, A3, B4 (JIS), ANSI C, ANSI D or ANSI E"})); + p.insert("orientation".into(),json!({"type":"string","enum":["portrait","landscape","automatic"]})); + } + if name == "export_scurve" { + p.insert("measure".into(),json!({"type":"string","enum":["auto","labor","cost","duration"],"default":"auto","description":"auto: labor hours, else cost, else duration, by what the project holds"})); + p.insert("period".into(),json!({"type":"string","enum":["day","week","month","financial"],"default":"week","description":"financial: the project's financial periods"})); + p.insert("breakdown".into(),json!({"type":"string","enum":["total","resource","wbs1","wbs2"],"description":"Rows of the breakdown sheets; resource by default when the measure has resources, else total"})); + p.insert("late".into(),json!({"type":"boolean","default":false,"description":"Add the late dates curve (actual plus remaining on the late dates)"})); + p.insert("week_start".into(),json!({"type":"string","enum":["sunday","monday"],"default":"sunday"})); + } + if name == "export_earned_hours" { + p.insert("breakdown".into(),json!({"type":"string","enum":["resource","wbs","activity"],"default":"resource","description":"Rows of the Earned to date sheet"})); + } + if name == "import_xlsx" { + p.insert("spreadsheet".into(),json!({"type":"string","minLength":1,"description":"The .xlsx to import; read-only"})); + p.insert("dry_run".into(),json!({"type":"boolean","default":false,"description":"Only return the preview"})); + } + if name == "usage" { + p.insert("activity".into(),json!({"type":"string","minLength":1,"description":"Only this Activity ID's assignments"})); + p.insert("resource".into(),json!({"type":"string","minLength":1,"description":"Only this resource's assignments (short name)"})); + p.insert("interval".into(),json!({"type":"string","enum":["day","week","month"],"default":"week","description":"Period length; weeks start on Monday"})); + p.insert("from".into(),json!({"type":"string","description":"Project-local YYYY-MM-DD or YYYY-MM-DD HH:MM; by default the first assignment window"})); + p.insert("to".into(),json!({"type":"string","description":"Project-local date; by default the last assignment window"})); + p.insert("costs".into(),json!({"type":"boolean","default":false,"description":"Costs instead of units"})); + } + if name == "records" { + p.insert("kind".into(),json!({"type":"string","enum":["expenses","issues","risks","thresholds"]})); + p.insert("activity".into(),json!({"type":"string","minLength":1,"description":"Only the records of this Activity ID"})); + } + if name == "earned_value" { + p.insert("basis".into(),json!({"type":"string","enum":["cost","labor_units"],"default":"cost"})); + p.insert("activity".into(),json!({"type":"string","minLength":1,"description":"Only this Activity ID's row (the project totals stay whole)"})); + } + if name == "documents" { + p.insert("activity".into(),json!({"type":"string","minLength":1,"description":"Only documents linked to this Activity ID"})); + p.insert("wbs".into(),json!({"type":"string","minLength":1,"description":"Only documents linked to this WBS element (code path 1.2.3) itself"})); + } + if name == "read_document" { + p.insert("document".into(),json!({"type":"string","minLength":1,"description":"The document's reference number, title or document id (from openxer_documents)"})); + p.insert("location".into(),json!({"type":"string","enum":["private","public"],"description":"Which file location to read; by default private when it is set, else public"})); + p.insert("offset".into(),json!({"type":"integer","minimum":0,"default":0,"description":"First character (text and docx)"})); + p.insert("limit".into(),json!({"type":"integer","minimum":1,"maximum":200000,"default":20000,"description":"Most characters returned"})); + p.insert("page".into(),json!({"type":"integer","minimum":1,"default":1,"description":"First PDF page"})); + p.insert("pages".into(),json!({"type":"integer","minimum":1,"maximum":100,"default":10,"description":"Most PDF pages returned"})); + } + if name == "relationship" { + p.insert("edit".into(),object(json!({ + "action":{"type":"string","enum":["add","update","remove"]}, + "predecessor":{"type":"string","description":"Exact activity code"},"successor":{"type":"string","description":"Exact activity code"}, + "relationship_type":{"type":"string","enum":["FS","SS","FF","SF"]}, + "lag_minutes":{"type":"integer","minimum":-6000000,"maximum":6000000}, + "new_type":{"type":"string","enum":["FS","SS","FF","SF"]} + }),&["action","predecessor","successor","relationship_type"])); + } + let required = if name == "relationship" { vec!["input","output","edit"] } else if name == "import_xlsx" { vec!["input","spreadsheet"] } else if name == "read_document" { vec!["input","document"] } else if name == "records" { vec!["input","kind"] } else if write { vec!["input","output"] } else { vec!["input"] }; + tools.push(json!({"name":format!("openxer_{name}"),"description":description,"inputSchema":object(Value::Object(p),&required), + "outputSchema":{"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}, + "annotations":{"readOnlyHint":!write,"destructiveHint":false,"idempotentHint":!write,"openWorldHint":false}})); + } + tools.extend(edit_tool_definitions()); + tools.extend(eps_tool_definitions()); + tools.extend(crate::workspace_cmd::tool_definitions()); + tools.extend(crate::baseline_cmd::tool_definitions()); + tools.extend(analysis_tool_definitions()); + tools.extend(skill_tool_definitions()); + tools +} + +/// What the server offers: tools, and one prompt per skill. +fn capabilities() -> Value { + json!({"tools":{},"prompts":{"listChanged":false}}) +} + +/// The prompts: one per skill, named by its id. +fn prompt_list() -> Vec { + crate::skills::catalog() + .entries + .iter() + .map(|e| { + json!({"name": e.skill.id, "title": e.skill.name, + "description": format!("{} ({})", e.skill.description, e.skill.kind.label())}) + }) + .collect() +} + +const OUTPUT: &str = r#"{"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}"#; + +fn read_only() -> Value { + json!({"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}) +} + +/// The read-only analysis tools: the numbers the skills report. +fn analysis_tool_definitions() -> Vec { + let output: Value = serde_json::from_str(OUTPUT).expect("output schema"); + let mut tools = vec![]; + let common = |p: &mut Map| { + p.insert("input".into(),json!({"type":"string","minLength":1,"description":"Local XER or OpenXER workspace path; read-only"})); + p.insert("project_id".into(),json!({"type":"integer","description":"Project id (the XER proj_id) returned by inspect"})); + p.insert("workspace_id".into(),json!({"type":"integer","description":"Workspace row id, useful when project ids repeat"})); + }; + let defs: [(&str, &str, Value); 7] = [ + ("openxer_paths", + "The chains of work into one activity (or the project finish when activity is omitted), ranked by float: path 1 drives it, path 2 is the next closest, with each path's lowest float, how far behind path 1 it is, what holds its first activity, its activities in order, merge points, and the counts of open work on the longest path and at zero or negative float. From the stored dates and float. Read-only.", + json!({"activity":{"type":"string","minLength":1,"description":"Activity ID of the milestone or activity; the project finish when omitted"}, + "count":{"type":"integer","minimum":1,"maximum":10,"default":5,"description":"Number of paths"}})), + ("openxer_compare", + "Compare the project with a reference: an earlier XER or workspace (reference) or a stored baseline of a workspace project (baseline project or primary). Gives the project finish then and now, milestones moved, the biggest finish moves, activities added and deleted, ties added, removed and changed (type or lag), original durations changed, remaining duration up on work in progress, constraints and calendars changed, renamed, and progress (started, finished, actual dates rewritten, status gone back). Moves are calendar days. Read-only.", + json!({"reference":{"type":"string","minLength":1,"description":"An earlier XER or workspace to compare with; read-only"}, + "reference_project_id":{"type":"integer","description":"Project id in the reference"}, + "reference_workspace_id":{"type":"integer","description":"Workspace row id in the reference"}, + "baseline":{"type":"string","enum":["project","primary"],"description":"A stored baseline of the workspace project instead of reference"}})), + ("openxer_lookahead", + "The work in progress or due in the next weeks from the data date (or from), by WBS: each activity with dates, float, resources, and whether it is in progress, ready (nothing before it is open) or waiting, with the open predecessors it waits on and their expected finish. Read-only.", + json!({"weeks":{"type":"integer","minimum":1,"maximum":26,"default":3}, + "from":{"type":"string","description":"Project-local YYYY-MM-DD; the data date when omitted"}})), + ("openxer_milestones", + "Every milestone in date order: date, status, total float, constraints, the baseline date and the move since it (workspace project baseline), and the driving ties into it. Read-only.", + json!({})), + ("openxer_schedule_stats", + "Counts and spreads for reviewing activities, durations, calendars and the WBS: activities by type and status, every calendar with its weekly hours, working days, nonwork exception dates and the activities on it, original durations in working days (median, 90th percentile, spread, the longest, zero-duration tasks, those longer than two update periods), repeated and one-word names, open work with no resource or expense, activities by WBS level and empty WBS elements. Read-only.", + json!({"update_period_days":{"type":"number","description":"The update cycle in working days, to list activities longer than two periods"}})), + ("openxer_resource_loading", + "Each assigned resource's units per period (actual plus remaining, spread as the usage views spread them), its peak period, its limit in units per hour and the periods over the limit. Read-only; to see what leveling would move, schedule a copy with level_resources.", + json!({"interval":{"type":"string","enum":["day","week","month"],"default":"week"}})), + ("openxer_wbs_summary", + "The schedule rolled up by WBS element down to level: activities, completed, start, finish, lowest total float, baseline finish and the move since it, and the milestones in each element. For a summary schedule and for checking that levels of detail agree. Read-only.", + json!({"level":{"type":"integer","minimum":1,"maximum":10,"default":2}})), + ]; + for (name, description, extra) in defs { + let mut p = Map::new(); + common(&mut p); + if let Some(extra) = extra.as_object() { + p.extend(extra.clone()); + } + tools.push(json!({"name":name,"description":description,"inputSchema":object(Value::Object(p),&["input"]),"outputSchema":output.clone(),"annotations":read_only()})); + } + tools +} + +/// The skill tools: list and get. +fn skill_tool_definitions() -> Vec { + let output: Value = serde_json::from_str(OUTPUT).expect("output schema"); + vec![ + json!({"name":"openxer_skills", + "description":"List the skills: instructions for analyzing (kind check, read-only) and building or changing (kind workflow) schedules with these tools. Each has id, name, description, use_when, request, kind and source (built_in, yours or customized). Call this before analyzing or building a schedule and follow the skill that matches.", + "inputSchema":object(json!({}),&[]),"outputSchema":output,"annotations":read_only()}), + json!({"name":"openxer_skill", + "description":"Get one skill's instructions by id (from openxer_skills) and follow them. Every number you report comes from a tool result; never compute schedule metrics yourself.", + "inputSchema":object(json!({"id":{"type":"string","minLength":1}}),&["id"]),"outputSchema":output,"annotations":read_only()}), + ] +} + +/// `openxer_eps_edit` takes the operation's fields at the top; they go +/// into the `operation` of an `eps` command. +fn eps_arguments(args: Map) -> Map { + let mut top = Map::new(); + let mut operation = Map::new(); + for (k, v) in args { + if matches!(k.as_str(), "input" | "output" | "dry_run") { + top.insert(k, v); + } else { + operation.insert(k, v); + } + } + top.insert("operation".into(), Value::Object(operation)); + top +} + +fn eps_tool_definitions() -> Vec { + let output = json!({"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}); + let input = json!({"type":"string","minLength":1,"description":"OpenXER workspace database path; read-only"}); + let text = json!({"type":"string","minLength":1}); + let list = json!({"name":"openxer_eps_list", + "description":"List the EPS (project folder tree) of an OpenXER workspace with every project and folder rollup: start, finish, late dates, data date (folders: latest), Must Finish By, baseline finish and finish variance (working hours), total float (lowest unfinished activity; folders: lowest project), duration-based schedule percent complete, labor units and costs (budgeted/actual/remaining) and activity counts. Read from stored projects, so closed projects are current. Use it to answer how all the jobs are doing.", + "inputSchema":object(json!({"input":input}),&["input"]),"outputSchema":output, + "annotations":{"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}}); + let edit = json!({"name":"openxer_eps_edit", + "description":"Edit the EPS of an OpenXER workspace on a copy written to output (or dry_run): add_folder (name, eps_id, parent), rename_folder (folder, name, new_eps_id), move_folder (folder, parent; omitted parent is the top level), delete_folder (folder, delete_projects; deletes the folder, the folders under it and every project filed in them with their baselines; a folder holding projects is refused unless delete_projects is true, dry_run lists what would go; the last top-level folder is refused), file_project (workspace_id, folder), create_project (folder, project_id, planned_start, name, must_finish, manager, rate_type; the New Project wizard's rules). Folders are named by EPS ID from openxer_eps_list; dates are YYYY-MM-DD or YYYY-MM-DD HH:MM.", + "inputSchema":object(json!({ + "input":input, + "output":{"type":"string","minLength":1,"description":"New workspace path; existing files are refused. Omit with dry_run"}, + "dry_run":{"type":"boolean","default":false}, + "op":{"type":"string","enum":["add_folder","rename_folder","move_folder","delete_folder","file_project","create_project"]}, + "folder":text,"parent":text,"name":text,"eps_id":text,"new_eps_id":text, + "workspace_id":{"type":"integer"},"project_id":text,"planned_start":text,"must_finish":text, + "delete_projects":{"type":"boolean","default":false,"description":"delete_folder: also delete the projects filed in the folder and its subfolders, with their baselines"}, + "manager":text,"rate_type":{"type":"string","description":"COST_PER_QTY .. COST_PER_QTY5 or a rate type name"} + }),&["input","op"]),"outputSchema":output, + "annotations":{"readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false}}); + vec![list, edit] +} diff --git a/automation/src/pdf.rs b/automation/src/pdf.rs new file mode 100644 index 0000000..cbec2eb --- /dev/null +++ b/automation/src/pdf.rs @@ -0,0 +1,186 @@ +//! `export_pdf`: prints a project's layout to a new PDF. Printing paints the +//! desktop's own table, Gantt and network, so this command runs the desktop +//! binary's headless `export-pdf` mode (no window opens) and returns its +//! summary. The binary is `OPENXER_DESKTOP` when set, otherwise `OpenXER` +//! next to this executable. +use crate::storage; +use crate::{AutomationError, Result}; +use serde_json::Value; +use std::path::{Path, PathBuf}; + +fn args(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +/// The desktop executable that renders the pages. +pub fn desktop_binary() -> Option { + if let Some(path) = std::env::var_os("OPENXER_DESKTOP") { + return Some(PathBuf::from(path)); + } + let name = if cfg!(windows) { + "OpenXER.exe" + } else { + "OpenXER" + }; + let exe = std::env::current_exe().ok()?; + let dir = exe.parent()?; + // Test runners sit one folder down, in `deps`. + [dir.join(name), dir.parent()?.join(name)] + .into_iter() + .find(|p| p.is_file()) +} + +#[allow(clippy::too_many_arguments)] +pub(crate) fn export_pdf( + input: &Path, + output: &Path, + project_id: Option, + workspace_id: Option, + layout: Option<&str>, + view: Option<&str>, + paper: Option<&str>, + orientation: Option<&str>, +) -> Result { + let is_pdf = output + .extension() + .and_then(|e| e.to_str()) + .is_some_and(|e| e.eq_ignore_ascii_case("pdf")); + if !is_pdf { + return Err(args("Output must end in .pdf")); + } + if std::fs::symlink_metadata(output).is_ok() { + return Err(AutomationError::new( + "output_exists", + format!("Destination already exists: {}", output.display()), + )); + } + let parent = output + .parent() + .filter(|p| !p.as_os_str().is_empty()) + .unwrap_or(Path::new(".")); + if !parent.is_dir() { + return Err(storage::io("Output parent directory does not exist")); + } + let mut command = vec![ + "export-pdf".to_string(), + "--output".into(), + output.display().to_string(), + ]; + if storage::is_database(input)? { + // Resolve the workspace row the same way every other command does. + let loaded = storage::load(input, project_id, workspace_id)?; + command.extend(["--database".into(), input.display().to_string()]); + if let Some(id) = loaded.workspace_id { + command.extend(["--workspace-id".into(), id.to_string()]); + } + } else { + if workspace_id.is_some() { + return Err(args("workspace_id needs an OpenXER workspace input")); + } + command.extend(["--input".into(), input.display().to_string()]); + if let Some(id) = project_id { + command.extend(["--project".into(), id.to_string()]); + } + } + for (flag, value) in [ + ("--layout", layout), + ("--view", view), + ("--paper", paper), + ("--orientation", orientation), + ] { + if let Some(v) = value { + command.extend([flag.to_string(), v.to_string()]); + } + } + let binary = desktop_binary().ok_or_else(|| { + AutomationError::new( + "desktop_missing", + "The OpenXER desktop executable renders PDFs; place it next to openxer-cli or set OPENXER_DESKTOP", + ) + })?; + let out = run_with_timeout(&binary, &command, EXPORT_TIMEOUT)?; + if !out.status.success() { + let message = String::from_utf8_lossy(&out.stderr).trim().to_string(); + return Err(AutomationError::new("export_failed", message)); + } + let text = String::from_utf8_lossy(&out.stdout); + serde_json::from_str(text.trim()).map_err(|e| { + AutomationError::new( + "export_failed", + format!("Unreadable summary from the desktop ({e}): {text}"), + ) + }) +} + +/// The desktop renderer is a separate process; a stale or wrong executable +/// (for example one that opens its window instead of printing) must not hang +/// the caller, so the child is killed after this long. +const EXPORT_TIMEOUT: std::time::Duration = std::time::Duration::from_secs(300); + +fn run_with_timeout( + binary: &Path, + args: &[String], + limit: std::time::Duration, +) -> Result { + use std::io::Read; + use std::process::Stdio; + let mut child = std::process::Command::new(binary) + .args(args) + .stdin(Stdio::null()) + .stdout(Stdio::piped()) + .stderr(Stdio::piped()) + .spawn() + .map_err(|e| { + AutomationError::new( + "desktop_missing", + format!("Cannot run {}: {e}", binary.display()), + ) + })?; + // Drain the pipes on threads so a chatty child cannot block on a full pipe. + let mut stdout = child.stdout.take(); + let mut stderr = child.stderr.take(); + let out_thread = std::thread::spawn(move || { + let mut buf = Vec::new(); + if let Some(s) = stdout.as_mut() { + let _ = s.read_to_end(&mut buf); + } + buf + }); + let err_thread = std::thread::spawn(move || { + let mut buf = Vec::new(); + if let Some(s) = stderr.as_mut() { + let _ = s.read_to_end(&mut buf); + } + buf + }); + let started = std::time::Instant::now(); + let status = loop { + match child.try_wait() { + Ok(Some(status)) => break status, + Ok(None) if started.elapsed() >= limit => { + let _ = child.kill(); + let _ = child.wait(); + return Err(AutomationError::new( + "export_timeout", + format!( + "{} did not finish the PDF export within {} s; is it an up-to-date OpenXER desktop build?", + binary.display(), + limit.as_secs() + ), + )); + } + Ok(None) => std::thread::sleep(std::time::Duration::from_millis(50)), + Err(e) => { + return Err(AutomationError::new( + "export_failed", + format!("Cannot wait for {}: {e}", binary.display()), + )) + } + } + }; + Ok(std::process::Output { + status, + stdout: out_thread.join().unwrap_or_default(), + stderr: err_thread.join().unwrap_or_default(), + }) +} diff --git a/automation/src/playbooks.rs b/automation/src/playbooks.rs new file mode 100644 index 0000000..7294e12 --- /dev/null +++ b/automation/src/playbooks.rs @@ -0,0 +1,264 @@ +//! `playbook`: step-by-step scheduling methods an agent loads when it +//! needs one, instead of carrying them in every prompt. Built-in texts are +//! assets compiled into the binary (`assets/playbooks/`); user-authored +//! Markdown files in `chat/playbooks/` are discovered beside them. +use crate::{AutomationError, Result}; +use serde_json::{json, Value}; +use std::path::{Path, PathBuf}; + +/// Most characters read from one user-authored playbook file. +pub const USER_PLAYBOOK_LIMIT: usize = 6_000; + +/// Each built-in playbook: name, what it is for, text. +pub const PLAYBOOKS: &[(&str, &str, &str)] = &[ + ( + "build", + "Build a new schedule: WBS, activities, durations, logic, calendars, resources, quality check", + include_str!("../../assets/playbooks/build.md"), + ), + ( + "update", + "Update progress to a new data date, reschedule and explain what moved", + include_str!("../../assets/playbooks/update.md"), + ), + ( + "audit", + "Audit logic and health: open ends, constraints, lags, durations, float, relationship mix, out of sequence", + include_str!("../../assets/playbooks/audit.md"), + ), + ( + "critical-path", + "Read the driving path, near-critical paths and what consumes float", + include_str!("../../assets/playbooks/critical-path.md"), + ), + ( + "delay-recovery", + "Find what drives a delay and list options to pull time back", + include_str!("../../assets/playbooks/delay-recovery.md"), + ), + ( + "schedule-check", + "Run Check Schedule and explain each result and what to look at next", + include_str!("../../assets/playbooks/schedule-check.md"), + ), + ( + "lookahead", + "Build a 2, 3 or 6 week field lookahead grouped by WBS with readiness flags", + include_str!("../../assets/playbooks/lookahead.md"), + ), + ( + "narrative", + "Draft a copy-ready executive weekly or monthly schedule narrative", + include_str!("../../assets/playbooks/narrative.md"), + ), + ( + "earned-value", + "Analyze SPI, CPI, EAC and VAC and isolate the activities driving variance", + include_str!("../../assets/playbooks/earned-value.md"), + ), + ( + "resource-review", + "Inspect time-phased resource peaks, crew bottlenecks and leveling options", + include_str!("../../assets/playbooks/resource-review.md"), + ), + ( + "what-if", + "Test a single change in Edit mode and measure its finish date and float impact", + include_str!("../../assets/playbooks/what-if.md"), + ), +]; + +/// One playbook entry (built-in or discovered from the user's folder). +#[derive(Clone, Debug, PartialEq, Eq)] +pub struct PlaybookEntry { + pub name: String, + pub about: String, + pub text: String, + pub custom: bool, + pub path: Option, +} + +/// The user's custom playbooks folder inside `data_folder`: `chat\playbooks`. +pub fn playbooks_dir(data_folder: &Path) -> PathBuf { + data_folder.join("chat").join("playbooks") +} + +/// Starter README dropped once when the user opens the custom playbooks folder +/// for the first time (only HTML comments, ignored by playbook discovery). +pub const CUSTOM_PLAYBOOK_SAMPLE: &str = " +"; + +/// Ensure `dir` exists and contains a starter example comment file if empty. +pub fn ensure_playbooks_dir(dir: &Path) -> std::io::Result { + std::fs::create_dir_all(dir)?; + let sample = dir.join("README-custom-playbooks.txt"); + if !sample.exists() { + let _ = std::fs::write(&sample, CUSTOM_PLAYBOOK_SAMPLE); + } + Ok(dir.to_path_buf()) +} + +fn normalize_name(stem: &str) -> Option { + let mut out = String::new(); + let mut last_dash = false; + for ch in stem.trim().chars() { + if ch.is_ascii_alphanumeric() { + out.push(ch.to_ascii_lowercase()); + last_dash = false; + } else if matches!(ch, '-' | '_' | ' ') && !out.is_empty() && !last_dash { + out.push('-'); + last_dash = true; + } + } + while out.ends_with('-') { + out.pop(); + } + (!out.is_empty()).then_some(out) +} + +fn extract_about(text: &str, fallback_name: &str) -> String { + for line in text.lines() { + let trimmed = line.trim(); + if trimmed.is_empty() { + continue; + } + let clean = trimmed + .trim_start_matches('#') + .trim() + .trim_start_matches("Goal:") + .trim(); + if !clean.is_empty() { + let mut s: String = clean.chars().take(110).collect(); + if clean.chars().count() > 110 { + s.push_str("..."); + } + return s; + } + } + format!("Custom playbook: {fallback_name}") +} + +/// Discover user-authored `.md` playbooks in `dir` (sorted by name). +/// Empty or comment-only files are skipped. +pub fn discover_user_playbooks(dir: &Path) -> Vec { + let Ok(entries) = std::fs::read_dir(dir) else { + return vec![]; + }; + let mut found = vec![]; + for entry in entries.flatten() { + let path = entry.path(); + if !path.is_file() { + continue; + } + let is_md = path + .extension() + .and_then(|e| e.to_str()) + .is_some_and(|e| e.eq_ignore_ascii_case("md")); + if !is_md { + continue; + } + let Some(stem) = path.file_stem().and_then(|s| s.to_str()) else { + continue; + }; + let Some(name) = normalize_name(stem) else { + continue; + }; + let Ok(bytes) = std::fs::read(&path) else { + continue; + }; + let cleaned = crate::chat_prompt::clean_markdown(&bytes); + let text = cleaned.trim(); + if text.is_empty() { + continue; + } + let text: String = text.chars().take(USER_PLAYBOOK_LIMIT).collect(); + let about = extract_about(&text, &name); + found.push(PlaybookEntry { + name, + about, + text, + custom: true, + path: Some(path), + }); + } + found.sort_by(|a, b| a.name.cmp(&b.name)); + found +} + +/// Built-in playbooks combined with any custom playbooks in `dir`. +/// A custom file with the same name as a built-in overrides it. +pub fn all_playbooks(dir: Option<&Path>) -> Vec { + let mut list: Vec = PLAYBOOKS + .iter() + .map(|(n, about, text)| PlaybookEntry { + name: (*n).to_string(), + about: (*about).to_string(), + text: text.replace("\r\n", "\n"), + custom: false, + path: None, + }) + .collect(); + if let Some(dir) = dir { + for custom in discover_user_playbooks(dir) { + if let Some(slot) = list + .iter_mut() + .find(|e| e.name.eq_ignore_ascii_case(&custom.name)) + { + *slot = custom; + } else { + list.push(custom); + } + } + } + list +} + +/// Without `name` the list of built-in playbooks; with it, that playbook's text. +pub fn playbook(name: Option<&str>) -> Result { + playbook_in(name, None) +} + +/// Same as [`playbook`], also including custom `.md` playbooks in `dir`. +pub fn playbook_in(name: Option<&str>, dir: Option<&Path>) -> Result { + let list = all_playbooks(dir); + match name { + None => Ok(json!({ + "playbooks": list + .iter() + .map(|p| { + if p.custom { + json!({"name": p.name, "about": p.about, "custom": true}) + } else { + json!({"name": p.name, "about": p.about}) + } + }) + .collect::>() + })), + Some(name) => list + .into_iter() + .find(|p| p.name.eq_ignore_ascii_case(name.trim())) + .map(|p| json!({"name": p.name, "text": p.text})) + .ok_or_else(|| { + AutomationError::new( + "not_found", + format!( + "No playbook named {name:?}; playbooks are {}", + all_playbooks(dir) + .iter() + .map(|p| p.name.as_str()) + .collect::>() + .join(", ") + ), + ) + }), + } +} diff --git a/automation/src/registers.rs b/automation/src/registers.rs new file mode 100644 index 0000000..e711548 --- /dev/null +++ b/automation/src/registers.rs @@ -0,0 +1,147 @@ +//! Read commands over the project registers and earned value: `records` +//! lists expense items, issues, risks or thresholds with their fields as the +//! edits name them; `earned_value` returns each activity's earned value +//! figures as the activity table's earned value columns compute them, with +//! the project totals. +use crate::{baselines, edit, storage, AutomationError, Result}; +use openxer_xer::edit::project_records::{self, Kind}; +use openxer_xer::ev::{Basis, Parts}; +use serde_json::{json, Value}; +use std::path::Path; + +fn invalid(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +/// The fields a kind of record takes, for the result. +fn field_names(kind: Kind) -> Vec { + project_records::fields(kind) + .iter() + .map(|f| { + json!({"field":f.name,"column":f.column, + "editable":f.kind != project_records::FieldKind::ReadOnly}) + }) + .collect() +} + +pub(crate) fn records( + input: &Path, + project_id: Option, + workspace_id: Option, + kind: &str, + activity: Option<&str>, +) -> Result { + let kind = Kind::parse(kind).map_err(invalid)?; + let loaded = storage::load(input, project_id, workspace_id)?; + let p = &loaded.project; + let task = match activity { + Some(code) => { + let found: Vec = p + .model + .activities + .iter() + .filter(|a| a.task_code == code) + .map(|a| a.task_id) + .collect(); + match found.as_slice() { + [id] => Some(*id), + [] => return Err(invalid(format!("No activity {code:?}."))), + _ => return Err(invalid(format!("Activity ID {code:?} is not unique."))), + } + } + None => None, + }; + let pid = p.model.project.proj_id; + let list: Vec = project_records::ids(p, kind) + .into_iter() + .filter(|&id| { + task.is_none_or(|t| match kind { + Kind::Risk => project_records::risk_activities(&p.document, pid, id).contains(&t), + _ => { + let table = kind.table(&p.document); + openxer_xer::edit::records::num(&project_records::value( + &p.document, + table, + kind.key(), + id, + "task_id", + )) == t + } + }) + }) + .map(|id| edit::register_json(p, kind, id)) + .collect(); + let mut out = json!({"kind":kind.name(),"count":list.len(),"records":list, + "fields":field_names(kind),"workspace_id":loaded.workspace_id}); + if kind == Kind::Threshold { + let parms: Vec = openxer_xer::edit::thresholds::parameters(&p.document) + .into_iter() + .map(|q| json!({"id":q.id,"name":q.name,"field":q.field,"wbs":q.wbs,"activities":q.task})) + .collect(); + out["parameters"] = Value::Array(parms); + } + Ok(out) +} + +fn round(v: f64) -> f64 { + (v * 100.).round() / 100. +} + +fn parts_json(x: &Parts) -> Value { + let eac = x.ac + x.etc; + let index = |v: Option| v.map(round); + json!({"budget_at_completion":round(x.bac),"planned_value":round(x.pv),"earned_value":round(x.ev), + "actual_cost":round(x.ac),"schedule_variance":round(x.ev - x.pv),"cost_variance":round(x.ev - x.ac), + "schedule_performance_index":index(x.spi()),"cost_performance_index":index(x.cpi()), + "estimate_to_complete":round(x.etc),"estimate_at_completion":round(eac), + "variance_at_completion":round(x.bac - eac)}) +} + +pub(crate) fn earned_value( + input: &Path, + project_id: Option, + workspace_id: Option, + basis: Option<&str>, + activity: Option<&str>, +) -> Result { + let basis = match basis.unwrap_or("cost") { + "cost" => Basis::Cost, + "labor_units" | "units" => Basis::LaborUnits, + other => { + return Err(invalid(format!( + "basis is cost or labor_units, not {other:?}" + ))) + } + }; + let loaded = storage::load(input, project_id, workspace_id)?; + let p = &loaded.project; + let ctx = baselines::context(input, loaded.workspace_id, p)?; + let calc = ctx.calculator(p); + let mut total = Parts::default(); + let mut rows = vec![]; + for (i, a) in p.model.activities.iter().enumerate() { + let parts = calc.parts(i, basis); + total.add(parts); + if activity.is_some_and(|c| c != a.task_code) { + continue; + } + let mut v = parts_json(&parts); + v["activity"] = json!(a.task_code); + v["performance_percent_complete"] = json!(round(calc.performance_percent(a))); + v["schedule_percent_complete"] = json!(calc + .ev_baseline(a) + .and_then(|b| openxer_xer::ev::schedule_percent(p, a, &b)) + .map(round)); + rows.push(v); + } + if let Some(code) = activity { + if rows.is_empty() { + return Err(invalid(format!("No activity {code:?}."))); + } + } + Ok( + json!({"basis":match basis { Basis::Cost => "cost", Basis::LaborUnits => "labor_units" }, + "baselines":ctx.describe(),"project":parts_json(&total),"activities":rows, + "workspace_id":loaded.workspace_id}), + ) +} diff --git a/automation/src/reports.rs b/automation/src/reports.rs new file mode 100644 index 0000000..4701c79 --- /dev/null +++ b/automation/src/reports.rs @@ -0,0 +1,198 @@ +//! `export-scurve` and `export-earned-hours`: the S-curve and cumulative +//! earned hours workbooks of Tools > Reports, from the same figures +//! (`openxer_xer::scurve`) and writers (`openxer_interchange::scurve_xlsx`) +//! the app uses. The project's assigned baselines come from the workspace +//! as earned value reads them; an XER input is its own baseline. +use crate::storage::{self, io, parent, publish}; +use crate::{baselines, project_json, AutomationError, Result}; +use openxer_interchange::scurve_xlsx::{self, Style}; +use openxer_xer::scurve::{self, Breakdown, Detection, Group, Measure, Options, Period, Source}; +use serde_json::{json, Value}; +use std::io::Write; +use std::path::Path; + +fn args(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +/// What the S-curve export is asked for. +pub struct CurveRequest<'a> { + pub measure: Option<&'a str>, + pub period: Option<&'a str>, + pub breakdown: Option<&'a str>, + pub late: bool, + pub week_start: Option<&'a str>, +} + +fn write(output: &Path, bytes: &[u8]) -> Result<()> { + let mut temp = tempfile::Builder::new() + .suffix(".xlsx") + .tempfile_in(parent(output)) + .map_err(io)?; + temp.write_all(bytes).map_err(io)?; + publish(temp, output) +} + +fn style(p: &openxer_xer::ProjectData) -> Style { + Style { + currency_format: scurve_xlsx::currency_format(&p.document), + ..Style::default() + } +} + +/// The options asked for, filled in from what the project holds: the +/// detected measure, weekly periods from Sunday and the detected breakdown. +pub fn curve_options(d: &Detection, r: &CurveRequest) -> Result { + let measure = match r.measure.filter(|m| *m != "auto") { + None => d.measure(), + Some(text) => { + let m = Measure::from_key(text) + .ok_or_else(|| args("measure takes auto, labor, cost or duration"))?; + if !d.measures().contains(&m) { + return Err(args(format!( + "The project has no {} to measure ({})", + match m { + Measure::Labor => "labor hours", + Measure::Cost => "costs", + Measure::Duration => "durations", + }, + d.line(d.measure()) + ))); + } + m + } + }; + let period = match r.period { + None => Period::Week, + Some(text) => Period::from_key(text) + .ok_or_else(|| args("period takes day, week, month or financial"))?, + }; + if period == Period::Financial && !d.financial { + return Err(args("The project has no financial periods")); + } + let breakdown = match r.breakdown { + None => d.breakdown(measure), + Some(text) => { + let b = Breakdown::from_key(text) + .ok_or_else(|| args("breakdown takes total, resource, wbs1 or wbs2"))?; + if !d.breakdowns(measure).contains(&b) { + return Err(args(format!( + "{} cannot be broken down by resource", + measure.label() + ))); + } + b + } + }; + let week_starts_sunday = match r.week_start.unwrap_or("sunday") { + "sunday" => true, + "monday" => false, + _ => return Err(args("week_start takes sunday or monday")), + }; + Ok(Options { + measure, + period, + breakdown, + late: r.late, + week_starts_sunday, + }) +} + +/// `export-scurve`. +pub(crate) fn export_scurve( + input: &Path, + output: &Path, + project_id: Option, + workspace_id: Option, + r: &CurveRequest, +) -> Result { + crate::interchange::check_new_output(output, &["xlsx"])?; + let loaded = storage::load(input, project_id, workspace_id)?; + let p = &loaded.project; + let ctx = baselines::context(input, loaded.workspace_id, p)?; + let src = Source { + project_baseline: ctx.project.clone(), + primary_baseline: ctx.primary.clone(), + basis: ctx.basis, + ..Source::new(p) + }; + let sources = [src]; + let detection = Detection::of(&sources); + let options = curve_options(&detection, r)?; + let mut c = scurve::curve(&sources, options).map_err(|e| AutomationError::new("no_data", e))?; + c.warnings.extend(ctx.warnings.iter().cloned()); + let bytes = scurve_xlsx::curve_bytes(&c, &[], &style(p)) + .map_err(|e| AutomationError::new("write_failed", e))?; + write(output, &bytes)?; + let sum = |v: &[f64]| (v.iter().sum::() * 100.).round() / 100.; + Ok(json!({ + "output": output, + "measure": c.options.measure.key(), + "period": c.options.period.key(), + "breakdown": c.options.breakdown.key(), + "late": c.options.late, + "week_starts": if c.options.week_starts_sunday { "sunday" } else { "monday" }, + "detected": c.detection, + "measures_available": detection.measures().iter().map(|m| m.key()).collect::>(), + "periods": c.periods.len(), + "rows": c.lines.len(), + "totals": {"budgeted": sum(&c.total.budget), "actual": sum(&c.total.actual), + "remaining": sum(&c.total.remaining)}, + "earned_to_data_date": c.earned.map(|e| (e * 100.).round() / 100.), + "budgeted_from": c.budget_source, + "warnings": c.warnings, + "project": project_json(p), + })) +} + +/// `export-earned-hours`. +pub(crate) fn export_earned_hours( + input: &Path, + output: &Path, + project_id: Option, + workspace_id: Option, + breakdown: Option<&str>, +) -> Result { + crate::interchange::check_new_output(output, &["xlsx"])?; + let group = match breakdown { + None => Group::Resource, + Some(text) => Group::from_key(text) + .ok_or_else(|| args("breakdown takes resource, wbs or activity"))?, + }; + let loaded = storage::load(input, project_id, workspace_id)?; + let p = &loaded.project; + let ctx = baselines::context(input, loaded.workspace_id, p)?; + let src = Source { + project_baseline: ctx.project.clone(), + primary_baseline: ctx.primary.clone(), + basis: ctx.basis, + ..Source::new(p) + }; + let mut e = scurve::earned_hours(&src, group).map_err(|e| { + let code = if e == scurve::NO_LABOR { + "no_labor_units" + } else { + "no_data" + }; + AutomationError::new(code, e) + })?; + e.warnings.extend(ctx.warnings.iter().cloned()); + let bytes = scurve_xlsx::earned_bytes(&e, &[], &style(p)) + .map_err(|e| AutomationError::new("write_failed", e))?; + write(output, &bytes)?; + let total = |pick: fn(&scurve::EarnedRow) -> f64| { + (e.rows.iter().map(pick).sum::() * 100.).round() / 100. + }; + Ok(json!({ + "output": output, + "breakdown": group.key(), + "rows": e.rows.len(), + "assignments": e.details.len(), + "totals": {"budgeted": total(|r| r.budgeted), "earned": total(|r| r.earned), + "actual": total(|r| r.actual), "remaining": total(|r| r.remaining)}, + "budgeted_from": e.budget_source, + "percent_complete": e.percent_rule, + "warnings": e.warnings, + "project": project_json(p), + })) +} diff --git a/automation/src/schedule_check.rs b/automation/src/schedule_check.rs new file mode 100644 index 0000000..0da8c39 --- /dev/null +++ b/automation/src/schedule_check.rs @@ -0,0 +1,3 @@ +//! Pure schedule diagnostics live in `openxer_xer::schedule_check`; this +//! module re-exports them so `analysis` and external callers share one copy. +pub use openxer_xer::schedule_check::*; diff --git a/automation/src/skills.rs b/automation/src/skills.rs new file mode 100644 index 0000000..f859d5f --- /dev/null +++ b/automation/src/skills.rs @@ -0,0 +1,732 @@ +//! Skills: instructions that teach any connected AI agent how to build and +//! analyze schedules with OpenXER's tools. +//! +//! A skill is one Markdown file: a header between two `---` lines, one +//! `key: value` per line (list keys take `- item` lines, `#` starts a +//! comment line), then the instructions. +//! +//! ```text +//! --- +//! id: logic-health-check # the file name without .md: a-z, 0-9, hyphens +//! name: Logic health check # the label in lists, at most 40 characters +//! description: One line, at most 160 characters. +//! request: Run the logic health check. # the sentence a user pastes to the agent +//! use_when: The plain words that ask for it. +//! examples: # optional: requests that should find it +//! - Check the logic +//! cites: # optional: standards by number and title +//! - GAO-16-89G Schedule Assessment Guide +//! tools: # the OpenXER tools its instructions run +//! - openxer_check_schedule +//! order: 10 # optional: place in the list, 0 to 999 +//! kind: check # check (read-only) or workflow (builds or changes) +//! --- +//! The instructions, in Markdown. +//! ``` +//! +//! Built-in skills are the files in `assets/skills/`, compiled in. The +//! user's skills are `.md` files in `\skills\` (see +//! [`crate::locate`]). A user file whose id equals a built-in's replaces it +//! (customized); deleting it brings the built-in back. A user file that does +//! not parse is left out and reported, never breaking the others. The folder +//! is read on every call, so edits show up without a restart. +//! +//! Skills are generic: no company's codes, gates or calendars. The agent +//! never computes schedule metrics itself: every count, date, float and +//! percent comes from a tool result. +use serde_json::{json, Value}; +use std::fmt; +use std::path::{Path, PathBuf}; + +/// Keys every skill must give. +pub const REQUIRED: [&str; 5] = ["id", "name", "description", "request", "use_when"]; +/// Keys whose value is a list of `- item` lines. +pub const LISTS: [&str; 3] = ["examples", "cites", "tools"]; +/// Optional single-value keys. +pub const OPTIONAL: [&str; 3] = ["order", "kind", "compare"]; +/// The only value `compare` takes (kept for files written for the earlier +/// format; it asks the agent to settle a reference before comparing). +pub const COMPARE: &str = "baseline-or-file"; +/// A skill without an order goes after those with one. +pub const ORDER_LAST: u32 = 1000; +pub const NAME_MAX: usize = 40; +pub const DESCRIPTION_MAX: usize = 160; +pub const ID_MAX: usize = 64; + +/// Check (read-only analysis) or workflow (builds or changes a schedule). +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +pub enum Kind { + #[default] + Check, + Workflow, +} + +impl Kind { + pub fn key(self) -> &'static str { + match self { + Kind::Check => "check", + Kind::Workflow => "workflow", + } + } + pub fn label(self) -> &'static str { + match self { + Kind::Check => "Check", + Kind::Workflow => "Workflow", + } + } +} + +/// Where a skill in the catalog comes from. +#[derive(Clone, Copy, Debug, PartialEq, Eq)] +pub enum Source { + /// Shipped with OpenXER. + BuiltIn, + /// A file of the user's own. + Yours, + /// The user's file that replaces a built-in of the same id. + Customized, +} + +impl Source { + pub fn key(self) -> &'static str { + match self { + Source::BuiltIn => "built_in", + Source::Yours => "yours", + Source::Customized => "customized", + } + } + pub fn label(self) -> &'static str { + match self { + Source::BuiltIn => "Built-in", + Source::Yours => "Yours", + Source::Customized => "Customized", + } + } +} + +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct Skill { + pub id: String, + pub name: String, + pub description: String, + pub request: String, + pub use_when: String, + pub instructions: String, + pub examples: Vec, + pub cites: Vec, + pub tools: Vec, + pub order: u32, + pub kind: Kind, + pub compare: Option, +} + +/// Why a skill file does not parse, with the line when one is to blame. +#[derive(Clone, Debug, PartialEq, Eq)] +pub struct SkillError { + pub line: Option, + pub message: String, +} + +impl SkillError { + fn at(line: usize, message: impl Into) -> Self { + Self { + line: Some(line), + message: message.into(), + } + } + fn whole(message: impl Into) -> Self { + Self { + line: None, + message: message.into(), + } + } +} + +impl fmt::Display for SkillError { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + match self.line { + Some(n) => write!(f, "line {n}: {}", self.message), + None => f.write_str(&self.message), + } + } +} + +impl std::error::Error for SkillError {} + +fn valid_id(id: &str) -> bool { + !id.is_empty() + && id.len() <= ID_MAX + && id.split('-').all(|part| { + !part.is_empty() + && part + .bytes() + .all(|b| b.is_ascii_lowercase() || b.is_ascii_digit()) + }) +} + +/// Parse a skill file's text. `stem`, when given, is the file name without +/// `.md`; the id must equal it. A byte order mark and CRLF line ends are +/// accepted. +pub fn parse(text: &str, stem: Option<&str>) -> Result { + let text = text.trim_start_matches('\u{feff}').replace("\r\n", "\n"); + let lines: Vec<&str> = text.split('\n').collect(); + if lines.first().map(|l| l.trim()) != Some("---") { + return Err(SkillError::at( + 1, + "a skill file starts with a --- header line", + )); + } + let Some(end) = (1..lines.len()).find(|&i| lines[i].trim() == "---") else { + return Err(SkillError::whole("the header has no closing --- line")); + }; + let mut single: Vec<(String, String, usize)> = vec![]; + let mut lists: Vec<(String, Vec, usize)> = vec![]; + let mut current: Option = None; + for (i, line) in lines[1..end].iter().enumerate() { + let n = i + 2; + if line.trim().is_empty() || line.trim_start().starts_with('#') { + continue; + } + if let Some(item) = line.strip_prefix("- ") { + let Some(key) = current.as_ref().filter(|k| LISTS.contains(&k.as_str())) else { + return Err(SkillError::at( + n, + format!("a list item outside a list key ({})", LISTS.join(", ")), + )); + }; + let item = strip_comment(item).trim().to_string(); + if item.is_empty() { + return Err(SkillError::at(n, "an empty list item")); + } + lists + .iter_mut() + .find(|(k, _, _)| k == key) + .expect("list key was opened") + .1 + .push(item); + continue; + } + let Some((key, value)) = line.split_once(':').filter(|(k, _)| { + !k.is_empty() && k.bytes().all(|b| b.is_ascii_lowercase() || b == b'_') + }) else { + return Err(SkillError::at( + n, + format!("expected 'key: value', got {:?}", line.trim()), + )); + }; + let value = strip_comment(value).trim().to_string(); + if single.iter().any(|(k, _, _)| k == key) || lists.iter().any(|(k, _, _)| k == key) { + return Err(SkillError::at(n, format!("{key} is given twice"))); + } + if LISTS.contains(&key) { + if !value.is_empty() { + return Err(SkillError::at( + n, + format!("{key} is a list: put each item on its own '- ' line below it"), + )); + } + lists.push((key.to_string(), vec![], n)); + } else if REQUIRED.contains(&key) || OPTIONAL.contains(&key) { + single.push((key.to_string(), value, n)); + } else { + let mut keys: Vec<&str> = REQUIRED.to_vec(); + keys.extend(LISTS); + keys.extend(OPTIONAL); + return Err(SkillError::at( + n, + format!("unknown key {key:?} (keys: {})", keys.join(", ")), + )); + } + current = Some(key.to_string()); + } + let get = |key: &str| { + single + .iter() + .find(|(k, _, _)| k == key) + .map(|(_, v, n)| (v.as_str(), *n)) + }; + for key in REQUIRED { + match get(key) { + None => return Err(SkillError::whole(format!("the header has no {key}"))), + Some(("", n)) => return Err(SkillError::at(n, format!("{key} is empty"))), + Some(_) => {} + } + } + let (id, id_line) = get("id").expect("required"); + if !valid_id(id) { + return Err(SkillError::at( + id_line, + format!("id {id:?}: use lower-case letters, digits and single hyphens, at most {ID_MAX} characters"), + )); + } + if let Some(stem) = stem { + if id != stem { + return Err(SkillError::at( + id_line, + format!("id {id:?} differs from its file name {stem:?}.md"), + )); + } + } + let (name, name_line) = get("name").expect("required"); + let count = name.chars().count(); + if count > NAME_MAX { + return Err(SkillError::at( + name_line, + format!("name is {count} characters; keep it to {NAME_MAX}"), + )); + } + let (description, description_line) = get("description").expect("required"); + let count = description.chars().count(); + if count > DESCRIPTION_MAX { + return Err(SkillError::at( + description_line, + format!("description is {count} characters; keep it to one line of at most {DESCRIPTION_MAX}"), + )); + } + let order = match get("order") { + None | Some(("", _)) => ORDER_LAST, + Some((value, n)) => { + if value.is_empty() || value.len() > 3 || !value.bytes().all(|b| b.is_ascii_digit()) { + return Err(SkillError::at( + n, + format!("order {value:?}: give a whole number from 0 to 999"), + )); + } + value.parse().expect("digits") + } + }; + let kind = match get("kind") { + None | Some(("", _)) => Kind::Check, + Some(("check", _)) => Kind::Check, + Some(("workflow", _)) => Kind::Workflow, + Some((value, n)) => { + return Err(SkillError::at( + n, + format!("kind {value:?}: use check or workflow"), + )) + } + }; + let compare = match get("compare") { + None | Some(("", _)) => None, + Some((COMPARE, _)) => Some(COMPARE.to_string()), + Some((value, n)) => { + return Err(SkillError::at( + n, + format!("compare {value:?}: the only value is {COMPARE}"), + )) + } + }; + let instructions = lines[end + 1..].join("\n").trim().to_string(); + if instructions.is_empty() { + return Err(SkillError::at( + end + 1, + "the skill has no instructions after its header", + )); + } + let list = |key: &str| { + lists + .iter() + .find(|(k, _, _)| k == key) + .map(|(_, v, _)| v.clone()) + .unwrap_or_default() + }; + Ok(Skill { + id: id.to_string(), + name: name.to_string(), + description: description.to_string(), + request: get("request").expect("required").0.to_string(), + use_when: get("use_when").expect("required").0.to_string(), + instructions, + examples: list("examples"), + cites: list("cites"), + tools: list("tools"), + order, + kind, + compare, + }) +} + +/// A value's trailing ` # comment`, as the header's own comments are +/// written; a `#` inside the text (no space before it) stays. +fn strip_comment(value: &str) -> &str { + match value.find(" #") { + Some(i) => &value[..i], + None => value, + } +} + +impl Skill { + /// The file text for this skill: header, then the instructions. + pub fn to_text(&self) -> String { + let mut out = String::from("---\n"); + out.push_str(&format!("id: {}\n", self.id)); + out.push_str(&format!("name: {}\n", self.name)); + out.push_str(&format!("description: {}\n", self.description)); + out.push_str(&format!("request: {}\n", self.request)); + out.push_str(&format!("use_when: {}\n", self.use_when)); + out.push_str(&format!("kind: {}\n", self.kind.key())); + if self.order != ORDER_LAST { + out.push_str(&format!("order: {}\n", self.order)); + } + if let Some(compare) = &self.compare { + out.push_str(&format!("compare: {compare}\n")); + } + for (key, items) in [ + ("examples", &self.examples), + ("cites", &self.cites), + ("tools", &self.tools), + ] { + if !items.is_empty() { + out.push_str(&format!("{key}:\n")); + for item in items { + out.push_str(&format!("- {item}\n")); + } + } + } + out.push_str("---\n"); + out.push_str(self.instructions.trim()); + out.push('\n'); + out + } +} + +/// The built-in skills' files, compiled in, in file name order. A test +/// checks this list against the folder. +macro_rules! built_in { + ($($id:literal),* $(,)?) => { + &[$(($id, include_str!(concat!("../../assets/skills/", $id, ".md")))),*] + }; +} +pub const BUILT_IN: &[(&str, &str)] = built_in![ + "activity-definition-review", + "add-scope", + "baseline-review", + "baseline-variance", + "build-schedule", + "calendar-duration-check", + "change-interview", + "compare-files", + "contingency-float", + "critical-path-explained", + "duration-review", + "export-pack", + "float-constraint-review", + "levels-of-detail", + "logic-health-check", + "look-ahead", + "milestone-status", + "near-critical-paths", + "one-page-schedule", + "progress-update", + "recovery-schedule", + "resource-load", + "resource-loading-review", + "risk-read", + "schedule-basis", + "schedule-maturity", + "schedule-review", + "sequence-review", + "time-impact", + "update-review", + "weather-nonwork", + "what-if", +]; + +/// The built-in skills, in catalog order. A built-in that does not parse is +/// a build mistake the tests catch; it is left out here. +pub fn built_in() -> Vec { + let mut list: Vec = BUILT_IN + .iter() + .filter_map(|(id, text)| parse(text, Some(id)).ok()) + .collect(); + sort(&mut list); + list +} + +fn sort(list: &mut [Skill]) { + list.sort_by(|a, b| a.order.cmp(&b.order).then_with(|| a.id.cmp(&b.id))); +} + +/// The folder of the user's skills: `skills` in the data folder. +pub fn user_dir() -> PathBuf { + crate::locate::data_folder().join("skills") +} + +/// The names of every tool the MCP server offers, the skill tools included. +pub fn known_tools() -> Vec { + crate::mcp::tool_definitions() + .iter() + .filter_map(|t| t["name"].as_str().map(String::from)) + .collect() +} + +/// The tools a skill names that the server does not offer. +pub fn unknown_tools(skill: &Skill, known: &[String]) -> Vec { + skill + .tools + .iter() + .filter(|t| !known.contains(t)) + .cloned() + .collect() +} + +/// One skill in the catalog. +#[derive(Clone, Debug, PartialEq)] +pub struct Entry { + pub skill: Skill, + pub source: Source, + /// The user's file, for Yours and Customized. + pub path: Option, + /// Problems that do not stop the skill from loading (a tool it names + /// that does not exist). + pub warnings: Vec, +} + +/// A user file left out, and why. +#[derive(Clone, Debug, PartialEq)] +pub struct Problem { + pub path: PathBuf, + pub error: String, +} + +#[derive(Clone, Debug, Default, PartialEq)] +pub struct Catalog { + pub entries: Vec, + pub problems: Vec, +} + +impl Catalog { + pub fn get(&self, id: &str) -> Option<&Entry> { + self.entries.iter().find(|e| e.skill.id == id) + } +} + +/// The catalog: the built-ins with the user's skills from `dir` (none when +/// `dir` is None or missing), in order, then by id. +pub fn catalog_in(dir: Option<&Path>) -> Catalog { + let mut entries: Vec = built_in() + .into_iter() + .map(|skill| Entry { + skill, + source: Source::BuiltIn, + path: None, + warnings: vec![], + }) + .collect(); + let mut problems = vec![]; + let mut files: Vec = dir + .and_then(|d| std::fs::read_dir(d).ok()) + .map(|rd| { + rd.filter_map(|e| e.ok()) + .map(|e| e.path()) + .filter(|p| { + p.is_file() && p.extension().is_some_and(|x| x.eq_ignore_ascii_case("md")) + }) + .collect() + }) + .unwrap_or_default(); + files.sort(); + let known = known_tools(); + for path in files { + let stem = path + .file_stem() + .map(|s| s.to_string_lossy().into_owned()) + .unwrap_or_default(); + let parsed = std::fs::read(&path) + .map_err(|e| format!("cannot read it: {e}")) + .and_then(|bytes| { + String::from_utf8(bytes).map_err(|_| "it is not UTF-8 text".to_string()) + }) + .and_then(|text| parse(&text, Some(&stem)).map_err(|e| e.to_string())); + let skill = match parsed { + Ok(skill) => skill, + Err(error) => { + problems.push(Problem { path, error }); + continue; + } + }; + let warnings = unknown_tools(&skill, &known) + .into_iter() + .map(|t| format!("tools: {t} is not an OpenXER tool")) + .collect(); + let entry = |source| Entry { + skill: skill.clone(), + source, + path: Some(path.clone()), + warnings, + }; + match entries.iter_mut().find(|e| e.skill.id == skill.id) { + Some(existing) if existing.source == Source::BuiltIn => { + *existing = entry(Source::Customized); + } + Some(_) => problems.push(Problem { + path: path.clone(), + error: format!("another file already has id {:?}", skill.id), + }), + None => entries.push(entry(Source::Yours)), + } + } + entries.sort_by(|a, b| { + a.skill + .order + .cmp(&b.skill.order) + .then_with(|| a.skill.id.cmp(&b.skill.id)) + }); + Catalog { entries, problems } +} + +/// The catalog with the user's skills from [`user_dir`]. +pub fn catalog() -> Catalog { + catalog_in(Some(&user_dir())) +} + +/// Check a skill's text: the parse error, or the skill with its warnings +/// (tools that do not exist). +pub fn validate(text: &str, stem: Option<&str>) -> Result<(Skill, Vec), SkillError> { + let skill = parse(text, stem)?; + let known = known_tools(); + let warnings = unknown_tools(&skill, &known) + .into_iter() + .map(|t| format!("tools: {t} is not an OpenXER tool")) + .collect(); + Ok((skill, warnings)) +} + +/// The text of a new skill with id `id`: a short template that explains +/// itself and parses as it is. +pub fn template(id: &str) -> String { + format!( + "--- +# A skill teaches an AI agent one way to analyze or change a schedule with +# OpenXER's tools. Lines starting with # are notes and are ignored. +id: {id} +name: My schedule check +# One line, shown in lists (at most 160 characters): +description: What this skill checks or does, in one line. +# The sentence a user pastes to the agent to run it: +request: Run my schedule check. +# The plain words that should make an agent pick this skill: +use_when: The user asks for ... +# check reads only; workflow builds or changes a schedule: +kind: check +# The OpenXER tools the steps run (see Tools you can name): +tools: +- openxer_load +--- +# My schedule check + +Say in one or two lines what this skill is for. + +## Steps + +1. Run `openxer_load` on the user's file and take ... from its result. +2. Every count, date, float and percent comes from a tool result. Never work + one out yourself. +3. Rank what you find by its consequence to the key dates, worst first. + +## Ask + +When something is unclear, ask the user one short question at a time. + +## Do not + +Do not change the schedule. Do not guess numbers. + +## Answer + +Two lines first: the finding that matters most. Then one section per finding. +" + ) +} + +/// A file name (without .md) that is a valid id and not yet used by a +/// user file in `dir` or a built-in: `base`, else `base-2`, `base-3` ... +pub fn free_id(dir: &Path, base: &str) -> String { + let taken = + |id: &str| dir.join(format!("{id}.md")).exists() || BUILT_IN.iter().any(|(b, _)| *b == id); + if valid_id(base) && !taken(base) { + return base.to_string(); + } + let base = if valid_id(base) { base } else { "my-skill" }; + (2..) + .map(|n| format!("{base}-{n}")) + .find(|id| !taken(id)) + .expect("a free id") +} + +/// Write a user skill file `

    /.md`, creating the folder. `replace` +/// false refuses an existing file. +pub fn write_user(dir: &Path, id: &str, text: &str, replace: bool) -> std::io::Result { + std::fs::create_dir_all(dir)?; + let path = dir.join(format!("{id}.md")); + if !replace && path.exists() { + return Err(std::io::Error::new( + std::io::ErrorKind::AlreadyExists, + format!("{} already exists", path.display()), + )); + } + let tmp = dir.join(format!(".{id}.md.tmp")); + std::fs::write(&tmp, text.replace("\r\n", "\n"))?; + std::fs::rename(&tmp, &path).inspect_err(|_| { + let _ = std::fs::remove_file(&tmp); + })?; + Ok(path) +} + +/// One entry as the list tool and `skills list` give it. +pub fn summary_json(e: &Entry) -> Value { + let mut v = json!({ + "id": e.skill.id, + "name": e.skill.name, + "description": e.skill.description, + "use_when": e.skill.use_when, + "request": e.skill.request, + "kind": e.skill.kind.key(), + "source": e.source.key(), + }); + if !e.warnings.is_empty() { + v["warnings"] = json!(e.warnings); + } + v +} + +/// One entry with its instructions, as the get tool and `skills show` give +/// it. A skill's `cites` stay in its file for the person who wrote it and +/// are never sent to an agent: answers do not say where a method came from. +pub fn detail_json(e: &Entry) -> Value { + let mut v = summary_json(e); + v["examples"] = json!(e.skill.examples); + v["tools"] = json!(e.skill.tools); + v["compare"] = json!(e.skill.compare); + v["path"] = json!(e.path); + v["instructions"] = json!(e.skill.instructions); + v +} + +/// The catalog as JSON: skills and the user files left out. +pub fn catalog_json(c: &Catalog, dir: Option<&Path>) -> Value { + json!({ + "skills": c.entries.iter().map(summary_json).collect::>(), + "problems": c.problems.iter().map(|p| json!({"path": p.path, "error": p.error})).collect::>(), + "folder": dir, + "rules": RULES, + }) +} + +/// What every agent is told with the skill list and each skill. +pub const RULES: &str = "Before analyzing or building a schedule, find the skill that matches the request and follow its instructions. Every count, date, float and percent you report comes from an OpenXER tool result; never compute schedule metrics yourself. Anything that writes is dry run first and goes to a new file."; + +/// The text an agent receives for one skill: the rules, then the skill. +pub fn prompt_text(s: &Skill) -> String { + format!( + "{RULES}\n\nSkill: {} ({}). {}\n\n{}", + s.name, + s.kind.label().to_lowercase(), + s.request, + s.instructions + ) +} + +#[cfg(test)] +#[path = "skills_tests.rs"] +mod tests; diff --git a/automation/src/skills_tests.rs b/automation/src/skills_tests.rs new file mode 100644 index 0000000..7735b7c --- /dev/null +++ b/automation/src/skills_tests.rs @@ -0,0 +1,386 @@ +use super::*; + +const GOOD: &str = "--- +id: my-check +name: My check +description: One line. +request: Run my check. +use_when: The user asks for my check. +kind: check +order: 5 +examples: +- Run it # a comment after the item +tools: +- openxer_load +--- +# My check + +Steps. +"; + +fn error(text: &str, stem: Option<&str>) -> String { + parse(text, stem).unwrap_err().to_string() +} + +#[test] +fn a_good_file_parses_with_every_field() { + let s = parse(GOOD, Some("my-check")).unwrap(); + assert_eq!(s.id, "my-check"); + assert_eq!(s.name, "My check"); + assert_eq!(s.order, 5); + assert_eq!(s.kind, Kind::Check); + assert_eq!(s.examples, vec!["Run it"]); + assert_eq!(s.tools, vec!["openxer_load"]); + assert!(s.instructions.starts_with("# My check")); + // A byte order mark and CRLF line ends are fine. + let crlf = format!("\u{feff}{}", GOOD.replace('\n', "\r\n")); + assert_eq!(parse(&crlf, Some("my-check")).unwrap(), s); + // The text a skill writes parses back to the same skill. + assert_eq!(parse(&s.to_text(), Some("my-check")).unwrap(), s); +} + +#[test] +fn each_bad_case_names_its_line_and_problem() { + let swap = |from: &str, to: &str| GOOD.replacen(from, to, 1); + let cases: Vec<(String, &str)> = vec![ + ( + "no header".to_string(), + "line 1: a skill file starts with a --- header line", + ), + ( + GOOD.replacen("---\n#", "\n#", 1), + "the header has no closing --- line", + ), + (swap("name: My check\n", ""), "the header has no name"), + ( + swap("request: Run my check.", "request:"), + "line 5: request is empty", + ), + ( + swap("id: my-check", "id: My_Check"), + "line 2: id \"My_Check\": use lower-case", + ), + ( + swap("id: my-check", "id: other"), + "line 2: id \"other\" differs from its file name \"my-check\".md", + ), + ( + swap("name: My check", &format!("name: {}", "x".repeat(41))), + "line 3: name is 41 characters; keep it to 40", + ), + ( + swap( + "description: One line.", + &format!("description: {}", "x".repeat(161)), + ), + "line 4: description is 161 characters", + ), + ( + swap("order: 5", "order: 1000"), + "line 8: order \"1000\": give a whole number from 0 to 999", + ), + ( + swap("kind: check", "kind: report"), + "line 7: kind \"report\": use check or workflow", + ), + ( + swap("kind: check", "colour: red"), + "line 7: unknown key \"colour\"", + ), + ( + swap("kind: check", "Not a key line"), + "line 7: expected 'key: value'", + ), + ( + swap("order: 5", "name: Again"), + "line 8: name is given twice", + ), + ( + swap("tools:", "tools: openxer_load"), + "line 11: tools is a list", + ), + ( + swap("order: 5", "- stray"), + "line 8: a list item outside a list key", + ), + ( + GOOD.split("---\n#").next().unwrap().to_string() + "---\n", + "has no instructions after its header", + ), + ( + swap("compare: x", "").replacen("kind: check", "compare: sometimes", 1), + "line 7: compare \"sometimes\"", + ), + ]; + for (text, expected) in cases { + let got = error(&text, Some("my-check")); + assert!( + got.starts_with(expected) || got.contains(expected), + "{expected:?} not in {got:?}" + ); + } +} + +fn user_dir() -> tempfile::TempDir { + tempfile::tempdir().unwrap() +} + +fn write(dir: &Path, id: &str, text: &str) { + std::fs::write(dir.join(format!("{id}.md")), text).unwrap(); +} + +#[test] +fn every_built_in_parses_names_real_tools_and_matches_the_folder() { + let known = known_tools(); + let mut problems = vec![]; + for (id, text) in BUILT_IN { + match parse(text, Some(id)) { + Err(e) => problems.push(format!("{id}: {e}")), + Ok(s) => { + for t in unknown_tools(&s, &known) { + problems.push(format!("{id}: names {t}, not an OpenXER tool")); + } + if s.tools.is_empty() { + problems.push(format!("{id}: names no tools")); + } + if !s.cites.is_empty() { + problems.push(format!("{id}: a built-in carries no cites")); + } + let lines = text.lines().count(); + if lines > 160 { + problems.push(format!("{id}: {lines} lines")); + } + } + } + } + assert!(problems.is_empty(), "{problems:#?}"); + let folder = Path::new(env!("CARGO_MANIFEST_DIR")).join("../assets/skills"); + let mut files: Vec = std::fs::read_dir(folder) + .unwrap() + .filter_map(|e| e.ok()) + .filter_map(|e| { + e.file_name() + .to_str() + .and_then(|n| n.strip_suffix(".md")) + .map(String::from) + }) + .collect(); + files.sort(); + let listed: Vec = BUILT_IN.iter().map(|(id, _)| id.to_string()).collect(); + assert_eq!( + files, listed, + "BUILT_IN lists every file in assets/skills, in name order" + ); + assert_eq!(built_in().len(), BUILT_IN.len()); +} + +#[test] +fn the_catalog_is_ordered_by_order_then_id() { + let dir = user_dir(); + write( + dir.path(), + "zz-first", + &GOOD + .replace("my-check", "zz-first") + .replace("order: 5", "order: 0"), + ); + write( + dir.path(), + "aa-last", + &GOOD + .replace("my-check", "aa-last") + .replace("order: 5\n", ""), + ); + let c = catalog_in(Some(dir.path())); + assert_eq!(c.entries[0].skill.id, "zz-first"); + assert_eq!(c.entries.last().unwrap().skill.id, "aa-last"); + let orders: Vec<(u32, String)> = c + .entries + .iter() + .map(|e| (e.skill.order, e.skill.id.clone())) + .collect(); + let mut sorted = orders.clone(); + sorted.sort(); + assert_eq!(orders, sorted); +} + +#[test] +fn a_user_file_customizes_a_built_in_and_deleting_it_restores_it() { + let dir = user_dir(); + let base = catalog_in(Some(dir.path())); + let original = base.get("look-ahead").unwrap(); + assert_eq!(original.source, Source::BuiltIn); + let mut mine = original.skill.clone(); + mine.name = "Our look-ahead".into(); + write(dir.path(), "look-ahead", &mine.to_text()); + let c = catalog_in(Some(dir.path())); + let e = c.get("look-ahead").unwrap(); + assert_eq!(e.source, Source::Customized); + assert_eq!(e.skill.name, "Our look-ahead"); + assert_eq!(c.entries.len(), base.entries.len()); + std::fs::remove_file(dir.path().join("look-ahead.md")).unwrap(); + let back = catalog_in(Some(dir.path())); + assert_eq!(back.get("look-ahead").unwrap().source, Source::BuiltIn); + assert_eq!( + back.get("look-ahead").unwrap().skill.name, + original.skill.name + ); +} + +#[test] +fn an_invalid_user_file_is_skipped_and_reported() { + let dir = user_dir(); + write(dir.path(), "broken", "no header here"); + write(dir.path(), "my-check", GOOD); + write( + dir.path(), + "odd-tool", + &GOOD + .replace("my-check", "odd-tool") + .replace("openxer_load", "made_up_tool"), + ); + std::fs::write(dir.path().join("notes.txt"), "not a skill").unwrap(); + let c = catalog_in(Some(dir.path())); + assert!(c.get("broken").is_none()); + assert_eq!(c.problems.len(), 1, "{:?}", c.problems); + assert!(c.problems[0].path.ends_with("broken.md")); + assert!(c.problems[0].error.contains("line 1")); + assert_eq!(c.get("my-check").unwrap().source, Source::Yours); + // An unknown tool loads with a warning. + let odd = c.get("odd-tool").unwrap(); + assert_eq!( + odd.warnings, + vec!["tools: made_up_tool is not an OpenXER tool"] + ); + // The built-ins are all still there. + assert!(c.entries.len() >= BUILT_IN.len() + 2); + // A missing folder is an empty one. + assert_eq!( + catalog_in(Some(&dir.path().join("none"))).entries.len(), + BUILT_IN.len() + ); +} + +#[test] +fn the_template_parses_and_free_ids_avoid_taken_ones() { + let dir = user_dir(); + let id = free_id(dir.path(), "my-skill"); + assert_eq!(id, "my-skill"); + let text = template(&id); + let s = parse(&text, Some(&id)).unwrap(); + assert!(unknown_tools(&s, &known_tools()).is_empty()); + write_user(dir.path(), &id, &text, false).unwrap(); + assert!(write_user(dir.path(), &id, &text, false).is_err()); + assert_eq!(free_id(dir.path(), "my-skill"), "my-skill-2"); + assert_eq!(free_id(dir.path(), "look-ahead"), "look-ahead-2"); + assert_eq!(free_id(dir.path(), "Bad Id"), "my-skill-2"); +} + +#[test] +fn the_cites_of_a_user_skill_are_never_sent_to_an_agent() { + let dir = user_dir(); + write( + dir.path(), + "my-check", + &GOOD.replace("tools:", "cites:\n- Some Book, chapter 3\ntools:"), + ); + let c = catalog_in(Some(dir.path())); + let e = c.get("my-check").unwrap(); + assert_eq!(e.skill.cites, vec!["Some Book, chapter 3"]); + for v in [summary_json(e), detail_json(e)] { + assert!(!v.to_string().contains("Some Book"), "{v}"); + } + assert!(!prompt_text(&e.skill).contains("Some Book")); +} + +/// Words that would say where a built-in skill came from. The pattern list +/// stays in this test: a standards body's acronym and name, the numbering of +/// recommended practices (two or three digits, R-, two digits), the other +/// agencies' acronyms, the earlier tool and other products. +#[test] +fn no_built_in_says_where_it_came_from() { + let words = [ + "aace", + "advancement of cost engineering", + "dcma", + "gao", + "pmi", + "project management institute", + "nasa", + "recommended practice", + "sidecar", + "primavera", + "oracle", + "p6", + "f9", + "ported", + "adapted from", + "based on the", + "according to", + ]; + let mut problems = vec![]; + for (id, text) in BUILT_IN { + let lower = text.to_lowercase(); + for w in words { + let found = lower.match_indices(w).any(|(i, _)| { + let before = lower[..i].chars().next_back(); + let after = lower[i + w.len()..].chars().next(); + let word = |c: Option| c.is_some_and(|c| c.is_alphanumeric()); + !word(before) && !word(after) + }); + if found { + problems.push(format!("{id}: {w}")); + } + } + // 24R-03, 105R-19 ... + let b = text.as_bytes(); + for i in 0..b.len() { + let digits = b[..i] + .iter() + .rev() + .take_while(|c| c.is_ascii_digit()) + .count(); + if (2..=3).contains(&digits) + && b[i..].starts_with(b"R-") + && b.get(i + 2).is_some_and(u8::is_ascii_digit) + && b.get(i + 3).is_some_and(u8::is_ascii_digit) + { + problems.push(format!("{id}: a practice number at byte {i}")); + } + } + for dash in ['\u{2013}', '\u{2014}'] { + if text.contains(dash) { + problems.push(format!("{id}: an en or em dash")); + } + } + } + assert!(problems.is_empty(), "{problems:#?}"); +} + +/// The private list the engine guard uses (`internal-refs.txt` in +/// `OPENXER_FIXTURES`), read through the same loader; skipped with a printed +/// line when it is absent. +#[test] +fn no_built_in_holds_a_word_of_the_private_list() { + let Some(lines) = openxer_engine::fixture::fixture_list("internal-refs.txt") else { + println!( + "SKIPPED no_built_in_holds_a_word_of_the_private_list: internal-refs.txt not found" + ); + return; + }; + let words: Vec = lines + .iter() + .map(|f| f.join(" ").to_ascii_lowercase()) + .filter(|w| !w.is_empty()) + .collect(); + let mut problems = vec![]; + for (id, text) in BUILT_IN { + let lower = text.to_ascii_lowercase(); + for w in &words { + if lower.contains(w.as_str()) { + problems.push(format!("{id}: contains a listed word")); + } + } + } + assert!(problems.is_empty(), "{problems:#?}"); +} diff --git a/automation/src/storage.rs b/automation/src/storage.rs new file mode 100644 index 0000000..92010ec --- /dev/null +++ b/automation/src/storage.rs @@ -0,0 +1,532 @@ +use crate::{project_json, AutomationError, Result}; +use openxer_xer::{Document, ProjectData}; +use rusqlite::{params, Connection, OpenFlags}; +use serde_json::{json, Value}; +use std::{fs, io::Read, path::Path}; + +pub(crate) struct Loaded { + pub project: ProjectData, + pub workspace_id: Option, + /// From a workspace with a shared dictionary (schema 3): what the + /// project read from it, so a save knows its own dictionary rows. + pub mark: Option, +} +pub(crate) fn io(error: impl std::fmt::Display) -> AutomationError { + AutomationError::new("io_error", error.to_string()) +} +pub(crate) fn invalid(error: impl std::fmt::Display) -> AutomationError { + AutomationError::new("invalid_source", error.to_string()) +} +pub(crate) fn is_database_extension(path: &Path) -> bool { + path.extension().and_then(|s| s.to_str()).is_some_and(|s| { + ["db", "sqlite", "sqlite3"] + .iter() + .any(|v| s.eq_ignore_ascii_case(v)) + }) +} +pub(crate) fn check_destination(path: &Path) -> Result<()> { + check_destination_as(path, false) +} +/// Like [`check_destination`]; with `xml` the output is a project XML file +/// and must end in `.xml`. +pub(crate) fn check_destination_as(path: &Path, xml: bool) -> Result<()> { + if path.as_os_str().is_empty() { + return Err(AutomationError::new( + "invalid_arguments", + "output path cannot be empty", + )); + } + if fs::symlink_metadata(path).is_ok() { + return Err(AutomationError::new( + "output_exists", + format!("Destination already exists: {}", path.display()), + )); + } + let ext_is = |e: &str| path.extension().is_some_and(|s| s.eq_ignore_ascii_case(e)); + if xml && !ext_is("xml") { + return Err(AutomationError::new( + "invalid_arguments", + "A project XML output must end in .xml", + )); + } + if !xml && !is_database_extension(path) && !ext_is("xer") { + return Err(AutomationError::new( + "invalid_arguments", + "Output must end in .xer, .db, .sqlite, or .sqlite3", + )); + } + if !parent(path).is_dir() { + return Err(io("Output parent directory does not exist")); + } + Ok(()) +} +pub(crate) fn parent(path: &Path) -> &Path { + path.parent() + .filter(|p| !p.as_os_str().is_empty()) + .unwrap_or_else(|| Path::new(".")) +} +pub(crate) fn is_database(path: &Path) -> Result { + let mut file = + fs::File::open(path).map_err(|e| io(format!("Cannot open {}: {e}", path.display())))?; + let mut prefix = [0u8; 16]; + let n = file + .read(&mut prefix) + .map_err(|e| io(format!("Cannot read {}: {e}", path.display())))?; + Ok(n == 16 && &prefix == b"SQLite format 3\0") +} +pub(crate) fn read_database(path: &Path) -> Result { + let c = Connection::open_with_flags( + path, + OpenFlags::SQLITE_OPEN_READ_ONLY | OpenFlags::SQLITE_OPEN_NO_MUTEX, + ) + .map_err(invalid)?; + c.prepare("SELECT id,source_name,project_key,title,xer_content FROM projects LIMIT 0") + .map_err(|_| invalid("Not an OpenXER workspace: expected projects table is missing"))?; + Ok(c) +} +/// Whether a workspace keeps its projects' calendars, resources, codes and +/// the other dictionaries once, in a shared workspace dictionary (schema 3; +/// see `workspace_db`). A newer schema is refused, and so is the schema 2 +/// an earlier build wrote until it is upgraded. +pub(crate) fn shared(c: &Connection) -> Result { + let schema = crate::workspace_db::schema(c).map_err(invalid)?; + if schema == crate::workspace_db::EARLIER_DICTIONARY_SCHEMA { + return Err(AutomationError::new( + "workspace_needs_migration", + "This workspace was made by an earlier OpenXER (workspace schema 2). `workspace migrate --output NEW.db` upgrades a copy of it; OpenXER upgrades it when it opens it.", + )); + } + if schema > crate::workspace_db::DICTIONARY_SCHEMA { + return Err(AutomationError::new( + "workspace_schema_unsupported", + format!("This workspace uses workspace schema {schema}, which needs a newer OpenXER."), + )); + } + Ok(schema == crate::workspace_db::DICTIONARY_SCHEMA) +} +fn columns(c: &Connection) -> Result> { + let mut stmt = c.prepare("PRAGMA table_info(projects)").map_err(invalid)?; + let rows = stmt.query_map([], |row| row.get(1)).map_err(invalid)?; + rows.collect::, _>>() + .map_err(invalid) +} +pub(crate) fn rows(c: &Connection) -> Result> { + let mut stmt = c + .prepare("SELECT id,project_key,title,source_name FROM projects ORDER BY id") + .map_err(invalid)?; + let rows = stmt.query_map([], |r| Ok(json!({"workspace_id":r.get::<_,i64>(0)?,"project_id":r.get::<_,i64>(1)?,"name":r.get::<_,String>(2)?,"source_name":r.get::<_,String>(3)?}))).map_err(invalid)?; + rows.collect::, _>>() + .map_err(invalid) +} +pub(crate) fn inspect(input: &Path) -> Result { + if is_database(input)? { + let c = read_database(input)?; + let schema = crate::workspace_db::schema(&c).map_err(invalid)?; + let mut out = json!({"input":input,"format":"openxer_workspace","workspace_schema":schema,"projects":rows(&c)?}); + if schema >= crate::workspace_db::DICTIONARY_SCHEMA { + let (dict, revision) = crate::workspace_db::read_dictionary(&c).map_err(invalid)?; + let counts: serde_json::Map = dict + .tables + .iter() + .filter(|t| !t.rows.is_empty()) + .map(|t| (t.name.to_ascii_uppercase(), json!(t.rows.len()))) + .collect(); + out["dictionary"] = json!({"revision": revision, "rows": counts}); + } + Ok(out) + } else { + let data = fs::read(input) + .map_err(|e| invalid(format!("Cannot read {}: {e}", input.display())))?; + use openxer_interchange::project_xml; + let xml = project_xml::is_xml(&data); + let (doc, report) = if xml { + let (doc, report) = project_xml::read_bytes_with_report(&data).map_err(invalid)?; + (doc, Some(report)) + } else { + (project_xml::read_bytes(&data).map_err(invalid)?, None) + }; + let projects: Vec<_> = doc + .projects() + .iter() + .map(|(id, name)| json!({"project_id":id,"name":name})) + .collect(); + let tables: Vec<_> = doc + .tables + .iter() + .map(|t| { + // A project XML file has no element for a project's own root + // WBS node, so its WBS count leaves those rows out. + let nodes = if xml && t.name.eq_ignore_ascii_case("PROJWBS") { + t.rows + .iter() + .filter(|r| t.value(r, "proj_node_flag") == "Y") + .count() + } else { + 0 + }; + let mut row = json!({"name":t.name,"row_count":t.rows.len() - nodes}); + if nodes > 0 { + row["project_nodes"] = json!(nodes); + } + row + }) + .collect(); + let format = if xml { "xml" } else { "xer" }; + let encoding = doc.windows_encoding; + let mut out = json!({"input":input,"format":format,"windows_1252":encoding, + "projects":projects,"tables":tables}); + if let Some(r) = report { + // What the file held, what OpenXER has no place for (skipped), + // and fields it does not read. + out["xml"] = json!({"elements":r.elements,"unhandled":r.unhandled, + "fields_not_read":r.fields_not_read}); + } + Ok(out) + } +} +pub(crate) fn load( + input: &Path, + project_id: Option, + workspace_id: Option, +) -> Result { + let (document, pid, source, wid, level, mark) = if is_database(input)? { + let c = read_database(input)?; + let shared = shared(&c)?; + let candidates: Vec<_> = rows(&c)? + .into_iter() + .filter(|r| { + project_id.is_none_or(|id| r["project_id"] == id) + && workspace_id.is_none_or(|id| r["workspace_id"] == id) + }) + .collect(); + if candidates.is_empty() { + return Err(AutomationError::new( + "project_not_found", + "No workspace project matches the selectors", + )); + } + if candidates.len() != 1 { + return Err(AutomationError::new( + "ambiguous_project", + "Select project_id or workspace_id from inspect; multiple projects match", + )); + } + let wid = candidates[0]["workspace_id"] + .as_i64() + .expect("SQLite integer id"); + let cols = columns(&c)?; + let encoding = if cols.iter().any(|s| s == "source_windows_encoding") { + "source_windows_encoding" + } else { + "0" + }; + let level = if cols.iter().any(|s| s == "level_resources") { + "level_resources" + } else { + "0" + }; + let sql = format!("SELECT source_name,project_key,xer_content,{encoding},{level} FROM projects WHERE id=?1"); + let (source, pid, text, legacy, level): (String, i64, String, bool, bool) = c + .query_row(&sql, [wid], |r| { + Ok((r.get(0)?, r.get(1)?, r.get(2)?, r.get(3)?, r.get(4)?)) + }) + .map_err(invalid)?; + let mut doc = Document::parse(&text).map_err(invalid)?; + doc.windows_encoding = legacy; + // The shared calendars, resources and codes come back from the + // workspace dictionary, as the app opens the project. + let mark = if shared { + Some(crate::workspace_db::hydrate(&c, &mut doc, Some(wid)).map_err(invalid)?) + } else { + None + }; + (doc, pid, source, Some(wid), Some(level), mark) + } else { + if workspace_id.is_some() { + return Err(AutomationError::new( + "invalid_arguments", + "workspace_id applies only to OpenXER databases", + )); + } + let doc = openxer_interchange::project_xml::read_file(input).map_err(invalid)?; + let projects: Vec<_> = doc + .projects() + .into_iter() + .filter(|(id, _)| project_id.is_none_or(|pid| *id == pid)) + .collect(); + if projects.is_empty() { + return Err(AutomationError::new( + "project_not_found", + "No XER project matches the selector", + )); + } + if projects.len() != 1 { + return Err(AutomationError::new( + "ambiguous_project", + "Select project_id from inspect; the XER contains multiple projects", + )); + } + ( + doc, + projects[0].0, + input + .file_name() + .unwrap_or_default() + .to_string_lossy() + .into_owned(), + None, + None, + None, + ) + }; + let mut project = ProjectData::from_document(document, pid, source).map_err(invalid)?; + if let Some(level) = level { + project.model.options.do_level = level; + } + project.model.validate().map_err(invalid)?; + Ok(Loaded { + project, + workspace_id: wid, + mark, + }) +} +pub(crate) fn schema(c: &Connection) -> Result<()> { + c.execute_batch("CREATE TABLE IF NOT EXISTS projects(id INTEGER PRIMARY KEY,source_name TEXT NOT NULL,project_key INTEGER NOT NULL,title TEXT NOT NULL,xer_content TEXT NOT NULL,updated_at TEXT DEFAULT CURRENT_TIMESTAMP,source_windows_encoding INTEGER NOT NULL DEFAULT 0,level_resources INTEGER NOT NULL DEFAULT 0,UNIQUE(source_name,project_key));CREATE TABLE IF NOT EXISTS preferences(key TEXT PRIMARY KEY,value TEXT NOT NULL);").map_err(io)?; + let cols = columns(c)?; + for col in ["source_windows_encoding", "level_resources"] { + if !cols.iter().any(|s| s == col) { + c.execute_batch(&format!( + "ALTER TABLE projects ADD COLUMN {col} INTEGER NOT NULL DEFAULT 0" + )) + .map_err(io)?; + } + } + Ok(()) +} +/// A database `schema` has just created (its `projects` table did not +/// exist): a new workspace keeps one shared dictionary from the start. +pub(crate) fn new_database(c: &Connection) -> Result { + let exists = c + .query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name='projects'", + [], + |_| Ok(()), + ) + .map(|_| true) + .or_else(|e| match e { + rusqlite::Error::QueryReturnedNoRows => Ok(false), + e => Err(e), + }) + .map_err(io)?; + Ok(!exists) +} + +/// Write project `p` into workspace row `id` (a new row when `None`). +/// With a shared dictionary its dictionary rows are merged into it first +/// (`mark`: what the project read from it) and left out of the stored text. +pub(crate) fn store( + c: &Connection, + p: &ProjectData, + id: Option, + mark: Option<&crate::workspace_db::Mark>, +) -> Result { + store_with(c, p, id, mark, &crate::workspace_db::Choices::new()).map(|(id, _)| id) +} + +/// [`store`] with an import's choices for dictionary rows whose name the +/// workspace has with different content; also returns the merge events. +pub(crate) fn store_with( + c: &Connection, + p: &ProjectData, + id: Option, + mark: Option<&crate::workspace_db::Mark>, + choices: &crate::workspace_db::Choices, +) -> Result<(i64, Vec)> { + let shared = shared(c)?; + let doc = p.updated_document(); + let id = match id { + Some(id) => id, + None => { + c.execute("INSERT INTO projects(source_name,project_key,title,xer_content,source_windows_encoding,level_resources) VALUES(?1,?2,?3,?4,?5,?6)",params![p.source_name,p.model.project.proj_id,p.model.project.name,if shared { String::new() } else { doc.text() },p.document.windows_encoding,p.model.options.do_level]).map_err(io)?; + let id = c.last_insert_rowid(); + if !shared { + return Ok((id, vec![])); + } + id + } + }; + let (text, events) = if shared { + let stored = crate::workspace_db::store_with( + c, + &doc, + mark, + Some(id), + &openxer_xer::workspace_scope::merge::Policy::Save, + choices, + ) + .map_err(invalid)?; + (stored.text, stored.outcome.events) + } else { + (doc.text(), vec![]) + }; + let count = c.execute("UPDATE projects SET title=?1,xer_content=?2,source_windows_encoding=?3,level_resources=?4,updated_at=CURRENT_TIMESTAMP WHERE id=?5",params![p.model.project.name,text,p.document.windows_encoding,p.model.options.do_level,id]).map_err(io)?; + if count != 1 { + return Err(invalid("Selected workspace row disappeared")); + } + Ok((id, events)) +} + +/// The XER text an export writes for project `pid` of `loaded`: from a +/// workspace with a shared dictionary, only the dictionary rows it uses. +pub(crate) fn export_document(loaded: &Loaded) -> Document { + let doc = loaded.project.updated_document(); + if loaded.mark.is_some() { + openxer_xer::workspace_scope::used_subset(&doc, loaded.project.model.project.proj_id) + } else { + doc + } +} +pub(crate) fn publish(temp: tempfile::NamedTempFile, output: &Path) -> Result<()> { + temp.as_file().sync_all().map_err(io)?; + temp.persist_noclobber(output).map_err(|e| { + AutomationError::new( + if e.error.kind() == std::io::ErrorKind::AlreadyExists { + "output_exists" + } else { + "io_error" + }, + e.error.to_string(), + ) + })?; + Ok(()) +} +pub(crate) fn save(input: &Path, output: &Path, loaded: &Loaded) -> Result<()> { + check_destination(output)?; + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + if is_database_extension(output) { + if loaded.workspace_id.is_some() { + let source = read_database(input)?; + source.backup("main", temp.path(), None).map_err(io)?; + } + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE").map_err(io)?; + let tx = c.transaction().map_err(io)?; + let new = new_database(&tx)?; + schema(&tx)?; + if new { + crate::workspace_db::start_new(&tx).map_err(io)?; + } + let id = store( + &tx, + &loaded.project, + loaded.workspace_id, + loaded.mark.as_ref(), + )?; + tx.execute("INSERT INTO preferences(key,value) VALUES('last_project',?1) ON CONFLICT(key) DO UPDATE SET value=excluded.value",[id.to_string()]).map_err(io)?; + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + } else { + export_document(loaded).write(temp.path()).map_err(io)?; + } + publish(temp, output) +} +/// `workspace migrate`: plan (dry run) or write a copy of `input` that keeps +/// its workspace rows in a shared dictionary. The input is never changed and +/// stays as the backup of the migrated copy. +pub(crate) fn workspace_migrate( + input: &Path, + output: Option<&Path>, + dry_run: bool, +) -> Result { + if !is_database(input)? { + return Err(invalid( + "workspace migrate needs an OpenXER workspace database", + )); + } + let failed = |e: String| AutomationError::new("migration_failed", e); + match (output, dry_run) { + (None, true) => { + let mut c = read_database(input)?; + let mut result = crate::workspace_db::migrate(&mut c, true, None).map_err(failed)?; + result["input"] = json!(input); + Ok(result) + } + (Some(output), false) => { + check_destination(output)?; + if !is_database_extension(output) { + return Err(AutomationError::new( + "invalid_arguments", + "workspace migrate writes an OpenXER database (.db/.sqlite/.sqlite3)", + )); + } + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + read_database(input)? + .backup("main", temp.path(), None) + .map_err(io)?; + let mut c = Connection::open(temp.path()).map_err(io)?; + c.execute_batch("PRAGMA journal_mode=DELETE").map_err(io)?; + let mut result = crate::workspace_db::migrate(&mut c, false, None).map_err(failed)?; + c.close().map_err(|(_, e)| io(e))?; + publish(temp, output)?; + result["input"] = json!(input); + result["output"] = json!(output); + result["backup"] = json!(input); + Ok(result) + } + _ => Err(AutomationError::new( + "invalid_arguments", + "workspace migrate needs exactly one of output or dry_run", + )), + } +} +pub(crate) fn import(input: &Path, output: &Path, project_id: Option) -> Result { + check_destination(output)?; + if !is_database_extension(output) { + return Err(AutomationError::new( + "invalid_arguments", + "import requires an OpenXER database output (.db/.sqlite/.sqlite3)", + )); + } + if is_database(input)? { + return Err(AutomationError::new( + "invalid_arguments", + "import requires XER input; use schedule/export for an existing workspace", + )); + } + let doc = openxer_interchange::project_xml::read_file(input).map_err(invalid)?; + let selected: Vec<_> = doc + .projects() + .into_iter() + .filter(|(id, _)| project_id.is_none_or(|pid| *id == pid)) + .collect(); + if selected.is_empty() { + return Err(AutomationError::new( + "project_not_found", + "No XER project matches the selector", + )); + } + let temp = tempfile::NamedTempFile::new_in(parent(output)).map_err(io)?; + let mut c = Connection::open(temp.path()).map_err(io)?; + let tx = c.transaction().map_err(io)?; + schema(&tx)?; + // A new workspace keeps one shared dictionary. + crate::workspace_db::start_new(&tx).map_err(io)?; + let mut summaries = vec![]; + for (pid, _) in selected { + let p = load(input, Some(pid), None)?.project; + let (id, events) = store_with(&tx, &p, None, None, &Default::default())?; + summaries.push( + json!({"workspace_id":id,"project":project_json(&p),"warnings":p.warnings, + "dictionary":crate::workspace_db::import_report(&events)}), + ); + } + tx.execute( + "INSERT INTO preferences(key,value) VALUES('last_project',?1)", + [summaries[0]["workspace_id"].to_string()], + ) + .map_err(io)?; + tx.commit().map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + publish(temp, output)?; + Ok(json!({"output":output,"projects":summaries})) +} diff --git a/automation/src/usage.rs b/automation/src/usage.rs new file mode 100644 index 0000000..3eef6b6 --- /dev/null +++ b/automation/src/usage.rs @@ -0,0 +1,233 @@ +//! `usage`: an assignment's or a resource's time-phased units (or costs) by +//! day, week or month, spread as the desktop's usage views spread them +//! (`openxer_xer::spread`, so resource curves shape it). Read-only. +use crate::{AutomationError, Result}; +use openxer_xer::spread::{self, Item, Lookup, Plan, Shaping}; +use openxer_xer::{date_string, parse_relative, periods, ProjectData}; +use serde_json::{json, Value}; + +/// Most periods one answer holds. +pub const MAX_PERIODS: usize = 1000; + +/// What `usage` reads: the project, an optional activity and resource +/// filter, the interval and an optional date range. +pub struct Request<'a> { + pub activity: Option<&'a str>, + pub resource: Option<&'a str>, + pub interval: Option<&'a str>, + pub from: Option<&'a str>, + pub to: Option<&'a str>, + pub costs: bool, +} + +fn invalid(message: impl Into) -> AutomationError { + AutomationError::new("invalid_arguments", message) +} + +fn num(s: &str) -> i64 { + s.trim().parse().unwrap_or(0) +} + +struct Row { + activity: String, + resource: String, + curve: Option, + duration_type: String, + shaping: Option, + task: usize, + original: i64, + quantities: [f64; 3], +} + +/// The `usage` answer. +pub fn usage(p: &ProjectData, r: &Request) -> Result { + let interval = r.interval.unwrap_or("week"); + if !matches!(interval, "day" | "week" | "month") { + return Err(invalid(format!( + "interval takes day, week or month, not {interval:?}" + ))); + } + if r.activity.is_none() && r.resource.is_none() { + return Err(invalid( + "usage needs an activity (Activity ID), a resource (short name) or both", + )); + } + let m = &p.model; + let origin = m.origin_serial; + let doc = &p.document; + let rsrc_id = match r.resource { + None => None, + Some(code) => Some( + doc.table("RSRC") + .and_then(|t| { + t.rows + .iter() + .find(|row| t.value(row, "rsrc_short_name").trim() == code.trim()) + .map(|row| num(t.value(row, "rsrc_id"))) + }) + .ok_or_else(|| { + AutomationError::new("not_found", format!("No resource {code:?}")) + })?, + ), + }; + let task = match r.activity { + None => None, + Some(code) => Some( + m.activities + .iter() + .position(|a| a.task_code == code) + .ok_or_else(|| { + AutomationError::new("not_found", format!("No activity {code:?}")) + })?, + ), + }; + let names: std::collections::HashMap = + doc.table("RSRC").map_or_else(Default::default, |t| { + t.rows + .iter() + .map(|row| { + ( + num(t.value(row, "rsrc_id")), + t.value(row, "rsrc_short_name").to_string(), + ) + }) + .collect() + }); + let lookup = Lookup::new(p); + let mut rows: Vec = vec![]; + for x in spread::assignment_rows(p) { + if task.is_some_and(|k| k != x.task) || rsrc_id.is_some_and(|id| id != x.rsrc) { + continue; + } + let a = &m.activities[x.task]; + rows.push(Row { + activity: a.task_code.clone(), + resource: names.get(&x.rsrc).cloned().unwrap_or_default(), + curve: openxer_xer::edit::curves::curve_label(doc, x.row), + duration_type: lookup.duration_type(a.task_id).to_string(), + shaping: x.shaping, + task: x.task, + original: x.original, + quantities: if r.costs { x.costs } else { x.units }, + }); + } + fn item<'a>(m: &'a openxer_engine::model::Model, x: &'a Row) -> Item<'a> { + Item { + activity: &m.activities[x.task], + original: x.original, + shaping: x.shaping.as_ref(), + } + } + // Each row's windows and curve position, worked out once. + let plans: Vec = rows.iter().map(|x| Plan::of(m, &item(m, x))).collect(); + // The range: what the caller asked for, else every window of the rows. + // A window without working time still needs the period holding its + // start, so it counts as reaching one minute past it. + let mut first = i64::MAX; + let mut last = i64::MIN; + for plan in &plans { + let w = &plan.windows; + for (s, f) in [w.budget, w.actual, w.remaining, w.remaining_late] + .into_iter() + .flatten() + { + first = first.min(s); + last = last.max(f.max(s + 1)); + } + } + let date = |name: &str, text: Option<&str>| -> Result> { + match text { + None => Ok(None), + Some(t) => parse_relative(origin, t).map_err(|e| invalid(format!("{name}: {e}"))), + } + }; + if let Some(v) = date("from", r.from)? { + first = v; + } + if let Some(v) = date("to", r.to)? { + last = v; + } + // Weeks start on Monday here. + let length = match interval { + "day" => periods::Interval::Day, + "week" => periods::Interval::Week { sunday: false }, + _ => periods::Interval::Month, + }; + let periods = if first != i64::MAX { + periods::sweep(origin, length, first, last, MAX_PERIODS).map_err(|_| { + invalid(format!( + "More than {MAX_PERIODS} periods; use a longer interval or from and to" + )) + })? + } else { + vec![] + }; + let n = periods.len(); + let mut totals = [vec![0.; n], vec![0.; n], vec![0.; n], vec![0.; n]]; + let mut stored_totals = [0.; 4]; + // `unplaced`: the part of the stored quantity no period holds (outside + // the periods, or no window to spread over, such as actual units + // without an actual start or remaining units on a completed activity), + // so that total + unplaced = stored. + let series = |values: &[f64], stored: f64| { + let total = values.iter().sum::() + 0.; + json!({"total": total, "unplaced": stored - total + 0., "per_period": values}) + }; + let mut assignments = vec![]; + for (x, plan) in rows.iter().zip(&plans) { + let it = item(m, x); + let [budget, actual, remaining] = x.quantities; + let stored = [budget, actual, remaining, remaining]; + let mut out = [vec![0.; n], vec![0.; n], vec![0.; n], vec![0.; n]]; + spread::budget(m, &it, plan, budget, &periods, &mut out[0]); + spread::actual(m, &it, plan, actual, &periods, &mut out[1]); + spread::remaining(m, &it, plan, remaining, &periods, &mut out[2]); + spread::remaining_late(m, &it, plan, remaining, &periods, &mut out[3]); + for (t, o) in totals.iter_mut().zip(&out) { + for (a, b) in t.iter_mut().zip(o) { + *a += b; + } + } + for (t, q) in stored_totals.iter_mut().zip(stored) { + *t += q; + } + let w = &plan.windows; + let window = |v: Option<(i64, i64)>| { + v.map_or(Value::Null, |(s, f)| { + json!({"start": date_string(origin, Some(s)), "finish": date_string(origin, Some(f))}) + }) + }; + assignments.push(json!({ + "activity": x.activity, + "resource": x.resource, + "curve": x.curve, + "duration_type": x.duration_type, + "curve_applies": spread::curve_applies(&x.duration_type), + "shaped": x.shaping.as_ref().is_some_and(|s| s.shape.is_some()), + "manual": x.shaping.as_ref().is_some_and(|s| s.manual.is_some()), + "curve_position": x.shaping.as_ref().and_then(|s| s.shape).map(|_| plan.position), + "windows": {"budget": window(w.budget), "actual": window(w.actual), + "remaining": window(w.remaining), "remaining_late": window(w.remaining_late)}, + "budget": series(&out[0], budget), + "actual": series(&out[1], actual), + "remaining": series(&out[2], remaining), + "remaining_late": series(&out[3], remaining), + "stored": {"budget": budget, "actual": actual, "remaining": remaining}, + })); + } + Ok(json!({ + "measure": if r.costs { "costs" } else { "units" }, + "interval": interval, + "periods": periods.iter().map(|&(s, e)| json!({ + "start": date_string(origin, Some(s)), "finish": date_string(origin, Some(e)) + })).collect::>(), + "assignments": assignments, + "totals": {"budget": series(&totals[0], stored_totals[0]), + "actual": series(&totals[1], stored_totals[1]), + "remaining": series(&totals[2], stored_totals[2]), + "remaining_late": series(&totals[3], stored_totals[3])}, + "rules": "Periods are [start, finish). Every assignment spreads over its own window: its lag after the activity's start (remaining lag only before the activity starts) and its own duration (units over units/time; without units or without a units/time it spans the activity), its own valid actual dates, on the resource's calendar on a resource dependent activity and the activity's calendar otherwise. Budget spreads over the planned dates, remaining over the early dates (leveled dates when the project levels) from the data date, remaining late over the late dates. Without a curve, or on a duration type other than DT_FixedDrtn and DT_FixedDUR2, a quantity spreads evenly over the window's working time. With a curve it follows the curve over the window: point k (1 to 20) weighs the k-th twentieth of the working duration, point 0 counts only for actuals (at the actual start); actuals follow the curve to the current position, remaining the rest of it. A window without working time puts everything in the period holding its start. When the periods cover a window, its periods add up to the stored quantity exactly; unplaced is the part no period holds (total + unplaced = stored). Leveling ignores curves.", + "verified": false, + "verification": "Curve spreading follows OpenXER's reading of the documented behavior; the exact per-period numbers have not yet been measured against other software.", + })) +} diff --git a/automation/src/user_prefs.rs b/automation/src/user_prefs.rs new file mode 100644 index 0000000..0a63d97 --- /dev/null +++ b/automation/src/user_prefs.rs @@ -0,0 +1,227 @@ +//! User preferences kept in a workspace that an agent may read or set: +//! the Assistance switches of the app's User Preferences (whether Add opens +//! the New Activity wizard). The desktop app reads and writes the same row +//! through [`Assistance`], so both always agree on its key and form. +use crate::storage::{self, invalid, io, parent}; +use crate::{AutomationError, Result}; +use rusqlite::{params, Connection, OptionalExtension}; +use serde::{Deserialize, Serialize}; +use serde_json::{json, Value}; +use std::path::{Path, PathBuf}; + +/// The `preferences` row that holds [`Assistance`]. +pub const ASSISTANCE_KEY: &str = "assistance_v1"; + +/// User Preferences, Assistance: which wizards guide an Add. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize)] +#[serde(default)] +pub struct Assistance { + /// Add (menu, toolbar, Insert, row menu) opens the New Activity wizard. + pub activity_wizard: bool, + /// The Resources view's Add opens the New Resource wizard. + pub resource_wizard: bool, +} + +impl Default for Assistance { + /// Both on, as on a first start. + fn default() -> Self { + Self { + activity_wizard: true, + resource_wizard: true, + } + } +} + +impl Assistance { + /// The stored form; anything unreadable counts as the defaults. + pub fn from_json(text: &str) -> Self { + serde_json::from_str(text).unwrap_or_default() + } + pub fn to_json(self) -> String { + serde_json::to_string(&self).unwrap_or_default() + } + /// The switch a preference name stands for. + fn switch(&mut self, name: &str) -> Result<&mut bool> { + match name + .trim() + .to_ascii_lowercase() + .replace([' ', '-'], "_") + .as_str() + { + "new_activity_wizard" | "activity_wizard" => Ok(&mut self.activity_wizard), + "new_resource_wizard" | "resource_wizard" => Ok(&mut self.resource_wizard), + _ => Err(AutomationError::new( + "invalid_arguments", + format!( + "{name:?} is not a preference; use new_activity_wizard or new_resource_wizard" + ), + )), + } + } + fn json(self) -> Value { + json!({ + "new_activity_wizard": self.activity_wizard, + "new_resource_wizard": self.resource_wizard, + }) + } +} + +fn read(c: &Connection) -> Result { + let has_table = c + .query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name='preferences'", + [], + |_| Ok(()), + ) + .optional() + .map_err(invalid)? + .is_some(); + if !has_table { + return Ok(Assistance::default()); + } + let text: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [ASSISTANCE_KEY], + |r| r.get(0), + ) + .optional() + .map_err(invalid)?; + Ok(text.map_or_else(Assistance::default, |t| Assistance::from_json(&t))) +} + +/// `workspace preference`: the Assistance switches of a workspace, or one +/// of them set (`name`, `value`) in a copy written to `output` (`dry_run` +/// reports the change and writes nothing). +pub fn preference( + input: &Path, + name: Option<&str>, + value: Option, + output: Option, + dry_run: bool, +) -> Result { + let args = |m: &str| AutomationError::new("invalid_arguments", m.to_string()); + if !storage::is_database(input)? { + return Err(args( + "workspace preference needs an OpenXER workspace database (.db)", + )); + } + let Some(value) = value else { + if output.is_some() || dry_run { + return Err(args("output and dry_run go with value")); + } + let mut now = read(&storage::read_database(input)?)?; + return Ok(match name { + Some(name) => json!({"input": input, "name": name, "value": *now.switch(name)?}), + None => json!({"input": input, "preferences": now.json()}), + }); + }; + let name = name.ok_or_else(|| args("value needs name"))?; + match (&output, dry_run) { + (Some(_), true) => return Err(args("dry_run writes nothing; omit output")), + (None, false) => return Err(args("output is required unless dry_run is true")), + (Some(path), false) => { + storage::check_destination(path)?; + if !storage::is_database_extension(path) { + return Err(args( + "workspace preference writes an OpenXER workspace (.db/.sqlite/.sqlite3)", + )); + } + } + (None, true) => {} + } + let source = storage::read_database(input)?; + let before = read(&source)?; + let mut after = before; + *after.switch(name)? = value; + if let Some(path) = &output { + let temp = tempfile::NamedTempFile::new_in(parent(path)).map_err(io)?; + source.backup("main", temp.path(), None).map_err(io)?; + drop(source); + let c = Connection::open(temp.path()).map_err(io)?; + c.execute( + "CREATE TABLE IF NOT EXISTS preferences(key TEXT PRIMARY KEY,value TEXT NOT NULL)", + [], + ) + .map_err(io)?; + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO UPDATE SET value=excluded.value", + params![ASSISTANCE_KEY, after.to_json()], + ) + .map_err(io)?; + c.close().map_err(|(_, e)| io(e))?; + storage::publish(temp, path)?; + } + Ok(json!({ + "input": input, + "output": output, + "dry_run": dry_run, + "name": name, + "before": *before.clone().switch(name)?, + "value": value, + "preferences": after.json(), + })) +} + +#[cfg(test)] +mod tests { + use super::*; + + fn workspace(dir: &Path) -> PathBuf { + let path = dir.join("ws.db"); + let c = Connection::open(&path).unwrap(); + c.execute_batch( + "CREATE TABLE projects(id INTEGER PRIMARY KEY,source_name TEXT NOT NULL,project_key INTEGER NOT NULL,title TEXT NOT NULL,xer_content TEXT NOT NULL,updated_at TEXT DEFAULT CURRENT_TIMESTAMP,source_windows_encoding INTEGER NOT NULL DEFAULT 0,level_resources INTEGER NOT NULL DEFAULT 0,UNIQUE(source_name,project_key));CREATE TABLE preferences(key TEXT PRIMARY KEY,value TEXT NOT NULL);", + ) + .unwrap(); + path + } + + #[test] + fn the_wizard_switch_reads_on_by_default_and_is_set_in_a_copy() { + let dir = tempfile::tempdir().unwrap(); + let input = workspace(dir.path()); + let now = preference(&input, None, None, None, false).unwrap(); + assert_eq!(now["preferences"]["new_activity_wizard"], true); + // A dry run changes nothing. + let dry = preference(&input, Some("new_activity_wizard"), Some(false), None, true).unwrap(); + assert_eq!(dry["before"], true); + assert_eq!(dry["preferences"]["new_activity_wizard"], false); + let output = dir.path().join("out.db"); + preference( + &input, + Some("new-activity-wizard"), + Some(false), + Some(output.clone()), + false, + ) + .unwrap(); + let read_back = + preference(&output, Some("new_activity_wizard"), None, None, false).unwrap(); + assert_eq!(read_back["value"], false); + let input_now = preference(&input, None, None, None, false).unwrap(); + assert_eq!( + input_now["preferences"]["new_activity_wizard"], true, + "input untouched" + ); + // The row is the one the app reads. + let c = Connection::open(&output).unwrap(); + let text: String = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [ASSISTANCE_KEY], + |r| r.get(0), + ) + .unwrap(); + assert_eq!( + Assistance::from_json(&text), + Assistance { + activity_wizard: false, + resource_wizard: true + } + ); + // Refusals: an unknown name, value without output or dry run. + assert!(preference(&input, Some("colors"), Some(true), None, true).is_err()); + assert!(preference(&input, Some("new_activity_wizard"), Some(true), None, false).is_err()); + } +} diff --git a/automation/src/workspace_cmd.rs b/automation/src/workspace_cmd.rs new file mode 100644 index 0000000..24adaf5 --- /dev/null +++ b/automation/src/workspace_cmd.rs @@ -0,0 +1,396 @@ +//! `workspace` commands on an OpenXER workspace database: `migrate` (see +//! `storage::workspace_migrate`), `dictionary` (list the shared workspace +//! dictionary), `dictionary-usage` (which projects use one of its rows) and +//! `preference` (the User Preferences, Assistance switches, see +//! `user_prefs`). +//! The command line and the MCP tools come from the same definitions here. +use crate::storage::{self, invalid}; +use crate::workspace_db; +use crate::{AutomationError, Result}; +use openxer_xer::workspace_scope::{self, merge::display_name}; +use openxer_xer::Table; +use serde_json::{json, Map, Value}; +use std::collections::BTreeMap; +use std::path::Path; + +/// Plain names a person may give for a dictionary table, with the table. +const KINDS: &[(&str, &str)] = &[ + ("calendar", "CALENDAR"), + ("calendars", "CALENDAR"), + ("resource", "RSRC"), + ("resources", "RSRC"), + ("role", "ROLES"), + ("roles", "ROLES"), + ("activity_code", "ACTVTYPE"), + ("activity_codes", "ACTVTYPE"), + ("code", "ACTVTYPE"), + ("codes", "ACTVTYPE"), + ("code_value", "ACTVCODE"), + ("code_values", "ACTVCODE"), + ("udf", "UDFTYPE"), + ("udfs", "UDFTYPE"), + ("user_defined_field", "UDFTYPE"), + ("account", "ACCOUNT"), + ("accounts", "ACCOUNT"), + ("cost_account", "ACCOUNT"), + ("obs", "OBS"), + ("currency", "CURRTYPE"), + ("currencies", "CURRTYPE"), +]; + +/// The dictionary table `name` names (a table name or a plain kind such as +/// `calendar`). +pub fn table_of(name: &str) -> Result<&'static str> { + let key = name.trim().to_ascii_lowercase().replace([' ', '-'], "_"); + if let Some((_, t)) = KINDS.iter().find(|(k, _)| *k == key) { + return Ok(t); + } + workspace_scope::WORKSPACE_TABLES + .iter() + .map(|(t, _)| *t) + .find(|t| t.eq_ignore_ascii_case(name.trim())) + .ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!("{name:?} is not a workspace dictionary table; use calendar, resource, role, activity_code, code_value, udf, account or a table name such as RSRCRATE"), + ) + }) +} + +/// Choices for an import's dictionary rows whose name the workspace has +/// with different content: `KIND=copy|keep|update,...`. +pub fn parse_choices(text: &str) -> Result { + let mut out = workspace_db::Choices::new(); + for part in text.split(',').map(str::trim).filter(|s| !s.is_empty()) { + let (kind, choice) = part.split_once('=').ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!("{part:?}: write KIND=copy, KIND=keep or KIND=update"), + ) + })?; + let choice = + openxer_xer::workspace_scope::merge::Choice::parse(choice).ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!("{choice:?} is not copy, keep or update"), + ) + })?; + out.insert(table_of(kind)?.to_string(), choice); + } + Ok(out) +} + +fn shared_database(input: &Path) -> Result { + if !storage::is_database(input)? { + return Err(AutomationError::new( + "invalid_arguments", + "workspace dictionary needs an OpenXER workspace database (.db)", + )); + } + let c = storage::read_database(input)?; + if !storage::shared(&c)? { + return Err(AutomationError::new( + "workspace_needs_migration", + "This workspace keeps calendars, resources and codes inside each project (workspace schema 1); `workspace migrate` converts it to a shared dictionary.", + )); + } + Ok(c) +} + +/// The name of a dictionary row as people know it. +fn row_name(t: &Table, r: &[String]) -> String { + match t.name.to_ascii_uppercase().as_str() { + "ACTVCODE" => t.value(r, "short_name").to_string(), + "UDFTYPE" => t.value(r, "udf_type_label").to_string(), + _ => display_name(t, r), + } +} + +fn row_json(t: &Table, r: &[String], used: &BTreeMap<(String, i64), Vec>) -> Value { + let table = t.name.to_ascii_uppercase(); + let id = workspace_scope::key_column(&table) + .and_then(|k| t.field(k)) + .and_then(|k| r[k].trim().parse::().ok()); + let mut v = json!({"name": row_name(t, r)}); + if let Some(id) = id { + v["id"] = json!(id); + v["used_by"] = json!(used.get(&(table.clone(), id)).cloned().unwrap_or_default()); + } + if table == "ACTVTYPE" { + v["scope"] = json!(match t.value(r, "actv_code_type_scope") { + "AS_EPS" => "eps", + _ => "global", + }); + if t.value(r, "actv_code_type_scope") == "AS_EPS" { + v["eps_node"] = json!(t.value(r, "wbs_id")); + } + } + if table == "CALENDAR" { + v["type"] = json!(t.value(r, "clndr_type")); + v["default"] = json!(t.value(r, "default_flag") == "Y"); + } + if table == "ACTVCODE" { + v["code_type_id"] = json!(t.value(r, "actv_code_type_id")); + } + v +} + +/// `workspace dictionary`: the shared dictionary's rows (optionally of one +/// table), each with the workspace projects that use it. +pub fn dictionary(input: &Path, table: Option<&str>) -> Result { + let c = shared_database(input)?; + let only = table.map(table_of).transpose()?; + let (dict, revision) = workspace_db::read_dictionary(&c).map_err(invalid)?; + let users: BTreeMap<(String, i64), Vec> = workspace_db::users(&c, None) + .map_err(invalid)? + .into_iter() + .map(|(k, v)| (k, v.into_iter().collect())) + .collect(); + let mut tables = vec![]; + for t in &dict.tables { + let name = t.name.to_ascii_uppercase(); + if only.is_some_and(|o| o != name) || t.rows.is_empty() { + continue; + } + tables.push(json!({ + "table": name, + "kind": workspace_db::kind_label(&name), + "count": t.rows.len(), + "rows": t.rows.iter().map(|r| row_json(t, r, &users)).collect::>(), + })); + } + Ok(json!({ + "input": input, + "workspace_schema": workspace_db::DICTIONARY_SCHEMA, + "revision": revision, + "tables": tables, + })) +} + +/// `workspace dictionary-usage`: the projects that use one dictionary row, +/// named by id or by name. +pub fn dictionary_usage( + input: &Path, + table: &str, + id: Option, + name: Option<&str>, +) -> Result { + let c = shared_database(input)?; + let table = table_of(table)?; + let (dict, _) = workspace_db::read_dictionary(&c).map_err(invalid)?; + let t = dict.table(table); + let key = workspace_scope::key_column(table).ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!("{table} rows have no id of their own; ask about their owner row"), + ) + })?; + let found: Vec<(i64, String)> = t + .map(|t| { + let k = t.field(key); + t.rows + .iter() + .filter_map(|r| { + let rid = k.and_then(|k| r[k].trim().parse::().ok())?; + let n = row_name(t, r); + let hit = match (id, name) { + (Some(i), _) => i == rid, + (None, Some(n2)) => n.eq_ignore_ascii_case(n2.trim()), + (None, None) => false, + }; + hit.then_some((rid, n)) + }) + .collect() + }) + .unwrap_or_default(); + if id.is_none() && name.is_none() { + return Err(AutomationError::new( + "invalid_arguments", + "dictionary-usage needs id or name", + )); + } + let (rid, rname) = match found.as_slice() { + [one] => one.clone(), + [] => { + return Err(AutomationError::new( + "not_found", + format!("No {table} row matches in the workspace dictionary"), + )) + } + _ => { + return Err(AutomationError::new( + "ambiguous", + format!("Several {table} rows have that name; pass id"), + )) + } + }; + let used = workspace_db::dictionary_usage(&c, table, rid, None).map_err(invalid)?; + Ok(json!({ + "input": input, + "table": table, + "kind": workspace_db::kind_label(table), + "id": rid, + "name": rname, + "used_by": used.iter().map(|(w, n)| json!({"workspace_id": w, "name": n})).collect::>(), + "in_use": !used.is_empty(), + })) +} + +/// The `workspace` command line: `migrate`, `dictionary`, +/// `dictionary-usage`. Returns the request for the shared dispatcher. +pub fn parse_cli( + args: &[String], + flags: impl Fn(&[String], &[&str]) -> Result>, +) -> Result { + let sub = args.first().map(String::as_str).unwrap_or(""); + let rest = args.get(1..).unwrap_or(&[]); + let mut request = Map::new(); + let input = |fields: &BTreeMap| { + fields.get("input").cloned().ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + format!("workspace {sub} requires --input"), + ) + }) + }; + match sub { + "migrate" => { + let fields = flags(rest, &["input", "output", "dry-run"])?; + request.insert("command".into(), Value::from("workspace_migrate")); + request.insert("input".into(), Value::from(input(&fields)?)); + if let Some(output) = fields.get("output") { + request.insert("output".into(), Value::from(output.as_str())); + } + let dry_run = match fields.get("dry-run").map(String::as_str) { + None | Some("false") => false, + Some("true") => true, + Some(other) => { + return Err(AutomationError::new( + "invalid_arguments", + format!("--dry-run takes true or false, not {other:?}"), + )) + } + }; + if dry_run == fields.contains_key("output") { + return Err(AutomationError::new( + "invalid_arguments", + "workspace migrate requires exactly one of --output or --dry-run", + )); + } + request.insert("dry_run".into(), Value::from(dry_run)); + } + "dictionary" => { + let fields = flags(rest, &["input", "table"])?; + request.insert("command".into(), Value::from("workspace_dictionary")); + request.insert("input".into(), Value::from(input(&fields)?)); + if let Some(t) = fields.get("table") { + request.insert("table".into(), Value::from(t.as_str())); + } + } + "dictionary-usage" => { + let fields = flags(rest, &["input", "table", "id", "name"])?; + request.insert("command".into(), Value::from("workspace_dictionary_usage")); + request.insert("input".into(), Value::from(input(&fields)?)); + let table = fields.get("table").ok_or_else(|| { + AutomationError::new( + "invalid_arguments", + "workspace dictionary-usage requires --table", + ) + })?; + request.insert("table".into(), Value::from(table.as_str())); + if let Some(id) = fields.get("id") { + let id: i64 = id.parse().map_err(|_| { + AutomationError::new( + "invalid_arguments", + format!("--id {id:?} is not an integer"), + ) + })?; + request.insert("id".into(), Value::from(id)); + } + if let Some(n) = fields.get("name") { + request.insert("name".into(), Value::from(n.as_str())); + } + if !fields.contains_key("id") && !fields.contains_key("name") { + return Err(AutomationError::new( + "invalid_arguments", + "workspace dictionary-usage requires --id or --name", + )); + } + } + "preference" => { + let fields = flags(rest, &["input", "name", "value", "output", "dry-run"])?; + request.insert("command".into(), Value::from("workspace_preference")); + request.insert("input".into(), Value::from(input(&fields)?)); + let flag = |key: &str| -> Result> { + match fields.get(key).map(String::as_str) { + None => Ok(None), + Some("true") => Ok(Some(true)), + Some("false") => Ok(Some(false)), + Some(other) => Err(AutomationError::new( + "invalid_arguments", + format!("--{key} takes true or false, not {other:?}"), + )), + } + }; + if let Some(n) = fields.get("name") { + request.insert("name".into(), Value::from(n.as_str())); + } + if let Some(v) = flag("value")? { + request.insert("value".into(), Value::from(v)); + } + if let Some(output) = fields.get("output") { + request.insert("output".into(), Value::from(output.as_str())); + } + request.insert( + "dry_run".into(), + Value::from(flag("dry-run")?.unwrap_or(false)), + ); + } + _ => { + return Err(AutomationError::new( + "invalid_arguments", + "workspace requires migrate, dictionary, dictionary-usage or preference", + )) + } + } + Ok(Value::Object(request)) +} + +/// The MCP tool name of each `workspace` command. +pub const TOOLS: &[(&str, &str)] = &[ + ("openxer_workspace_migrate", "workspace_migrate"), + ("openxer_workspace_dictionary", "workspace_dictionary"), + ( + "openxer_workspace_dictionary_usage", + "workspace_dictionary_usage", + ), + ("openxer_workspace_preference", "workspace_preference"), +]; + +/// The MCP tool definitions of the `workspace` commands. +pub fn tool_definitions() -> Vec { + let output = json!({"type":"object","properties":{"schema_version":{"type":"string"},"ok":{"type":"boolean"},"result":{"type":"object"},"error":{"type":"object"}},"required":["schema_version","ok"]}); + let input = json!({"type":"string","minLength":1,"description":"OpenXER workspace database path; read-only"}); + let table = json!({"type":"string","minLength":1,"description":"calendar, resource, role, activity_code, code_value, udf, account, or a dictionary table name such as RSRCRATE"}); + let read = json!({"readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}); + vec![ + json!({"name":"openxer_workspace_migrate", + "description":"Move a workspace that keeps calendars, resources, codes and the other dictionaries inside each project (workspace schema 1) to one shared workspace dictionary (schema 3). dry_run reports the plan per project (rows shared, added, renumbered, kept as renamed copies with the fields that differ); otherwise the converted copy is written to output and the input stays as its backup. Every project is checked first: same rows and the same dates and float, unleveled and leveled.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{"input":input,"output":{"type":"string","minLength":1,"description":"New workspace path for the converted copy; existing files are refused. Omit with dry_run"},"dry_run":{"type":"boolean","default":false}},"required":["input"]}, + "outputSchema":output, + "annotations":{"readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false}}), + json!({"name":"openxer_workspace_dictionary", + "description":"List the shared workspace dictionary of an OpenXER workspace (schema 3): global calendars, resources and rates, roles, global and EPS activity codes and values, UDFs, cost accounts and the other workspace tables, each row with its id, name and the workspace ids of the projects that use it. table limits the list to one table.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{"input":input,"table":table},"required":["input"]}, + "outputSchema":output,"annotations":read}), + json!({"name":"openxer_workspace_dictionary_usage", + "description":"Which workspace projects use one row of the shared workspace dictionary (named by table and id or name). A row in use cannot be deleted in the app.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{"input":input,"table":table,"id":{"type":"integer"},"name":{"type":"string","minLength":1}},"required":["input","table"]}, + "outputSchema":output,"annotations":read}), + json!({"name":"openxer_workspace_preference", + "description":"The app's User Preferences, Assistance tab, kept in a workspace: new_activity_wizard (on by default: Edit > Add opens the New Activity wizard; off: Add inserts the row at once) and new_resource_wizard (on by default: the Resources view's Add opens the New Resource wizard; off: Add inserts the resource at once). Without value it reads them; with name and value it writes a copy to output with that switch set, or with dry_run reports the change. The app reads the switch when it starts.", + "inputSchema":{"type":"object","additionalProperties":false,"properties":{"input":input,"name":{"type":"string","enum":["new_activity_wizard","new_resource_wizard"]},"value":{"type":"boolean"},"output":{"type":"string","minLength":1,"description":"New workspace path for the copy; existing files are refused. Omit with dry_run"},"dry_run":{"type":"boolean","default":false}},"required":["input"]}, + "outputSchema":output, + "annotations":{"readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false}}), + ] +} diff --git a/automation/src/workspace_db.rs b/automation/src/workspace_db.rs new file mode 100644 index 0000000..6edf1ac --- /dev/null +++ b/automation/src/workspace_db.rs @@ -0,0 +1,953 @@ +//! The workspace dictionary of an OpenXER database (workspace schema 3). +//! +//! A version 3 workspace keeps the workspace rows of every project (global +//! calendars, resources, roles, global and EPS codes, UDFs and the other enterprise +//! tables, see `openxer_xer::workspace_scope`) once, in `workspace_dictionary`, +//! and each project's stored text without them. Opening a project hydrates +//! the dictionary into its document; saving merges the project's workspace +//! rows back and stores the rest. `workspace_keys` holds the highest id each +//! workspace table has used, so a new row never takes an id another project +//! holds. A version 1 workspace (no `workspace_schema` preference) keeps +//! whole XER text per project and is read and written as before. A version +//! 2 workspace (earlier builds: EPS codes stayed in each project's text) is +//! upgraded by [`migrate`] before it is used. +//! +//! The desktop store and the command line share these functions. +use openxer_xer::workspace::Workspace; +use openxer_xer::workspace_scope::merge::{Choice, Event, EventKind, Merger, Outcome, Policy}; +use openxer_xer::workspace_scope::{self, referenced_ids, table_highs, EpsPlace}; +use openxer_xer::Document; +use rusqlite::{params, Connection, OptionalExtension}; +use std::collections::{BTreeMap, BTreeSet}; + +/// Preference naming the workspace schema; absent means version 1. +pub const SCHEMA_KEY: &str = "workspace_schema"; +/// The schema with a workspace dictionary that also holds EPS code types. +pub const DICTIONARY_SCHEMA: i64 = 3; +/// The schema earlier builds wrote: a workspace dictionary without the EPS +/// code types, which stay in each project's text. Read only to upgrade it +/// ([`migrate`]); a build that knows only this schema refuses schema 3. +pub const EARLIER_DICTIONARY_SCHEMA: i64 = 2; + +type R = Result; + +fn err(e: impl std::fmt::Display) -> String { + e.to_string() +} + +/// The workspace schema of a database: 1 unless the preference says otherwise. +pub fn schema(c: &Connection) -> R { + let has_preferences: bool = c + .query_row( + "SELECT 1 FROM sqlite_master WHERE type='table' AND name='preferences'", + [], + |_| Ok(()), + ) + .optional() + .map_err(err)? + .is_some(); + if !has_preferences { + return Ok(1); + } + let value: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [SCHEMA_KEY], + |r| r.get(0), + ) + .optional() + .map_err(err)?; + match value { + None => Ok(1), + Some(v) => v + .trim() + .parse() + .map_err(|_| format!("The workspace schema \"{v}\" is not a number.")), + } +} + +/// Make a database that has just been created a schema 3 workspace: new +/// workspaces keep one shared dictionary from the start. Call it only when +/// the `projects` table did not exist before; an existing version 1 +/// workspace stays as it is until it is converted ([`migrate`]). +pub fn start_new(c: &Connection) -> R<()> { + ensure(c)?; + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO NOTHING", + params![SCHEMA_KEY, DICTIONARY_SCHEMA.to_string()], + ) + .map(|_| ()) + .map_err(err) +} + +/// Create the dictionary tables when missing. +pub fn ensure(c: &Connection) -> R<()> { + c.execute_batch( + "CREATE TABLE IF NOT EXISTS workspace_dictionary(id INTEGER PRIMARY KEY CHECK(id=1), xer_content TEXT NOT NULL, revision INTEGER NOT NULL DEFAULT 0); + CREATE TABLE IF NOT EXISTS workspace_keys(table_name TEXT PRIMARY KEY, high INTEGER NOT NULL);", + ) + .map_err(err) +} + +/// Header of a dictionary that has no text yet. +const HEADER: &str = + "ERMHDR\t25.12\t2026-11-08\tProject\tOpenXER\tOpenXER\tdbxDatabaseNoName\tProject Management\tUSD"; + +fn empty_dictionary() -> Document { + Document::parse(&format!("{HEADER}\r\n%E\r\n")).expect("the empty dictionary parses") +} + +/// A database that has no dictionary tables yet reads as an empty one. +fn missing_table(e: rusqlite::Error) -> Result, rusqlite::Error> { + match e { + rusqlite::Error::SqliteFailure(_, Some(ref m)) if m.contains("no such table") => Ok(None), + e => Err(e), + } +} + +/// The stored dictionary and its revision (an empty one at revision 0). +pub fn read_dictionary(c: &Connection) -> R<(Document, i64)> { + let row: Option<(String, i64)> = c + .query_row( + "SELECT xer_content,revision FROM workspace_dictionary WHERE id=1", + [], + |r| Ok((r.get(0)?, r.get(1)?)), + ) + .optional() + .or_else(missing_table) + .map_err(err)?; + match row { + Some((text, revision)) => Ok(( + Document::parse(&text).map_err(|e| format!("The workspace dictionary: {e}"))?, + revision, + )), + None => Ok((empty_dictionary(), 0)), + } +} + +/// The dictionary's revision alone (0 when there is none yet). +pub fn read_revision(c: &Connection) -> R { + c.query_row( + "SELECT revision FROM workspace_dictionary WHERE id=1", + [], + |r| r.get(0), + ) + .optional() + .or_else(|e| match e { + rusqlite::Error::SqliteFailure(..) => Ok(None), + e => Err(e), + }) + .map(|r| r.unwrap_or(0)) + .map_err(err) +} + +/// The highest id each workspace table has used. +pub fn read_keys(c: &Connection) -> R> { + let Some(mut stmt) = c + .prepare("SELECT table_name,high FROM workspace_keys") + .map(Some) + .or_else(missing_table) + .map_err(err)? + else { + return Ok(BTreeMap::new()); + }; + let rows = stmt + .query_map([], |r| Ok((r.get::<_, String>(0)?, r.get::<_, i64>(1)?))) + .map_err(err)?; + rows.collect::, _>>().map_err(err) +} + +/// Raise the stored highs to at least `highs`. +fn raise_keys(c: &Connection, highs: &BTreeMap) -> R<()> { + for (table, high) in highs { + c.execute( + "INSERT INTO workspace_keys(table_name,high) VALUES(?1,?2) ON CONFLICT(table_name) DO UPDATE SET high=MAX(high,excluded.high)", + params![table, high], + ) + .map_err(err)?; + } + Ok(()) +} + +fn write_dictionary(c: &Connection, dict: &Document, revision: i64) -> R<()> { + c.execute( + "INSERT INTO workspace_dictionary(id,xer_content,revision) VALUES(1,?1,?2) ON CONFLICT(id) DO UPDATE SET xer_content=excluded.xer_content,revision=excluded.revision", + params![dict.text(), revision], + ) + .map(|_| ()) + .map_err(err) +} + +/// Write `dict` as the dictionary at the next revision (when it differs +/// from the stored one) and raise the key highs to cover it. Returns the +/// revision it is stored at. +pub fn replace_dictionary(c: &Connection, dict: &Document) -> R { + ensure(c)?; + let (stored, revision) = read_dictionary(c)?; + if stored.text() == dict.text() { + return Ok(revision); + } + write_dictionary(c, dict, revision + 1)?; + raise_keys(c, &table_highs(dict))?; + Ok(revision + 1) +} + +/// What a project read from the dictionary when it was opened. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct Mark { + /// The dictionary revision it was read at. + pub revision: i64, + /// The dictionary rows it holds, as (table, id). + pub rows: BTreeSet<(String, i64)>, +} + +/// The workspace EPS of a database (its preference row; the default tree +/// when there is none). +pub fn read_eps(c: &Connection) -> R { + let text: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [openxer_xer::workspace::KEY], + |r| r.get(0), + ) + .optional() + .or_else(|e| match e { + rusqlite::Error::SqliteFailure(..) => Ok(None), + e => Err(e), + }) + .map_err(err)?; + Ok(Workspace::from_text(&text.unwrap_or_default())) +} + +/// Where workspace project `row` sits in the EPS (the first top-level node +/// for a project not stored yet). +pub fn eps_place(c: &Connection, row: Option) -> R { + Ok(place_in(&read_eps(c)?, row)) +} + +/// [`eps_place`] in an EPS already read. +pub fn place_in(ws: &Workspace, row: Option) -> EpsPlace { + let node = ws.node_of(row); + EpsPlace { + node, + visible: ws.lineage(node).into_iter().collect(), + nodes: ws.eps().iter().map(|n| n.id).collect(), + } +} + +/// Add the dictionary's rows to a project's document read from its stored +/// text, and set its id floors. `row` is the project's workspace row: it sees +/// only the EPS code types of its EPS node and those above (every one when +/// `None`). Returns what it read. +pub fn hydrate(c: &Connection, doc: &mut Document, row: Option) -> R { + let (dict, revision) = read_dictionary(c)?; + hydrate_with(c, doc, row, &dict, revision) +} + +/// [`hydrate`] with the dictionary already read. +pub fn hydrate_with( + c: &Connection, + doc: &mut Document, + row: Option, + dict: &Document, + revision: i64, +) -> R { + let keys = read_keys(c)?; + let visible = match row { + Some(_) => Some(eps_place(c, row)?.visible), + None => None, + }; + let report = workspace_scope::hydrate_for(doc, dict, visible.as_ref()); + let mut floor = keys; + for (t, high) in table_highs(dict) { + let e = floor.entry(t).or_insert(high); + *e = (*e).max(high); + } + doc.id_floor = floor; + if !report.shadowed.is_empty() { + let shown: Vec = report + .shadowed + .iter() + .take(5) + .map(|(t, id)| format!("{t} {id}")) + .collect(); + doc.warnings.push(format!( + "{} workspace rows share an id with this project's own rows; the project's rows are used ({}).", + report.shadowed.len(), + shown.join(", ") + )); + } + Ok(Mark { + revision, + rows: report.added, + }) +} + +/// A project as `store` wrote it. +#[derive(Clone, Debug)] +pub struct Stored { + /// The project text without workspace rows, to store in `projects`. + pub text: String, + /// What the project now holds of the dictionary, by the ids of the + /// document that was saved. + pub mark: Mark, + pub outcome: Outcome, + /// Rows the project deleted that another project still uses, kept. + pub kept_in_use: Vec<(String, i64)>, + /// EPS code types moved to the project's EPS node ([`EpsPlace`]). + pub placed: usize, +} + +impl Stored { + /// Whether the saved document differs from the one given to [`store`] + /// (rows renumbered, renamed, matched to stored rows or moved), so an + /// open project should take `outcome.document`. + pub fn changed_document(&self) -> bool { + self.placed > 0 + || self + .outcome + .events + .iter() + .any(|e| e.kind != openxer_xer::workspace_scope::merge::EventKind::Added) + } +} + +/// Each workspace row the stored projects other than `except` refer to, +/// with the workspace ids of those projects. +pub fn users(c: &Connection, except: Option) -> R>> { + let mut stmt = c + .prepare("SELECT id,xer_content FROM projects") + .map_err(err)?; + let rows = stmt + .query_map([], |r| Ok((r.get::<_, i64>(0)?, r.get::<_, String>(1)?))) + .map_err(err)?; + let mut out: BTreeMap<(String, i64), BTreeSet> = BTreeMap::new(); + for row in rows { + let (id, text) = row.map_err(err)?; + if Some(id) == except { + continue; + } + if let Ok(doc) = Document::parse(&text) { + for k in referenced_ids(&doc) { + out.entry(k).or_default().insert(id); + } + } + } + Ok(out) +} + +/// Workspace project titles by id. +pub fn titles(c: &Connection) -> R> { + let mut stmt = c.prepare("SELECT id,title FROM projects").map_err(err)?; + let rows = stmt + .query_map([], |r| Ok((r.get::<_, i64>(0)?, r.get::<_, String>(1)?))) + .map_err(err)?; + rows.collect::, _>>().map_err(err) +} + +/// The stored projects (workspace id and title) that use dictionary row +/// `table` `id`, other than `except`. +pub fn dictionary_usage( + c: &Connection, + table: &str, + id: i64, + except: Option, +) -> R> { + let users = users(c, except)?; + let titles = titles(c)?; + Ok(users + .get(&(table.to_ascii_uppercase(), id)) + .map(|ids| { + ids.iter() + .map(|i| (*i, titles.get(i).cloned().unwrap_or_default())) + .collect() + }) + .unwrap_or_default()) +} + +/// What kind of dictionary row a table holds, for messages. +pub fn kind_label(table: &str) -> &'static str { + match table.to_ascii_uppercase().as_str() { + "CALENDAR" => "Calendar", + "RSRC" => "Resource", + "ROLES" => "Role", + "ACTVTYPE" => "Activity code", + "ACTVCODE" => "Activity code value", + "UDFTYPE" => "User defined field", + "ACCOUNT" => "Cost account", + "OBS" => "Responsible manager", + "CURRTYPE" => "Currency", + "UMEASURE" => "Unit of measure", + "SHIFT" => "Shift", + "RSRCCURVDATA" => "Resource curve", + "FUNDSRC" => "Funding source", + "FINTMPL" => "Financial period calendar", + "RCATTYPE" => "Resource code", + "PCATTYPE" => "Project code", + "ROLECATTYPE" => "Role code", + "ASGNMNTCATTYPE" => "Assignment code", + "MEMOTYPE" => "Notebook topic", + "COSTTYPE" => "Expense category", + "DOCCATG" => "Document category", + "DOCSTAT" => "Document status", + "RISKTYPE" => "Risk category", + "BASETYPE" => "Baseline type", + "THRSPARM" => "Threshold parameter", + "NONWORK" => "Nonwork type", + "PROCGROUP" => "Step template", + _ => "Dictionary row", + } +} + +/// One line per dictionary decision of an import a person should know +/// about: a row whose name the workspace has with different content (added +/// as a copy, kept or updated, with the fields that differ), then a count of +/// the rows that were the workspace's own already. +pub fn import_report(events: &[Event]) -> Vec { + let mut out = vec![]; + let differs = |e: &Event| { + if e.differences.is_empty() { + "its rates, periods or values".to_string() + } else { + e.differences.join(", ") + } + }; + for e in events { + let kind = kind_label(&e.table); + match e.kind { + EventKind::Copied => out.push(format!( + "{kind} \"{}\" is added as \"{}\": it differs from the workspace's in {}.", + e.name, + e.renamed.as_deref().unwrap_or(&e.name), + differs(e) + )), + EventKind::Kept => out.push(format!( + "{kind} \"{}\": the workspace's is kept (the file's differs in {}).", + e.name, + differs(e) + )), + EventKind::Updated => out.push(format!( + "{kind} \"{}\": the workspace's takes the file's values ({}); every project that uses it sees them.", + e.name, + differs(e) + )), + _ => {} + } + } + let shared = events + .iter() + .filter(|e| e.kind == EventKind::Merged) + .count(); + let added = events + .iter() + .filter(|e| { + matches!(e.kind, EventKind::Added | EventKind::Renumbered) && !e.name.is_empty() + }) + .count(); + if shared + added > 0 { + out.push(format!( + "{added} new dictionary row(s) added, {shared} already the workspace's." + )); + } + out +} + +/// The tables whose rows an import would add as copies (or keep or update), +/// from its events: where a Keep or Update choice applies. +pub fn clash_tables(events: &[Event]) -> BTreeSet { + events + .iter() + .filter(|e| { + matches!( + e.kind, + EventKind::Copied | EventKind::Kept | EventKind::Updated + ) + }) + .map(|e| e.table.to_ascii_uppercase()) + .collect() +} + +/// What storing these projects one after another would decide, without +/// writing anything: each project's merge events. Each entry is the +/// project's document, what it read from the dictionary and its workspace +/// row. +pub fn preview( + c: &Connection, + projects: &[(&Document, Option<&Mark>, Option)], + choices: &Choices, +) -> R>> { + c.execute_batch("SAVEPOINT openxer_preview").map_err(err)?; + let result = (|| { + let mut out = vec![]; + for (doc, mark, row) in projects { + let stored = store_with(c, doc, *mark, *row, &Policy::Save, choices)?; + out.push(stored.outcome.events); + } + Ok(out) + })(); + c.execute_batch("ROLLBACK TO openxer_preview; RELEASE openxer_preview") + .map_err(err)?; + result +} + +/// The name a person knows dictionary row `table` `id` by (its id when it +/// has no name), with what kind of row it is. +pub fn row_label(dict: &Document, table: &str, id: i64) -> String { + let kind = kind_label(table); + let name = dict + .table(table) + .and_then(|t| { + let k = workspace_scope::key_column(table).and_then(|k| t.field(k))?; + let r = t.rows.iter().find(|r| r[k].trim() == id.to_string())?; + let column = match table.to_ascii_uppercase().as_str() { + "ACTVCODE" => "short_name", + "UDFTYPE" => "udf_type_label", + _ => "", + }; + let n = if column.is_empty() { + workspace_scope::merge::display_name(t, r) + } else { + t.value(r, column).to_string() + }; + (!n.is_empty()).then_some(n) + }) + .unwrap_or_else(|| format!("{table} {id}")); + format!("{kind} \"{name}\"") +} + +/// The rows `delta`, applied to `dict` `forward` (redo) or backward (undo), +/// would remove that something still uses, with who uses each by name: a +/// stored project other than `except`, one of `open` (open projects with +/// their workspace ids, which may hold unsaved uses; one whose id is +/// `except` is skipped), or a dictionary row the delta keeps. +pub fn removals_in_use( + c: &Connection, + dict: &Document, + delta: &workspace_scope::delta::Delta, + forward: bool, + except: Option, + open: &[(Option, &Document)], +) -> R>> { + let removes: BTreeSet<(String, i64)> = delta.removes(forward).into_iter().collect(); + let mut out: BTreeMap<(String, i64), Vec> = BTreeMap::new(); + if removes.is_empty() { + return Ok(out); + } + let titles = titles(c)?; + let mut users = users(c, except)?; + for (id, doc) in open { + if id.is_some() && *id == except { + continue; + } + for k in referenced_ids(doc) { + users.entry(k).or_default().insert(id.unwrap_or(-1)); + } + } + for k in &removes { + if let Some(ids) = users.get(k) { + let mut names: Vec = ids + .iter() + .map(|i| { + titles + .get(i) + .cloned() + .unwrap_or_else(|| "an open project".into()) + }) + .collect(); + names.dedup(); + out.insert(k.clone(), names); + } + } + let mut after = dict.clone(); + delta.apply(&mut after, forward); + let kept = workspace_scope::references_outside(&after, &removes); + for k in &removes { + if kept.contains(k) && !out.contains_key(k) { + out.insert(k.clone(), vec!["another workspace dictionary row".into()]); + } + } + Ok(out) +} + +/// Workspace rows the stored projects other than `except` refer to. +pub fn usage(c: &Connection, except: Option) -> R> { + let mut stmt = c + .prepare("SELECT id,xer_content FROM projects") + .map_err(err)?; + let rows = stmt + .query_map([], |r| Ok((r.get::<_, i64>(0)?, r.get::<_, String>(1)?))) + .map_err(err)?; + let mut out = BTreeSet::new(); + for row in rows { + let (id, text) = row.map_err(err)?; + if Some(id) == except { + continue; + } + if let Ok(doc) = Document::parse(&text) { + out.extend(referenced_ids(&doc)); + } + } + Ok(out) +} + +/// Merge a project's workspace rows into the dictionary and return the text +/// to store for it. Run inside the transaction that writes the project row +/// (`row` is its id when it already exists). A dictionary row the project +/// read and has since deleted is removed unless a stored project, or another +/// dictionary row, still uses it. +pub fn store(c: &Connection, doc: &Document, mark: Option<&Mark>, row: Option) -> R { + store_with(c, doc, mark, row, &Policy::Save, &Choices::new()) +} + +/// What a row whose name the dictionary already has with different content +/// does, per owner table (upper case); a table not named makes a copy. +pub type Choices = BTreeMap; + +/// [`store`] naming copies by `policy`, and with `choices` for rows whose +/// name is taken by different content (an import's Keep or Update). +pub fn store_with( + c: &Connection, + doc: &Document, + mark: Option<&Mark>, + row: Option, + policy: &Policy, + choices: &Choices, +) -> R { + ensure(c)?; + let (dict, revision) = read_dictionary(c)?; + let keys = read_keys(c)?; + let mut merger = Merger::new(dict); + merger.set_floor(&keys); + merger.choices = choices.clone(); + let empty = BTreeSet::new(); + let marked = mark.map_or(&empty, |m| &m.rows); + // EPS code types the project brought keep being seen by it. + let place = eps_place(c, row)?; + let placed; + let moved = workspace_scope::misplaced_eps_codes(doc, &place, marked); + let doc = if moved > 0 { + let mut d = doc.clone(); + workspace_scope::place_eps_codes(&mut d, &place, marked); + placed = d; + &placed + } else { + doc + }; + let outcome = merger.merge(doc, policy, marked); + note_shared_sample_rows(c, row, &outcome.events)?; + let present = workspace_rows(doc); + let gone: Vec<(String, i64)> = marked + .iter() + .filter(|k| !present.contains(*k)) + .cloned() + .collect(); + let mut kept_in_use = vec![]; + if !gone.is_empty() { + // Rows the deleted rows themselves refer to (a resource's rates) + // do not keep them. + let skip: BTreeSet<(String, i64)> = gone.iter().cloned().collect(); + let mut used = usage(c, row)?; + used.extend(workspace_scope::references_outside(&merger.dict, &skip)); + used.extend(workspace_scope::references_outside( + &outcome.document, + &skip, + )); + for (table, id) in gone { + if used.contains(&(table.clone(), id)) { + kept_in_use.push((table, id)); + } else { + merger.remove(&table, id); + } + } + } + let revision = if merger.changed { + write_dictionary(c, &merger.dict, revision + 1)?; + revision + 1 + } else { + revision + }; + let mut highs = table_highs(&merger.dict); + for (t, h) in table_highs(&outcome.document) { + let e = highs.entry(t).or_insert(h); + *e = (*e).max(h); + } + raise_keys(c, &highs)?; + let text = workspace_scope::split(&outcome.document).0.text(); + Ok(Stored { + text, + mark: Mark { + revision, + rows: outcome.mark.clone(), + }, + outcome, + kept_in_use, + placed: moved, + }) +} + +// ------------------------------------------------------------ the sample + +/// Preference naming the workspace row of the first-run sample project and +/// the dictionary rows only it brought (JSON: `row`, `rows`). It goes when +/// the sample is removed. +pub const SAMPLE_KEY: &str = "sample_project"; + +/// The first-run sample in a workspace: its project row and the dictionary +/// rows that are the sample's alone. +#[derive(Clone, Debug, Default, PartialEq, Eq)] +pub struct SampleRecord { + pub row: i64, + pub rows: BTreeSet<(String, i64)>, +} + +/// The workspace's sample record, if it still has its sample. +pub fn read_sample(c: &Connection) -> R> { + let text: Option = c + .query_row( + "SELECT value FROM preferences WHERE key=?1", + [SAMPLE_KEY], + |r| r.get(0), + ) + .optional() + .or_else(missing_table) + .map_err(err)?; + let Some(text) = text else { return Ok(None) }; + let v: serde_json::Value = serde_json::from_str(&text).map_err(err)?; + let rows = v["rows"] + .as_array() + .map(|a| { + a.iter() + .filter_map(|x| Some((x[0].as_str()?.to_string(), x[1].as_i64()?))) + .collect() + }) + .unwrap_or_default(); + Ok(v["row"].as_i64().map(|row| SampleRecord { row, rows })) +} + +/// Write the sample record, or remove it (`None`). +pub fn write_sample(c: &Connection, s: Option<&SampleRecord>) -> R<()> { + match s { + Some(s) => { + let rows: Vec = s + .rows + .iter() + .map(|(t, id)| serde_json::json!([t, id])) + .collect(); + let text = serde_json::json!({"row": s.row, "rows": rows}).to_string(); + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO UPDATE SET value=excluded.value", + params![SAMPLE_KEY, text], + ) + } + None => c.execute("DELETE FROM preferences WHERE key=?1", [SAMPLE_KEY]), + } + .map(|_| ()) + .map_err(err) +} + +/// Note that workspace row `row` is the first-run sample and that the +/// dictionary rows it holds now and `before` (the dictionary before the +/// sample was stored) lacked are the sample's own. +pub fn record_sample(c: &Connection, row: i64, before: &Document) -> R<()> { + let (now, _) = read_dictionary(c)?; + let had = workspace_rows(before); + let rows = workspace_rows(&now) + .into_iter() + .filter(|k| !had.contains(k)) + .collect(); + write_sample(c, Some(&SampleRecord { row, rows })) +} + +/// A project other than the sample (workspace row `row`) was merged into +/// the dictionary: a sample row it matched or chose (same name and content, +/// Keep or Update) is now its row too, and stays when the sample goes. +fn note_shared_sample_rows(c: &Connection, row: Option, events: &[Event]) -> R<()> { + let Some(mut s) = read_sample(c)? else { + return Ok(()); + }; + if row == Some(s.row) { + return Ok(()); + } + let before = s.rows.len(); + for e in events { + if matches!( + e.kind, + EventKind::Merged | EventKind::Kept | EventKind::Updated + ) { + s.rows.remove(&(e.table.to_ascii_uppercase(), e.to)); + } + } + if s.rows.len() != before { + write_sample(c, Some(&s))?; + } + Ok(()) +} + +/// What removing the sample does to the dictionary. +#[derive(Clone, Debug, Default)] +pub struct SampleRemoval { + /// The dictionary change: the sample's rows out, renamed copies back. + pub delta: workspace_scope::delta::Delta, + /// How many rows go. + pub removed: usize, + /// Rows of other projects named `_` because the sample held + /// ``, which take their own name back. + pub renamed: Vec, +} + +/// The dictionary change that removing the sample project (stored as +/// workspace row `sample`) brings, without writing anything: the rows only +/// the sample brought go, except those another stored project, one of +/// `open` (open projects with their workspace ids) or a remaining row still +/// uses; a row another project named `_` because the sample held +/// `` takes its name back. `None` when the workspace has no sample +/// record for that row. +pub fn plan_sample_removal( + c: &Connection, + sample: i64, + open: &[(Option, &Document)], +) -> R> { + use openxer_xer::workspace_scope::merge::{NAMES, VALUE_GROUPS}; + use openxer_xer::workspace_scope::{key_column, references_outside, OWNED}; + let Some(s) = read_sample(c)?.filter(|s| s.row == sample) else { + return Ok(None); + }; + let (dict, _) = read_dictionary(c)?; + let mut used = usage(c, Some(sample))?; + for (id, doc) in open { + if *id != Some(sample) { + used.extend(referenced_ids(doc)); + } + } + let present = workspace_rows(&dict); + let mut gone: BTreeSet<(String, i64)> = s + .rows + .iter() + .filter(|k| present.contains(*k) && !used.contains(*k)) + .cloned() + .collect(); + // A row that stays keeps what it refers to, its rates and periods, and + // a code or field type that stays keeps its values. + loop { + let before = gone.len(); + let kept = references_outside(&dict, &gone); + gone.retain(|k| !kept.contains(k)); + let owner_kept = |table: &str, column: &str, owner: &str, k: &(String, i64)| { + k.0 == table + && dict.table(table).is_some_and(|t| { + key_column(table) + .and_then(|kc| t.field(kc)) + .is_some_and(|kc| { + t.rows.iter().any(|r| { + r[kc].trim().parse::() == Ok(k.1) + && !gone.contains(&( + owner.to_string(), + t.value(r, column).trim().parse().unwrap_or(0), + )) + }) + }) + }) + }; + let keep: Vec<(String, i64)> = gone + .iter() + .filter(|k| { + OWNED + .iter() + .any(|(table, column, owner)| owner_kept(table, column, owner, k)) + || VALUE_GROUPS + .iter() + .any(|(ty, value, column, _, _)| owner_kept(value, column, ty, k)) + }) + .cloned() + .collect(); + for k in keep { + gone.remove(&k); + } + if gone.len() == before { + break; + } + } + let mut merger = Merger::new(dict.clone()); + for (table, id) in &gone { + merger.remove(table, *id); + } + let mut after = merger.dict; + // Copies named after a sample row take that name back. + let mut renamed = vec![]; + for (table, id) in &gone { + let Some(column) = NAMES + .iter() + .find(|(t, _)| t == table) + .and_then(|(_, n)| n.first()) + else { + continue; + }; + let Some(name) = dict.table(table).and_then(|t| { + let k = t.field(key_column(table)?)?; + let r = t + .rows + .iter() + .find(|r| r[k].trim().parse::() == Ok(*id))?; + Some(t.value(r, column).to_string()) + }) else { + continue; + }; + let Some(t) = after + .tables + .iter_mut() + .find(|t| t.name.eq_ignore_ascii_case(table)) + else { + continue; + }; + let Some(col) = t.field(column) else { continue }; + if t.rows.iter().any(|r| r[col] == name) { + continue; + } + let copies: Vec = (0..t.rows.len()) + .filter(|&i| { + t.rows[i][col] + .strip_prefix(name.as_str()) + .and_then(|rest| rest.strip_prefix('_')) + .is_some_and(|n| !n.is_empty() && n.chars().all(|ch| ch.is_ascii_digit())) + }) + .collect(); + if let [i] = copies[..] { + renamed.push(format!( + "{} \"{}\" is \"{name}\" again", + kind_label(table), + t.rows[i][col] + )); + t.rows[i][col] = name; + } + } + Ok(Some(SampleRemoval { + delta: workspace_scope::delta::diff(&dict, &after), + removed: gone.len(), + renamed, + })) +} + +/// The (table, id) of the keyed workspace rows of `doc`. +pub fn workspace_rows(doc: &Document) -> BTreeSet<(String, i64)> { + let scopes = workspace_scope::Scopes::of(doc); + let mut out = BTreeSet::new(); + for t in &doc.tables { + let Some(k) = workspace_scope::key_column(&t.name).and_then(|k| t.field(k)) else { + continue; + }; + for r in &t.rows { + if scopes.shared(t, r) { + if let Ok(id) = r[k].trim().parse() { + out.insert((t.name.to_ascii_uppercase(), id)); + } + } + } + } + out +} + +mod migrate; +pub use migrate::migrate; + +#[cfg(test)] +mod tests; diff --git a/automation/src/workspace_db/migrate.rs b/automation/src/workspace_db/migrate.rs new file mode 100644 index 0000000..005dc17 --- /dev/null +++ b/automation/src/workspace_db/migrate.rs @@ -0,0 +1,311 @@ +//! Moving a version 1 workspace to a shared workspace dictionary. +use super::{ + ensure, err, hydrate, raise_keys, read_dictionary, read_revision, schema, write_dictionary, + DICTIONARY_SCHEMA, EARLIER_DICTIONARY_SCHEMA, R, SCHEMA_KEY, +}; +use openxer_xer::workspace_scope; +use openxer_xer::workspace_scope::merge::{Event, EventKind}; +use openxer_xer::workspace_scope::migrate::{ + plan_migration, schedule_result, verify_hydrated, MigrationPlan, ProjectPlan, Scheduled, +}; +use openxer_xer::Document; +use rusqlite::{params, Connection, TransactionBehavior}; +use serde_json::{json, Value}; +use std::path::Path; + +/// A stored project as migration reads it. +struct ProjectRow { + id: i64, + key: i64, + title: String, + text: String, + windows_encoding: bool, + level: bool, +} + +fn project_rows(c: &Connection) -> R> { + let mut stmt = c + .prepare("SELECT id,project_key,title,xer_content,source_windows_encoding,level_resources FROM projects ORDER BY id") + .map_err(err)?; + let rows = stmt + .query_map([], |r| { + Ok(ProjectRow { + id: r.get(0)?, + key: r.get(1)?, + title: r.get(2)?, + text: r.get(3)?, + windows_encoding: r.get(4)?, + level: r.get(5)?, + }) + }) + .map_err(err)?; + rows.collect::, _>>().map_err(err) +} + +/// Whether two readings of the stored projects hold the same rows. +fn same_rows(a: &[ProjectRow], b: &[ProjectRow]) -> bool { + a.len() == b.len() + && a.iter().zip(b).all(|(x, y)| { + (x.id, x.key, &x.text, x.windows_encoding, x.level) + == (y.id, y.key, &y.text, y.windows_encoding, y.level) + }) +} + +/// The schedules a project must keep: with its own leveling setting, and +/// leveled (the dictionary holds the resource limits leveling reads). +fn schedules(doc: &Document, key: i64, level: bool) -> Vec> { + let mut out = vec![schedule_result(doc, key, level)]; + if !level { + out.push(schedule_result(doc, key, true)); + } + out +} + +/// Prove one migrated project: `doc` (its stored text hydrated with the new +/// dictionary) holds everything the plan expects and schedules to the same +/// dates and float as before. +fn prove( + planned: &ProjectPlan, + doc: &Document, + key: i64, + level: bool, + before: &[Result], +) -> R<()> { + verify_hydrated(&planned.document, doc) + .map_err(|e| format!("{} (workspace row {}): {e}", planned.label, planned.id))?; + if schedules(doc, key, level) != before { + return Err(format!( + "{} (workspace row {}): the scheduled dates or float would change", + planned.label, planned.id + )); + } + Ok(()) +} + +/// Move a version 1 workspace to a shared dictionary (schema 3), or +/// upgrade a schema 2 one an earlier build made (its EPS code types move +/// into the dictionary). +/// +/// The plan is made and proved first: every project, its stored text +/// hydrated with the new dictionary, must hold all of its rows (ids +/// renumbered where the plan says) and schedule, unleveled and leveled, to +/// the same dates and float as before. A dry run stops there and changes +/// nothing. Otherwise `backup`, when given, receives a copy of the database +/// first (it must not exist), then one transaction writes the dictionary +/// and every project's text, proves each project again from what was +/// written, and commits only when all pass. +pub fn migrate(c: &mut Connection, dry_run: bool, backup: Option<&Path>) -> R { + migrate_with(c, dry_run, backup, || {}) +} + +/// [`migrate`], running `between` after the plan is proved and before the +/// transaction that writes it (tests use it to write from another +/// connection in between). +fn migrate_with( + c: &mut Connection, + dry_run: bool, + backup: Option<&Path>, + between: impl FnOnce(), +) -> R { + let before = schema(c)?; + if before > DICTIONARY_SCHEMA { + return Err(format!( + "This workspace uses workspace schema {before}, which needs a newer OpenXER." + )); + } + if before == DICTIONARY_SCHEMA { + return Ok( + json!({"dry_run": dry_run, "schema_before": before, "already_migrated": true, "projects": []}), + ); + } + let rows = project_rows(c)?; + // A workspace an earlier build gave a dictionary (schema 2) keeps its + // EPS code types in each project's text: each project is read whole, + // its text with that dictionary, and converted as a version 1 one. + let earlier = if before == EARLIER_DICTIONARY_SCHEMA { + Some(read_dictionary(c)?) + } else { + None + }; + let eps = super::read_eps(c)?; + let mut inputs = vec![]; + let mut originals = vec![]; + for row in &rows { + let mut doc = Document::parse(&row.text).map_err(|e| { + format!( + "Workspace row {} ({}) cannot be read: {e}", + row.id, row.title + ) + })?; + if let Some((dict, _)) = &earlier { + workspace_scope::hydrate(&mut doc, dict); + } + doc.windows_encoding = row.windows_encoding; + let label = doc + .projects() + .into_iter() + .find(|(id, _)| *id == row.key) + .map(|(_, name)| name) + .filter(|n| !n.is_empty()) + .unwrap_or_else(|| row.title.clone()); + originals.push(doc.clone()); + // EPS code types name the EPS nodes of the database the project came + // from; they move to the project's own workspace node. + let place = super::place_in(&eps, Some(row.id)); + workspace_scope::place_eps_codes(&mut doc, &place, &Default::default()); + inputs.push((row.id, label, doc)); + } + let plan = plan_migration(&inputs); + let baseline: Vec>> = rows + .iter() + .zip(&originals) + .map(|(row, doc)| schedules(doc, row.key, row.level)) + .collect(); + // Prove the plan in memory, through text as it will be stored. + let dict = Document::parse(&plan.dictionary.text()).map_err(err)?; + for ((row, planned), before) in rows.iter().zip(&plan.projects).zip(&baseline) { + let mut doc = Document::parse(&planned.stored.text()).map_err(err)?; + doc.windows_encoding = row.windows_encoding; + workspace_scope::hydrate(&mut doc, &dict); + prove(planned, &doc, row.key, row.level, before)?; + } + let mut result = report_json(&plan, dry_run, before); + if dry_run { + return Ok(result); + } + if let Some(path) = backup { + if path.exists() { + return Err(format!("The backup {} already exists.", path.display())); + } + c.execute("VACUUM INTO ?1", [path.to_string_lossy()]) + .map_err(|e| format!("The backup could not be written: {e}"))?; + result["backup"] = json!(path); + } + between(); + // The write lock is taken first (BEGIN IMMEDIATE) and the rows are read + // again inside it: proving a large workspace takes minutes, and a save + // made in that time by another connection must not be overwritten by + // text planned from the rows as they were. + let tx = c + .transaction_with_behavior(TransactionBehavior::Immediate) + .map_err(err)?; + let revision = read_revision(&tx)?; + if schema(&tx)? != before + || !same_rows(&rows, &project_rows(&tx)?) + || earlier.as_ref().is_some_and(|(_, r)| *r != revision) + { + return Err("The workspace changed while the conversion was being checked (a project was saved by another program). Nothing was changed; run the conversion again.".into()); + } + ensure(&tx)?; + write_dictionary(&tx, &plan.dictionary, revision + 1)?; + raise_keys(&tx, &plan.keys)?; + for planned in &plan.projects { + tx.execute( + "UPDATE projects SET xer_content=?1 WHERE id=?2", + params![planned.stored.text(), planned.id], + ) + .map_err(err)?; + } + tx.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2) ON CONFLICT(key) DO UPDATE SET value=excluded.value", + params![SCHEMA_KEY, DICTIONARY_SCHEMA.to_string()], + ) + .map_err(err)?; + // Prove every project again from what the transaction holds. + for ((row, planned), before) in rows.iter().zip(&plan.projects).zip(&baseline) { + let text: String = tx + .query_row( + "SELECT xer_content FROM projects WHERE id=?1", + [row.id], + |r| r.get(0), + ) + .map_err(err)?; + let mut doc = Document::parse(&text).map_err(err)?; + doc.windows_encoding = row.windows_encoding; + hydrate(&tx, &mut doc, Some(row.id))?; + prove(planned, &doc, row.key, row.level, before)?; + } + tx.commit().map_err(err)?; + Ok(result) +} + +/// The migration report as JSON, with the plain-text report beside it. +fn events(p: &ProjectPlan, kind: EventKind) -> impl Iterator { + p.events.iter().filter(move |e| e.kind == kind) +} + +fn report_json(plan: &MigrationPlan, dry_run: bool, before: i64) -> Value { + let projects: Vec = plan + .projects + .iter() + .map(|p| { + json!({ + "workspace_id": p.id, + "project": p.label, + "shared": events(p, EventKind::Merged).count(), + "added": events(p, EventKind::Added).count(), + "copies": events(p, EventKind::Copied).map(|e| json!({ + "table": e.table, "name": e.name, "renamed": e.renamed, + "differences": e.differences, "from_id": e.from, "to_id": e.to, + })).collect::>(), + "renumbered": events(p, EventKind::Renumbered) + .chain(events(p, EventKind::ProjectRenumbered)) + .map(|e| json!({"table": e.table, "name": e.name, "from_id": e.from, "to_id": e.to})) + .collect::>(), + "renamed_to_match": events(p, EventKind::Merged) + .filter(|e| e.renamed.is_some()) + .map(|e| json!({"table": e.table, "name": e.name, "renamed": e.renamed})) + .collect::>(), + "verified": {"rows": true, "schedule": true}, + }) + }) + .collect(); + json!({ + "dry_run": dry_run, + "schema_before": before, + "schema_after": if dry_run { before } else { DICTIONARY_SCHEMA }, + "dictionary_rows": plan.dictionary_rows(), + "projects": projects, + "report": plan.report(), + }) +} + +#[cfg(test)] +mod tests { + use super::*; + + /// B9/B12: a project saved by another connection while the conversion + /// is being proved is not overwritten with text planned from the rows + /// as they were: the conversion is refused and changes nothing. + #[test] + fn a_save_made_while_the_conversion_is_checked_is_never_overwritten() { + let dir = tempfile::tempdir().unwrap(); + let path = dir.path().join("w.db"); + let text = openxer_xer::starter().updated_document().text(); + { + let c = Connection::open(&path).unwrap(); + crate::storage::schema(&c).unwrap(); + c.execute( + "INSERT INTO projects(source_name,project_key,title,xer_content) VALUES('A.xer',1,'A',?1)", + [&text], + ) + .unwrap(); + } + let saved = text.replace("RIVERBEND", "RIVERBEND SAVED MEANWHILE"); + assert_ne!(saved, text); + let mut c = Connection::open(&path).unwrap(); + let result = migrate_with(&mut c, false, None, || { + let other = Connection::open(&path).unwrap(); + other + .execute("UPDATE projects SET xer_content=?1", [&saved]) + .unwrap(); + }); + let error = result.expect_err("refused"); + assert!(error.contains("changed while"), "{error}"); + let now: String = c + .query_row("SELECT xer_content FROM projects", [], |r| r.get(0)) + .unwrap(); + assert_eq!(now, saved, "the later save stays"); + assert_eq!(schema(&c).unwrap(), 1, "nothing was converted"); + } +} diff --git a/automation/src/workspace_db/tests.rs b/automation/src/workspace_db/tests.rs new file mode 100644 index 0000000..8cb8d4a --- /dev/null +++ b/automation/src/workspace_db/tests.rs @@ -0,0 +1,261 @@ +use super::*; + +fn workspace() -> Connection { + let c = Connection::open_in_memory().unwrap(); + crate::storage::schema(&c).unwrap(); + ensure(&c).unwrap(); + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,'3')", + [SCHEMA_KEY], + ) + .unwrap(); + c +} + +fn insert(c: &Connection, source: &str, text: &str) -> i64 { + c.execute( + "INSERT INTO projects(source_name,project_key,title,xer_content) VALUES(?1,1,'P',?2)", + params![source, text], + ) + .unwrap(); + c.last_insert_rowid() +} + +#[test] +fn schema_is_1_without_the_preference() { + let c = Connection::open_in_memory().unwrap(); + assert_eq!(schema(&c).unwrap(), 1); + crate::storage::schema(&c).unwrap(); + assert_eq!(schema(&c).unwrap(), 1); + assert_eq!(schema(&workspace()).unwrap(), 3); +} + +#[test] +fn store_then_hydrate_returns_the_project() { + let c = workspace(); + let p = openxer_xer::starter(); + let doc = p.updated_document(); + let stored = store(&c, &doc, None, None).unwrap(); + assert!(!stored.text.contains("Standard 5-day")); + let id = insert(&c, "A.xer", &stored.text); + let (dict, revision) = read_dictionary(&c).unwrap(); + assert_eq!(revision, 1); + assert!(dict.table("CALENDAR").is_some()); + let text: String = c + .query_row("SELECT xer_content FROM projects WHERE id=?1", [id], |r| { + r.get(0) + }) + .unwrap(); + let mut back = Document::parse(&text).unwrap(); + let mark = hydrate(&c, &mut back, None).unwrap(); + assert_eq!(back.text(), doc.text()); + assert_eq!(mark.revision, 1); + assert!(mark.rows.contains(&("CALENDAR".to_string(), 1))); + let keys = read_keys(&c).unwrap(); + assert!(keys["CALENDAR"] >= 1); + assert_eq!(back.id_floor_of("CALENDAR"), keys["CALENDAR"]); + // Saving the same project again changes nothing. + let again = store(&c, &back, Some(&mark), Some(id)).unwrap(); + assert_eq!(again.text, stored.text); + assert_eq!(read_dictionary(&c).unwrap().1, 1); +} + +#[test] +fn commands_read_and_write_a_shared_dictionary_workspace() { + let dir = tempfile::tempdir().unwrap(); + let path = dir.path().join("w.db"); + let doc = openxer_xer::starter().updated_document(); + { + let c = Connection::open(&path).unwrap(); + crate::storage::schema(&c).unwrap(); + start_new(&c).unwrap(); + let id = insert(&c, "A.xer", ""); + let stored = store(&c, &doc, None, Some(id)).unwrap(); + c.execute( + "UPDATE projects SET xer_content=?1 WHERE id=?2", + params![stored.text, id], + ) + .unwrap(); + } + // load reads the project whole, its calendars from the dictionary. + let loaded = crate::storage::load(&path, None, None).unwrap(); + assert_eq!(loaded.project.updated_document().text(), doc.text()); + assert!(loaded.mark.is_some()); + let inspected = crate::storage::inspect(&path).unwrap(); + assert_eq!(inspected["workspace_schema"], 3); + assert_eq!(inspected["dictionary"]["rows"]["CALENDAR"], 1); + // A newer schema is refused. + let c = Connection::open(&path).unwrap(); + c.execute( + "UPDATE preferences SET value='99' WHERE key=?1", + [SCHEMA_KEY], + ) + .unwrap(); + drop(c); + let e = crate::storage::load(&path, None, None).err().unwrap(); + assert_eq!(e.code, "workspace_schema_unsupported"); +} + +fn code_types(doc: &Document) -> Vec { + doc.table("ACTVTYPE").map_or(vec![], |t| { + t.rows + .iter() + .map(|r| t.value(r, "actv_code_type").to_string()) + .collect() + }) +} + +#[test] +fn eps_codes_are_shared_with_the_projects_under_their_eps_node() { + let c = workspace(); + let starter = openxer_xer::starter().updated_document().text(); + let p = insert(&c, "P.xer", &starter); + let q = insert(&c, "Q.xer", &starter); + let r = insert(&c, "R.xer", &starter); + // Workspace > North (P, Q) and South (R). + let mut ws = Workspace::default(); + let root = ws.eps()[0].id; + let north = ws.add_folder(Some(root), "North", Some("N")).unwrap(); + let south = ws.add_folder(Some(root), "South", Some("S")).unwrap(); + ws.place(p, north).unwrap(); + ws.place(q, north).unwrap(); + ws.place(r, south).unwrap(); + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2)", + params![openxer_xer::workspace::KEY, ws.to_text()], + ) + .unwrap(); + // P brings an EPS code filed under its source database's node 999, and + // a global one. + let mut project = openxer_xer::starter(); + openxer_xer::edit::tables::add_code_type(&mut project, "Unit", "eps", None).unwrap(); + openxer_xer::edit::tables::add_code_type(&mut project, "Area", "global", None).unwrap(); + let doc = project.updated_document(); + let stored = store(&c, &doc, None, Some(p)).unwrap(); + assert_eq!(stored.placed, 1, "the EPS code moves to P's node"); + assert!(stored.changed_document()); + let (dict, _) = read_dictionary(&c).unwrap(); + let t = dict.table("ACTVTYPE").unwrap(); + let unit = t + .rows + .iter() + .find(|row| t.value(row, "actv_code_type") == "Unit") + .unwrap(); + assert_eq!(t.value(unit, "wbs_id"), north.to_string()); + // Q (same node) and P see both codes; R (another node) the global one. + for (row, want) in [ + (p, vec!["Unit", "Area"]), + (q, vec!["Unit", "Area"]), + (r, vec!["Area"]), + ] { + let mut back = Document::parse(&stored.text).unwrap(); + hydrate(&c, &mut back, Some(row)).unwrap(); + let mut got = code_types(&back); + got.sort(); + let mut want: Vec = want.into_iter().map(String::from).collect(); + want.sort(); + assert_eq!(got, want, "workspace row {row}"); + } + // A project under a node below North sees North's codes too. + let mut ws = read_eps(&c).unwrap(); + let below = ws.add_folder(Some(north), "Unit 1", Some("U1")).unwrap(); + ws.place(r, below).unwrap(); + c.execute( + "UPDATE preferences SET value=?2 WHERE key=?1", + params![openxer_xer::workspace::KEY, ws.to_text()], + ) + .unwrap(); + let mut back = Document::parse(&stored.text).unwrap(); + hydrate(&c, &mut back, Some(r)).unwrap(); + assert!(code_types(&back).contains(&"Unit".to_string())); +} + +/// Schema marker: the command line refuses a schema 2 workspace an earlier +/// build made (its EPS codes are still in each project's text) instead of +/// reading it as this build's layout, and `migrate` upgrades it. +#[test] +fn an_earlier_shared_dictionary_workspace_is_refused_until_upgraded() { + let dir = tempfile::tempdir().unwrap(); + let path = dir.path().join("w.db"); + let doc = openxer_xer::starter().updated_document(); + { + let c = Connection::open(&path).unwrap(); + crate::storage::schema(&c).unwrap(); + ensure(&c).unwrap(); + c.execute( + "INSERT INTO preferences(key,value) VALUES(?1,?2)", + params![SCHEMA_KEY, EARLIER_DICTIONARY_SCHEMA.to_string()], + ) + .unwrap(); + insert(&c, "A.xer", &doc.text()); + } + let e = crate::storage::load(&path, None, None).err().unwrap(); + assert_eq!(e.code, "workspace_needs_migration"); + let mut c = Connection::open(&path).unwrap(); + let report = migrate(&mut c, false, None).unwrap(); + assert_eq!(report["schema_before"], 2); + assert_eq!(report["schema_after"], DICTIONARY_SCHEMA); + drop(c); + let loaded = crate::storage::load(&path, None, None).unwrap(); + assert_eq!(loaded.project.updated_document().text(), doc.text()); +} + +/// A project with the starter's rows and the notebook topics `topics`. +fn with_topics(source_key: &str, topics: &[(i64, &str)]) -> Document { + let mut doc = openxer_xer::starter().updated_document(); + for (id, name) in topics { + doc.table_mut("MEMOTYPE").add(&[ + ("memo_type_id", id.to_string()), + ("seq_num", id.to_string()), + ("memo_type", name.to_string()), + ]); + } + let t = doc.table_mut("PROJECT"); + t.set(0, "proj_short_name", source_key.into()); + doc +} + +/// A dictionary row the sample brought stays when another project brings +/// the same row (same name and content), even one that project does not +/// use; the rows only the sample has go. +#[test] +fn sample_rows_another_project_shares_stay() { + let c = workspace(); + let sample = insert(&c, "Sample", ""); + let before = read_dictionary(&c).unwrap().0; + let doc = with_topics("RIVERBEND", &[(1, "Scope"), (2, "Field Notes")]); + let stored = store(&c, &doc, None, Some(sample)).unwrap(); + c.execute( + "UPDATE projects SET xer_content=?1 WHERE id=?2", + params![stored.text, sample], + ) + .unwrap(); + record_sample(&c, sample, &before).unwrap(); + let record = read_sample(&c).unwrap().unwrap(); + assert!(record.rows.contains(&("MEMOTYPE".to_string(), 1))); + assert!(record.rows.contains(&("CALENDAR".to_string(), 1))); + // Another project brings the same "Scope" topic and calendar. + let other = insert(&c, "Mine.xer", ""); + let mine = with_topics("MINE", &[(1, "Scope")]); + let stored = store(&c, &mine, None, Some(other)).unwrap(); + c.execute( + "UPDATE projects SET xer_content=?1 WHERE id=?2", + params![stored.text, other], + ) + .unwrap(); + let record = read_sample(&c).unwrap().unwrap(); + assert!(!record.rows.contains(&("MEMOTYPE".to_string(), 1))); + assert!(!record.rows.contains(&("CALENDAR".to_string(), 1))); + c.execute("DELETE FROM projects WHERE id=?1", [sample]) + .unwrap(); + let removal = plan_sample_removal(&c, sample, &[]).unwrap().unwrap(); + assert_eq!(removal.removed, 1, "only Field Notes goes"); + let (mut dict, _) = read_dictionary(&c).unwrap(); + removal.delta.apply(&mut dict, true); + let t = dict.table("MEMOTYPE").unwrap(); + let topics: Vec<&str> = t.rows.iter().map(|r| t.value(r, "memo_type")).collect(); + assert_eq!(topics, vec!["Scope"]); + assert!(dict.table("CALENDAR").is_some_and(|t| t.rows.len() == 1)); + // Another workspace row is no sample. + assert!(plan_sample_removal(&c, other, &[]).unwrap().is_none()); +} diff --git a/automation/tests/agent_host.rs b/automation/tests/agent_host.rs new file mode 100644 index 0000000..0f1da7e --- /dev/null +++ b/automation/tests/agent_host.rs @@ -0,0 +1,1839 @@ +//! The agent host against recorded transcripts and a scripted fake agent: +//! both parsers, the launch arguments (the sandbox), sessions (multi-turn, +//! tools, proposals, cancel, early exit, missing or signed-out agents, bad +//! output, cleanup), detection and sign-in. No real agent runs here. +use openxer_automation::agent_host::{ + self, claude, codex, model_choices, parse_sign_in_status, tool_target, Agent, AgentError, + AgentProcess, Captured, Event, Launch, ModelChoice, Session, SessionOptions, SignIn, + SignInState, Spawner, Usage, +}; +use openxer_automation::{chat_tools::ChatMode, connect::Env}; +use serde_json::json; +use std::collections::VecDeque; +use std::io::{self, Read, Write}; +use std::path::{Path, PathBuf}; +use std::sync::atomic::{AtomicBool, AtomicUsize, Ordering}; +use std::sync::mpsc::{self, Receiver, RecvTimeoutError, Sender}; +use std::sync::{Arc, Mutex}; +use std::time::{Duration, Instant}; + +// ------------------------------------------------------------ fixtures + +fn fixture(name: &str) -> Vec { + let path = Path::new(env!("CARGO_MANIFEST_DIR")) + .join("tests/fixtures/agent") + .join(name); + std::fs::read_to_string(path) + .unwrap() + .lines() + .map(str::to_string) + .collect() +} + +/// A recorded transcript cut into its turns (each ends with `end`). +fn turns(name: &str, end: &str) -> Vec> { + let mut out = vec![vec![]]; + for line in fixture(name) { + let last = line.contains(end); + out.last_mut().unwrap().push(line); + if last { + out.push(vec![]); + } + } + out.retain(|t| !t.is_empty()); + out +} + +fn claude_turns() -> Vec> { + turns("claude-two-turns.jsonl", "\"type\":\"result\"") +} + +fn codex_turns() -> Vec> { + turns("codex-two-turns.jsonl", "\"type\":\"turn.completed\"") +} + +fn parse_claude(lines: &[String]) -> (Vec, claude::ClaudeParser) { + let mut p = claude::ClaudeParser::new(); + let now = Instant::now(); + let events = lines.iter().flat_map(|l| p.parse_line(l, now)).collect(); + (events, p) +} + +fn parse_codex(lines: &[String]) -> (Vec, codex::CodexParser) { + let mut p = codex::CodexParser::new("gpt-test"); + let now = Instant::now(); + let events = lines.iter().flat_map(|l| p.parse_line(l, now)).collect(); + (events, p) +} + +fn messages(events: &[Event]) -> String { + events + .iter() + .filter_map(|e| match e { + Event::Message { text } => Some(text.as_str()), + _ => None, + }) + .collect::>() + .join("\n") +} + +fn deltas(events: &[Event]) -> String { + events + .iter() + .filter_map(|e| match e { + Event::TextDelta { text } => Some(text.as_str()), + _ => None, + }) + .collect() +} + +fn finished(events: &[Event]) -> Vec<(Usage, Option, bool)> { + events + .iter() + .filter_map(|e| match e { + Event::TurnFinished { + usage, + cost_usd, + cancelled, + } => Some((*usage, *cost_usd, *cancelled)), + _ => None, + }) + .collect() +} + +// -------------------------------------------------------------- parsers + +#[test] +fn the_claude_parser_reads_a_recorded_conversation() { + let all: Vec = claude_turns().concat(); + let (events, parser) = parse_claude(&all); + assert_eq!( + parser.session_id.as_deref(), + Some("00000000-0000-4000-8000-000000000001") + ); + // One init per turn; the session reports Ready once. + let ready: Vec<_> = events + .iter() + .filter(|e| matches!(e, Event::Ready { model } if model == "claude-opus-5-5")) + .collect(); + assert_eq!(ready.len(), 2); + assert!( + !events.iter().any(|e| matches!(e, Event::Error { .. })), + "{events:?}" + ); + let tools: Vec<(String, String)> = events + .iter() + .filter_map(|e| match e { + Event::ToolStarted { tool, target, .. } => Some((tool.clone(), target.clone())), + _ => None, + }) + .collect(); + assert_eq!( + tools, + [ + ( + "openxer_load".to_string(), + "critical activities".to_string() + ), + ("openxer_apply".to_string(), "1 change".to_string()) + ] + ); + assert_eq!( + events + .iter() + .filter(|e| matches!(e, Event::ToolFinished { ok: true, .. })) + .count(), + 2 + ); + let text = messages(&events); + assert!(text.contains("PM0920")); + assert!(text.contains("2026-10-12")); + // The deltas add up to the whole messages. + assert_eq!(deltas(&events).replace('\n', ""), text.replace('\n', "")); + let proposal = events + .iter() + .find_map(|e| match e { + Event::ProposedChanges { changes, diff, .. } => Some((changes, diff)), + _ => None, + }) + .expect("a proposal"); + assert_eq!(proposal.0["operations"][0]["activity"], "PM0910"); + assert_eq!( + proposal.1.as_ref().unwrap()["activities"]["changed"]["PM0910"]["task_name"]["after"], + "Submit as-built drawings and O&M manuals" + ); + let ends = finished(&events); + assert_eq!(ends.len(), 2); + assert_eq!( + ends[0].0, + Usage { + input_tokens: 4 + 5698 + 3746, + cached_input_tokens: 3746, + output_tokens: 331 + } + ); + // Each turn's own cost, not the running total. + assert!((ends[0].1.unwrap() - 0.0529692).abs() < 1e-6); + assert!(ends[1].1.unwrap() < 0.02, "{:?}", ends[1]); +} + +#[test] +fn the_claude_parser_takes_the_turn_cost_from_the_running_total_when_needed() { + let mut p = claude::ClaudeParser::new(); + let now = Instant::now(); + let a = p.parse_line( + r#"{"type":"result","subtype":"success","total_cost_usd":0.05,"usage":{}}"#, + now, + ); + let b = p.parse_line( + r#"{"type":"result","subtype":"success","total_cost_usd":0.07,"usage":{}}"#, + now, + ); + assert!((finished(&a)[0].1.unwrap() - 0.05).abs() < 1e-9); + assert!((finished(&b)[0].1.unwrap() - 0.02).abs() < 1e-9); +} + +#[test] +fn the_codex_parser_reads_a_recorded_conversation() { + let recorded = codex_turns(); + assert_eq!(recorded.len(), 2); + let (first, parser) = parse_codex(&recorded[0]); + assert_eq!( + parser.thread_id.as_deref(), + Some("00000000-0000-4000-8000-000000000002") + ); + assert_eq!( + first[0], + Event::Ready { + model: "gpt-test".into() + } + ); + let started = first + .iter() + .filter(|e| matches!(e, Event::ToolStarted { tool, .. } if tool == "openxer_load")) + .count(); + let ended = first + .iter() + .filter(|e| matches!(e, Event::ToolFinished { ok: true, .. })) + .count(); + assert_eq!((started, ended), (6, 6)); + assert!(first.iter().any( + |e| matches!(e, Event::ToolStarted { target, .. } if target == "activities, from row 186") + )); + assert!(messages(&first).contains("PM0920")); + assert_eq!( + finished(&first), + [( + Usage { + input_tokens: 27086, + cached_input_tokens: 11520, + output_tokens: 252 + }, + None, + false + )] + ); + let (second, _) = parse_codex(&recorded[1]); + let proposal = second + .iter() + .find_map(|e| match e { + Event::ProposedChanges { changes, diff, .. } => Some((changes.clone(), diff.clone())), + _ => None, + }) + .expect("a proposal"); + assert_eq!(proposal.0["operations"][0]["field"], "activity_name"); + assert!(proposal.1.is_some()); + assert!(!second.iter().any(|e| matches!(e, Event::Error { .. }))); +} + +#[test] +fn parsers_report_failures_and_odd_lines() { + let now = Instant::now(); + let mut c = claude::ClaudeParser::new(); + assert!(c.parse_line(" ", now).is_empty()); + assert!(matches!( + c.parse_line("not json {", now).as_slice(), + [Event::Error { + error: AgentError::BadOutput { .. } + }] + )); + // Unknown kinds are ignored. + assert!(c + .parse_line(r#"{"type":"rate_limit_event"}"#, now) + .is_empty()); + let init = c.parse_line( + r#"{"type":"system","subtype":"init","session_id":"s","model":"m","mcp_servers":[{"name":"openxer","status":"failed"}]}"#, + now, + ); + assert!( + matches!(&init[1], Event::Error { error: AgentError::Failed { message } } if message.contains("failed")) + ); + c.parse_line( + r#"{"type":"assistant","message":{"content":[{"type":"tool_use","id":"t1","name":"mcp__openxer__openxer_load","input":{"activities":["A1","A2","A3","A4","A5","A6"]}}]}}"#, + now, + ); + let failed = c.parse_line( + r#"{"type":"user","message":{"content":[{"type":"tool_result","tool_use_id":"t1","is_error":true,"content":[{"type":"text","text":"{\"ok\":false,\"error\":{\"code\":\"invalid_arguments\",\"message\":\"Unknown field colour\"}}"}]}]}}"#, + now, + ); + assert_eq!( + failed, + [Event::ToolFinished { + id: "t1".into(), + tool: "openxer_load".into(), + ok: false, + error: Some("Unknown field colour".into()), + duration_ms: 0 + }] + ); + let signed_out = c.parse_line( + r#"{"type":"result","subtype":"success","is_error":true,"result":"Not logged in - Please run /login","usage":{}}"#, + now, + ); + assert!(matches!( + &signed_out[0], + Event::Error { + error: AgentError::NotSignedIn { + agent: Agent::ClaudeCode, + .. + } + } + )); + assert!(matches!(signed_out[1], Event::TurnFinished { .. })); + let other = c.parse_line( + r#"{"type":"result","subtype":"error_max_turns","is_error":true,"usage":{}}"#, + now, + ); + assert!( + matches!(&other[0], Event::Error { error: AgentError::Failed { message } } if message.contains("error_max_turns")) + ); + + let mut x = codex::CodexParser::new("m"); + assert!(matches!( + x.parse_line("{broken", now).as_slice(), + [Event::Error { + error: AgentError::BadOutput { .. } + }] + )); + // A call finished without a start line, arguments as JSON text, failed. + let call = x.parse_line( + r#"{"type":"item.completed","item":{"id":"i9","type":"mcp_tool_call","server":"openxer","tool":"openxer_records","arguments":"{\"kind\":\"risks\"}","status":"failed","error":{"message":"tool call failed"}}}"#, + now, + ); + assert_eq!( + call[0], + Event::ToolStarted { + id: "i9".into(), + tool: "openxer_records".into(), + target: "risks".into() + } + ); + assert!( + matches!(&call[1], Event::ToolFinished { ok: false, error: Some(e), .. } if e == "tool call failed") + ); + let failed = x.parse_line( + r#"{"type":"turn.failed","error":{"message":"unexpected status 401 Unauthorized"}}"#, + now, + ); + assert!(matches!( + &failed[0], + Event::Error { + error: AgentError::NotSignedIn { + agent: Agent::Codex, + .. + } + } + )); + assert!(matches!( + failed[1], + Event::TurnFinished { + cancelled: false, + .. + } + )); + let error = x.parse_line(r#"{"type":"error","message":"stream disconnected"}"#, now); + assert!(matches!( + &error[0], + Event::Error { + error: AgentError::Failed { .. } + } + )); +} + +#[test] +fn tool_targets_are_a_few_plain_words() { + let t = |tool: &str, input: serde_json::Value| tool_target(tool, &input); + assert_eq!(t("openxer_load", json!({})), "activities"); + assert_eq!(t("openxer_load", json!({"limit":0})), "project summary"); + assert_eq!(t("openxer_load", json!({"activities":["A","B"]})), "A, B"); + assert_eq!( + t( + "openxer_load", + json!({"activities":["1","2","3","4","5","6","7"]}) + ), + "1, 2, 3, 4, 5 and 2 more" + ); + assert_eq!( + t( + "openxer_load", + json!({"wbs":"ENG","critical":true,"offset":50}) + ), + "WBS ENG, critical activities, from row 51" + ); + assert_eq!( + t("openxer_records", json!({"kind":"issues","activity":"A1"})), + "issues of A1" + ); + assert_eq!(t("openxer_earned_value", json!({})), "project"); + assert_eq!(t("openxer_usage", json!({"resource":"PF"})), "PF"); + assert_eq!(t("openxer_documents", json!({"wbs":"ENG"})), "WBS ENG"); + assert_eq!( + t("openxer_apply", json!({"changes":{"operations":[{},{}]}})), + "2 changes" + ); + assert_eq!( + t("openxer_playbook", json!({"name":"audit"})), + "audit playbook" + ); + assert_eq!(t("openxer_playbook", json!({})), "playbook list"); + assert_eq!( + t("openxer_check_schedule", json!({"check":"Logic"})), + "Logic" + ); + assert_eq!(t("openxer_check_schedule", json!({})), "all checks"); + assert_eq!(t("other", json!({})), ""); +} + +// ------------------------------------------------------------- sandbox + +fn options(agent: Agent, dir: &Path, mode: ChatMode, model: ModelChoice) -> SessionOptions { + SessionOptions { + agent, + executable: dir.join("agent.exe"), + model, + mode, + cli: dir.join("openxer-cli.exe"), + data_dir: dir.join("data"), + work_dir: dir.join("work"), + snapshot: dir.join("snapshot.xer"), + preamble: "Open project: SAMPLE.".into(), + transcript: None, + user_instructions: None, + project_instructions: None, + playbooks_dir: None, + ui_actions: None, + keep_files: false, + } +} + +const UUID: &str = "00000000-0000-4000-8000-0000000000c1"; + +fn after<'a>(args: &'a [String], flag: &str) -> &'a str { + let i = args + .iter() + .position(|a| a == flag) + .unwrap_or_else(|| panic!("{flag} in {args:?}")); + &args[i + 1] +} + +#[test] +fn claude_runs_with_no_tools_but_openxers_and_none_of_the_users_settings() { + let dir = tempfile::tempdir().unwrap(); + let o = options( + Agent::ClaudeCode, + dir.path(), + ChatMode::Ask, + ModelChoice::AgentDefault, + ); + let config = claude::config_path(&o); + let args = claude::arguments(&o, &config, Path::new("RULES.md"), None).unwrap(); + for flag in [ + "-p", + "--restricted", + "--strict-mcp-config", + "--disable-slash-commands", + ] { + assert!(args.iter().any(|a| a == flag), "{flag}"); + } + assert_eq!(after(&args, "--tools"), ""); + assert_eq!(after(&args, "--permission-prompts"), "none"); + // The instructions come from a file, never on the command line. + assert_eq!(after(&args, "--system-prompt-file"), "RULES.md"); + assert!(!args.iter().any(|a| a == "--system-prompt")); + assert_eq!(after(&args, "--input-format"), "stream-json"); + assert_eq!(after(&args, "--mcp-config"), config.display().to_string()); + let allowed = after(&args, "--allowedTools"); + assert!(!allowed.contains("openxer_apply"), "Ask mode: {allowed}"); + assert!(allowed + .split(',') + .all(|t| t.starts_with("mcp__openxer__openxer_"))); + assert!(!args.iter().any(|a| a == "--model" || a == "--resume")); + let edit = options( + Agent::ClaudeCode, + dir.path(), + ChatMode::Edit, + ModelChoice::LowerCost, + ); + let args = claude::arguments(&edit, &config, Path::new("RULES.md"), Some(UUID)).unwrap(); + assert!(after(&args, "--allowedTools").contains("mcp__openxer__openxer_apply")); + assert_eq!(after(&args, "--model"), claude::LOWER_COST_MODEL); + assert_eq!(after(&args, "--resume"), UUID); + assert!(claude::arguments(&edit, &config, Path::new("RULES.md"), Some("-x")).is_err()); + let named = options( + Agent::ClaudeCode, + dir.path(), + ChatMode::Ask, + ModelChoice::Named("opus".into()), + ); + assert_eq!( + after( + &claude::arguments(&named, &config, Path::new("R.md"), None).unwrap(), + "--model" + ), + "opus" + ); + // The MCP config holds only the chat server, on the snapshot. + let c = claude::mcp_config(&edit); + let servers = c["mcpServers"].as_object().unwrap(); + assert_eq!(servers.len(), 1); + let args: Vec<&str> = servers["openxer"]["args"] + .as_array() + .unwrap() + .iter() + .map(|a| a.as_str().unwrap()) + .collect(); + assert_eq!(&args[..3], ["mcp", "--toolset", "chat"]); + assert!(args.contains(&"--snapshot") && args.contains(&"edit")); + assert_eq!( + servers["openxer"]["env"]["OPENXER_DATA_DIR"], + json!(dir.path().join("data")) + ); + assert_eq!( + claude::user_line("hi"), + r#"{"message":{"content":[{"text":"hi","type":"text"}],"role":"user"},"type":"user"}"# + ); +} + +#[test] +fn codex_runs_read_only_with_its_extras_off_and_only_the_openxer_server() { + let dir = tempfile::tempdir().unwrap(); + let o = options( + Agent::Codex, + dir.path(), + ChatMode::Ask, + ModelChoice::AgentDefault, + ); + let args = codex::arguments(&o, None).unwrap(); + assert_eq!(args[0], "exec"); + assert_ne!(args[1], "resume"); + for flag in [ + "--json", + "--skip-git-repo-check", + "--ignore-user-config", + "--ignore-rules", + ] { + assert!(args.iter().any(|a| a == flag), "{flag}"); + } + assert!( + !args.iter().any(|a| a == "--ephemeral"), + "resume needs the saved thread" + ); + let configs: Vec<&str> = args + .windows(2) + .filter(|w| w[0] == "-c") + .map(|w| w[1].as_str()) + .collect(); + for expected in [ + "sandbox_mode=\"read-only\"", + "approval_policy=\"never\"", + "web_search=\"disabled\"", + "include_environment_context=false", + "project_doc_max_bytes=0", + "mcp_servers.openxer.startup_timeout_sec=30", + ] { + assert!(configs.contains(&expected), "{expected} in {configs:?}"); + } + let server_args = configs + .iter() + .find(|c| c.starts_with("mcp_servers.openxer.args=")) + .unwrap(); + assert!( + server_args.contains("\"--toolset\", \"chat\""), + "{server_args}" + ); + assert!(server_args.contains("\"ask\"")); + assert!(configs + .iter() + .any(|c| c.starts_with("mcp_servers.openxer.env={OPENXER_DATA_DIR="))); + assert!(configs + .iter() + .any(|c| c.starts_with("model_instructions_file="))); + let disabled: Vec<&str> = args + .windows(2) + .filter(|w| w[0] == "--disable") + .map(|w| w[1].as_str()) + .collect(); + for feature in [ + "shell_tool", + "unified_exec", + "multi_agent", + "plugins", + "apps", + ] { + assert!(disabled.contains(&feature), "{feature}"); + } + assert_eq!( + &args[args.len() - 2..], + ["--", "-"], + "the prompt comes on stdin" + ); + assert!(!args.iter().any(|a| a == "-m")); + let cheap = options( + Agent::Codex, + dir.path(), + ChatMode::Edit, + ModelChoice::LowerCost, + ); + let args = codex::arguments(&cheap, Some(UUID)).unwrap(); + assert_eq!(&args[..2], ["exec", "resume"]); + assert_eq!(&args[args.len() - 3..], ["--", UUID, "-"]); + assert!(codex::arguments(&cheap, Some("--dangerously-bypass-approvals-and-sandbox")).is_err()); + assert_eq!(after(&args, "-m"), codex::LOWER_COST_MODEL); + assert!(args.iter().any(|a| a == "model_reasoning_effort=\"low\"")); + // A path with a quote stays one TOML string. + let mut odd = options( + Agent::Codex, + dir.path(), + ChatMode::Ask, + ModelChoice::AgentDefault, + ); + odd.cli = PathBuf::from("C:\\it's here\\openxer-cli.exe"); + let args = codex::arguments(&odd, None).unwrap(); + let command = args + .iter() + .find(|a| a.starts_with("mcp_servers.openxer.command=")) + .unwrap(); + let value: toml_edit::Value = command.split_once('=').unwrap().1.parse().unwrap(); + assert_eq!(value.as_str(), Some("C:\\it's here\\openxer-cli.exe")); +} + +#[test] +fn the_rules_tell_the_agent_what_its_mode_allows() { + let dir = tempfile::tempdir().unwrap(); + let mut o = options( + Agent::Codex, + dir.path(), + ChatMode::Ask, + ModelChoice::AgentDefault, + ); + let ask = agent_host::rules(&o); + o.mode = ChatMode::Edit; + o.user_instructions = Some("Write dates as 12-Mar-27.".into()); + let edit = agent_host::rules(&o); + assert!(ask.starts_with(openxer_automation::chat_prompt::CORE)); + assert!(ask.ends_with(openxer_automation::chat_prompt::mode_line(ChatMode::Ask))); + assert!(ask.contains("read only")); + assert!(edit.contains("openxer_apply") && edit.contains("approves")); + assert!(edit.contains("Write dates as 12-Mar-27.")); + assert!(!ask.contains('\u{2014}') && !edit.contains('\u{2014}')); + let choices = model_choices(Agent::Codex); + assert_eq!(choices[0].0, ModelChoice::AgentDefault); + assert!(choices[1].1.contains(codex::LOWER_COST_MODEL)); + assert!(model_choices(Agent::ClaudeCode)[1].1.contains("sonnet")); +} + +// ----------------------------------------------------------- fake agent + +#[derive(Clone, Debug)] +enum Step { + Line(String), + /// Wait for one stdin line. + Read, + /// Keep running (and the output open) until stopped. + Hang, + /// Raw output bytes, as they are. + Bytes(Vec), + /// Keep running until stopped, then keep the output open anyway, as a + /// grandchild that holds the pipe would. + Orphan, + Exit(i32), +} + +#[derive(Clone, Debug, Default)] +struct Script { + steps: Vec, + stderr: Vec, +} + +fn lines(list: &[String]) -> Vec { + list.iter().map(|l| Step::Line(l.clone())).collect() +} + +#[derive(Default)] +struct Fake { + scripts: Mutex>, + launches: Mutex>, + stdin: Arc>>, + alive: Arc, + missing: bool, +} + +impl Fake { + fn new(scripts: Vec", +]; + +#[test] +fn hostile_names_export_as_inert_text() { + let old = scheduled_starter(); + let mut new = old.clone(); + for (n, name) in HOSTILE.iter().enumerate() { + let task_id = new.model.activities[n].task_id; + new.details.get_mut(&task_id).unwrap().name = name.to_string(); + } + new.model.activities[3].task_code = "@SUM(A1)".into(); + let r = report::report(&compare(&old, "a", &new, "b", &Options::default())); + let dir = temp("injection"); + // CSV: a leading quote, then normal quoting. + let path = dir.join("r.csv"); + doc::write(&r, Output::Csv, &path).unwrap(); + let csv = std::fs::read_to_string(&path).unwrap(); + assert!( + csv.contains("\"'=HYPERLINK(\"\"http://x\"\",\"\"y\"\")\""), + "{csv}" + ); + assert!(csv.contains(",'+1+1,"), "{csv}"); + assert!(csv.contains("'@SUM(A1)"), "{csv}"); + for line in csv.lines() { + for field in line.split(',') { + // A plain signed number is a number, not a formula. + assert!( + !field.starts_with(['=', '+', '@', '-']) || field.parse::().is_ok(), + "unguarded field {field:?} in {line:?}" + ); + } + } + // Excel: string cells holding the exact text. + let path = dir.join("r.xlsx"); + doc::write(&r, Output::Excel, &path).unwrap(); + let wb = read_workbook(&path).unwrap(); + let texts: Vec = wb + .sheets + .iter() + .flat_map(|s| s.rows.iter().flatten()) + .filter_map(|c| match c { + Cell::Text(t) => Some(t.clone()), + _ => None, + }) + .collect(); + for name in HOSTILE.iter().chain(["@SUM(A1)"].iter()) { + assert!(texts.iter().any(|t| t == name), "{name} as text"); + } + // HTML: escaped, still well formed. + let page = html::write(&r); + html::well_formed(&page).unwrap(); + assert!(!page.contains("