Skip to content

Commit

Permalink
Merge branch 'current' into next
Browse files Browse the repository at this point in the history
# Conflicts:
#	esphomeyaml/changelog/index.rst
  • Loading branch information
OttoWinter committed Jan 6, 2019
2 parents 4188e4a + 7166e05 commit 834b27b
Show file tree
Hide file tree
Showing 164 changed files with 1,192 additions and 818 deletions.
1 change: 0 additions & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,3 @@
## Checklist:
- [ ] The documentation change has been tested and compiles correctly.
- [ ] Branch: `next` is for changes and new documentation that will go public with the next esphomelib release. Fixes, changes and adjustments for the current release should be created against `current`.
- [ ] Check this box if you have read, understand, comply, and agree with the [Code of Conduct](https://github.com/OttoWinter/esphomedocs/blob/master/CODE_OF_CONDUCT.md).
16 changes: 4 additions & 12 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,4 @@
---
build:
tags:
- esphomedocs
script:
- make ../esphomelib
- make html
except:
- current
- rc

.deploy: &deploy
tags:
- esphomedocs
Expand All @@ -26,12 +16,14 @@ build:
- git fetch --force [email protected]:${TARGET_REPO}.git gh-pages:gh-pages
- git worktree add _build/html gh-pages
- make ../esphomelib
- touch _build/html/.nojekyll
- echo ${CNAME} >_build/html/CNAME
- make html
- make convertimages
- git -C _build/html add --all
- git -C _build/html commit -m "Deploy to gh-pages"
- git -C _build/html push -f [email protected]:${TARGET_REPO}.git gh-pages
cache:
paths:
- _build/doctrees

deploy-release:
<<: *deploy
Expand Down
6 changes: 6 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
make \
doxygen \
openssh-client \
software-properties-common \
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/*

RUN apt-add-repository ppa:inkscape.dev/stable && \
apt-get update && apt-get install -y --no-install-recommends \
inkscape \
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/*

RUN pip3 install --no-cache-dir --no-binary :all: \
Expand Down
2 changes: 1 addition & 1 deletion Doxygen
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ PROJECT_NAME = "esphomelib"
# could be handy for archiving the generated documentation or if some version
# control system is used.

PROJECT_NUMBER = 1.9.0b3
PROJECT_NUMBER = 1.9.3

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
Expand Down
9 changes: 3 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ SPHINXPROJ = esphomelib
SOURCEDIR = .
BUILDDIR = _build
ESPHOMELIB_PATH = ../esphomelib
ESPHOMELIB_TAG = v1.9.0b3
ESPHOMELIB_TAG = v1.9.3
CNAME = esphomelib.com

.PHONY: html cleanhtml doxyg cleandoxyg deploy help webserver Makefile $(ESPHOMELIB_PATH)
Expand All @@ -32,11 +32,8 @@ $(ESPHOMELIB_PATH):
git clone --branch $(ESPHOMELIB_TAG) https://github.com/OttoWinter/esphomelib.git $(ESPHOMELIB_PATH); \
fi

deploy: cleanhtml doxyg html $(ESPHOMELIB_PATH)
touch "$(BUILDDIR)/html/.nojekyll"
echo "$(CNAME)" >"$(BUILDDIR)/html/CNAME"
git -C "$(BUILDDIR)/html" add --all && git -C "$(BUILDDIR)/html" commit -m "Deploy to gh-pages"
@printf "Run \033[0;36mcd $(BUILDDIR)/html && git push origin gh-pages\033[0m to deploy\n"
convertimages:
python3 svg2png.py

help:
$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
Expand Down
32 changes: 31 additions & 1 deletion _static/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,34 @@ table.docutils {
100% {
visibility: visible;
}
}
}

#upgrade-footer {
position: fixed;
left: 0;
bottom: 0;
right: 0;
width: 100%;
background-color: rgba(20,20,20,0.8);
min-height: 26px;
font-size: 14px;
color: #ccc;
line-height: 26px;
padding: 8px 0 8px 30px;
z-index: 9999;
display: none
}
#upgrade-footer-changelog {
background-color: #b3b3b3;
color: #4e4e4e;
display: inline-block;
border-radius: 5px;
padding: 0 20px;
cursor: pointer;
float: right;
margin: 0 60px 0 10px;
text-decoration: none;
}
.not-hidden {
display: block !important;
}
1 change: 1 addition & 0 deletions _static/version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.9.3
32 changes: 32 additions & 0 deletions _templates/layout.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{% extends 'alabaster/layout.html' %}

{% block footer %}
<div class="footer">
<a href="/misc/privacy.html">Privacy Policy</a>
</div>
<div id="upgrade-footer">
A new version has been release since you last visited this page: {{ release }} 🎉
<a id="upgrade-footer-changelog" href="/esphomeyaml/changelog/index.html">View Changelog</a>
</div>

<script async src="https://www.googletagmanager.com/gtag/js?id=UA-113203480-2"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'UA-113203480-2', {'anonymize_ip': true});
</script>

<script>
var old = window.localStorage.getItem("release");
if (old === null) {
window.localStorage.setItem("release", "{{ release }}");
} else if (old !== "{{ release }}") {
document.getElementById("upgrade-footer").classList.add("not-hidden");
document.getElementById("upgrade-footer-changelog").addEventListener('click', function () {
window.localStorage.setItem("release", "{{ release }}");
});
}
</script>
{% endblock %}
25 changes: 16 additions & 9 deletions conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@
'disqus',
'github',
'seo',
'githubpages',
'sitemap',
]

breathe_projects = {"esphomelib": "./_doxyxml/"}
Expand All @@ -64,8 +66,10 @@
master_doc = 'index'

# General information about the project.
project = 'esphomelib'
copyright = '2018, Otto Winter'
project = 'ESPHome'
copyright = '2019, Otto Winter'
html_show_copyright = False
html_show_sphinx = False
author = 'Otto Winter'

# The version info for the project you're documenting, acts as replacement for
Expand All @@ -75,7 +79,7 @@
# The short X.Y version.
version = '1.9'
# The full version, including alpha/beta/rc tags.
release = '1.9.0b3'
release = '1.9.3'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand All @@ -93,9 +97,9 @@
# default_role = 'cpp:any'

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'
pygments_style = 'xcode'

# highlight_language = 'yaml'
highlight_language = 'yaml'

primary_domain = None

Expand All @@ -114,6 +118,7 @@
# further. For a list of options available for each theme, see the
# documentation.
#
html_baseurl = os.getenv('BASE_URL', 'https://esphomelib.com')
html_theme_options = {
# 'logo': 'logo-full.png',
'logo_name': False,
Expand All @@ -123,6 +128,8 @@
'show_related': False,
'sidebar_collapse': True,
'fixed_sidebar': True,
'show_powered_by': False,
'canonical_url': html_baseurl + '/',
}

html_logo = '_static/logo-full.png'
Expand Down Expand Up @@ -181,7 +188,7 @@
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
(master_doc, 'esphomelib.tex', 'esphomelib Documentation',
(master_doc, 'esphomelib.tex', 'ESPHome Documentation',
'Otto Winter', 'manual'),
]

Expand All @@ -193,7 +200,7 @@
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
(master_doc, 'esphomelib', 'esphomelib Documentation',
(master_doc, 'esphomelib', 'ESPHome Documentation',
[author], 1)
]

Expand All @@ -204,8 +211,8 @@
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
(master_doc, 'esphomelib', 'esphomelib Documentation',
(master_doc, 'esphomelib', 'ESPHome Documentation',
author, 'esphomelib', 'One line description of project.',
'Miscellaneous'),
]
html_baseurl = os.getenv('BASE_URL', 'https://esphomelib.com')
linkcheck_ignore = [r'https://github.com/.*', r'https://discord.gg/.*']
4 changes: 2 additions & 2 deletions esphomeyaml/changelog/v1.7.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ Breaking Changes
parameter. The accuracy now defaults to ``HIGH``.
- The ``inverted`` option of binary sensors has been moved into the ``filters:`` section. So instead of

.. code:: yaml
.. code-block:: yaml
binary_sensor:
- platform: ...
Expand All @@ -103,7 +103,7 @@ Breaking Changes
you would now write:

.. code:: yaml
.. code-block:: yaml
binary_sensor:
- platform: ...
Expand Down
6 changes: 3 additions & 3 deletions esphomeyaml/changelog/v1.8.0.rst
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ Other notable changes

- In actions, instead of

.. code:: yaml
.. code-block:: yaml
on_...:
then:
Expand All @@ -130,15 +130,15 @@ Other notable changes

You can now write:

.. code:: yaml
.. code-block:: yaml
on_...:
then:
- switch.turn_on: my_switch

Or even shorter:

.. code:: yaml
.. code-block:: yaml
on_...:
- switch.turn_on: my_switch
Expand Down
2 changes: 1 addition & 1 deletion esphomeyaml/components/ads1115.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ To use this hub, first setup the :ref:`I²C Bus <i2c>` and connect the sensor to

.. _Adafruit: https://www.adafruit.com/product/1085

.. code:: yaml
.. code-block:: yaml
ads1115:
- address: 0x48
Expand Down
12 changes: 8 additions & 4 deletions esphomeyaml/components/binary_sensor/esp32_ble_tracker.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ESP32 Bluetooth Low Energy Device

.. seo::
:description: Instructions for setting up BLE binary sensors for the ESP32.
:image: bluetooth.svg
:image: bluetooth.png

The ``esp32_ble_tracker`` binary sensor platform lets you track the presence of a
bluetooth low energy device.
Expand All @@ -12,7 +12,7 @@ bluetooth low energy device.
:align: center
:width: 80.0%

.. code:: yaml
.. code-block:: yaml
# Example configuration entry
esp32_ble_tracker:
Expand Down Expand Up @@ -44,12 +44,16 @@ to track. Most devices show this screen in some setting menu. If you don't know
however, you can use the ``esp32_ble_tracker`` hub without any binary sensors attached and read through
the logs to see discovered Bluetooth Low Energy devices.

.. code:: yaml
.. code-block:: yaml
# Example configuration entry for finding MAC addresses
esp32_ble_tracker:
Using above configuration, first you should see a ``Starting scan...`` debug message at
After adding that to your configuration, you will need to re-flash the ESP32 over USB, as esphomeyaml
needs to repartition the flash memory of the ESP in order to allow for the increased firmware size that
the BLE stack requires.

Using the configuration above, first you should see a ``Starting scan...`` debug message at
boot-up. Then, when a BLE device is discovered, you should see messages like
``Found device AC:37:43:77:5F:4C`` together with some information about their
address type and advertised name. If you don't see these messages, your device is unfortunately
Expand Down
6 changes: 3 additions & 3 deletions esphomeyaml/components/binary_sensor/esp32_touch.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ESP32 Touch Pad Binary Sensor

.. seo::
:description: Instructions for setting up the touch pad on the ESP32.
:image: touch.svg
:image: touch.png

The ``esp32_touch`` binary sensor platform lets you use the touch peripheral of the
ESP32 to detect if a certain pin is being "touched".
Expand All @@ -17,7 +17,7 @@ an ``OFF`` state.
:align: center
:width: 80.0%

.. code:: yaml
.. code-block:: yaml
# Example configuration entry
esp32_touch:
Expand Down Expand Up @@ -72,7 +72,7 @@ to output measured values using the ``setup_mode:`` configuration option. Next,
for the touch pads you want to observe. Also put some threshold in the configuration as seen below
to make the validator happy, we are going to find good thresholds in a moment anyway.

.. code:: yaml
.. code-block:: yaml
# Example configuration entry for finding threshold values
esp32_touch:
Expand Down
Loading

0 comments on commit 834b27b

Please sign in to comment.