@orderful/droid 0.2.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 (86) hide show
  1. package/.changeset/README.md +30 -0
  2. package/.changeset/config.json +14 -0
  3. package/.eslintrc.json +20 -0
  4. package/.github/PULL_REQUEST_TEMPLATE.md +9 -0
  5. package/.github/workflows/ci.yml +47 -0
  6. package/.github/workflows/release.yml +45 -0
  7. package/CHANGELOG.md +11 -0
  8. package/README.md +153 -0
  9. package/bun.lock +571 -0
  10. package/dist/bin/droid.d.ts +3 -0
  11. package/dist/bin/droid.d.ts.map +1 -0
  12. package/dist/bin/droid.js +48 -0
  13. package/dist/bin/droid.js.map +1 -0
  14. package/dist/commands/config.d.ts +8 -0
  15. package/dist/commands/config.d.ts.map +1 -0
  16. package/dist/commands/config.js +67 -0
  17. package/dist/commands/config.js.map +1 -0
  18. package/dist/commands/install.d.ts +2 -0
  19. package/dist/commands/install.d.ts.map +1 -0
  20. package/dist/commands/install.js +42 -0
  21. package/dist/commands/install.js.map +1 -0
  22. package/dist/commands/setup.d.ts +2 -0
  23. package/dist/commands/setup.d.ts.map +1 -0
  24. package/dist/commands/setup.js +132 -0
  25. package/dist/commands/setup.js.map +1 -0
  26. package/dist/commands/skills.d.ts +2 -0
  27. package/dist/commands/skills.d.ts.map +1 -0
  28. package/dist/commands/skills.js +135 -0
  29. package/dist/commands/skills.js.map +1 -0
  30. package/dist/commands/uninstall.d.ts +2 -0
  31. package/dist/commands/uninstall.d.ts.map +1 -0
  32. package/dist/commands/uninstall.js +17 -0
  33. package/dist/commands/uninstall.js.map +1 -0
  34. package/dist/commands/update.d.ts +7 -0
  35. package/dist/commands/update.d.ts.map +1 -0
  36. package/dist/commands/update.js +45 -0
  37. package/dist/commands/update.js.map +1 -0
  38. package/dist/index.d.ts +5 -0
  39. package/dist/index.d.ts.map +1 -0
  40. package/dist/index.js +6 -0
  41. package/dist/index.js.map +1 -0
  42. package/dist/lib/config.d.ts +46 -0
  43. package/dist/lib/config.d.ts.map +1 -0
  44. package/dist/lib/config.js +133 -0
  45. package/dist/lib/config.js.map +1 -0
  46. package/dist/lib/skill-config.d.ts +6 -0
  47. package/dist/lib/skill-config.d.ts.map +1 -0
  48. package/dist/lib/skill-config.js +80 -0
  49. package/dist/lib/skill-config.js.map +1 -0
  50. package/dist/lib/skills.d.ts +56 -0
  51. package/dist/lib/skills.d.ts.map +1 -0
  52. package/dist/lib/skills.js +245 -0
  53. package/dist/lib/skills.js.map +1 -0
  54. package/dist/lib/types.d.ts +54 -0
  55. package/dist/lib/types.d.ts.map +1 -0
  56. package/dist/lib/types.js +31 -0
  57. package/dist/lib/types.js.map +1 -0
  58. package/dist/lib/version.d.ts +10 -0
  59. package/dist/lib/version.d.ts.map +1 -0
  60. package/dist/lib/version.js +41 -0
  61. package/dist/lib/version.js.map +1 -0
  62. package/dist/skills/comments/SKILL.md +65 -0
  63. package/dist/skills/comments/SKILL.yaml +18 -0
  64. package/dist/skills/comments/commands/comments.md +48 -0
  65. package/package.json +58 -0
  66. package/src/bin/droid.ts +58 -0
  67. package/src/commands/config.ts +86 -0
  68. package/src/commands/install.ts +48 -0
  69. package/src/commands/setup.ts +149 -0
  70. package/src/commands/skills.ts +159 -0
  71. package/src/commands/uninstall.ts +18 -0
  72. package/src/commands/update.ts +58 -0
  73. package/src/index.ts +5 -0
  74. package/src/lib/config.test.ts +99 -0
  75. package/src/lib/config.ts +154 -0
  76. package/src/lib/skill-config.ts +93 -0
  77. package/src/lib/skills.test.ts +138 -0
  78. package/src/lib/skills.ts +285 -0
  79. package/src/lib/types.test.ts +65 -0
  80. package/src/lib/types.ts +68 -0
  81. package/src/lib/version.test.ts +23 -0
  82. package/src/lib/version.ts +47 -0
  83. package/src/skills/comments/SKILL.md +65 -0
  84. package/src/skills/comments/SKILL.yaml +18 -0
  85. package/src/skills/comments/commands/comments.md +48 -0
  86. package/tsconfig.json +19 -0
@@ -0,0 +1,30 @@
1
+ # Changesets
2
+
3
+ This project uses [changesets](https://github.com/changesets/changesets) for version management and changelog generation.
4
+
5
+ ## Adding a changeset
6
+
7
+ When you make a change that should be released, run:
8
+
9
+ ```bash
10
+ bun changeset
11
+ ```
12
+
13
+ This will prompt you to:
14
+ 1. Select the package(s) affected
15
+ 2. Choose the semver bump type (major/minor/patch)
16
+ 3. Write a summary of the change
17
+
18
+ The changeset file will be created in `.changeset/` and should be committed with your PR.
19
+
20
+ ## Versioning guide
21
+
22
+ - **patch**: Bug fixes, documentation updates, internal refactors
23
+ - **minor**: New features, new skills, non-breaking enhancements
24
+ - **major**: Breaking changes to CLI interface or config format
25
+
26
+ ## Release process
27
+
28
+ Releases happen automatically when PRs with changesets are merged to `main`:
29
+ 1. A "Version Packages" PR is created/updated
30
+ 2. Merging that PR publishes to npm and creates GitHub releases
@@ -0,0 +1,14 @@
1
+ {
2
+ "$schema": "https://unpkg.com/@changesets/config@3.0.0/schema.json",
3
+ "changelog": [
4
+ "@changesets/changelog-github",
5
+ { "repo": "orderful/droid" }
6
+ ],
7
+ "commit": false,
8
+ "fixed": [],
9
+ "linked": [],
10
+ "access": "restricted",
11
+ "baseBranch": "main",
12
+ "updateInternalDependencies": "patch",
13
+ "ignore": []
14
+ }
package/.eslintrc.json ADDED
@@ -0,0 +1,20 @@
1
+ {
2
+ "env": {
3
+ "node": true,
4
+ "es2022": true
5
+ },
6
+ "extends": [
7
+ "eslint:recommended"
8
+ ],
9
+ "parser": "@typescript-eslint/parser",
10
+ "parserOptions": {
11
+ "ecmaVersion": "latest",
12
+ "sourceType": "module"
13
+ },
14
+ "plugins": ["@typescript-eslint"],
15
+ "rules": {
16
+ "no-unused-vars": "off",
17
+ "@typescript-eslint/no-unused-vars": ["error", { "argsIgnorePattern": "^_" }]
18
+ },
19
+ "ignorePatterns": ["dist/", "node_modules/", "*.test.ts"]
20
+ }
@@ -0,0 +1,9 @@
1
+ ## Summary
2
+
3
+ <!-- Brief description of changes -->
4
+
5
+ ## Test Plan
6
+
7
+ <!-- How to test these changes -->
8
+
9
+ ---
@@ -0,0 +1,47 @@
1
+ name: CI
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [main]
6
+ push:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ test:
11
+ name: Test
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - name: Checkout
15
+ uses: actions/checkout@v4
16
+
17
+ - name: Setup Bun
18
+ uses: oven-sh/setup-bun@v2
19
+ with:
20
+ bun-version: latest
21
+
22
+ - name: Install dependencies
23
+ run: bun install
24
+
25
+ - name: Build
26
+ run: bun run build
27
+
28
+ - name: Test
29
+ run: bun test src/
30
+
31
+ lint:
32
+ name: Lint
33
+ runs-on: ubuntu-latest
34
+ steps:
35
+ - name: Checkout
36
+ uses: actions/checkout@v4
37
+
38
+ - name: Setup Bun
39
+ uses: oven-sh/setup-bun@v2
40
+ with:
41
+ bun-version: latest
42
+
43
+ - name: Install dependencies
44
+ run: bun install
45
+
46
+ - name: Lint
47
+ run: bun run lint
@@ -0,0 +1,45 @@
1
+ name: Release
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+
7
+ concurrency: ${{ github.workflow }}-${{ github.ref }}
8
+
9
+ jobs:
10
+ release:
11
+ name: Release
12
+ runs-on: ubuntu-latest
13
+ permissions:
14
+ contents: write
15
+ pull-requests: write
16
+ id-token: write
17
+ steps:
18
+ - name: Checkout
19
+ uses: actions/checkout@v4
20
+
21
+ - name: Setup Bun
22
+ uses: oven-sh/setup-bun@v2
23
+ with:
24
+ bun-version: latest
25
+
26
+ - name: Install dependencies
27
+ run: bun install
28
+
29
+ - name: Build
30
+ run: bun run build
31
+
32
+ - name: Test
33
+ run: bun test src/
34
+
35
+ - name: Create Release Pull Request or Publish
36
+ id: changesets
37
+ uses: changesets/action@v1
38
+ with:
39
+ version: bun changeset version
40
+ publish: bun changeset publish
41
+ title: "chore: version packages"
42
+ commit: "chore: version packages"
43
+ env:
44
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45
+ NPM_TOKEN: ${{ secrets.ORDERFUL_NPM_TOKEN }}
package/CHANGELOG.md ADDED
@@ -0,0 +1,11 @@
1
+ # @orderful/droid
2
+
3
+ ## 0.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1](https://github.com/Orderful/droid/pull/1) [`5deb7b2`](https://github.com/Orderful/droid/commit/5deb7b2aa3c4510940cfc2336e3600de071a40a1) Thanks [@frytyler](https://github.com/frytyler)! - Initial release of @orderful/droid - AI workflow toolkit
8
+ - CLI commands: `droid setup`, `droid config`, `droid skills`, `droid install`, `droid update`
9
+ - First skill: `comments` - inline conversation via `@droid`/`@user` markers
10
+ - Config system with global and per-skill overrides
11
+ - Support for Claude Code and OpenCode
package/README.md ADDED
@@ -0,0 +1,153 @@
1
+ # @orderful/droid
2
+
3
+ **"Teaching your droid new tricks"**
4
+
5
+ AI workflow toolkit for sharing skills, commands, and agents across the engineering team.
6
+
7
+ ### Why Droid?
8
+
9
+ - **Lower the barrier to entry** - Get started with AI coding tools (Claude Code, OpenCode) without configuring skills and commands from scratch
10
+ - **Share what works** - Power users discover great workflows, everyone benefits
11
+ - **Consistent experience** - Common patterns like `@droid`/`@user` comments work the same across the team
12
+
13
+ ## Installation
14
+
15
+ ```bash
16
+ npm install -g @orderful/droid
17
+ ```
18
+
19
+ ## Quick Start
20
+
21
+ ```bash
22
+ # Initial setup - configure your AI tool and preferences
23
+ droid setup
24
+
25
+ # Browse available skills
26
+ droid skills
27
+
28
+ # Install a skill
29
+ droid install comments
30
+
31
+ # View/edit your config
32
+ droid config
33
+ droid config -e # Open in editor
34
+ ```
35
+
36
+ ## What is Droid?
37
+
38
+ Droid is a CLI tool that helps you install and manage AI workflow extensions (skills, commands, agents) for tools like Claude Code and OpenCode.
39
+
40
+ ### Core Concepts
41
+
42
+ - **Skills** - Teach your AI new capabilities (e.g., inline comments, PR workflows)
43
+ - **Commands** - Slash commands that invoke skill functionality (e.g., `/comments check`)
44
+ - **Config** - Global and per-skill configuration stored in `~/.droid/`
45
+
46
+ ### Directory Structure
47
+
48
+ ```
49
+ ~/.droid/
50
+ ├── config.yaml # Global config
51
+ └── skills/
52
+ └── {skill}/
53
+ └── overrides.yaml # Per-skill config overrides
54
+ ```
55
+
56
+ Skills are installed to your AI tool's location:
57
+ - **Claude Code**: `~/.claude/skills/` and `~/.claude/commands/`
58
+ - **OpenCode**: `~/.config/opencode/skills/` and `~/.config/opencode/command/`
59
+
60
+ ## Available Skills
61
+
62
+ ### `comments` (v0.1.0 - beta)
63
+
64
+ Inline conversation in any file via `@droid`/`@user` markers.
65
+
66
+ ```markdown
67
+ > @droid What do you think of this approach?
68
+
69
+ > @fry I think this approach is solid. One consideration...
70
+ ```
71
+
72
+ **Commands:**
73
+ - `/comments check` - Address all `@droid` comments
74
+ - `/comments cleanup` - Remove resolved comment threads
75
+
76
+ ## Configuration
77
+
78
+ ### Global Config (`~/.droid/config.yaml`)
79
+
80
+ ```yaml
81
+ ai_tool: claude-code # claude-code | opencode
82
+ user_mention: "@fry" # Your @mention for responses
83
+ output_preference: terminal # terminal | editor | brain
84
+ git_username: "frytyler"
85
+ skills: {} # Installed skills with versions
86
+ ```
87
+
88
+ ### Skill Overrides
89
+
90
+ Each skill can have its own config in `~/.droid/skills/{skill}/overrides.yaml`:
91
+
92
+ ```yaml
93
+ # ~/.droid/skills/comments/overrides.yaml
94
+ preserve_comments: true
95
+ ```
96
+
97
+ ## CLI Commands
98
+
99
+ | Command | Description |
100
+ |---------|-------------|
101
+ | `droid setup` | Interactive setup wizard |
102
+ | `droid config` | View current config |
103
+ | `droid config -e` | Edit config in $EDITOR |
104
+ | `droid config --get <key>` | Get a config value |
105
+ | `droid config --set <key=value>` | Set a config value |
106
+ | `droid skills` | Interactive skill browser |
107
+ | `droid install <skill>` | Install a skill |
108
+ | `droid update` | Update droid and skills |
109
+
110
+ ## Development
111
+
112
+ ```bash
113
+ # Clone and install
114
+ git clone https://github.com/orderful/droid.git
115
+ cd droid
116
+ npm install
117
+
118
+ # Build
119
+ npm run build
120
+
121
+ # Run locally
122
+ node dist/bin/droid.js --help
123
+ ```
124
+
125
+ ## Roadmap
126
+
127
+ ### Phase 1: Foundation (Current)
128
+ - [x] CLI structure
129
+ - [x] Config management
130
+ - [x] `comments` skill
131
+
132
+ ### Phase 2: Core Skills
133
+ - [ ] `pr` - PR workflow with configurable output
134
+ - [ ] `brain` - Collaborative thinking space (Obsidian vault)
135
+ - [ ] `playwright` - UI testing with Playwright MCP
136
+
137
+ ### Phase 3: Polish
138
+ - [ ] `droid update` with version checks
139
+ - [ ] `droid feedback` - Slack the skill author
140
+ - [ ] Contributor tooling
141
+
142
+ ## Contributing
143
+
144
+ Skills are bundled with the package. To add a new skill:
145
+
146
+ 1. Create `src/skills/{name}/SKILL.yaml` (manifest)
147
+ 2. Create `src/skills/{name}/SKILL.md` (skill instructions)
148
+ 3. Create `src/skills/{name}/commands/*.md` (commands)
149
+ 4. Submit a PR
150
+
151
+ ## License
152
+
153
+ MIT