Skip to content

Instantly share code, notes, and snippets.

View nickdos's full-sized avatar

Nick dos Remedios nickdos

View GitHub Profile
@datadavev
datadavev / solr_heat_geojson.ipynb
Last active July 26, 2022 01:05
Solr heatmap as GeoJSON
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@bricewge
bricewge / ble-button.py
Last active December 18, 2023 18:12
Use iTag Bluetooth BLE tracker as a light switch with Home Assistant
from bluepy import btle
import requests
bleAddr = "ff:ff:10:05:ef:ff"
url = "http://localhost:8123/api/services/light/toggle"
lamp = "light.mylight"
hassPasswd = "password"
class LightToggleDelegate(btle.DefaultDelegate):
def __init__(self):
@kdevo
kdevo / IntelliJ + Maven - Unresolved Plugin.md
Last active July 19, 2024 18:57
IntelliJ IDEA and Maven - "Unresolved Plugin" notes
# Defaults / Configuration options for homebridge
# The following settings tells homebridge where to find the config.json file and where to persist the data (i.e. pairing and others)
HOMEBRIDGE_OPTS=-U /var/lib/homebridge
# If you uncomment the following line, homebridge will log more
# You can display this via systemd's journalctl: journalctl -f -u homebridge
# DEBUG=*
@dtanner
dtanner / Config.groovy
Created April 30, 2015 05:32
Example of loading a Grails configuration value from etcd
import groovy.json.JsonSlurper
dataSource {
// most properties are directly set
pooled = true
// ...
// the url is retrieved from etcd...make sure the etcd resource is properly protected
def jsonSlurper = new JsonSlurper()
def catalogUrlConfig = jsonSlurper.parseText(new URL("http://etcdlocation:2379/v2/keys/dataSource/url").text)
@nickdos
nickdos / README.md
Last active May 26, 2020 23:28
Get list of commits for change log in GitHub (via latest release change page)

Browser bookmark

  • create a bookmark with a URL:
javascript:Array.from(document.getElementsByClassName("link-gray")).filter(x=>x.getAttribute('title')!=null).reduce((c,i)=>c+'* '+i.getAttribute('title').replace(/[\n\r]+/g," - ")+'<br>',"");
  • view the project's releases page
  • under the most recent release find the link that looks like N commits to master since this release and follow the link (noting the current version number for later)
  • run the bookmark from the bookmark menu
  • copy the MD text on the screen
  • "draft a new release" and paste the MD text into the release description
@marktheunissen
marktheunissen / pedantically_commented_playbook.yml
Last active June 5, 2024 22:16 — forked from phred/pedantically_commented_playbook.yml
Insanely complete Ansible playbook, showing off all the options
This playbook has been removed as it is now very outdated.
@gudbergur
gudbergur / README.markdown
Created February 19, 2012 23:49
Bootstrap's Typeahead plugin extended (allowing for AJAX functionality) among other things

This is a fork of Bootstrap Typeahead that adds minimal but powerful extensions.

For example, process typeahead list asynchronously and return objects

  # This example does an AJAX lookup and is in CoffeeScript
  $('.typeahead').typeahead(
    # source can be a function
    source: (typeahead, query) ->
 # this function receives the typeahead object and the query string