Commit 7be8ee4
do not discover projects in buck-out
Summary:
A buck project puts its artefacts into a directory called `buck-out`, with a hash as part of the file name. When buck is used to generate `.erl` or `.hrl` files, they will end up there.
This means we have no way of knowing what project a given file in `buck-out` belongs to.
When we do load the owning project, it explicitly enumerates all the files belonging to the project in the `applicable_files` part of the `AppData`, and we can then correctly process files in `buck-out`.
The ELP LSP project discovery process starts at the given open file in the IDE, and keeps looking in parent directories until it finds something that identifies an erlang project, such as a `.elp.toml` file. Even if we have one at the root of the repo, `buck-out` is shared across all projects within the repo, so we do not necessarily know which one the file belongs to.
To prevent loading a fallback project and then not correctly reesolving the file in its correct project when it is opened, we do not initiate project discovery on files withing the `buck-out` directory.
Reviewed By: TD5, TheGeorge
Differential Revision: D85577495
fbshipit-source-id: 58e1ad4ab25e1278493ac4a620119ece6d8971e81 parent ed59eb5 commit 7be8ee4
1 file changed
+5
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1808 | 1808 | | |
1809 | 1809 | | |
1810 | 1810 | | |
| 1811 | + | |
| 1812 | + | |
| 1813 | + | |
| 1814 | + | |
| 1815 | + | |
1811 | 1816 | | |
1812 | 1817 | | |
1813 | 1818 | | |
| |||
0 commit comments