Skip to content

Instantly share code, notes, and snippets.

View lktslionel's full-sized avatar
👨‍💻

Lionel LONKAP TSAMBA lktslionel

👨‍💻
View GitHub Profile
@lktslionel
lktslionel / v1.js
Last active February 26, 2016 01:13
/**
* Auto-generated code below aims at helping you parse
* the standard input according to the problem statement.
**/
var inputs = readline().split(' ');
var N = parseInt(inputs[0]); // the total number of nodes in the level, including the gateways
var L = parseInt(inputs[1]); // the number of links
var E = parseInt(inputs[2]); // the number of exit
@lktslionel
lktslionel / .gitignore
Last active May 3, 2016 20:22
VScode Preferences
snippets
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
@lktslionel
lktslionel / tput.bash
Last active October 17, 2016 11:17
Hands on with the tput command
# More on tput : http://www.tldp.org/HOWTO/Bash-Prompt-HOWTO/x405.html
# Print text $t at the end of the current line
tput cuf $(( $(tput cols) - ${#t} )) 12 && printf "%s" $t
@lktslionel
lktslionel / bash-script-startup.sh
Last active October 24, 2016 15:26
Snippet : bash script startup - getopt
unset OPTIND
while getopts ":s:d:c:a:hv" opt; do
case $opt in
h)
usage
exit 0
;;
v)
GLOBAL_VERBOSE_ENABLED=$TRUE
@lktslionel
lktslionel / Excel-convert-disk-space-units--B-Kb-Mb-Gb
Created December 1, 2016 11:04
Excel formula to convert Byte to K, M, G
=SI(
DROITE(SUPPRESPACE(SUBSTITUE(C4;".";",")))="K";
PRODUIT(
CNUM(GAUCHE(SUPPRESPACE(SUBSTITUE(C4;".";","));NBCAR(SUPPRESPACE(SUBSTITUE(C4;".";",")))-1));
1024
);
SI(
DROITE(SUPPRESPACE(SUBSTITUE(C4;".";",")))="M";
PRODUIT(
CNUM(GAUCHE(SUPPRESPACE(SUBSTITUE(C4;".";","));NBCAR(SUPPRESPACE(SUBSTITUE(C4;".";",")))-1));
@lktslionel
lktslionel / git-clone-identity-key.sh
Created December 14, 2016 09:43
Git clone with a specific identity key
ssh-agent bash -c 'ssh-add -D && ssh-add <path/to/your/ssh/key/file> && git clone git@github.com:<username>/<repo>.git'
@lktslionel
lktslionel / README.md
Created December 31, 2016 01:11 — forked from leonardofed/README.md
A curated list of AWS resources to prepare for the AWS Certifications


A curated list of AWS resources to prepare for the AWS Certifications

A curated list of awesome AWS resources you need to prepare for the all 5 AWS Certifications. This gist will include: open source repos, blogs & blogposts, ebooks, PDF, whitepapers, video courses, free lecture, slides, sample test and many other resources.


Index:

@lktslionel
lktslionel / README.md
Last active January 2, 2017 09:47
List of my vscode extensions

Vscode extension

Freeze extensions : get list of extensions

code --list-extensions > vscode-exts.list

Install extension from the list :

for ext in $(cat /path/to/vscode-exts.list); do 
@lktslionel
lktslionel / installvagrant
Created January 3, 2017 10:45 — forked from rrgrs/installvagrant
installs brew, virtualbox, and vagrant in osx
if ! type "brew" > /dev/null; then
ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)";
fi
brew tap phinze/homebrew-cask && brew install brew-cask;
brew cask install vagrant;
brew cask install virtualbox;