Skip to content

Instantly share code, notes, and snippets.

@NonPolynomial
NonPolynomial / .eslintrc.js
Last active May 10, 2021 20:32
disable airbnb rules when using typescript-eslint
const tsRules = Reflect.ownKeys(
require('@typescript-eslint/eslint-plugin').rules,
);
const airbnbRules = require('eslint-config-airbnb-base')
.extends.map((e) => Reflect.ownKeys(require(e).rules))
.reduce((acc, cur) => [...acc, ...cur], []);
const disabledRules = airbnbRules
.filter((airbnbRule) => tsRules.includes(airbnbRule))

Setup multiple git identities & git user informations

/!\ Be very carrefull in your setup : any misconfiguration make all the git config to fail silently ! Go trought this guide step by step and it should be fine 😉

Setup multiple git ssh identities for git

  • Generate your SSH keys as per your git provider documentation.
  • Add each public SSH keys to your git providers acounts.
  • In your ~/.ssh/config, set each ssh key for each repository as in this exemple:
cat package.json | grep version | sed "s/^.*\"version\".*\"\(.*\)\".*$/\1/"
@NonPolynomial
NonPolynomial / README.md
Created August 10, 2019 11:49
CommonJS Markdown Extension Helper

CommonJS Markdown Extension Helper

extension helper for commonjs projects to require markdown files