Skip to content

Instantly share code, notes, and snippets.

View ricsdeol's full-sized avatar

Ricardo Siqueira de Oliveira Leite ricsdeol

View GitHub Profile
@ricsdeol
ricsdeol / resoursable.rb
Created October 1, 2020 01:14
Resoursable
# frozen_string_literal: true
module Resourceable
extend ActiveSupport::Concern
included do
before_action :set_resource, only: %i[show edit update destroy]
before_action :authorize_resource
helper_method :resource
@ricsdeol
ricsdeol / goal_ucase.rb
Last active November 10, 2020 21:05
Goals Ucase Exemple
require 'pp'
require 'bundler/inline'
gemfile do
source 'https://rubygems.org'
gem 'u-case', '~> 4.2.1'
gem 'pry-byebug'
gem 'awesome_print'
gem 'activesupport', require: 'active_support/all'
@ricsdeol
ricsdeol / ..setup.md
Last active September 23, 2023 19:18
Config WSL2 Ubuntu

Config WSL2 Ubuntu

Config Shared Drive projects

Create VHDX dirve

Mount-VHD -PATH "D:\Ricardo\projects.vhdx" -PassThru
wsl --mount \\.\PHYSICALDRIVE2
@ricsdeol
ricsdeol / file.md
Created May 7, 2024 21:46 — forked from jjb/file.md
Using Jemalloc 5 with Ruby.md

For years, people have been using jemalloc with ruby. There were various benchmarks and discussions. Legend had it that Jemalloc 5 didn't work as well as Jemalloc 3.

Then, one day, hope appeared on the horizon. @wjordan offered a config for Jemalloc 5.

Ubuntu/Debian

FROM ruby:3.1.2-bullseye
RUN apt-get update ; \