Skip to content

Instantly share code, notes, and snippets.

View mathiasmoeller's full-sized avatar
🐢
I like turtles

Mathias Möller mathiasmoeller

🐢
I like turtles
View GitHub Profile
@gasolin
gasolin / gist:9300f5f9276b2df884c80da3e2c54ffc
Last active July 15, 2023 10:13
Install Android Simulator

Install Android SDK on macOS

Install homebrew https://brew.sh/

brew cask install adoptopenjdk8
brew cask install android-sdk
@mkhatib
mkhatib / geo.js
Created May 24, 2013 02:55
A Javascript utility function to generate number of random Geolocations around a center location and in a defined radius.
/**
* Generates number of random geolocation points given a center and a radius.
* @param {Object} center A JS object with lat and lng attributes.
* @param {number} radius Radius in meters.
* @param {number} count Number of points to generate.
* @return {array} Array of Objects with lat and lng attributes.
*/
function generateRandomPoints(center, radius, count) {
var points = [];
for (var i=0; i<count; i++) {
@tleunen
tleunen / embed-gist-angularjs.html
Last active May 1, 2019 00:51
Here is a directive in AngularJS to embed a Gist. This technique uses an iframe to add the gist because AngularJS doesn't handle script tags inside a template. And even if it does (with jQuery), it won't work as expected because Gist uses document.write. The iframe solves both issues.
<!-- In your template -->
<div data-gist="{{gistId}}"></div>
@chrisle
chrisle / gist:2252209
Created March 30, 2012 15:15
CURL as GoogleBot 2.1
curl --user-agent "Googlebot/2.1 (+http://www.google.com/bot.html)" -v $@