{"id":20548552,"url":"https://github.com/benleb/automoli-go","last_synced_at":"2025-07-17T20:33:28.834Z","repository":{"id":257827858,"uuid":"872968751","full_name":"benleb/automoli-go","owner":"benleb","description":"💡 Fully automatic light management based on conditions like motion, illuminance, humidity, and other clever features. Completely rewritten in go!","archived":false,"fork":false,"pushed_at":"2024-11-05T20:47:27.000Z","size":177,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-01T20:03:39.662Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/benleb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-15T11:41:38.000Z","updated_at":"2024-11-05T20:47:31.000Z","dependencies_parsed_at":"2024-10-26T11:59:27.268Z","dependency_job_id":"1b759ffc-f951-409a-b57d-e62fce3d86fe","html_url":"https://github.com/benleb/automoli-go","commit_stats":null,"previous_names":["benleb/automoli-go"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benleb%2Fautomoli-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benleb%2Fautomoli-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benleb%2Fautomoli-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benleb%2Fautomoli-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/benleb","download_url":"https://codeload.github.com/benleb/automoli-go/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242152660,"owners_count":20080329,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T02:13:51.476Z","updated_at":"2025-03-06T05:25:24.539Z","avatar_url":"https://github.com/benleb.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# [![automoli](https://socialify.git.ci/benleb/automoli-go/image?description=1\u0026font=KoHo\u0026forks=1\u0026language=1\u0026logo=https%3A%2F%2Femojipedia-us.s3.dualstack.us-west-1.amazonaws.com%2Fthumbs%2F240%2Fapple%2F237%2Felectric-light-bulb_1f4a1.png\u0026owner=1\u0026pulls=1\u0026stargazers=1\u0026theme=Light)](https://github.com/benleb/automoli-go)\n\n\u003c!-- # AutoMoLi - **Auto**matic **Mo**tion **Li**ghts --\u003e\n\n[![Go Report Card](https://goreportcard.com/badge/github.com/benleb/automoli-go)](https://goreportcard.com/report/github.com/benleb/automoli-go) [![Go Reference](https://pkg.go.dev/badge/github.com/benleb/automoli-go.svg)](https://pkg.go.dev/github.com/benleb/automoli-go) [![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/benleb/automoli-go/build.yml\n)](https://github.com/benleb/automoli-go/actions/workflows/build.yml) [![No Maintenance Intended](http://unmaintained.tech/badge.svg)](http://unmaintained.tech/)\n\nFully *automatic light management* based on motion, daytime, brightness and even humidity 💦 🚿\n\n🕓 multiple **daytimes** to define different scenes for morning, noon, ...  \n💡 supports **Hue** (for Hue Rooms/Groups) \u0026 **Home Assistant** scenes  \n🔌 switches **lights** and **plugs** (with lights)  \n☀️ supports **illumination sensors** to switch the light just if needed  \n💦 supports **humidity sensors** as blocker (the \"*shower case*\")  \n🔒 **locks** the light if the light was manually turned on\n\u003c!-- not yet implemented in the go version: --\u003e\n\u003c!-- 🔍 **automatic** discovery of **lights** and **sensors**   --\u003e\n\u003c!-- ⛰️ **stable** and **tested** by many people with different homes   --\u003e  \n\n*- successor of the famous original [ad-AutoMoLi](https://github.com/benleb/ad-automoli) (written in Python as [AppDaemon](https://github.com/AppDaemon/appdaemon) plugin/app) -*\n\n## install\n\nvia [go install](https://go.dev/ref/mod#go-install)\n\n```bash\ngo install github.com/benleb/automoli-go@latest\n```\n\n## run\n\nsee the [example config](automoli.yaml) for a multi-room configuration with different daytimes and sensors and settings.\n\n```bash\n# run\nautomoli-go run --config ~/automoli.yaml\n\n# more options\nautomoli-go --help\n```\n\n### systemd service example\n\nthis is an **example** how the [systemd service file](automoli.service) can be used for running AutoMoLi as a service.\nuuser, group and repo/config directory may need to be adjusted.\n\n```bash\n# clone repo\ngit clone https://github.com/benleb/automoli-go ~/automoli\n\n# create a new user and group for automoli\nuseradd --system --home-dir /etc/automoli --user-group automoli\n\n# create config directory and set permissions\nmkdir /etc/automoli \u0026\u0026 chown automoli:automoli /etc/automoli\n\n# link or copy the systemd service file\nln -s ~/automoli/automoli.service /etc/systemd/system/automoli.service\n```\n\n## build\n\n### single target\n\n```bash\n# build for current platform\ngoreleaser build --clean --snapshot --single-target\n\n# build for specific platform\nGOOS=\"linux\" GOARCH=\"amd64\" GOAMD64=\"v3\" goreleaser build --clean --snapshot --single-target\n```\n\n### docker image\n\nwith [ko](https://ko.build)\n\n```bash\n# build image and push to registry\nKO_DOCKER_REPO=your.registry.io:5000 ko build --verbose --base-import-paths --tags dev\n```\n\n## development\n\n### lint\n\nwith [golangci-lint](https://golangci-lint.run)\n\n```bash\n# run all linters\ngolangci-lint run --verbose --enable-all --fix --max-issues-per-linter 0 --max-same-issues 0\n```\n\n### tests\n\n```bash\n# run tests with coverage\ngo test -cover ./...\n```\n\n### release/tag\n\nvith [goreleaser](https://goreleaser.com) triggered by a git tag\n\n```bash\n# create a new annotated tag\ngit tag -a \"vX.Y.Z\" -m \"short release description vX.Y.Z\"\n# push tag to trigger the release workflow\ngit push --follow-tags\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenleb%2Fautomoli-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbenleb%2Fautomoli-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenleb%2Fautomoli-go/lists"}