Since the previous toss over SVN, although ultimately not successful, but also experienced, git get started is relatively simple.Create an initialization repository in a new directory: Git initgit Add Filegit add file2Git commit-m "Add Files"git reset--hard head^ (HEAD indicates the latest version, ^ represents the previous version ^^ represents the second versio
Install git under Windows
1. Download Git https://git-for-windows.github.io/
2. Installation
Installation: Click Next
In the "Configuring the Line Ending Conversions" option,First option: If it is a cross-platform project, install in Windows system, select;Second option: If it is a cross-platform project, install in Unix system, select;Third option: Non-cross-
pull5. Submit Codegit Add. Git commit-m "description" Git push origin MasterFAQs FAQThe 1.git pull code reported the following error:Error:your local changes to the following files would is overwritten by merge:Please, commit your changes or stash them before you can merge.This means that there is a conflict between the updated content and the locally modified c
Create a branchGit branch Create and switch to a new branchGit checkout-b Switch branchesgit checkout Merging branchesgit merge Merge is a merge of two branches, if you want to merge b_branch into the A_branch,The actual operation is to switch to A_branch first and then execute merge on A_branch.git checkout git merge ?Conflicts must be resolved if a conflict occurs in the merge.Git conflict resolution:。。。。。。。。。。。。。。。。。。。。。。。。。??
1 Installation
There are several implementations of the current version of Git for Windows, but we chose the Msysgit release, which is currently the best compatibility. Download Address: Http://code.google.com/p/msysgit/downloads/list
When the download is complete, double-click the installation file and follow the prompts to complete the installation of Git. Git
version library, and the log information provided by the user at the time of submission is repeatedly stored in the version history of each modified file.The drawback of the CVS serial bulk commit model is that when a bulk operation is interrupted for any reason (typical reasons include: network interruption, client panic, etc., the version of the library is often in an inconsistent state: the original should be all the storage of the file only part of the storage, it is likely that the latest
copy its corresponding clone command as shown inexecute the Clone command as follows:Project Androiddevtools on clone oschina.netOpen the androiddevtools item on the git.oschina.net, and copy its corresponding clone command as shown inexecute the Clone command as follows:Learning ExperienceIn the process of using git, generally only focus on the situation of single account, the work of the configuration is directly from their superiors to send a conf
+HAo3FXRitBqxiX1nKhXpHAZsMciLq8V6RjsNAQwdsdMFvSlVK/7XAt3FaoJoAsncM1Q9x5+3V0Ww68/eIFmb1zuUFljQJKprrX88XypNDvjYNby6vw/Pb0rwert/EnmZ+AW4OZPnTPI89ZPmVMLuayrD2cE86Z/il8b+gw3r3+1nKatmIkjn2so1d01QraTlMqVSsbxNrRFi9wrf+M7Q== [emailprotected]Global configurationThe configuration file for the cat ~/.gitconfig//git is. Gitconfig, which can be in the user's home directory (global configuration)Edit git config file $
point of the master Branch at the moment does not change:Now, we merge the work of the Dev branch onto the master branch, using git merge dev the command to merge the specified branch dev to the current branch master, and then view README.txt to see the latest commit of the dev branch:Now the branching situation is like this:In effect, the merge is done by pointing master directly to the current commit of Dev.Delete BranchAfter you merge the branches
Branch management policies
Typically, when merging branches, GIT uses patterns when possible, Fast forward but in this mode, the branch information is discarded after the branch is deleted.If you want to force the mode to be disabled, Fast forward git will generate a new commit at merge, so you can see the branching information from the branch history.Here'
This is a creation in
Article, where the information may have evolved or changed.
Using Gogs to build a private git Management Server
[TOC]
Because there are many procedures need to manage, the company, home, go out, a number of modified procedures need to copy to copy, it is easy to cause file mismatch, merger difficulties and other issues. So plan to build a version of the server, can upload and dow
New label git tag default HEAD , or you can specify a commit IDeg. git tag v0.9git tag v1.0 31aa59cgit tag Git tag-s View Tagsgit tag View all tags git show see a tag messageDelete a labelGit tag-d Push local tags to remote Git push Origin
Turn from: http://www.cnblogs.com/eddy-he/archive/2012/03/08/git_ignore_file.html
Software version:Operating system: ubuntu10.04Kernel versions: Linux version 2.6.32-36-genericgit versions: Git version 1.7.0.4
Directory:1. Introduce2. Global and Local2.1 Global2.2 Local3. Grammar4. Examples5. Reference materials
1. Introduce
There are files that we don't want to join and don't need to be added to Git
Master is the main branch of the project, points to the project version, head is the latest version of the main branch of the project, pointing to the main line namegit checkout-b Dev//Create the Dev branch and switch to the branch, equivalent to:Git branch Dev//Create a branchgit checkout Dev//Switch BranchesGit branch//View Current Branchgit merge Dev//switch to the other, then merge the Dev branch into the current branchgit branch-d Dev//Remove Dev Branchgit log--graph--pretty=noline--abbrev-
Code management in the general development process
1. Download the code from the repository
git clone ssh://[email protected]192.168.1.3: 29418/mustang-web
2. Open a new branch for a feature (e.g. Instance-lanuch)
CD Mustang-web
Git checkout-b instance-lanuch
One sentence: Each time from master synchronization code, it
Learn the notes from the Liaoche Teacher's git tutorial to review them later. ★★★★★ Create, merge, and delete branches. ★ Create Branch git branch branchname--------Create a branch git checkout branchname-----Switch to Branch The above two commands can be combined as: Git checkout-b branchname Create and switch to br
There are multiple ways to navigate to the Web management interface. If you want to generate a web application in Visual Studio. NET 2005Program, You canWebsiteSelectASP. NET ConfigurationTo open the web site management tool. If you want to develop a web application outside Visual Studio. NET, you can directly navigate to the web site
First, delete the local labelIf the label is wrong, you can delete it:git tag-d v0.1Because the created labels are stored only locally, they are not automatically pushed to the remote.Therefore, the wrong tag can be safely deleted locally.Second, push the labelIf you want to push a tag to a remote, use the command GIT push Origin git push Origin v1.0Or, all-in-one push is not yet pushed to the remote local
This is a created
article in which the information may have evolved or changed.
Goal:
1. The Golang official has moved the URL of the package following its own project Git code uploaded to the project source.
2. Make or modify the differentiated fork package to follow your own project Git code is uploaded to the project source.
Solution:
Scenario 1. Third-party Package
Recently, users git found that it is really good to use, recently done some finishing summary, found some very good information, collected here, for forgetting.Git getting started is quite simple, before some of the article, about git, but are some blunt operation, and did not systematically learn and use it. Some recent experience tells me, do not fear new things, as long as adhere to learn and tolerant of
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.