Skip to content

Instantly share code, notes, and snippets.

Avatar

Joshua Williams jwlms

View GitHub Profile
@jwlms
jwlms / mq nesting
Created Jul 15, 2013
media query nesting
View mq nesting
.svg #site-title a { // OK
@media( max-width: $w7 ) {
background: transparent url(images/flv-logo.svg) no-repeat 0 0;
}
}
.svg #site-title a { // no
@media( max-width: $w7 ) {
@media ( max-device-width: $ipad ) {
background: transparent url(images/flv-logo.svg) no-repeat 0 0;
}
@jwlms
jwlms / mq nesting
Created Jul 15, 2013
don't nest too deep
View mq nesting
.menu-toggle { ... // ok
.menu-toggle {
ul {
... // ok
}
}
.menu-toggle {
ul {
li {
View gist:bc07c3398439ecba1829
/*
On OS X, basic text manipulations (left, right, command+left, etc) make use of the system key bindings,
and don't need to be repeated here. Anything listed here will take precedence, however.
*/
[
{ "keys": ["super+shift+n"], "command": "new_window" },
{ "keys": ["super+shift+w"], "command": "close_window" },
{ "keys": ["super+o"], "command": "prompt_open" },
{ "keys": ["super+shift+t"], "command": "reopen_last_file" },
{ "keys": ["super+alt+up"], "command": "switch_file", "args": {"extensions": ["cpp", "cxx", "cc", "c", "hpp", "hxx", "h", "ipp", "inl", "m", "mm"]} },
View intro-to-ember-cli-node.md

Introduction To Node, NPM and Ember CLI

This guide is for developers who are new Node, NPM, and Ember CLI. This guide is designed to get you started with ember cli development and provide some general background info on what Node is and how it works with Ember CLI.

Overview

  • What is Node?
  • What is NPM?
  • How do I setup my environment if I don't have node js or npm installed?
  • I accidently installed something wrong how can I start over?
View gist:c6d57f61774dd9976652
function reinstall-npm-bower() {
CONT=
vared -p "Are you sure you want to update npm and bower dependancies? (y/n)? " CONT
if [ "$CONT" == "y" ]; then
install-npm-bower
echo "\n\n\n"
echo $fg[green] "Done!"
else
echo $fg[green] "Ok then!"
fi
View gist:7e3df4670c56bb418e53
gulp.task('test', function() {
return browserify().bundle()
.pipe(source('./test/test.js'))
.pipe(buffer())
.pipe(gulp.dest('./dist/js/test'));
})
View gist:12951f1a63339a3165f0
sudo wget -P /etc/apt/sources.list.d https://sslmate.com/apt/ubuntu1404/sslmate.list
sudo wget -P /etc/apt/trusted.gpg.d https://sslmate.com/apt/ubuntu1404/sslmate.gpg
sudo apt-get update
sudo apt-get install sslmate
View ssl-config
server {
#listening on port 443
listen 443 ssl;
#set site root
root /var/www/HOSTNAME.com;
index index.php index.html;
#set key locations
ssl_certificate /etc/sslmate/HOSTNAME.com.chained.crt;
View default-server
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;
server_name HOSTNAME.com;
return 301 https://HOSTNAME.com$request_uri;
}
View gist:bf7afd0585c5d6cfbcaa
find . -name "*[format]" | while read line; do expand -t 4 $line > $line.new; mv $line.new $line; done