Skip to content

Commit 73b62a5

Browse files
authored
Merge pull request #11 from erlangpack/readme-otp-21.3
Set min OTP version to 21.3. Update readme
2 parents 66a2b68 + 9401602 commit 73b62a5

File tree

3 files changed

+60
-3
lines changed

3 files changed

+60
-3
lines changed

README.md

Lines changed: 59 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,45 @@ algorithm, as described in
99
[A Future-Adaptable Password Scheme](http://www.openbsd.org/papers/bcrypt-paper.ps)
1010
by Niels Provos and David Mazieres.
1111

12+
This bcrypt repository at erlangpack is in active maintainance and used
13+
as the basis of the Hex package.
14+
15+
16+
OTP Compatibility
17+
-----------------
18+
19+
erlang-bcrypt is compatible with OTP 21.3 to 23.
20+
21+
Use version 1.0.3 on OTP versions before 21.3
22+
23+
In version 1.1.0 support for OTP 21.2 and earlier is removed
24+
due to the removal of erl_interface in OTP 23.
25+
26+
27+
Rebar.config
28+
------------
29+
30+
erlang-bcrypt is on Hex:
31+
32+
```erlang
33+
{deps, [
34+
{bcrypt, "1.1.0"}
35+
]}.
36+
```
37+
38+
To use the master branch:
39+
40+
```erlang
41+
{deps, [
42+
{bcrypt, {git, ".*", {git, "https://github.com/erlangpack/bcrypt.git", {branch, "master"}}}
43+
]}.
44+
```
45+
46+
1247
Basic build instructions
1348
------------------------
1449

15-
1. Build it (project uses rebar, but I’ve included a Makefile):
50+
1. Build it (project uses rebar3, a Makefile is included):
1651

1752
```shell
1853
make
@@ -21,7 +56,16 @@ Basic build instructions
2156
2. Run it (simple way, starting sasl, crypto and bcrypt):
2257

2358
```shell
24-
erl -pa ebin -boot start_sasl -s crypto -s bcrypt
59+
$ ./rebar3 shell
60+
===> Verifying dependencies...
61+
===> Compiling bcrypt
62+
make: Nothing to be done for `all'.
63+
Erlang/OTP 23 [erts-11.0] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1] [hipe]
64+
65+
Eshell V11.0 (abort with ^G)
66+
1> application:ensure_all_started(bcrypt).
67+
{ok,[bcrypt]}
68+
2>
2569
```
2670
2771
Basic usage instructions
@@ -65,6 +109,19 @@ application's environment:
65109
`pool_size`
66110
Specifies the size of the port program pool. Defaults to ``4``.
67111

112+
113+
Run tests
114+
---------
115+
116+
To run the eunit tests use:
117+
118+
```shell
119+
make tests
120+
```
121+
122+
Both the _port_ and the _NIF_ version of bcrypt are tested.
123+
All tests should pass.
124+
68125
Original authors
69126
----------------
70127

ebin/.gitignore

Whitespace-only changes.

rebar.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
%% -*- mode: erlang;erlang-indent-level: 2;indent-tabs-mode: nil -*-
22

3-
{require_min_otp_vsn, "21"}.
3+
{require_min_otp_vsn, "21.3"}.
44

55
{erl_opts,
66
[debug_info]}.

0 commit comments

Comments
 (0)