Skip to content

Instantly share code, notes, and snippets.

View renaco's full-sized avatar

Renán Romero renaco

View GitHub Profile
# System-wide .bashrc file for interactive bash(1) shells.
# To enable the settings / commands in this file for login shells as well,
# this file has to be sourced in /etc/profile.
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
@renaco
renaco / gist:74bbbb9dfaf1c3492ff0
Created April 29, 2015 22:56
Set Winmege for Mergetool on Windows
[merge]
tool = winmerge
[mergetool "winmerge"]
cmd = \"C:\\Program Files (x86)\\WinMerge\\WinMergeU.exe\" "$PWD/$LOCAL" "$PWD/$REMOTE" "$PWD/$MERGED"
trustExitCode = false
keepBackup = false
[diff]
tool = winmerge
@renaco
renaco / gist:d6b365c8d26ec134b018
Created July 17, 2015 05:17
Sublime Text - Setting User
{
"color_scheme": "Packages/Material Theme/schemes/Material-Theme.tmTheme",
"theme": "Material-Theme.sublime-theme",
"font_size": 14,
"ignored_packages":
[
"Vintage"
],
"tab_size": 2,
"translate_tabs_to_spaces": true
@renaco
renaco / english-links.md
Created November 27, 2015 20:07 — forked from anareyna/english-links.md
English
export function Log() {
let enviroment = {
local: "localhost",
dev: "dev1acobranzas\.",
pre: "pre1acobranzas\."
};
var regExpEnvironment = new RegExp([enviroment.local, "|", enviroment.dev, "|", enviroment.pre].join(""), "gi");
if(regExpEnvironment.test(document.domain)){
if(typeof console.log == "function"){
console.log.apply(console,arguments);
@renaco
renaco / gist:7fe8bf00331e17b446e0
Last active June 19, 2017 21:15
.bash_profile
export PATH=~/bin:$PATH
export PATH="/usr/local/mysql/bin:$PATH"
# git bash auto-completion
source `brew --prefix git`/etc/bash_completion.d/git-completion.bash
# latest versions of git has the prompt stuff on an extra file
__git_prompt_file=`brew --prefix git`/etc/bash_completion.d/git-prompt.sh
if [ -f "$__git_prompt_file" ]
then
source $__git_prompt_file
var fullName = 'Sergio Brito';
console.log(fullName);
function setName(name: string): void {
this.fullName = name;
}
setName('Chicharito');
@renaco
renaco / basic bash_profile
Last active December 11, 2017 16:09
.bash_profile
export PATH=~/bin:$PATH
export PATH="/usr/local/mysql/bin:$PATH"
# git bash auto-completion
source `brew --prefix git`/etc/bash_completion.d/git-completion.bash
# latest versions of git has the prompt stuff on an extra file
__git_prompt_file=`brew --prefix git`/etc/bash_completion.d/git-prompt.sh
if [ -f "$__git_prompt_file" ]
then
source $__git_prompt_file
@renaco
renaco / sunat-ruc.js
Created January 11, 2018 23:09
Improvement consult sunat ruc
var getFrame = document.getElementsByName('leftFrame')[0];
var getImage = getFrame.contentWindow.document.querySelectorAll("[name='imagen']")[0];
var getButton = getFrame.contentWindow.document.querySelectorAll(".form-button")[0];
var getInput = getFrame.contentWindow.document.querySelectorAll("input[name='codigo']")[0];
getImage.parentElement.align = 'right';
getInput.parentElement.width = '';
getInput.style.fontSize = 15 + 'px';
getInput.style.width = 95 + '%';