This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import urllib2,os; pf='Package Control.sublime-package'; ipp=sublime.installed_packages_path(); os.makedirs(ipp) if not os.path.exists(ipp) else None; urllib2.install_opener(urllib2.build_opener(urllib2.ProxyHandler())); open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')).read()); print 'Please restart Sublime Text to finish installation' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env node | |
| function primeNumbers(n) { | |
| arr = []; | |
| for (var i = 2; arr.length < n; i++) { | |
| var is_div = false; | |
| for (var count = 2; count < i; count++) { | |
| if (i % count === 0) { | |
| is_div = true; | |
| break; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # A Shell Script To Convert All .flac Files To .MP3 Format | |
| # Note: I found this script somewhere on usenet and I've modified it for my needs | |
| METAFLAC=/usr/local/bin/metaflac | |
| FLAC=/usr/local/bin/flac | |
| #ID3=/usr/bin/id3 | |
| LAME=/usr/local/bin/lame | |
| FIND=/usr/bin/find | |
| t=$(${FIND} . -type f -iname "*.flac") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| URL_LIST=$* | |
| YOUTUBE_DL="/usr/local/bin/youtube-dl" | |
| YOUTUBE_DL_OPTS="--title --restrict-filenames --write-thumbnail --extract-audio --audio-format mp3 --audio-quality 0 --continue --no-overwrites" | |
| ${YOUTUBE_DL} ${YOUTUBE_DL_OPTS} ${URL_LIST} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| table .blue { | |
| color: #049cdb; | |
| border-bottom-color: #049cdb; | |
| } | |
| table .green { | |
| color: #46a546; | |
| border-bottom-color: #46a546; | |
| } | |
| table .red { | |
| color: #9d261d; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| table .blue { color: #049cdb; border-bottom-color: #049cdb; } table .green { color: #46a546; border-bottom-color: #46a546; } table .red { color: #9d261d; border-bottom-color: #9d261d; } table .yellow { color: #ffc40d; border-bottom-color: #ffc40d; } table .orange { color: #f89406; border-bottom-color: #f89406; } table .purple { color: #7a43b6; border-bottom-color: #7a43b6; } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * @@@BUILDINFO@@@ VariableImporter.jsx !Version! Tue Dec 15 2015 03:06:17 GMT-0600 | |
| */ | |
| /* | |
| ============================= VARIABLE IMPORTER Version 7.1.3 ============================== | |
| By Vasily Hall | |
| e: | |
| [email protected] | |
| LinkedIn: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| # | |
| # Undelete a document from a CouchDB database. | |
| # | |
| # Recovers a previously deleted document by looking at the _changes | |
| # feed, putting a new empty document preserving the revisions chain, | |
| # retrieves the revs_info for the document, asks the user which one | |
| # to recover, and puts back the old revision into place. | |
| # | |
| # For this to work, GETting the document must return error: "not_found", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # encoding: utf-8 | |
| # @author Filipe Rocha <[email protected]> | |
| # Describe Portugal's Administrative Areas | |
| class DistritoConcelho | |
| # @return [Array] list of [concelho, [distritos]] | |
| def self.list | |
| [ | |
| ['Aveiro', ['Águeda', 'Albergaria-a-Velha', 'Anadia', 'Arouca', 'Aveiro', 'Castelo de Paiva', 'Espinho', 'Estarreja', 'Santa Maria da Feira', 'Ílhavo', 'Mealhada', 'Murtosa', 'Oliveira de Azeméis', 'Oliveira do Bairro', 'Ovar', 'São João da Madeira', 'Sever do Vouga', 'Vagos', 'Vale de Cambra']], | |
| ['Beja', ['Aljustrel', 'Almodôvar', 'Alvito', 'Barrancos', 'Beja', 'Castro Verde', 'Cuba', 'Ferreira do Alentejo', 'Mértola', 'Moura', 'Odemira', 'Ourique', 'Serpa', 'Vidigueira']], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* if portrait mode is detected, rotate the entire site -90 degrees to hint rotating to landscape */ | |
| @media (orientation: portrait) { | |
| body { | |
| -webkit-transform: rotate(-90deg); | |
| -moz-transform: rotate(-90deg); | |
| -o-transform: rotate(-90deg); | |
| -ms-transform: rotate(-90deg); | |
| transform: rotate(-90deg); | |
| } | |
| } |