vscode-codeql icon indicating copy to clipboard operation
vscode-codeql copied to clipboard

Allow unzipped source archives

Open aeisenberg opened this issue 3 years ago • 1 comments

Background

This feature request is about allowing unzipped database source archives in addition to zipped source archives. Historically, we allowed unzipped archives, but it was challenging to maintain multiple ways of interacting with sources as we grew the number of features that the extension supported. Also, users would sometimes inadvertently edit the unzipped sources and sometimes even expect that the database would be transparently updated to handle the new sources.

Previously, we had allowed unzipped database sources to be imported as regular folders into the project. This would signal to users that they could edit the sources, which should not be possible.

Proposal

Currently, we have created the archive-filesystem-provider, which displays the contents of zip files in the file explorer in read-only mode.

I think we should be able to extend archive-filesystem-provider so that there are two variants: one variant is backed by a zip file and the other is backed by a regular file system directory. Of course, this would mean that the name archive-filesystem-provider is no longer really appropriate, but that is a minor issue.

The benefit is that we can read in the source folder of a database and ensure that even though the file explorer points to regular files, everything is read-only. And we will also be able to interact with both kinds of filesystems through the same API even though they are differently implemented.

aeisenberg avatar Apr 28 '22 16:04 aeisenberg

Relates to #393 (because test projects have unzipped source archives)

Marcono1234 avatar Oct 06 '23 23:10 Marcono1234