Count Files Inside NSIS - nsis

I have a NSIS executable files and I just want to list the numbers of files inside each of the files.
Is there any way on how to determine the count of files inside the setup.exe or NSIS files without extracting it?

NSIS itself does not support this.
7-zip is able to understand most NSIS installers and you can use their command line tool to get a file listing.

Related

Add file after generating the installer executable

I would if we can add some files(text or executable) to a NSIS installer with a tool(or not) after the package is done.
Thank you for your help
You cannot really append extra files after the compiler has finished. You can however append a small text string if you need to embed some sort of id/hash/serial number. This data can be read with the ReadCustomerData function from the NSIS wiki.
You can compile installers on Windows and POSIX based systems so you can build installers anywhere if you absolutely need to add a file that does not exist on your system...

How to make own language file in NSIS?

I want to make my own language file for my installer. I want to make my installer which will support two languages "English" and "Hindi". But there is no language file for hindi. So I want to make my own language file for hindi. Can anyone tell me how to make it and how to link it with NSIS? And what is ".nlf" files e.g "English.nlf" present in the NSIS Contrib folder?
The .nlf files inside Contrib\Language files are storing all default dialogs used by NSIS. The .nsh files in the same folder are used by installers with Modern UI. I'd clone the files for English translation (or any other language you prefer as starting point) and change all the strings inside.
For your convenience, there are packages available for Sublime Text and Atom, that let you jump between each translation field.
As suggested by idleberg, you just copy one of the .nlf and .nsh files and translate the strings but you are in luck, the NSIS fork already has a almost complete translation.

Create a setup.exe file without any dependent files

I am a first time user of this group and so pardon me for any mistakes and unclear statements.
What I am trying to do is to create single setup.exe (not msi) using installshield. But when I build the project what I get is other files along with the .exe file for e.g. .cab, .hdr, .inx and other such files.
I am using the options under Release -> Release Wizard -> General options-> Checked the "Create a single file executable" & "Compress compiled script" options but still I get the extra files along with the setup.exe file. I want a setup.exe file to be created independent of the other local files.
So could anyone suggest me how to achieve that.
Any help will be appriciated.
Thanks.
As Michael Urman wrote, you will find the one file in adjacent folder.
The folder name is "Package".
Those files are always created for InstallScript projects. When you build a single file executable, the single file version that packages it all together is available in an adjacent folder.

How to check if file locked/used by other process NSIS

Hi I am writing nsis script for a patch installer. Before installer copies new files I need to check if any process is using the files I want to replace and I want rename those files to tmp and delete them on reboot.
Is there any way installer can detect that if any process is using those files (in my case the files I am going to install are dlls).
There is no native way in NSIS how to do this. But there are third party tools which can detect dlls used by certain process - maybe you could use them in your installer.
But my question is: Do you really need to detect this?
What about deleting files directly with Delete /REBOOTOK file command? (http://nsis.sourceforge.net/Docs/Chapter4.html#4.9.4.11)
If /REBOOTOK is specified and the file cannot be deleted then the file is deleted when the system reboots.

is it possible to tell NSIS to setof files listed in a config file?

I have to download different files from a location on the network, http, but the file names versions I want to supply in a configuration file. is this possible ?
You can read from files with the NSIS ini instructions, manual parsing with FileRead or use one of the helper macros.
You can download files with the INetC plugin...

Resources