I hereby claim:
- I am diogob on github.
- I am diogob (https://keybase.io/diogob) on keybase.
- I have a public key whose fingerprint is 5F1B DEFC 9976 76EF 08E2 F984 0ADC 5D85 D8E9 8174
To claim this, I am signing this object:
set nocompatible " be iMproved | |
filetype off " required! | |
call plug#begin('~/.vim/plugged') | |
" Plugs: | |
" Utilities | |
Plug 'tpope/vim-commentary' | |
Plug 'tpope/vim-fugitive' | |
Plug 'tpope/vim-surround' |
# vim:fileencoding=utf-8:ft=conf:foldmethod=marker | |
#: Fonts {{{ | |
font_family Fira Code Regular Nerd Font Complete | |
# bold_font auto | |
# italic_font auto | |
# bold_italic_font auto | |
font_size 12.0 |
call plug#begin('~/.vim/plugged') | |
" General editting goodies | |
Plug 'bronson/vim-trailing-whitespace' | |
Plug 'tpope/vim-commentary' | |
Plug 'danilamihailov/beacon.nvim' | |
" Show Registers | |
Plug 'junegunn/vim-peekaboo' |
I hereby claim:
To claim this, I am signing this object:
;; -*- mode: emacs-lisp -*- | |
;; This file is loaded by Spacemacs at startup. | |
;; It must be stored in your home directory. | |
(defun dotspacemacs/layers () | |
"Configuration Layers declaration. | |
You should not put any user code in this function besides modifying the variable | |
values." | |
(setq-default | |
;; Base distribution to use. This is a layer contained in the directory |
export PS1="\[\033[0;31m\]\u@\h\[\033[0;33m\]:\[\033[0;32m\]\W\[\033[0;37m\] \\$ \[\033[0m\]" | |
export SUDO_PS1=$PS1 | |
alias ls="ls -h -G" | |
alias brake="bundle exec rake" | |
alias be="bundle exec" | |
alias ce="cabal exec" | |
alias se="stack exec" | |
alias dokku="ssh dokku@dokku.catarse.me" | |
alias e="open -a Emacs" |
[github] | |
user = diogob | |
[user] | |
name = Diogo Biazus | |
email = diogob@gmail.com | |
[color] | |
branch = auto | |
diff = auto | |
status = auto | |
[color "branch"] |
describe ".channel_subscribers_report" do | |
let(:url){ "/users/:id" } | |
before do | |
User.should_receive(:select).with("users.name, users.email, replace('#{url}', ':id', users.id::text) AS url").and_call_original | |
end | |
it("should call select with name, email and user url") do | |
User.channel_subscribers_report("/users/:id") | |
end | |
end |
class BackersByPeriod < ActiveRecord::Base | |
def self.chart | |
self.all.reduce([]) do |memo, row| | |
memo << {name: I18n.t("adm.statistics.backers_by_week.#{row.series}"), data: {}} unless memo.last && memo.last[:name] == I18n.t("adm.statistics.backers_by_week.#{row.series}") | |
memo.last[:data][Date.today - (row[:week] * 7).days] = row[:sum] | |
memo | |
end | |
end | |
end |
class Fixnum | |
SECONDS_IN_A_DAY = 86400 | |
SECONDS_IN_A_MINUTE = 3600 | |
def days | |
self * SECONDS_IN_A_DAY | |
end | |
def minutes | |
self * SECONDS_IN_A_MINUTE | |
end |