From 71170aa668a5b997dfb246961d14ce26088f2807 Mon Sep 17 00:00:00 2001 From: Sheharyar Naseer Date: Wed, 31 Jul 2024 02:44:25 -0600 Subject: [PATCH] Update and cleanup hexdocs --- README.md | 6 +++--- lib/memento/memento.ex | 3 +-- mix.exs | 36 ++++++++++++++++++++++++------------ 3 files changed, 28 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index dfc79c6..5ace2a8 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,9 @@ -

+
- Memento + Memento -

+

diff --git a/lib/memento/memento.ex b/lib/memento/memento.ex index 21c9f0c..39cda47 100644 --- a/lib/memento/memento.ex +++ b/lib/memento/memento.ex @@ -7,8 +7,7 @@ defmodule Memento do Simple + Powerful interface to the Erlang Mnesia Database. - See the [README](https://github.com/sheharyarn/memento) to get - started. + See the [README](https://hexdocs.pm/memento) to get started. """ diff --git a/mix.exs b/mix.exs index 3b4ad85..48dfdfd 100644 --- a/mix.exs +++ b/mix.exs @@ -27,17 +27,9 @@ defmodule Memento.Mixfile do description: description(), package: package(), deps: deps(), + docs: docs(), elixirc_paths: elixirc_paths(Mix.env), - - # ExDoc - name: @name, - source_url: @github, - homepage_url: @github, - docs: [ - main: @name, - canonical: "https://hexdocs.pm/#{@app}", - extras: ["README.md"] - ] + homepage_url: @github, ] end @@ -76,8 +68,28 @@ defmodule Memento.Mixfile do name: @app, maintainers: [@author], licenses: [@license], - files: ~w(mix.exs lib README.md), - links: %{"Github" => @github} + files: ~w(mix.exs lib README.md CHANGELOG.md), + links: %{"GitHub" => @github} + ] + end + + + # ExDoc + defp docs do + [ + name: @name, + main: "readme", + source_url: @github, + source_ref: "v#{@version}", + canonical: "https://hexdocs.pm/#{@app}", + extras: [ + {"README.md", title: @name}, + "CHANGELOG.md", + "LICENSE" + ], + assets: %{ + "media" => "media" + } ] end end