|
1 | | -Git for Windows |
| 1 | +Microsoft Git |
2 | 2 | =============== |
3 | 3 |
|
4 | | -[](https://github.com/git-for-windows/git/actions?query=branch%3Amaster+event%3Apush) |
5 | | -[](https://gitter.im/git-for-windows/git?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) |
| 4 | +[](https://github.com/microsoft/git/actions/workflows/main.yml) |
6 | 5 |
|
7 | | -This is [Git for Windows](http://git-for-windows.github.io/), the Windows port |
8 | | -of [Git](http://git-scm.com/). |
| 6 | +This is Microsoft Git, a special Git distribution to support monorepo scenarios. If you are _not_ working in a monorepo, you are likely searching for [Git for Windows](http://git-for-windows.github.io/) instead of this codebase. |
9 | 7 |
|
10 | | -The Git for Windows project is run using a [governance |
11 | | -model](http://git-for-windows.github.io/governance-model.html). If you |
12 | | -encounter problems, you can report them as [GitHub |
13 | | -issues](https://github.com/git-for-windows/git/issues), discuss them on Git |
14 | | -for Windows' [Google Group](http://groups.google.com/group/git-for-windows), |
15 | | -and [contribute bug |
16 | | -fixes](https://github.com/git-for-windows/git/wiki/How-to-participate). |
| 8 | +If you encounter problems with Microsoft Git, please report them as [GitHub issues](https://github.com/microsoft/git/issues). |
17 | 9 |
|
18 | | -Git - fast, scalable, distributed revision control system |
| 10 | +Why is Microsoft Git needed? |
19 | 11 | ========================================================= |
20 | 12 |
|
21 | | -Git is a fast, scalable, distributed revision control system with an |
22 | | -unusually rich command set that provides both high-level operations |
23 | | -and full access to internals. |
24 | | - |
25 | | -Git is an Open Source project covered by the GNU General Public |
26 | | -License version 2 (some parts of it are under different licenses, |
27 | | -compatible with the GPLv2). It was originally written by Linus |
28 | | -Torvalds with help of a group of hackers around the net. |
29 | | - |
30 | | -Please read the file [INSTALL][] for installation instructions. |
31 | | - |
32 | | -Many Git online resources are accessible from <https://git-scm.com/> |
33 | | -including full documentation and Git related tools. |
34 | | - |
35 | | -See [Documentation/gittutorial.txt][] to get started, then see |
36 | | -[Documentation/giteveryday.txt][] for a useful minimum set of commands, and |
37 | | -`Documentation/git-<commandname>.txt` for documentation of each command. |
38 | | -If git has been correctly installed, then the tutorial can also be |
39 | | -read with `man gittutorial` or `git help tutorial`, and the |
40 | | -documentation of each command with `man git-<commandname>` or `git help |
41 | | -<commandname>`. |
42 | | - |
43 | | -CVS users may also want to read [Documentation/gitcvs-migration.txt][] |
44 | | -(`man gitcvs-migration` or `git help cvs-migration` if git is |
45 | | -installed). |
46 | | - |
47 | | -The user discussion and development of core Git take place on the Git |
48 | | -mailing list -- everyone is welcome to post bug reports, feature |
49 | | -requests, comments and patches to [email protected] (read |
50 | | -[Documentation/SubmittingPatches][] for instructions on patch submission). |
51 | | -To subscribe to the list, send an email with just "subscribe git" in |
52 | | -the body to [email protected]. The mailing list archives are |
53 | | -available at <https://lore.kernel.org/git/>, |
54 | | -<http://marc.info/?l=git> and other archival sites. |
55 | | -The core git mailing list is plain text (no HTML!). |
56 | | - |
57 | | -Issues which are security relevant should be disclosed privately to |
58 | | -the Git Security mailing list <[email protected]>. |
59 | | - |
60 | | -The maintainer frequently sends the "What's cooking" reports that |
61 | | -list the current status of various development topics to the mailing |
62 | | -list. The discussion following them give a good reference for |
63 | | -project status, development direction and remaining tasks. |
64 | | - |
65 | | -The name "git" was given by Linus Torvalds when he wrote the very |
66 | | -first version. He described the tool as "the stupid content tracker" |
67 | | -and the name as (depending on your mood): |
68 | | - |
69 | | - - random three-letter combination that is pronounceable, and not |
70 | | - actually used by any common UNIX command. The fact that it is a |
71 | | - mispronunciation of "get" may or may not be relevant. |
72 | | - - stupid. contemptible and despicable. simple. Take your pick from the |
73 | | - dictionary of slang. |
74 | | - - "global information tracker": you're in a good mood, and it actually |
75 | | - works for you. Angels sing, and a light suddenly fills the room. |
76 | | - - "goddamn idiotic truckload of sh*t": when it breaks |
77 | | - |
78 | | -[INSTALL]: INSTALL |
79 | | -[Documentation/gittutorial.txt]: Documentation/gittutorial.txt |
80 | | -[Documentation/giteveryday.txt]: Documentation/giteveryday.txt |
81 | | -[Documentation/gitcvs-migration.txt]: Documentation/gitcvs-migration.txt |
82 | | -[Documentation/SubmittingPatches]: Documentation/SubmittingPatches |
| 13 | +Git is awesome - it's a fast, scalable, distributed version control system with an unusually rich command set that provides both high-level operations and full access to internals. What more could you ask for? |
| 14 | + |
| 15 | +Well, because Git is a distributed version control system, each Git repository has a copy of all files in the entire history. As large repositories, aka _monorepos_ grow, Git can struggle to manage all that data. As Git commands like `status` and `fetch` get slower, developers stop waiting and start switching context. And context switches harm developer productivity. |
| 16 | + |
| 17 | +Microsoft Git is focused on addressing these performance woes and making the monorepo developer experience first-class. It does so in part by working with the [GVFS protocol](https://docs.microsoft.com/en-us/azure/devops/learn/git/gvfs-architecture#gvfs-protocol) to prefetch packs of commits and trees and delay downloading of associated blobs. This is required for monorepos using [VFS for Git](https://github.com/microsoft/VFSForGit/blob/master/Readme.md). Additionally, some Git hosting providers support the GVFS protocol instead of the Git-native [partial clone feature](https://github.blog/2020-12-21-get-up-to-speed-with-partial-clone-and-shallow-clone/). |
| 18 | + |
| 19 | +Downloading and Installing |
| 20 | +========================================================= |
| 21 | + |
| 22 | +If you're working in a monorepo and want to take advantage of Microsoft Git's performance boosts, you can |
| 23 | +download the latest version installer for your OS from the [Releases page](https://github.com/microsoft/git/releases). Alternatively, |
| 24 | +you can opt to install via the command line, using the below instructions for supported OSes: |
| 25 | + |
| 26 | +## Windows |
| 27 | +__Note:__ Winget is still in public preview, meaning you currently [need to take special installation steps](https://docs.microsoft.com/en-us/windows/package-manager/winget/#install-winget) (i.e. manually installing the `.appxbundle`, installing the preview version of [App Installer](https://www.microsoft.com/p/app-installer/9nblggh4nns1?ocid=9nblggh4nns1_ORSEARCH_Bing&rtc=1&activetab=pivot:overviewtab), or participating in the [Windows Insider flight ring](https://insider.windows.com/https://insider.windows.com/)). |
| 28 | + |
| 29 | +To install with Winget, run |
| 30 | + |
| 31 | +```shell |
| 32 | +winget install microsoft/git |
| 33 | +``` |
| 34 | + |
| 35 | +To upgrade Microsoft Git, use the following Git command, which will download and install the latest release. |
| 36 | + |
| 37 | +```shell |
| 38 | +git update-microsoft-git |
| 39 | +``` |
| 40 | + |
| 41 | +You may also be alerted with a notification to upgrade, which presents a single-click process for running `git update-microsoft-git`. |
| 42 | + |
| 43 | +## macOS |
| 44 | + |
| 45 | +To install Microsoft Git on macOS, first [be sure that Homebrew is installed](https://brew.sh/) then install the `microsoft-git` cask with these steps: |
| 46 | + |
| 47 | +```shell |
| 48 | +brew tap microsoft/git |
| 49 | +brew install --cask microsoft-git |
| 50 | +``` |
| 51 | + |
| 52 | +To upgrade microsoft/git, you can run the necessary brew commands: |
| 53 | + |
| 54 | +```shell |
| 55 | +brew update |
| 56 | +brew upgrade --cask microsoft-git |
| 57 | +``` |
| 58 | + |
| 59 | +Or you can run the `git update-microsoft-git` command, which will run those brew commands for you. |
| 60 | + |
| 61 | +## Linux |
| 62 | + |
| 63 | +For Ubuntu/Debian distributions, `apt-get` support is coming soon. For now, though, please use the most recent [`.deb` package](https://github.com/microsoft/git/releases). |
| 64 | + |
| 65 | +```shell |
| 66 | +wget -o microsoft-git.deb https://github.com/microsoft/git/releases/download/v2.31.1.vfs.0.1/git-vfs_2.31.1.vfs.0.1.deb |
| 67 | +sudo dpkg -i microsoft-git.deb |
| 68 | +``` |
| 69 | + |
| 70 | +For other distributions, you will need to compile and install microsoft/git from source: |
| 71 | + |
| 72 | +```shell |
| 73 | +git clone https://github.com/microsoft/git microsoft-git |
| 74 | +cd microsoft-git |
| 75 | +make -j12 prefix=/usr/local |
| 76 | +sudo make -j12 prefix=/usr/local install |
| 77 | +``` |
| 78 | + |
| 79 | +For more assistance building Git from source, see [the INSTALL file in the core Git project](https://github.com/git/git/blob/master/INSTALL). |
| 80 | + |
| 81 | +Contributing |
| 82 | +========================================================= |
| 83 | + |
| 84 | +This project welcomes contributions and suggestions. Most contributions require you to agree to a |
| 85 | +Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us |
| 86 | +the rights to use your contribution. For details, visit <https://cla.microsoft.com.> |
| 87 | + |
| 88 | +When you submit a pull request, a CLA-bot will automatically determine whether you need to provide |
| 89 | +a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions |
| 90 | +provided by the bot. You will only need to do this once across all repos using our CLA. |
| 91 | + |
| 92 | +This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). |
| 93 | +For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or |
| 94 | +contact [[email protected]](mailto:[email protected]) with any additional questions or comments. |
0 commit comments