Skip to content

Instantly share code, notes, and snippets.

Raphael Ferreira FerreiraRaphael

Block or report user

Report or block FerreiraRaphael

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View Preferences.sublime-keymap
[
{ "keys": ["ctrl+shift+o"], "command": "prompt_open_folder" },
{ "keys": ["shift+ctrl+i"], "command": "reindent", "args": {"single_line": false}},
{ "keys": ["ctrl+tab"], "command": "next_view" },
{ "keys": ["ctrl+shift+tab"], "command": "prev_view" },
{ "keys": ["ctrl+v"], "command": "paste_and_indent" },
{ "keys": ["ctrl+f"], "command": "show_panel", "args": {"panel": "replace", "reverse": false} },
{ "keys": ["ctrl+shift+v"], "command": "paste" },
{ "keys": ["ctrl+;"], "command": "toggle_comment", "args": { "block": false } },
{ "keys": ["ctrl+shift+;"], "command": "toggle_comment", "args": { "block": true } },
@FerreiraRaphael
FerreiraRaphael / fedora-init.sh
Last active Aug 19, 2016
Shells com meus apps favoritos do fedora
View fedora-init.sh
#!/bin/sh
#update fedora
sudo dnf upgrade
#dmenu
sudo dnf install dmenu
#Gnome Tweak Tools
sudo dnf install gnome-tweak-tool
@FerreiraRaphael
FerreiraRaphael / create_superuser_postgresql.sh
Last active Jan 24, 2017
How to install, config and create a superuser on postgresql fedora
View create_superuser_postgresql.sh
#Login as root
su -
#Switch to postgres user
su postgres
#Connect to the DB
psql
#Create user
CREATE USER username SUPERUSER INHERIT CREATEDB CREATEROLE;
#Alter it`s password
ALTER USER username PASSWORD 'password';
@FerreiraRaphael
FerreiraRaphael / addsudo.sh
Created Apr 9, 2017
scripts for a clean debian
View addsudo.sh
#!/bash/bin
#enable sudo to current user
apt-get install sudo
adduser whoami sudo
reset
@FerreiraRaphael
FerreiraRaphael / cloudSettings
Last active Aug 23, 2017
Visual Studio Code Settings Sync Gist
View cloudSettings
{"lastUpload":"2017-08-23T19:05:46.953Z","extensionVersion":"v2.8.3"}
View composicao-funcional.js
//Baixe este arquivo em https://gist.github.com/FerreiraRaphael/541090faceef655e9d949f5ce926f855
//Execute:
//node <nome-do-arquivo>.js
let resultadoEsperado, resultado;
//Composição funcional
const usuarios = [
{
id: 1,
nome: "Raphael"
View .eslintrc.js
{
"extends": ["airbnb", "prettier"],
"env": {
"browser": true,
"node": true,
"mocha": true
},
"globals": {
"describe": false,
"it": false,
@FerreiraRaphael
FerreiraRaphael / extract.sh
Created Feb 28, 2018
shell Extract function
View extract.sh
function extract {
if [ -z "$1" ]; then
# display usage if no parameters given
echo "Usage: extract <path/file_name>.<zip|rar|bz2|gz|tar|tbz2|tgz|Z|7z|xz|ex|tar.bz2|tar.gz|tar.xz>"
echo " extract <path/file_name_1.ext> [path/file_name_2.ext] [path/file_name_3.ext]"
return 1
else
for n in $@
do
if [ -f "$n" ] ; then
@FerreiraRaphael
FerreiraRaphael / cloudSettings
Last active Mar 19, 2018
Visual Studio Code Settings Sync Gist
View cloudSettings
{"lastUpload":"2018-03-19T14:30:56.963Z","extensionVersion":"v2.9.0"}
You can’t perform that action at this time.