Skip to content

Instantly share code, notes, and snippets.

View rajibahmed's full-sized avatar
🚴‍♂️
Life is fine !

Rajib Ahmed rajibahmed

🚴‍♂️
Life is fine !
  • Stockholm
View GitHub Profile
@gaearon
gaearon / slim-redux.js
Last active March 25, 2024 19:12
Redux without the sanity checks in a single file. Don't use this, use normal Redux. :-)
function mapValues(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
result[key] = fn(obj[key], key);
return result;
}, {});
}
function pick(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
if (fn(obj[key])) {
@josegonzalez
josegonzalez / deploy.rb
Created October 23, 2010 16:40
Capistrano Deploy Script for CakePHP applications using GIT (Update the $config hash))
$config = {
"application" => "DOMAIN.TLD",
"repository" => "git@GITHOST:USERNAME/REPOSITORYNAME.git",
"remoteusername" => "REMOTEUSERNAME",
"cake_folder" => "/PATH/TO/CAKE",
"cake_version" => "cakephp1.3",
"plugin_dir" => "plugins",
"servers" => {
"prod" => {
"server" => "APPLICATION.TLD",