Skip to content

Commit 58669f3

Browse files
Add completions, upload script, defaults, tests, AI workflow, docs, fixes and new resources (#27)
* feat: Add uv and tests * feat: Add rbenv and tests * feat: Add rbenv and tests * feat: Fixed ollama tests * feat: Added new integration test for everything * feat: Test workflow by adding push * fix: disable cron until I can get it to work * feat: Added syncthing support * fix: bug fixes * fix: fixed syncthing bugs and fixed test runner bug * feat: Add file based completions files. And moved the completions cron to this repo * feat: Improved folder naming and added README documentation * feat: Added completions for asdf * feat: Added completions for apt * feat: Added completions for npm and pip * feat: Added uv completions and rb completions and test completions script * feat: Changed npm install to a single string command instead of string + object. * feat: Added completions for ollama, pnpm and snap * feat: Modified the deploy script to deploy each resource directly to the db as well. Modified the build script to build the original json schema. Bump to version 1.1.0 * feat: Modified the deploy script to deploy each resource directly to the db as well. Modified the build script to build the original json schema. Bump to version 1.1.0 * feat: Modified the build script to build a metadata.json * fix: Fix path and aliases imports * feat: Add support on db side for example and default parameters * feat: Added example and defaults for path, aliases, ssh-config * feat: Added alias resource and syncthing * feat: Added asdf and aws * feat: Added apt, npm login, nvm and pnpm * breaking: Removed object option from apt. Split git-repository into singular and plural versions * feat: Added homebrew, git, git-lfs, examples, aws-profile, aws-cli * feat: Added python tools * feat: Added action, package-managers, tart, terraform, ollama, and files. Added new skill for generating examples * feat: Fixes jenv for linux * feat: Fixes testing harness for linux. Fix syncthing for linux * fix: nvm test for now and moved nvm destroy out of npm-login and npm tests (the testing environment relies on nvm) * fix: rbenv, terraform, aliases, apt, and snap * fix: Fixed a bunch of resources not pre-installing curl and unzip if it doesn't exist. Added fixes for alias, android-studio (linux support), asdf, aws-cli, npm, npm-login, nvm, ollama, pyenv, terraform, uv * fix: Fixes for docker and uv. Added global parameter for uv * fix: Fixes for docker and pnpm. Improved python tests by switching to uv * feat: improved run all test * feat: temp add push to test * Kevin/automated testing (#28) Added automated tests on github actions: Shard macOS and linux tests to improve speed Fix testing problems Fix platform problems (had to integrate the existing tests with the differences between tart and the github actions runner) Fixed structural problems Added claude to run on test failure to attempt to auto fixing * Added testing change to enable tests for example and default configs. Added push to test changes. * Fixes the distro not being in schema by adding to schema * Update plugin lib library as well * Updated libs and fix error * Disable test on push. Homebrew fixes * Tap fix * Omit system from nvm import * Switch homebrew back askpass * Switch homebrew to use askpass * Imrpove beta deploys (just deploy with the version as -beta now * Add adopt parameter to brew install * feat: Added minCliVersion support * fix: Fixed cask parameter installations. Fixed docker deteching volume breaking entire apply. Filter corepack out of npm install * fix: allow asdf to allow multiple. Added description to homebrew schema * fix: Disable import for git repository, fix import for macports install, allow pnpm to query the version * fix: Path not importing correctly * feat: Added env-var resource * fix: Fixed terraform latest version and uv global parameter * fix: Fixes for docker, ollama, ssh-add and uv * chore: bumped package version * feat: Updated test name. Added fix for pnpm * fix: Fix for git * fix: Fix for git * fix: Enable test on push temp * fix: Move workflow dispatch to top * fix: Pnpm and apt tests * temp add push tags * Macports fix * feat: Moved documentation over from main-site * feat: Added missing documentation * feat: Moved homebrew and other package managers to a dedicated package managers folder. Fixed broken links. * feat: Added actions for automated AI based resource creation * Update automated test to run on Mon, Wed, Saturday instead of every day
1 parent db2b03e commit 58669f3

231 files changed

Lines changed: 28599 additions & 6603 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.circleci/config.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
version: 2.1
2+
3+
jobs:
4+
test:
5+
parameters:
6+
executor:
7+
type: executor
8+
executor: << parameters.executor >>
9+
steps:
10+
- checkout
11+
- node/install:
12+
node-version: '24'
13+
- run:
14+
name: Enable linger for current user (Linux only)
15+
command: |
16+
if [[ "$OSTYPE" == "linux"* ]]; then
17+
loginctl enable-linger $(whoami)
18+
sudo chown -R circleci:circleci /usr/local /opt /var/tmp
19+
fi
20+
- run:
21+
name: Install dependencies
22+
command: npm ci
23+
- run:
24+
name: Clean up pre-installed tools
25+
command: npx tsx scripts/cleanup-circleci.ts
26+
no_output_timeout: 10m
27+
- run:
28+
name: Run tests
29+
command: npm run test -- ./test --no-file-parallelism --disable-console-intercept
30+
no_output_timeout: 30m
31+
32+
orbs:
33+
node: circleci/node@6
34+
35+
executors:
36+
linux-x86:
37+
machine:
38+
image: ubuntu-2404:current
39+
resource_class: medium
40+
linux-arm:
41+
machine:
42+
image: ubuntu-2404:current
43+
resource_class: arm.medium
44+
macos:
45+
macos:
46+
xcode: '26.4.0'
47+
resource_class: m4pro.medium
48+
49+
#workflows:
50+
# test-all:
51+
# jobs:
52+
# - test:
53+
# matrix:
54+
# parameters:
55+
# executor: [linux-arm]

.claude/commands/add-examples.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# add-examples
2+
3+
Add `defaultConfig` and `exampleConfigs` to a Codify resource.
4+
5+
## Instructions
6+
7+
The user will either pass a file path as an argument (`$ARGUMENTS`) or have a file open in the IDE. Read the resource file, then follow the rules below to add `defaultConfig` and `exampleConfigs`.
8+
9+
If `$ARGUMENTS` is provided, use that file path. Otherwise use the file the user has open.
10+
11+
### Step 1 — Read the resource
12+
13+
Read the resource file. Identify:
14+
- The config interface/type (fields, which are required vs optional)
15+
- `operatingSystems` declared in `getSettings()` — determines whether to add `os` to examples
16+
- `dependencies` — used to decide whether to show a multi-resource example
17+
- Any existing `defaultConfig` or `exampleConfigs` (update rather than duplicate)
18+
19+
If the schema is a separate JSON file, read it too.
20+
21+
Also check for sibling resources that are commonly used together (e.g. if this resource `dependsOn` another type, read that type's file to understand its config shape).
22+
23+
### Step 2 — Add `defaultConfig`
24+
25+
Rules:
26+
- Type: `Partial<TheConfig>` (never include `os` — it's not on the typed config interface)
27+
- For required fields with no sensible default: use the placeholder string `'<Replace me here!'>`
28+
- For optional arrays that default to empty: set to `[]`
29+
- Omit fields that are purely user-specific (paths, names, credentials)
30+
- Use the tool's own documented defaults where applicable
31+
32+
### Step 3 — Add `exampleConfigs`
33+
34+
Rules:
35+
- Up to two examples: `example1` and `example2`
36+
- **No trivial examples** — every example must have meaningful configuration, not just `{ type: 'foo' }` with no parameters
37+
- `example1`: the most common real-world use case with substantive config values
38+
- `example2`: a more advanced variant OR a multi-resource example showing full end-to-end setup; multi-resource is preferred when the resource `dependsOn` another
39+
- Every example needs a `title` (short noun-phrase) and a `description` (one sentence)
40+
- Use realistic placeholder values for sensitive fields (`'<Replace me here!'>`), not real credentials
41+
- Do not add step-numbering in descriptions
42+
43+
**`os` field in examples:**
44+
- The `os` field values come from the `ResourceOs` enum in `@codifycli/schemas` (`../codify-schemas/src/types/index.ts`): `'macOS'`, `'linux'`, `'windows'`
45+
- Add `os` to config entries inside examples only when `operatingSystems` is restricted to a single OS (e.g. Darwin-only → `os: ['macOS']`, Linux-only → `os: ['linux']`)
46+
- Skip `os` entirely when the resource supports both Darwin and Linux
47+
48+
**Shared examples:**
49+
- When a multi-resource example is used across multiple related resources (e.g. asdf + asdf-plugin + asdf-install), define it once in a shared `examples.ts` file in the resource folder and spread it in with `...exampleSharedConfigs`
50+
51+
### Step 4 — Import `ExampleConfig`
52+
53+
Add `ExampleConfig` to the existing `@codifycli/plugin-core` import if not already present.
54+
55+
### Step 5 — Register in `getSettings()`
56+
57+
Add `defaultConfig` and `exampleConfigs` fields inside the object returned by `getSettings()`, before `operatingSystems`.
58+
59+
## Output format
60+
61+
Make all edits directly to the file. Do not summarise every line changed — just briefly confirm what was added.

.fleet/run.json

Lines changed: 0 additions & 47 deletions
This file was deleted.

.fleet/settings.json

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: New Resource Request
2+
description: Request a new Codify resource — it will be automatically generated, tested, and queued for human review.
3+
title: "New resource request: "
4+
labels: ["New resource request"]
5+
body:
6+
- type: input
7+
id: tool_name
8+
attributes:
9+
label: Tool Name
10+
description: The name of the tool or application
11+
placeholder: e.g. Syncthing, k9s, rbenv
12+
validations:
13+
required: true
14+
15+
- type: input
16+
id: homepage
17+
attributes:
18+
label: Homepage / Documentation URL
19+
description: The official homepage or documentation URL for the tool
20+
placeholder: https://...
21+
validations:
22+
required: true
23+
24+
- type: textarea
25+
id: description
26+
attributes:
27+
label: What should the resource manage?
28+
description: Describe what you want the Codify resource to install and configure
29+
placeholder: |
30+
e.g. The syncthing resource should install syncthing and allow users to manage
31+
its configuration including device IDs, shared folders, and GUI settings.
32+
Syncthing has a CLI so direct configuration should be possible.
33+
validations:
34+
required: true
35+
36+
- type: textarea
37+
id: install_notes
38+
attributes:
39+
label: Installation Notes (optional)
40+
description: Any known installation details, quirks, or preferred installation method
41+
placeholder: e.g. Prefer homebrew on macOS; uses the official install script on Linux
42+
validations:
43+
required: false
44+
45+
- type: textarea
46+
id: use_cases
47+
attributes:
48+
label: Use Cases (optional)
49+
description: How do you plan to use this resource? Any specific config parameters that matter?
50+
placeholder: e.g. I want to pin the version and configure custom data directories
51+
validations:
52+
required: false

.github/workflows/claude-fixer.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Claude Test Fixer
2+
on:
3+
workflow_run:
4+
workflows: ["Test all cron (Linux)", "Test all cron (MacOS)"]
5+
types: [completed]
6+
7+
jobs:
8+
fix-on-failure:
9+
runs-on: ubuntu-latest
10+
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
11+
permissions:
12+
contents: write
13+
pull-requests: write
14+
actions: read # Allows Claude to read the logs of the failed run
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Claude Fix Failed Tests
18+
uses: anthropics/claude-code-action@v1
19+
with:
20+
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
21+
prompt: |
22+
The "CI Tests" workflow just failed.
23+
1. Analyze the logs from the last failed run.
24+
2. Identify the root cause of the test failure.
25+
3. Implement a fix and create a new pull request.
26+
27+
28+
29+
additional_permissions: |
30+
actions: read

0 commit comments

Comments
 (0)