You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

140 lines
3.7 KiB

преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
  1. %% -*- mode: erlang;erlang-indent-level: 4;indent-tabs-mode: nil -*-
  2. %% ex: ts=4 sw=4 ft=erlang et
  3. %% This is a sample rebar.conf file that shows examples of some of rebar's
  4. %% options.
  5. %% == Core ==
  6. %% Additional library directories to add to the code path
  7. {lib_dirs, []}.
  8. %% == Erlang Compiler ==
  9. %% Erlang files to compile before the rest. Rebar automatically compiles
  10. %% parse_transforms and custom behaviours before anything other than the files
  11. %% in this list.
  12. {erl_first_files, ["mymib1", "mymib2"]}.
  13. %% Erlang compiler options
  14. {erl_opts, [no_debug_info, {i, "myinclude"}, {src_dirs, ["src1", "src2"]},
  15. {platform_define,
  16. "(linux|solaris|freebsd|darwin)", 'HAVE_SENDFILE'},
  17. {platform_define, "(linux|freebsd)", 'BACKLOG', 128},
  18. {platform_define, "R13", 'old_inets'}]}.
  19. %% MIB Options?
  20. {mib_opts, []}.
  21. %% SNMP mibs to compile first?
  22. {mib_first_files, []}.
  23. %% == EDoc ==
  24. %% EDoc options
  25. {edoc_opts, []}.
  26. %% == Port Compiler ==
  27. %% List and wildcard list of files to be compiled. Default is `"c_src/*.c"'
  28. {port_sources, []}.
  29. %% Port compilation environment variables. See rebar_port_compiler.erl for
  30. %% more info. Default is `[]'
  31. {port_envs, []}.
  32. %% Custom name of the port driver .so file. Defaults to `<Application>_drv.so'.
  33. {so_name, "driver.so"}.
  34. %% == LFE Compiler ==
  35. %% LFE files to compile before the rest
  36. {lfe_first_files, []}.
  37. %% Options for the LFE compiler: reuse {erl_opts, []}
  38. %% == ErlyDTL Compiler ==
  39. %% Options for the ErlyDTL compiler
  40. {erlydtl_opts, []}.
  41. %% == EUnit ==
  42. %% Options for eunit:test()
  43. {eunit_opts, []}.
  44. %% Additional compile options for eunit. erl_opts from above is also used
  45. {eunit_compile_opts, []}.
  46. %% Same as erl_first_files, but used only when running 'eunit'
  47. {eunit_first_files, []}.
  48. %% Whether to enable coverage reporting. Default is `false'
  49. {cover_enabled, false}.
  50. %% Whether to print coverage report to console. Default is `false'
  51. {cover_print_enabled, false}.
  52. %% == Common Test ==
  53. %% Option to pass extra parameters when launching Common Test
  54. {ct_extra_params, "-boot start_sasl -s myapp"}.
  55. %% == Dialyzer ==
  56. %% Options for running dialyzer
  57. %% {plt, PltFile}
  58. %% 'src': run Dialyzer on the source files as in 'dialyzer --src'
  59. %% {warnings, [WarnOpts]}: turn on/off Dialyzer warnings
  60. {dialyzer_opts, [{plt, PltFile}, {warnings, [WarnOpts]}, src]}.
  61. %% == Cleanup ==
  62. %% Which files to cleanup
  63. {clean_files, ["file", "file2"]}.
  64. %% == Reltool ==
  65. %% Target directory for the release
  66. {target, "target"}.
  67. %% == OTP Applications ==
  68. %% Binaries to link into the erlang path?
  69. {app_bin, []}.
  70. %% Enable validation of the OTP app module list. Default is 'true'
  71. {validate_app_modules, true}.
  72. %% == Dependencies ==
  73. %% Where to put any downloaded depandencies. Default is `deps'
  74. {deps_dir, ["deps"]}.
  75. %% What dependancies we have, depandencies can be of 3 forms, an application
  76. %% name as an atom, eg. mochiweb, a name and a version (from the .app file), or
  77. %% an application name, a version and the SCM details on how to fetch it (SCM
  78. %% type, location and revision). Rebar currently supports git, hg, bzr and svn.
  79. {deps, [application_name,
  80. {application_name, "1.0.*"},
  81. {application_name, "1.0.*",
  82. {git, "git://github.com/basho/rebar.git", {branch, "master"}}}]}.
  83. %% == Subdirectories ==
  84. %% Subdirectories?
  85. {sub_dirs, ["dir1", "dir2"]}.
  86. %% == Pre/Post Command Hooks ==
  87. {pre_hooks, [{clean, "./prepare_package_files.sh"},
  88. {compile, "escript generate_headers"}]}.
  89. {post_hooks, [{clean, "touch file1.out"},
  90. {eunit, "touch file2.out"},
  91. {compile, "touch postcompile.out"}]}.
  92. %% == xref ==
  93. {xref_warnings, false}.
  94. %% xref checks to run
  95. {xref_checks, [exports_not_used, undefined_function_calls]}.