Cannot choose my MSI script location?

This forum can be browsed by the general public. Posting is limited to current SAPIEN license holders with active maintenance and does not offer a response time guarantee.
Forum rules
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 6 years and 1 week old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
User avatar
michaelbain
Posts: 3
Last visit: Fri Feb 01, 2019 3:21 pm

Cannot choose my MSI script location?

Post by michaelbain »

Product, version and build: Powershell Studio 2018 v5.5.149
32 or 64 bit version of product: 64-bit
Operating system: Windows 10
32 or 64 bit OS: 64-bit

Dear Sapien,

Why (oh why) cannot I not customise my install location of scripts when installed from an MSI on a machine?
It appears to be hard-coded into the software that all scripts will go to c:\%program files%\<companyname>\<script name>. Why am I not allowed to choose?
At the very least, I would like all scripts to follow the pattern of Windows Powershell's native "install-script" cmdlet, and install them to the c:\%program files%\WindowsPowershell\Scripts folder.
I don't understand why this isn't the case - particularly since this appears to be the behaviour when installing MSI 'module' installers from the Powershell Studio - why make scripts different?
If I am not missing something glaringly obvious in the available installer settings, then this is an extremely poor design decision by Sapien in my opinion.

Please do explain..
User avatar
Alexander Riedel
Posts: 8488
Last visit: Tue Apr 16, 2024 8:42 am
Answers: 20
Been upvoted: 37 times

Re: Cannot choose my MSI script location?

Post by Alexander Riedel »

There is not much to explain or understand. It follows an established pattern virtually all software products follow. It is prescribed Microsoft standard to build install paths that way. Never mind PowerShell going against established practices more often than not, it simply is that way because it works and nobody wanted to change it so far.
Modules are an entirely different animal, since they have to follow PowerShell's search path behavior, otherwise they won't work.
The best way to affect change is usually to make feature request. We even have a special place for that: https://www.sapien.com/requests
Be constructive and detail what you need and why. In this instance, knowing why you care where things get installed outside of established patterns is of interest.
I would like to point out though, that bunching all scripts from various applications and vendors into one central script folder might not be the best practice, since there are bound to be naming collisions.
Alexander Riedel
SAPIEN Technologies, Inc.
User avatar
michaelbain
Posts: 3
Last visit: Fri Feb 01, 2019 3:21 pm

Re: Cannot choose my MSI script location?

Post by michaelbain »

"Modules are an entirely different animal, since they have to follow PowerShell's search path behavior, otherwise they won't work." - In Powershell I can edit the $psmodulepath variable to include a bespoke location, thereby allowing "get-module" to find it. There is no such capability, however, using "get-installedscript", that I'm aware of. Thus, in hardcoding the installation path, I am losing out in functionality.

And, following on from that last point, telling me that "Never mind PowerShell going against established practices more often than not, it simply is that way because it works and nobody wanted to change it so far", is not very helpful at all. This product - Powershell Studio - as it's aptly named, is designed to support and enhance the Windows Powershell product, and thus, I would expect should be tailored with Powershell's design practices in mind, rather than using it's own rigid, hardcoded methods which the user can not cusomtise to suit theirs or Microsoft's practices.

"It follows an established pattern virtually all software products follow" - Could you also give me an example of such products? I would say this is incorrect; I'f i'm installing an application of any sort, which would normally, by default, look to install in the %program files% directory, I am at least presented with the ability during installation to change that path. There is no such option here. Furthermore, since what we're talking about here are scripts, and not so much "applications", this should give even more reason to allow customisation of the installation path.

I will do as you say by filing a feature request, and will do so constructively.
This topic is 6 years and 1 week old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.