ha(HACS): комплект файлов для Custom Repositories
- info.md (страница HACS), LICENSE (MIT), codeowners @petr.polezhaev - brand: icon/icon@2x/logo + dark-варианты (сгенерированные плейсхолдеры с силуэтом кондиционера) - .github/workflows/validate-hacs.yaml и hassfest.yaml (включатся на GitHub) - pyproject: license=MIT, license-files; MANIFEST: LICENSE в sdist - README/RELEASE_HA: HACS работает только с публичным GitHub-зеркалом (Custom Repositories), точные команды mirror и настройки GitHub
@@ -0,0 +1,19 @@
|
||||
name: Validate (hassfest)
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
schedule:
|
||||
- cron: "0 0 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
jobs:
|
||||
validate-hassfest:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: hassfest
|
||||
uses: home-assistant/actions/hassfest@master
|
||||
@@ -0,0 +1,21 @@
|
||||
name: Validate (HACS)
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
schedule:
|
||||
- cron: "0 0 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
jobs:
|
||||
validate-hacs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: HACS validation
|
||||
uses: hacs/action@main
|
||||
with:
|
||||
category: integration
|
||||
@@ -0,0 +1,26 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2026 Petr Polezhaev
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
|
||||
---
|
||||
|
||||
Вендоренный парсер JSON `third_party/jsmn` распространяется под лицензией
|
||||
MIT (см. `third_party/jsmn/LICENSE`).
|
||||
@@ -1,4 +1,4 @@
|
||||
include CMakeLists.txt README.md pyproject.toml setup.py
|
||||
include CMakeLists.txt LICENSE README.md pyproject.toml setup.py
|
||||
recursive-include include *.h *.hpp
|
||||
recursive-include src *.cpp *.hpp
|
||||
recursive-include third_party *
|
||||
|
||||
@@ -126,5 +126,6 @@ converted from the module's 0.01 °C+5000 format.
|
||||
|
||||
## License / provenance
|
||||
|
||||
Protocol documentation and code reconstructed from the FGLair 3.4.3 APK for
|
||||
interoperability; `third_party/jsmn` is MIT.
|
||||
MIT — see [`LICENSE`](LICENSE). Protocol documentation and code reconstructed
|
||||
from the FGLair 3.4.3 APK for interoperability; vendored `third_party/jsmn`
|
||||
is MIT.
|
||||
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
|
After Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 607 B After Width: | Height: | Size: 1.0 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 832 B After Width: | Height: | Size: 1.5 KiB |
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"domain": "fglair",
|
||||
"name": "FGLair (Fujitsu General)",
|
||||
"codeowners": [],
|
||||
"codeowners": ["@petr.polezhaev"],
|
||||
"config_flow": true,
|
||||
"documentation": "https://git.ratigorsk-12.ru/esphome/fgl-aircon",
|
||||
"integration_type": "device",
|
||||
|
||||
@@ -39,25 +39,44 @@ twine upload dist/manylinux/* dist/*.tar.gz
|
||||
repair` внутри, но текущий `bdist_wheel`-хук отдаёт тег
|
||||
`py3-none-<plat>`, поэтому проверяйте итоговые теги вручную.
|
||||
|
||||
## 2. GitHub-зеркало и HACS
|
||||
## 2. GitHub-зеркало и Custom Repositories
|
||||
|
||||
HACS устанавливает интеграции только с публичных **GitHub**-репозиториев
|
||||
(GitLab/Gitea не поддерживаются). Шаги:
|
||||
(GitLab/Gitea не поддерживаются: https://hacs.xyz/docs/faq/other_git_providers/).
|
||||
Публикация в default-репозиторий HACS не требуется — достаточно Custom
|
||||
Repositories, но хостинг обязан быть GitHub.
|
||||
|
||||
* создать GitHub-зеркало (push mirror) и убедиться, что оно содержит
|
||||
`custom_components/fglair/`, `hacs.json`, тег релиза;
|
||||
* заполнить `codeowners` в `custom_components/fglair/manifest.json`
|
||||
(GitHub-хендлы; сейчас пустой список);
|
||||
```sh
|
||||
# один раз: зеркало и перенос веток/тегов
|
||||
git remote add github git@github.com:<owner>/fgl-aircon.git
|
||||
git push --mirror github
|
||||
```
|
||||
|
||||
После зеркала:
|
||||
|
||||
* заполнить в настройках GitHub: Description, Topics
|
||||
(`home-assistant`, `hacs`, `fujitsu`, `air-conditioner`), включить Issues
|
||||
(эти пункты проверяет HACS Action; файлами они не настраиваются);
|
||||
* проверить `codeowners` в `custom_components/fglair/manifest.json` —
|
||||
сейчас `@petr.polezhaev`; для GitHub Action/HACS это должен быть реальный
|
||||
GitHub-логин;
|
||||
* проверить `documentation`/`issue_tracker` в манифесте;
|
||||
* обновить `version` манифеста под номер тега (сейчас `0.1.0`, pyfglair —
|
||||
`1.0.0`; синхронизируйте по вкусу — компонент и пакет версионируются
|
||||
отдельно);
|
||||
`1.0.0`; компонент и пакет версионируются отдельно);
|
||||
* заменить заглушки `custom_components/fglair/screenshots/step-N.png`
|
||||
реальными скриншотами (описания «что должно быть видно» — в README);
|
||||
* заменить заглушки `custom_components/fglair/brand/{icon,logo}.png`
|
||||
фирменными ассетами;
|
||||
* заменить заглушки `custom_components/fglair/brand/*.png` фирменными
|
||||
ассетами (сейчас — сгенерированные плейсхолдеры: icon/icon@2x/logo и
|
||||
тёмные варианты);
|
||||
* создать git-тег (semver) в GitHub-зеркале — HACS покажет версию.
|
||||
|
||||
Файлы, которые HACS/hassfest проверяют у интеграции: `hacs.json`,
|
||||
`custom_components/fglair/manifest.json` (domain/documentation/
|
||||
issue_tracker/codeowners/name/version), `custom_components/fglair/brand/icon.png`,
|
||||
README/info.md, OSI-лицензия (`LICENSE`, MIT). Всё это в репозитории есть;
|
||||
workflow `.github/workflows/{validate-hacs,hassfest}.yaml` включатся на
|
||||
GitHub.
|
||||
|
||||
## 3. Приёмка на живом стенде
|
||||
|
||||
* `tests/acceptance/test_esphome_ha.py quick` — матрица изменений (HA;
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
# FGLair — локальное управление кондиционерами Fujitsu General
|
||||
|
||||
Интеграция Home Assistant для кондиционеров Fujitsu General (FGLair / Ayla)
|
||||
**по локальной сети, без облака в рантайме**. Протокол и ядро — C++
|
||||
(`fgl-aircon`), доступ из HA — через python-пакет `pyfglair` (cffi).
|
||||
|
||||
## Возможности
|
||||
|
||||
* `climate`: режим (off/cool/dry/fan/heat/auto), скорость вентилятора,
|
||||
swing (вертикальный и горизонтальный), preset ECO/BOOST, уставка 16–30 °C,
|
||||
текущая температура;
|
||||
* `switch`: economy, powerful, coil dry, min heat, outdoor low noise,
|
||||
human det auto save, Wi-Fi LED, indoor fan control;
|
||||
* `select`: положение заслонок, `sensor`: температура/код ошибки/состояние
|
||||
связи, `binary_sensor`: connectivity и флаги op_status;
|
||||
* настройка через облако FGLair (однократно), вручную или импортом
|
||||
`config_*.json`; превью шаблона с ручными конверсиями;
|
||||
* Repair при несовпадении LAN-ключа, диагностика и переводы en/ru.
|
||||
|
||||
## Установка
|
||||
|
||||
HACS работает только с публичными **GitHub**-репозиториями — используйте
|
||||
GitHub-зеркало этого репозитория:
|
||||
|
||||
1. HACS → ⋮ → **Custom repositories** → URL GitHub-зеркала, категория
|
||||
**Integration** → Add → Download → перезапуск HA.
|
||||
2. Либо вручную скопируйте `custom_components/fglair/` в
|
||||
`<config>/custom_components/`.
|
||||
|
||||
Требуется пакет `pyfglair` (манифест ставит его из PyPI) и HA ≥ 2025.1 на
|
||||
Linux x86_64/aarch64.
|
||||
|
||||

|
||||
|
||||
Подробная инструкция — в
|
||||
[`custom_components/fglair/README.md`](custom_components/fglair/README.md).
|
||||
@@ -1,5 +1,5 @@
|
||||
[build-system]
|
||||
requires = ["setuptools>=68", "wheel"]
|
||||
requires = ["setuptools>=77", "wheel"]
|
||||
build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
@@ -7,6 +7,8 @@ name = "pyfglair"
|
||||
version = "1.0.0"
|
||||
description = "Local control of Fujitsu General (FGLair/Ayla) air conditioners: cffi bindings to the fgl-aircon C++ core"
|
||||
readme = "README.md"
|
||||
license = "MIT"
|
||||
license-files = ["LICENSE"]
|
||||
requires-python = ">=3.10"
|
||||
dependencies = [
|
||||
"cffi>=1.15",
|
||||
|
||||