Skip to content

Instantly share code, notes, and snippets.

View nemmarramos's full-sized avatar
🎯
Focusing

Nemmar Ramos nemmarramos

🎯
Focusing
  • Metro Manila, Philippines
  • 20:17 (UTC +08:00)
View GitHub Profile
@nemmarramos
nemmarramos / serverless.yml
Created June 25, 2021 08:23 — forked from codecitizen/serverless.yml
A serverless.yml file configuring a AWS ElastiCache redis instance that is accessible by all AWS Lambda functions deployed by this serverless function.
service: my-service
provider:
name: aws
runtime: nodejs8.10
stage: ${opt:stage, 'dev'}
environment:
REDIS_HOST:
"Fn::GetAtt": [ElasticCacheCluster, RedisEndpoint.Address]
functions:
@nemmarramos
nemmarramos / ffmpeg
Created December 15, 2020 05:47 — forked from bnerd/ffmpeg
Encode RTMP input stream into multiple outputs with ffmpeg
ffmpeg -re -i rtmp://localhost/live/input_stream -acodec libfaac -ab 128k -vcodec libx264 -s 640x360 -b:v 500k -preset medium -vprofile baseline -r 25 -f flv rtmp://localhost/live/medium_500k -acodec libfaac -ab 128k -vcodec libx264 -s 480x272 -b:v 300k -preset medium -vprofile baseline -r 25 -f flv rtmp://localhost/live/medium_300k -acodec libfaac -ab 128k -c:v libx264 -s 320x200 -b:v 150k -preset:v fast -profile:v baseline -level 1.2 -r 25 -f flv rtmp://localhost/live/medium_150k -acodec libfaac -vn -ab 48k -f flv rtmp://localhost/live/audio_only
@nemmarramos
nemmarramos / review-checklist.md
Created October 9, 2018 03:34 — forked from bigsergey/review-checklist.md
Front-end Code Review Checklist

Review checklist

General

  1. Does the code work?
  2. Description of the project status is included.
  3. Code is easily understand.
  4. Code is written following the coding standarts/guidelines (React in our case).
  5. Code is in sync with existing code patterns/technologies.
  6. DRY. Is the same code duplicated more than twice?
@nemmarramos
nemmarramos / serve.py
Created October 1, 2018 09:11 — forked from chrisbolin/serve.py
Python SimpleHTTPServer for Static Serving (React / Angular / Ember) in HTML5 mode (a la mod_rewrite)
'''
Taken from:
http://stackoverflow.com/users/1074592/fakerainbrigand
http://stackoverflow.com/questions/15401815/python-simplehttpserver
'''
import SimpleHTTPServer, SocketServer
import urlparse, os
PORT = 3000
function fib(n) {
const sqt = Math.sqrt(5);
const grd = (1 + sqt) / 2;
return Math.floor(Math.pow(grd, n) / sqt + 0.5);
}
@nemmarramos
nemmarramos / QuickJSQuestion.js
Last active December 21, 2017 10:17 — forked from lukealbao/QuickJSQuestion.js
Quick JS Question
var inventory = {
'000001': {
name: 'Banana Slicer',
price: 2.99
},
'000002': {
name: 'Three Wolves Tea Cozy',
price: 14.95
}
};