Add Celebright holiday-lights integration
Home Assistant custom integration for Celebright (CLC-03) holiday-lights controllers, plus a standalone reference client. Local-only, reverse-engineered from the device's WebSocket protocol — talks directly to the controller on the LAN with no vendor cloud. - select entity exposes the device's saved scenes plus an off option - firmware-v2 protocol (savedScenes); getSystemState drives availability and the active scene, scene library fetched best-effort and cached - WS connect/recv/send wrapped in asyncio timeouts so a silent device can't blow past HA's setup deadline - config flow prompts for the controller IP; no credentials involved - docs/PROTOCOL.md: full v2 WebSocket protocol and device behaviors Migrated from the private dfritz/celebright with history dropped and internal site references removed. MIT-licensed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01F6B8b3iYNv6QUftK2FDfYb
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
.PHONY: deploy clean help setup
|
||||
|
||||
# Configuration — override on the command line or in your environment, e.g.
|
||||
# make deploy REMOTE_HOST=homeassistant.local
|
||||
REMOTE_HOST ?= homeassistant.local
|
||||
REMOTE_PATH ?= /homeassistant/custom_components
|
||||
REMOTE_USER ?= root
|
||||
LOCAL_PATH = custom_components/celebright
|
||||
|
||||
# Default target
|
||||
help:
|
||||
@echo "Celebright Home Assistant Integration - Makefile"
|
||||
@echo ""
|
||||
@echo "Available targets:"
|
||||
@echo " make deploy - Deploy integration to Home Assistant (set REMOTE_HOST)"
|
||||
@echo " make setup - Ensure remote directory exists with correct permissions"
|
||||
@echo " make clean - Remove Python cache files"
|
||||
@echo " make help - Show this help message"
|
||||
@echo ""
|
||||
@echo "Override REMOTE_HOST / REMOTE_PATH / REMOTE_USER for your own host."
|
||||
|
||||
# Ensure remote directory exists with correct permissions
|
||||
setup:
|
||||
@echo "Setting up remote directory on $(REMOTE_HOST)..."
|
||||
@ssh $(REMOTE_HOST) "sudo mkdir -p $(REMOTE_PATH)/celebright && sudo chown -R $(REMOTE_USER):$(REMOTE_USER) $(REMOTE_PATH)/celebright"
|
||||
@echo "Setup complete!"
|
||||
|
||||
# Deploy integration to Home Assistant
|
||||
deploy: setup
|
||||
@echo "Deploying Celebright integration to $(REMOTE_HOST)..."
|
||||
rsync -avz --delete \
|
||||
--exclude='__pycache__' \
|
||||
--exclude='*.pyc' \
|
||||
--exclude='.DS_Store' \
|
||||
--exclude='*.swp' \
|
||||
$(LOCAL_PATH)/ $(REMOTE_HOST):$(REMOTE_PATH)/celebright/
|
||||
@echo ""
|
||||
@echo "Deployment complete!"
|
||||
@echo "Remember to restart Home Assistant to load the changes."
|
||||
|
||||
# Clean Python cache files
|
||||
clean:
|
||||
@echo "Cleaning Python cache files..."
|
||||
find $(LOCAL_PATH) -type d -name '__pycache__' -exec rm -rf {} + 2>/dev/null || true
|
||||
find $(LOCAL_PATH) -type f -name '*.pyc' -delete 2>/dev/null || true
|
||||
@echo "Clean complete!"
|
||||
Reference in New Issue
Block a user