Skip to content

Instantly share code, notes, and snippets.

@AlonEirew
AlonEirew / python_smtp.txt
Last active August 13, 2020 15:22
python send mail using smtp
import smtplib
if __name__ == '__main__':
print('Enter email address (eg. yourname@gmail.com):')
gmail_user = input()
print('Enter password OR App password for 2-Step-Verification (https://support.google.com/accounts/answer/185833):')
gmail_password = input()
sent_to = [gmail_user]
@AlonEirew
AlonEirew / CLIFileDownloader.java
Last active August 13, 2020 16:09
Java CLI - Print progress bar when downloading file from a URL
package wiki.utils;
import me.tongfei.progressbar.ProgressBar;
import me.tongfei.progressbar.ProgressBarStyle;
import org.apache.commons.io.IOUtils;
import org.apache.commons.io.input.CountingInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
@AlonEirew
AlonEirew / extract_dblp.html
Created June 1, 2023 20:13
Code to automatically parse DBLP research publications into an HTML table with highlighted publisher name
<!DOCTYPE html>
<html>
<head>
<title>DBLP Publication</title>
</head>
<body>
<h1>DBLP Publication</h1>
<table id="publications">
<thead>
<tr>