mirror of
https://github.com/shouptech/synthale.git
synced 2026-02-03 15:39:45 +00:00
Compare commits
3 commits
| Author | SHA1 | Date | |
|---|---|---|---|
| cbd2619f90 | |||
| 0214065276 | |||
| dae353ce72 |
8 changed files with 50 additions and 9 deletions
15
CHANGELOG.rst
Normal file
15
CHANGELOG.rst
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
Changelog
|
||||
=========
|
||||
|
||||
0.1.1 - 2018-01-04
|
||||
------------------
|
||||
|
||||
* Fix `Issue 1`_, dry hop times are now in days.
|
||||
* Added a Changelog
|
||||
|
||||
.. _`Issue 1`: https://github.com/shouptech/synthale/issues/1
|
||||
|
||||
0.1.0 - 2018-01-03
|
||||
------------------
|
||||
|
||||
* Initial release
|
||||
|
|
@ -55,9 +55,9 @@ author = 'Mike Shoup'
|
|||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = '0.1.0'
|
||||
version = '0.1.1'
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '0.1.0'
|
||||
release = '0.1.1'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
[bumpversion]
|
||||
current_version = 0.1.0
|
||||
current_version = 0.1.1
|
||||
commit = True
|
||||
tag = True
|
||||
tag_name = {new_version}
|
||||
|
|
|
|||
2
setup.py
2
setup.py
|
|
@ -28,7 +28,7 @@ install_requires = [
|
|||
|
||||
setup(
|
||||
name='synthale',
|
||||
version='0.1.0',
|
||||
version='0.1.1',
|
||||
url='https://github.com/shouptech/synthale',
|
||||
author='Mike Shoup',
|
||||
author_email='mike@shoup.io',
|
||||
|
|
|
|||
|
|
@ -15,4 +15,4 @@
|
|||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
VERSION = '0.1.0'
|
||||
VERSION = '0.1.1'
|
||||
|
|
|
|||
|
|
@ -185,6 +185,7 @@ class MarkdownRecipe:
|
|||
headers = ('Name', 'Origin', 'Alpha', 'Amount', 'Time', 'Use')
|
||||
rows = []
|
||||
for hop in self.recipe.hops:
|
||||
# Determine hop unit
|
||||
if self.hop_unit == 'pounds':
|
||||
amt = convert.pounds(hop.amount, '.2f')
|
||||
elif self.hop_unit == 'grams':
|
||||
|
|
@ -193,12 +194,19 @@ class MarkdownRecipe:
|
|||
amt = convert.kilograms(hop.amount, '.2f')
|
||||
else:
|
||||
amt = convert.ounces(hop.amount, '.1f')
|
||||
|
||||
# Determine hop timing
|
||||
if hop.use == 'Dry Hop':
|
||||
# 1 day = 1440 minutes
|
||||
time = '{:.1f} days'.format(hop.time / 1440.0)
|
||||
else:
|
||||
time = '{} min'.format(int(round(hop.time)))
|
||||
rows.append((
|
||||
hop.name,
|
||||
hop.origin,
|
||||
'{:.1f} %'.format(hop.alpha),
|
||||
amt,
|
||||
'{}'.format(int(round(hop.time))),
|
||||
time,
|
||||
hop.use,
|
||||
))
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -76,6 +76,19 @@
|
|||
<DISPLAY_TIME>60.0 min</DISPLAY_TIME>
|
||||
<NOTES></NOTES>
|
||||
</HOP>
|
||||
<HOP>
|
||||
<NAME>Cascade</NAME>
|
||||
<ORIGIN>U.S.</ORIGIN>
|
||||
<ALPHA>5.5</ALPHA>
|
||||
<BETA></BETA>
|
||||
<AMOUNT>0.0141747</AMOUNT>
|
||||
<DISPLAY_AMOUNT>0.5 oz</DISPLAY_AMOUNT>
|
||||
<USE>Dry Hop</USE>
|
||||
<FORM>Pellet</FORM>
|
||||
<TIME>7200</TIME>
|
||||
<DISPLAY_TIME>5 days</DISPLAY_TIME>
|
||||
<NOTES></NOTES>
|
||||
</HOP>
|
||||
</HOPS>
|
||||
<YEASTS>
|
||||
<YEAST>
|
||||
|
|
|
|||
|
|
@ -128,9 +128,14 @@ def test_recipe_hops(md_weizen):
|
|||
assert md_weizen.hops == (
|
||||
'Hops\n'
|
||||
'----\n'
|
||||
'| Name | Origin | Alpha | Amount | Time | Use |\n'
|
||||
'| -------------------- | ------- | ----- | ------ | ---- | ---- |\n'
|
||||
'| Northern Brewer (DE) | Germany | 4.9 % | 1.0 oz | 60 | Boil |'
|
||||
'| Name | Origin | Alpha | Amount | Time |'
|
||||
' Use |\n'
|
||||
'| -------------------- | ------- | ----- | ------ | -------- |'
|
||||
' ------- |\n'
|
||||
'| Northern Brewer (DE) | Germany | 4.9 % | 1.0 oz | 60 min |'
|
||||
' Boil |\n'
|
||||
'| Cascade | U.S. | 5.5 % | 0.5 oz | 5.0 days |'
|
||||
' Dry Hop |'
|
||||
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue