-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.ps1
More file actions
21 lines (17 loc) · 919 Bytes
/
init.ps1
File metadata and controls
21 lines (17 loc) · 919 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
$env:repository = "$HOME\git\dotfiles_windows"
# If repo and pwsh is already there just update it and run script again
if (Test-Path $env:repository\setup.ps1) {
Set-Location $env:repository
git pull
pwsh -NoProfile .\setup.ps1
}
# Git and PowerShellCore installation
# https://github.com/microsoft/terminal/pull/18639
# https://github.com/PowerShell/PowerShell-RFC/blob/master/Draft-Accepted/RFC0065-Install-PowerShell.md
winget install -h --accept-package-agreements --accept-source-agreements 9mz1snwt0n5d Git.Git
# Refresh env so git will be present in PATH
# Invoke-WebRequest -Uri "https://raw.githubusercontent.com/badrelmers/RefrEnv/main/refrenv.ps1" -OutFile "$HOME/refrenv.ps1"
# . "$HOME/refrenv.ps1"
iwr "https://raw.githubusercontent.com/badrelmers/RefrEnv/main/refrenv.ps1" | iex
git clone "https://github.com/soredake/dotfiles_windows" $env:repository
pwsh -NoProfile $env:repository\setup.ps1