Closed alnoki closed 1 month ago
@wrwg I can format this with movefmt but not with aptos move fmt:
movefmt
aptos move fmt
module hello_wolfgang::red_black_map { enum Color { Red, Black } struct Node<V> { key: u256, value: V, color: Color } }
aptos move fmt throws:
error[E01002]: unexpected token ┌─ /a/file-path/ │ 2 │ enum Color { │ ^^^^ │ │ │ Unexpected 'enum' │ Expected a module member: 'spec', 'use', 'friend', 'const', 'fun', 'inline', or 'struct'
Perhaps there could be some kind of passthrough option that lets the CLI user choose which movefmt is in use? Or maybe a CI action @banool that can package the latest stable movefmt version with each aptos release?
aptos
Hi @alnoki, 1.0.5 supports move 2, you can use aptos update movefmt --target-version 1.0.5 to install the latest version: https://github.com/movebit/movefmt/issues/38
aptos update movefmt --target-version 1.0.5
@wrwg I can format this with
movefmt
but not withaptos move fmt
:aptos move fmt
throws:Perhaps there could be some kind of passthrough option that lets the CLI user choose which
movefmt
is in use? Or maybe a CI action @banool that can package the latest stablemovefmt
version with eachaptos
release?