mirror of
				https://github.com/folke/lazy.nvim.git
				synced 2025-10-31 06:21:14 +00:00 
			
		
		
		
	fix(bootstrap): fixed bootstrap script
This commit is contained in:
		
					parent
					
						
							
								a2f5c515de
							
						
					
				
			
			
				commit
				
					
						de82a99197
					
				
			
		
					 2 changed files with 8 additions and 16 deletions
				
			
		
							
								
								
									
										12
									
								
								README.md
									
										
									
									
									
								
							
							
						
						
									
										12
									
								
								README.md
									
										
									
									
									
								
							|  | @ -39,14 +39,10 @@ You can add the following Lua code to your `init.lua` to bootstrap **lazy.nvim** | |||
| ```lua | ||||
| local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" | ||||
| if not vim.loop.fs_stat(lazypath) then | ||||
|   vim.fn.system({ | ||||
|     "git", | ||||
|     "clone", | ||||
|     "--filter=blob:none", | ||||
|     "--branch=stable", -- remove this if you want to bootstrap to HEAD | ||||
|     "https://github.com/folke/lazy.nvim.git", | ||||
|     lazypath, | ||||
|   }) | ||||
|   if not vim.loop.fs_stat(lazypath) then | ||||
|     vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath }) | ||||
|     vim.fn.system({ "git", "-C", lazypath, "checkout", "tags/stable" }) -- last stable release | ||||
|   end | ||||
| end | ||||
| vim.opt.rtp:prepend(lazypath) | ||||
| ``` | ||||
|  |  | |||
|  | @ -68,14 +68,10 @@ end | |||
| function M.bootstrap() | ||||
|   local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" | ||||
|   if not vim.loop.fs_stat(lazypath) then | ||||
|     vim.fn.system({ | ||||
|       "git", | ||||
|       "clone", | ||||
|       "--filter=blob:none", | ||||
|       "--branch=stable", -- remove this if you want to bootstrap to HEAD | ||||
|       "https://github.com/folke/lazy.nvim.git", | ||||
|       lazypath, | ||||
|     }) | ||||
|     if not vim.loop.fs_stat(lazypath) then | ||||
|       vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath }) | ||||
|       vim.fn.system({ "git", "-C", lazypath, "checkout", "tags/stable" }) -- last stable release | ||||
|     end | ||||
|   end | ||||
|   vim.opt.rtp:prepend(lazypath) | ||||
| end | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue