Current section
8 Versions
Jump to
Current section
8 Versions
Compare versions
4
files changed
+29
additions
-17
deletions
| @@ -58,7 +58,7 @@ of the following in your `config/config.exs` file: | |
| 58 58 | config :ex_ngrok, |
| 59 59 | # The name of the Ngrok executable |
| 60 60 | executable: "ngrok", |
| 61 | - # The type of tunnel (http, tcp, or tls) |
| 61 | + # The type of tunnel (http, https, tcp, or tls) |
| 62 62 | protocol: "http", |
| 63 63 | # The port to which Ngrok will forward requests |
| 64 64 | port: "4000", |
| @@ -2,7 +2,7 @@ | |
| 2 2 | {<<"build_tools">>,[<<"mix">>]}. |
| 3 3 | {<<"description">>, |
| 4 4 | <<"A wrapper around Ngrok providing a secure tunnel to\nlocalhost for demoing your Elixir/Phoenix web application or testing\nwebhook integrations.">>}. |
| 5 | - {<<"elixir">>,<<"~> 1.3">>}. |
| 5 | + {<<"elixir">>,<<"~> 1.7">>}. |
| 6 6 | {<<"files">>, |
| 7 7 | [<<"bin/wrap">>,<<"lib/api.ex">>,<<"lib/ex_ngrok.ex">>, |
| 8 8 | <<"lib/executable.ex">>,<<"lib/settings.ex">>,<<"mix.exs">>,<<"README.md">>, |
| @@ -12,12 +12,14 @@ | |
| 12 12 | {<<"maintainers">>,[<<"Joshua Fleck">>]}. |
| 13 13 | {<<"name">>,<<"ex_ngrok">>}. |
| 14 14 | {<<"requirements">>, |
| 15 | - [[{<<"app">>,<<"httpoison">>}, |
| 16 | - {<<"name">>,<<"httpoison">>}, |
| 17 | - {<<"optional">>,false}, |
| 18 | - {<<"requirement">>,<<"~> 0.10">>}], |
| 19 | - [{<<"app">>,<<"poison">>}, |
| 15 | + [[{<<"app">>,<<"poison">>}, |
| 20 16 | {<<"name">>,<<"poison">>}, |
| 21 17 | {<<"optional">>,false}, |
| 22 | - {<<"requirement">>,<<"~> 3.0">>}]]}. |
| 23 | - {<<"version">>,<<"0.3.3">>}. |
| 18 | + {<<"repository">>,<<"hexpm">>}, |
| 19 | + {<<"requirement">>,<<"~> 3.1">>}], |
| 20 | + [{<<"app">>,<<"httpoison">>}, |
| 21 | + {<<"name">>,<<"httpoison">>}, |
| 22 | + {<<"optional">>,false}, |
| 23 | + {<<"repository">>,<<"hexpm">>}, |
| 24 | + {<<"requirement">>,<<"~> 1.4">>}]]}. |
| 25 | + {<<"version">>,<<"0.3.4">>}. |
| @@ -20,10 +20,20 @@ defmodule Ngrok.Executable do | |
| 20 20 | defp ngrok do |
| 21 21 | arguments = [ |
| 22 22 | Application.get_env(:ex_ngrok, :executable), |
| 23 | - Application.get_env(:ex_ngrok, :protocol), |
| 23 | + protocol(), |
| 24 24 | Application.get_env(:ex_ngrok, :port), |
| 25 25 | Application.get_env(:ex_ngrok, :options), |
| 26 26 | ] |
| 27 27 | Enum.join(arguments, " ") |
| 28 28 | end |
| 29 | + |
| 30 | + @spec protocol :: String.t |
| 31 | + defp protocol do |
| 32 | + case Application.get_env(:ex_ngrok, :protocol) do |
| 33 | + "https" -> |
| 34 | + "http" |
| 35 | + protocol -> |
| 36 | + protocol |
| 37 | + end |
| 38 | + end |
| 29 39 | end |
| @@ -3,8 +3,8 @@ defmodule Ngrok.Mixfile do | |
| 3 3 | |
| 4 4 | def project do |
| 5 5 | [app: :ex_ngrok, |
| 6 | - version: "0.3.3", |
| 7 | - elixir: "~> 1.3", |
| 6 | + version: "0.3.4", |
| 7 | + elixir: "~> 1.7", |
| 8 8 | build_embedded: Mix.env == :prod, |
| 9 9 | start_permanent: Mix.env == :prod, |
| 10 10 | deps: deps(), |
| @@ -27,11 +27,11 @@ defmodule Ngrok.Mixfile do | |
| 27 27 | |
| 28 28 | defp deps do |
| 29 29 | [ |
| 30 | - {:ex_doc, "~> 0.14", only: :dev, runtime: false}, |
| 31 | - {:credo, "~> 0.5", only: [:dev, :test], runtime: false}, |
| 32 | - {:dialyxir, "~> 0.4", only: [:dev], runtime: false}, |
| 33 | - {:httpoison, "~> 0.10"}, |
| 34 | - {:poison, "~> 3.0"} |
| 30 | + {:ex_doc, "~> 0.19", only: :dev, runtime: false}, |
| 31 | + {:credo, "~> 0.10", only: [:dev, :test], runtime: false}, |
| 32 | + {:dialyxir, "~> 0.5", only: [:dev], runtime: false}, |
| 33 | + {:httpoison, "~> 1.4"}, |
| 34 | + {:poison, "~> 3.1"} |
| 35 35 | ] |
| 36 36 | end |