Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Pavel S. Pobegov pobegov

🎯
Focusing
View GitHub Profile
@pobegov
pobegov / convert_latin1_data_in_a_utf8_mysql_database_to_utf8mb4.php
Created Jul 4, 2019
Convert MySQL Database (tables and data) to UTF8MB4, where UTF8 data stored via latin1 connection
View convert_latin1_data_in_a_utf8_mysql_database_to_utf8mb4.php
<?php
/**
* Requires php >= 5.5
*
* Use this script to convert utf-8 data in utf-8 mysql tables stored via latin1 connection
* This is a PHP port from: https://gist.github.com/njvack/6113127
*
* BACKUP YOUR DATABASE BEFORE YOU RUN THIS SCRIPT!
*
* Once the script ran over your databases, change your database connection charset to utf8:
@pobegov
pobegov / Update Fork.md
Created Oct 3, 2018 — forked from seankross/Update Fork.md
Update a Github Fork from the Original Repo
View Update Fork.md

Taken from here

Add remonte branch:

git remote add --track master mleung git://github.com/mleung/feather.git

Verify:

git remote

@pobegov
pobegov / migrate.sh
Created Jun 1, 2018 — forked from pedro-santiago/migrate.sh
Upgrade MAMP 4 to Mysql 5.7.18 (on Sierra tested)
View migrate.sh
#!/bin/sh
wget http://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.18-macos10.12-x86_64.tar.gz
tar xfvz mysql-5.7.18-macos10.12-x86_64.tar.gz
echo "Stopping MAMP"
sudo /Applications/MAMP/bin/stop.sh
sudo killall httpd mysqld
echo "Copy Bin"
@pobegov
pobegov / curl.md
Created May 10, 2017 — forked from subfuzion/curl.md
curl POST examples
View curl.md

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@pobegov
pobegov / multiple_ssh_setting.md
Created Jul 25, 2016 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts
View multiple_ssh_setting.md

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"