Skip to content

Moon translate#15498

Merged
balloob merged 5 commits intodevfrom
moon-translate
Jul 18, 2018
Merged

Moon translate#15498
balloob merged 5 commits intodevfrom
moon-translate

Conversation

@pvizeli
Copy link
Copy Markdown
Member

@pvizeli pvizeli commented Jul 16, 2018

Description:

I try to add a translation for moon sensor. I change it like the season sensor. A sensor they return a string should be lowercase. It should be return a number as sensor but it work now like in this way.

"""Return the state of the device."""
if self._state == 0:
return 'New moon'
return 'new moon'
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

although we can use whitespaces in translation file keys, I'm not sure if we want this wild mix of " ", "_". "-" for states

@balloob balloob merged commit 058081b into dev Jul 18, 2018
@ghost ghost removed the in progress label Jul 18, 2018
@balloob balloob deleted the moon-translate branch July 18, 2018 08:54
michaeldavie pushed a commit to michaeldavie/home-assistant that referenced this pull request Jul 31, 2018
* Translate moon

* Create strings.moon.json

* Update moon.py

* Update strings.moon.json

* Update test_moon.py
@balloob balloob mentioned this pull request Aug 3, 2018
girlpunk pushed a commit to girlpunk/home-assistant that referenced this pull request Sep 4, 2018
* Translate moon

* Create strings.moon.json

* Update moon.py

* Update strings.moon.json

* Update test_moon.py
@home-assistant home-assistant locked and limited conversation to collaborators Dec 10, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants