
* Update architecture.markdown * Update component_discovery.markdown * Update development_validation.markdown * Update frontend.markdown * Update maintenance.markdown * Update multiple_instances.markdown * Update python_api.markdown * Update releasing.markdown * Update rest_api.markdown * Update server_sent_events.markdown * Update website.markdown
1.7 KiB
layout, title, description, date, sidebar, comments, sharing, footer
layout | title | description | date | sidebar | comments | sharing | footer |
---|---|---|---|---|---|---|---|
page | Maintenance | Steps involved to maintain the current state of Home Assistant. | 2016-09-13 17:00 | true | false | true | true |
This page documents a couple of points for maintaining the Home Assistant code. Most of the tasks don't need to be performed on a regular base thus the steps, used tools, or details are preserved here.
{% linkable_title Line separator %}
People are using various operating systems to develop components and platforms for Home Assistant. This could lead to different line endings on file. We prefer LN
. Especially Microsoft Windows tools tend to use CRLF
.
$ find homeassistant -name "*.py" -exec file {} \; | grep BOM
$ find homeassistant -name "*.py" -exec file {} \; | grep CRLF
To fix the line separator, use dos2unix
or sed
.
$ dos2unix homeassistant/components/notify/kodi.py
{% linkable_title Dependencies %}
A lot of components and platforms depends on third-party Python modules. The dependencies which are stored in the requirements_*.txt
files are tracked by gemnasium and Requires.io.
If you update the requirements of a component/platform through the REQUIREMENTS = ['modules-xyz==0.3']
entry, run the provided script to update the requirements_*.txt
file(s).
$ script/gen_requirements_all.py
Start a test run of Home Assistant if that was successful include all files in a Pull Request. Add a short summary of the changes, a sample configuration entry, details about the tests, and other useful information to the description.