Skip to content

Instantly share code, notes, and snippets.

View r17x's full-sized avatar
🤘
REconciling...

RiN r17x

🤘
REconciling...
View GitHub Profile
@sconstantinides
sconstantinides / manifest.json
Last active July 29, 2018 15:23
React PWA example
{
"short_name": "My App // Should be <= 12 characters. Appears on the home screen once installed ",
"name": "My App // Must be <= 45 characters. Appears in places with more space (install dialogs, etc.)",
"icons": [{
"src": "images/splashIcon.png // Android: Requires a PNG at least 512x512 for your startup screen. This is used along with your app name (above) and background color (below) to generate a splash screen. Learn more: https://developers.google.com/web/fundamentals/web-app-manifest/#add_a_splash_screen",
"sizes": "512x512",
"type": "image/png"
}, {
"src": "images/appIcon.png // Android requires a PNG at least 192x192 for your home screen icon",
"sizes": "192x192",
@sconstantinides
sconstantinides / index.html
Last active July 29, 2018 15:23
React PWA example
<!DOCTYPE html>
<html lang="en">
<head>
<!-- The usual suspects -->
<meta charset="utf-8">
<meta name="description"
content="My app is awesome because...">
<title>My awesome app</title>
<link rel="shortcut icon"
@Yoric
Yoric / Binary AST benchmarks.csv
Last active February 23, 2020 15:44
Binary AST benchmarks
Parsing benchmark duration (ms) Text (ideal syntax parsing heuristics) Text (full parsing) Pure syntax parsing Binary Binary vs ideal syntax parsing heuristics Binary vs full parsing Binary vs pure syntax parsing
frameworks/angular.1.6.5 1106 1061 1240 671 0.61 0.63 0.54
frameworks/backbone.1.3.3 135 138 105 76 0.56 0.55 0.72
frameworks/bootstrap.4.1.0 242 242 198 150 0.62 0.62 0.76
frameworks/chart.2.7.2 844 852 703 533 0.63 0.63 0.76
frameworks/ember.2.18.2 2583 2392 2155 1673 0.65 0.70 0.78
frameworks/foundation.6.4.3 659 652 544 427 0.65 0.65 0.78
frameworks/jquery.3.3.1 644 521 415 322 0.50 0.62 0.78
frameworks/moment.2.22.1 283 292 233 184 0.65 0.63 0.79
frameworks/react-dom.production.16.3.2 493 498 409 294 0.60 0.59 0.72
# https://regex101.com/r/AsjSye/5
# regex : (<select.*class\s*=\s*\".*)(required span12)(.*\"\s*>)
# Find Text : <select class="required span12"> change to <select class="chosen-select required span12">
# why use ? if you have 1000 Files and want to change it
# Change with ack + perl -pi -E 
$ ack -l  "(<select.*class\s*=\s*\".*)(required span12)(.*\"\s*>)" | xargs perl -pi -E "s/(<select.*class\s*=\s*\".*)(required span12)(.*\"\s*>)/\$1chosen-select required span12\$3/g" 

Thanks To : @dev-makassar @yusrideb

@nijicha
nijicha / install_nodejs_and_yarn_homebrew.md
Last active February 24, 2025 17:32
Install NVM, Node.js, Yarn via Homebrew
@r17x
r17x / submodule-git.md
Last active September 14, 2018 04:34 — forked from CristinaSolana/gist:1885435
Keeping a fork up to date

1. Clone your fork:

git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@r17x
r17x / arraySort.js
Last active February 21, 2018 02:05
ArraySortJavascript.js
Array.prototype.sorted = true;
Array.prototype.sortBy = function(p) {
// this = [] = Array || global array
this.sorted = ! this.sorted;
return ! this.
}
@chandraratnam
chandraratnam / mutt_mbsync_multipleaccounts.md
Last active January 21, 2025 17:30
Mutt + isync mbsync + gmail + multiple accounts.

Mutt + isync multiple accounts Unfinished

This is the setup that I use for mutt, I have two google domain account (read as gmail) and an institution where I work and study account. This means I have two gmail accounts and one outlook 365 account that i want to sync and read via mutt.

I want to store all my email locally as I travel a lot and will be in countries without easy internet access. For this I use mbsync (iSync). As it can handle multiple account types easily and efficently.

The setup works this way

[Remote Mail Servers] <= mbsync => [Local Mail Folders]

@mkjiau
mkjiau / axios-interceptors-refresh-token.js
Last active February 17, 2025 14:25
Axios interceptors for token refreshing and more than 2 async requests available
let isRefreshing = false;
let refreshSubscribers = [];
const instance = axios.create({
baseURL: Config.API_URL,
});
instance.interceptors.response.use(response => {
return response;
}, error => {
@kapillamba4
kapillamba4 / pacman.md
Created November 15, 2017 07:57
ArchLinux Pacman Cheatsheet

Update package list

sudo pacman -Syy

Update and upgrade all

sudo pacman -Syu

Install specific package

sudo pacman -S pkgname

Find available packages