Last change
on this file since 11316 was
9604,
checked in by pfleck, 12 years ago
|
#2063:
Set up basic webpage layout based on WebApplication branch.
Added Asp.Net MVC packages and some helper packages.
Implemented login.
|
File size:
1.3 KB
|
Line | |
---|
1 | param($installPath, $toolsPath, $package, $project)
|
---|
2 |
|
---|
3 | . (Join-Path $toolsPath common.ps1)
|
---|
4 |
|
---|
5 | # VS 11 and above supports the new intellisense JS files
|
---|
6 | $vsVersion = [System.Version]::Parse($dte.Version)
|
---|
7 | $supportsJsIntelliSenseFile = $vsVersion.Major -ge 11
|
---|
8 |
|
---|
9 | if (-not $supportsJsIntelliSenseFile) {
|
---|
10 | $displayVersion = $vsVersion.Major
|
---|
11 | Write-Host "IntelliSense JS files are not supported by your version of Visual Studio: $displayVersion"
|
---|
12 | exit
|
---|
13 | }
|
---|
14 |
|
---|
15 | if ($scriptsFolderProjectItem -eq $null) {
|
---|
16 | # No Scripts folder
|
---|
17 | Write-Host "No Scripts folder found"
|
---|
18 | exit
|
---|
19 | }
|
---|
20 |
|
---|
21 | # Delete the vsdoc file from the project
|
---|
22 | try {
|
---|
23 | $vsDocProjectItem = $scriptsFolderProjectItem.ProjectItems.Item("jquery-$ver-vsdoc.js")
|
---|
24 | Delete-ProjectItem $vsDocProjectItem
|
---|
25 | }
|
---|
26 | catch {
|
---|
27 | Write-Host "Error deleting vsdoc file: " + $_.Exception -ForegroundColor Red
|
---|
28 | exit
|
---|
29 | }
|
---|
30 |
|
---|
31 | # Copy the intellisense file to the project from the tools folder
|
---|
32 | $intelliSenseFileSourcePath = Join-Path $toolsPath $intelliSenseFileName
|
---|
33 | try {
|
---|
34 | $scriptsFolderProjectItem.ProjectItems.AddFromFileCopy($intelliSenseFileSourcePath)
|
---|
35 | }
|
---|
36 | catch {
|
---|
37 | # This will throw if the file already exists, so we need to catch here
|
---|
38 | }
|
---|
39 |
|
---|
40 | # Update the _references.js file
|
---|
41 | AddOrUpdate-Reference $scriptsFolderProjectItem $jqueryFileNameRegEx $jqueryFileName |
---|
Note: See
TracBrowser
for help on using the repository browser.