github basic usage in windows

1. create a new accout, create orginazation, create repo


2. install git in your local pc

Note: you can create ssh key to avoid username/password input for github operation

https://help.github.com/articles/generating-ssh-keys

https://help.github.com/articles/set-up-git


3. git clone https://github.com/elulian/CustomerSecurityManagementSystem.git

Note: failed to connect to github 443 windows/ Failed to connect to gitHub - No Error
check your git proxy setting:
git config --global http.proxy

Reset git proxy setting:
git config --global --unset http.proxy

set git proxy:
git config --global http.proxy ***@****:8080
git config --global https.proxy ****@****:8080
#git config --global http.sslverify false

4.git branch -a to list all the branches, normally we are working in the origin/master branch, so direclty add/change files


5. If you are using eclipse, you can simple use eclipse git gui, my suggestion, if you want to use git bash, you can use below commands:


5.1 git add command to track your changes in local repo
warning: LF will be replaced by CRLF in src/main/webapp/WEB-INF/web.xml.
In Unix systems the end of a line is represented with a line feed (LF). In windows a line is represented with a carriage return (CR) and a line feed (LF) thus (CRLF). when you get code from git that was uploaded from a unix system they will only have a LF.

5.2. git status/gitk to check your changes, git commit to local repo
Note: create mode 100644
The following flags are defined for the st_mode field:

       S_IFMT     0170000   bit mask for the file type bit fields
       S_IFSOCK   0140000   socket
       S_IFLNK    0120000   symbolic link
       S_IFREG    0100000   regular file
       S_IFBLK    0060000   block device
       S_IFDIR    0040000   directory
       S_IFCHR    0020000   character device
       S_IFIFO    0010000   FIFO
       S_ISUID    0004000   set UID bit
       S_ISGID    0002000   set-group-ID bit (see below)
       S_ISVTX    0001000   sticky bit (see below)
       S_IRWXU    00700     mask for file owner permissions
       S_IRUSR    00400     owner has read permission
       S_IWUSR    00200     owner has write permission
       S_IXUSR    00100     owner has execute permission
       S_IRWXG    00070     mask for group permissions
       S_IRGRP    00040     group has read permission
       S_IWGRP    00020     group has write permission
       S_IXGRP    00010     group has execute permission
       S_IRWXO    00007     mask for permissions for others (not in group)
       S_IROTH    00004     others have read permission

       S_IWOTH    00002     others have write permission
       S_IXOTH    00001     others have execute permission

5.3. git pull origin master to merge changes if require (git stash/stash pop, git reset --hard)

Note: for code merge, I am using kdiff3:

a. install kdf

b. git config --global merge.tool kdiff3

c. git config --global mergetool.kdiff3.cmd '"(kdiff3 installation path (C:\\Program Files (x86)\\KDiff3\\kdiff3)" $BASE $LOCAL $REMOTE -o $MERGED'

d. git mergetool


5.4. git push origin master to remote repo
Note: username/password: your github username/password
git config --global user.name [your github username]

git config --global user.password [your github password]

### GLM4 Library on Windows Installation and Usage For developers working with OpenGL Mathematics (GLM) version 4 under the Windows operating system, several steps are necessary to ensure proper setup and utilization of this powerful mathematics library. #### Installing GLM via Package Managers or Manual Download One approach is downloading directly from the official repository hosted at GitHub. Since no direct package manager support exists specifically tailored towards Windows like `apt` used in Linux environments[^1], manual download becomes a viable option: - Navigate to the [official GLM releases page](https://github.com/g-truc/glm/releases). - Choose an appropriate release based on requirements. - Extract files into a preferred directory within your project structure. Alternatively, using dependency management tools such as vcpkg can simplify installation processes significantly by handling dependencies automatically: ```bash git clone https://github.com/Microsoft/vcpkg.git cd vcpkg .\bootstrap-vcpkg.bat vcpkg install glm ``` This method ensures compatibility across different projects while maintaining ease-of-use during development phases. #### Incorporating GLM Into Projects Once installed through either means mentioned above, incorporating GLM headers requires adding paths pointing toward extracted directories when configuring build systems or IDEs settings accordingly. For CMake-based builds, consider including lines similar to these below depending upon chosen installation path: ```cmake find_package(glm REQUIRED) include_directories(${GLM_INCLUDE_DIRS}) target_link_libraries(your_project_name PRIVATE ${GLM_LIBRARIES}) ``` When utilizing Visual Studio solutions without external configuration scripts, manually specify include directories inside project properties panels before compilation begins. #### Basic Example Demonstrating Vector Operations Using GLM Below showcases how vectors operations might look implemented leveraging functionalities provided by GLM: ```cpp #include <iostream> #define GLM_FORCE_RADIANS #include <glm/glm.hpp> int main() { glm::vec3 vectorA(1.0f, 2.0f, 3.0f); glm::vec3 vectorB(-1.0f, -2.0f, -3.0f); std::cout << "Vector A + B = (" << vectorA.x + vectorB.x << ", " << vectorA.y + vectorB.y << ", " << vectorA.z + vectorB.z << ")" << std::endl; return 0; } ``` --related questions-- 1. How does one integrate GLM effectively with other graphics libraries? 2. What alternatives exist for managing packages besides VCPKG on Windows platforms? 3. Can you provide examples demonstrating advanced features offered by GLM beyond basic vector arithmetic? 4. Are there any notable differences between versions of GLM that could impact functionality?
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值