<commit_before>param($rootPath, $toolsPath, $package, $project)

function Get-ScriptDirectory {
	$Invoc = (Get-Variable MyInvocation -Scope 1).Value
	Split-Path $Invoc.MyCommand.Path
}

function get-content-path($contentRoot) {
	$moniker = $project.Properties.Item("TargetFrameworkMoniker").Value
	$frameworkname = new-object System.Runtime.Versioning.FrameworkName($moniker)

	$id = $frameworkname.Identifier

	if($id -eq ".NETFramework") { $relative = "NET40" }
	elseif($id -eq "Silverlight" -and $frameworkname.Profile -eq "WindowsPhone") { $relative = "SL40-WP" }
	elseif($id -eq "Silverlight" ) { $relative = "SL40" }
 
	[System.IO.Path]::Combine($contentRoot, $relative)
}
 
$contentSource = get-content-path ($rootPath + "\tools")
$defaultNamespace = $project.Properties.Item("DefaultNamespace").Value

ls $contentSource | foreach-object { 
	$content = [System.IO.File]::ReadAllText($_.FullName)
	$content = $content.Replace('$safeprojectname$', $defaultNamespace)
	$content | out-file $_.FullName
	$project.ProjectItems.AddFromFileCopy($_.FullName)
}

write-host "Added Bootstrapper and Shell.  You will want to update the your App.xaml as described here: http://caliburnmicro.codeplex.com/wikipage?title=Basic%20Configuration%2c%20Actions%20and%20Conventions&referringTitle=Documentation"
 
# WPF4 will be NETFramework,Version=v4.0,Profile=Client 
# SL4 will be Silverlight,Version=v4.0 
# WP7 will be Silverlight,Version=v4.0,Profile=WindowsPhone<commit_msg>Removing some vestigial code from the nuget install script.<commit_after>param($rootPath, $toolsPath, $package, $project)

function get-content-path($contentRoot) {
	$moniker = $project.Properties.Item("TargetFrameworkMoniker").Value
	$frameworkname = new-object System.Runtime.Versioning.FrameworkName($moniker)

	$id = $frameworkname.Identifier

	if($id -eq ".NETFramework") { $relative = "NET40" }
	elseif($id -eq "Silverlight" -and $frameworkname.Profile -eq "WindowsPhone") { $relative = "SL40-WP" }
	elseif($id -eq "Silverlight" ) { $relative = "SL40" }
 
	[System.IO.Path]::Combine($contentRoot, $relative)
}
 
$contentSource = get-content-path($rootPath + "\tools")
$defaultNamespace = $project.Properties.Item("DefaultNamespace").Value

ls $contentSource | foreach-object { 
	$content = [System.IO.File]::ReadAllText($_.FullName)
	$content = $content.Replace('$safeprojectname$', $defaultNamespace)
	$content | out-file $_.FullName
	$project.ProjectItems.AddFromFileCopy($_.FullName)
}

write-host "Added Bootstrapper and Shell.  You will want to update the your App.xaml as described here: http://caliburnmicro.codeplex.com/wikipage?title=Basic%20Configuration%2c%20Actions%20and%20Conventions&referringTitle=Documentation"
{'fraction_non_alphanumeric': 0.14476119955572012, 'fraction_numerical': 0.014809329877823029, 'mean_word_length': 6.322493224932249, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7035371', 'n_tokens_mistral': 896, 'n_tokens_neox': 863, 'n_words': 165}