问题描述
每次我在命令窗口中输入
Every time I enter in my command window
git lfs install
我收到的消息是git:'lfs'不是git命令.参见"git --help".
the message I get is git: 'lfs' is not a git command. See 'git --help'.
我试图寻找解决方案,但是没有一个明确的答案.有人可以解释清楚如何解决此问题吗?
I tried looking up for a solution, but none of the answers were clear. Can someone explain clear how to fix this?
推荐答案
您似乎尚未在计算机上下载git-lfs,因此 git lfs install
并非由以下人员注册的命令git.
It looks like you haven't downloaded git-lfs on your machine, so git lfs install
isn't a registered command by git.
按如下所示安装git-lfs:
Install git-lfs as outlined below:
- git-lfs requires git version 1.8.2 or later. You can check the version you have by running
git --version
, and update if required. - If you are installing on macOS, make sure you have Homebrew installed.
根据您的操作系统按照以下步骤下载git-lfs.
Download git-lfs by following the steps based on your operating system.
Debian/Ubuntu
$ curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | sudo bash
$ sudo apt-get install git-lfs
MacOS(使用自制软件)
$ brew update
$ brew install git-lfs
Windows
下载并运行最新的 Windows安装程序.
最后,运行 git-lfs install
在系统上安装 git-lfs
.您始终可以运行 git-lfs卸载
进行卸载.
Finally, run git-lfs install
to install git-lfs
on your system.You can always run git-lfs uninstall
to uninstall.
更详细的信息(例如在其他平台上的安装)可在git-lfs的安装页面.
这篇关于git:'lfs'不是一个不清楚的git命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!