init.m

init.m

is a Wolfram System initialization file.

Details

  • Wolfram System initialization files contain start-up code to be evaluated whenever a Wolfram Language kernel or front end is launched.
  • Possible locations for init.m files include the following:
  • $BaseDirectory/Kernelkernel initialization code for all users
    $UserBaseDirectory/Kernelkernel initialization code for the currently logged-in user
    $BaseDirectory/FrontEndfront end initialization code for all users
    $UserBaseDirectory/FrontEndfront end initialization code for the currently logged-in user
  • The user-specific initialization files within $UserBaseDirectory are read after the systemwide initialization files within $BaseDirectory, so any conflicting symbols will be defined as in the user-specific initialization files.
  • The Wolfram System will also load the init.m files of applications that are installed in Autoload directories.
  • To suppress the loading of kernel initialization files, use the kernel command-line option -noinit.
  • To specify another file to be used for kernel initialization in addition to init.m, use the kernel command-line option -initfile file, where file is the additional initialization file.
  • Template initialization files for the kernel are created automatically if they do not already exist.
  • If front end options are changed while the Wolfram System is running, the user-specific front end initialization file will be updated automatically to reflect these changes. The systemwide front end initialization file will remain unchanged.