Some reoccurring git commands
-
Graphical git log
git log --graph --oneline --decorate -
Difference between local file and remote
git diff origin/master path/to/file.ext
![]() |
VOOZH | about |
Instantly share code, notes, and snippets.
| /** |
| * Prgram to test async.queue usage |
| * - gerenates tasks at the rate of "taskGenRate" |
| * - tasks are proocessed at the rate of "taskProcessRate" |
| * - process is paused when queue size reaches "maxQueueSize" |
| */ |
| const async = require('async'); |
| let i = 0; |
| /** |
| * Prgram to test async.queue usage |
| * - gerenates tasks at the rate of "taskGenRate" |
| * - tasks are proocessed at the rate of "taskProcessRate" |
| * - process is paused when queue size reaches "maxQueueSize" |
| */ |
| const async = require('async'); |
| let i = 0; |
| node_modules |
Graphical git log
git log --graph --oneline --decorate
Difference between local file and remote
git diff origin/master path/to/file.ext
| var express = require('express'); |
| var router = express.Router(); |
| var babel = require("babel-core"); |
| var React = require('react'); |
| // Get ReactDOMServer for server side rendering |
| var ReactDOMServer = require('react-dom/server'); |
| // Compile code transformed by babel.transformFileSysnc |
| module._compile(babel.transformFileSync('./public/js/components/header.js').code); |
| // Save it to a accessible header before moudle.exports gets replaaced |
Contained here are trival stuffs. Like with all trival stuffs, its inevitably bound to be forgotten.
| <!DOCTYPE html> |
| <html> |
| <head> |
| <meta name="viewport" content="initial-scale=1.0, user-scalable=no" /> |
| <style type="text/css"> |
| html { height: 100% } |
| body { height: 100%; margin: 0; padding: 0 } |
| #map_canvas { |
| position: absolute; |
| width: 100%; |
| #include <SoftwareSerial.h> |
| SoftwareSerial mySerial = SoftwareSerial(10, 11);; // RX, TX |
| void setup() { |
| pinMode(10,INPUT); |
| pinMode(11,OUTPIT); |
| mySerial.begin(19200);// this connects to the other USART device |
| Serial.begin(19200); // this one connects to a computer via USB |
| while (!Serial) { |
| javascript:(function(){%20window.open('http://talkgadget.google.com/talkgadget/popout','myWindow',%20'status=1,%20height=600,width=400,resizable%20=%200,location=0');%20})(); |