Skip to content

Instantly share code, notes, and snippets.

View tricomsol's full-sized avatar
🏠
Working from home

Hemant Patel tricomsol

🏠
Working from home
  • MeritCapital
  • Ahmedabad, India
View GitHub Profile
### Keybase proof
I hereby claim:
* I am tricomsol on github.
* I am hemant2308 (https://keybase.io/hemant2308) on keybase.
* I have a public key ASCsuad7tMDLBIDX-ec58GfxJRRKdPQidghusnHVzl2lHQo
To claim this, I am signing this object:
@tricomsol
tricomsol / osx-setup.sh
Created April 30, 2020 23:40 — forked from somebox/osx-setup.sh
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.
#!/bin/bash
# A script to set up a new mac. Uses bash, homebrew, etc.
# Focused for ruby/rails development. Includes many utilities and apps:
# - homebrew, rvm, node
# - quicklook plugins, terminal fonts
# - browsers: chrome, firefox
# - dev: iterm2, sublime text, postgres, chrome devtools, etc.
# - team: slack, dropbox, google drive, skype, etc
/**
* Example of using an angular provider to build an api service.
* @author Jeremy Elbourn ([email protected])
*/
/** Namespace for the application. */
var app = {};
/******************************************************************************/
namespace.views.MyWizard = Backbone.Views.extend({
initialize: function() {
_.bindAll(this, 'render', 'wizardMethod');
}
render: function() {
this.wizardMethod();
return this;
},
@tricomsol
tricomsol / paginated_collection.js
Created August 5, 2011 00:21 — forked from io41/paginated_collection.js
Pagination with Backbone.js
// includes bindings for fetching/fetched
var PaginatedCollection = Backbone.Collection.extend({
initialize: function() {
_.bindAll(this, 'parse', 'url', 'pageInfo', 'nextPage', 'previousPage');
typeof(options) != 'undefined' || (options = {});
this.page = 1;
typeof(this.perPage) != 'undefined' || (this.perPage = 10);
},
fetch: function(options) {
#!/usr/bin/env ruby
#
# Passenger management script
# By James Smith http://loopj.com
# Based heavily on a similar script by Jon Bettcher
#
# Check memory usage of all paseenger child process and kill if grows
# too large.
#
#!/bin/sh
#
# redis - this script starts and stops the redis-server daemon
#
# chkconfig: - 85 15
# description: Redis is a persistent key-value database
# processname: redis-server
# config: /etc/redis/redis.conf
# config: /etc/sysconfig/redis
# pidfile: /var/run/redis.pid
@tricomsol
tricomsol / .monitrc
Created March 22, 2011 10:28 — forked from arikfr/.monitrc
set mailserver smtp.gmail.com port 587 username "[email protected]" password "password" using tlsv1 with timeout 30 seconds
# you'd obviously have more settings somewhere
set :scm, :git
set :repository, "[email protected]:defunkt/github.git"
set :branch, "origin/master"
set :migrate_target, :current
set :use_sudo, false
set :ssh_options, {:forward_agent => true}
set :rails_env, 'production'
set(:latest_release) { fetch(:current_path) }