Skip to content

Instantly share code, notes, and snippets.

View bouyagas's full-sized avatar
🏠
Working from home

Mohamed Bouyagui Gassama bouyagas

🏠
Working from home
View GitHub Profile
@bouyagas
bouyagas / .tmux.conf
Created February 15, 2020 01:19 — forked from rsp/.tmux.conf
The best and greatest tmux.conf ever - improved!
# The best and greatest tmux.conf ever - improved!
# https://gist.github.com/rsp/f4770a1fe8ea7e2378ac3a16e01a2b53
# Here are some customizations done by Rafał Pocztarski:
# use Ctrl+Backslash instead of Ctrl+A or Ctrl+B
# use Slash to split vertically
# use Backslash to split horizontally
unbind-key C-b
set -g prefix 'C-\'
bind-key 'C-\' send-prefix
@bouyagas
bouyagas / init.vim
Created February 13, 2020 23:36
neovim configuration
" vim:foldmethod=marker:foldlevel=0
" vim-plug {{{
call plug#begin()
" color scheme
Plug 'chriskempson/base16-vim'
" syntax highlighting
Plug 'peterhoeg/vim-qml'
@bouyagas
bouyagas / mongodb_cheat_sheet.md
Created November 24, 2019 09:59 — forked from bradtraversy/mongodb_cheat_sheet.md
MongoDB Cheat Sheet

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@bouyagas
bouyagas / node_nginx_ssl.md
Created September 28, 2019 22:50 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

@bouyagas
bouyagas / vanilla-js-cheatsheet.md
Created August 20, 2019 09:14 — forked from thegitfather/vanilla-js-cheatsheet.md
Vanilla JavaScript Quick Reference / Cheatsheet
@bouyagas
bouyagas / postgres-cheatsheet.md
Created March 11, 2019 21:30 — forked from Kartones/postgres-cheatsheet.md
PostgreSQL command line cheatsheet

PSQL

Magic words:

psql -U postgres

Some interesting flags (to see all, use -h or --help depending on your psql version):

  • -E: will describe the underlaying queries of the \ commands (cool for learning!)
  • -l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
@bouyagas
bouyagas / Readme.md
Created October 9, 2018 06:09 — forked from ErikCH/Readme.md
@bouyagas
bouyagas / docker-help.md
Created August 21, 2018 02:11 — forked from bradtraversy/docker-help.md
Docker Commands, Help & Tips

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

@bouyagas
bouyagas / webdev_online_resources.md
Created July 17, 2018 06:30 — forked from bradtraversy/webdev_online_resources.md
Online Resources For Web Developers (No Downloading)
@bouyagas
bouyagas / ssh.txt
Created July 14, 2018 09:31 — forked from bradtraversy/ssh.md
SSH & DevOps Crash Course Snippets
# Login via SSH with password (LOCAL SERVER)
> ssh brad@192.168.1.29
# Create folder, file, install Apache (Just messing around)
mkdir test
cd test
touch hello.txt
sudo apt-get install apache2
# Generate Keys