Skip to content

Instantly share code, notes, and snippets.

Juane Chomon juanecl

Block or report user

Report or block juanecl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@juanecl
juanecl / instalacion.sh
Last active Feb 1, 2019
Configurar PostFix con Gmail Relay para CentOS 7
View instalacion.sh
#!/bin/bash
BASE_PATH=(Reemplaza por la ruta de tus archivos de configuracion sin parentesis)
CONF="$BASE_PATH/postfix_conf.txt"
POSTFIX_CONF=/etc/postfix/main.cf
DEPENDENCIAS=(postfix cyrus-sasl-plain mailx)
ACCESO_POSTFIX=/etc/postfix/sasl_passwd
ACCESO="$BASE_PATH/postfix_access.txt"
DESTINATARIO=(Reemplaza por el correo al cual quieres enviar la prueba de operacion del servicio de correo sin parentesis)
for i in ${DEPENDENCIAS[*]}
@juanecl
juanecl / comunas.json
Last active Oct 30, 2019
División político administrativa de Chile. Las jerarquías que se pueden lograr son Región > Provincia > Comuna o Región > Provincia > Localidad. Las localidades no son una unidad oficial de división político-administrativo en Chile, es por eso que no contienen un código. Las coordenadas están incompletas. Los JSON de Regiones, Provincias y Comun…
View comunas.json
[
{
"codigo": "05602",
"tipo": "comuna",
"nombre": "Algarrobo",
"lat": -33.3332,
"lng": -71.6023,
"url": "",
"codigo_padre": "056"
},
@juanecl
juanecl / Fibonacci.java
Last active Dec 21, 2018
Function to get Fibonacci series numbers from one to an entered number by user
View Fibonacci.java
import java.util.ArrayList;
import java.util.List;
import java.util.*;
public class Fibonacci {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int end, init, aux, i, ciclo;
@juanecl
juanecl / drupal_update_for_ubuntu_server.sh
Created Dec 21, 2018
Bash script for automatization of Drupal 7 within Apache2 in Ubuntu Server. Tested upon Trusty Tahr and forth.
View drupal_update_for_ubuntu_server.sh
#!/bin/bash
# Author: Juane Chomon
# Author URL: https://www.juane.cl
# Created: September 01, 2018
# Version: 1.0
# License: Free to use it whatever you like. But don't be that ass to say you made it if you don't add it your own value to it
# Usage: sh update_drupal7_core.sh {version_number} or ./update_drupal7_core {version_number}
# eg. sh update_drupal7_core.sh 7.59 or ./update_drupal7_core 7.59
TIMESTAMP=`date '+%Y%m%d%H%M%S'` # Datetime string to log and backup as a distinctive attempt
@juanecl
juanecl / svn_merge.sh
Created Dec 21, 2018
SVN script for merging a branch to trunk with cli
View svn_merge.sh
#!/bin/bash
# Usage: svn_merge {trunk url} {branch url}
# This script requires 2 parameters. The first one is the full url of the trunk and the second is the full url of the branch. Do not add trailing slashes in the urls.
TRUNK=$1
BRANCH=$2
TMP_DIR=~/svn/temp_merge_dir/
BRANCH_DIR=`echo $BRANCH | rev | cut -d '/' -f 1 | rev`
MERGED_DIR="MERGED_"$BRANCH_DIR
TRUNK_DIR=`echo $TRUNK | rev | cut -d '/' -f 1 | rev`
NEW_BRANCH=${BRANCH/$BRANCH_DIR/$MERGED_DIR}
@juanecl
juanecl / GoogleSpreadsheet.html
Created Jun 25, 2018 — forked from terrywbrady/GoogleSpreadsheet.html
Sample HTML/JS to parse a Google Spreadsheet
View GoogleSpreadsheet.html
<!doctype html>
<html>
<head>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script type="text/javascript">
var spData = null;
function doData(json) {
spData = json.feed.entry;
}
You can’t perform that action at this time.