Skip to content

Instantly share code, notes, and snippets.

View tiste's full-sized avatar
💡
crafting

Baptiste Lecocq tiste

💡
crafting
View GitHub Profile
@somebox
somebox / osx-setup.sh
Last active July 9, 2026 09:31 — forked from foz/osx-setup.sh.md
Set up an OSX machine from zero to awesome. Uses Homebrew (and cask, fonts, etc). Focused on Ruby/Rails development, includes rvm, xquartz, editor fonts, sublime text, and many tools.
#!/usr/bin/env bash
# Generic macOS workstation setup
#
# A pragmatic, public bootstrap for developer / technical-productivity Macs.
# It installs Homebrew, common CLI utilities, runtimes, terminal/editor/agentic
# coding apps, viewers, media tools, and a curated font set.
#
# Philosophy:
# - Open-source / cross-platform first.
# - Commercial apps only when explicitly useful/common for this workflow.
@demisx
demisx / angularjs-providers-explained.md
Last active August 26, 2025 03:06
AngularJS Providers: Constant/Value/Service/Factory/Decorator/Provider
Provider Singleton Instantiable Configurable
Constant Yes No No
Value Yes No No
Service Yes No No
Factory Yes Yes No
Decorator Yes No? No
Provider Yes Yes Yes

Constant

@tonycoco
tonycoco / image_filters.rb
Created June 11, 2012 15:04
Useful image filters (Instagram/Hipster/Cool) for CarrierWave using MiniMagick (ImageMagick)
module CarrierWave
module MiniMagick
def toaster_filter
manipulate! do |img|
img.modulate '150,80,100'
img.gamma 1.1
img.contrast
img.contrast
img.contrast
img.contrast
@tcocca
tcocca / FollowsController.rb
Created March 9, 2011 21:55
sample of how to use acts_as_follower with rails3 and ajax
class FollowsController < ApplicationController
def create
@user = User.find(params[:user_id])
current_user.follow(@user)
end
def destroy
@user = User.find(params[:user_id])
current_user.stop_following(@user)