Skip to content

Digital-Alchemy-TS/code-glue

Code Glue

❓ Overview

Code Glue is a Home Assistant add-on that lets you create and edit entities and automations using TypeScript and Digital Alchemy from within an embedded IDE.

🔧 Install

Add repository on my Home Assistant

  1. In Home Assistant, go to: Settings → Add-ons → Add-on Store
  2. Click the three dots (⋮) in the top-right → Repositories
  3. Add this URL as a custom repository:
  1. Close the dialog

You'll now see two add-ons available:

Available Add-ons

Code Glue

Stable production releases

  • "Thoroughly tested"
  • Recommended for production use
  • Pulls from ghcr.io/digital-alchemy-ts/code-glue:latest

Code Glue (Dev)

Development builds for testing

  • Latest features and bug fixes
  • May (will) be unstable and/or ugly.
  • Pulls from ghcr.io/digital-alchemy-ts/code-glue:dev
  • Can run alongside production version with its own DB.

🏗️ Developer Setup

⚠️ NOTE: This section is for contributors working on Code Glue itself (not end‑users). ⚠️

Repository layout

/               # Yarn workspaces monorepo, TypeScript-first
/apps
  /server       # API and runtime for Code Glue features
  /client       # Embedded IDE / UI used inside the add-on
/packages       # Shared libraries (types, utils, SDK)
  /paradigm     # UI Component Library for the client

Development Workflow

Development is done locally with hot reloading:

Setup

  1. Install Node

⚠️ Do not use Node from Homebrew ⚠️

curl -fsSL https://fnm.vercel.app/install | bash

fnm use 22
fnm default 22
  1. Init Submodules
git submodule update --init --recursive
  1. Install dependencies
# you may need to do this first to properly set up yarn
corepack enable

# install dependencies for root + all sub-projects
yarn install
  1. Bring up dev containers
docker compose up -d
  1. Create config file:
  • .code_glue.template to .code_glue & fill in variables (for server)
  1. Configure development environment:
  • Copy .env.template to .env to get the client dev env setup.
  1. Migrate the database:
yarn workspace @code-glue/server db:migrate
  1. Start the client and server
yarn dev

Frontend: http://localhost:3000 Swagger: http://localhost:3789/swagger/

🎛️ General Commands

Command Notes
yarn dev Start all workspaces in dev (start script)
yarn build Build all workspaces
yarn lint Lint all workspaces
yarn format Format all workspaces
yarn test Run tests across workspaces
yarn typecheck Type check all workspaces

About

Top secret stuff

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors 4

  •  
  •  
  •  
  •