From b671d5403b2747a2be60ffe6b9e7a9db36c2f1a9 Mon Sep 17 00:00:00 2001 From: "Rico Sta. Cruz" Date: Mon, 16 Feb 2015 17:43:14 +0800 Subject: [PATCH] Update vitamins --- micronutrients.md | 10 ++++++---- sh.md | 27 ++++++++++++++++++++++++--- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/micronutrients.md b/micronutrients.md index e4f46163e..4f4fe9669 100644 --- a/micronutrients.md +++ b/micronutrients.md @@ -50,14 +50,16 @@ layout: default * Major benefits: bone health * Fat-soluble -### Vitamin B12 - -### Vitamin B6 - ### Thiamin (Vitamin B1) ### Riboflavin (Vitamin B2) +### Niacin (Vitamin B3) + +### Vitamin B6 + +### Vitamin B12 + ### Potassium ### Omega 3 diff --git a/sh.md b/sh.md index 357836dda..c40df61f3 100644 --- a/sh.md +++ b/sh.md @@ -1,5 +1,5 @@ --- -title: Shell scripting +title: Shell scripting (bash) layout: default --- @@ -210,7 +210,28 @@ or DIR="${0%/*}" ----------- +### Getting options -* http://wiki.bash-hackers.org/ + while [[ "$1" =~ ^- && ! "$1" == "--" ]]; do + case $1 in + -V | --version ) + echo $version + exit + ;; + -s | --string ) + shift; string=$1 + ;; + -f | --flag ) + flag=1 + ;; + esac + shift + done + if [[ "$1" == "--" ]]; then shift; fi + + # compact + while [[ "$1" =~ ^- && ! "$1" == "--" ]]; do; case $1 in + esac; shift; done + +* http://wiki.bash-hackers.org/ * http://wiki.bash-hackers.org/syntax/shellvars