Skip to main content

Questions tagged [powershell]

Apply this tag to questions related to any version of PowerShell.

Filter by
Sorted by
Tagged with
1 vote
1 answer
232 views

Azure Automation is a service for running scripts in the cloud, intended for the automation of administration tasks. While using it, I came across strangely outdated technologies being used under the ...
Palec's user avatar
  • 125
2 votes
1 answer
227 views

I recently wrote a small PowerShell script to clean a Visual Studio solution. It's used by a small team of 5 persons on a regular basis. I built it in PowershellISE (GUI client) and it works great, ...
David's user avatar
  • 313
3 votes
1 answer
1k views

To improve my command lines scripts, I want to add some optional console output, mainly for logging purposes. In my PowerShell modules, I use Write-Verbose for this (but it should be clear this isn't ...
Alex_P's user avatar
  • 171
0 votes
1 answer
181 views

I come from a Java background, but now I'm supporting a PowerShell code base. In the PowerShell code base there are multiple modules that were written against a certain Azure environment. Now, we ...
The Gilbert Arenas Dagger's user avatar
3 votes
0 answers
727 views

Currently, in my PowerShell scripts I am using [ValidateSet()] in my functions in order to limit the options for user input. Now I discovered the Enum as an alternative. I have read a couple of blogs ...
Alex_P's user avatar
  • 171
4 votes
1 answer
352 views

I run on a daily basis a set of VBA-rich Excel files. Most of them include MS Office application cross-talk, but also employ third-party applications and MySQL. Due to the fact of running those files ...
Oskar_U's user avatar
  • 151
2 votes
2 answers
607 views

We are automating the testing on an Web ERP solution (Dynamics) through a tool (RSAT, which uses selenium) provided by the developer of the ERP (Microsoft). The RSAT has a list of instructions to do ...
Maxime's user avatar
  • 153
2 votes
1 answer
1k views

To make an installation of opensource software for the Windows platform single click, I am trying to convert the setup.ps1 into a setup.exe file. (To make a powershell script executable in a single (...
a.t.'s user avatar
  • 225
2 votes
1 answer
189 views

Default display of objects in the Windows PowerShell console In PowerShell you have format.ps1xml documents. These are used to simplify what and how object data is shown to the end user. A simple ...
Matt's user avatar
  • 129
0 votes
0 answers
67 views

I have a C# cmdlet(1) that uses "ConfigurationManager.AppSettings" to get database connection strings necessary for some stored procedures used in the cmdlet(1). If another application instantiates an ...
Rayshawn's user avatar
  • 279
7 votes
2 answers
18k views

Is there a preferred practice around initialising variables which are first defined within a branch of code, or is this purely subjective / personal preference? i.e. there are multiple ways this can ...
JohnLBevan's user avatar
1 vote
0 answers
108 views

I am trying to do a nightly package integration with one of our projects that consumes 6 other internal teams’ -PreRelease packages. Background Info We have our own internal ProGet Server that ...
Flightdeck73's user avatar
-1 votes
1 answer
404 views

After almost 2 years learning how to code (in Powershell) and some help at Stackoverflow from time to time, I'm now finally on my way to release my first GUI project. I intend to release the compiled ...
StUffz's user avatar
  • 9
1 vote
1 answer
314 views

This is one of my functions I have in a module: Function Get-DatabaseUser { [CmdletBinding()] Param() Write-Verbose 'Getting database...' $Database = Get-Database Write-Debug('...
Jake's user avatar
  • 163
0 votes
1 answer
222 views

At home I use Linux and have for more than a decade. At work we use Windows and so I find PowerShell more familiar. I am a Linux/Unix fanboy at heart, but I've had greater success grokking the ...
M. Lanza's user avatar
  • 1,738
5 votes
1 answer
219 views

Pash is an open source reimplementation of Windows PowerShell. It was released in 2008, and has been idle since then. I would like to take up the mantle. It's not clear what the license is. There is ...
Jay Bazuzi's user avatar
  • 1,604
0 votes
1 answer
4k views

How to using multiple files in Powershell to ensure modularity? function.ps1 could have all the utility functions? command1.ps1 could have calls related to a command?
Nida Sahar's user avatar
20 votes
4 answers
4k views

Are there any well-defined conventions when programming in PowerShell? For example, in scripts which are to be maintained long-term, do we need to: Use the real cmdlet name or alias? Specify the ...
Tahir Hassan's user avatar