The type
command in Cmd shell supports typing multiple files at the same time. File names are just space separated. In Powershell, type
is an alias for Get-Content
. It supports multiple source files, but doesn't use space separation. An array is needed, as specified by the -Path
parameter that supports a String array:
man type
Get-Content [-Path] <string[]> [-Credential <PSCredential>] ...
Try passing the cmdlet an array of file names. Like so,
type @("My.js", "MyLogon.js", "MyMenu.js") | uglifyjs -o files.min.js