Skip to content

Instantly share code, notes, and snippets.

Avatar

Nick O. albacoretuna

View GitHub Profile
View async-await-promise-all.js
"use strict";
const request = require('request-promise');
const headers = {
'User-Agent': 'scottwrobinson'
};
const repos = [
'scottwrobinson/camo',
View run-command-nodejs.js
// require an internal utility in node for running commands in command line
var exec = require('child_process').exec;
var child;
// get exec from that utily, give the command you want to run as it's first argument
child = exec('npm install ffi',
function (error, stdout, stderr) {
// these are the result, somehow, it's devided to when there's error, or output etc.
console.log('stdout: ' + stdout);
console.log('stderr: ' + stderr);
View exportjson.js
// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible).
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export.
var FORMAT_ONELINE = 'One-line';
var FORMAT_MULTILINE = 'Multi-line';
var FORMAT_PRETTY = 'Pretty';
var LANGUAGE_JS = 'JavaScript';
var LANGUAGE_PYTHON = 'Python';
View gist:dd21672ea15e12940de5
[user]
email =
name =
[core]
editor = vim
safecrlf = false
autocrlf = input
excludesfile = /home/omid/.gitignore
[github]
user = omidfi
View vim_cheatsheet.md

Introduction

  • C-a == Ctrl-a
  • M-a == Alt-a

General

:q        close
:w        write/saves
:wa[!]    write/save all windows [force]
:wq       write/save and close
@albacoretuna
albacoretuna / SassMeister-input-HTML.html
Created Jan 27, 2015
Generated by SassMeister.com.
View SassMeister-input-HTML.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Week 3</title>
<script type="text/javascript" src="modernizr.js"></script>
<link rel="stylesheet" href="reset.css" />
<link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Princess+Sofia" />
<link rel="stylesheet" href="style.css" />
@albacoretuna
albacoretuna / index.html
Last active Aug 29, 2015
Sekender A HTML5 app to find the nearest second hand store.
View index.html
<!DOCTYPE html>
<html>
<head>
<!-- I have used jQuery Mobile for the UI, Google api for the map. So here comes all the js libraries, jquery, jquery mobile, google maps -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css">
<link rel="stylesheet" href="styles.css">
<script src="http://code.jquery.com/jquery-1.11.1.min.js"></script>
<script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>
View jumbotron.html
<!-- row 2 -->
<div class="jumbotron">
<img src="img/jumbotron.jpg" alt="">
<h1> We treat your pets like our own</h1>
<p>At Wisdom Pet Medicine, we strive to blend the best in traditional and alternative healing techniques to diagnose and treat companion animals, including dogs, cats, birds, reptiles, rodents, and fish. </p>
</div>
@albacoretuna
albacoretuna / Fade in fade out
Created Aug 29, 2014
Fadeout Fadein hide... jquery functions
View Fade in fade out
fadeIn()
fadeOut()
hide()
fadeTo('fast',1)
View index.html
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width; user-scalable=no; initial-scale=1.0; maximum-scale=1.0;"/>
<script src="jquery-1.7.1.min.js"> </script>
<style type="text/css">
.rahmen {