Skip to content

Instantly share code, notes, and snippets.

View iamloivx's full-sized avatar

Xuân-Lợi Vũ iamloivx

View GitHub Profile
@pcn
pcn / logback.conf
Created May 24, 2012 17:31
trying for a logstash conf file that works with java's logback logger
input {
# file {
# path => ["/var/log/knewton/*/*.log"]
# type => "knewton_logback"
# }
stdin {
type => "knewton_logback"
}
}
@morrelinko
morrelinko / m2cache.py
Created May 6, 2014 16:25
Copy gradle store of libraries into .m2 local cache
import os
import shutil
gradle_cache_dir = 'C:\\Users\\morrelinko\\.gradle\\caches\\modules-2\\files-2.1'
maven_cache_dir = 'C:\\Users\\morrelinko\\.m2\\repository2'
"""
Build a dictionary of java libraries
"""
packages = {}
@briandk
briandk / pasteUsingSepAndCollapseInR.R
Created November 27, 2014 07:11
Understanding `sep` and `collapse` in R using `paste()
# The difference between the `sep` and `collapse` arguments
# in paste can be thought of like this:
#
# paste can accept multiple *vectors* as input, and will
# concatenate the ith entries of each vector pairwise
# (or tuplewise), if it can.
#
# When you pass paste multiple vectors, sep defines what
# separates the entries in those tuple-wise concatenations.
#
@gbuckingham89
gbuckingham89 / AuthServiceProvider.php
Last active August 22, 2022 12:01
Blog: Laravel Authentication Customer User Provider Demo
<?php
namespace App\Authentication;
use Auth;
use App\Authentication\UserProvider;
use Illuminate\Support\ServiceProvider;
class AuthServiceProvider extends ServiceProvider
{