Skip to content

Instantly share code, notes, and snippets.

Avatar
🔰
( ͡ᵔ ͜ʖ ͡ᵔ )

Max Ogden maxogden

🔰
( ͡ᵔ ͜ʖ ͡ᵔ )
View GitHub Profile
@maxogden
maxogden / bibtex.png
Last active Nov 25, 2020
How to make a scientific looking PDF from markdown (with bibliography)
@maxogden
maxogden / urls.txt
Created Aug 8, 2017
Scihub DOI resolved URLs by frequency
View urls.txt
15030476 linkinghub.elsevier.com
9053559 link.springer.com
7949710 doi.wiley.com
3749242 ieeexplore.ieee.org
3468507 www.tandfonline.com
2005530 academic.oup.com
2000344 www.jstor.org
1662232 content.wkhealth.com
1498775 www.degruyter.com
1438236 pubs.acs.org
@maxogden
maxogden / readme.md
Created Feb 4, 2017
my book duo (16tb) linux format
View readme.md
  1. install WD Drive Utilities on Mac OS
  2. convert to JBOD/EXFAT and turn off Drive Sleep
  3. plug into linux
sudo parted /dev/sd<num>
print
rm 1 (and others)
mklabel gpt
unit TB
View readme.md

Disclaimer: This is an unofficial post by a random person from the community. I am not an official representative of io.js. Want to ask a question? open an issue on the node-forward discussions repo

io.js - what you need to know

io-logo-substack

  • io is a fork of node v0.12 (the next stable version of node.js, currently unreleased)
  • io.js will be totally compatible with node.js
  • the people who created io.js are node core contributors who have different ideas on how to run the project
  • it is not a zero-sum game. many core contributors will help maintain both node.js and io.js
@maxogden
maxogden / index.sh
Last active Oct 31, 2020
generate ES512 and RS256 elliptic curve keypairs for JWT JWK (JSON Web Token JSON Web Key) using openssl
View index.sh
# RS256
# private key
openssl genrsa -out rs256-4096-private.rsa 4096
# public key
openssl rsa -in rs256-4096-private.rsa -pubout > rs256-4096-public.pem
# ES512
# private key
openssl ecparam -genkey -name secp521r1 -noout -out ecdsa-p521-private.pem
# public key
@maxogden
maxogden / 0.md
Last active Oct 25, 2020
JS hoisting by example
View 0.md

JavaScript function hoisting by example

Below are many examples of function hoisting behavior in JavaScript. Ones marked as works successfuly print 'hi!' without errors.

To play around with these examples (recommended) clone them with git and execute them with e.g. node a.js

Notes on hoisting

(I may be using incorrect terms below, please forgive me)

@maxogden
maxogden / upload.sh
Created Mar 27, 2019
upload large file to zenodo from command line (curl)
View upload.sh
# in zenodo ui create a deposition. get the id
curl -H "Accept: application/json" -H "Authorization: Bearer $TOKEN" "https://www.zenodo.org/api/deposit/depositions/$DEPOSITION"
# get the bucket id from above
curl --progress-bar -o /dev/null --upload-file ./$FILE https://www.zenodo.org/api/files/$BUCKET/$FILE?access_token=$TOKEN
@maxogden
maxogden / index.js
Created May 17, 2019
secp256k1 encrypt/decrypt with bip32 keys
View index.js
var KeyEncoder = require('key-encoder')
var VirgilCrypto = require('virgil-crypto').VirgilCrypto
var HDKey = require('hdkey')
const secp256k1 = require('secp256k1')
var keyEncoder = new KeyEncoder('secp256k1')
var hdKey = HDKey.fromMasterSeed(Buffer.from(SEED, 'hex'))
var childKey = hdKey.derive(PATH)
@maxogden
maxogden / readme.md
Last active Oct 20, 2020
node modules for converting PDFs into other formats
View readme.md
@maxogden
maxogden / readme.md
Last active Sep 29, 2020
merkle dag replication draft
View readme.md

Synchronization for Merkle graphs

abstract

intro

  • Problem we’re solving: Efficient p2p Merkle DAG replication
  • Proposed solution in a nutshell: Simplistic and symmetric protocol with reference implementation in Node.js
You can’t perform that action at this time.