2024-02-03 16:17:24 -04:00
|
|
|
# Unix like pwd
|
|
|
|
if (Test-Path alias:pwd) {
|
|
|
|
Remove-Alias -Name pwd
|
|
|
|
}
|
|
|
|
Function pwd {(Get-Location).Path}
|
|
|
|
|
|
|
|
# Change to dotfiles directory
|
|
|
|
if (Test-Path alias:dotfolder) {
|
|
|
|
Remove-Alias -Name dotfolder
|
|
|
|
}
|
|
|
|
Function dotfolder {Set-Location ~/.local/share/chezmoi}
|
|
|
|
|
|
|
|
if (Test-Path alias:dotcommit) {
|
|
|
|
Remove-Alias -Name dotcommit
|
|
|
|
}
|
|
|
|
|
|
|
|
Function dotcommit {
|
2024-02-07 17:56:23 -04:00
|
|
|
# Export installed apps to file
|
|
|
|
. ~/Documents/PowerShell/installed-apps.ps1
|
|
|
|
|
2024-02-03 16:17:24 -04:00
|
|
|
# If no arguments are passed, use the default message
|
|
|
|
if ($args.Length -eq 0) {
|
|
|
|
$message = "Update dotfiles"
|
|
|
|
} else {
|
|
|
|
$message = $args -join " "
|
|
|
|
}
|
|
|
|
chezmoi re-add
|
|
|
|
chezmoi diff
|
|
|
|
chezmoi git -- commit -a -m $message
|
2024-02-03 16:18:58 -04:00
|
|
|
chezmoi git -- push
|
2024-02-03 16:18:11 -04:00
|
|
|
chezmoi apply
|
2024-02-03 16:17:24 -04:00
|
|
|
}
|