When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:
main {
max-width: 38rem;
padding: 2rem;
margin: auto;
}
# install pygit2: pip install pygit2 | |
import pygit2 | |
import json | |
repo = pygit2.Repository('path/to/repository') | |
last = repo[repo.head.target] | |
data = [] | |
for commit in repo.walk(last.id): |
[alias] | |
; creates timestamped branch rst-XXXXX and pushes it to default remote (origin) | |
rst = "!rst() { export tmpBranch=rst-$(date +%s) && git add -A && git checkout -b $tmpBranch && git commit -m 'WIP remote stash' && git push --set-upstream origin $tmpBranch; }; rst" |
<?php | |
/** | |
* The MIT License (MIT) | |
* | |
* Copyright (c) Ozgur (Ozzy) Giritli <ozgur@zeronights.com> | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy | |
* of this software and associated documentation files (the "Software"), to deal | |
* in the Software without restriction, including without limitation the rights |
server { | |
listen 80; | |
server_name example.com; | |
root d:/webs/example.com/www; | |
index index.php index.html; | |
try_files $uri $uri/ /index.php?$args; | |
location ~ \.phpt?$ { | |
try_files $uri @missing; |
Easy peasy parallax effect
A Pen by Daniel Riemer on CodePen.
<!doctype html> | |
<script> | |
if ("WebSocket" in window) { | |
var ws = new WebSocket("ws://127.0.0.1:31339"); | |
ws.onopen = function() { | |
console.log('connected'); | |
}; | |
ws.onerror = function(e) { |
#! /bin/bash | |
MYSQL="/opt/local/etc/LaunchDaemons/org.macports.mysql5/mysql5.wrapper" | |
NGINX="/opt/local/sbin/nginx" | |
PHPFPM="/opt/local/sbin/php-fpm" | |
PIDPATH="/opt/local/var/run" | |
MEMCACHED="/opt/local/bin/memcached -m 24 -P /opt/local/var/run/memcached.pid -u root" | |
if [ $1 = "start" ]; then | |
sudo $MYSQL start | |
echo "Starting php-fpm ..." |
server { | |
index index.php; | |
set $basepath "/var/www"; | |
set $domain $host; | |
# check one name domain for simple application | |
if ($domain ~ "^(.[^.]*)\.dev$") { | |
set $domain $1; | |
set $rootpath "${domain}"; |
# Please paste to folder common/common.conf | |
index index.html index.htm; | |
error_page 500 502 503 504 /50x.html; | |
location = /50x.html { | |
root html; | |
} | |
#location ~ \.(js|ico|gif|jpg|png|css|rar|zip|tar\.gz)$ { } |