microwatt: Added link to YouTube tutorial.
[libreriscv.git] / HDL_workflow / git_checklist.mdwn
index 0cea45a27c1909627a0aa15542ce2da70b7df7df..b1260178f6011882a7f42e8a5344c728d34747aa 100644 (file)
@@ -1,59 +1,49 @@
-[!] *mepy: Working in progress* [!]
-
 # git checklist
 
-when using git this is a reminder of commands to run and best practices
-
-## How does working with git looks like
-- You download a directory with project files in it
-- Modify some files, add others
-- Upload your work so other can take advantage of it
-
-In git you do this by
-- *Cloning* a repository (aka downloading stuff)
-- *Committing* your local changes (aka you "take note" of what you did. e.g. modified some files, added new files, deleted some files and so on)
-- *Pushing* your work online (aka uploading online)
-
-## Cloning
-(optional) `cd ` + somewhere in your disk
-
-`git clone ` + repo url
-
-## Making changes
-// You know what to do
-
-## Committing
-`git add` + files you want to "take note" of.
+When using git this is a reminder of commands to run and best practices  
+If you are very new to git, you would want to read [a really quick intro to git](/HDL_workflow/git_intro) first.
 
-E.g. `git add test.png` will take note of the “test.png" file for when you will want to commit your work. (Committing your work is like saving in a videogame. When you are good with what you have done, you save the stage of your "enjoyment").
+## what to do if you want to modify some pages
 
-When committing you are required to add a comment to your "save file" (commit).
-Like "I added the test.png file".
+Here is the checklist for making changes.
 
-## Pushing
-When you are done committing all your stuff, you want to share it with other. So you push on the remote repository (directory).
+[[!template id=note text="""If you do not intend to complete
+the work right the way through to "git push" immediately (at least by the end
+of the day), or do not "have time", reconsider and find a way to make the work
+smaller. If unsure, ask on the mailing list."""]]
 
-So you just `git push`.
+* run `git pull`
+* edit files, making sure only one “purpose"
+* save them
+* run unit tests and make sure they pass
+* fix errors
+* run `git status | more`, review the output
+* run `git diff`, review the output
+* run `git commit -a -m 'useful description' `
+* run `git pull`
+* run `git push`
 
+# Troubleshooting
+## [[!toggle  id="conflict" text="""what to do if "git pull" results in conflict"""]]
 
-### Notes 1
-Pay attention to:
-- what you modify in the repository
-- what files you add to your commit
-- when pushing, what are you actually pushing
+[[!toggleable  id="conflict" text="""
+* to be done
+* if you are still unsure what to do please ask for advice on IRC or the
+mailing list
 
-### Notes 2
-When doing `git commit` best thing to do is to add ` -m "<comment here, without brackets>"`
+[[!toggle id="conflict" text="hide"]]
+"""]]
 
-Like this: `git commit -m "added test.png"`.
+## [[!toggle  id="add" text="""what to do if you want to add files."""]]
 
-If you omit the -m option, a text editor will appear to let you insert a commit message. Sometimes is useful to let git open the editor. e.g. for long comments or comments with quotes in it.
+[[!toggleable  id="add" text="""
+* to be done
+* if you are still unsure what to do please ask for advice on IRC or the
+mailing list
 
-If `vim` editor opens (you get stuck into something you do not know how to exit from), remember:
-- type `i` to "insert text".
-- when you are doing typing some text, press the esc key on the keyboard
-- if you want to save the comment/text, press `w` (means "write")
-- to quit, press `q`
-You are done. 
+[[!toggle id="add" text="hide"]]
+"""]]
+---
 
-To quit without saving/writing: `q!` (e.g. you want to exit)
+this one, `git status` is very important, to check files that should have
+been added but have not.