Skip to content

2. Project management

To start the cours the first thing to be done is setting up git to update your own website and document weekly all the assigments.

Download and configure git

to download git you can do it in two ways firs one is in their webpage or you can do it using your terminal with ‘’‘sudo apt-get install git’‘’ to get sure that git has been installed correctly you can tipe in the terminal ‘’‘git –version’‘’.

git --version

The next step is to set up your git acount to your computer.

’‘’ git config –global user.name “your.username” git config –global user.email “your.email” ‘’‘

finaly its time to get the ssh key with ssh-keygen -t rsa -C "your.email" -f ~/.ssh/id_rsa_gitlab- the last part afer your email adress changes the name of the file in order to know wich is the ssk you are generating incase that you have more than one ssh i the designed folder and be able to recognise which is the one you have just generated.

Now its time to copy this ssh key to your gitlab acount. To put your ssh key go to edit profile and i tle left menu there is a place that says SSH KEY and there you can copy the ssh key remember to copy the public key is the one that ends with .pub

Clone your repository

It’s time to clone your repository, open the terminal and change directory to where you are going to copy the repository, once you are there in the git lab page (https://gitlab.fabcloud.org/academany/fabacademy/2022/labs/barcelona/students/your.name) copy the ssh clone URL and in your terminal (the correct direcoty) ‘’‘git clone git@gitlab.fabcloud.org:academany/fabacademy/2022/labs/barcelona/students/your-name.git ‘’‘

NOW YOU HAVE YOUR LOCAL ROPOSITORY!!!

Edit the local repository

I left the template that the lad gave to us as it is, just changing the ‘mkdocs.yml’ to change the site name, site description, site author and the color of the website (theme) primary and accent

add, commit, push

After modifing the documents in the text editor you prefer (in my case I use sublime text) in your local repository it’s time to update the online repository to update the web page.

To visualize the webpage localy before pushing all the files and be able to correct and modeify if necesary I istalled mkdocs.

Once mkdocs is installed and you want to see the changes you made in your files localy just go to the drectory where you have all the repository saved and open a terminal, send mkdocs serve, this will gives you back an adress where you can see the webpage already build.

In order to update the repository three steps are needed, fist one is to know which files have been edited with git status this will tell which are the files that have to be added with git add name.file there is the possibility to uplopad all the files with git add . but get sure that the files have the right size.

Now make a commit before pushing to make comment what chanhes you have make

git commit -m "your.comment"

It’s time to git push!!


Last update: June 29, 2022