Skip to content

Commit

Permalink
Merge pull request #7 from Wall-Brew-Co/de-const
Browse files Browse the repository at this point in the history
De-constify
  • Loading branch information
nnichols committed Oct 10, 2020
2 parents b5d3b79 + 7d071f9 commit 610a7a1
Show file tree
Hide file tree
Showing 59 changed files with 69 additions and 64 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/clojure.yml
Expand Up @@ -9,6 +9,8 @@ jobs:

steps:
- uses: actions/checkout@v1
- name: Test artifact build
run: lein uberjar
- name: Install Clojure/ClojureScript dependencies
run: lein deps
- name: Install node.js dependencies
Expand All @@ -17,4 +19,3 @@ jobs:
run: lein test-build
# - name: Secret Scan
# uses: max/secret-scan@1.0.0

4 changes: 4 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,7 @@
## v1.3.1 / 2020 Oct 10

> Drop ^:const use to allow uberjarring and to fix some performance issues in js contexts
## v1.3.0 / 2020 Jul 18

> Expose a conform function so downstream users aren't required to install spec tools as a dependency for edn data
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "common-beer-format",
"version": "1.3.0",
"version": "1.3.1",
"description": "An implementation of the BeerXML spec in multiple formats",
"main": "index.js",
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion project.clj
@@ -1,4 +1,4 @@
(defproject com.wallbrew/common-beer-format "1.3.0"
(defproject com.wallbrew/common-beer-format "1.3.1"
:description "An implementation of the BeerXML spec in multiple formats"
:url "https://github.com/Wall-Brew-Co/common-beer-format"
:license {:name "MIT"
Expand Down
2 changes: 1 addition & 1 deletion src/common_beer_format/data/fermentables/adjuncts.cljc
Expand Up @@ -37,5 +37,5 @@
:potential 1.0
:notes "Neutral hulls used to improve lautering."}))

(def ^:const adjuncts
(def adjuncts
(merge barley-hulls grits rice-hulls))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/fermentables/dry_extracts.cljc
Expand Up @@ -44,5 +44,5 @@
:potential 1.044
:notes "Wheat extract for general-purpose use in wheat beers."}))

(def ^:const dry-extracts
(def dry-extracts
(merge amber-dry-extract dark-dry-extract extra-light-dry-extract light-dry-extract wheat-dry-extract))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/fermentables/extracts.cljc
Expand Up @@ -93,5 +93,5 @@
:potential 1.036
:notes "Wheat/barley extract for general-purpose use in wheat beers."}))

(def ^:const extracts
(def extracts
(merge amber-liquid-extract dark-liquid-extract honey pale-liquid-extract pilsner-liquid-extract rice-extract-syrup rye-liquid-extract sorghum-syrup wheat-liquid-extract))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/fermentables/grains.cljc
Expand Up @@ -906,7 +906,7 @@
:protein 0.145
:notes "White wheat gives a malty flavor not available from raw wheat."}))

(def ^:const grains
(def grains
(merge acid-malt amber-malt aromatic-malt barley-flaked barley-raw barley-torrefied biscuit-malt black-patent-malt black-barley-stout brown-malt brumalt
cara-pils-dextrine carafoam dextrine caraamber caramel-crystal-malt-10l caramel-crystal-malt-20l caramel-crystal-malt-30l caramel-crystal-malt-40l
caramel-crystal-malt-60l caramel-crystal-malt-80l caramel-crystal-malt-90l caramel-crystal-malt-120l caramel-crystal-malt-140l caramel-crystal-malt-160l
Expand Down
2 changes: 1 addition & 1 deletion src/common_beer_format/data/fermentables/sugars.cljc
Expand Up @@ -172,6 +172,6 @@
:max-in-batch 0.1
:notes "A light, raw brown sugar used to increase starting gravity"}))

(def ^:const sugars
(def sugars
(merge dark-brown-sugar light-brown-sugar belgian-candi-syrup-45l belgian-candi-syrup-90l belgian-candi-syrup-180l clear-candi-sugar cane-sugar beet-sugar
dextrose corn-sugar corn-syrup demerara-sugar invert-sugar milk-sugar lactose molasses maple-syrup sucrose table-sugar turbinado))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/hops/aroma.cljc
Expand Up @@ -314,6 +314,6 @@
:alpha 0.06
:substitutes "Hallertau, Saaz, Mt Hood"}))

(def ^:const aroma
(def aroma
(merge crystal liberty glacier mt-hood simcoe cascade willamette spalt sterling santiam ultra ahtanum mosaic golding-us
east-kent-golding fuggle-us delta saaz-us palisade centennial hallertau-us amarillo vanguard strisselspalt))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/hops/bittering.cljc
Expand Up @@ -236,5 +236,5 @@
:alpha 0.08
:substitutes "Columbus, Chinook, Galena"}))

(def ^:const bittering
(def bittering
(merge summit chelan cluster eroica tillicum brewers-gold-us nugget bravo magnum-us apollo ctz super-galena warrior chinook millennium newport galena bullion))
2 changes: 1 addition & 1 deletion src/common_beer_format/data/hops/both.cljc
Expand Up @@ -158,5 +158,5 @@
:alpha 0.15
:substitutes "Galaxy, Citra, Amarillo"}))

(def ^:const both
(def both
(merge el-dorado celeia perle-us northdown horizon columbus challenger citra tettnanger galaxy topaz))
Expand Up @@ -48,5 +48,5 @@
:profile "Aroma: Same as the base beer, except that some additional fermentables (honey, molasses, etc.) may add an aroma component. Whatever additional aroma component is present should be in balance with the beer components, and be a pleasant combination. Appearance: Same as the base beer, although some sugars will bring additional colors. Flavor: Same as the base beer, except that some additional fermentables (honey, molasses, etc.) may add a flavor component. Whatever additional flavor component is present should be in balance with the beer components, and be a pleasant combination. Added sugars should not have a raw, unfermented flavor. Some added sugars will have unfermentable elements that may provide a fuller finish; fully fermentable sugars may thin out the finish. Mouthfeel: Same as the base beer, although depending on the type of sugar added, could increase or decrease the body."
:ibu-min 7}))

(def ^:const alternative-fermentables-beer
(def alternative-fermentables-beer
(merge alternative-grain-beer alternative-sugar-beer))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Moderate malty-sweet to malty-rich aroma with chocolate, caramel, nutty, and/or toasty qualities. Hop aroma is typically low to moderate, of almost any variety that complements the malt. Some interpretations of the style may feature a stronger hop aroma, an American or New World hop character (citrusy, fruity, tropical, etc.), and/or a fresh dry-hopped aroma (all are optional). Fruity esters are moderate to very low. The dark malt character is more robust than other brown ales, yet stops short of being overly porter-like. The malt and hops are generally balanced. Appearance: Light to very dark brown color. Clear. Low to moderate off-white to light tan head. Flavor: Medium to moderately-high malty-sweet or malty-rich flavor with chocolate, caramel, nutty, and/or toasty malt complexity, with medium to medium-high bitterness. The medium to medium-dry finish provides an aftertaste having both malt and hops. Hop flavor can be light to moderate, and may optionally have a citrusy, fruity, or tropical character, although any hop flavor that complements the malt is acceptable. Very low to moderate fruity esters. Mouthfeel: Medium to medium-full body. More bitter versions may have a dry, resiny impression. Moderate to moderately-high carbonation."
:ibu-min 20}))

(def ^:const amber-and-brown-american-beer
(def amber-and-brown-american-beer
(merge american-amber-ale california-common american-brown-ale))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Moderate intensity of German malt, typically rich, bready, somewhat toasty, with light bread crust notes. Moderately-low to moderate spicy peppery hop aroma. Very low to low diacetyl, occasionally low to moderately-low sulfur and very low green apple or other yeast-derived notes. Caramel, biscuity, or roasted malt aroma is inappropriate. Appearance: Moderately cloudy to clear depending on age, but never extremely cloudy or murky. Gold to deep reddish-amber color. Off-white, creamy head. When served on cask, can have low carbonation and very low head. Flavor: Initial malt flavor may suggest sweetness, but finish is moderately dry to dry, and slightly bitter. Distinctive and complex maltiness often includes a bready-toasty aspect. Hop bitterness is moderate to moderately high, and spicy or herbal hop flavor is low to moderately high. Balance can be either on the malt or hop side, but the finish is not sweet. Noticeable caramel or roasted malt flavors are inappropriate. Very low to low diacetyl. Possible very low green apple or other yeast-derived notes. Smooth, malty aftertaste. Mouthfeel: Medium body, with a creamy texture and medium carbonation. Fully fermented, without a sweet or cloying impression."
:ibu-min 25}))

(def ^:const amber-bitter-european-beer
(def amber-bitter-european-beer
(merge vienna-lager altbier kellerbier))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Medium to medium-high bready-malty-rich aroma, often with moderate amounts of rich Maillard products and/or toasty overtones. Virtually no hop aroma. Some alcohol may be noticeable. Clean lager character, although the malts can provide a slight (low to none) dark fruit character, particularly in aged examples. Appearance: Light copper to brown color, often with attractive garnet highlights. Lagering should provide good clarity despite the dark color. Large, creamy, persistent, off-white head. Flavor: Complex, rich maltiness is dominated by the toasty-rich Maillard products. Some caramel notes may be present. Hop bitterness is generally only high enough to support the malt flavors, allowing a bit of sweetness to linger into the finish. Well-attenuated, not cloying. Clean fermentation profile, although the malt can provide a slight dark fruit character. No hop flavor. No roasted or burnt character. Mouthfeel: Medium to medium-full bodied. Moderate to moderately low carbonation. Some alcohol warmth may be found, but should never be hot. Smooth, without harshness or astringency."
:ibu-min 20}))

(def ^:const amber-malty-european-lager
(def amber-malty-european-lager
(merge märzen rauchbier dunkles-bock))
Expand Up @@ -70,5 +70,5 @@
:profile "Aroma: Rich and complex, with variable amounts of roasted grains, maltiness, fruity esters, hops, and alcohol. The roasted malt character can take on coffee, dark chocolate, or slightly burnt tones and can be light to moderately strong. The malt aroma can be subtle to rich and barleywine-like. May optionally show a slight specialty malt character (e.g., caramel), but this should only add complexity and not dominate. Fruity esters may be low to moderately strong, and may take on a complex, dark fruit (e.g., plums, prunes, raisins) character. Hop aroma can be very low to quite aggressive, and may contain any hop variety. An alcohol character may be present, but shouldn't be sharp, hot, or solventy. Aged versions may have a slight vinous or port-like quality, but shouldn't be sour. The balance can vary with any of the aroma elements taking center stage. Not all possible aromas described need be present; many interpretations are possible. Aging affects the intensity, balance and smoothness of aromatics. Appearance: Color may range from very dark reddish-brown to jet black. Opaque. Deep tan to dark brown head. Generally has a well-formed head, although head retention may be low to moderate. High alcohol and viscosity may be visible in \"legs\" when beer is swirled in a glass. Flavor: Rich, deep, complex and frequently quite intense, with variable amounts of roasted malt/grains, maltiness, fruity esters, hop bitterness and flavor, and alcohol. Medium to aggressively high bitterness. Medium-low to high hop flavor (any variety). Moderate to aggressively high roasted malt/grain flavors can suggest bittersweet or unsweetened chocolate, cocoa, and/or strong coffee. A slightly burnt grain, burnt currant or tarry character may be evident. Fruity esters may be low to intense, and can take on a dark fruit character (raisins, plums, or prunes). Malt backbone can be balanced and supportive to rich and barleywine-like, and may optionally show some supporting caramel, bready or toasty flavors. The palate and finish can vary from relatively dry to moderately sweet, usually with some lingering roastiness, hop bitterness and warming character. The balance and intensity of flavors can be affected by aging, with some flavors becoming more subdued over time and some aged, vinous or port-like qualities developing. Mouthfeel: Full to very full-bodied and chewy, with a velvety, luscious texture (although the body may decline with long conditioning). Gentle smooth warmth from alcohol should be present and noticeable, but not a primary characteristic; in well-conditioned versions, the alcohol can be deceptive. Should not be syrupy or under-attenuated. Carbonation may be low to moderate, depending on age and conditioning."
:ibu-min 50}))

(def ^:const american-porter-and-stout
(def american-porter-and-stout
(merge american-porter american-stout imperial-stout))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Variable by base style. Should show the fruit, sour and/or funk of a wild fermentation, as well as the characteristics of the special ingredients used. The best examples will blend the aromatics from the fermentation with the special ingredients, creating an aroma that may be difficult to attribute precisely. Appearance: Variable by base style, generally showing a color, tint, or hue from any fruit (if used) in both the beer and the head. Clarity can be variable; some haze is not a fault. Head retention is often poor. Flavor: Variable by base style. Should show the fruit, sour and/or funk of a wild fermentation, as well as the characteristics of the special ingredients used. Any fruit sweetness is generally gone, so only the esters typically remain from the fruit. The sour character from the fruit and wild fermentation could be prominent, but should not be overwhelming. The acidity and tannin from any fruit can both enhance the dryness of the beer, so care must be taken with the balance. The acidity should enhance the perception of the fruit flavor, not detract from it. Wood notes, if present, add flavor but should be balanced. Mouthfeel: Variable by base style. Generally a light body, lighter than what might be expected from the base style. Generally moderate to high carbonation; carbonation should balance the base style if one is declared. The presence of tannin from some fruit or wood can provide a slight astringency, enhance the body, or make the beer seem drier than it is."
:ibu-min 7}))

(def ^:const american-wild-ale
(def american-wild-ale
(merge brett-beer mixed-fermentation-sour-beer wild-specialty-beer))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Prominent malty sweetness, often with a complex, light to moderate intensity toasty-bready-rich malt character. Low to moderate esters. Little to no hop aroma (may be a bit spicy, peppery, or herbal). Paler versions will still be malty but will lack richer, deeper aromatics and may have a bit more hops. Generally quite clean, although stronger versions may have a light, spicy alcohol note as it warms. Appearance: Three main variations exist (blond, amber and brown), so color can range from golden-blonde to reddish-bronze to chestnut brown. Clarity is brilliant to fair, although haze is not unexpected in this type of often unfiltered beer. Well-formed head, generally white to off-white (varies by beer color), average persistence. Flavor: Medium to high malt flavor often with a toasty-rich, biscuity, toffee-like or light caramel-sweet character. Malt flavors and complexity tend to increase with beer color. Low to moderate esters and alcohol flavors. Medium-low hop bitterness provides some support, but the balance is always tilted toward the malt. Darker versions will have more of an initial malty-sweet impression than paler versions, but all should be malty in the palate and finish. The malt flavor lasts into the finish, which is medium-dry to dry, never cloying. Low to no hop flavor (spicy, peppery, or herbal), although paler versions can have slightly higher levels of herbal or spicy hop flavor (which can also come from the yeast). Smooth, well-lagered character, even if made with ale yeast. Aftertaste of malt (character appropriate for the color) with some dryness and light alcohol. Mouthfeel: Medium to medium-light (lean) body, often with a smooth, creamy-silky character. Moderate to high carbonation. Moderate alcohol warming, but should be very smooth and never hot."
:ibu-min 18}))

(def ^:const belgian-ale
(def belgian-ale
(merge witbier belgian-pale-ale bière-de-garde))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Hop aroma moderately-high to moderately-low, typically with a floral, earthy, resiny, and/or fruity character. Medium to medium-high malt aroma, optionally with a low to moderate caramel component. Medium-low to medium-high fruity esters. Generally no diacetyl, although very low levels are allowed. Appearance: Light amber to deep copper color. Good to brilliant clarity. Low to moderate white to off-white head. A low head is acceptable when carbonation is also low. Flavor: Medium to medium-high bitterness with supporting malt flavors evident. The malt profile is typically bready, biscuity, nutty, or lightly toasty, and optionally has a moderately low to moderate caramel or toffee flavor. Hop flavor moderate to moderately high, typically with a floral, earthy, resiny, and/or fruity character. Hop bitterness and flavor should be noticeable, but should not totally dominate malt flavors. Moderately-low to high fruity esters. Optionally may have low amounts of alcohol. Medium-dry to dry finish. Generally no diacetyl, although very low levels are allowed. Mouthfeel: Medium-light to medium-full body. Low to moderate carbonation, although bottled versions will be higher. Stronger versions may have a slight alcohol warmth but this character should not be too high."
:ibu-min 30}))

(def ^:const british-bitter
(def british-bitter
(merge ordinary-bitter best-bitter strong-bitter))
Expand Up @@ -71,5 +71,5 @@
:profile "Aroma: Moderate to moderately low bready, biscuity, and toasty malt aroma with mild roastiness, and may have a chocolate quality. May also show some non-roasted malt character in support (caramelly, nutty, toffee-like and/or sweet). May have up to a moderate level of floral or earthy hops. Fruity esters moderate to none. Diacetyl low to none. Appearance: Light brown to dark brown in color, often with ruby highlights when held up to light. Good clarity, although may approach being opaque. Moderate off-white to light tan head with good to fair retention. Flavor: Moderate bready, biscuity, and toasty malt flavor includes a mild to moderate roastiness (frequently with a chocolate character) and often a significant caramel, nutty, and/or toffee character. May have other secondary flavors such as coffee, licorice, biscuits or toast in support. Should not have a significant burnt or harsh roasted flavor, although small amounts may contribute a bitter chocolate complexity. Earthy or floral hop flavor moderate to none. Medium-low to medium hop bitterness will vary the balance from slightly malty to slightly bitter. Usually fairly well-attenuated, although can be somewhat sweet. Diacetyl moderately-low to none. Moderate to low fruity esters. Mouthfeel: Medium-light to medium body. Moderately-low to moderately-high carbonation. Light to moderate creamy texture."
:ibu-min 18}))

(def ^:const brown-british-beer
(def brown-british-beer
(merge dark-mild british-brown-ale english-porter))

0 comments on commit 610a7a1

Please sign in to comment.