Note
Highlights information that users should take into account, even when skimming.
Important
Crucial information necessary for users to succeed.
Warning
This gist contains shell files intended to make the setup process a seamless one.
To make use of these scripts, you will need to have bash
installed, as well as jq
, and curl
.
Note: Mac OS users have
bash
installed on their machines by default.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ses@1.2.0 | |
'use strict'; | |
(() => { | |
const functors = [ | |
// === functors[0] === | |
({ imports: $h_imports, liveVar: $h_live, onceVar: $h_once, importMeta: $h____meta, }) => (function () { 'use strict'; $h_imports([]); /* global globalThis */ | |
/* eslint-disable no-restricted-globals */ | |
/** | |
* commons.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const c = new Compartment({ console, Math: { log2: Math.log2 }); | |
c.evaluate( | |
` | |
console.log('---------------') | |
console.group('---- inside compartment ----') | |
console.log('---------------') | |
const num = 10; |
- Make the
clock
plug-in usingendo make --UNCONFINED
~/ ==> git clone https://gist.github.com/tgrecojs/71ed5f69356eef848a9b0e0328cffb79 && cd $_
~/71ed5f69356eef848a9b0e0328cffb79 ==> endo make --UNSAFE src/clock.js -n clock
Object [Alleged: Clock] {}
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
import "@endo/init"; | |
const isFrozen = o => Object.isFrozen(o); | |
const mathCompartment = new Compartment({ Math, print: console.log }); | |
mathCompartment.evaluate(` | |
const result = Math.pow(2, 5); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
import 'ses'; | |
lockdown(); | |
const isFrozen = x => Object.isFrozen(x); | |
const c1 = new Compartment({ console, Date }); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"amount": 2000, | |
"address": "cosmos1p00xhl9ysacadcduxglhavstr8yvh9hfzk6z6w", | |
"pubkey": "033f1d99e8f90c8b46e7a2f14f3fa52ce484bd419744b3bac58db2b227b87a2e5a", | |
"PrivateKey": "047baf28b432df107dcfb71d21ecc93a655cfaf842b5e4268a9603369c39c47d" | |
}, | |
{ | |
"amount": 2000, | |
"address": "cosmos1yquxnvua4me07zxyq85fnxkdg9htqvn90x8m7h", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @file endo plugin for cosmos network protocol primitives: RPC, LCD (aka API). | |
*/ | |
// @ts-check | |
/* global globalThis */ | |
import { Far } from '@endo/far'; | |
import { makeHttpClient, makeLCD } from './httpClient.js'; | |
assert.typeof(globalThis.fetch, 'function'); |
I ran into an issue when trying to create the channel due to a mismatch of keys. The output below shows the error that I received. The issue was - the keys generated via gm keys
were not in sync with the keys that hermes had known about.
hermes create channel --a-chain ibc-0 --b-chain agoriclocal --a-port transfer --b-port pegasus --new-client-connection
2023-05-31T22:18:46.926628Z INFO ThreadId(01) using default configuration from '/Users/tgreco/.hermes/config.toml'
NewerOlder