This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# See here: https://developer.atlassian.com/blog/2016/02/best-way-to-store-dotfiles-git-bare-repo/ | |
git clone --bare https://github.com/aos/dotfiles.git $HOME/.cfg | |
function config { | |
/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME $@ | |
} | |
mkdir -p .config-backup | |
config checkout | |
if [ $? = 0 ]; then | |
echo "Checked out config."; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Relational (SQL) Database Normalization | |
Normalization: | |
- Every non-key attribute must provide a fact about the key, the whole key, and nothing but the key. (3NF) | |
- Reduction and elimination of redundant data | |
- Example: A post in a blog, each post will have an author e-mail but if you needed to update the e-mail address of 'Andrew', you should only have to do it once (and not for each post). | |
Examples of un-normalized databases: | |
(https://en.wikipedia.org/wiki/Database_normalization) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Database server using node and express | |
'use strict' | |
const express = require('express'); | |
const app = express(); | |
const db = {}; | |
app.get('/set', (req, res) => { |