Skip to content

About

:octocat: Oh My Zsh's Git aliases for PowerShell.

Topics

Resources

Stars

507 stars

Watchers

2 watching

Forks

Latest commit

 

History

130 Commits

Folders and files

Repository files navigation

Git aliases for PowerShell

license PowerShell Gallery PowerShell Gallery GitHub Actions Workflow Status

A PowerShell module that provide partial Git aliases from Oh My Zsh's git plugin.

ℹ️ This module will replace some built-in PowerShell aliases with our Git aliases to prevent conflict.

⚙️ Installation

Install from PowerShell Gallery

Install-Module git-aliases -Scope CurrentUser -AllowClobber

Or from Scoop

scoop bucket add extras
scoop install git-aliases

⚠️ If you haven't allowed script execution policy, set your script execution policy to RemoteSigned or Unrestricted.

Set-ExecutionPolicy RemoteSigned -Scope CurrentUser

🛂 Usage

You have to import the module to use git-aliases.

Add below command into your PowerShell profile.

Import-Module git-aliases -DisableNameChecking

Then restart your PowerShell. Now you can use Git aliases.


⚠️ If you don't have PowerShell profile yet, create it with below command!

New-Item -ItemType File $profile

📖 Aliases

See aliases.md for the full list of available aliases and what each one does.

You can also inspect them from PowerShell with Get-Git-Aliases.

Get-Git-Aliases

Prints the definition of every Git alias in the module, or the definition of a single alias.

Parameter Type Description
-Alias String Optional. Name of the alias to inspect (e.g. gst). When omitted, all aliases are listed in a table.

Show all aliases:

Get-Git-Aliases

Show the definition of a single alias:

Get-Git-Aliases -Alias gst

The output is the alias' function body, so it shows exactly which git command the alias runs:

git status $args

Passing an unknown alias name throws an error.

About

:octocat: Oh My Zsh's Git aliases for PowerShell.

Topics

Resources

Stars

507 stars

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages