Skip to content

Instantly share code, notes, and snippets.

View zar3bski's full-sized avatar
:shipit:
Focusing

zar3bski zar3bski

:shipit:
Focusing
View GitHub Profile
@RRMoelker
RRMoelker / asyncio_pipeline_basic.py
Last active November 12, 2021 13:33
Dead simple asyncio pipeline
"""
Example program for basic asyncio pipeline.
Program takes string as input and converts it to upper case.
For sake of simplicity missing some "features", most notably error handling is absent.
Errors will silenty prevent program completion in many cases.
"""
import asyncio
from dataclasses import dataclass
@samayo
samayo / 00_ReadMe.md
Created October 17, 2018 21:57 — forked from mohamed-el-habib/00_ReadMe.md
drupal fpm with nginx and mysql

Usage

git clone git://github.com/fd57d8aa59b1574ee7728edf128814d3.git docker-drupal-fpm
cd docker-drupal-fpm
mkdir -p /usr/local/share/dockervolumes/drupal # if you change this folder please update the run.sh

chmod +x run.sh && ./run.sh up

@kunanit
kunanit / pandas_postgres.py
Created April 24, 2017 14:36
Read postgres database table into pandas dataframe
import pandas as pd
from sqlalchemy import create_engine
# follows django database settings format, replace with your own settings
DATABASES = {
'production':{
'NAME': 'dbname',
'USER': 'user',
'PASSWORD': 'pass',
'HOST': 'rdsname.clqksfdibzsj.us-east-1.rds.amazonaws.com',
@janus57
janus57 / disclaimer.js
Last active March 4, 2021 16:40
disclaimer JavaScript "universal"
/* variable(s) */
expireAfter1d = new Date();
expireAfter1d.setDate(expireAfter1d.getDate() + 1);
/* fonctions */
function getCookie(cname) {
var name = cname + "=";
var ca = document.cookie.split(';');
for(var i=0; i<ca.length; i++) {
var c = ca[i].trim();
@pitch-gist
pitch-gist / gist:2999707
Created June 26, 2012 22:21
HTML: Simple Maintenance Page
<!doctype html>
<title>Site Maintenance</title>
<style>
body { text-align: center; padding: 150px; }
h1 { font-size: 50px; }
body { font: 20px Helvetica, sans-serif; color: #333; }
article { display: block; text-align: left; width: 650px; margin: 0 auto; }
a { color: #dc8100; text-decoration: none; }
a:hover { color: #333; text-decoration: none; }
</style>