summaryrefslogtreecommitdiff
path: root/priv/templates
diff options
context:
space:
mode:
Diffstat (limited to 'priv/templates')
-rw-r--r--priv/templates/app.template2
-rw-r--r--priv/templates/app_rebar.config7
-rw-r--r--priv/templates/escript_rebar.config2
-rw-r--r--priv/templates/sup.erl3
4 files changed, 12 insertions, 2 deletions
diff --git a/priv/templates/app.template b/priv/templates/app.template
index d0bebd7..7d68b2c 100644
--- a/priv/templates/app.template
+++ b/priv/templates/app.template
@@ -6,7 +6,7 @@
{template, "app.erl", "{{name}}/src/{{name}}_app.erl"}.
{template, "sup.erl", "{{name}}/src/{{name}}_sup.erl"}.
{template, "otp_app.app.src", "{{name}}/src/{{name}}.app.src"}.
-{template, "rebar.config", "{{name}}/rebar.config"}.
+{template, "app_rebar.config", "{{name}}/rebar.config"}.
{template, "gitignore", "{{name}}/.gitignore"}.
{template, "LICENSE", "{{name}}/LICENSE"}.
{template, "README.md", "{{name}}/README.md"}.
diff --git a/priv/templates/app_rebar.config b/priv/templates/app_rebar.config
new file mode 100644
index 0000000..203ce4a
--- /dev/null
+++ b/priv/templates/app_rebar.config
@@ -0,0 +1,7 @@
+{erl_opts, [debug_info]}.
+{deps, []}.
+
+{shell, [
+ % {config, [{config, "config/sys.config"}]},
+ {apps, [{{name}}]}
+]}.
diff --git a/priv/templates/escript_rebar.config b/priv/templates/escript_rebar.config
index ef498a8..3ed7150 100644
--- a/priv/templates/escript_rebar.config
+++ b/priv/templates/escript_rebar.config
@@ -5,7 +5,7 @@
[{{name}}]}.
{escript_main_app, {{name}}}.
{escript_name, {{name}}}.
-{escript_emu_args, "%%! +sbtu +A0\n"}.
+{escript_emu_args, "%%! +sbtu +A1\n"}.
%% Profiles
{profiles, [{test,
diff --git a/priv/templates/sup.erl b/priv/templates/sup.erl
index a2e7209..0db7155 100644
--- a/priv/templates/sup.erl
+++ b/priv/templates/sup.erl
@@ -26,6 +26,9 @@ start_link() ->
%% Supervisor callbacks
%%====================================================================
+%% Child :: #{id => Id, start => {M, F, A}}
+%% Optional keys are restart, shutdown, type, modules.
+%% Before OTP 18 tuples must be used to specify a child. e.g.
%% Child :: {Id,StartFunc,Restart,Shutdown,Type,Modules}
init([]) ->
{ok, { {one_for_all, 0, 1}, []} }.