Skip to content

Instantly share code, notes, and snippets.

View dunglehome's full-sized avatar

Dung Le dunglehome

View GitHub Profile
@dunglehome
dunglehome / pycon-views.py
Last active August 29, 2015 14:26 — forked from miguelgrinberg/pycon-views.py
Generate statistics about PyCon 2014 videos
View pycon-views.py
import argparse
import re
from multiprocessing.pool import ThreadPool as Pool
import requests
import bs4
root_url = 'http://pyvideo.org'
index_url = root_url + '/category/50/pycon-us-2014'
@dunglehome
dunglehome / README.md
Created January 14, 2016 21:24 — forked from scttnlsn/README.md
Pub/sub with MongoDB and Node.js
View README.md

Pub/sub with MongoDB and Node.js

Setup:

$ mongo
> use pubsub
> db.createCollection('messages', { capped: true, size: 100000 })
> db.messages.insert({})
View FibonacciCommand.php
<?php
namespace HunterBundle\Command;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Input\InputArgument;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Formatter\OutputFormatterStyle;
@dunglehome
dunglehome / dspace
Created August 18, 2017 16:51
http://localhost:8080/solr/statistics/select?indent=on&version=2.2&start=0&rows=10&fl=*%2Cscore&qt=standard&wt=standard&explainOther=&hl.fl=&facet=true&facet.field=epersonid&q=type:0+owningItem:4636
View dspace
This XML file does not appear to have any style information associated with it. The document tree is shown below.
<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">1</int>
<lst name="params">
<str name="explainOther"/>
<str name="facet">true</str>
<str name="fl">*,score</str>
<str name="indent">on</str>
@dunglehome
dunglehome / gist:e106623173dfd90a6a764c1723e7043c
Created August 18, 2017 16:57
http://localhost:8080/solr/statistics/select?indent=on&version=2.2&start=0&rows=0&fl=*%2Cscore&qt=standard&wt=standard&explainOther=&hl.fl=&facet=true&facet.field=country&q=type:0+owningItem:4636
View gist:e106623173dfd90a6a764c1723e7043c
<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">1</int>
<lst name="params">
<str name="explainOther"/>
<str name="facet">true</str>
<str name="fl">*,score</str>
<str name="indent">on</str>
<str name="start">0</str>