Skip to content

Instantly share code, notes, and snippets.

View lightyrs's full-sized avatar
🌒
ლ(▀̿̿Ĺ̯̿̿▀̿ლ)

Harris Novick lightyrs

🌒
ლ(▀̿̿Ĺ̯̿̿▀̿ლ)
View GitHub Profile
#app/inputs/collection_check_boxes_input.rb
class CollectionCheckBoxesInput < SimpleForm::Inputs::CollectionCheckBoxesInput
def item_wrapper_class
"checkbox-inline"
end
end
My iTunes Match Track upgrading and process info:
If you have less than 25,000 tracks:
1. First let iTunes Match do its things and find all possible matches in your library and finish uploading any non-matching tracks.
2. Once its done, make a new Smart Playlist (I made a folder for all my Smart iTunes Match Related Playlists)
Name this one: iCloud-Upgradeable
Criteria:
MATCH ALL:
Bit Rate is less than 256kbps
fsync = off
synchronous_commit = off
full_page_writes = off
upstream myapp_puma {
server unix:/tmp/myapp_puma.sock fail_timeout=0;
}
# for redirecting to https version of the site
server {
listen 80;
rewrite ^(.*) https://$host$1 permanent;
}
@lightyrs
lightyrs / ssl_puma.sh
Last active August 29, 2015 14:15 — forked from tadast/ssl_puma.sh
# 1) Create your private key (any password will do, we remove it below)
$ cd ~/.ssh
$ openssl genrsa -des3 -out server.orig.key 2048
# 2) Remove the password
$ openssl rsa -in server.orig.key -out server.key
FIXME:
WARNING: Nokogiri was built against LibXML version 2.7.3, but has dynamically loaded 2.7.8
or
ERROR -: Incompatible library version: nokogiri.bundle requires version 11.0.0 or later, but libxml2.2.dylib provides version 10.0.0
gem uninstall nokogiri libxml-ruby
brew update
brew uninstall libxml2
#!/bin/bash
# Sync Homebrew installations between Macs via Dropbox
#
BREW="/usr/local/bin/brew"
# first get local settings
echo "Reading local settings ..."
rm -f /tmp/brew-sync.*
@lightyrs
lightyrs / force-utf8.rb
Created March 12, 2015 06:01
really force utf-8 in ruby
line.encode!('UTF-8', 'binary', invalid: :replace, undef: :replace, replace: '')
@lightyrs
lightyrs / keybase.md
Created May 12, 2015 00:52
keybase.md

Keybase proof

I hereby claim:

  • I am lightyrs on github.
  • I am h1 (https://keybase.io/h1) on keybase.
  • I have a public key whose fingerprint is 9A17 4265 5180 52AE 464B 10D4 CD37 16F2 14C2 E724

To claim this, I am signing this object:

@lightyrs
lightyrs / passcard.txt
Created May 12, 2015 15:10
passcard proof
Verifying I am +h1 on my passcard. https://onename.com/h1