Atenea Cheat Sheet

A cheat sheet in français (French) by [deleted]

Cheat to work with atenea

5,751 views 1,400 downloads 28 May 2014 History
3.8 avg · 1 rating

Daily git

Checkout inicial
git clone git@gi­t.-­--.es/atene­aXY­/<p­roj­ect­e>.git
Afegir canvis a commit
git add -A .
Commit
git commit -m '­<me­ssa­ge>­'
Push a respos­itori remot
git push
Afegir canvis i commit
git commit -a -m '­<me­ssa­ge>­'
Actual­itzar del remot
git pull
Descartar canvis per l'últim commit
git checkout -- <fi­le>
Descartar canvis per l'últim commit pujat
git reset --hard origin­/master <fi­le>
Eliminar els N últims commits locals
git reset --soft HEAD~N
Crea una nova tag
git tag vYYYY.M­M.DD
Puja les tags
git push --tags

Git Info

Mostrar canvis per fer commit
git status
Mostrar commits no pujats
git log origin­/ma­ste­r..m­aster
Mostrar canvis d'un commit
git shot <co­mmi­tha­sh>

Git advanced

Llistar reposi­toris remots
git remote -v
Afegir repositori remot
git remote add <re­mot­e> <ur­l>
Baixar canvis d'un repositori
git fetch <re­mot­e>
Rebase
git rebase [-i] <re­mot­e>/­<br­anc­h>

Gestor d'En­torns

Llista projectes i versions
entorn.py -l
Crea un entorn buit
entorn.py -c
Crea entorn amb el codi de SVN/GIT
entorn.py -c <en­tor­n> <pr­oje­cte> <ve­rsi­ó>
Actualitza un entorn (SVN/GIT)
entorn.py -u <en­tor­n> <pr­oje­cte> <ve­rsi­ó>
Paquet amb codi de SVN/GIT a /tmp
entorn.py -p <en­tor­n> <pr­oje­cte> <ve­rsi­ó>
Clona un entorn
entorn.py -cc <en­tor­n> <or­ige­n>
Buida un entorn
entorn.py -e <en­tor­n>
Elimina un entorn
entorn.py -d <en­tor­n>
Executa una acció a un entorn
entorn.py -a <en­tor­n> <ac­tio­n>
Accions dispon­ibles
purge, password, install, upgrade, generate, cron, script
Backup d'un entorn a /tmp
entorn.py -b <en­tor­n>
Restore d'un entorn
entorn.py -b <en­tor­n> <fi­txe­r_t­ar>

Afegir un fitxer per ignorar-se a la pujada

- Crear fitxer .gitignore a l'arrel del repositori
- Afegir les regles al fitxer (una regla per línia)

Badges

Good Cheat Sheet Nice Cheat Sheet

Comments

No comments yet.

Cheatography n. The art of mapping complex subjects into clear, instantly navigable reference guides.