private void WriteSaveSnapshot(IProjectConfiguration config)
{
var snapshot = config as ISaveSnapshot;
if (snapshot == null)
return;
using (CbTag("AppendToFile"))
{
Attr("file", snapshot.TempFileExcludeFromSnapshot());
Attr("text", "$tf");
}
using (CbTag("AppendToFile"))
{
Attr("file", snapshot.TempFileExcludeFromSnapshot());
Attr("text", "*.nupkg");
}
var source = config as ISourceDirectory;
if (source != null)
{
using (CbTag("CompressDirectoryExclude"))
{
Attr("path", source.SourceDirectory());
Attr("output", snapshot.SnapshotSourceFile());
Attr("exclude", snapshot.TempFileExcludeFromSnapshot());
}
AzureUpload(config, "snapshot", snapshot.SnapshotSourceFile());
}
var packages = config as IPackagesDirectory;
if (packages != null)
{
using (CbTag("CompressDirectoryExclude"))
{
Attr("path", packages.PackagesDirectory());
Attr("output", snapshot.SnapshotPackagesFile());
Attr("exclude", snapshot.TempFileExcludeFromSnapshot());
}
AzureUpload(config, "snapshot", snapshot.SnapshotPackagesFile());
}
}