Questions tagged [pscx]

The PowerShell Community Extensions (PSCX) is an open source PowerShell module.

Description of PSCX

PSCX is an acronym for the PowerShell Community Extensions which is an open source PowerShell module project. The latest version is 3.3.2. The extension provides a wide variety of generic CmdLets e.g.:

  • Out-Clipboard
  • Get-FileTail (tail)
  • Set-FileTime (touch)
  • Invoke-BatchFile - to execute *.bat and *.cmd files.
  • Unblock-File
  • Format-Hex
  • Format-Xml
  • Test-Xml
  • Test-Assembly
  • Write-Zip
  • Read-Archive
  • Expand-Archive
  • etc.

Resources

23 questions
3
votes
1 answer

Install PSCX with PowerShell

I want to install the PowerShell Community Extensions using only the command-line. I don't want to use a UI, no right-click extract, double-clicking an MSI file. I have to do this process on dozens of computers. However, all of the instructions I've…
Gates VP
  • 44,957
  • 11
  • 105
  • 108
3
votes
0 answers

Appending files and folders with PSCX Write-Zip does not respect folder structure

I just downloaded the latest version of the PowerShell Community Extensions and I'm struggling to append files and folders to an existing zip file. I'm running the PowerShell ISE to test the command, and I'm currently in my profile folder. Here is…
julealgon
  • 7,072
  • 3
  • 32
  • 77
3
votes
2 answers

How can I make PowerShell run the original Start-Process cmdlet rather than the PSCX Start-Process cmdlet?

I have PowerShell v2.0 installed and on top of that, PSCX is installed. PSCX is the PowerShell Community Extensions (http://pscx.codeplex.com/Wikipage). It seems that I have two cmdlets called Start-Process installed and I'm guessing one is the…
urig
  • 16,016
  • 26
  • 115
  • 184
3
votes
1 answer

Can I use New-Symlink on UNC paths?

I am trying to create a symlink to a file on Windows using PowerShell. I am using the New-Symlink cmdlet from the PowerShell Community Extensions. After struggling to figure out the syntax of New-Symlink I was able to get it to work correctly on my…
Kris Harper
  • 5,672
  • 8
  • 51
  • 96
1
vote
1 answer

How can I exclude certain file types when using Powershell and the PSCX Write-Zip cmdlet?

How can I exclude certain file types when using Powershell and the PSCX Write-Zip cmdlet? Right now I'm using this: Write-Zip -Path "C:\Program Files (x86)\Folder" -OutputPath "C:\newDeploy\backup\Folder.zip" -IncludeEmptyDirectories -NoClobber…
user1161625
  • 642
  • 1
  • 8
  • 13
1
vote
1 answer

Searching zipped folders

Is it possible to search zipped folders for a specific file name like this? gci $pathContainingZippedFolders -rec | ?{$_ -like "filename"} or gci $pathContainingZippedFolders -rec | ?{$_ -match "filename"} Edit: I forgot to include that I was not…
Animesh
  • 4,926
  • 14
  • 68
  • 110
1
vote
2 answers

PowerShell Pscx Expand-Archive method failure detection

PowerShell snippet: Import-Module Pscx Expand-Archive ConsoleApplication1.zip ./ Write-Host $? Write-Host $LastExitCode Neither $? nor $LastExitCode report about error. But there is error, because file ConsoleApplication1.exe is locked (i started…
Roman
  • 4,531
  • 10
  • 40
  • 69
1
vote
1 answer

How to call an overloaded command in PowerShell

My PowerShell environment has two Expand-Archive commands: Windows 10 -> a function from Microsoft.PowerShell.Archive (1.0.1.0) PowerShell Community Extension -> a CmdLet from Pscx (3.2.2) My current environment defaults to the CmdLet from…
Paebbels
  • 15,573
  • 13
  • 70
  • 139
1
vote
1 answer

Can I include a folder relative to the current directory in PATH in Powershell?

I run a lot of node projects and often have binaries located in: .\node_modules\.bin ...relative to the projects folder. I'd like to be able to have PATH always include these directories, if they exist. I don't want to include other directories,…
mikemaccana
  • 110,530
  • 99
  • 389
  • 494
1
vote
1 answer

PowerShell Write-Zip not preserving directory structure

I'm trying to create one Zip-file which contains everything in that directory (files & folders) and that preserves the directory structure. By looking around on the net I see that lots of people have issues with this. So to make it easy on myself I…
DarkLite1
  • 13,637
  • 40
  • 117
  • 214
1
vote
1 answer

Powershell Write-Zip Partial Folder Tree

I have a folder structure that looks like this: -Daily Logs -Script1Logs -AnotherScriptLogs -ThirdScriptLogs I would like to zip all the folders underneath "Daily Logs" and retain the same folder structure. Is there a way to zip the folders…
mack
  • 2,715
  • 8
  • 40
  • 68
0
votes
2 answers

Powershell PSCX Write-Zip is slow

Can anyone help me troubleshoot why this PSCX cmdlet 'Write-Zip' is so slow? It takes 1.5 hours when the DotNetZip library can ZIP the same folders in about 20 minutes. (The issue with the DotNetZip library is that it chokes with large files, so I…
user1161625
  • 642
  • 1
  • 8
  • 13
0
votes
0 answers

powershell expand-archive cmdlet - problem with unpack split zip files

I'm trying to unpack zip file which is in pieces (file.z01, file.z02, file.zip) I use expand-archive cmdlet from PSCX but i get an error PS C:\> expand-archive -format zip -path c:\temp\file.zip -outputpath c:\temp\ -showprogress error…
kate
  • 1
  • 1
  • 1
0
votes
0 answers

Loading pscx module fails with Error in TypeData

I'm getting the following error when I try to load the pscx PowerShell Module. Import-Module : The following error occurred while loading the extended type data file: Error in TypeData "System.TimeSpan": Type…
0
votes
1 answer

What is the syntax for converting XML to HTML using PSCX Convert-XML?

There is a commandlet in PSCX called Convert-XML that uses XSL to convert XML into HTML. I can't for the life of me figure out the syntax to get it to work. I know I need to feed it paths for the XML input, the XSLT style sheet, and the HTML…
convoke
  • 191
  • 11
1
2