Skip to content

Instantly share code, notes, and snippets.

View neroze's full-sized avatar
🎯
Focusing

Jumper neroze

🎯
Focusing
View GitHub Profile
@neroze
neroze / gist:c299a1573098f2ca532d4c943e2c4dc4
Created June 6, 2024 07:57
search with CLI - find + grep
❯ find [tareget folder] -type d -name '[folder to ingore]' -prune -o -type f -print | xargs grep --color=auto "[text to search]"
❯ find ./core/ -type d -name 'node_modules' -prune -o -type f -print | xargs grep --color=auto "click"
@neroze
neroze / .dockerignore
Created September 6, 2022 10:23 — forked from ksmithut/.dockerignore
Node Docker Compose nodemon
node_modules
/**
* Simple object check.
* @param item
* @returns {boolean}
*/
export function isObject(item) {
return item && typeof item === 'object' && !Array.isArray(item);
}
/**
# Node.js Boilerplate
-----------------------------------------------------------------
# 1: https://github.com/sahat/hackathon-starter?source=post_page---------------------------
# 2: https://github.com/kriasoft/nodejs-api-starter?source=post_page---------------------------
# 3: https://github.com/madhums/node-express-mongoose?source=post_page---------------------------
# 4: https://github.com/talyssonoc/node-api-boilerplate?source=post_page---------------------------
@neroze
neroze / index.js
Last active February 4, 2019 11:12
set Up fish alias
#!/usr/bin/env node
console.log('yay gist')
const shell = require('shelljs')
shell.exec('sudo touch ~/config/f/index.js')
@neroze
neroze / install-docker.sh
Created January 17, 2019 04:07 — forked from dweldon/install-docker.sh
Install docker CE on Linux Mint 18.3
#!/usr/bin/env bash
# https://docs.docker.com/install/linux/docker-ce/ubuntu/
sudo apt-get install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable"
sudo apt-get update
sudo apt-get install docker-ce
# https://docs.docker.com/compose/install/
@neroze
neroze / class-decorator-function-example
Created June 25, 2018 05:05
A class decorator function
/*
A class decorator function will receive target class UserRef, which is User in above example (on which decorator is applied)
and must return a constructor function. This opens the door of infinite possibilities that you can do with the decorator.
Hence class decorators are more popular than method/property decorators
*/
Ref: https://itnext.io/a-minimal-guide-to-ecmascript-decorators-55b70338215e
function withLoginStatus( UserRef ) {
return class extends UserRef {
@neroze
neroze / disposable-email-provider-domains
Created May 25, 2018 08:53
List of disposable email provider domains
0815.ru
0wnd.net
0wnd.org
10minutemail.co.za
10minutemail.com
123-m.com
1fsdfdsfsdf.tk
1pad.de
20minutemail.com
21cn.com
@neroze
neroze / throw-away-email-domains.js
Created May 25, 2018 08:33
Throw away email domains
export default [
'0815.ru',
'0wnd.net',
'0wnd.org',
'10minutemail.co.za',
'10minutemail.com',
'123-m.com',
'1fsdfdsfsdf.tk',
'1pad.de',
'20minutemail.com',
@neroze
neroze / .babelrc config
Created May 9, 2018 10:09
.babelrc config
{
"env": {
"production": {
"presets": [
["env", {
"targets": {
"browsers": ["last 2 versions", "safari >= 7"]
}
}],
"react"