Use the following code in .eslintrc.js
in node/backend projects:
// This is a workaround for https://github.com/eslint/eslint/issues/3458
require('@rushstack/eslint-config/patch/modern-module-resolution')
module.exports = {
extends: [
alias gst='git status' | |
alias gco='git checkout' | |
alias ga='git add' | |
alias gd='git diff' | |
alias gc='git commit' | |
alias gp='git push' | |
alias gl='git pull' | |
alias gs='git stash' | |
# make these commands work predictably in all environments |
# If not running interactively, don't do anything | |
case $- in | |
*i*) ;; | |
*) return;; | |
esac | |
# Control bash history | |
# http://www.biostat.jhsph.edu/~afisher/ComputingClub/webfiles/KasperHansenPres/IntermediateUnix.pdf | |
# https://unix.stackexchange.com/questions/48713/how-can-i-remove-duplicates-in-my-bash-history-preserving-order | |
# don't put duplicate lines or lines starting with space in the history. |
export DEBIAN_FRONTEND=noninteractive | |
apt-get update -y | |
apt-get install -y acl sudo software-properties-common python-is-python3 | |
apt-add-repository -y ppa:ansible/ansible | |
apt-get install -y ansible |
" | |
" A (not so) minimal vimrc. | |
" | |
" You want Vim, not vi. When Vim finds a vimrc, 'nocompatible' is set anyway. | |
" We set it explicitely to make our position clear! | |
set nocompatible | |
filetype plugin indent on " Load plugins according to detected filetype. |
[user] | |
name = "Tabrez Iqbal" | |
email = "[email protected]" | |
[color] | |
ui = true | |
[color "branch"] | |
current = green bold | |
local = yellow bold | |
remote = green bold |
# If not running interactively, don't do anything | |
[[ $- != *i* ]] && return | |
export TERM="xterm-256color" | |
fpath+=~/.zsh/pure | |
autoload -U promptinit; promptinit | |
autoload -U compinit; compinit | |
prompt pure |
const { GraphQLServer } = require('graphql-yoga'); | |
const server = new GraphQLServer({ typeDefs, resolvers }); | |
server.start(() => console.log('Server is running...')); | |
// run integration tests | |
// how to stop the server? |
"""Implement doubly-linked list in Python.""" | |
class Node: | |
"""Node implementation for doubly-linked list.""" | |
def __init__(self, v=None, next=None, prev=None): | |
"""Construct a node.""" | |
self.value = v | |
self.next = next |