Brian Fraser | GitLab Workflow: Merge Request with Android Studio / IntelliJ @DrBFraser | Uploaded 7 years ago | Updated March 01 2023
Using the GitLab workflow to do some changes to a project with Android Studio (same as IntelliJ).
Overview:
- Create a GitLab issue
- Assign issue to self and create branch
- Checkout branch in Android Studio / IntelliJ
- Do coding, commit and push.
- In GitLab, create Merge Request, and delete branch
- In Android Studio switch to master, pull.
Related Videos:
- Setting up a GitLab project with Android Studio: https://www.youtube.com/watch?v=zprAqNffSjk
- Putting a button onto an Android Studio activity: https://www.youtube.com/watch?v=aE5f1tV5nU4
1.Setup
Create new Android Studio project
Create GitLab project;
Commit/push empty project.
2. Create GitLab issues:
“Add random number generation”
Assign issue to self
Create local branch via GitLab
3. In Android Studio, switch to branch:
Update project from Repo
Click the “Git: master” button on status bar bottom right:
Under remote, select the new branch you created
Then select “Checkout as new local branch”
4. Work:
Write code;
Commit/push (x2)
5. Create Merge Request:
On GitLab’s Merge Request page, select “Create Merge Request” for your recent push.
Select “Remove source branch when merge request is accepted.”
6. Accept Merge Request:
On GitLab’s Merge Request page
May be done by someone else if a code review is required.
View in Gitlab: Repository: Network
7. Set Android Studio Ready for Work:
Switch to master branch (bottom right, select Local Branch “origin/master”)
Pull or Update Project
Version Control: View log
Using the GitLab workflow to do some changes to a project with Android Studio (same as IntelliJ).
Overview:
- Create a GitLab issue
- Assign issue to self and create branch
- Checkout branch in Android Studio / IntelliJ
- Do coding, commit and push.
- In GitLab, create Merge Request, and delete branch
- In Android Studio switch to master, pull.
Related Videos:
- Setting up a GitLab project with Android Studio: https://www.youtube.com/watch?v=zprAqNffSjk
- Putting a button onto an Android Studio activity: https://www.youtube.com/watch?v=aE5f1tV5nU4
1.Setup
Create new Android Studio project
Create GitLab project;
Commit/push empty project.
2. Create GitLab issues:
“Add random number generation”
Assign issue to self
Create local branch via GitLab
3. In Android Studio, switch to branch:
Update project from Repo
Click the “Git: master” button on status bar bottom right:
Under remote, select the new branch you created
Then select “Checkout as new local branch”
4. Work:
Write code;
Commit/push (x2)
5. Create Merge Request:
On GitLab’s Merge Request page, select “Create Merge Request” for your recent push.
Select “Remove source branch when merge request is accepted.”
6. Accept Merge Request:
On GitLab’s Merge Request page
May be done by someone else if a code review is required.
View in Gitlab: Repository: Network
7. Set Android Studio Ready for Work:
Switch to master branch (bottom right, select Local Branch “origin/master”)
Pull or Update Project
Version Control: View log