Skip to content

Instantly share code, notes, and snippets.



  • Laguna, Philippines
View GitHub Profile
arvi / sublime-settings-osx.json
Last active Nov 8, 2021
Sublime Settings OSX
View sublime-settings-osx.json
"characters": "<",
"selector": "text.html"
"characters": ".",
"selector": "source.js"
arvi /
Created Nov 30, 2016 — forked from NightlyNexus/
OkHttp 3 implementation of Volley's HttpStack
* Copyright (C) 2016 Eric Cochran
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* Unless required by applicable law or agreed to in writing, software
arvi / promise-dot-all.js
Created Apr 23, 2018 — forked from indiesquidge/promise-dot-all.js
Recreating Promise.all with async/await
View promise-dot-all.js
Let us re-create `Promise.all`
`Promise.all` method returns a promise that resolves when all of the promises in the iterable argument have resolved,
or rejects with the reason of the first passed promise that rejects.
Read more about `Promise.all` on MDN:
A basic example would be something like this:
arvi / cloudSettings
Last active Jun 9, 2019
Visual Studio Code Settings Sync Gist
View cloudSettings
View framework7-messages-socketio.js
var myApp = new Framework7();
var $$ = Dom7;
// Conversation flag
var conversationStarted = false;
// Init Messages
var myMessages = myApp.messages('.messages', {
autoLayout: true
arvi / employee-update.js
Created Oct 3, 2018
View employee-update.js
switch (idType) {
case 'national':
case 'iqama':
case 'visa':
if (isPrimaryId) {
form.append('id_type', idType);
form.append('id_number', idNumber);
form.append('id_issuing_country', idIssuingCountry);
form.append('id_expiration', idExpiration);
View promises.js
function hello() {
return new Promise(function(resolve, reject) {
function helloThere() {
return 'helloThere';
arvi /
Created Jan 20, 2018 — forked from katychuang/
remove mongodb that was installed via brew
#!/usr/bin/env sh
# checks to see if running
launchctl list | grep mongo
launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.mongodb.plist
launchctl remove homebrew.mxcl.mongodb
pkill -f mongod
arvi / client.js
Created Aug 30, 2016 — forked from crtr0/client.js
A simple example of setting-up dynamic "rooms" for clients to join
View client.js
// set-up a connection between the client and the server
var socket = io.connect();
// let's assume that the client page, once rendered, knows what room it wants to join
var room = "abc123";
socket.on('connect', function() {
// Connected, let's sign-up for to receive messages for this room
socket.emit('room', room);
arvi /
Last active Apr 27, 2017 — forked from dionysius/
Setup launcher icon (.desktop file) for AMPPS. Tested for elementaryOS freya, but should work with most ubuntu derivates.

Fix/Create AMPPS Launcher icon (.desktop file)

Install AMPPS with default options (at this time of writing there are no options). Expecting it is installed in /usr/local/ampps/*

Since its important to place the new files at specific locations, you need to adapt the filename as requested. All files are owned by root.

ampps_starter: place this file exactly as /usr/local/bin/ampps and make it executable