Skip to content

Instantly share code, notes, and snippets.

View lildude's full-sized avatar
🌻

Colin Seymour lildude

🌻
View GitHub Profile
/*
1) Open your calendar on trainerroad
2) Press F12 to open developer tools, select console and paste the script below
3) OPTIONAL - modify the two dates (beg & end) to suit your needs
4) Copy the result of the execution (something like TRData = ...)
*/
(function () {
var beg = '2021-01-01';
var end = '2022-01-01';
function normalizeDate(dat) {
@lildude
lildude / making_language_grammar.md
Created May 7, 2021 09:32 — forked from Aerijo/making_language_grammar.md
Guide to writing an Atom language grammar

A guide to writing a language grammar (TextMate) in Atom

Tree sitter

  • Atom is transitioning to an entirely new way of defining grammars using tree-sitter. This will be enabled by default quite soon now. It is theoretically faster and more powerful than regex based grammars (the one described in this guide), but requires a steeper learning curve. My understanding is that regex based grammars will still be supported however (at least until version 2), so this guide can still be useful. To enable it yourself, go to Settings -> Core and check Use Tree Sitter Parsers

Links for tree-sitter help:

@lildude
lildude / tablebear
Created December 26, 2018 11:26 — forked from matux/tablebear
How to Tables on Bear app. Copy/paste example _as is_ on a note. (https://www.reddit.com/r/bearapp/comments/8a2k04/how_to_craft_pseudo_tables_on_bear/)
# Playgrounds Markup Cheat Sheet
## Callouts
::Name Description PG QH::
[Note](https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/Note.html#//apple_ref/doc/uid/TP40016497-CH39-SW1) Adds a Note callout. ✓ ✓
[Example](https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/Example.html#//apple_ref/doc/uid/TP40016497-CH58-SW1) Adds an Example callout. ✓
[Experiment](https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/Experiment.html#//apple_ref/doc/uid/TP40016497-CH36-SW1) Adds an Experiment callout. ✓ ✓
[Important](https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/Important.html#//apple_ref/doc/uid/TP40016497-CH37-SW1) Adds an Important callout ✓ ✓
[Custom Callout](https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/CustomCallouts.html#//apple_re
@lildude
lildude / nft-flush.sh
Created March 20, 2017 12:11
Flush and delete all nftables rules, chains and tables
#!/bin/bash
#
# Name: nft-flush
# Auth: Gavin Lloyd <gavinhungry@gmail.com>
# Date: 06 Mar 2014
# Desc: Flush and delete all nftables rules, chains and tables
#
NFT=/usr/bin/nft
FAMILIES="ip ip6 arp bridge"
@lildude
lildude / auto-deploy.md
Created July 2, 2016 16:54 — forked from domenic/0-github-actions.md
Auto-deploying built products to gh-pages with Travis

Auto-deploying built products to gh-pages with Travis

This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.

Create a compile script

You want a script that does a local compile to e.g. an out/ directory. Let's call this compile.sh for our purposes, but for your project it might be npm build or gulp make-docs or anything similar.

The out/ directory should contain everything you want deployed to gh-pages. That almost always includes an index.html.

@lildude
lildude / disconnect.rb
Last active August 29, 2015 14:02 — forked from tmcw/disconnect.rb
#!/usr/bin/env ruby
## disconnect
# ./disconnect.rb -u yourusername [-o /your/path] [-p yourhttpproxyserver]
#
# Updated: 8 Jun '14 to work with the new Garmin login redirect step (@lildude)
#
# This is a command-line utility for the bulk-downloading of run data from
# the connect.garmin.com web application, which has lackluster export