My application is a "self-contained" ruby app.
It downloads images from the web.
When I run it, the files are created at the root app folder.
I created a InnoSetup installer. Installer works as expected, installing at Program Files. When I run the app, it creates files at C:\Users\myuser\AppData\Local\VirtualStore\Program Files\MyApp instead of the root app data.
How can I keep creating the files at my app folder, instead of AppData? Why does this occur? Couldn't find any info.
Related
I have an electron app that I want my users to be able to install. However, a dependency of this app is a C++ package that I have compressed in a .zip file. I need the user to unzip this file and put it into a certain directory under Program Files (target platform is windows). Is it possible to create an installer that both installs the electron app and contains a payload that it can unzip and put into that directory?
Yes, this is possible. An Electron app is just a bunch of files that you can package however you want. A great tool for packaging Electron apps is electron-builder
electron-builder uses NSIS by default to build Windows setups. It also provides a way to customize the NSIS script
If you want to include additional resources for use during installation, such as scripts or additional installers, you can place them in the build directory and include them with File. For example, to include and run extramsi.msi during installation, place it in the build directory and use the following:
!macro customInstall
File /oname=$PLUGINSDIR\extramsi.msi "${BUILD_RESOURCES_DIR}\extramsi.msi"
ExecWait '"msiexec" /i "$PLUGINSDIR\extramsi.msi" /passive'
!macroend
In your case, instead of extramsi.msi, you'll probably want to include 7zip standalone console version and your additional .zip file. You can use this custom script to extract this file to wherever you want
So I have recently developed an app for the windows store, I packaged it into an APPX package. The problem is that windows auto installs it into a non-accessible folder meaning I cannot reference .exe and .pdf files.
Is there a way to make it always install 2 files in the same place, for example the two files which need to be edited install on desktop and the rest of the app in the usual install location?
Can I do this using two separate .APPX files?
No, all APPX/MSIX packages are installed/extracted under the ProgramFiles/WindowsApps folder.
This folder is read-only, only the OS can write in there (when it's installing the app).
The solution is to copy the files you want from the install folder, the first time a user launches your application.
Using Advanced Installer. When I build and run my install project, after the install there is a folder called MyCompany (equivalent to [Manufacturer]) located within the ApplicationData folder (which resolves to C:\Users\Joey\AppData\Roaming\ on my system).
Within that particular folder is another folder called MyProgram 1.0.0 (equivalent to [ProductName] [ProductVersion].
And within that folder is another folder called install. And within that folder is a file called setup.msi with a size of 1.17MB
I have no understanding of why this file and these folders are being created. Further, after I uninstall my app, they get left behind on the system, which means my app is creating garbage.
Can someone please explain why this is happening? And also...if I can't cause this to not be present in the file system while my app is installed, how can I avoid leaving it behind on the file system after I uninstall?
Thanks.
When you are building an EXE setup file, that is the default extraction folder for the EXE, where you can find all the resources during the installation. You can change it from Media page, "Extraction folder".
It is not deleted after uninstall due a bug in Advanced Installer, you can find more details and a workaround on the forums.
I am trying to install gems in a Ruby Mac OSX app. I have:
export GEM_HOME=/usr/local/...
However this requires sudo access which I'm trying to avoid. Where do you install it so it installs inside the directory of the app? In the Resources folder or somewhere else?
Applications are usually expected not to modify their own bundle (their application directory). Unless you are planning to ship these gems as part of your app you should probably create a gem home for them in your application's "Application Support" directory.
See https://developer.apple.com/library/mac/documentation/General/Conceptual/MOSXAppProgrammingGuide/AppRuntime/AppRuntime.html#//apple_ref/doc/uid/TP40010543-CH2-SW9
The Application Support directory is where your app stores any type of file that supports the app but is not required for the app to run, such as document templates or configuration files. The files should be app-specific but should never store user data. This directory is located inside the Library directory.
Never store files at the top level of this directory: Always put them in a subdirectory named for your app or company.
If the resources apply to all users on the system, such as document templates, place them in /Library/Application Support. To get the path to this directory use the NSApplicationSupportDirectory search path key with the NSLocalDomainMask domain. If the resources are user-specific, such as workspace configuration files, place them in the current user’s ~/Library/Application Support directory. To get the path to this directory use the NSApplicationSupportDirectory search path key with the NSUserDomainMask domain.
I have created my first XE2 FM HD application.
I have my OSX machine connected and running debug builds on OSX works fine, but I don't have a way to create a release version and copy it to another computer.
I tried just copying over the Package made by the debug but that's missing files.
Inside XE2 I went to Project -> Deployment.
For the OSX Debug deployment I have a green button, but under OSX Release deployment I don't.
Clues?
Here's step-by-step instructions for building the App bundle and putting in the required dynamic link library:
Create a folder called MyApp.app
Create a subfolder in Myapp.app called Contents
Create a subfolder in Contents called MacOS
Create a subfolder in Contents called Resources
From your build, copy Info.plist into Contents
From your build, copy the Mac binary to MacOS
From your build, copy the icon to Resources
Copy libcgunwind.1.0.dylib to MacOS
Copy the .app folder to your Mac and double-click it to run
You will find libcunwind.1.0.dylib on your Mac where you installed the platform assistant, most likely:
/Users/username/Applications/Embarcadero/PAServer/
Here's a video tutorial on how to create the manual install Disk Image installer on the Mac.