From 6f9d175335350c515fca5cdb772b709939e59e5e Mon Sep 17 00:00:00 2001 From: Gabor Liptak Date: Sun, 19 Dec 2010 17:52:54 -0500 Subject: Add back documentation on .erlang processing --- erts/doc/src/erl.xml | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) (limited to 'erts/doc/src/erl.xml') diff --git a/erts/doc/src/erl.xml b/erts/doc/src/erl.xml index 77bd952d41..9aebcf6111 100644 --- a/erts/doc/src/erl.xml +++ b/erts/doc/src/erl.xml @@ -1015,6 +1015,49 @@
+ + Configuration +

The standard Erlang/OTP system can be re-configured to change the default + behavior on start-up.

+ + The .erlang Start-up File + +

When Erlang/OTP is started, the system searches for a file named .erlang + in the directory where Erlang/OTP is started. If not found, the user's home + directory is searched for an .erlang file.

+

If an .erlang file is found, it is assumed to contain valid Erlang expressions. + These expressions are evaluated as if they were input to the shell.

+

A typical .erlang file contains a set of search paths, for example:

+ +
+ user_default and shell_default + +

Functions in the shell which are not prefixed by a module name are assumed + to be functional objects (Funs), built-in functions (BIFs), or belong to the + module user_default or shell_default.

+

To include private shell commands, define them in a module user_default and + add the following argument as the first line in the .erlang file.

+ +
+ erl + +

If the contents of .erlang are changed and a private version of + user_default is defined, it is possible to customize the Erlang/OTP environment. + More powerful changes can be made by supplying command line arguments in the + start-up script erl. Refer to erl(1) and init(3) + for further information.

+
+
+
+ +
SEE ALSO

init(3), erl_prim_loader(3), -- cgit v1.2.3