Page 1 of 1
Temporary files created for publishing
Posted: Fri Dec 31, 2021 3:37 pm
by WWBman
I've just noticed that the temporary files created for publishing in
"C:\Users\...\AppData\Local\Temp\~publish\"
are not removed although the publish displays "Removing temporary files..." before it ends.
Is this intentional?
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 3:42 pm
by Pablo
Yes, this is intentional.
The files will be removed the next time publish.
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 3:45 pm
by WWBman
Is there a disadvantage in removing them immediately after publishing?
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 4:23 pm
by Pablo
Basically, publishing works the same as preview.
if the files were immediately removed then you would not be able to preview.
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 4:54 pm
by WWBman
Pablo wrote: ↑Fri Dec 31, 2021 4:23 pm
Basically, publishing works the same as preview.
if the files were immediately removed then you would not be able to preview.
I thought wwb generated the required files before each preview or publish.
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 5:57 pm
by Pablo
Correct.
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 6:18 pm
by alan_sh
WWBman wrote: ↑Fri Dec 31, 2021 4:54 pm
Pablo wrote: ↑Fri Dec 31, 2021 4:23 pm
Basically, publishing works the same as preview.
if the files were immediately removed then you would not be able to preview.
I thought wwb generated the required files before each preview or publish.
Let me see if I get this right. If you publish, WWB removes any old html code from the temp location, creates the new html code and then copies it to the correct location. It then exits. In Preview, it uses the same routines to create the code, passes the location to the browser and then exits.
So, if WWB was to delete the code after it exits the routine to create it, Preview wouldn't work (and probably, publish would fail too unless specific code was there to check what you'd asked it to do - preview or publish).
For me, this all works well, because sometimes I want to use a different browser to preview my work and I know the html code is in my temp folder waiting for me.
I hope this all makes sense and I haven't been over simplifying things.
Alan
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 6:24 pm
by Pablo
Correct!
Re: Temporary files created for publishing
Posted: Fri Dec 31, 2021 7:09 pm
by WWBman
I was going to leave this but.
You would normally do many Previews before Publishing so obviously you don't need to have Published to do a Preview.
I always specify my own Preview Folder in Options > Files and Folders but I don't think this is relevant.
This is how I thought it worked.
Preview always first deletes all files in the Preview Folder and then creates all the files necessary for the Preview.
Publish always first deletes all files in the Publish Folder (which in my case is different to the Preview Folder) and then creates all the files before Publishing them.
So, if WWB was to delete the code after it exits the routine to create it, Preview wouldn't work (and probably, publish would fail too unless specific code was there to check what you'd asked it to do - preview or publish).
Since WWB creates all files each time a Preview or Publish is done I don't think this would apply.
For me, this all works well, because sometimes I want to use a different browser to preview my work and I know the html code is in my temp folder waiting for me.
The same applies to this.
So the fact that WWB does the file creation each time is why I suggested the deletion afterwards.
I stand corrected if anything is not how it is.
Apologies for continuing this thread (I didn't intend to!).