Skip to content

Instantly share code, notes, and snippets.

View v0lkan's full-sized avatar
🎸
totally rocking it 🚀.

Volkan Özçelik v0lkan

🎸
totally rocking it 🚀.
View GitHub Profile
@v0lkan
v0lkan / evolution-of-a-fetch.js
Last active February 26, 2018 08:27
The Evolution of a Fetch
// Assume `dispatch` and `fetchFromNetwork` are defined elsewhere.
// ## 1. CPS With Nodebacks
// This is the old-school-style fetch. Mostly here for
// historical reasons.
//
// Yet, contrary to the arguments against using it,
// it‘s not that hard to maintain this code when you are
// careful and know what you are doing.
@paulirish
paulirish / gist:366184
Created April 14, 2010 18:59
html5 geolocation with fallback.
// geo-location shim
// currentely only serves lat/long
// depends on jQuery
// doublecheck the ClientLocation results because it may returning null results
;(function(geolocation){
if (geolocation) return;
@v0lkan
v0lkan / rafraf.js
Last active May 5, 2018 16:03
Double requestAnimatioFrame FTW!
const rafraf = (callback) => {
if (!window.requestAnimationFrame) {return null;}
return window.requestAnimationFrame(() =>
window.requestAnimationFrame(callback)
);
};
@v0lkan
v0lkan / engineer.md
Last active June 7, 2021 07:18
The Evolution of a Software Engineer

This gist outlines the change in the depth and breadth of the tasks and responsibilities of a software engineer as she continuously improves herself.

I created this to supplement a discussion in an internal slack group; then I though the rest of the world might benefit from this too.

Contributions are always welcome.

Junior Engineer

  • Knowledge
@v0lkan
v0lkan / index.md
Last active October 24, 2022 01:40
List of my useful gists, because GitHub is terrible at arranging them.

About

This is a collection of recipes that I gather from various sources.

It is NOT a replacement for the official docs. I maintain them at a “best effort” basis.

I also provide links to official references in these recipes whenever applicable.

Enjoy, and may the source be with you 🦄.

@1Marc
1Marc / workshops-planning.md
Last active January 20, 2023 02:34
Workshop Planning

This gist is no longer in use.

@v0lkan
v0lkan / silence.sh
Last active July 20, 2023 12:03
How to Have a Silent and High-Performing Western Digital MyCloud Mirror
#
# Needless to say, I (Volkan Ozcelik) take no responsibility, whatsoever,
# about what will happen to your NAS when you try these.
# When did it to mine, I observed *ENORMOUS* performance gain and a zen-like silence.
#
# +----------------------------------------------------------+
# | WHAT YOU ARE GOING TO DO CAN LIKELY VOID YOUR WARRANTY |
# | SO PROCEED WITH CAUTION |
# +----------------------------------------------------------+
#
@v0lkan
v0lkan / docker-i-t-trivia.md
Last active July 25, 2023 04:35
docker run -i -t
docker run -i -t --name nodejs ubuntu:latest /bin/bash

So here, -i stands for interactive mode and -t will allocate a pseudo terminal for us.

Some more trivia about these flags.

@trevnorris
trevnorris / perf-flame-graph-notes.md
Last active December 24, 2023 05:25
Quick steps of how to create a flame graph using perf

The prep-script.sh will setup the latest Node and install the latest perf version on your Linux box.

When you want to generate the flame graph, run the following (folder locations taken from install script):

sudo sysctl kernel.kptr_restrict=0
# May also have to do the following:
# (additional reading http://unix.stackexchange.com/questions/14227/do-i-need-root-admin-permissions-to-run-userspace-perf-tool-perf-events-ar )
sudo sysctl kernel.perf_event_paranoid=0
@v0lkan
v0lkan / JFDI.md
Created May 14, 2012 16:27
Jedis Feel Doin' It!
Nowadays, being really busy has become something worth bragging about or something you can't escape. 
You will probably even blame your commitments for stealing your time.

But is it truly impossible for you to make time for your "dream project"? 
Are you busy or is it avoidance?

Really. Look at your schedule; and put in a little "dream" time. 
Everything else would benefit more if you spend some time caring for your passions ;)

#JFDI™ (*):