diff options
| author | Daniel Mensinger <daniel@mensinger-ka.de> | 2021-08-21 16:27:56 +0200 |
|---|---|---|
| committer | Daniel Mensinger <daniel@mensinger-ka.de> | 2021-10-03 11:46:34 +0200 |
| commit | 2b482e39a90fa1929e0fa4006861f4264f28adb2 (patch) | |
| tree | 0af5ef229d25bef1b974445406fc3c9d28c0756f /docs/yaml/functions/join_paths.yaml | |
| parent | ad65a699f93a7659739287882ca27c58c564670b (diff) | |
| download | meson-2b482e39a90fa1929e0fa4006861f4264f28adb2.tar.gz | |
docs: Add the YAML Reference manual
Diffstat (limited to 'docs/yaml/functions/join_paths.yaml')
| -rw-r--r-- | docs/yaml/functions/join_paths.yaml | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/docs/yaml/functions/join_paths.yaml b/docs/yaml/functions/join_paths.yaml new file mode 100644 index 000000000..f0cef0c7d --- /dev/null +++ b/docs/yaml/functions/join_paths.yaml @@ -0,0 +1,26 @@ +name: join_paths +returns: str +since: 0.36.0 +description: | + Joins the given strings into a file system path segment. For example + `join_paths('foo', 'bar')` results in `foo/bar`. If any one of the + individual segments is an absolute path, all segments before it are + dropped. That means that `join_paths('foo', '/bar')` returns `/bar`. + + *(since 0.49.0)* Using the `/` operator on strings is equivalent to calling + [[join_paths]]. + + ```meson + # res1 and res2 will have identical values + res1 = join_paths(foo, bar) + res2 = foo / bar + ``` + +warnings: + - Don't use [[join_paths]] for sources in [[library]] and [[executable]]. You should use [[files]] instead. + +varargs: + name: part + type: str + description: The path parts to join. + min_varargs: 1 |
