Mac--Git安装

注意:在安装Git前,可先安装homebrew,应用brew命令安装Git即可。

一。Mac 安装homebrew

参考博客:https://blog.csdn.net/yuexiaxiaoxi27172319/article/details/51279369

Homebrew官网 http://brew.sh/index_zh-cn.html

说明:Homebrew简称brew,是Mac OSX上的软件包管理工具,能在Mac中方便的安装软件或者卸载软件,可以说Homebrew就是mac下的apt-get、yum神器

1。Homebrew安装

//打开终端,输入命令
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

2。Homebrew使用

//搜索软件:

brew search 软件名,如brew search wget

//安装软件:

brew install 软件名,如brew install wget

//卸载软件:

brew remove 软件名,如brew remove wget  
brew uninstall 软件名,如brew uninstall wget

3。Homebrew安装成功显示如下:

centlingdeMacBook-Pro:openssl-1.0.2g centling$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/doc/homebrew
/usr/local/share/man/man1/brew.
/usr/local/share/zsh/site-functions/_brew
/usr/local/etc/bash_completion.d/brew Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/mkdir /usr/local
==> /usr/bin/sudo /bin/chmod g+rwx /usr/local
==> /usr/bin/sudo /usr/sbin/chown centling:admin /usr/local
==> /usr/bin/sudo /bin/mkdir /Library/Caches/Homebrew
==> /usr/bin/sudo /bin/chmod g+rwx /Library/Caches/Homebrew
==> /usr/bin/sudo /usr/sbin/chown centling /Library/Caches/Homebrew
==> Downloading and installing Homebrew...
remote: Counting objects: , done.
remote: Compressing objects: % (/), done.
remote: Total (delta ), reused (delta ), pack-reused
Receiving objects: % (/), 701.87 KiB | 116.00 KiB/s, done.
Resolving deltas: % (/), done.
From https://github.com/Homebrew/brew
* [new branch] master -> origin/master
HEAD is now at 496fff6 doco: more updates for core/formula separation
==> Tapping homebrew/core
Cloning into '/usr/local/Library/Taps/homebrew/homebrew-core'...
remote: Counting objects: , done.
remote: Compressing objects: % (/), done.
remote: Total (delta ), reused (delta ), pack-reused
Receiving objects: % (/), 2.75 MiB | 375.00 KiB/s, done.
Resolving deltas: % (/), done.
Checking connectivity... done.
Tapped formulae (, files, 8.6M)
==> Installation successful!
==> Next steps
Run `brew help` to get started
centlingdeMacBook-Pro:openssl-1.0.2g centling$

二。应用brew安装Git版本控制工具

参考博客:https://blog.csdn.net/xiaohanluo/article/details/53214933

1。打开终端,输入命令:brew install git

2。安装好Git后,配置用户名和用户邮箱,以后每次与Git的交互都会使用该信息

git config --global user.name "your_name"
git config --global user.email "your_email@gmail.com"

配置信息可以更改,以后想要更改使用上面指令就可以。同时可以使用git config --list指令查看Git的配置信息。

Git默认是大小写不敏感的,也就是说,将一个文件名某个字母做了大小写转换的修改Git是忽略这个改动的,导致在同步代码时候会出现错误,所以建议大小把Git设置成大小写敏感。

git config core.ignorecase false

相关Git学习参考博客:

https://blog.csdn.net/xiaohanluo/article/details/53214933

Git教程,里面有介绍到Git的工作原理,可以仔细阅读。

Git Community Book 中文版介绍了Git具体使用,这本书也是关于Git的一本好书。

Git练习,实战练习Git的各种指令

Mac002--Git安装的更多相关文章

  1. CentOS 7 Git安装

    Git安装 yum -y install git 安装后,在srv目录下建立Git的目录. 初始化一个git空仓库 git init --bare project.git 增加用于访问git仓库的用户 ...

  2. Git安装

    前面说了很多废话,说得再好,还不如实践一次.要想使用Git,首先得安装.这次实验主要是实践怎样安装Git. 安装与检查是否安装成功 1. 在Linux(Ubuntu)上安装 上篇的Git简介已经介绍过 ...

  3. Git安装与配置

    一.简介 Git是一款免费.开源的分布式版本控制系统,用于敏捷高效地处理任何或小或大的项目版本管理. Git 是 Linus Torvalds 为了帮助管理 Linux 内核开发而开发的一个开放源码的 ...

  4. 版本管理之Git(二):Win7上Git安装及简单配置过程

    一.安装包 msysgit(Windows版本的Git) 下载地址:http://code.google.com/p/msysgit/downloads/list?q=full+installer+o ...

  5. git安装及命令使用和github网站

    最近参与别人的github项目时,学习了git的使用,首先需要在https://github.com/网站上注册账号和邮箱,然后fork一个开源项目,然后下载目前Windows下最新版本的git,下载 ...

  6. Git 安装

    安装参考资料: http://lzw.me/a/msysgit-tortoisegit-win-git.html http://blog.csdn.net/qwiwuqo/article/detail ...

  7. 转 git安装配置

    Win7上Git安装及配置过程 一.安装说明 1.Git在windows平台上安装说明. Git 是 Linux Torvalds 为了帮助管理 Linux 内核开发而开发的一个开放源码的版本控制软件 ...

  8. git学习1:git安装和配置

    Git是什么?世界上最先进的分布式版本控制系统,记录了一个文本文件的每次一修改信息,比如,一篇散文,从草稿到最终出版,经历过无数次修改,修改了标点符号形成一个版本,老师帮助修改形成一个版本,同学帮忙修 ...

  9. ubuntu下git安装及使用

    ubuntu下git安装及使用   其实,好几个月前,就已经安装好了,可是一直搁置在那儿,所以密码等一些其它细节都忘的差不多了,所以今天就重新部署了一下,并开始积极使用......... 1,git ...

  10. 分布式管理系统-git安装及配置

    安装完成后,在开始菜单里找到“Git”->“Git Bash”,蹦出一个类似命令行窗口的东西,就说明Git安装成功! 安装完成后,还需要最后一步设置,在命令行输入: $ git config - ...

随机推荐

  1. docker网络 macvlan

    docker 还开发了另一个支持跨主机容器网络的 driver:macvlan. macvlan 本身是 linxu kernel 模块,其功能是允许在同一个物理网卡上配置多个 MAC 地址,即多个 ...

  2. centos7操作防火墙

    1.firewalld的基本使用 启动: systemctl start firewalld 关闭: systemctl stop firewalld 查看状态: systemctl status f ...

  3. 第一次写的MySQLHelper

    一. 第一次写MysqlHelper,用来管理城市的数据库 二.MySQLHelper源代码 using MySql.Data.MySqlClient; using System; using Sys ...

  4. set unused

    使用 set unused 选项标记不再使用的列 使用 drop unsused columns 丢弃标记为unused的列 alter table tabName set unused column ...

  5. thinkphp数据库连接

    https://www.kancloud.cn/manual/thinkphp5/118059 一.配置文件定义 常用的配置方式是在应用目录或者模块目录下面的database.php中添加下面的配置参 ...

  6. ubuntu idea 安装

    一.下载 1.进入官网 下载对应安装包 https://www.jetbrains.com/idea/download/#section=linux sudo wget https://downloa ...

  7. 4. jaxp----dom解析器(DocumentBuilderFactory、DocumentBuilder)

    1.DocumentBuilderFactory--解析器工厂(抽象类 javax.xml.parsers.DocumentBuilderFactory) newInstance()  获取 Docu ...

  8. Android 播放器开发

    GSY https://github.com/CarGuo/GSYVideoPlayer/blob/master/doc/USE.md 阿里云播放器 https://helpcdn.aliyun.co ...

  9. hdu 6047: Maximum Sequence (2017 多校第二场 1003)【贪心】

    题目链接 可以贪心写,先把b数组按从小到大的顺序排个序,根据b[i]的值来产生a[n+i] 借助一个c数组,c[i]记录,j从i到n,a[j]-j的最大值,再加上一个实时更新的变量ma,记录从n+1到 ...

  10. 【leetcode】1028. Recover a Tree From Preorder Traversal

    题目如下: We run a preorder depth first search on the root of a binary tree. At each node in this traver ...