Note: This is a template README used in the talk.
Checkout the slides for context.
Unboxing GitHub
Lecture notes for Unboxing GitHub.
Index
Formatted Text
Git & GitHub
-
What’s Git?
Git is a distributed, version-control-system (VCS) for tracking changes in source code.
It was created by Linus Torvalds (= creator of Linux) to manage the Linux Kernel source code. -
What’s Github?
GitHub allows you to host your content (probably source code) on the internet, allowing you to manage it using Git.
So, Git is the tool that allows you to manage several versions of a software, and GitHub gives you a website where you can post your work online, and manage it using Git.
-
What’s in it for you?
Let’s say, you want to write lecture notes for your class. Each lecture consists of a vast number of equations, tables, graphs, diagrams, simulations, code and obviously, formatted text. You want to update these notes as you go along the course. You also want to allow the reader to access only a certain portion of the notes (eg. Lec1,2,…) if he wants to.
This is exactly what we will tackle in today’s talk.
Code
- Python
#!/usr/bin/env python3
import re
text = '''
abc1234!
'''
pattern = re.compile(r'(\bDoe\b)')
matches = pattern.finditer(text)
for match in matches:
print(match)
- JavaScript
const math = {
sqrt(x){
return Math.sqrt(x);
},
square(x) {
return x ** 2;
},
cube(x){
return x ** 3;
},
rms(x,y){
return Math.sqrt(0.5* (x**2 + y**2));
}
}
- Generic
>> If no language is mentioned, no syntax highlighting takes place.
Everything is printed out as it is.
Maths
LaTex Equations
$e^{i \pi} = -1$
$x = a + b, y = a - b$
$$a^2x + bx + c = 0$$
$$\begin{vmatrix}a & b\\
c & d
\end{vmatrix}=ad-bc$$
Option1: Jupyter Notebooks
Option2: The GitHub Way
Tables
Step | Explanation | Example |
---|---|---|
clone | Create a local copy of the repository | git clone https://github.com/CRTejaswi/Test.git |
pull | Update changes from GitHub | git pull |
status | Check for changes in file(s) | git status |
add | Add files to be updated | git add . |
commit | Record file changes in local database | git commit -m 'Updated README' |
push | Update changes to GitHub | git push origin master |
AV Content
Graphs/Diagrams/Simulations/Videos …