It’s demoralizing. I’ve been avoiding this for a week, and I can’t start.
Libraries as a thing is something that has to be fixed. It doesn’t work. You can’t have an open source universe built on this unreliable nonsense where files are everywhere.
It is entirely possible that the github repo is in an incompatible format. I don’t know as you have not shown us theplatformio.ini file, nor mentioned whch board etc.
You will find a number of libraries for different platforms. Pick the one for you, possibly this one:
There are instructions on installing.
I recommend always searching for a library that is known to PlatformIO, rather than randomly picking one off github. There’s usually plenty available with examples and/or instructions etc.
I’m wondering why you are using the github link when the BME280 library is available to install. Add adafruit/Adafruit BME280 Library to your lib_deps.
In general, compiler supplied headers, or those that are subsequently installed into the system location, use <> while your own, or others in this project location, ie, lib_deps and/or pio lib install, use "".
Run a clean from VSCode. That should get rid. If not, just delete the .pio folder in the project, then build again. However, even though the removed libraries are present, they are not used by the code, so will not be linked to the final executable.
Libraries are compiled once and reused, unless you change the library source files. So only the first compile will build new libraries but you need a clean to get rid of removed libraries.