Skip to content
Snippets Groups Projects
README.md 2.66 KiB
Newer Older
Bourdel Laurent's avatar
Bourdel Laurent committed
Source Package for Embedded Linux Lab

Command line instructions

Bourdel Laurent's avatar
Bourdel Laurent committed
0/ Create SSH keys for rights access on GitLab INSA account in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
cmdline : ssh-keygen
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Generating public/private rsa key pair.
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Enter file in which to save the key (/home/user/.ssh/id_rsa):
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Enter passphrase (empty for no passphrase):
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Enter same passphrase again:
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Your identification has been saved in id_rsa.
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Your public key has been saved in id_rsa.pub.
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
1/ Add public key on GitLab INSA account on web browser
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Display your public key : cat ~/.ssh/id_rsa.pub
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Copy text and paste it to GitLAB INSA (Profile/Settings/SSH keys)
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Zip .ssh folder and send by mail your secure key for future use 
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
2/ Clone Teacher Repo in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Clone repo in your home
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
git clone ssh://git@gitlab.insa-rennes.fr:16022/EmbeddedLinux_Group/EmbeddedLinux_UDOO-NEO.git
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Go inside folder created : cd EmbeddedLinux_UDOO-NEO
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
3/ Config your git ID in terminal windows
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
git config --global user.name "Name SurName"
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
git config --global user.email "surname.name@insa-rennes.fr"
(info stored in ~/.gitconfig)
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
4/ Open your GitLab INSA account on web browser
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
https://gitlab.insa-rennes.fr/
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Ask Teacher to add you member of group EmbeddedLinux_UDOO-NEO with Maintainer rights
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
5/ Create your Repo on GitLab INSA on web browser
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
"New Project" button
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Choose group "EmbeddedLinux_Group" (drop down menu Project path) 
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Name Project like "4CDTI-P2020-<YourName>-LabUdooNeo"
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
Add your co-worker as developer role (Settings/Members)
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
6/ Config origin-teacher & your origin repo in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed
git remote rename origin origin-teacher
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
git remote add origin ssh://git@gitlab.insa-rennes.fr:16022/EmbeddedLinux_Group/4CDTI-P2020-<YourName>-LabUdooNeo
Bourdel Laurent's avatar
Bourdel Laurent committed
git remote -v
Bourdel Laurent's avatar
Bourdel Laurent committed
7/ Push your local directory to your personal repo in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed
git status
Bourdel Laurent's avatar
Bourdel Laurent committed
git push -u origin --all
Bourdel Laurent's avatar
Bourdel Laurent committed
git push -u origin --tags
Bourdel Laurent's avatar
Bourdel Laurent committed
git status

Bourdel Laurent's avatar
Bourdel Laurent committed
9/ Check if your local repo is pushed on Gitlab repo on web browser
Bourdel Laurent's avatar
Bourdel Laurent committed

Check Activity, OK ?
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
10/ Submit your LAB codes in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

git add .

git status

Bourdel Laurent's avatar
Bourdel Laurent committed
11/ Commit your modification when needed in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

git commit -a -m "message to explain commit content"

or git commit -a
Bourdel Laurent's avatar
Bourdel Laurent committed
(vim command : 'i' to insert, 'ESC' to leave edit mode, ':wq' to save commit message)

Bourdel Laurent's avatar
Bourdel Laurent committed
12/ Push your modification on GitLab server in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

git push origin master

Bourdel Laurent's avatar
Bourdel Laurent committed
git log
Bourdel Laurent's avatar
Bourdel Laurent committed
git log -p
Bourdel Laurent's avatar
Bourdel Laurent committed
git log --stat

13/ Check on GitLab server "new activity" on web browser
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
14/ If Teacher updates repo,  in terminal window
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
get modification's historical from remote repo : git fetch origin-teacher master
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
check modifications by : git diff --name-only master origin-teacher/master
Bourdel Laurent's avatar
Bourdel Laurent committed

Bourdel Laurent's avatar
Bourdel Laurent committed
update (merge) modif by : git pull origin-teacher master
Bourdel Laurent's avatar
Bourdel Laurent committed

!!! Well Done !!!