【发布时间】:2013-11-25 14:35:34
【问题描述】:
我需要使用 Sitecore Powershell 脚本序列化一些项目。
我需要:
- 序列化项目
- 在文件系统(
C:/serialisation/1)中创建一个文件夹,并将序列化文件夹中的结果移动到该文件夹中
有人能写出 powershell 脚本的样子吗?还可以提供有关使用 Powershell 进行序列化的资源的链接。
【问题讨论】:
标签: powershell serialization sitecore
我需要使用 Sitecore Powershell 脚本序列化一些项目。
我需要:
C:/serialisation/1)中创建一个文件夹,并将序列化文件夹中的结果移动到该文件夹中有人能写出 powershell 脚本的样子吗?还可以提供有关使用 Powershell 进行序列化的资源的链接。
【问题讨论】:
标签: powershell serialization sitecore
我想你知道Sitecore Powershell Extensions。
项目的序列化:
# Serialization
Get-Item -Path "master:\templates\spe\" | Serialize-Item -Recurse
复制文件:
#copy
Copy-Item -Path C:\fso\20110314.log -Destination c:\fsox\mylog.log
您可以在video Sitecore PowerShell Extensions - Packages and Serialization 中找到解释。
这是一篇解释serialization and deserialization with Sitecore Powershell Extensions的博文。
【讨论】:
您可以使用 Export-CLIXML 序列化 Powershell 对象。
运行 Get-Help Export-CLIXML -full 以获取更多信息。
【讨论】: