Browse Source

Add .gitattributes

pull/73/head
Alex Hirsch 10 years ago
parent
commit
da846996f5
  1. 4
      .gitattributes
  2. 180
      scripts/remove-default-apps.ps1
  3. 106
      utils/install-basic-software.ps1

4
.gitattributes

@ -0,0 +1,4 @@
* text=auto
*.ps1 text eol=crlf
*.psm1 text eol=crlf
*.reg text eol=crlf

180
scripts/remove-default-apps.ps1

@ -1,90 +1,90 @@
# Description: # Description:
# This script removes unwanted Apps that come with Windows. If you do not want # This script removes unwanted Apps that come with Windows. If you do not want
# to remove certain Apps comment out the corresponding lines below. # to remove certain Apps comment out the corresponding lines below.
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1 Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1
echo "Elevating priviledges for this process" echo "Elevating priviledges for this process"
do {} until (Elevate-Privileges SeTakeOwnershipPrivilege) do {} until (Elevate-Privileges SeTakeOwnershipPrivilege)
echo "Uninstalling default apps" echo "Uninstalling default apps"
$apps = @( $apps = @(
# default Windows 10 apps # default Windows 10 apps
"Microsoft.3DBuilder" "Microsoft.3DBuilder"
"Microsoft.Appconnector" "Microsoft.Appconnector"
"Microsoft.BingFinance" "Microsoft.BingFinance"
"Microsoft.BingNews" "Microsoft.BingNews"
"Microsoft.BingSports" "Microsoft.BingSports"
"Microsoft.BingWeather" "Microsoft.BingWeather"
#"Microsoft.FreshPaint" #"Microsoft.FreshPaint"
"Microsoft.Getstarted" "Microsoft.Getstarted"
"Microsoft.MicrosoftOfficeHub" "Microsoft.MicrosoftOfficeHub"
"Microsoft.MicrosoftSolitaireCollection" "Microsoft.MicrosoftSolitaireCollection"
#"Microsoft.MicrosoftStickyNotes" #"Microsoft.MicrosoftStickyNotes"
"Microsoft.Office.OneNote" "Microsoft.Office.OneNote"
#"Microsoft.OneConnect" #"Microsoft.OneConnect"
"Microsoft.People" "Microsoft.People"
"Microsoft.SkypeApp" "Microsoft.SkypeApp"
#"Microsoft.Windows.Photos" #"Microsoft.Windows.Photos"
"Microsoft.WindowsAlarms" "Microsoft.WindowsAlarms"
#"Microsoft.WindowsCalculator" #"Microsoft.WindowsCalculator"
"Microsoft.WindowsCamera" "Microsoft.WindowsCamera"
"Microsoft.WindowsMaps" "Microsoft.WindowsMaps"
"Microsoft.WindowsPhone" "Microsoft.WindowsPhone"
"Microsoft.WindowsSoundRecorder" "Microsoft.WindowsSoundRecorder"
#"Microsoft.WindowsStore" #"Microsoft.WindowsStore"
"Microsoft.XboxApp" "Microsoft.XboxApp"
"Microsoft.ZuneMusic" "Microsoft.ZuneMusic"
"Microsoft.ZuneVideo" "Microsoft.ZuneVideo"
"microsoft.windowscommunicationsapps" "microsoft.windowscommunicationsapps"
"Microsoft.MinecraftUWP" "Microsoft.MinecraftUWP"
# Threshold 2 apps # Threshold 2 apps
"Microsoft.CommsPhone" "Microsoft.CommsPhone"
"Microsoft.ConnectivityStore" "Microsoft.ConnectivityStore"
"Microsoft.Messaging" "Microsoft.Messaging"
"Microsoft.Office.Sway" "Microsoft.Office.Sway"
#Redstone apps #Redstone apps
"Microsoft.BingFoodAndDrink" "Microsoft.BingFoodAndDrink"
"Microsoft.BingTravel" "Microsoft.BingTravel"
"Microsoft.BingHealthAndFitness" "Microsoft.BingHealthAndFitness"
"Microsoft.WindowsReadingList" "Microsoft.WindowsReadingList"
# non-Microsoft # non-Microsoft
"9E2F88E3.Twitter" "9E2F88E3.Twitter"
"Flipboard.Flipboard" "Flipboard.Flipboard"
"ShazamEntertainmentLtd.Shazam" "ShazamEntertainmentLtd.Shazam"
"king.com.CandyCrushSaga" "king.com.CandyCrushSaga"
"king.com.CandyCrushSodaSaga" "king.com.CandyCrushSodaSaga"
"king.com.*" "king.com.*"
"ClearChannelRadioDigital.iHeartRadio" "ClearChannelRadioDigital.iHeartRadio"
"4DF9E0F8.Netflix" "4DF9E0F8.Netflix"
"6Wunderkinder.Wunderlist" "6Wunderkinder.Wunderlist"
"Drawboard.DrawboardPDF" "Drawboard.DrawboardPDF"
"2FE3CB00.PicsArt-PhotoStudio" "2FE3CB00.PicsArt-PhotoStudio"
"D52A8D61.FarmVille2CountryEscape" "D52A8D61.FarmVille2CountryEscape"
"TuneIn.TuneInRadio" "TuneIn.TuneInRadio"
"GAMELOFTSA.Asphalt8Airborne" "GAMELOFTSA.Asphalt8Airborne"
#"TheNewYorkTimes.NYTCrossword" #"TheNewYorkTimes.NYTCrossword"
# apps which cannot be removed using Remove-AppxPackage # apps which cannot be removed using Remove-AppxPackage
#"Microsoft.BioEnrollment" #"Microsoft.BioEnrollment"
#"Microsoft.MicrosoftEdge" #"Microsoft.MicrosoftEdge"
#"Microsoft.Windows.Cortana" #"Microsoft.Windows.Cortana"
#"Microsoft.WindowsFeedback" #"Microsoft.WindowsFeedback"
#"Microsoft.XboxGameCallableUI" #"Microsoft.XboxGameCallableUI"
#"Microsoft.XboxIdentityProvider" #"Microsoft.XboxIdentityProvider"
#"Windows.ContactSupport" #"Windows.ContactSupport"
) )
foreach ($app in $apps) { foreach ($app in $apps) {
echo "Trying to remove $app" echo "Trying to remove $app"
Get-AppxPackage -Name $app -AllUsers | Remove-AppxPackage Get-AppxPackage -Name $app -AllUsers | Remove-AppxPackage
Get-AppXProvisionedPackage -Online | Get-AppXProvisionedPackage -Online |
where DisplayName -EQ $app | where DisplayName -EQ $app |
Remove-AppxProvisionedPackage -Online Remove-AppxProvisionedPackage -Online
} }

106
utils/install-basic-software.ps1

@ -1,53 +1,53 @@
# Description: # Description:
# This script will use Windows package manager to bootstrap Chocolatey and # This script will use Windows package manager to bootstrap Chocolatey and
# install a list of packages. Script will also install Sysinternals Utilities # install a list of packages. Script will also install Sysinternals Utilities
# into your default drive's root directory. # into your default drive's root directory.
$packages = @( $packages = @(
"notepadplusplus.install" "notepadplusplus.install"
"peazip.install" "peazip.install"
#"7zip.install" #"7zip.install"
#"aimp" #"aimp"
#"audacity" #"audacity"
#"autoit" #"autoit"
#"classic-shell" #"classic-shell"
#"filezilla" #"filezilla"
#"firefox" #"firefox"
#"gimp" #"gimp"
#"google-chrome-x64" #"google-chrome-x64"
#"imgburn" #"imgburn"
#"keepass.install" #"keepass.install"
#"paint.net" #"paint.net"
#"putty" #"putty"
#"python" #"python"
#"qbittorrent" #"qbittorrent"
#"speedcrunch" #"speedcrunch"
#"sysinternals" #"sysinternals"
#"thunderbird" #"thunderbird"
#"vlc" #"vlc"
#"windirstat" #"windirstat"
#"wireshark" #"wireshark"
) )
echo "Setting up Chocolatey software package manager" echo "Setting up Chocolatey software package manager"
Get-PackageProvider -Name chocolatey -Force Get-PackageProvider -Name chocolatey -Force
echo "Creating daily task to automatically upgrade Chocolatey packages" echo "Creating daily task to automatically upgrade Chocolatey packages"
# adapted from https://blogs.technet.microsoft.com/heyscriptingguy/2013/11/23/using-scheduled-tasks-and-scheduled-jobs-in-powershell/ # adapted from https://blogs.technet.microsoft.com/heyscriptingguy/2013/11/23/using-scheduled-tasks-and-scheduled-jobs-in-powershell/
$taskName = "Chocolatey Daily Upgrade" $taskName = "Chocolatey Daily Upgrade"
$taskAction = New-ScheduledTaskAction Execute C:\programdata\chocolatey\choco.exe -Argument "upgrade all -y" $taskAction = New-ScheduledTaskAction Execute C:\programdata\chocolatey\choco.exe -Argument "upgrade all -y"
$taskTrigger = New-ScheduledTaskTrigger -At 2am -Daily $taskTrigger = New-ScheduledTaskTrigger -At 2am -Daily
$taskUser = "Admin" $taskUser = "Admin"
Register-ScheduledTask TaskName $taskName -Action $taskAction Trigger $taskTrigger -User $taskUser Register-ScheduledTask TaskName $taskName -Action $taskAction Trigger $taskTrigger -User $taskUser
echo "Installing Packages" echo "Installing Packages"
Install-Package -Name $packages -Force -ProviderName chocolatey Install-Package -Name $packages -Force -ProviderName chocolatey
echo "Installing Sysinternals Utilities to C:\Sysinternals" echo "Installing Sysinternals Utilities to C:\Sysinternals"
$download_uri = "https://download.sysinternals.com/files/SysinternalsSuite.zip" $download_uri = "https://download.sysinternals.com/files/SysinternalsSuite.zip"
$wc = new-object net.webclient $wc = new-object net.webclient
$wc.DownloadFile($download_uri, "/SysinternalsSuite.zip") $wc.DownloadFile($download_uri, "/SysinternalsSuite.zip")
Add-Type -AssemblyName "system.io.compression.filesystem" Add-Type -AssemblyName "system.io.compression.filesystem"
[io.compression.zipfile]::ExtractToDirectory("/SysinternalsSuite.zip", "/Sysinternals") [io.compression.zipfile]::ExtractToDirectory("/SysinternalsSuite.zip", "/Sysinternals")
echo "Removing zipfile" echo "Removing zipfile"
rm "/SysinternalsSuite.zip" rm "/SysinternalsSuite.zip"

Loading…
Cancel
Save