No description
- C 90.7%
- Elixir 8.7%
- Makefile 0.6%
Makefile: Use CPPFLAGS See merge request pleroma/elixir-libraries/elixir-captcha!13 |
||
|---|---|---|
| config | ||
| lib | ||
| priv | ||
| src | ||
| test | ||
| .formatter.exs | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| LICENSE | ||
| Makefile | ||
| mix.exs | ||
| README.md | ||
Captcha
This is a Elixir lib for generating captcha. No dependencies. It drawing captcha image with C code. No ImageMagick, No RMagick.
C code come from: https://github.com/huacnlee/rucaptcha

Installation
If available in Hex, the package can be installed as:
- Add
captchato your list of dependencies inmix.exs:
```elixir
def deps do
[{:captcha, "~> 0.1.0"}]
end
```
- Ensure
captchais started before your application:
```elixir
def application do
[applications: [:captcha]]
end
```
Usage
# allow customize receive timeout, default: 10_000
case Captcha.get() do
{:ok, text, img_binary } ->
# save text in session, then send img to client
{:timeout} ->
# log some error
end