Resources for learning web design & front-end development:
ONLINE
Design
| #!/bin/bash | |
| # Place in /usr/share/backup/ | |
| # and make executable | |
| # chmod 0744 dup-backup.sh | |
| # install: | |
| # apt-get install duplicity python-gdata python-gobject-2 python-paramiko | |
| ## Remeber to change Google drive user name and Google drive folder | |
| ## And change Email | |
| # Must run as root for system wide backups |
| (function() { | |
| var CSSCriticalPath = function(w, d, opts) { | |
| var opt = opts || {}; | |
| var css = {}; | |
| var pushCSS = function(r) { | |
| if(!!css[r.selectorText] === false) css[r.selectorText] = {}; | |
| var styles = r.style.cssText.split(/;(?![A-Za-z0-9])/); | |
| for(var i = 0; i < styles.length; i++) { | |
| if(!!styles[i] === false) continue; | |
| var pair = styles[i].split(": "); |
| require 'pdfkit' | |
| require 'nokogiri' | |
| require 'haml' | |
| # config/initializers/pdfkit.rb | |
| PDFKit.configure do |config| | |
| # Note: Often required for Windows OS configuration | |
| # config.wkhtmltopdf = '/path/to/wkhtmltopdf' | |
Resources for learning web design & front-end development:
ONLINE
Design
| # This goes in _plugins/excerpt.rb | |
| module Jekyll | |
| class Post | |
| alias_method :original_to_liquid, :to_liquid | |
| def to_liquid | |
| original_to_liquid.deep_merge({ | |
| 'excerpt' => content.match('<!--more-->') ? content.split('<!--more-->').first : nil | |
| }) | |
| end | |
| end |
| http { | |
| # Default virtual host for www.example.com. This will pick up all HTTP | |
| # requests to port 80 that are not for one of the other virtual hosts. | |
| server { | |
| listen 80; | |
| server_name www.example.com; | |
| # ...your server config here... |
| server { | |
| listen *:80; | |
| location = /crossdomain.xml { | |
| root /var/www/html/; | |
| } | |
| location = /test.html { | |
| root /var/www/html/; | |
| } |