Skip to content

Instantly share code, notes, and snippets.

View ibnesayeed's full-sized avatar

Sawood Alam ibnesayeed

View GitHub Profile
@ibnesayeed
ibnesayeed / twitter-alternate-lang.html
Created March 18, 2018 20:30
Twitter Language Alternate Links
<link rel="alternate" hreflang="fr" href="https://twitter.com/?lang=fr">
<link rel="alternate" hreflang="en" href="https://twitter.com/?lang=en">
<link rel="alternate" hreflang="ar" href="https://twitter.com/?lang=ar">
<link rel="alternate" hreflang="ja" href="https://twitter.com/?lang=ja">
<link rel="alternate" hreflang="es" href="https://twitter.com/?lang=es">
<link rel="alternate" hreflang="de" href="https://twitter.com/?lang=de">
<link rel="alternate" hreflang="it" href="https://twitter.com/?lang=it">
<link rel="alternate" hreflang="id" href="https://twitter.com/?lang=id">
<link rel="alternate" hreflang="pt" href="https://twitter.com/?lang=pt">
<link rel="alternate" hreflang="ko" href="https://twitter.com/?lang=ko">
@ibnesayeed
ibnesayeed / d3.v4.js
Created February 1, 2018 06:04
Sample example banner heatmap
// https://d3js.org Version 4.13.0. Copyright 2018 Mike Bostock.
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
typeof define === 'function' && define.amd ? define(['exports'], factory) :
(factory((global.d3 = global.d3 || {})));
}(this, (function (exports) { 'use strict';
var version = "4.13.0";
function ascending(a, b) {
@ibnesayeed
ibnesayeed / fixity.svg
Last active January 24, 2018 13:17
Memento fixity visualization
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ibnesayeed
ibnesayeed / README.md
Last active January 18, 2018 20:12
Install openconnect VPN client with GlobalProtect support

GlobalProtect VPN

This script is made to work on modern Ubuntu-based Linux distributions.

Install openconnect VPN client with GlobalProtect support:

$ chmod a+x openconnect-installer.sh
$ sudo ./openconnect-installer.sh
@ibnesayeed
ibnesayeed / oducs-vpn.sh
Created January 18, 2018 19:49
Install and run ODU CS VPN on Newer Ubuntu-based OSes
#!/usr/bin/env bash
# Install build esentials
apt update
sudo apt install -y git build-essential gettext autoconf automake libproxy-dev libxml2-dev libtool vpnc-scripts pkg-config libgnutls28-dev
# Install special openconnect with GlobalProtect support
cd /tmp
git clone https://github.com/dlenski/openconnect.git
cd openconnect
@ibnesayeed
ibnesayeed / docker-compose.yml
Created December 4, 2017 01:42
A compose file to orchestrate two docker services together
version: '3'
services:
api:
image: api:python
build: ./api
ports:
- "5000:5000"
web:
image: php:7-apache
@ibnesayeed
ibnesayeed / Dockerfile
Created December 4, 2017 00:43
A basic Dockerfile to install various requirements of a simple Python script
FROM python
LABEL maintainer="Sawood Alam <@ibnesayeed>"
RUN pip install beautifulsoup4
RUN pip install requests
WORKDIR /app
COPY linkextractor.py /app/
RUN chmod a+x linkextractor.py
@ibnesayeed
ibnesayeed / linkextractor.py
Created December 4, 2017 00:29
A basic page scraping script that prints out all the hyper references of the given web page.
#!/usr/bin/env python
import sys
import requests
from bs4 import BeautifulSoup
res = requests.get(sys.argv[-1])
soup = BeautifulSoup(res.text, "html.parser")
for link in soup.find_all("a"):
print(link.get("href"))
@ibnesayeed
ibnesayeed / Dockerfile
Created July 20, 2017 14:53
Dockerize Your Projects: An example to illustrate basic Dockerization
FROM python
LABEL maintainer="Sawood Alam <@ibnesayeed>"
RUN pip install beautifulsoup4
RUN pip install requests
COPY main.py /app/
WORKDIR /app
RUN chmod a+x main.py
ENTRYPOINT ["./main.py"]
@ibnesayeed
ibnesayeed / Makefile
Created April 26, 2017 03:18
LaTeX Build Makefile
SHELL=/bin/bash
MAIN=main
LATEX=pdflatex
BIBTEX=bibtex
DTM=$(shell date +%Y%m%d-%H%M%S)
all: clean build clear
build:
$(LATEX) $(MAIN).tex