modified: RdzeN-Profile.ps1
modified: functions/Override-Profile.ps1 modified: functions/Reload-Profile.ps1 modified: functions/Test-Profile.ps1
This commit is contained in:
parent
0010dd1979
commit
94499ff700
@ -45,29 +45,9 @@ Get-ChildItem $path_gitea_powershell_profile_functions | ForEach-Object {
|
||||
. $_.FullName
|
||||
}
|
||||
|
||||
# 96. Update Profile Section:
|
||||
if (-not (Test-Path $PROFILE)) {
|
||||
# 97. Test Profile
|
||||
Test-Profile
|
||||
} else {
|
||||
# 98. Override Profile
|
||||
do {
|
||||
New-SimulateTyping "Do you want to Override your PS Profile?"
|
||||
$reload = Read-Host "Type [Y]es or [N]o"
|
||||
} until (
|
||||
$reload -in ("Y","N")
|
||||
)
|
||||
if ($reload -eq "Y") {
|
||||
Override-Profile
|
||||
}
|
||||
}
|
||||
# 99. Reload Profile
|
||||
do {
|
||||
New-SimulateTyping "Do you want to Reload your PS Profile?"
|
||||
$reload = Read-Host "Type [Y]es or [N]o"
|
||||
} until (
|
||||
$reload -in ("Y","N")
|
||||
)
|
||||
if ($reload -eq "Y") {
|
||||
Reload-Profile
|
||||
}
|
||||
|
@ -3,6 +3,5 @@
|
||||
function Override-Profile {
|
||||
if ((Test-Path $PROFILE)) {
|
||||
Get-Content "$path_gitea_powershell_profile\RdzeN-Profile.ps1" | Set-Content $PROFILE -Force
|
||||
New-SimulateTyping "Your PowerShell profile was Override!"
|
||||
}
|
||||
}
|
@ -3,4 +3,3 @@
|
||||
function Reload-Profile {
|
||||
. $PROFILE
|
||||
}
|
||||
New-SimulateTyping "Your PowerShell profile was Reloaded!"
|
@ -3,6 +3,5 @@
|
||||
function Test-Profile {
|
||||
if (-not (Test-Path $PROFILE)) {
|
||||
Copy-Item -Path "$path_gitea_powershell_profile\RdzeN-Profile.ps1" -Destination $PROFILE -force
|
||||
New-SimulateTyping "Your PowerShell profile was created!"
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user