helm-types-gen
Use when asking about generating Helm types, HelmValuesForChart, TypeScript interfaces from Helm charts, or the helm-types CLI.
What this skill does
# Helm Types Generation
## Overview
The `@homelab/helm-types` package generates TypeScript interfaces from Helm chart JSON schemas, enabling compile-time type safety for Helm values configuration.
## CLI Usage
```bash
bunx @homelab/helm-types \
--name argo-cd \
--repo https://argoproj.github.io/argo-helm \
--version 8.3.1 \
--output src/cdk8s/generated/helm/argo-cd.types.ts
```
## CLI Options
| Option | Alias | Required | Description |
| ------------- | ----- | -------- | ----------------------------------------------- |
| `--name` | `-n` | Yes | Unique identifier for the chart |
| `--repo` | `-r` | Yes | Helm repository URL |
| `--version` | `-v` | Yes | Chart version |
| `--chart` | `-c` | No | Chart name in repo (defaults to --name) |
| `--output` | `-o` | No | Output file path (stdout if omitted) |
| `--interface` | `-i` | No | Interface name (auto-generated from chart name) |
## Integration with CDK8s
### Step 1: Generate Types
```bash
bunx @homelab/helm-types \
--name cert-manager \
--repo https://charts.jetstack.io \
--version 1.14.0 \
--output src/cdk8s/generated/helm/cert-manager.types.ts
```
### Step 2: Register in HelmChartValuesMap
Edit `src/cdk8s/src/misc/typed-helm-parameters.ts`:
```typescript
import type { CertmanagerHelmValues } from "../../generated/helm/cert-manager.types.ts";
type HelmChartValuesMap = {
"argo-cd": ArgocdHelmValues;
"cert-manager": CertmanagerHelmValues; // Add new chart
// ... other charts
};
export type HelmValuesForChart<TChart extends keyof HelmChartValuesMap> =
HelmChartValuesMap[TChart];
```
### Step 3: Use in ArgoCD Applications
```typescript
import type { HelmValuesForChart } from "../misc/typed-helm-parameters.ts";
const certManagerValues: HelmValuesForChart<"cert-manager"> = {
installCRDs: true, // Type-safe with autocomplete
prometheus: {
enabled: true,
servicemonitor: {
enabled: true,
},
},
};
```
## How It Works
The tool performs these steps:
1. **Fetch Chart**: Downloads chart from Helm repo, extracts `values.yaml` and `values.schema.json`
2. **Parse YAML**: Extracts structure and preserves comments for documentation
3. **Convert Schema**: Transforms JSON Schema to TypeScript types
4. **Infer Types**: Falls back to runtime type inference when schema is incomplete
5. **Generate Code**: Outputs TypeScript interfaces with JSDoc comments
## Generated Type Features
- **Nested Interfaces**: Each object becomes its own TypeScript type
- **JSDoc Comments**: Preserves documentation from chart comments
- **Default Values**: Shows `@default` annotations
- **Optional Properties**: All properties are optional (Helm defaults apply)
- **Extensible Types**: ConfigMaps and similar allow arbitrary keys
## Example Generated Output
```typescript
export type CertmanagerHelmValues = {
/**
* Install CRDs as part of the Helm release
* @default true
*/
installCRDs?: boolean;
/**
* Prometheus monitoring configuration
*/
prometheus?: CertmanagerHelmValuesPrometheus;
};
export type CertmanagerHelmValuesPrometheus = {
enabled?: boolean;
servicemonitor?: CertmanagerHelmValuesPrometheusServicemonitor;
};
```
## Key Files
- `src/helm-types/src/cli.ts` - CLI entry point
- `src/helm-types/src/type-converter.ts` - JSON Schema → TypeScript conversion
- `src/helm-types/src/yaml-comments.ts` - Comment extraction and preservation
- `src/helm-types/src/interface-generator.ts` - Code generation
- `src/cdk8s/src/misc/typed-helm-parameters.ts` - Type registry
- `src/cdk8s/generated/helm/*.types.ts` - Generated type files
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.