Skip to content

Instantly share code, notes, and snippets.

View rafaelBadan's full-sized avatar
🎯
Focusing

Rafael rafaelBadan

🎯
Focusing
View GitHub Profile
@rafaelBadan
rafaelBadan / docker-volume-directory.md
Created November 27, 2020 12:39 — forked from giansalex/docker-volume-directory.md
Docker volume in specify path (Linux)

Create docker volume

Create new docker volume in specific path.

Create Directory to save volume data

mkdir -p /mnt/xxxx/volume/data

Create volume with above path

# Audit log is only avaliable in MongoDB Enterprise and MongoDB Atlas
# auditLog:
# destination: <string>
# format: <string>
# path: <string>
# filter: <string>
systemLog:
verbosity: 0
quiet: false
traceAllExceptions: true
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>GoBarber</title>
<link rel="stylesheet" href="/styles.css" />
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>GoBarber</title>
<link rel="stylesheet" href="/styles.css" />
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<title>GoBarber</title>
<link rel="stylesheet" href="/styles.css"/>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/flatpickr/dist/flatpickr.min.css">
@rafaelBadan
rafaelBadan / print_progress.py
Created February 1, 2018 14:23 — forked from aubricus/License
Python Progress Bar
# -*- coding: utf-8 -*-
# Print iterations progress
def print_progress(iteration, total, prefix='', suffix='', decimals=1, bar_length=100):
"""
Call in a loop to create terminal progress bar
@params:
iteration - Required : current iteration (Int)
total - Required : total iterations (Int)
@rafaelBadan
rafaelBadan / _webserver.md
Created January 8, 2018 18:06 — forked from jgravois/_webserver.md
a simple guide for getting a local web server set up

Do I have a web server running?


having a web server turned on doesn't necessarily mean you are serving pages on the world wide web. its what allows you to load your own static files (.html, .js etc.) in a browser via http://.

if you're not sure whether or not you have a web server running, no problem! its easy to confirm.

what happens when you visit http://localhost/?

@rafaelBadan
rafaelBadan / scrapingexample.py
Created December 21, 2017 18:04 — forked from kashaziz/scrapingexample.py
Example of web scraping using Python and BeautifulSoup.
'''
Example of web scraping using Python and BeautifulSoup.
Sraping ESPN College Football data
http://www.espn.com/college-sports/football/recruiting/databaseresults/_/sportid/24/class/2006/sort/school/starsfilter/GT/ratingfilter/GT/statuscommit/Commitments/statusuncommit/Uncommited
The script will loop through a defined number of pages to extract footballer data.
'''
from bs4 import BeautifulSoup
@rafaelBadan
rafaelBadan / JSON with JS.md
Created November 4, 2017 19:44
Access local JSON data with Javascript

What

An updated guide/collection of guides on how to access JSON data with JavaScript

Original Question on Stack Exchange.


Example 1

For reading the external Local JSON file (data.json) using java script

@rafaelBadan
rafaelBadan / comoNaoDeixarNoVaucoNoWhatsapp.js
Created November 4, 2017 18:09 — forked from callmeloureiro/comoNaoDeixarNoVaucoNoWhatsapp.js
Como não deixar no vácuo no whatsapp
/*
Hoje não deixaremos mais ninguém no vácuo no whatsapp
Para utilizar:
- Abra o web.whatsapp.com;
- Abra o console e cole o código que está no gist;
- Aguarde e verá uma mensagem sendo enviada a cada momento que alguém te enviar alguma mensagem.
Confira também como ser chato no whatsapp: https://gist.github.com/mathloureiro/4c74d60f051ed59650cc76d1da0d32da
e como ser chato no mensseger: https://gist.github.com/mathloureiro/d3f91d19cf148838217e42a0c6df5ed8
*/