Spec-Zone.ru › Nushell

path self for path

Get the absolute path of the script or module containing this command at parse time.

Signature

> path self {flags} (path)

Parameters

  • path: Path to get instead of the current file.

Input/output types:

input output
nothing string

Examples

Get the path of the current file.

> const current_file = path self

Get the path of the directory containing the current file.

> const current_file = path self .

Get the absolute form of a path relative to the current file.

> const current_file = path self ../foo

Copyright © 2019–2026 The Nushell Project DevelopersLicensed under the MIT License.
https://www.nushell.sh/commands/docs/path_self.html

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API