Skip to content

Instantly share code, notes, and snippets.

View dipu-bd's full-sized avatar

Sudipto Chandra dipu-bd

View GitHub Profile
@dipu-bd
dipu-bd / autogen.py
Last active May 2, 2020 23:53
Auto generate LN
import os
import time
PUBLIC_DATA = '/etc/lncrawl/public-data'
novels = []
for user in os.listdir(PUBLIC_DATA):
user_dir = os.path.join(PUBLIC_DATA, user)
if not os.path.isdir(user_dir):
continue
@dipu-bd
dipu-bd / urllib.dart
Last active May 2, 2020 23:52
This is a direct port of python's urllib.parse.urlparse into dart. Additionally, it splits the netloc (authority) component into user, password, host and port components.
class URL {
final String original;
String _fragment = '';
String _query = '';
String _scheme = '';
String _user = '';
String _password = '';
String _host = '';
String _port = '';
String _path = '';
@dipu-bd
dipu-bd / turing.json
Last active January 13, 2024 00:24
JSON schema for a Turing complete machine
{
"$schema": "http://json-schema.org/schema",
"title": "JSON schema for a turing complete machine",
"type": "object",
"definitions": {
"statement": {
"description": "",
"type": "object",