Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| # Backup | |
| docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql | |
| # Restore | |
| cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE | |
| SELECT table_name AS "Table", | |
| ROUND(((data_length + index_length) / 1024 / 1024), 2) AS "Size (MB)" | |
| FROM information_schema.TABLES | |
| WHERE table_schema = "alidb" | |
| ORDER BY (data_length + index_length) DESC; | 
| sshuttle -v -r username@hostip -x hostip 0/0 | |
| without output: | |
| sshuttle -v -r username@hostip -x hostip 0/0 >/dev/null 2>&1 | 
| import pandas as pd | |
| fileName = 'excelFile.xlsx' | |
| sheet1 = pd.read_excel(fileName, sheet_name = 'sheet1') | |
| sheet2 = pd.read_excel(fileName, sheet_name = 'sheet2') | |
| sheet3 = pd.read_excel(fileName, sheet_name = 'sheet3') | 
| # Example config file for ansible -- https://ansible.com/ | |
| # ======================================================= | |
| # Nearly all parameters can be overridden in ansible-playbook | |
| # or with command line flags. Ansible will read ANSIBLE_CONFIG, | |
| # ansible.cfg in the current working directory, .ansible.cfg in | |
| # the home directory, or /etc/ansible/ansible.cfg, whichever it | |
| # finds first | |
| # For a full list of available options, run ansible-config list or see the | 
| Exmaple log file: | |
| ```Log | |
| New Request 1 | |
| get user-id (Ref_8a28) | |
| update user history (Ref_7a27) | |
| send notification (Ref_6a26) | |
| user info updated (Ref_5a25) | |
| New Request 2 (Ref_4a24) | 
Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| #Trim spaces | |
| ali.rename(columns=lambda x: x.strip(), inplace=True) | |
| #Fill merged cells with upper head | |
| ali = mini.fillna(method='ffill', axis=0) | |
| #Replace nan with zero | |
| support['xx'] = support['xx'].replace(np.nan, 0) | 
| git filter-branch --force --index-filter "git rm --cached --ignore-unmatch filePath" --prune-empty --tag-name-filter cat -- --all | 
| pandoc -o output.md --extract-media=./ inputfile.docx |