sudo apt update && sudo apt upgrade
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Cloning all GitHub repositories belonging to a specific user provided as an argument. | |
# | |
# Command Execution Example: | |
# ./clone-all-repos-github.sh <USERNAME> | |
# | |
# Arguments: | |
# <USERNAME> GitHub username whose repositories will be cloned. | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from bs4 import BeautifulSoup | |
import json | |
def get_filepaths(path): | |
return [os.path.join(path, talk) for talk in os.listdir(path)] | |
def extract_questions_talk(filepath): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo add-apt-repository -y ppa:ubuntugis/ubuntugis-unstable | |
sudo apt update | |
sudo apt upgrade | |
sudo apt-get install libgdal-dev libgdal1i | |
pip install --global-option=build_ext --global-option="-I/usr/include/gdal" GDAL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: ConfigMap | |
metadata: | |
name: nginx-conf | |
data: | |
nginx.conf: | | |
user nginx; | |
worker_processes 3; | |
error_log /var/log/nginx/error.log; | |
events { |
Here is an updated list of the colors that are currently implemented with a name.
To using colors on discord.js, this is a typedef Colors, Colors.Aqua
to get the Aqua color.
Name | Int value | Hex Code |
---|---|---|
Default |
0 | #000000 |
Aqua |
1752220 | #1ABC9C |
DarkAqua |
1146986 | #11806A |
Green |
5763719 | #57F287 |
DarkGreen |
2067276 | #1F8B4C |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const request = require('request-promise-native') | |
const cheerio = require('cheerio') | |
const login = ({user, pass}) => { | |
let options = { | |
method: 'POST', | |
uri: 'https://siga.cps.sp.gov.br/aluno/login.aspx', | |
headers: { | |
'User-Agent': 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2228.0 Safari/537.36', | |
'Content-Type': 'application/x-www-form-urlencoded', | |
'Origin': 'https://siga.cps.sp.gov.br' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from keras import backend as K | |
from keras.models import Sequential | |
from keras.layers.core import Dense, Dropout, Activation, Flatten | |
from keras.layers.convolutional import Convolution2D, MaxPooling2D | |
from keras.preprocessing.image import ImageDataGenerator | |
from sklearn.metrics import classification_report, confusion_matrix | |
#Start | |
train_data_path = 'F://data//Train' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env/python | |
import psycopg2 | |
import os | |
from io import StringIO | |
import pandas as pd | |
# Get a database connection | |
dsn = os.environ.get('DB_DSN') # Use ENV vars: keep it secret, keep it safe | |
conn = psycopg2.connect(dsn) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const EventEmitter = require('events') | |
class MyClass extends EventEmitter { | |
constructor() { | |
super() // required | |
this.emit('event', 100) | |
} | |
} |
NewerOlder