# Library Carpentry, Library and Knowledge Services, NHS
Schedule: [https://marcocrotti.github.io/2021-06-22-hee-online/](https://marcocrotti.github.io/2021-06-22-hee-online/)
Zoom room: [https://carpentries.zoom.us/my/carpentriesroom1](https://carpentries.zoom.us/my/carpentriesroom1)
Code of Conduct: https://docs.carpentries.org/topic_folders/policies/code-of-conduct.html
Library Carpentry: https://librarycarpentry.org/
Portable Git Bash: https://git-scm.com/download/win
Day 1 HackMD Notes: https://hackmd.io/@hchughtai/rJuMTE0ju
Day 2 HackMD Notes: https://hackmd.io/@ostephens/Skd5uyW2u
---
## Introduction to Git and Github
### Git vs Github
* Git is a "version control" system. Version control systems is a way of tracking changes to documents and files over time. Git was designed specifically for version control on code being written by multiple people over time
* GitHub is a website where you can share and access "git repositories" - there are other options for sharing git repositories (e.g. GitLab, GitBucket, ...) but GitHub is probably the most widely used
### Basic git commands
* `git init` : Initialise git repository
* `git status`: Print summary of repository status
* `git add filename-here`: Track changes made to a directory
* `git commit -m "your commit message here": `Save the changes made
*Note that to version control your files using git there are two key steps. First you use `git add` to track the changes made, then you use `git commit` to save all of the changes in one snapshot.*
### Using github
* `git remote add origin repository-web-address-here`: add a remote repository. This will sync with your local repository using the following commands.
* `git push -u origin main`: push local changes to the remote repository. After running this command once you can push changes using simply `git push`.
* `git pull`: pull changes from the remote repository to the local repository
### Monitoring changes
* `git diff`: See the changes made since the last commit
* `git log`: See a list of the previous commits
Exercise: Visualising Git
1. try to come up with synonyms for what the commands are doing.
1. try to express git commands in a non ‘git’ way
1. try to visualise what commits are doing to your repository
#### Breakout Room 1
#### Breakout Room 2
#### Breakout Room 3
#### Breakout Room 4
#### Breakout Room 5
#### Breakout Room 6
---
## OpenRefine
Once you've downloaded OpenRefine, make sure you "unzip" or "extract all" from the folder to get the uncompressed folder on your computer
We know that there can sometimes (but not always) be problems running OpenRefine from a network drive or remote desktop - so generally it's safest to extract the files to your local drive.
Data file: https://github.com/LibraryCarpentry/lc-open-refine/raw/gh-pages/data/doaj-article-sample.csv
*You need to download this file to your computer, not open in the browser or in Excel*. To do this: right click or control click in order to save the file (in Chrome and Firefox, right click and select "Save link as…"; in Safari, right click and select "Download linked file")
Places to get support with OpenRefine:
* OpenRefine official documentation https://docs.openrefine.org/
* The OpenRefine Wiki: https://github.com/OpenRefine/OpenRefine/wiki
* The OpenRefine mailing list and forum: http://groups.google.com/d/forum/openrefine
* LibraryCarpentry OpenRefine Lesson: https://librarycarpentry.org/lc-open-refine/
* The 'Free your metadata' site: http://freeyourmetadata.org/
Library specific examples and tutorials:
https://docs.google.com/document/d/12njJBX6TcxniI7pub6MQkWXsa5uhV4xnbaHHPMmRgFA/edit?usp=sharing