Skip to content

self.path

Say where this CLI keeps things — for scripts, and for finding out.

Named alone it prints one bare line, so DIR=$(fm self.path data) is the whole idiom. With no name it prints every location, and under --json it returns them as an object, so a script that wants three of them makes one call instead of three.

A location that does not apply here — project-root outside a project — is empty rather than absent: the question was answered.

fm self.path [<which> ...]
Parameter Type Default Description
<which>... variadic locations to print; none means every one

Returns: a mapping of text (or null)

Example

$ fm self.path <which>