Skip to content

Instantly share code, notes, and snippets.

View ross-spencer's full-sized avatar
💭
🖖

Ross Spencer ross-spencer

💭
🖖
View GitHub Profile
@mikekeke
mikekeke / PAB_setup.md
Last active January 25, 2023 17:43
PAB setup

Hosted PAB setup

This document describes how to prepare hosted PAB deployment from scratch that can operate on Alonzo purple testnet.

The following required to be run on host machine to use PAB with contracts in hosted scenario on testnet (for 2020-11-05 PAB Release):

  • Cardano node connected to Alonzo testnet
  • cardano wallet connected to node
  • chain-index connected to node
  • PAB executable connected to node, cardano-wallet and chain-index

Note: we are using somewhat more involved setup with a bit custom docker compose, and wallet and chain-index being built from sources, but there is ready to go node+wallet docker solution available

@michaeljclark
michaeljclark / please-license.c
Created November 21, 2020 08:15
PLEASE LICENSE is a software license somewhere in between the ISC license and public domain.
/*
* PLEASE LICENSE 11/2020, John Smith <john.smith@example.com>
*
* All rights to this work are granted for all purposes, with exception of
* author's implied right of copyright to defend the free use of this work.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES

AM - AtoM Docker Compose integration

Connect AM and AtoM Docker Compose environments using a shared external volume and other tweaks needed to test and develop DIP uploads between both applications.

  1. Setup both Docker Compose environments independently:

  2. Create local folder and Docker volume:

@aciceri
aciceri / bf2pyc.py
Last active March 14, 2024 16:38
Brainfuck to Python bytecode compiler
#!/usr/bin/env python3
from sys import exit, stdin
from argparse import ArgumentParser, RawDescriptionHelpFormatter, FileType
from types import CodeType
from dis import dis, opmap
import marshal
from importlib.util import MAGIC_NUMBER
from textwrap import dedent
@mohanpedala
mohanpedala / bash_strict_mode.md
Last active May 17, 2024 12:44
set -e, -u, -o, -x pipefail explanation
@sinclairtarget
sinclairtarget / bernoulli.c
Created August 17, 2018 20:22
Lovelace's Note G Program in C
#include <stdio.h>
/*
* Calculates what Ada Lovelace labeled "B7", which today we would call the 8th
* Bernoulli number.
*/
int main(int argc, char* argv[])
{
// ------------------------------------------------------------------------
// Data
import urllib.request, json
import re
import pandas as pd
import spotipy
import itertools
# you will need to create a spotify app and add the credentials below
# also create a public spotify playlist and get it ID (the last part of its URI)
# import spotipy.util as util
# token = util.prompt_for_user_token('hfmuehleisen',"playlist-modify-public",client_id='XXX',client_secret='XXX',redirect_uri='http://example.com/callback')
@anjackson
anjackson / puid-fmt-583.csv
Last active December 14, 2017 15:07
Current results for fmt/583 from the frequent crawl index
crawl_date content_type_ext content_type_tika content_ffb url
2016-04-18T18:15:10Z shtml application/xhtml+xml; charset=windows-1252 0d0a0d0a http://www.southportreporter.com/484/484-7.shtml
2016-08-11T22:48:34Z htm text/html; charset=windows-1252 3c68746d https://www.iwight.com/Meetings/committees/Policy%20Commission%20for%20Economy/4-4-07/minutes.htm
2016-01-06T05:23:06Z aspx application/xhtml+xml; charset=UTF-8 3c21444f http://www.t.www.rspb.org.uk/discoverandenjoynature/discoverandlearn/birdguide/name/w/wheatear/videos.aspx
2016-01-06T04:20:01Z aspx application/xhtml+xml; charset=UTF-8 3c21444f http://www.t.www.rspb.org.uk/discoverandenjoynature/seenature/events/details.aspx?id=tcm:9-404023
2016-09-08T19:26:46Z aspx application/xhtml+xml; charset=UTF-8 3c21444f http://www.rspb.org.uk/discoverandenjoynature/seenature/reserves/tags.aspx?tag=flowers
2016-01-06T05:10:16Z application/xhtml+xml; charset=UTF-8 3c21444f http://www.information.www.rspb.org.uk/vacancies/details/411612-membership-development-office
@exlcodeshare
exlcodeshare / collection_metadata.xml
Last active November 16, 2021 06:24
Rosetta Delivery XML examples
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<collection-metadata>
<collection-dc>
<dc:record xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:mets="http://www.loc.gov/METS/">
<dc:title>Western Star</dc:title>
<dcterms:isPartOf>Newspapers</dcterms:isPartOf>
</dc:record>
</collection-dc>
</collection-metadata>
@anjackson
anjackson / Nanite on DROID 6.1.3 branch.
Last active March 19, 2017 22:40
Nanite basic comparison with Skeleton Suite
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/fmt/fmt-894-signature-id-1241.gjf
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/fmt/fmt-899-signature-id-1249.exe
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/fmt/fmt-900-signature-id-1251.exe
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/x-fmt/x-fmt-411-signature-id-198.exe
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/x-fmt/x-fmt-451-signature-id-243.skb
FAIL: File could not be identified! src/test/resources/skeleton-suite-test/skeleton-suite-pronom-export-2017-03-08-sig-file-v89/x-fmt/x-fmt-453-signature-id-242.ttf