Skip to content

Instantly share code, notes, and snippets.

View alphaolomi's full-sized avatar
🎯
Focusing

Alpha alphaolomi

🎯
Focusing
View GitHub Profile
@alphaolomi
alphaolomi / mysql.md
Created September 20, 2019 07:39
Mysql Quick Commands

Mysql Quick Commands

Using Command-Line Tools

MySQL and MariaDB include two command-line tools that you can use to quickly backup and restore databases. The mysqldump tool is used to export the contents of a database to a text file, while the mysql client can be used to import data from a text file into a MySQL/MariaDB database.

To backup a MySQL/MariaDB database from the command line, follow these steps:

  1. Launch a new Windows command shell using the "Shell" button in the XAMPP control panel.
@alphaolomi
alphaolomi / countries.php
Created September 20, 2019 07:37
List of All Countries
'AF' => 'Afghanistan',
'AX' => 'Aland Islands',
'AL' => 'Albania',
'DZ' => 'Algeria',
'AS' => 'American Samoa',
'AD' => 'Andorra',
'AO' => 'Angola',
'AI' => 'Anguilla',
'AQ' => 'Antarctica',
'AG' => 'Antigua And Barbuda',
@alphaolomi
alphaolomi / Heroku with Node.js.md
Last active August 10, 2019 08:24
🚀 Getting Started on Heroku with Node.js

Heroku with Node.js

Deploy the app

In this step you will deploy the app to Heroku.

  1. Create an app on Heroku, which prepares Heroku to receive your source code.
heroku create

bits

Snippets of things I re-use but always forget exactly how to write it

HTML boilerplate

<!doctype html>
<html lang="en">
<head>
 
@alphaolomi
alphaolomi / django_cheat_sheet.py
Last active July 23, 2020 17:11
[Django] Cheat Sheet #python #django
# *****************************************************************************
# CODING STYLE > MAKING YOUR CODE READABLE
# *****************************************************************************
# 1. Avoid abbreviating variable names.
# 2. Write out your function argument names.
# 3. Document your classes and methods.
# 4. Comment your code.
@alphaolomi
alphaolomi / custom_localhost_url.md
Last active March 25, 2020 14:32
Custom localhost Url

Custom Localhost URL

For Windows

Assuming using XAMPP Server

  1. Open [C:\Windows\System32\Drivers\etc\hosts](file://C:\Windows\System32\Drivers\etc\hosts)
127.0.0.1     something.local