I've been having trouble with serving a Flask app via uWSGI and nginx, so I thought I'd put together some of the basics to help out others.
- Flask is managed by
uWSGI. uWSGItalks tonginx.
| (function(){ | |
| var a = function(){ | |
| var y = document.createElement('script'); | |
| y.onload = function(){ jQuery(document).fartscroll(600) }; | |
| y.src="https://raw.github.com/theonion/fartscroll.js/master/fartscroll.js"; | |
| document.head.appendChild(y); | |
| }; | |
| if(typeof jQuery == 'undefined') { | |
| var x = document.createElement('script'); | |
| x.onload = a; |
People
:bowtie: |
😄 :smile: |
😆 :laughing: |
|---|---|---|
😊 :blush: |
😃 :smiley: |
:relaxed: |
😏 :smirk: |
😍 :heart_eyes: |
😘 :kissing_heart: |
😚 :kissing_closed_eyes: |
😳 :flushed: |
😌 :relieved: |
😆 :satisfied: |
😁 :grin: |
😉 :wink: |
😜 :stuck_out_tongue_winking_eye: |
😝 :stuck_out_tongue_closed_eyes: |
😀 :grinning: |
😗 :kissing: |
😙 :kissing_smiling_eyes: |
😛 :stuck_out_tongue: |
This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.
The script is here:
#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"
| #!/usr/bin/env python2 | |
| """ | |
| Author: takeshix <[email protected]> | |
| PoC code for CVE-2014-0160. Original PoC by Jared Stafford ([email protected]). | |
| Supportes all versions of TLS and has STARTTLS support for SMTP,POP3,IMAP,FTP and XMPP. | |
| """ | |
| import sys,struct,socket | |
| from argparse import ArgumentParser |
The pricing should be ~3$ for the first year (assuming 30GB upload per month). See here for more details.
| module PlaylistBuilder | |
| SEG_DURATION, PKT_SIZE, PKT_POS, PKT_TIME = 0,1,2,3 | |
| def self.extract_iframes_data(video_filepath) | |
| raise "#{video_filepath} does not exists!" unless File.exists?(video_filepath) | |
| iframes_data = [] | |
| cmd = "ffprobe -show_frames -select_streams v -of compact -show_entries packet=pts_time,codec_type,pos:frame=pict_type,pkt_pts_time,pkt_size,pkt_pos -i #{video_filepath.shellescape}" | |
| frames_and_packets = nil | |
| r = Benchmark.measure('') do | |
| frames_and_packets = `#{cmd}`.split("\n") |
| (function() { | |
| var FavEmoji = function(unicode) { | |
| 'use strict'; | |
| var | |
| canvas = document.createElement('canvas'), | |
| getContext = function(w) { | |
| canvas.width = canvas.height = w; | |
| context = canvas.getContext('2d'); | |
| context.font = 'normal normal normal 32px/' + w + 'px sans'; | |
| context.textBaseline = 'middle'; |
| /* bling.js */ | |
| window.$ = document.querySelector.bind(document); | |
| window.$$ = document.querySelectorAll.bind(document); | |
| Node.prototype.on = window.on = function(name, fn) { this.addEventListener(name, fn); }; | |
| NodeList.prototype.__proto__ = Array.prototype; | |
| NodeList.prototype.on = function(name, fn) { this.forEach((elem) => elem.on(name, fn)); }; |
| import transitions from './transitions.css'; | |
| export default () => ( | |
| <ReactCSSTransitionGroup transitionName={transitions}> | |
| { ... } | |
| </ReactCSSTransitionGroup> | |
| ); |