Skip to content

Commit

Permalink
Merge branch 'main' into v0.1.x
Browse files Browse the repository at this point in the history
  • Loading branch information
leandrocp committed Oct 9, 2024
2 parents 0494af8 + 8c60bf7 commit 9e5d24e
Show file tree
Hide file tree
Showing 10 changed files with 44 additions and 16 deletions.
6 changes: 3 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Changelog

## 0.1.0-dev
## 0.1.0 (2024-10-09)

### Breaking Changes
* Require minimum Elixir v1.14
* Require minimun `:mdex` v0.1.17
* Require minimum Elixir v1.14.0
* Require minimun `:mdex` v0.2.0
* Removed config `:skip_boot?` in favor of `:mode` which can be `:live`, `:testing`, and `:manual` (defaults to `:live`) - the major difference between then is that live loads all modules and broadcasts all messages, testing only does that when it makes sense for tests (for example it does reload modules on fixtures), and manual does pretty much nothing, it's useful to seed data or to test specific scenarios where you need total control over Beacon.Loader

### Enhancements
Expand Down
4 changes: 2 additions & 2 deletions assets/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 assets/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "beacon",
"version": "0.1.0-dev",
"version": "0.1.0",
"license": "MIT",
"repository": {},
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion guides/introduction/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Note that Beacon supports Umbrella applications as well.
7. Add `:beacon` and `:beacon_live_admin` dependencies to `mix.exs`

```diff
+ {:beacon, "~> 0.1.0-rc.2", override: true},
+ {:beacon, "~> 0.1.0", override: true},
+ {:beacon_live_admin, ">= 0.0.0"},
```

Expand Down
6 changes: 3 additions & 3 deletions guides/recipes/customize-markdown-rendering.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Customize Markdown Rendering

Markdown pages are rendered using the [Beacon.Template.Markdown](https://hexdocs.pm/beacon/0.1.0-rc.2/Beacon.Template.Markdown.html) module with a set of default options that works for most cases,
Markdown pages are rendered using the [Beacon.Template.Markdown](https://hexdocs.pm/beacon/0.1.0/Beacon.Template.Markdown.html) module with a set of default options that works for most cases,
but you might want to change how some features work or enable more features. For example, let's suppose you want to generate an ID for every header of the page with the suffix `"topic-"`.

You can do that by changing the `:load_template` lifecycle of `:markdown` in your [site configuration](https://hexdocs.pm/beacon/0.1.0-rc.2/Beacon.html#start_link/1) as the example below:
You can do that by changing the `:load_template` lifecycle of `:markdown` in your [site configuration](https://hexdocs.pm/beacon/0.1.0/Beacon.html#start_link/1) as the example below:

```elixir
[
Expand Down Expand Up @@ -31,4 +31,4 @@ so the only features enabled will be the one you set and the others will take th

For example with this configuration the `:header_ids` extension is enabled but others like tables and autolinks would be turned off.

You can inspect the actual configuration in the [Beacon.Template.Markdown](https://hexdocs.pm/beacon/0.1.0-rc.2/Beacon.Template.Markdown.html) module and also check the [MDEx docs](https://hexdocs.pm/mdex/MDEx.html#to_html/2) for more info.
You can inspect the actual configuration in the [Beacon.Template.Markdown](https://hexdocs.pm/beacon/0.1.0/Beacon.Template.Markdown.html) module and also check the [MDEx docs](https://hexdocs.pm/mdex/MDEx.html#to_html/2) for more info.
2 changes: 1 addition & 1 deletion guides/recipes/testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ config :my_app, :my_site, mode: :testing

And the actual test would look like the example below.

First we create and publish a page by calling the [fixture](https://hexdocs.pm/beacon/0.1.0-rc.2/Beacon.Test.Fixtures.html) `beacon_published_page_fixture/0`,
First we create and publish a page by calling the [fixture](https://hexdocs.pm/beacon/0.1.0/Beacon.Test.Fixtures.html) `beacon_published_page_fixture/0`,
then we build and assert the correct email was delivered, using [assert_delivered_email/1](https://hexdocs.pm/bamboo/Bamboo.Test.html#assert_delivered_email/2)
from the Bamboo library.

Expand Down
28 changes: 28 additions & 0 deletions guides/upgrading/v0.1.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Upgrading to v0.1.0

## Bump your deps

Update Beacon to v0.1.x

```elixir
[
{:beacon, "~> 0.1.0"}
]
```

Note that a more relaxed version like `~> 0.1` or `>= 0.0.0` would install the version `1.1.0` which is not the Beacon CSM project,
ie: you have to install a version that is less than `1.0.0`.

Remember to keep the option `override: true` if running BeaconLiveAdmin in the same project.

## Update sites config

Replace the option `:skip_boot?` with `:mode` if you were using it (most sites don't need to set this option).

## Update Elixir version

Beacon v0.1.0 requires Elixir 1.14.0 or later, please update your tools if necessary.

## Update mdex version (only if using `:mdex` directly)

Update `:mdex` to `~> 0.2` in your `mix.exs` file, and replace any calls to `MDEx.to_html` with `MDEx.to_html/1`.
2 changes: 1 addition & 1 deletion lib/beacon/template/markdown.ex
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ defmodule Beacon.Template.Markdown do
syntax_highlight_theme = Keyword.get(opts, :syntax_highlight_theme, "onedark")

template =
MDEx.to_html(template,
MDEx.to_html!(template,
extension: [
strikethrough: true,
tagfilter: false,
Expand Down
4 changes: 2 additions & 2 deletions mix.exs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
defmodule Beacon.MixProject do
use Mix.Project

@version "0.1.0-dev"
@version "0.1.0"
@source_url "https://github.com/BeaconCMS/beacon"
@homepage_url "https://beaconcms.org"

Expand Down Expand Up @@ -55,7 +55,7 @@ defmodule Beacon.MixProject do
override_dep(:phoenix, "~> 1.7", "PHOENIX_VERSION", "PHOENIX_PATH"),
override_dep(:phoenix_live_view, "~> 0.20", "PHOENIX_LIVE_VIEW_VERSION", "PHOENIX_LIVE_VIEW_PATH"),
override_dep(:live_monaco_editor, "~> 0.1", "LIVE_MONACO_EDITOR_VERSION", "LIVE_MONACO_EDITOR_PATH"),
override_dep(:mdex, "~> 0.1.17", "MDEX_VERSION", "MDEX_PATH"),
override_dep(:mdex, "~> 0.2", "MDEX_VERSION", "MDEX_PATH"),

# Runtime
{:accent, "~> 1.1"},
Expand Down
4 changes: 2 additions & 2 deletions mix.lock
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"makeup": {:hex, :makeup, "1.1.2", "9ba8837913bdf757787e71c1581c21f9d2455f4dd04cfca785c70bbfff1a76a3", [:mix], [{:nimble_parsec, "~> 1.2.2 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "cce1566b81fbcbd21eca8ffe808f33b221f9eee2cbc7a1706fc3da9ff18e6cac"},
"makeup_elixir": {:hex, :makeup_elixir, "0.16.2", "627e84b8e8bf22e60a2579dad15067c755531fea049ae26ef1020cad58fe9578", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}, {:nimble_parsec, "~> 1.2.3 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "41193978704763f6bbe6cc2758b84909e62984c7752b3784bd3c218bb341706b"},
"makeup_erlang": {:hex, :makeup_erlang, "1.0.1", "c7f58c120b2b5aa5fd80d540a89fdf866ed42f1f3994e4fe189abebeab610839", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}], "hexpm", "8a89a1eeccc2d798d6ea15496a6e4870b75e014d1af514b1b71fa33134f57814"},
"mdex": {:hex, :mdex, "0.1.18", "20c5b12633e485f9a6eaf06e8d992fa186c5798be98d1405ee6a8bb6b465f59e", [:mix], [{:rustler, "~> 0.32", [hex: :rustler, repo: "hexpm", optional: true]}, {:rustler_precompiled, "~> 0.7", [hex: :rustler_precompiled, repo: "hexpm", optional: false]}], "hexpm", "726b1aee2cc197c08f5b004d73a64d268d28837f79f8eaba74478237ddc9930f"},
"mdex": {:hex, :mdex, "0.2.0", "af93e03bc964f2628c3940d22ba03435b119e070bd423fd62d31772d428a7e6c", [:mix], [{:rustler, "~> 0.32", [hex: :rustler, repo: "hexpm", optional: true]}, {:rustler_precompiled, "~> 0.7", [hex: :rustler_precompiled, repo: "hexpm", optional: false]}], "hexpm", "d8d21d3d6ecb0b2a10f88b539f3a61df974f9570226bf6bd24404c9e361c8089"},
"metrics": {:hex, :metrics, "1.0.1", "25f094dea2cda98213cecc3aeff09e940299d950904393b2a29d191c346a8486", [:rebar3], [], "hexpm", "69b09adddc4f74a40716ae54d140f93beb0fb8978d8636eaded0c31b6f099f16"},
"mime": {:hex, :mime, "2.0.6", "8f18486773d9b15f95f4f4f1e39b710045fa1de891fada4516559967276e4dc2", [:mix], [], "hexpm", "c9945363a6b26d747389aac3643f8e0e09d30499a138ad64fe8fd1d13d9b153e"},
"mimerl": {:hex, :mimerl, "1.3.0", "d0cd9fc04b9061f82490f6581e0128379830e78535e017f7780f37fea7545726", [:rebar3], [], "hexpm", "a1e15a50d1887217de95f0b9b0793e32853f7c258a5cd227650889b38839fe9d"},
Expand All @@ -58,7 +58,7 @@
"poison": {:hex, :poison, "6.0.0", "9bbe86722355e36ffb62c51a552719534257ba53f3271dacd20fbbd6621a583a", [:mix], [{:decimal, "~> 2.1", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "bb9064632b94775a3964642d6a78281c07b7be1319e0016e1643790704e739a2"},
"postgrex": {:hex, :postgrex, "0.19.1", "73b498508b69aded53907fe48a1fee811be34cc720e69ef4ccd568c8715495ea", [:mix], [{:db_connection, "~> 2.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:decimal, "~> 1.5 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:table, "~> 0.1.0", [hex: :table, repo: "hexpm", optional: true]}], "hexpm", "8bac7885a18f381e091ec6caf41bda7bb8c77912bb0e9285212829afe5d8a8f8"},
"ranch": {:hex, :ranch, "1.8.0", "8c7a100a139fd57f17327b6413e4167ac559fbc04ca7448e9be9057311597a1d", [:make, :rebar3], [], "hexpm", "49fbcfd3682fab1f5d109351b61257676da1a2fdbe295904176d5e521a2ddfe5"},
"rustler_precompiled": {:hex, :rustler_precompiled, "0.8.1", "8afe0b6f3a9a677ada046cdd23e3f4c6399618b91a6122289324774961281e1e", [:mix], [{:castore, "~> 0.1 or ~> 1.0", [hex: :castore, repo: "hexpm", optional: false]}, {:rustler, "~> 0.23", [hex: :rustler, repo: "hexpm", optional: true]}], "hexpm", "90b8c2297bf7959cfa1c927b2881faad7bb0707183124955369991b76177a166"},
"rustler_precompiled": {:hex, :rustler_precompiled, "0.8.2", "5f25cbe220a8fac3e7ad62e6f950fcdca5a5a5f8501835d2823e8c74bf4268d5", [:mix], [{:castore, "~> 0.1 or ~> 1.0", [hex: :castore, repo: "hexpm", optional: false]}, {:rustler, "~> 0.23", [hex: :rustler, repo: "hexpm", optional: true]}], "hexpm", "63d1bd5f8e23096d1ff851839923162096364bac8656a4a3c00d1fff8e83ee0a"},
"safe_code": {:hex, :safe_code, "0.2.3", "c37329a03d4ac847ccd437344abdbb6d8a8ff6a46f1b6e5ad976bf9a86a5227f", [:mix], [{:jason, "~> 1.3", [hex: :jason, repo: "hexpm", optional: false]}, {:phoenix_live_view, ">= 0.18.17", [hex: :phoenix_live_view, repo: "hexpm", optional: false]}], "hexpm", "de5f3ad37d0f7804281f42be8dac32ee52f7b5f7c5c4c851eba34e42bffd4aef"},
"solid": {:hex, :solid, "0.15.2", "6921af98a3a862041bb6af72b5f6e094dbf0242366b142f98a92cabe4ed30d2a", [:mix], [{:nimble_parsec, "~> 1.0", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "18b062b04948b7f7b99ac4a9360681dac7e0bd142df5e62a7761696c7384be45"},
"ssl_verify_fun": {:hex, :ssl_verify_fun, "1.1.7", "354c321cf377240c7b8716899e182ce4890c5938111a1296add3ec74cf1715df", [:make, :mix, :rebar3], [], "hexpm", "fe4c190e8f37401d30167c8c405eda19469f34577987c76dde613e838bbc67f8"},
Expand Down

0 comments on commit 9e5d24e

Please sign in to comment.