skilluse 0.8.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/cli.js +125 -38
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -66477,8 +66477,8 @@ var AGENTS = {
66477
66477
  id: "opencode",
66478
66478
  name: "OpenCode",
66479
66479
  description: "OpenCode CLI",
66480
- localPath: ".opencode/skills",
66481
- globalPath: join(homedir2(), ".opencode/skills")
66480
+ localPath: ".opencode/skill",
66481
+ globalPath: join(homedir2(), ".config/opencode/skill")
66482
66482
  },
66483
66483
  letta: {
66484
66484
  id: "letta",
@@ -67802,11 +67802,23 @@ function Install({ args: [skillName], options: opts }) {
67802
67802
  setState({ phase: "no_repos" });
67803
67803
  return;
67804
67804
  }
67805
- const allRepos = config2.repos;
67806
- for (const repo2 of allRepos) {
67807
- setState({ phase: "searching", repo: repo2.repo });
67805
+ let searchRepos;
67806
+ if (config2.defaultRepo) {
67807
+ const defaultRepoConfig = config2.repos.find((r) => r.repo === config2.defaultRepo);
67808
+ if (defaultRepoConfig) {
67809
+ searchRepos = [defaultRepoConfig];
67810
+ } else {
67811
+ setState({
67812
+ phase: "error",
67813
+ message: `Default repo "${config2.defaultRepo}" not found in configured repos`
67814
+ });
67815
+ return;
67816
+ }
67817
+ } else {
67818
+ searchRepos = config2.repos;
67808
67819
  }
67809
- const findResult = await findSkill(token, allRepos, source.name);
67820
+ setState({ phase: "searching", repo: searchRepos[0].repo });
67821
+ const findResult = await findSkill(token, searchRepos, source.name);
67810
67822
  if ("authRequired" in findResult) {
67811
67823
  setState({ phase: "auth_required", message: findResult.message });
67812
67824
  return;
@@ -68134,16 +68146,23 @@ function Install({ args: [skillName], options: opts }) {
68134
68146
  ]
68135
68147
  }, undefined, true, undefined, this),
68136
68148
  /* @__PURE__ */ jsx_dev_runtime10.jsxDEV(Box_default, {
68149
+ flexDirection: "column",
68137
68150
  marginTop: 1,
68138
- children: /* @__PURE__ */ jsx_dev_runtime10.jsxDEV(Text, {
68139
- dimColor: true,
68140
- children: [
68141
- "Try 'skilluse search ",
68142
- state.skillName,
68143
- "' to find available skills."
68144
- ]
68145
- }, undefined, true, undefined, this)
68146
- }, undefined, false, undefined, this)
68151
+ children: [
68152
+ /* @__PURE__ */ jsx_dev_runtime10.jsxDEV(Text, {
68153
+ dimColor: true,
68154
+ children: [
68155
+ "Try 'skilluse search ",
68156
+ state.skillName,
68157
+ "' to find available skills."
68158
+ ]
68159
+ }, undefined, true, undefined, this),
68160
+ /* @__PURE__ */ jsx_dev_runtime10.jsxDEV(Text, {
68161
+ dimColor: true,
68162
+ children: "Or install from a specific repo: skilluse install https://github.com/owner/repo/tree/main/skill-name"
68163
+ }, undefined, false, undefined, this)
68164
+ ]
68165
+ }, undefined, true, undefined, this)
68147
68166
  ]
68148
68167
  }, undefined, true, undefined, this);
68149
68168
  case "conflict":
@@ -68609,7 +68628,6 @@ function Login(_props) {
68609
68628
  phase: "no_installation",
68610
68629
  installUrl: "https://github.com/apps/skilluse/installations/new"
68611
68630
  });
68612
- exit();
68613
68631
  return;
68614
68632
  }
68615
68633
  if (installations.length === 0) {
@@ -68617,7 +68635,6 @@ function Login(_props) {
68617
68635
  phase: "no_installation",
68618
68636
  installUrl: "https://github.com/apps/skilluse/installations/new"
68619
68637
  });
68620
- exit();
68621
68638
  return;
68622
68639
  }
68623
68640
  const storedInstallations = installations.map((inst) => ({
@@ -68635,10 +68652,14 @@ function Login(_props) {
68635
68652
  username,
68636
68653
  installations: storedInstallations
68637
68654
  });
68638
- exit();
68639
68655
  }
68640
68656
  runLogin();
68641
68657
  }, [exit]);
68658
+ import_react35.useEffect(() => {
68659
+ if (state.phase === "success" || state.phase === "no_installation") {
68660
+ exit();
68661
+ }
68662
+ }, [state.phase, exit]);
68642
68663
  switch (state.phase) {
68643
68664
  case "requesting_code":
68644
68665
  return /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Spinner2, {
@@ -68727,25 +68748,51 @@ function Login(_props) {
68727
68748
  flexDirection: "column",
68728
68749
  children: [
68729
68750
  /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68730
- dimColor: true,
68731
- children: [
68732
- state.installations.length,
68733
- " installation",
68734
- state.installations.length > 1 ? "s" : "",
68735
- " found:"
68736
- ]
68737
- }, undefined, true, undefined, this),
68738
- state.installations.map((inst) => /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68739
- dimColor: true,
68751
+ children: "App installed on:"
68752
+ }, undefined, false, undefined, this),
68753
+ state.installations.map((inst) => /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Box_default, {
68754
+ marginLeft: 2,
68740
68755
  children: [
68741
- "• ",
68742
- inst.account,
68743
- " (",
68744
- inst.accountType.toLowerCase(),
68745
- ")"
68756
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68757
+ color: "green",
68758
+ children: "*"
68759
+ }, undefined, false, undefined, this),
68760
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68761
+ children: [
68762
+ " ",
68763
+ inst.account
68764
+ ]
68765
+ }, undefined, true, undefined, this),
68766
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68767
+ dimColor: true,
68768
+ children: [
68769
+ " ",
68770
+ "(",
68771
+ inst.accountType.toLowerCase(),
68772
+ ",",
68773
+ " ",
68774
+ inst.repositorySelection === "all" ? "all repos" : "selected repos",
68775
+ ")"
68776
+ ]
68777
+ }, undefined, true, undefined, this)
68746
68778
  ]
68747
68779
  }, inst.id, true, undefined, this))
68748
68780
  ]
68781
+ }, undefined, true, undefined, this),
68782
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Box_default, {
68783
+ marginTop: 1,
68784
+ flexDirection: "column",
68785
+ children: [
68786
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68787
+ dimColor: true,
68788
+ children: "To publish skills to other orgs, install the App there first:"
68789
+ }, undefined, false, undefined, this),
68790
+ /* @__PURE__ */ jsx_dev_runtime12.jsxDEV(Text, {
68791
+ color: "cyan",
68792
+ dimColor: true,
68793
+ children: "https://github.com/apps/skilluse/installations/new"
68794
+ }, undefined, false, undefined, this)
68795
+ ]
68749
68796
  }, undefined, true, undefined, this)
68750
68797
  ]
68751
68798
  }, undefined, true, undefined, this);
@@ -71638,11 +71685,51 @@ function Publish({ args: [skillName] }) {
71638
71685
  ]
71639
71686
  }, undefined, true, undefined, this);
71640
71687
  case "no_write_access":
71641
- return /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(StatusMessage, {
71642
- type: "error",
71688
+ return /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(jsx_dev_runtime25.Fragment, {
71643
71689
  children: [
71644
- "No write access to repo: ",
71645
- state.repo
71690
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(StatusMessage, {
71691
+ type: "error",
71692
+ children: [
71693
+ "No write access to repo: ",
71694
+ state.repo
71695
+ ]
71696
+ }, undefined, true, undefined, this),
71697
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Box_default, {
71698
+ marginTop: 1,
71699
+ flexDirection: "column",
71700
+ children: [
71701
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71702
+ dimColor: true,
71703
+ children: "Possible causes:"
71704
+ }, undefined, false, undefined, this),
71705
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71706
+ dimColor: true,
71707
+ children: "1. Skilluse App not installed on this org/account"
71708
+ }, undefined, false, undefined, this),
71709
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71710
+ dimColor: true,
71711
+ children: "2. App not granted access to this specific repo"
71712
+ }, undefined, false, undefined, this)
71713
+ ]
71714
+ }, undefined, true, undefined, this),
71715
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Box_default, {
71716
+ marginTop: 1,
71717
+ flexDirection: "column",
71718
+ children: [
71719
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71720
+ dimColor: true,
71721
+ children: "Install or configure the App for this repo:"
71722
+ }, undefined, false, undefined, this),
71723
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71724
+ color: "cyan",
71725
+ children: "https://github.com/apps/skilluse/installations/new"
71726
+ }, undefined, false, undefined, this),
71727
+ /* @__PURE__ */ jsx_dev_runtime25.jsxDEV(Text, {
71728
+ dimColor: true,
71729
+ children: "Then run 'skilluse login' to refresh your token."
71730
+ }, undefined, false, undefined, this)
71731
+ ]
71732
+ }, undefined, true, undefined, this)
71646
71733
  ]
71647
71734
  }, undefined, true, undefined, this);
71648
71735
  case "repo_not_found":
@@ -71717,7 +71804,7 @@ function Publish({ args: [skillName] }) {
71717
71804
  // package.json
71718
71805
  var package_default = {
71719
71806
  name: "skilluse",
71720
- version: "0.8.0",
71807
+ version: "0.10.0",
71721
71808
  description: "CLI tool for managing and installing AI Coding Agent Skills",
71722
71809
  main: "dist/cli.js",
71723
71810
  bin: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "skilluse",
3
- "version": "0.8.0",
3
+ "version": "0.10.0",
4
4
  "description": "CLI tool for managing and installing AI Coding Agent Skills",
5
5
  "main": "dist/cli.js",
6
6
  "bin": {