Skip to content

Instantly share code, notes, and snippets.

View jimlambie's full-sized avatar
🐙

James Lambie jimlambie

🐙
  • Dunedin, New Zealand
  • 09:57 (UTC +12:00)
View GitHub Profile
@jimlambie
jimlambie / Mapmyrun exporter.js
Created October 3, 2022 06:32 — forked from stampyzfanz/Mapmyrun exporter.js
Exports Mapmyrun workouts to a series of tcx files which can be imported into lots of software.
// # Javascript to copy in dev tools console
let data = await (await fetch("https://www.mapmyrun.com/internal/allWorkouts/?started_after=2020-01-29")).json()
// Change started_after for date you want to filter from or remove entirely for every workout
// Api parameters:
// number user= *id* - can be found in url of the person's profile ie https://www.mapmyrun.com/profile/[id]/activity_feed
// ISO-8601-date started_after= *date* for example this is valid 2020-01-29
// ISO-8601-date started_before= *date* this is another valid date 2011-10-05T14:48:00.000Z
// Remove ?user= to access only your own workouts
// Example url using all 3 parameters
// https://www.mapmyrun.com/internal/allWorkouts/?started_after=2020-01-29&started_before=2021-5-29&user=123456789
@jimlambie
jimlambie / celo
Created February 15, 2021 12:24
CELO development starter tutorial
CELO Testnet Address: 0xC0317003c3F7C88b50eF416D3C25C250EaA8948B

Local computer

  1. Make new directory and change into it
~ $ mkdir my-files
~ $ cd my-files
  1. Add a new file to the directory
BASE_PORT=3001
INCREMENT=1
port=$BASE_PORT
isfree=$(netstat -taln | grep $port)
while [[ -n "$isfree" ]]; do
port=$[port+INCREMENT]
isfree=$(netstat -taln | grep $port)
done

Keybase proof

I hereby claim:

  • I am jimlambie on github.
  • I am jimlambie (https://keybase.io/jimlambie) on keybase.
  • I have a public key ASA6aKbpU8CsoQdHOtOu6a6WFemxHrkhb3X-TWD2n6LwDwo

To claim this, I am signing this object:

@jimlambie
jimlambie / sale.md
Last active January 26, 2018 11:30

Public Sale Contract

Things to test

  • The USD/ETH rate in the contract is $1064.11/ETH
  • There is a USD5000 individual cap, so the maximum you could contribute is ~4.69 ETH
  • The maximum gas price is 60 Gwei. Transactions above this will be rejected.
  1. go to MyEtherWallet.com
  2. make sure you're on the Rinkeby network
  3. slect "contracts"
  4. enter contract address: e.g. 0xfCF1c289390614adA6779b192d297B9442e318F4
  5. enter ABI:
[{"constant": true,"inputs": [],"name": "beneficiary","outputs": [{"name": "",    "type": "address" }
      ],"payable": false,"stateMutability": "view","type": "function"},{
      "constant": false,"inputs": [],"name": "claim","outputs": [],"payable": false,"stateMutability": "nonpayable","type": "function" },{

0x0A1f6c2bE095DF39141B3735288EF74CfB04eF08

0x0078E498b87A1E683A7A7CdF5E4EDfEb463dA763

0x0078E498b87A1E683A7A7CdF5E4EDfEb463dA763