time.google.com
time1.google.com
time2.google.com
time3.google.com
| #!/bin/bash | |
| # Compile and install/update (or install via Apt) FFmpeg Codecs | |
| # Compile and install/update FFmpeg suite | |
| # Compile with hardware acceleration | |
| # Modified from https://retroresolution.com/compiling-ffmpeg-from-source-code-all-in-one-script/ | |
| echo "Begining Installation of FFmpeg Suite" | |
| #Update APT Repository | |
| echo "Updating the APT repository information" |
| #!/bin/bash | |
| mkdir toolchain | |
| cd toolchain | |
| wget ftp://sources.redhat.com/pub/newlib/newlib-1.19.0.tar.gz | |
| wget ftp://ftp.gnu.org/gnu/gdb/gdb-7.2a.tar.gz | |
| wget ftp://ftp.gnu.org/gnu/binutils/binutils-2.29.tar.bz2 | |
| wget ftp://ftp.gnu.org/gnu/gcc/gcc-4.6.4/gcc-core-4.6.4.tar.bz2 |
| # Basically the nginx configuration I use at konklone.com. | |
| # I check it using https://www.ssllabs.com/ssltest/analyze.html?d=konklone.com | |
| # | |
| # To provide feedback, please tweet at @konklone or email eric@konklone.com. | |
| # Comments on gists don't notify the author. | |
| # | |
| # Thanks to WubTheCaptain (https://wubthecaptain.eu) for his help and ciphersuites. | |
| # Thanks to Ilya Grigorik (https://www.igvita.com) for constant inspiration. | |
| server { |
| user www-data; | |
| #worker_processes 4; | |
| #worker_priority 0; | |
| #worker_cpu_affinity 0001 0010 0100 1000; | |
| #worker_rlimit_nofile 163840; | |
| #worker_processes 8; | |
| #worker_priority 0; | |
| #worker_cpu_affinity 00000001 00000010 00000100 00001000 00010000 00100000 01000000 10000000; |
| // PhantomJS Cheatsheet | |
| $ brew update && brew install phantomjs // install PhantomJS with brew | |
| phantom.exit(); | |
| var page = require('webpage').create(); | |
| page.open('http://example.com', function() {}); | |
| page.evaluate(function() { return document.title; }); |
| String.prototype.strReplace = function(find, replace) { | |
| if(typeof find === 'string') | |
| return this.split(find).join(replace); | |
| var str = this; | |
| for(var i in find) | |
| str = str.split(find[i]).join(replace[i]); | |
| return str; |
| /* | |
| * This decorates Handlebars.js with the ability to load | |
| * templates from an external source, with light caching. | |
| * | |
| * To render a template, pass a closure that will receive the | |
| * template as a function parameter, eg, | |
| * T.render('templateName', function(t) { | |
| * $('#somediv').html( t() ); | |
| * }); | |
| * Source: https://github.com/wycats/handlebars.js/issues/82 |
| // Get the template HTML and remove it from the doumenthe template HTML and remove it from the doument | |
| var previewNode = document.querySelector("#template"); | |
| previewNode.id = ""; | |
| var previewTemplate = previewNode.parentNode.innerHTML; | |
| previewNode.parentNode.removeChild(previewNode); | |
| var myDropzone = new Dropzone(document.body, { // Make the whole body a dropzone | |
| url: "/target-url", // Set the url | |
| thumbnailWidth: 80, | |
| thumbnailHeight: 80, |