Skip to content

Commit 385ecdf

Browse files
authored
Merge pull request #75 from dashingfon/master
Added the osaka opcodes and type hints
2 parents 3c5ece9 + 2001bc7 commit 385ecdf

File tree

4 files changed

+282
-115
lines changed

4 files changed

+282
-115
lines changed

README.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ pyevmasm is an assembler and disassembler library for the Ethereum Virtual Machi
1010

1111
`evmasm` is a commandline utility that uses pyevmasm to assemble or disassemble EVM:
1212

13-
```
13+
```sh
1414
usage: evmasm [-h] (-a | -d | -t) [-bi] [-bo] [-i [INPUT]] [-o [OUTPUT]] [-f FORK]
1515

1616
pyevmasm the EVM assembler and disassembler
@@ -35,7 +35,7 @@ optional arguments:
3535
3636
Disassembling the preamble of compiled contract:
3737
38-
```
38+
```sh
3939
$ echo -n "608060405260043610603f57600035" | evmasm -d
4040
00000000: PUSH1 0x80
4141
00000002: PUSH1 0x40
@@ -51,7 +51,7 @@ $ echo -n "608060405260043610603f57600035" | evmasm -d
5151
5252
## Python API Examples
5353
54-
```
54+
```sh
5555
>>> from pyevmasm import instruction_tables, disassemble_hex, disassemble_all, assemble_hex
5656
>>> instruction_table = instruction_tables['byzantium']
5757
>>> instruction_table[20]
@@ -78,17 +78,23 @@ MSTORE
7878
Python >=3.10 is required.
7979
8080
Install the latest stable version using pip:
81-
```
81+
```sh
8282
pip install pyevmasm
8383
```
8484
8585
Or, install the library from source:
86-
```
86+
```sh
8787
git clone https://github.com/trailofbits/pyevmasm
8888
cd pyevmasm
8989
python setup.py install --user
9090
```
9191
92+
to run the tests
93+
94+
```sh
95+
python -m unittest tests\test_EVMAssembler.py -v
96+
```
97+
9298
## Documentation
9399
94100
[https://pyevmasm.readthedocs.io](https://pyevmasm.readthedocs.io)

0 commit comments

Comments
 (0)