Skip to content

Instantly share code, notes, and snippets.

View guillermo-menjivar's full-sized avatar

gmo guillermo-menjivar

View GitHub Profile
"""""""""""""""""""""
"configure pathogen
"""""""""""""""""""""
execute pathogen#infect()
"pathogen plugins
call plug#begin()
Plug 'fatih/vim-go'
"Plug 'SirVer/ultisnips'
@guillermo-menjivar
guillermo-menjivar / load.go
Last active April 15, 2020 18:33
load and search
4+ basic_file_upload.go + !/b/zsh [running] X
~/lab/analysis $ cat basic_file_upload.go
import datetime
import calendar
from collections import namedtuple
predicate_string_template = "dt between \'{from_datetime}\' and \'{to_datetime}\' and timestamp between {from_datetime_epoch} and
@guillermo-menjivar
guillermo-menjivar / nosuchuser.html
Created July 14, 2019 09:24 — forked from mubix/nosuchuser.html
No Such User - Spam Deterrent
<html>
<head>
<style>
* {
font-family:Roboto, "Helvetica Neue", Helvetica, Arial, sans-serif;
}
</style>
</head>
<body>
<table cellpadding="0" cellspacing="0" class="email-wrapper" style="padding-top:32px;background-color:#ffffff;"><tbody>
@guillermo-menjivar
guillermo-menjivar / bash-colors.md
Created July 2, 2018 04:00 — forked from iamnewton/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
"vim-go
"auto import
let g:go_disable_autoinstall = 0
let g:go_fmt_command = "goimports"
let g:go_textobj_include_function_doc = 0
let g:go_addtags_transform = "camelcase"
let g:go_highlight_types = 1
let g:go_highlight_fields = 1
let g:go_highlight_functions = 1
let g:go_highlight_methods = 1
@guillermo-menjivar
guillermo-menjivar / postgres-cheatsheet.md
Created May 20, 2018 04:25 — forked from Kartones/postgres-cheatsheet.md
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
@guillermo-menjivar
guillermo-menjivar / more.java
Created April 13, 2018 04:26
somejava.java
import java.util.*;
public class TicTacToe {
public static void main(String[] args) {
int[][]board= new int [3][3];
int turn= 1;
while(full(board)== false && winner(board)==0)
{
printBoard(board);
@guillermo-menjivar
guillermo-menjivar / something.java
Last active April 9, 2018 05:22
example for ya
import java.util.*;
public class GTac {
public static String PlayerO = " O ";
public static String PlayerX = " X ";
public static String Blank = " ";
public static String Delineator = "-----------"; // 11 ( each entry has 3 spaces and there are 3 entries + 2 deviders = 11
public static String Devider = "|";
public static void main(String[] args){
#!/usr/bin/env python
from sys import exit
import json
import datetime
import requests
from uuid import uuid4
import psycopg2
import manicthief