If you haven't already set your NPM author info, now you should:
npm set init.author.name "Your Name"
npm set init.author.email "[email protected]"
npm set init.author.url "http://yourblog.com"
npm adduser
| // ---- | |
| // libsass (v3.2.5) | |
| // ---- | |
| @mixin selectorer($selector: null) { | |
| &#{if($selector, ' ' + unquote($selector), $selector)} { | |
| background: center/100% auto no-repeat url('foo'); | |
| } | |
| } |
If you haven't already set your NPM author info, now you should:
npm set init.author.name "Your Name"
npm set init.author.email "[email protected]"
npm set init.author.url "http://yourblog.com"
npm adduser
| // ---- | |
| // libsass (v3.2.5) | |
| // ---- | |
| // Validated against http://www.modularscale.com/ | |
| // http://www.modularscale.com/?1&&1.5&web&text | |
| $mod-scale--size: 1rem !default; | |
| $mod-scale--ratio: 1.5 !default; | |
| @function modular-scale($increment, $base-size, $ratio) { |
| str = 'This hyperlink should be stripped out: http://www.bhalash.com. word www.google.ie, more word https://www.twitter.com!' | |
| regex = /(\b(http(s?)|www).*?(?=(\s|[[:punct:]]\s|.(?=$))))/ | |
| p = str.scan(regex).each { |url| | |
| link = url[0] | |
| link_text = url[0] | |
| link_href = url[0] | |
| if !link_href.match(/^http(s?):\/\//) |
Hey!
I have a headache and this is easier than talking. :) I have not added baked-in avatar support to my application. While there are gems like Paperclip, I haven't added any becuase it is more work.
Instead I use Adorable Avatars:
[![][2]][1]
An active git repository will look like a tree:
Before a branch can be created on the server, it must first be created on your computer. All branches in a repository are instigated in a client computer, in your local copy.
| #!/usr/bin/env zsh | |
| if [ ! -d "${1}" ]; then | |
| echo "'${1}' is not a valid directory!" | |
| exit 1 | |
| fi | |
| cd "${1}" | |
| # Months |
This gist is dedicated to all of my fellow clueless n00bs who are frightened by the combination of [RSpec][1], [Capybara][2] and [Authlogic][3].
This gist will not tell you how to install Ruby, Rails, RSpec, Capybara or Authlogic. For the most part, you can install any of these by running either:
brew install <packagename>
bundle install <packagename>
At the point in time that you reach this gist, you should have all of them installed.
| #!/usr/bin/env bash | |
| # Blame Mark ([email protected]) for this. | |
| function trim_spaces() { | |
| # Safely remove spaces in the file name. | |
| new_name=$(sed 's/[[:space:]]/_/g' <<< "${1}") | |
| mv "$1" $new_name && echo $new_name | |
| } | |
| function test_aspect_ratio() { |
| #!/bin/bash | |
| # https://www.bhalash.com/archives/13544793955 | |
| # April 23, 2013 | |
| # Need to escape the source path both as when we declare and use it, or Errors Occur. | |
| IFS=' ' | |
| src="/home/bhalash/Dropbox/Camera Uploads/" | |
| destination="/home/bhalash/Dropbox/Photos/Instagram" | |
| temp=/tmp/instafind |