0% found this document useful (0 votes)
57 views3 pages

Hands-On Lab Guidelines

1. The document provides guidelines for completing hands-on labs and submitting assignments for an object-oriented language and theory course on Bitbucket, including committing and pushing work regularly and resolving any conflicts that arise. 2. It outlines tutorials for learning Git and Bitbucket and provides the naming convention for creating private repositories on Bitbucket for assignments. 3. Step-by-step instructions are given for cloning repositories, creating and switching branches, committing changes, pushing to remote repositories, pulling changes, and resolving any conflicts that may occur.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
57 views3 pages

Hands-On Lab Guidelines

1. The document provides guidelines for completing hands-on labs and submitting assignments for an object-oriented language and theory course on Bitbucket, including committing and pushing work regularly and resolving any conflicts that arise. 2. It outlines tutorials for learning Git and Bitbucket and provides the naming convention for creating private repositories on Bitbucket for assignments. 3. Step-by-step instructions are given for cloning repositories, creating and switching branches, committing changes, pushing to remote repositories, pulling changes, and resolving any conflicts that may occur.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Object-Oriented Language and Theory

Hands-on lab guidelines


1. You have to follow the instructions in the hands-on lab and complete all exercises. If you
can not finish them at class, please do it at home.
2. Commit and push all your results as soon as possible (when you finish, even at class) to
bitbucket.org (through git) BEFORE 9PM of the day before our weekly class.
3. Git and Bitbucket tutorial:
a. Git tutorial:
i. Learn Git commands in https://git-scm.com/book/en/v2
ii. https://git-scm.com/docs/gittutorial
iii. https://www.atlassian.com/git/tutorials
iv. https://www.youtube.com/watch?v=HVsySz-h9r4&list=PL-
osiE80TeTuRUfjRe54Eea17-YfnOOAx
b. Bitbucket tutorial:
i. https://www.atlassian.com/git/tutorials/learn-git-with-bitbucket-cloud
ii. https://bitbucket.org/tutorials/bucket-o-sand
4. Guidelines to git/bitbucket.org to submit your assignment/mini-project:
a. Install Git (with optional tools: Source Tree, eGit for Eclipse…)
i. https://www.youtube.com/watch?v=HVsySz-h9r4
b. Create an account on https://bitbucket.org/
c. Create a private repository naming “IT3103.ClassID.2023.1.StudentID.StudentName”. If
you don’t follow this naming convention, your repository will be ignored.
d. Add lethihoa.hust@gmail.com, email TA) as a member of your repository, also add your
reviewer
e. Clone a repository, create a branch (the default and main one is master):

cd <local_working_folder>
git clone <repository_url>
cd <repository_name> /* e.g. OOLT.ICT.20212.StudentID.StudentName */
git branch /* let you know which branch you’rgit e working on */
git checkout -b <your_branch> /* create and switch to your new branch */

git

f. Commit and push after changing some resources:


cd <local_working_folder/repository_name>
git add -A /* -A: for all operations or . for without deletions in the current folder */
gitgit status /* check status of the stage */
git commit -m "Your comment for the update" /* commit with comment*/
git push origin <your_branch> /* push from local repo to remote repo */

After checking carefully the new branch code, the leader can go to the Bitbucket to Create merge request,
then Approve merge request to merge the code to the master branch.

g. Pull without conflicts


git stash /* run this command if you want to ignore your current change */

1
git pull origin <your_branch>
h. Pull and resgitolve conflicts
After you commit and push to the remote repository, if there is any conflict when creating merge request,
you need to resolve conflicts.
git checkout master
git pull origin master
git checkout <your_branch>
git rebase master
git add -A
git status
git rebase –continue

You need to resolve conflicts by checking the resources that have conflicts. There are both versions in the
resources so that you can observe and make decisions, e.g.
Having conflig:
<<<<<<< HEAD /* master branch in the remote repository */
suggestor.setClientId(clientID);
suggestion = suggestor.translate(input).replaceAll("-", " ");
======= /* your branch in the local repository */
suggestion = suggestor.translate(input);
>>>>>>> Your comment for the update
Merging (merge your local repository version with the replaceAll() method, remove the first
statement of the remote repository):
suggestion = suggestor.translate(input).replaceAll("-", " ");

Then continue, force to push the merged version to the remote repository
git push origin <your_branch> -f

https://tedu.com.vn/video/bai-1-gioi-thieu-tong-quan-ve-he-thong-quan-ly-version-vcs-155.html

Tạo

2
3

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy