2.2 The user's initialisation file

After the necessary system initialisation the system consults (see consult/1) the user's startup file. The base-name of this file follows conventions of the operating system. On MS-Windows, it is the file pl.ini and on Unix systems .plrc. The file is searched using the file_search_path/2 clauses for user_profile. The table below shows the default value for this search-path. The phrase <appdata> refers to the Windows CSIDL name for the folder. The actual name depends on the Windows language. English versions typically use ApplicationData. See also win_folder/2

UnixWindows
local. .
home~ <appdata>/SWI-Prolog

After the first startup file is found it is loaded and Prolog stops looking for further startup files. The name of the startup file can be changed with the `-f file' option. If File denotes an absolute path, this file is loaded, otherwise the file is searched for using the same conventions as for the default startup file. Finally, if file is none, no file is loaded.

See also the -s (script) and -F (system-wide initialisation) in section 2.4 and section 2.3.