Skip to content

Instantly share code, notes, and snippets.

View xheisenbugx's full-sized avatar
🏠
Working from home

Osvaldo xheisenbugx

🏠
Working from home
  • ~/.config/nvim
  • 00:02 (UTC -06:00)
View GitHub Profile
@xheisenbugx
xheisenbugx / virtualenvwrapper.md
Created June 15, 2017 19:38
Virtualenvwrapper configuration

Add the following line to ~/.virtualenvs/venv/postactivate and ~/.virtualenvs/venv/postdeactivate

source ~/.oh-my-zsh/themes/honukai.zsh-theme

Visual Studio Code

Plugins

  • Python
  • Unique Lines
  • Djaneiro -Django Snippets
  • Django Template
  • Sublime Text Keymap
# Machine name.
function box_name {
[ -f ~/.box-name ] && cat ~/.box-name || echo $HOST
}
# Directory info.
local current_dir='${PWD/#$HOME/~}'
# VCS
YS_VCS_PROMPT_PREFIX1=" %{$fg[white]%}on%{$reset_color%} "
@xheisenbugx
xheisenbugx / .zshrc
Last active December 14, 2022 22:45
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH=~/.oh-my-zsh
# Set name of the theme to load. Optionally, if you set this to "random"
# it'll load a random theme each time that oh-my-zsh is loaded.
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
if [ -f "$HOME/.oh-my-zsh/themes/honukai.zsh-theme" ]; then
@xheisenbugx
xheisenbugx / switch.py
Created June 14, 2015 18:23
Simular switch en python
def f(x):
return {
'a': 1,
'b': 2,
}.get(x, "No se encontró esa opción")
/*
* C++ - Arbol binario de busqueda aplicado en archivos
* Copyright 2013 Martin Cruz Otiniano
* Description : Tiene las funciones de insertar registro en un nodo (escribir), mostrar los registros
* haciendo uso del algoritmo y eliminar archivo ABB.
* Site : www.marcsdev.com
*/
#include <iostream>
#include <stdio.h>
/*
* C++ - Metodo de dispersion (Hashing)
* Copyright 2013 Martin Cruz Otiniano
* Site: www.marcsdev.com
*/
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
/*
* Criba de Eratostenes - C++
* Copyright 2014 Martin Cruz Otiniano
* Description : Esta funcion devuelve un vector(STL) con los numeros primos hasta un rango n enviado como parametro.
* Site : www.marcsdev.com
*/
#include <iostream>
#include <vector>
#include <cmath>
/*
* C++ - Árboles Binarios de Búsqueda
* Copyright 2014 Martin Cruz Otiniano
* Description : Funciones de Insercion, Busqueda, Eliminacion, Recorridos por niveles(amplitud), Altura, Arbol reflejo, Contar hojas.
* Site : www.marcsdev.com
*/
#include <iostream>
#include <stdlib.h>
/*
* C++ - Autómata Finito Determinista
* Copyright 2014 Martin Cruz Otiniano
* Description: Ingresa automata, verifica palabra
* Site: www.marcsdev.com
*/
#include <iostream>
#include <vector>
#include <algorithm>