Skip to content

Instantly share code, notes, and snippets.

View Esteban-Rocha's full-sized avatar
🔥
The Fire

Esteban Rocha λ Esteban-Rocha

🔥
The Fire
View GitHub Profile
@anilnautiyal
anilnautiyal / For WPengine (.gitlab-ci.yml)
Last active February 16, 2022 02:13
.gitlab-ci.yml
before_script:
- mkdir -p ~/.ssh
- eval $(ssh-agent -s)
- '[[ -f /.dockerenv ]] && echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config'
- echo "$PRIVATEKEY" | tr -d '\r' | ssh-add - > /dev/null
stages:
- deploy_staging
- deploy_master
@tonioriol
tonioriol / laravel-forge-deploy.sh
Last active April 25, 2023 22:20 — forked from rap2hpoutre/laravel-forge-deploy.sh
Laravel Forge zero downtime deployment script
# stop script on error signal
set -e
SITE="your-site-original-folder-name.com"
DEPL="/home/forge/deployments/${SITE}"
# create directory and any intermediate directories if don't exist
mkdir -p ${DEPL}
CUR="/home/forge/${SITE}"
@FarhadG
FarhadG / .md
Created September 26, 2017 05:03
full-stack-javascript-series

Here is a curated list of resources, question and exercises to go through that covers the essentials of being a competent full stack JS developer.

The contents have been broken down into 4 phases, covering the basics from HTML/CSS to APIs. It would be best to cover these phases in chronological order to gain a broad understanding from the basics to the more advanced topics.

Phase 1

HTML

@ryanshoover
ryanshoover / .circleci config.yml
Last active January 24, 2023 16:18
CircleCI 2.1 Continuous Integration with WP Engine
# Continuous Integration to a WP Engine install
# PHP CircleCI 2.1 configuration file
# Requirements:
# 1. In CircleCI settings, add environment variables for your site's installs:
# * WPE_PRODUCTION_INSTALL=thenameofyourproductioninstall
# * WPE_STAGING_INSTALL=thenameofyourstaginginstall
# * WPE_DEVELOPMENT_INSTALL=thenameofyourdevelopmentinstall
# 2. In your repo, have two files
# * `./.gitignores/__default` -- Excludes any compiled files
@zainxyz
zainxyz / interview-questions.js
Last active May 24, 2019 03:21
Couple of good JavaScript Interview Questions (solved using ES6+)
/**
* What is the difference between '==' and '===' in JavaScript?
*
* '==' matches just the value, where as '===' (also known as the 'strict') operator matches both
* the value and the type.
*/
console.log(100 == '100'); // true, because only value matter
console.log(100 === '100'); // false, because type and value both matter
/**
@nat-c
nat-c / nc-custom-wp-error-pages
Last active February 9, 2023 10:37
Custom WordPress Error Pages (not 404; this one is handled via your theme): A php snippet to put in your functions.php or in your plugin to get rid of the default WP error pages and have custom ones that match with your theme. The code is taken from a CRM application I'm building on top of WordPress [personal project] and slightly modified to be…
<?php
add_filter( 'wp_die_handler', 'nc_get_custom_error_handler' );
function nc_get_custom_error_handler() {
return 'nc_custom_error_handler';
}
function nc_custom_error_handler( $message, $title = '', $args = array() ) {
$defaults = array( 'response' => 500, 'back_link' => false );
@iambibhas
iambibhas / scopes.txt
Last active May 5, 2024 06:39
Sublime Text 2: Snippet scopes
Here is a list of scopes to use in Sublime Text 2 snippets -
ActionScript: source.actionscript.2
AppleScript: source.applescript
ASP: source.asp
Batch FIle: source.dosbatch
C#: source.cs
C++: source.c++
Clojure: source.clojure
CoffeeScript: source.coffee