Skip to content

Instantly share code, notes, and snippets.

View stivncastillo's full-sized avatar
🎯
Focused

Stiven Castillo stivncastillo

🎯
Focused
View GitHub Profile
$departamentos = array(
'AMAZONAS' => [
'LETICIA',
'EL ENCANTO',
'LA CHORRERA',
'LA PEDRERA',
'LA VICTORIA',
'MIRITI-PARANA',
'PUERTO ALEGRIA',
'PUERTO ARICA',
@stivncastillo
stivncastillo / routes.php
Last active September 30, 2016 14:31
Artisan commands from url, Laravel.
<?php
Route::get('/artisan/{key?}', array('as' => 'artisan', function($key = null)
{
if($key == "down"){
try {
Artisan::call('down');
echo 'Server Down';
} catch (Exception $e) {
Response::make($e->getMessage(), 500);
server {
listen 80;
listen [::]:80;
root /home/ubuntu/projects/finlog-backend/web;
# Add index.php to the list if you are using PHP
index index.php app.php index.html index.htm index.nginx-debian.html;
server_name finlog.creardigital.com www.finlog.creardigital.com;
@stivncastillo
stivncastillo / Laravel PHP7 LEMP AWS.md
Created December 11, 2017 14:22 — forked from santoshachari/Laravel PHP7 LEMP AWS.md
Laravel 5.x on Ubuntu 16.x, PHP 7.x, Nginx 1.9.x

#Steps to install latest Laravel, LEMP on AWS Ubuntu 16.4 version. This tutorial is the improvised verision of this tutorial on Digitalocean based on my experience.

Install PHP 7 on Ubuntu

Run the following commands in sequence.

sudo apt-get install -y language-pack-en-base
sudo LC_ALL=en_US.UTF-8 add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install zip unzip
@stivncastillo
stivncastillo / Instructions.sh
Created August 10, 2018 13:49 — forked from GhazanfarMir/Instructions.sh
Install PHP7.2 NGINX and PHP7.2-FPM on Ubuntu 16.04
########## Install NGINX ##############
# Install software-properties-common package to give us add-apt-repository package
sudo apt-get install -y software-properties-common
# Install latest nginx version from community maintained ppa
sudo add-apt-repository ppa:nginx/stable
# Update packages after adding ppa
@stivncastillo
stivncastillo / challenges-ES6-class-1.md
Last active August 23, 2018 05:35
Ejercicios para la el curso de React para la primer clase de ES6

Ejercicio 1

Teniendo en cuenta los datos dados al principio del código, use un Template String para producir la siguiente cadena. Asegúrese de que los números, los nombres y el rol realmente provengan de los datos.

Hay 4 personas en el equipo.
Sus nombres son Stiven, Maria, Joaquín, Javier.
2 de ellos tienen el rol administrator.

@stivncastillo
stivncastillo / package.json
Created August 23, 2018 06:00
Webpack + React + Sass
{
"name": "webpack-r",
"version": "1.0.0",
"description": "",
"main": "main.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build": "webpack-dev-server",
"build:prod": "webpack -p"
},
<!DOCTYPE html>
<html>
<head>
<title>Devhack - React</title>
<script src="https://unpkg.com/redux@latest/dist/redux.min.js"></script>
</head>
<body>
<div>
<p>
Counter: <span id="value">0</span> times
@stivncastillo
stivncastillo / _colors.scss
Last active October 26, 2018 04:47
Workshop Reactjs
$primary-color: #EF476F;
$color-blue-dark: #26547C;
$color-green: #06D6A0;
$color-white-gray: #F4F4F8;
$color-white: #FFFFFF;
$color-gray: #4A4A4A;
{
"extends": "airbnb",
"parser": "babel-eslint",
"env": {
"browser": true
},
"plugins": [
"react"
],
"rules": {