[Gambas-user] /!\ WARNING ! /!\ File compression in the IDE

Benoît Minisini g4mba5 at gmail.com
Fri Feb 14 13:42:28 CET 2020


Hi,

This mail is a warning about a recent change in the IDE about file 
compression.

Before that change, you had the ability to "compress" js, css and html 
files with two buttons : one for compress the file, one for uncompress it.

Here, "compress" means rewriting the file in a more compact way to speed 
the download and the interpretation of the file a bit (or to obfuscate 
it). By the way I should have named it "compact" instead of "compress".

Once compressed, the uncompressed file was stored in the 
".hidden/Uncompressed" project directory.

Now the compression is more transparent.

- You have only one button, that toggles between compression and no 
compression.

- The uncompressed file is stored in ".hidden/.uncompressed" instead. 
You don't see it anymore in the project tree.

- When you edit a compressed file in the IDE, you always see the 
uncompress contents. If you save the file, the compressed and 
uncompressed versions are updated accordingly.

- To be backward-compatible, if you open a project using the old 
compression mode, the file in ".hidden/Uncompressed" is opened instead. 
The first time you save the file, the uncompressed version is stored in 
".hidden/.uncompressed", and the file stored in ".hidden/Uncompressed" 
is deleted.

/!\ **** WARNING! **** /!\

Consequently, if you have compressed a file, uncompress it, and modified 
it, you may lose these modifications, as the uncompressed version stored 
in ".hidden/Uncompressed" will be used, unless its modification time is 
1 minute lower than the modification time of the normal file.

If someone find a better way to distinguish between the uncompressed 
version stored in ".hidden/Uncompressed" and the uncompressed version 
currently at its normal location (because modification time is not 
reliable, if, for example, you play with 'git'), he is welcome to share it!

Regards,

-- 
Benoît Minisini


More information about the User mailing list