Skip to content

Instantly share code, notes, and snippets.

View lurch's full-sized avatar

Andrew Scheller lurch

View GitHub Profile
@lurch
lurch / architecture-detect.sh
Last active December 7, 2017 04:07
Handy scripts to automate part of the Etcher release process
#!/bin/bash
###
# Copyright 2017 resin.io
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
@lurch
lurch / Github Flavored Markdown.md
Last active January 18, 2024 09:01 — forked from paulprogrammer/Github Flavored Markdown.md
Github Flavored Markdown cheatsheet

Github Flavored Markdown (GFMD) is based on Markdown Syntax Guide with some overwriting as described at Github Flavored Markdown

Text Writing

It is easy to write in GFMD. Just write simply like text and use the below simple "tagging" to mark the text and you are good to go!

To specify a paragraph, leave 2 spaces at the end of the line

Headings

@lurch
lurch / bmap_write.py
Created March 23, 2018 15:18
Super simple standalone script to parse a bmap file (works on Python2 or Python3)
#!/usr/bin/python
# A super-simple standalone script (which makes various assumptions, and does no
# verification) to show how easily .bmap files can be parsed.
# It only supports uncompressed images, and if the image is named mydata.img it
# assumes the bmap is named mydata.bmap
# MIT License
#
# Copyright (c) 2018 Andrew Scheller
#!/usr/bin/env python3
import json
import os
import urllib.request
repo_list_url = 'https://raw.githubusercontent.com/procount/pinn-os/master/os/repo_list.json'
output_dir = 'os_metadata'
os.makedirs(output_dir, exist_ok=True)
#!/usr/bin/env python3
# Written by Andrew Scheller, May 2021
# Released under the WTFPL
# This is a fun little script that provides an interactive text-based menu for
# the user to select an image from; once an image has been selected it prints
# the "choices path" that was navigated to get to that image, and the URL that
# the image can be downloaded from (e.g. using wget)
#
# Alternatively, if given a "choices path" it runs non-interactively and