Cocos2d-x version 3.6 continuous view version control, cocos2d-x3.6

Source: Internet
Author: User

Cocos2d-x version 3.6 continuous view version control, cocos2d-x3.6

For future development and management, version control must be used for source code development. Of course we chose git for version control.

If you enter git on the terminal and prompt that it is not a command, it means that your machine has not installed the git tool. So install one. Baidu has many installation tutorials.

Well, delete res under Resources first. This directory is useless. You can delete it in Xcode and choose to drop it into the recycle bin. You can also delete unnecessary directories, such as proj. linux, proj. win8.1-universal, proj. win32. We probably only use the ios version and then port it to the Android platform, so we have deleted all of this.

Then, cd the terminal to the LLK root directory and initialize a git local repository:

git init

The prompt Initialized empty Git repository in xxxx indicates that the repository is successfully Initialized.
Terminal-typed command:

ls -al

You can see an additional. git directory. This is the git repository created.

To avoid adding unnecessary files to version tracing, you also need to create a description file to tell git which files should not be added to version control. This description file is. gitignore. As the name implies, objects are ignored.

Terminal mvim. gitignore. Here we use macvim to create a. gitignore file. You can use any text editor to create this file.

What do you want to write in it? You don't need to add it to a version control file or directory. I wrote one for your reference.

The bottom is the cocos2d/directory, because this is part of the cocos2d-x engine, we write the game is not the Assembly to modify the source code, so the entire Engine Directory is not added to version control.

Then, run the command on the terminal.

git add .

The file is added to the version library.

Then, run the following command:

git status

You can see which files are added.

Then, submit it to the local repository to generate a submission record.

Git commit-m "initialize the Connection check Project"

After you press enter, the first submission is completed.

Then you can view the submission record and run the following command on the terminal:

git log

You can see the submitted record and write comments for submission.

Okay. If you use xcode to open this project, restart xcode. Now xcode has a built-in git tool. You need to enable this option to enable source code control.

Disable xcode and restart it. Open the LLK project again and modify the source code and add a comment. You can see that an M Symbol is displayed, indicating that it has been modified.

Well, there are some usage instructions, which will be discussed later

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.