Skip to content

Instantly share code, notes, and snippets.

View cliffano's full-sized avatar
🎧
Hustlin' hustlin' hustlin' hustlin' hustlin'

Cliffano Subagio cliffano

🎧
Hustlin' hustlin' hustlin' hustlin' hustlin'
View GitHub Profile
@cliffano
cliffano / gist:5465541
Created April 26, 2013 07:29
Node modules with latest version having gypfile: true
kingkong:/tmp/gypfilecheck$ time couchtato iterate -u http://host/registry -p 5000
retrieved 5000 docs - 0
>> LDAP 1.1.4 has gypfile: true
>> airtunes 0.1.3 has gypfile: true
>> aligned-buffer 0.1.2 has gypfile: true
>> allsync 0.0.3b has gypfile: true
>> ancillary 2.0.0 has gypfile: true
>> aplus 0.1.0 has gypfile: true
>> base128 0.1.0 has gypfile: true
>> bcrypt 0.7.5 has gypfile: true
@cliffano
cliffano / gist:5054305
Created February 28, 2013 04:57
VAGRANT_LOG vagrant up | GH-580
> VAGRANT_LOG=debug vagrant up
INFO global: Vagrant version: 1.0.6
INFO vagrant: `vagrant` invoked: ["up"]
DEBUG vagrant: Creating Vagrant environment
INFO environment: Environment initialized (#<Vagrant::Environment:0x7fad33034200>)
INFO environment: - cwd: /home/user1
INFO environment: Home path: /home/user1/.vagrant.d
INFO environment: Copying private key to home directory
/usr/lib/ruby/1.8/fileutils.rb:1268:in `initialize': Permission denied - /usr/lib/ruby/gems/1.8/gems/vagrant-1.0.6/keys/vagrant (Errno::EACCES)
from /usr/lib/ruby/1.8/fileutils.rb:1268:in `open'
[debug] [<0.85.0>] New task status for <0.308.0>: [{checkpointed_source_seq,
98413},
{continuous,true},
{doc_id,<<"my_content">>},
{doc_write_failures,175},
{docs_read,46479},
{docs_written,46304},
{missing_revisions_found,
46479},
{progress,87},
@cliffano
cliffano / gist:4545061
Last active September 13, 2020 07:23
CouchDB delete followed by bulk fetch against _replicator database
========================================================================
Step 1: Delete an existing doc in _replicator database.
request:
{ method: 'POST',
headers:
{ 'content-type': 'application/json',
accept: 'application/json' },
uri: 'http://user:pass@localhost:5984/_replicator/_bulk_docs',
body: '{"docs":[{"_id":"foo1","source":"http://user:pass@localhost:5984/mydb","target":"http://user:pass@localhost:5984/mydb2","continuous":true,"_rev":"59-abb0482eb5a5730d6a290a4c38206e96","_deleted":true}]}' }
var b = require('sandboxed-module').require('./b', {});
b.foo();
@cliffano
cliffano / svn2gitloop.sh
Created July 18, 2012 00:24
svn2git loop in bash
#! /bin/bash
mkdir -p workspace
cd workspace
for PROJ in 'app1' 'app2' 'app3'
do
mkdir $PROJ
cd $PROJ
# for SVN repo with structure app/trunk, app/branches, app/tags
@cliffano
cliffano / gist:2641397
Created May 9, 2012 02:44
Mocha issue #414 example
var should = require('should');
function _something(cb) {
cb();
}
describe('foo', function () {
describe('bar', function () {
it('should do something', function (done) {
var x = {};