Skip to content

Commit

Permalink
add metadata for package (#48)
Browse files Browse the repository at this point in the history
  • Loading branch information
nsidnev authored Feb 10, 2022
1 parent 8c6bb28 commit 45c47d6
Show file tree
Hide file tree
Showing 3 changed files with 73 additions and 33 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

[Compare with 0.1.0](https://github.com/nsidnev/edgedb-elixir/compare/0.1.0...HEAD)

## [0.1.0] - 2022-02-10

[Compare with first commit](https://github.com/nsidnev/edgedb-elixir/compare/a9c18f910e36e728eb8d59e6e8e41721474f201c...0.1.0)

### Added

- First release.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ How to use:
```elixir
iex(1)> {:ok, conn} = EdgeDB.start_link() # NOTE: you should initialize EdgeDB project first
iex(2)> arg = [16, 13, 2, 42]
[16, 13, 2, 42]
iex(3)> ^arg = EdgeDB.query_required_single!(conn, "SELECT <array<int64>>$arg", arg: arg)
[16, 13, 2, 42]
```
Expand Down
97 changes: 65 additions & 32 deletions mix.exs
Original file line number Diff line number Diff line change
@@ -1,36 +1,29 @@
defmodule EdgeDB.MixProject do
use Mix.Project

@version "0.0.0"
@app :edgedb
@version "0.1.0"
@source_url "https://github.com/nsidnev/edgedb-elixir"
@description "EdgeDB driver for Elixir"

def project do
[
app: :edgedb,
app: @app,
version: @version,
elixir: "~> 1.10",
elixir: "~> 1.12",
deps: deps(),
elixirc_paths: elixirc_paths(Mix.env()),
elixirc_options: [
warnings_as_errors: true
],
elixirc_options: elixirc_options(),
start_permanent: Mix.env() == :prod,
consolidate_protocols: Mix.env() != :test,
test_coverage: [tool: ExCoveralls],
preferred_cli_env: [
dialyzer: :test,
credo: :test,
coveralls: :test,
"coveralls.detail": :test,
"coveralls.github": :test,
"coveralls.html": :test
],
dialyzer: [
plt_add_apps: [:ex_unit],
plt_file: {:no_warn, "priv/plts/dialyzer.plt"}
],
test_coverage: test_coverage(),
preferred_cli_env: preferred_cli_env(),
dialyzer: dialyzer(),
aliases: aliases(),
name: "EdgeDB",
description: "EdgeDB driver for Elixir",
docs: docs()
description: @description,
docs: docs(),
package: package()
]
end

Expand All @@ -53,17 +46,65 @@ defmodule EdgeDB.MixProject do
{:decimal, "~> 2.0"},
{:jason, "~> 1.2", optional: true},
# dev/test
{:ex_doc, "~> 0.27", only: :dev, runtime: false},
{:dialyxir, "~> 1.0", only: [:dev, :test], runtime: false},
{:credo, "~> 1.2", only: [:dev, :test], runtime: false},
{:excoveralls, "~> 0.14", only: :test},
{:mox, "~> 1.0", only: :test}
{:mox, "~> 1.0", only: :test},
{:ex_doc, "~> 0.28", only: :dev, runtime: false}
]
end

defp elixirc_paths(:test) do
["lib", "test/support"]
end

defp elixirc_paths(_env) do
["lib"]
end

defp elixirc_options do
[
warnings_as_errors: true
]
end

defp dialyzer do
[
plt_add_apps: [:ex_unit],
plt_file: {:no_warn, "priv/plts/dialyzer.plt"}
]
end

defp test_coverage do
[
tool: ExCoveralls
]
end

defp preferred_cli_env do
[
dialyzer: :test,
credo: :test,
coveralls: :test,
"coveralls.detail": :test,
"coveralls.github": :test,
"coveralls.html": :test
]
end

defp package do
[
maintainers: ["Nik Sidnev"],
licenses: ["MIT"],
links: %{
"GitHub" => @source_url
}
]
end

defp docs do
[
source_url: "https://github.com/nsidnev/edgedb-elixir",
source_url: @source_url,
source_ref: "v#{@version}",
main: "main",
extras: [
Expand Down Expand Up @@ -91,14 +132,6 @@ defmodule EdgeDB.MixProject do
]
end

defp elixirc_paths(:test) do
["lib", "test/support"]
end

defp elixirc_paths(_env) do
["lib"]
end

defp aliases do
[
"edgedb.roles.setup": [
Expand Down

0 comments on commit 45c47d6

Please sign in to comment.