Skip to content

Instantly share code, notes, and snippets.

View monkeymonk's full-sized avatar
😶
β+∂(ℤ²-i)ℕ×g³=α!

Stéphan Zych monkeymonk

😶
β+∂(ℤ²-i)ℕ×g³=α!
View GitHub Profile
@monkeymonk
monkeymonk / install.sh
Last active April 9, 2019 06:45 — forked from fideloper/install.sh
Server quick install PHP 5 #server
#!/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'
@monkeymonk
monkeymonk / .bash_profile
Last active February 8, 2023 13:04
Mac OS - BASH Configuration and Aliases (eg. `sudo nano ~/.bash_profile`)
# BASH Configuration and Aliases
# source: http://natelandau.com/my-mac-osx-bash_profile/
# source: https://github.com/mathiasbynens/dotfiles
# Sections:
# 0. Execute Only Once (if you want)
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
@monkeymonk
monkeymonk / gist:8058289
Last active January 8, 2022 09:25
List of all icons of Font Awesome 4.0.3 #resources
fa-glass
fa-music
fa-search
fa-envelope-o
fa-heart
fa-star
fa-star-o
fa-user
fa-film
fa-th-large
@monkeymonk
monkeymonk / wp-query-ref.php
Last active April 9, 2019 06:52 — forked from luetkemj/wp-query-ref.php
WordPress Query Comprehensive Reference #wordpress
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.com
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query
* Source: http://core.trac.wordpress.org/browser/tags/3.5.1/wp-includes/query.php
*/
$args = array(
@monkeymonk
monkeymonk / angular-solution
Last active January 3, 2016 13:38
How to use AngularJS and Laravel Blade together.
var customInterpolationApp = angular.module('customInterpolationApp', []);
customInterpolationApp.config(function($interpolateProvider) {
$interpolateProvider.startSymbol('<%');
$interpolateProvider.endSymbol('%>');
});
@monkeymonk
monkeymonk / functions.php
Last active May 14, 2024 04:55
WordPress theme customization API (source: http://web-profile.com.ua/wordpress/docs/customization-api/) #wordpress
/**
* WP_Customize_Manager->add_setting(); // adds a new setting to the database
* WP_Customize_Manager->add_section(); // adds a new section (i.e. category/group) to the Theme Customizer page
* WP_Customize_Manager->add_control(); // creates an HTML control that admins can use to change settings.
* WP_Customize_Manager->get_setting(); // can be used to fetch any existing setting, in the event you need to modify something
*/
add_action( 'customize_register', 'my_customize_register' );
function my_customize_register( $wp_customize ) {
$.extend($.fn, {
spin: function (opts, callback) {
this.each(function() {
var $this = $(this),
data = $this.data();
if (opts !== false) {
data.spinner = new Spinner(opts).spin(this);
$this.trigger('spin');
module.exports = {
'A lot of screenshots': function (test) {
var resolutions = [{width: 1280, height: 1024}, {width: 1024, height: 768}, {width: 800, height: 600}];
var pages = ['http://facebook.com', 'http://twitter.com', 'http://dalekjs.com'];
resolutions.forEach(function (res) {
pages.forEach(function (page) {
test.open(page)
.resize(res)
.select2-container .select2-choice {
border: 2px solid #dce4ec;
font-family: "Lato", sans-serif;
font-size: 14px;
text-indent: 1px;
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
-webkit-box-shadow: none;
-moz-box-shadow: none;