summaryrefslogtreecommitdiff
path: root/docs/markdown
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2023-08-17 23:56:51 -0400
committerEli Schwartz <eschwartz@archlinux.org>2023-08-17 23:56:51 -0400
commit84c8905d527893bedc673e8a036b8b2ec89368b4 (patch)
treeffe8f20e45a5d6fdcc19927ae237c1bea2d769e0 /docs/markdown
parent1fd70a2a004900b7d97d9fc560e87d33266ecfed (diff)
downloadmeson-84c8905d527893bedc673e8a036b8b2ec89368b4.tar.gz
Revert "Add fs.relative_to()"
This reverts commit f52bcaa27fc125ab9ae583af466ba99c164169f3. It did not pass CI, and was merged anyway because there were two CI errors in the same cygwin job. The other error was not the fault of this commit, and since cygwin errors were glossed over because they were "expected", the presence of a new error *added* by this commit was overlooked. Per the meson development policy, PRs which result in CI errors can/should be reverted at will, no questions asked.
Diffstat (limited to 'docs/markdown')
-rw-r--r--docs/markdown/Fs-module.md14
-rw-r--r--docs/markdown/snippets/fs_relative_to.md17
2 files changed, 0 insertions, 31 deletions
diff --git a/docs/markdown/Fs-module.md b/docs/markdown/Fs-module.md
index f136bb904..cc67355b5 100644
--- a/docs/markdown/Fs-module.md
+++ b/docs/markdown/Fs-module.md
@@ -224,20 +224,6 @@ fs.stem('foo/bar/baz.dll.a') # baz.dll
project. If the file specified by `path` is a `files()` object it
cannot refer to a built file.
-### relative_to
-
-*Since 1.3.0*
-
-Return a relative filepath. In the event a relative path could not be found, the
-absolute path of `to` is returned. Relative path arguments will be assumed to be
-relative to `meson.current_source_dir()`.
-
-Has the following positional arguments:
- - to `str | file | custom_tgt | custom_idx | tgt`: end path
- - from `str | file | custom_tgt | custom_idx | tgt`: start path
-
-returns:
- - a string
### copyfile
diff --git a/docs/markdown/snippets/fs_relative_to.md b/docs/markdown/snippets/fs_relative_to.md
deleted file mode 100644
index 82e6a4268..000000000
--- a/docs/markdown/snippets/fs_relative_to.md
+++ /dev/null
@@ -1,17 +0,0 @@
-## `fs.relative_to()`
-
-The `fs` module now has a `relative_to` method. The method will return the
-relative path from argument one to argument two, if one exists. Otherwise, the
-absolute path to argument one is returned.
-
-```meson
-assert(fs.relative_to('c:\\prefix\\lib', 'c:\\prefix\\bin') == '..\\lib')
-assert(fs.relative_to('c:\\proj1\\foo', 'd:\\proj1\\bar') == 'c:\\proj1\\foo')
-assert(fs.relative_to('prefix\\lib\\foo', 'prefix') == 'lib\\foo')
-
-assert(fs.relative_to('/prefix/lib', '/prefix/bin') == '../lib')
-assert(fs.relative_to('prefix/lib/foo', 'prefix') == 'lib/foo')
-```
-
-In addition to strings, it can handle files, custom targets, custom target
-indices, and build targets.