Skip to content

Instantly share code, notes, and snippets.

View Bill0412's full-sized avatar
🎯
Focusing

Fenghe Xu Bill0412

🎯
Focusing
View GitHub Profile
@Bill0412
Bill0412 / async_download_files.py
Created May 16, 2022 08:29 — forked from darwing1210/async_download_files.py
Script to download files in a async way, using Python asyncio
import os
import asyncio
import aiohttp # pip install aiohttp
import aiofiles # pip install aiofiles
REPORTS_FOLDER = "reports"
FILES_PATH = os.path.join(REPORTS_FOLDER, "files")
def download_files_from_report(urls):
@Bill0412
Bill0412 / epol.cc
Created March 13, 2022 10:21 — forked from waffle2k/epol.cc
Threaded + epoll server
// Compile with: $ g++ epoll.cc -o epoll1 -lboost_thread
#include <iostream>
#include <netinet/in.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/epoll.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <unistd.h>
@Bill0412
Bill0412 / notes.md
Last active July 27, 2020 00:43 — forked from datlife/notes.md
Setup Apache Spark/ Jupyter Notebook on MacOS
@Bill0412
Bill0412 / instructions.txt
Created September 22, 2018 01:19 — forked from imthatcarlos/instructions.txt
Create a new rails application with a specific version
# make directory for new rails app
mkdir app
cd app
# specify ruby version
echo 2.3.1 > .ruby-version
# initialize bundler (creates Gemfile)
bundler init