Use Git for the first time today using git push times wrong
No refs in common and none specified; Doing nothing.
Perhaps you should specify a branch such as ' master '.
Fatal:the remote end hung up unexpectedly
Error:failed to push some refs to ' ssh://[email protected]/adsailer.git '
Haha, please don't panic. This is git can't find the version you're submitting.
1 commit git content git commit-a
2 Create. Gitignore put the ignored files
Example
. idea/*
runtime/*
. Ds_store
git Add. Gitignore
git Add.
Git commit-a
3 Git push-u Origin master Yes
Two Create a library
mkdir "directory Name" #创建目录.
Git–bare init #这样就创建完必一个空库. No more cloning directories.
Finally, the Git directory that you create in general is ended with ". Git". Well, there's nothing mysterious about that.
Tri-Fetch library file
git clone xxxx://Address
Git can fetch libraries based on different protocols. For example, file, HTTP, git and so on as long as the support can be provided. For example, use a local file to fetch the library.
git clone file:///home/viweei/src/xxx.git
Iv. Submission of documents
Git is no more complicated than SVN when extracting files, adding files, and deleting files. It was only when I started to use it that I was making mistakes.
Add File
When extracted from the library, add a new file FUCK.txt. and add it to the library.
Touch fuck.txt #创建 fuck file.
git add * #这里的 "*" is just a wildcard character and can be used directly with a filename.
Git commit–m "Fill in the extracted logs here"
A simple two-step process to extract the files into a local repository, similar to SVN. But a little different is when the commit is executed, VI displays the submission information
Start with Git small problem Solving Memo