MachineElf
MachineElf

Reputation: 1281

Sublime Text Build Systems variables

The docs for Sublime Text Build Systems state:

you can use some variables in build systems too, as we have done above with $file, which expands to the active buffer’s filename.

Are there more variables other than $file and if so where can I learn about them?

Upvotes: 1

Views: 292

Answers (1)

Darrick Herwehe
Darrick Herwehe

Reputation: 3752

They are under the reference section. Here is a current listing of supported variables:

$file_path - The directory of the current file, e.g., C:\Files.

$file - The full path to the current file, e.g., C:\Files\Chapter1.txt.

$file_name - The name portion of the current file, e.g., Chapter1.txt.

$file_extension - The extension portion of the current file, e.g., txt.

$file_base_name - The name-only portion of the current file, e.g., Document.

$packages - The full path to the Packages folder.

$project - The full path to the current project file.

$project_path - The directory of the current project file.

$project_name - The name portion of the current project file.

$project_extension - The extension portion of the current project file.

$project_base_name - The name-only portion of the current project file.

Upvotes: 1

Related Questions