Skip to content

Instantly share code, notes, and snippets.

Avatar
:shipit:
Ship it!

Ricardo Shiota Yasuda shadowmaru

:shipit:
Ship it!
View GitHub Profile
View init.vim
set nocompatible
filetype off
set cursorline " highlight current line
set synmaxcol=128
set number " show line numbers
set noswapfile " doesn't generate those awful .swp files
set nobackup " doesn't generate those awful .bkp files
set lazyredraw " redraw only when we need to.
set showmatch " highlight matching [{()}]
set wildignore+=*/tmp/*,*/_build/*,*/node_modules/*,*.so,*.swp,*.zip,*/.git/*,*/coverage/*
View keybase.md

Keybase proof

I hereby claim:

  • I am shadowmaru on github.
  • I am shadowmaru (https://keybase.io/shadowmaru) on keybase.
  • I have a public key ASDSp8YtijUg-Hr2ek00HFd3-XypP_-u70uz3Zf8qudFZAo

To claim this, I am signing this object:

@shadowmaru
shadowmaru / db-open
Created Mar 6, 2017 — forked from helderco/db-open
Script to open a mysql database in Sequel Pro from a service in docker-compose.
View db-open
#!/bin/bash
set -e
show_help() {
cat << EOF
Usage: ${0##*/} [-u USER] [-p PASS] [-P PORT] [-H HOST] [DATABASE]
${0##*/} -h
Open a standard connection in Sequel PRO.
@shadowmaru
shadowmaru / layout_style_guide.md
Last active Feb 26, 2018
Layout Style Guide Bio Ritmo
View layout_style_guide.md

Guia de estilos para layouts de websites - Grupo Bio Ritmo

Formato do layout

Entregue seu layout no formato Photoshop. Também inclua jpegs caso haja muitas variações do responsivo (break points).

Peso dos arquivos

Evite arquivos muito grandes, principalmente as imagens. Otimize-as para web e principalmente para mobile.

View angular-directive.js
'use strict';
angular.module('app')
.directive('my-input', [
function() {
return {
restrict: 'E',
templateUrl: '/my-input.html',
scope: {},
controllerAs: 'myInput',
View keybase.md

Keybase proof

I hereby claim:

  • I am shadowmaru on github.
  • I am shadowmaru (https://keybase.io/shadowmaru) on keybase.
  • I have a public key whose fingerprint is 16BD 33FB D8C8 541D D751 64D2 4146 8958 61AA 4F17

To claim this, I am signing this object:

View gist:1706208
deploy 7546 0.0 0.0 17724 656 ? S 22:41 0:00 -bash
deploy 7605 0.0 0.0 17724 640 ? S 22:42 0:00 -bash
deploy 7609 0.0 0.0 17724 664 ? S 22:42 0:00 -bash
deploy 7628 0.0 0.0 17724 668 ? S 22:42 0:00 -bash
deploy 7674 0.0 0.0 17724 668 ? S 22:43 0:00 -bash
deploy 7675 0.0 0.0 17724 668 ? S 22:43 0:00 -bash
deploy 7676 0.0 0.0 17724 672 ? S 22:43 0:00 -bash
deploy 7679 0.0 0.0 17724 676 ? S 22:43 0:00 -bash
deploy 7680 0.0 0.0 17724 672 ? S 22:43 0:00 -bash
deploy 7684 0.0 0.0 17724 672 ? S 22:43 0:00 -bash
View devise.pt-BR.yml
pt-BR:
errors:
messages:
expired: "expirou, por favor solicite uma nova"
not_found: "não encontrado"
already_confirmed: "já foi confirmado, por favor tente fazer login"
not_locked: "não foi bloqueado"
not_saved:
one: "1 erro evitou que este %{resource} fosse gravado:"
other: "%{count} erros evitaram que este %{resource} fosse gravado:"
View migrate_products_to_paperclip.rb
class MigrateProductsToPaperclip < ActiveRecord::Migration
def self.up
# Rename the old "image" column to "old_file_name", since Product.image will now try to do Paperclip stuff
rename_column :products, :image, :old_file_name
# Rename asset directories to pluralize
File.rename("public/system/product","public/system/products")
File.rename("public/system/products/image","public/system/products/images")