A simple example drawing a great arc as a LineString. The projection is rotated to avoid interrupting the arc. See also an earlier example with multiple great arcs.
🏳️🌈
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
require 'coderay' | |
codeToHighlight = `pbpaste` | |
highlightedCode = CodeRay.scan(codeToHighlight, :ruby).div | |
IO.popen("pbcopy", mode='w') do |io| | |
io.write highlightedCode | |
end |
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
require 'find' | |
def convertFile(path) | |
puts "Converting #{path}" | |
choppedSafeFilePath = path.chomp(File.extname(path)) | |
`ffmpeg -i "#{choppedSafeFilePath}.flac" -ar 44100 -ab 128k -y "#{choppedSafeFilePath}.mp3" 2>/dev/null` | |
end | |
Find.find("/media/New Volume/song_directory") do |path| | |
if File.extname(path) == ".flac" | |
convertFile path |
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
# run in command line | |
gsettings set org.gnome.settings-daemon.plugins.power 'use-time-for-policy' 'false' |
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
// in app/assets/javascripts/application.js | |
//= require jquery | |
//= require jquery_ujs | |
//= require ./stitch_header | |
//= require_tree . |
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
(ns sudoku | |
(:refer-clojure :exclude [==]) | |
(:use clojure.core.logic)) | |
(defn get-square [rows x y] | |
(for [x (range x (+ x 3)) | |
y (range y (+ y 3))] | |
(get-in rows [x y]))) | |
(defn init [vars hints] |
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
/** | |
* KineticJS Bezier Extension | |
* Compatible with KineticJS JavaScript Library v3.8.0 | |
* Author: Greg Zoller | |
* Date: Apr 12 2012 | |
*/ | |
/////////////////////////////////////////////////////////////////////// | |
// Bezier | |
/////////////////////////////////////////////////////////////////////// |
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
var connect = require('connect'); | |
var fs = require('fs'); | |
var querystring = require('querystring'); | |
var util = require('util'); | |
var pageMarkup = 'Error'; | |
var staticFiles = new Array(); | |
try { | |
staticFiles['/'] = fs.readFileSync('page.html', 'ascii'); | |
staticFiles['/jquery-1.7.1.min.js'] = fs.readFileSync('jquery-1.7.1.min.js', 'ascii'); |
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
module Homepage | |
module V2 | |
class Board | |
include Redis::Objects | |
value :name | |
value :exists | |
counter :views | |
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
event = require('pilot/event') | |
Anchor = require('ace/anchor').Anchor | |
doc = ace_editor.session.getDocument() | |
editablePositions = [[1, 0, 2, 0]] # allow editong only the second row | |
jQuery.each editable, (index, row) -> | |
editablePositions.push [new Anchor(doc, row[0], row[1]), new Anchor(doc, row[2], row[3])] | |
Range = require('ace/range').Range |
OlderNewer