Skip to content

Instantly share code, notes, and snippets.

View luonghuycuong's full-sized avatar

Lương Cường luonghuycuong

  • Ho Chi Minh City, Viet Nam
View GitHub Profile
04e5816e4a004eef65474e65b1719585263bde8cb2535b6d26f01ec0f241032c93d52df7f56aadfc7975608a3a5301d4ed3f6605ea9821623b4d96d730a57c2871
https://github.com/vysheng/tg
export CPPFLAGS="-I/usr/local/opt/readline/include"
export LDFLAGS="-L/usr/local/opt/readline/lib"
./configure --with-openssl=/usr/local/opt/openssl --disable-liblua

Keybase proof

I hereby claim:

  • I am luonghuycuong on github.
  • I am luongcuong (https://keybase.io/luongcuong) on keybase.
  • I have a public key ASAKUe9dJCcjOwbEdwLFhi3DsFRSpxwiFkJRmajtKYGplQo

To claim this, I am signing this object:

@luonghuycuong
luonghuycuong / gist:2d7f7e18269ae30b0df4279514e1a6fc
Created April 21, 2016 05:42 — forked from bramus/gist:5b4f4733e543912a518f
OS X 10.10 Yosemite, Apache, MySQL, PHP 5.6, (MAMP) Homebrew Dev Setup
# From http://www.iyware.com/osx-yosemite-mamp-homebrew-development-setup/
# Install Homebrew
xcode-select --install
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew doctor
# Tap Repos
brew tap homebrew/dupes
brew tap homebrew/versions
@luonghuycuong
luonghuycuong / post_receive
Last active January 11, 2016 02:48
Git hooks - post receive
#!/bin/bash
echo "Push to Deploy"
while read oldrev newrev ref
do
echo $ref
if [[ $ref =~ .*/test$ ]];
then
echo "Test ref received. Deploying test branch to test..."
git --work-tree=/var/www/domains/test...net --git-dir=/var/...git checkout -f test
elif [[ $ref =~ .*/master$ ]];
@luonghuycuong
luonghuycuong / yeu-than-ky-243.txt
Created September 18, 2015 02:27
yêu thần ký đệ 243 chương hắc viêm thối luyện
yêu thần ký đệ 243 chương hắc viêm thối luyện ( cầu nguyệt phiếu !)
<!-- chính|đang] văn bắt đầu -->
hắc viêm tháp đứng sửng ở trong hoang dã , nọ,vậy] hừng hực liệt diễm đem xuân g quanh nham thạch đô cho nướng đỏ 。<p>
thương minh 、 mộ đêm 、 hoa hỏa chờ người khán|nhìn|xem] đến nọ,vậy] tọa|ngồi] tháp , liếc nhìn nhau sau , đều toát ra không chịu thua thần sắc , đối với , thân là siêu cấp thế gia đích hệ , bọn họ đều là mưu lược|sơ lược|xâm lược] có nghe thấy , ký|vừa|đã|rồi] nhưng như này , làm sao phương 。</p><p>
sưu sưu sưu !</p><p>
ba cái bóng người dẫn đầu hướng nọ,vậy] tọa|ngồi] hắc viêm tháp lao đi 。</p><p>
ngay sau đó , tất cả tộc cường giả tất cả đều hướng nọ,vậy] tọa|ngồi] tháp cao bay vút mà đi 。</p><p>
function timeAgo(previous, current){
var elapsed = current - previous;
var msPerMinute = 60 * 1000;
if(elapsed < msPerMinute){
return Math.round(elapsed/1000) +' giây trước';
}
var msPerHour = msPerMinute * 60;
if(elapsed < msPerHour){
@luonghuycuong
luonghuycuong / .htaccess
Last active August 29, 2015 14:17
www; cors;
RewriteEngine On
RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
RewriteRule ^(.*)$ http://%1/$1 [R=301,L]
<IfModule mod_headers.c>
Header set Access-Control-Allow-Origin http://truyencuatui.net
Header set Access-Control-Allow-Credentials true
</IfModule>
@luonghuycuong
luonghuycuong / git-vs-dropbox.md
Last active August 29, 2015 14:04
Private Git

Dropbox vs Git

$ cd ~/Dropbox/Git
$ git init --bare mytestrepo.git

$ cd ~
$ mkdir testrepo
$ cd testrepo
$ git init