next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
Macaulay2Doc > The Macaulay2 language > system facilities > path

path -- list of directories to look in

Description

A list of strings containing names of directories in which load, input, loadPackage, needsPackage, and installPackage should seek files. These strings are simply concatenated with the filename being sought, so should include a terminal slash. One further directory is implicitly searched first: the directory containing the current input file; when input is coming from the standard input, that directory is the current directory of the process.

After the core Macaulay2 files are loaded, unless the command line option -q is encountered, the following subdirectories will be prepended to the path, based on the value of the applicationDirectory for your system.

     /home2/dan/.Macaulay2/code/
     /home2/dan/.Macaulay2/local/share/Macaulay2/
i1 : path

o1 = {./, /home2/dan/src/M2/M2/Macaulay2/m2/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/Macaulay2/packages/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-release-1.13/
     ------------------------------------------------------------------------
     Macaulay2/m2/, /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-
     ------------------------------------------------------------------------
     release-1.13/usr-dist/common/share/Macaulay2/Core/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-release-1.13/usr-
     ------------------------------------------------------------------------
     dist/common/share/Macaulay2/}

o1 : List
i2 : path = append(path, "~/resolutions/")

o2 = {./, /home2/dan/src/M2/M2/Macaulay2/m2/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/Macaulay2/packages/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-release-1.13/
     ------------------------------------------------------------------------
     Macaulay2/m2/, /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-
     ------------------------------------------------------------------------
     release-1.13/usr-dist/common/share/Macaulay2/Core/,
     ------------------------------------------------------------------------
     /home2/dan/src/M2/M2/BUILD/dan/builds.tmp/ubuntu1810-release-1.13/usr-
     ------------------------------------------------------------------------
     dist/common/share/Macaulay2/, ~/resolutions/}

o2 : List

For the programmer

The object path is a list.