Skip to content

Instantly share code, notes, and snippets.

View viniciusban's full-sized avatar

Vinicius Assef viniciusban

  • Rio de Janeiro, Brazil
View GitHub Profile

Keybase proof

I hereby claim:

  • I am viniciusban on github.
  • I am viniciusban (https://keybase.io/viniciusban) on keybase.
  • I have a public key ASAVZBinTkSjynTnLZOBiJriADJUiQWgFKQwon3jtGeuoAo

To claim this, I am signing this object:

@viniciusban
viniciusban / functions.py
Created January 19, 2021 19:43
Checking arguments of called mocked objects
# functions.py
class CustomPessoa:
def __init__(self, *args, **kwargs):
for (k, v) in kwargs.items():
setattr(self, k, v)
def target_function(pessoa, outro_arg):
@viniciusban
viniciusban / grok_vi.mdown
Created November 21, 2019 16:42 — forked from nifl/grok_vi.mdown
Your problem with Vim is that you don't grok vi.

Answer by Jim Dennis on Stack Overflow question http://stackoverflow.com/questions/1218390/what-is-your-most-productive-shortcut-with-vim/1220118#1220118

Your problem with Vim is that you don't grok vi.

You mention cutting with yy and complain that you almost never want to cut whole lines. In fact programmers, editing source code, very often want to work on whole lines, ranges of lines and blocks of code. However, yy is only one of many way to yank text into the anonymous copy buffer (or "register" as it's called in vi).

The "Zen" of vi is that you're speaking a language. The initial y is a verb. The statement yy is a simple statement which is, essentially, an abbreviation for 0 y$:

0 go to the beginning of this line. y yank from here (up to where?)

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@viniciusban
viniciusban / python-code-style.md
Last active June 20, 2019 16:14
Python coding style

Coding style

Follow these rules below.

General style

Follow PEP 8.

As a summary:

@viniciusban
viniciusban / good-commit-messages.md
Last active April 7, 2023 03:15
Good commit messages
@viniciusban
viniciusban / Email Server (Linux, Unix, Mac).md
Created May 17, 2019 14:06 — forked from raelgc/Email Server (Linux, Unix, Mac).md
Setup a Local Only SMTP Email Server (Linux, Unix, Mac)

Setup a Local Only SMTP Email Server (Linux, Unix, Mac)

1 - Point localhost.com to your machine

Most of programs will not accept an email using just @localhost as domain. So, edit /etc/hosts file to make the domain localhost.com point to your machine, including this content to the file:

127.0.0.1 localhost.com

2 - Install Postfix

@viniciusban
viniciusban / api.md
Last active July 3, 2018 17:22
API description example
@viniciusban
viniciusban / new_user.txt
Last active May 22, 2020 15:40
new user credentials
john:hey,Iamjohn.:John Doe
@viniciusban
viniciusban / id_rsa.pub
Created June 17, 2018 22:28
viniciusban's public key
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDUFIov46XUlv2asCgDacXFEfJC3f0Wd4bgZ4EkT++D+15IrqzuMtf5IY/n4fi0ZYcBPbWoTOx6kP/80tOT4XZhUqxZ8GXjJAoKzJS+rNIysO4P5jpZh6y3zr7OlWchHBaYtMo+VrT6KIbEPL+iUcv3XozTB6hyPF3gIhnjv0X9pAykvTIqUoosJJu127ljuIT4XUqUs3TLlrAGD52rNdKSnOYioybJWsWPkWv1zkf/9lmA/ZLVP0tsCAwHV6MVF2OwWtdUEKA1HL541aQl3QMzLopk8JKIIWETQOPPel5TWbNEFMwZcdJTIavqahAcN7Q/hIWHZVMpGGCTgPckFi+j viniciusban@PINGO