The existing ID collection $set[' old_id ') contrasts with the ID set $set[' new_id ' from the foreground,
public function contrast_new_old_id(){ //从前台传来的id组 $checkids['id']=$this->input->post('id'); //根据逗号将$checkids['id']拆解,并形成新ID集合$set_new_id $set_new_id=explode(',', $checkids['id']); //从数据库中取得的现有的ID的集合$set_old_id $set_old_id=$this->m_checkout->acquire_old_id(); //print_r($set_old_id); //将$set_new_id 中的id一个个拿出来,在$set_old_id 中作对比。将在$set_old_id 中没有的ID存入数据库
warehouses, the same "object name" will exist.
Git can also determine whether the object content is correct by checking that the SHA1 hash value of the object's content is the same as the object name.
Summarize the Git object model, where the Blob object is all the entity files in the project, including source code, picture resources, XML configuration information, and so on. In particular, the Blob object records only the contents of the file, and information about the directory, name
Common scenarios: I want to synchronize some php files under/myweb, but I don't want to copy some log files in/myweb/log/because these files are too large, backup is meaningless. Now, if you want to avoid adding-exclude directly to a path, such as-exclude "./log"-exclude './log/file'Note: the directory path is relative to the folder you are backing up.Exclude specified directories or files during rsync backupTo exclude the specified directory, you can use the-exclude-from c
Tags: date () article card World ROM main function BSP memory Stored procedures can be used to improve the query efficiency of the database. Because it was compiled beforehand. is stored in memory, before each execution. It doesn't have to be newly compiled, so it's very efficient.A stored procedure is a set of SQL The collection of additions and deletions, assuming that a function in the program involves multiple operations on the database. Then you can compile the stored procedure beforehand.
-You can go in and see for yourself.
3. Two Dads (parent node)-You're right!
When you view a consolidated submission in history, you will see two parent nodes (different from regular submissions on the working copy). The first parent node is the branch you are in, and the second is the branch you merged with.
4. Merge conflict
At the moment I believe you have encountered a merger conflict and solved it. Usually edit the file, remove the
$ git diff--merge
diff--cc dummy.rb
index 5175dde,0
the options returned in the model. This new option has a suitable display string and a null value.
After all this has been done, we can open the browser. To add some items to the shopping cart, click on the Checkout link and you will see the new Payment page as shown in Figure 9.1:
It looks good. Of course, if you click on the Checkout button, you will be greeted with the following:
Unknown Action
No Actio
.------------------3. Viewing the current repository status--git status If you have only modified the no git addGit status tail line shows--no changes added to commit (use "git add" and/or "Git Commit-a")If only git add has no git commitGit status second line shows--changes to be committedIf the file you submitted for the first time is not displayed by git addChanges not staged for commit:(use "git add (use "Git checkout--Modified:readme.txtuntracked
(add, commit), WARNING:LF will is replaced by CRLF in XXXXThis is an issue caused by the automatic addition of line breaks (in Linux format), which can be set globally with the –global parameter
git Tag v1.0Make a v1.0 label for the current state.
git tagView history Tag Record
git branchTo view the current branch situation
git branch aCreate a new branch with the name a on the current basis
git Checkout aToggle Branch to a
git
example, E: \ svndemo \ wc1, right-click-> checkout, enter SVN: // localhost/trunk in URL of repository, in this way, we get a copy of work.
Make changes in the work copy and submit:
Open readme.txt, modify it, and right-click commit... to submit the modification to the version library. We can run it.
View the modifications:
Right-click readme.txt-> tortoisesvn-> show log, so that we can see all the submissions to this file. Right-click on ve
Q: How can I avoid synchronizing specified folders? -- Exclude
Rsync -- exclude files and foldersHttp://articles.slicehost.com/2007/10/10/rsync-exclude-files-and-foldersVery common: I want to synchronize/usr/boot/Under/, but I don't want to copy/proc/tmp folders.If you want to avoid a path, add -- exclude directly.For example, -- exclude "proc"-- Exclude 'Sources'Note: the directory path is relative to the folder you are backing up.Note: This path must be a relative path, not an absolute path.
E
.
Easy to remember, it can be divided into low-level input and high-level input. Note that each level is not necessarily transferred between adjacent levels. Cross-level transfer can be achieved through the Parameter options of the GIT command,
For example, common git checkout git reset git commit
Low level input
High level input
Working directory
Manually created
Git checkout
counteract a commit you've committed incorrectly.
Fix last Commit message
scene: you have a clerical error in the last commit message and have already executed git commit-m "fxies bug #42", but before git push you realize that the message should be "fixes bug #42 ″."
Method: git commit --amend Or git commit --amend -m "Fixes bug #42"
principle: git commit --amend is updated with a new commit and replaces the recent commit, which combines any modifications with the contents of the previous
:
Latency and throughput
The server returns directly
These techniques are roughly sorted according to the steps required to increase site traffic. For example, the application layer load balancing is the first thing to do (much earlier than the anycast). The first three technologies improve throughput and availability, but there are single points of failure. The remaining three technologies improve throughput while avoiding single points of failure.
To help us understand load balancing, let's
Why should there be branches, there are branches so that many people can be more efficient development. View branches, branch list
$ git Branch
* Master
administrator@young-pc MINGW64 ~/helloworld (Master)
There is only one branch, and then there is a * number in front of master, which represents the current branch. Create branch, switch branch git checkout-b
#创建并切换分支 $ git checkout-b feature-a switched t
1. Summary
Git is a branch development and trunk release. It is best to pull the new branch out of the basic master.2. Branch
Git branch-A # refer to all current branches.*Indicates the current branch.
Git branch P1 origin/MasterGit branch Dev origin/master # create a Dev branch, which is a remote branch master based on origin
Git checkout Dev # Switch to the dev Branch
Git branch-D Dev # Delete the dev Branch
Git push -- Set-upstream origin Dev # pus
command can view the modified file. To view the specific modification content, enter the following command:
git diff
The execution result is as follows:
Git diff, as its name implies, is to view difference. The displayed format is the common diff format for Unix.
If you only want to view the changes in the activity_main.xml file, run the following command:
git diff res/layout/activity_main.xml
The execution result is as follows:
3. Undo unadded changes:Git
course it is easier to write 100 ^ in 100 versions, so it is written as HEAD ~ 100.
2) version number
5. The git reflog command is used to record each of your commands.
6. git checkout-file modification in the workspace is all revoked.
Run git checkout -- readme.txtto cancel all modifications to the readme.txt file in the workspace. There are two situations:
Readme.txt has not been put into the tempora
Background:Versioning is critical for developers who have been using SVN (primarily TORTOISESVN) as a collaboration tool for teamwork. But the relevant open source project uses Git on GitHub. Due to the limitations of the project itself, very few people have modified common files and abandoned working directory local uncommitted changes. So there's a bit of ambiguity about Git's use. This blog post uses an example to explain how git discards uncommitted local modifications in working direcotry .
sections mentioned adding files to the repository in two-step execution:The first step git add is actually adding files to the staging area;The second git commit commit modification is to commit the contents of the staging area to the current branch, and the staging area will be emptied.Manage changesThis section is also to learn more about Git's working mechanism.For example, we make a modification to a file and then add: git add filenameThe file is then modified for the second time without ex
Very common situation: I want to sync some php files under/myweb, but do not want to copy some of the/myweb/log/inside the log files, because these files are too large, backup is meaningless. Now if you want to avoid a path directly add-exclude can be like-exclude "./log" –exclude './log/file 'Note: The directory path is relative to the folder backing up.Exclude specified directories or files during rsync backupTo exclude a specified directory, you can use the –exclude-from command on the client
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.