@workit-dev/pi 1.14.2 → 1.14.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/workit.js +13 -1
  2. package/package.json +1 -1
package/dist/workit.js CHANGED
@@ -24773,8 +24773,18 @@ var WORKIT_USER_ONLY = [
24773
24773
  ["grant", "set"],
24774
24774
  ["grant", "raise"],
24775
24775
  ["ledger", "void"],
24776
- ["approve"]
24776
+ ["approve"],
24777
+ ["setup"],
24778
+ ["uninstall"],
24779
+ ["install"],
24780
+ ["workspace", "seal"]
24777
24781
  ];
24782
+ var USER_ONLY_WORD = new RegExp(`\\b(?:${[...new Set(WORKIT_USER_ONLY.map((words) => words[0]))].join("|")})\\b`);
24783
+ var mayRunUserOnly = (text) => {
24784
+ const joined = text.replace(/\\\r?\n/g, "");
24785
+ const bare = joined.replace(/['"\\]/g, "");
24786
+ return [bare, bare.replace(/`/g, "")].some((all) => /\bworkit\b/.test(all) && (USER_ONLY_WORD.test(all) || /\$['"]/.test(joined)));
24787
+ };
24778
24788
  var ALLOWED = new Set(WORKIT_ALLOWED_VERBS);
24779
24789
  var hasWordsInOrder = (words, needle) => {
24780
24790
  let at = 0;
@@ -24807,6 +24817,8 @@ var workitBypassFlag = (command, dialect = "posix") => {
24807
24817
  return null;
24808
24818
  };
24809
24819
  var userOnlyWorkitCall = (command, dialect = "posix") => {
24820
+ if (!mayRunUserOnly(command))
24821
+ return null;
24810
24822
  for (const segment of segmentsOf(command, dialect)) {
24811
24823
  if (segment.unanalyzable)
24812
24824
  continue;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workit-dev/pi",
3
- "version": "1.14.2",
3
+ "version": "1.14.3",
4
4
  "description": "Workit native extension for Pi — tools, method skills, and session continuity",
5
5
  "keywords": [
6
6
  "agentic-coding",