Skip to content

Instantly share code, notes, and snippets.

@atma
atma / org.mongodb.mongod.plist
Created October 1, 2013 01:27
mongodb launch agent, put to ~/Library/LaunchAgents/org.mongodb.mongod.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>org.mongodb.mongod</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/bin/mongod</string>
<string>run</string>
@atma
atma / dabblet.css
Created December 7, 2013 15:26 — forked from LeaVerou/dabblet.css
(C)Leanest CSS spinner ever
/**
* (C)Leanest CSS spinner ever
*/
@keyframes spin {
to { transform: rotate(1turn); }
}
.progress {
position: relative;
@atma
atma / .gitignore
Created March 1, 2014 14:04
.gitignore for .NET froject
# Build Folders (you can keep bin if you'd like, to store dlls and pdbs)
[Bb]in/
[Oo]bj/
# mstest test results
TestResults
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
@atma
atma / fotorama-keyboard-fullscreen.html
Last active August 29, 2015 14:01
Fotorama sample usage with keyboard & fullscreen enabled
<div class="fotorama" data-allowfullscreen="native" data-fit="cover"
data-keyboard="true" data-width="700" data-ratio="4/3" data-max-width="100%">
<img src="images/1.jpg">
<img src="images/2.jpg">
<img src="images/3.jpg">
<img src="images/4.jpg">
<img src="images/5.jpg">
</div>
@atma
atma / fotorama-thumbnails.html
Created May 15, 2014 16:33
Fotorama sample usage with thumbnail navigation
<div class="fotorama" data-nav="thumbs" data-width="700" data-ratio="4/3"
data-max-width="100%">
<a href="1.jpg"><img src="thumb_1.jpg" width="100" height="75"></a>
<a href="2.jpg"><img src="thumb_2.jpg" width="100" height="75"></a>
<a href="3.jpg"><img src="thumb_3.jpg" width="100" height="75"></a>
<a href="4.jpg"><img src="thumb_4.jpg" width="100" height="75"></a>
<a href="5.jpg"><img src="thumb_5.jpg" width="100" height="75"></a>
</div>
@atma
atma / gulpfile.js
Created October 8, 2014 02:38
A sample gulpfile for typical frontend dev
var gulp = require('gulp'),
browserify = require('browserify'),
es6ify = require('es6ify'),
hbsfy = require('hbsfy'),
bulkify = require('bulkify'),
source = require('vinyl-source-stream'),
streamify = require('gulp-streamify'),
concat = require('gulp-concat'),
gutil = require('gulp-util'),
livereload = require('gulp-livereload'),
(function(){
function addFont() {
var style = document.createElement('style');
style.rel = 'stylesheet';
document.head.appendChild(style);
style.textContent = localStorage.sourceSansPro;
}
try {
if (localStorage.sourceSansPro) {
@atma
atma / call-sample.html
Created November 11, 2014 12:35
An example usage of Google Experiments on client side only
<!-- Call immediately an experiment method to prevent a FOOC (Flash of original content) -->
<button class="btn btn-link" type="button" id="button">Click me</button>
<script>typeof __abt !== "undefined" && __abt.some && __abt.some();</script>
<div classs="another-html-content"></div>
@atma
atma / example_ssl.conf
Created February 18, 2015 10:53
Nginx SSL configuration for A+ grade
listen 443 ssl spdy;
ssl on;
ssl_protocols TLSv1.2 TLSv1.1 TLSv1;
ssl_session_cache shared:SSL:20m;
ssl_session_timeout 10m;
ssl_ciphers 'EECDH+ECDSA+AESGCM:AES128+EECDH:AES128+EDH:!RC4:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!CAMELLIA:!ADH';
ssl_prefer_server_ciphers on;
resolver 8.8.8.8 8.8.4.4 valid=300s;
resolver_timeout 10s;
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.