Skip to content

Commit

Permalink
Merge pull request #8 from ar-io/fix-evolve
Browse files Browse the repository at this point in the history
Fix evolve
  • Loading branch information
atticusofsparta authored Aug 5, 2024
2 parents c677eff + 5913790 commit 3ec1907
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build_test_evolve.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Build and Test

on: [push]
on: [push, workflow_dispatch]

jobs:
# TODO: add unit tests using bused
Expand Down Expand Up @@ -31,4 +31,4 @@ jobs:
- run: yarn evolve
env:
WALLET: ${{ secrets.WALLET }}
REGISTRY_ID: ${{ secrets.REGISTRY_ID }}
REGISTRY_ID: ${{ vars.REGISTRY_ID }}
12 changes: 7 additions & 5 deletions tools/evolve.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
import { AOProcess, createAoSigner } from '@ar.io/sdk';
import { BUNDLED_AOS_LUA } from './constants';
import { AOProcess, createAoSigner, ArweaveSigner } from '@ar.io/sdk';
import { BUNDLED_AOS_LUA } from './constants.js';
import process from 'process';

const registryId = process.env.REGISTRY_ID;
const wallet = JSON.parse(process.env.WALLET);
const process = new AOProcess({ processId: registryId });

const registry = new AOProcess({ processId: registryId });

const signer = createAoSigner(new ArweaveSigner(wallet));

const evolveResult = await process.send({
const evolveResult = await registry.send({
tags: [{ name: 'Action', value: 'Eval' }],
data: BUNDLED_AOS_LUA,
signer,
});
console.log(`Evolve result: ${evolveResult}`);
console.log(`Evolve result: ${JSON.stringify(evolveResult)}`);

0 comments on commit 3ec1907

Please sign in to comment.