powershell是否有在自动开始新行之前输出的默认行长度?我在我的输出文件中看到了额外的CRLF,它们不应该出现在这里(即.输入文件是csv文件,每行的末尾是crlf,但在执行-pattern之后,结果文件会将每行拆分为多行,并且每行看起来都是相同的最大大小)。
发布于 2013-09-03 22:34:05
在我的powershell配置文件中(将500替换为适合您的内容):
# Dynamically change the host buffer width because some cmdlets specifically
# rely on it and truncate information that exceeds the initial limit (80 characters).
if ($Host -and $Host.UI -and $Host.UI.RawUI)
{
$rawUI = $Host.UI.RawUI
$oldSize = $rawUI.BufferSize
$typeName = $oldSize.GetType().FullName
$newSize = New-Object $typeName (500, $oldSize.Height)
$rawUI.BufferSize = $newSize
}https://stackoverflow.com/questions/18594857
复制相似问题