-
-
Notifications
You must be signed in to change notification settings - Fork 23
/
update.ps1
17 lines (13 loc) · 800 Bytes
/
update.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
$pkgold = Get-Content "package-lock.json" | ConvertFrom-Json -AsHashtable
$bversionold = $pkgold["packages"]["node_modules/bootstrap"]["version"]
Write-Host "Bootstrap current: $bversionold"
npm update
Copy-Item -Force .\node_modules\bootstrap\dist\js\bootstrap.bundle.min.js .\assets\js\bootstrap.bundle.min.js
New-Item -Path ".\assets\sass\bootstrap\" -ItemType "Directory" -Force
Copy-Item -Path ".\node_modules\bootstrap\scss\*" -Destination ".\assets\sass\bootstrap\" -Recurse -Force
$pkg = Get-Content "package-lock.json" | ConvertFrom-Json -AsHashtable
$bversion = $pkg["packages"]["node_modules/bootstrap"]["version"]
Write-Host "Bootstrap: $bversion"
Write-Host "For tagging:"
Write-Host "git tag -a v$bversion -m ""Bootstrap version $bversion"""
Write-Host "git push origin v$bversion"