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.

161 lines
4.6 KiB

преди 14 години
преди 14 години
преди 14 години
преди 13 години
преди 14 години
преди 14 години
преди 14 години
преди 14 години
преди 13 години
преди 13 години
преди 14 години
преди 14 години
преди 13 години
преди 13 години
преди 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 of filenames or wildcards to be compiled. May also contain a tuple
  28. %% consisting of a regular expression to be applied against the system
  29. %% architecture and a list of filenames or wildcards to include should the
  30. %% expression pass. Default is `"c_src/*.c"'
  31. {port_sources, ["c_src/*.c", {"R14", ["c_src/*.c"]}]}.
  32. %% Port files to compile before the rest.
  33. {port_first_files, ["c_src/first.c", "c_src/second.c"]}.
  34. %% Port compilation environment variables. See rebar_port_compiler.erl for
  35. %% more info. Default is `[]'
  36. {port_envs, []}.
  37. %% Custom name of the port driver .so file. Defaults to `<Application>_drv.so'.
  38. {so_name, "driver.so"}.
  39. %% so_specs - useful for building multiple *.so files
  40. %% from one or more object files
  41. {so_specs, [{"priv/so_name.so", ["c_src/object_file_name.o"]}]}.
  42. %% == LFE Compiler ==
  43. %% LFE files to compile before the rest
  44. {lfe_first_files, []}.
  45. %% Options for the LFE compiler: reuse {erl_opts, []}
  46. %% == ErlyDTL Compiler ==
  47. %% Options for the ErlyDTL compiler
  48. {erlydtl_opts, []}.
  49. %% == EUnit ==
  50. %% Options for eunit:test()
  51. {eunit_opts, []}.
  52. %% Additional compile options for eunit. erl_opts from above is also used
  53. {eunit_compile_opts, []}.
  54. %% Same as erl_first_files, but used only when running 'eunit'
  55. {eunit_first_files, []}.
  56. %% Whether to enable coverage reporting. Default is `false'
  57. {cover_enabled, false}.
  58. %% Whether to print coverage report to console. Default is `false'
  59. {cover_print_enabled, false}.
  60. %% == Common Test ==
  61. %% Override the default "test" directory in which SUITEs are located
  62. {ct_dir, "itest"}.
  63. %% Option to pass extra parameters when launching Common Test
  64. {ct_extra_params, "-boot start_sasl -s myapp"}.
  65. %% == Cleanup ==
  66. %% Which files to cleanup
  67. {clean_files, ["file", "file2"]}.
  68. %% == Reltool ==
  69. %% Target directory for the release
  70. {target, "target"}.
  71. %% == OTP Applications ==
  72. %% Binaries to link into the erlang path?
  73. {app_bin, []}.
  74. %% Enable validation of the OTP app module list. Default is 'true'
  75. {validate_app_modules, true}.
  76. %% == Dependencies ==
  77. %% Where to put any downloaded dependencies. Default is "deps"
  78. {deps_dir, "deps"}.
  79. %% What dependencies we have, dependencies can be of 3 forms, an application
  80. %% name as an atom, eg. mochiweb, a name and a version (from the .app file), or
  81. %% an application name, a version and the SCM details on how to fetch it (SCM
  82. %% type, location and revision). Rebar currently supports git, hg, bzr and svn.
  83. {deps, [application_name,
  84. {application_name, "1.0.*"},
  85. {application_name, "1.0.*",
  86. {git, "git://github.com/basho/rebar.git", {branch, "master"}}}]}.
  87. %% == Subdirectories ==
  88. %% Subdirectories?
  89. {sub_dirs, ["dir1", "dir2"]}.
  90. %% == Plugins ==
  91. %% Plugins you wish to include.
  92. %% These can include any module on the code path, including deps.
  93. %% Alternatively, plugins can be placed as source files in the plugin_dir, in
  94. %% which case they will be compiled and loaded dynamically at runtime.
  95. {plugins, [plugin1, plugin2]}.
  96. %% Override the directory in which plugin sources can be found.
  97. %% Defaults to ./plugins
  98. {plugin_dir, "some_other_directory"}.
  99. %% == Pre/Post Command Hooks ==
  100. {pre_hooks, [{clean, "./prepare_package_files.sh"},
  101. {"linux", compile, "c_src/build_linux.sh"},
  102. {compile, "escript generate_headers"},
  103. {compile, "escript check_headers"}]}.
  104. {post_hooks, [{clean, "touch file1.out"},
  105. {"freebsd", compile, "c_src/freebsd_tweaks.sh"},
  106. {eunit, "touch file2.out"},
  107. {compile, "touch postcompile.out"}]}.
  108. %% == xref ==
  109. {xref_warnings, false}.
  110. %% xref checks to run
  111. {xref_checks, [exports_not_used, undefined_function_calls]}.