Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
COURS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ainas ImeneZahoua
COURS
Commits
ac15443d
Commit
ac15443d
authored
1 year ago
by
FILIPPONE Jerome
Browse files
Options
Downloads
Patches
Plain Diff
Upload New File
parent
c15323c0
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
UE701/SEMESTRE_1_2023-24/EXERCICES/sujet_exercice.txt
+129
-0
129 additions, 0 deletions
UE701/SEMESTRE_1_2023-24/EXERCICES/sujet_exercice.txt
with
129 additions
and
0 deletions
UE701/SEMESTRE_1_2023-24/EXERCICES/sujet_exercice.txt
0 → 100644
+
129
−
0
View file @
ac15443d
************ PARTIE A ************
sur le serveur GITLAB :
- créer un projet nommé "projet"
- créer le fichier changelog.txt dans la branche principale MAIN
- éditer le fichier changelog.txt pour qu'il contienne cette 1ère ligne "version 1.0 : première version"
- créer 2 branches à partir de la branche principale MAIN : DEV et TEST
- créer 2 branches à partir de la branche principale DEV : DEV1 et DEV2
- créer puis supprimer une branche DEV3
************ PARTIE B ************
//sur sa machine :
//ouvrir un terminal (ou console X) et préparer le répertoire de travail²
mkdir ~/TP_GIT
cd TP_GIT
mkdir DEV1@paris
mkdir DEV2@nancy
mkdir DEV@metz
mkdir TEST@strasbourg
mkdir FONCTION1
//récupérer les fichiers sf1a.c et sf1b.c du gitlab dans le répertoire FONCTION1
//les fichiers sont dans https://gitlab.univ-lorraine.fr/filippon1/cours/main/UE701/SEMESTRE_1_2023-24/EXERCICES
//récupérer le script profile.sh du gitlab dans le répertoire ~/TP_GIT
//le fichier est dans https://gitlab.univ-lorraine.fr/filippon1/cours/main/UE701/SEMESTRE_1_2023-24/EXERCICES
//lancer le script profile.sh
cd ~/TP_GIT
source profile.sh
//vérifier avec la commande alias que le script a fonctionné
//configuration de GIT
git config --global user.email "votre_email"
git config --global user.name "votre_pseudo"
more ~/.gitconfig
//tapper CTRL-C pour sortir
//augmenter la durée du mise en cache des identifiants (par défaut 15min)
git config --global credential.helper "cache --timeout=7200"
//créer les dépôts distants pour chaque environnement DEV1 et DEV2
dev1
DEV1@paris >git clone https://gitlab.univ-lorraine.fr/VOUS/projet.git
DEV1@paris >cd projet
projet >git remote add origin https://gitlab.univ-lorraine.fr/filippon1/projet.git
//si existe déjà, on continue
~ >dev2
DEV2@nancy >git clone https://gitlab.univ-lorraine.fr/filippon1/projet.git
//... pareil pour DEV et TEST...
************ PARTIE C ************
//EN TANT QUE DEVELOPPEUR DEV1, je prépare la sous-fonctionnalité 1a :
~ >dev1
DEV1@paris >cd projet/
DEV1@paris >ls
projet >git branch
projet >git branch -a
projet >git checkout DEV1
projet >cp ~/TP_GIT/FONCTION1/sf1a.c .
projet >gcc -o sf1a.o -c sf1a.c
projet >gcc -o sf1a sf1a.o
projet >./sf1a
projet >git add sf1a*
projet >git commit -m "ajout de sf1a"
projet >git push -u
************ PARTIE D ************
//EN TANT QUE DEVELOPPEUR DEV2, je prépare la sous-fonctionnalité 1b :
projet >dev2
DEV2@nancy >cd projet/
projet >cp ~/TP_GIT/FONCTION1/sf1b.c .
projet >git branch
projet >git checkout DEV2
projet >gcc -o sf1b.o -c sf1b.c
projet >gcc -o sf1b sf1b.o
projet >./sf1b
projet >git add sf1b*
projet >git commit -m "ajout de sf1b"
projet >git push -u
************ PARTIE E ************
//EN TANT QUE DEVELOPPEUR DEV, je fusionne le travail de DEV1 et DEV2 et je prépare un build adapté à l'architecture processeur réelle:
projet >dev
DEV@metz >cd projet/
projet >git branch
projet >git branch -a
projet >git checkout DEV
projet >git pull
projet >ls
projet >git merge origin/DEV1
projet >ls
projet >git merge origin/DEV2
projet >ls
//construire un nouveau fichier sf1.c en concaténant les 2 fichiers sf1a.c et sf1b.c avec un éditeur
projet >gcc -o sf1.o -c sf1.c
projet >gcc -o sf1 sf1.o
projet >./sf1
projet >rm sf1
projet >rm sf1.o
projet >ls
projet >gcc -o sf1.o -c sf1.c -march=native
projet >rm sf1.o
projet >gcc -o sf1-build.o -c sf1.c -march=native
projet >gcc -o sf1-build sf1-build.o
projet >./sf1-build
projet >git add sf1-build
projet >git push -u
projet >git commit -m "ajout de sf1-build"
projet >git push -u
projet >git pull
************ PARTIE F ************
//EN TANT QUE TESTEUR TEST, j'exécute le programme sf1-build préparé par DEV pour le vérifier:
projet >test
TEST@strasbourg >cd projet/
projet >git branch -a
projet >git checkout TEST
projet >ls
projet >git pull
projet >git branch -a
projet >git merge origin/DEV
projet >ls
projet >./sf1-build
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment