Extract build status URLs to make lines shorter
This commit is contained in:
parent
89e3dda530
commit
684aa1a6e2
14
README.md
14
README.md
|
|
@ -1,6 +1,6 @@
|
||||||
# Isn
|
# Isn
|
||||||
|
|
||||||
[](https://semaphoreci.com/frost/isn)
|
[![Build Status][4]][5]
|
||||||
|
|
||||||
Isn adds a [`Postgrex.Extension`][1] and [`Ecto.Type`][2] definitions
|
Isn adds a [`Postgrex.Extension`][1] and [`Ecto.Type`][2] definitions
|
||||||
for the datatypes defined in the [`isn`][3] PostgreSQL module.
|
for the datatypes defined in the [`isn`][3] PostgreSQL module.
|
||||||
|
|
@ -8,15 +8,12 @@ for the datatypes defined in the [`isn`][3] PostgreSQL module.
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
1. Add the package to your Mixfile:
|
1. Add the package to your Mixfile:
|
||||||
|
|
||||||
```elixir
|
```elixir
|
||||||
defp deps do
|
defp deps do
|
||||||
[{:isn, "~> 0.1"}]
|
[{:isn, "~> 0.1"}]
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Add the isn extension to your database
|
2. Add the isn extension to your database
|
||||||
|
|
||||||
```elixir
|
```elixir
|
||||||
{:ok, pid} = Postgrex.Connection.start_link(
|
{:ok, pid} = Postgrex.Connection.start_link(
|
||||||
hostname: "localhost",
|
hostname: "localhost",
|
||||||
|
|
@ -24,16 +21,13 @@ end
|
||||||
)
|
)
|
||||||
Postgrex.Connection.query!(pid, "CREATE EXTENSION isn;", [])
|
Postgrex.Connection.query!(pid, "CREATE EXTENSION isn;", [])
|
||||||
```
|
```
|
||||||
|
3. Register the postgrex extension
|
||||||
2. Register the postgrex extension
|
|
||||||
|
|
||||||
```elixir
|
```elixir
|
||||||
Postgrex.Connection.start_link(
|
Postgrex.Connection.start_link(
|
||||||
database: "isn_test",
|
database: "isn_test",
|
||||||
extensions: [{Isn, {}}])
|
extensions: [{Isn, {}}])
|
||||||
```
|
```
|
||||||
|
4. Start using all of the `isn` goodness in your project.
|
||||||
3. Start using all of the `isn` goodness in your project.
|
|
||||||
|
|
||||||
## Examples
|
## Examples
|
||||||
|
|
||||||
|
|
@ -88,3 +82,5 @@ Ecto.Type | Postgrex type
|
||||||
[1]: http://hexdocs.pm/postgrex/Postgrex.Extension.html
|
[1]: http://hexdocs.pm/postgrex/Postgrex.Extension.html
|
||||||
[2]: http://hexdocs.pm/ecto/Ecto.Type.html
|
[2]: http://hexdocs.pm/ecto/Ecto.Type.html
|
||||||
[3]: http://www.postgresql.org/docs/9.4/static/isn.html
|
[3]: http://www.postgresql.org/docs/9.4/static/isn.html
|
||||||
|
[4]: https://semaphoreci.com/api/v1/projects/be7c4c34-c49e-45c7-9320-3fcc4f7f476a/458429/badge.svg
|
||||||
|
[5]: https://semaphoreci.com/frost/isn
|
||||||
Loading…
Reference in New Issue