mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-12-23 23:29:02 +01:00
Improved configure-git.ps1
This commit is contained in:
parent
5f4734149d
commit
106da19467
@ -4,9 +4,15 @@
|
||||
.DESCRIPTION sets up the Git configuration
|
||||
.LINK https://github.com/fleschutz/PowerShell
|
||||
.NOTES Author: Markus Fleschutz / License: CC0
|
||||
requires installation of Git
|
||||
#>
|
||||
|
||||
try {
|
||||
git --version
|
||||
} catch {
|
||||
write-error "No Git installation found - make sure Git is installed"
|
||||
exit 1
|
||||
}
|
||||
|
||||
$FullName = read-host "Enter your full name"
|
||||
$EmailAddress = read-host "Enter your e-mail address"
|
||||
$FavoriteEditor = read-host "Enter your favorite text editor (emacs,nano,vi,vim,...)"
|
||||
@ -18,7 +24,7 @@ try {
|
||||
git config --global http.sslVerify false
|
||||
git config --global core.autocrlf false
|
||||
git config --global core.symlinks true
|
||||
# git config --global init.defaultBranch main
|
||||
git config --global init.defaultBranch main
|
||||
write-output "OK - your Git configuration is now:"
|
||||
git config --list
|
||||
exit 0
|
||||
|
Loading…
Reference in New Issue
Block a user