Skip to content

Instantly share code, notes, and snippets.

* executing `deploy'
* executing `deploy:update'
** transaction: start
* executing `deploy:update_code'
updating the cached checkout on all servers
executing locally: "git ls-remote git@github.com:sourcebitsusa/Safewatch-web.git HEAD"
command finished in 4247ms
* executing "if [ -d /home/deploy/apps/development/SafeWatch/shared/cached-copy ]; then cd /home/deploy/apps/development/SafeWatch/shared/cached-copy && git fetch -q origin && git fetch --tags -q origin && git reset -q --hard 9f6549c3b22fab8ea16a06aafbfda8517d27cee6 && git clean -q -d -x -f; else git clone -q git@github.com:sourcebitsusa/Safewatch-web.git /home/deploy/apps/development/SafeWatch/shared/cached-copy && cd /home/deploy/apps/development/SafeWatch/shared/cached-copy && git checkout -q -b deploy 9f6549c3b22fab8ea16a06aafbfda8517d27cee6; fi"
servers: ["176.9.24.201"]
Password:
@dayanand-sourcebits
dayanand-sourcebits / gist:1626596
Created January 17, 2012 13:20
ripple.yml for multiple node
# Configure Riak connections for the Ripple library.
development:
#http_port: 8092
# pb_port: 8087
nodes:
- host: 192.168.31.2
http_port: 8092
- host: 127.0.0.1
http_port: 8091
@dayanand-sourcebits
dayanand-sourcebits / gist:1779785
Created February 9, 2012 12:45
Riak Secondary Search
in your console
client=Ripple.client
client['account_types'].enable_index!
This will enable secondary index for the new entries in "account_types" bucket.
I will add this to the Migrate rake as a new task so things propagate to all the servers. Also i will add it to the setup.rake so that subsequent server setups will have this
-------------------------------------------------------------------------------------------
in your code
client=Ripple.client
The auto-generated password at the bottom of the page should have a label or else the regular end user will have no idea what it is.
The label text should read:
"Auto-generated password. (To customize password, type desired password in the field.)"
Note: this label cannot be located inside the field itself because the autogenerated password is already present when the user first navigates onto the Lock page and will not see the label.
application error
NoMethodError at /devices/bccf4d12d11815ca50d7cd6bac779ac7d0c89c5e/state
private method `get_action_for_lost' called for #<Device:0xbfec990>
file: attribute_methods.rb
location: method_missing
line: 385
map <F4> :NERDTreeToggle <CR>
let g:fuf_dir_exclude = '^pry'
:set nu
set tabstop=2
colorscheme desert
nnoremap <F3> :FufCoverageFile<CR>
nnoremap <F5> :FufFile<CR>
filetype indent on
nnoremap <C-down> :m+<CR>==
nnoremap <C-up> :m-2<CR>==
Riak::HTTPFailedRequest - Expected 201 from Riak but received 500. <html><head><title>500 Internal Server Error</title></head><body><h1>Internal Server Error</h1>The server encountered an error while processing this request:<br><pre>{error,
{error,badarg,
[{erlang,iolist_to_binary,
[{hook_crashed,{riak_search_kv_hook,precommit,error,undef}}]},
{wrq,append_to_response_body,2},
{riak_kv_wm_object,handle_common_error,3},
{webmachine_resource,resource_call,3},
{webmachine_resource,do,3},
{webmachine_decision_core,resource_call,1},
{webmachine_decision_core,accept_helper,0},
Command.find('6geFvMBEFGqY3YEqSrXiC2qRD2j')
<Command:6geFvMBEFGqY3YEqSrXiC2qRD2j created_at=2012-03-28 22:28:45 UTC sorting_time=1332967640 command_type="302" source="web" state="device_notified" device_id="355031040449155" delivery_requested_at=2012-03-28 18:28:45 UTC updated_at=2012-03-28 22:28:45 UTC profile_type=nil params=nil device_audit_id=nil>
Riak search
1.9.2-p290 :184 > client.search('commands','device_id:355031040449155')
=> {"responseHeader"=>{"status"=>0, "QTime"=>14, "params"=>{"q"=>"device_id:355031040449155", "q.op"=>"or", "filter"=>"", "wt"=>"json"}}, "response"=>{"numFound"=>0, "start"=>0, "maxScore"=>"0.0", "docs"=>[]}}
var getAllProducts = function(){
var i;
var product_divs;
var products = new Array();
try{
product_divs = document.getElementsByClassName('listing-card');
if(product_divs.length){
for(i=0; i<product_divs.length; i++){
if(product_divs[i].getElementsByTagName('IMG').length){
var element = product_divs[i].getElementsByTagName('IMG')[0];
class CardsController < ApplicationController
def index
end
end