Skip to content

Instantly share code, notes, and snippets.

View kru's full-sized avatar
Tinkering...

Kris Pamungkas kru

Tinkering...
View GitHub Profile
@kru
kru / ubuntu_agnoster_install.md
Created January 22, 2017 17:20 — forked from renshuki/ubuntu_agnoster_install.md
Ubuntu 14.04 + Terminator + Oh My ZSH with Agnoster Theme

Install Terminator (shell)

sudo add-apt-repository ppa:gnome-terminator
sudo apt-get update
sudo apt-get install terminator

Terminator should be setup as default now. Restart your terminal (shortcut: "Ctrl+Alt+T").

Install ZSH

@kru
kru / request.json
Last active May 19, 2017 16:39
request to the endpoint staging
{
"data": {
"attributes": {
"first_name": "Carley"
},
"relationships": {
"object-custom-fields": {
"data": [
{
"attributes": {
@kru
kru / response.json
Created May 19, 2017 16:44
response from the endpoint staging
{
"data": {
"type": "persons",
"id": "52",
"attributes": {
"prefix": "Dr.",
"first_name": "Carley",
"middle_name": "Rosemarie",
"last_name": "McClure",
"preferred_name": "Darrion McClure",
### React Native 0.48 still can't using java 9
make sure you have brew installed
```/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"```
`brew tap caskroom/version`
`brew cask install java8`
@kru
kru / closure.js
Last active February 26, 2018 09:54
closure
var myAwesomeModule = function(x) {
return function() {
var y = x * 10;
console.log(y);
};
};
var multiplyBy100 = myAwesomeModule(10);
var multiplyBy25 = myAwesomeModule(2.5);
var myAwesomeModule = (function(members) {
function change() {
publicAPI.showMember = removeFalsy;
}
function getMembers() {
console.log(members);
}
function removeFalsy() {
@kru
kru / module.js
Last active February 26, 2018 09:31
var myAwesomeModule = function(members) {
function change() {
publicAPI.showMember = removeFalsy;
}
function getMembers() {
console.log(members);
}
function removeFalsy() {
/**
* policyCategory: this is either
* 0: General,
* 1: Land & Agriculture,
* 3: Energy
* 4: IPPU & Waste
* 5: Water and Fisheries
*/
const POLICY_CATEGORY = {
GENERAL: 0,
@kru
kru / query.log
Created August 30, 2019 08:06
Query results for 2039 contacts
This file has been truncated, but you can view the full file.
[2019-08-30 08:01:27] local.INFO: QUERIES:[{"query":"select `id` from `contact_emails` where `contact_id` in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)","bindings":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],"time":4.26},{"query":"delete from `emails` where `contact_email_id` in (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?
This file has been truncated, but you can view the full file.
{
"log": {
"version": "1.2",
"creator": {
"name": "WebInspector",
"version": "537.36"
},
"pages": [
{
"startedDateTime": "2019-09-19T07:13:39.414Z",