Skip to content

Instantly share code, notes, and snippets.

  • Dynamic Dispatch
  • Dynamic Method
  • Ghost Methods
  • Dynamic Proxies
  • Blank Slate
  • Kernel Method
  • Flattening the Scope (aka Nested Lexical Scopes)
  • Context Probe
  • Class Eval (not really a 'spell' more just a demonstration of its usage)
  • Class Macros
@qhduc
qhduc / Vagrant
Created January 22, 2015 02:52
vagrant setup
# setup vagrant
gem install vagrant
vagrant box add lucid32 http://files.vagrantup.com/lucid32.box
mkdir my_vagrant_test
cd my_vagrant_test
vagrant init lucid32
vim Vagrantfile
vagrant up
vagrant ssh
@qhduc
qhduc / share-file-android-demo2.md
Created October 28, 2016 08:54
share-file-android demo2

Share file in android

📘 Step 1 create new project

Use android studio to create android phone project (blank)

📗 Step 2 Config sharing file in AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
@qhduc
qhduc / share-file-android-demo1.md
Created October 28, 2016 08:54
share file document android

Share file in android

📘 Step 1 create new project

Use android studio to create android phone project (blank)

📗 Step 2 config sharing file in AndroidManifest.xml

...
@qhduc
qhduc / Sublime Text 3 Build 3103 License Key - CRACK
Created October 28, 2016 08:55
Sublime Text 3 Build 3103 License Key - CRACK
I use the first
—– BEGIN LICENSE —–
Michael Barnes
Single User License
EA7E-821385
8A353C41 872A0D5C DF9B2950 AFF6F667
C458EA6D 8EA3C286 98D1D650 131A97AB
AA919AEC EF20E143 B361B1E7 4C8B7F04
@qhduc
qhduc / google_text2speech.md
Created October 28, 2016 08:55
Google Text to Speech API

Google Text to Speech API

Base URL: http://translate.google.com/translate_tts
It converts written words into audio. It accepts GET requests.

GET

q
The query string to convert to audio

tl
Translation language, for example, ar for Arabic, or en-us for English

@qhduc
qhduc / install.sh
Created October 28, 2016 08:55
Vagrant Provisioning Script for PHP applications. This installs a LAMP stack.
#!/usr/bin/env bash
echo ">>> Starting Install Script"
# Update
sudo apt-get update
# Install MySQL without prompt
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password root'
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password root'
@qhduc
qhduc / README.md
Created October 28, 2016 08:55
My simply MySQL Command Line Cheatsheet
@qhduc
qhduc / README.md
Created October 28, 2016 08:55
Vagrant tutorial

Vagrant Setup

This tutorial guides you through creating your first Vagrant project.

We start with a generic Ubuntu VM, and use the Chef provisioning tool to:

  • install packages for vim, git
  • create user accounts, as specified in included JSON config files
  • install specified user dotfiles (.bashrc, .vimrc, etc) from a git repository

Afterwards, we'll see how easy it is to package our newly provisioned VM

@qhduc
qhduc / Basics Laravel.md
Created October 28, 2016 08:59 — forked from superguigui/Basics Laravel.md
Laravel memo

Laravel help

Basics

Create controller

php artisan make:controller NameOfTheController --plain

Connect to Homestead VM