mirror of
				https://github.com/ohmyzsh/ohmyzsh.git
				synced 2025-11-04 13:21:19 +08:00 
			
		
		
		
	Add git-lfs plugin (#9077)
This commit is contained in:
		
							parent
							
								
									58ff4e1d2e
								
							
						
					
					
						commit
						8ad9b315a3
					
				
							
								
								
									
										1
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								.github/CODEOWNERS
									
									
									
									
										vendored
									
									
								
							@ -1,3 +1,4 @@
 | 
			
		||||
# Plugin owners
 | 
			
		||||
plugins/gitfast/ @felipec
 | 
			
		||||
plugins/sdk/ @rgoldberg
 | 
			
		||||
plugins/git-lfs/ @vietduc01100001
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										24
									
								
								plugins/git-lfs/README.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								plugins/git-lfs/README.md
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,24 @@
 | 
			
		||||
# git lfs plugin
 | 
			
		||||
 | 
			
		||||
The git lfs plugin provides [aliases](#aliases) and [functions](#functions) for [git-lfs](https://github.com/git-lfs/git-lfs).
 | 
			
		||||
 | 
			
		||||
To use it, add `git-lfs` to the plugins array in your zshrc file:
 | 
			
		||||
 | 
			
		||||
```zsh
 | 
			
		||||
plugins=(... git-lfs)
 | 
			
		||||
```
 | 
			
		||||
 | 
			
		||||
## Aliases
 | 
			
		||||
 | 
			
		||||
| Alias    | Command                             |
 | 
			
		||||
| :------- | :---------------------------------- |
 | 
			
		||||
| `glfsi`  | `git lfs install`                   |
 | 
			
		||||
| `glfst`  | `git lfs track`                     |
 | 
			
		||||
| `glfsls` | `git lfs ls-files`                  |
 | 
			
		||||
| `glfsmi` | `git lfs migrate import --include=` |
 | 
			
		||||
 | 
			
		||||
## Functions
 | 
			
		||||
 | 
			
		||||
| Function | Command                                         |
 | 
			
		||||
| :------- | :---------------------------------------------- |
 | 
			
		||||
| `gplfs`  | `git lfs push origin "$(current_branch)" --all` |
 | 
			
		||||
							
								
								
									
										17
									
								
								plugins/git-lfs/git-lfs.plugin.zsh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								plugins/git-lfs/git-lfs.plugin.zsh
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,17 @@
 | 
			
		||||
#
 | 
			
		||||
# Aliases
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
alias glfsi='git lfs install'
 | 
			
		||||
alias glfst='git lfs track'
 | 
			
		||||
alias glfsls='git lfs ls-files'
 | 
			
		||||
alias glfsmi='git lfs migrate import --include='
 | 
			
		||||
 | 
			
		||||
#
 | 
			
		||||
# Functions
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
function gplfs() {
 | 
			
		||||
  local b="$(git_current_branch)"
 | 
			
		||||
  git lfs push origin "$b" --all
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user