aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.config/powershell/bootstrap.ps18
1 files changed, 5 insertions, 3 deletions
diff --git a/.config/powershell/bootstrap.ps1 b/.config/powershell/bootstrap.ps1
index 6ee4651..b63ced7 100644
--- a/.config/powershell/bootstrap.ps1
+++ b/.config/powershell/bootstrap.ps1
@@ -2,7 +2,7 @@
# Variables
$newUsername = "srdusr"
-$dotfiles_url = 'https://github.com/$newUsername/dotfiles.git'
+$dotfiles_url = 'https://github.com/srdusr/dotfiles.git'
$dotfiles_dir = "$HOME\.cfg"
$oldUsername = $env:USERNAME
@@ -29,8 +29,8 @@ foreach ($app in $apps) {
}
# Define the `config` alias in the current session
-function config {
- git --git-dir=$env:USERPROFILE/.cfg/ --work-tree=$env:USERPROFILE @args
+function global:config {
+ git --git-dir="$env:USERPROFILE\.cfg" --work-tree="$env:USERPROFILE" $args
}
# Add .gitignore entries
@@ -38,6 +38,8 @@ Add-Content -Path "$HOME\.gitignore" -Value ".cfg"
Add-Content -Path "$HOME\.gitignore" -Value "install.bat"
Add-Content -Path "$HOME\.gitignore" -Value ".config/powershell/bootstrap.ps1"
+Set-ExecutionPolicy RemoteSigned
+
# Check if the profile exists, otherwise create it
if (!(Test-Path -Path $PROFILE)) {
New-Item -Type File -Path $PROFILE -Force