Skip to content

Instantly share code, notes, and snippets.

@cucxabeng
cucxabeng / alias
Last active April 3, 2017 04:00
Some alias for developer
alias gs="git status"
alias gl="git log"
alias gcom="git checkout master"
alias gaa="git add ."
alias gc="git commit -m "
alias gp="git push"
alias nah="git reset --hard && git clean -df"
alias code="cd ~/Code"
alias desktop="cd ~/Desktop"
@cucxabeng
cucxabeng / disable_strict_MySQL.md
Last active March 17, 2017 10:03
Disable strict SQL mode

To disable strict SQL mode, SSH in to your server as root and create this file:

/etc/mysql/conf.d/disable_strict_mode.cnf

Open the file and enter these two lines:

[mysqld]
sql_mode=IGNORE_SPACE,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

Restart MySQL with this command:

export http_proxy=socks5://127.0.0.1:8080 https_proxy=socks5://127.0.0.1:8080
@cucxabeng
cucxabeng / disable_strict_mode_mac_homebrew.md
Created April 6, 2017 15:48
Config disable strict SQL mode for a Homebrew-installed MySQL server
  1. Find config file:
mysqld --help --verbose | grep my.cnf

In my case, it's locate at: /usr/local/etc/my.cnf, show content and find config directory path.

  1. Create new file at this path:
/usr/local/etc/my.cnf.d/disable_strict_mode.cnf
#!/bin/bash
if [ $# -eq 0 ]
then
echo "No arguments supplied"
exit 1
fi
domain=$1
root="/home/forge/$domain"
Name: Flash
Serial: eNrzzU/OLi0odswsqnHLSSzOqDGoca7JKCkpsNLXLy8v1ytJTczVLUotKNFLzs8FAJHYETc=
if anyone wants to thank ETH: 0x527c2aB55b744D6167dc981576318af96ed26676
Thank you!
{
	"command": "close_all",
	"ignored_packages":
	[
		"Vintage"
	],
	"keys":
	[
 "super+ctrl+shift+w"

| | | | () | | | |__| | __ _ _ __| | __ _ _ __ __ _ | __ |/ | | / _ |/ | '_ \ / _ | | | | | (| | | (| | (| | | | | (| | || ||_,|| _,|_,|| ||_, | / | |/