Commit Graph

85 Commits

Author SHA1 Message Date
microproofs
55887d3a45 fix: decode should always print to textual 2023-08-01 00:47:29 -04:00
Cainã Costa
49cc76cf77 chore: cargo fmt 2023-07-25 14:00:29 -04:00
Cainã Costa
2cecb099d7 feat: add a generator for shell completions 2023-07-25 14:00:29 -04:00
rvcas
152e847e26 chore: no longer need this env var 2023-07-24 10:30:02 -04:00
Cainã Costa
d19a39239d fix: fix clippy error 2023-07-24 10:24:37 -04:00
Pi Lanningham
27c0f25606 Add a blueprint hash command
Similar to blueprint address and blueprint policy, this just prints the
hash of the validator; useful if you need the hash, and you don't want
to pipe the address to a bech32 decoder and juggle the hex.
2023-07-21 22:57:31 -04:00
rvcas
97acd6d7bd chore: Release 2023-07-15 21:37:10 -04:00
rvcas
621017bd93 chore: Release 2023-07-14 10:55:13 -04:00
rvcas
a36cc7d631 fix: cpu and mem in white terminals, cyan makes things stand out nicely closes #415 2023-07-11 18:50:27 -04:00
Pi Lanningham
c10f0e53df cargo fmt 2023-07-01 16:17:10 -04:00
Pi Lanningham
4a8cb72708 Add a blueprint policy command
Computes the policy ID of a minting policy; added guards for blueprint address to check that it's not a minting policy; Wasn't 100% sure where the errors should live, so I'm happy to move them if there's objections
2023-07-01 16:17:10 -04:00
rvcas
90ff211205 chore: Release 2023-06-23 19:41:14 -04:00
rvcas
619b73d03e feat: enhance new command 2023-06-23 19:40:11 -04:00
rvcas
85d82e5aec chore: Release 2023-06-13 21:24:41 -04:00
rvcas
06079fa57e fix: wow 2023-06-13 21:03:16 -04:00
microproofs
379c2fe2bf chore: Release 2023-06-13 20:32:22 -04:00
rvcas
878fd4de48 feat: include column number in location 2023-06-13 20:30:43 -04:00
rvcas
44e066f907 feat: add a panic hook, present issue link 2023-06-13 20:30:43 -04:00
microproofs
c5af6e0be3 chore: Release 2023-06-08 19:34:51 -04:00
rvcas
41a08e4a06 chore: re-add nix stuff from @waalge
Co-authored-by: waalge
2023-06-07 17:16:56 -04:00
Pi Lanningham
fbec4a9385 Update docs.rs
The doc comment was long, leading to an incorrect description on the command line
2023-06-02 02:25:04 -04:00
rvcas
cb9a140601 chore: Release 2023-06-02 00:34:07 -04:00
rvcas
335cc0c8bc feat(cli): rework uplc subcommands
closes #553

* rename flat to encode
* rename unflat to decode
* alias both to their old names
* both only print to stdout
  use can pipe to file
* split cbor and hex flags
* hex flag works for either cbor or flat
* encode takes --to flag
  [name, named-debruijn, debruijn]
* decode takes --from flag
  [name, named-debruijn, debruijn]
2023-06-01 23:50:59 -04:00
Micah Kendall
ccb2d0b7ee urgent nix patch 2023-05-19 18:28:07 -04:00
rvcas
d68d4656df feat(aiken-new): output a github action
- bonus: include git short sha in version

closes #515
2023-05-18 01:33:03 -04:00
microproofs
8e60234562 chore: Release 2023-05-17 18:04:45 -04:00
rvcas
f2d8c8938c chore: Release 2023-05-14 21:25:29 -04:00
rvcas
e1a75391a1 chore: Release 2023-05-09 23:16:59 -04:00
microproofs
b1728b57b8 chore: Release 2023-04-28 17:11:56 -04:00
KtorZ
4269cf20b0 Fix erroneous "aiken new" command's output instructions
Fixes #505.
2023-04-20 14:38:48 +02:00
rvcas
3182dac908 chore: Release 2023-04-17 10:53:30 -04:00
rvcas
3d0fa1a5f6 chore: Release 2023-04-16 16:49:08 -04:00
rvcas
63ddef7efb chore: Release 2023-04-13 13:37:12 -04:00
rvcas
12e8ebdf4f chore: revert version bumps 2023-04-13 13:03:43 -04:00
KtorZ
067e39286d Bump versions to 1.0.0-alpha, update CHANGELOG. 2023-04-13 17:35:21 +02:00
KtorZ
00550f8ddb Add myself as co-authors for some of the project's crate
Forgot to do it before, and noticing now :D
2023-04-13 17:25:21 +02:00
KtorZ
e2c78bdd3b Add min rust-version to crates
So that people runs into better errors if they try installing from source with an 'obsolete' rust compiler.
2023-04-13 17:24:44 +02:00
KtorZ
74a7257ec9 Add some more instructions to 'blueprint apply' command help text. 2023-04-13 12:23:20 +02:00
KtorZ
4799af3242 Rework 'blueprint apply' command and wrap up wiring up validation.
The apply command now works only from a serialized CBOR data (instead of a UPLC syntax). So it is no longer possible to specify arbitrary cbor terms through the CLI. I believe it to be an acceptable limitation for now; especially given that Aiken will never generate blueprints with non-data terms at the interface boundary.
2023-04-08 08:57:40 +02:00
KtorZ
cdc7ebf9a0 Remove now-unnecessary blueprint generics.
These were needed before as a way to _partially deserialize_
  blueprints. Indeed, some commands required accessing information of
  the blueprint, but not necessarily the schema. So out of laziness (or
  cleverness?), we only deserialized validators as serde::Value and
  achieved that through the use of generics.

  Now that validators and schemas have proper deserialisers, we can
  simply deserialize a blueprint.

  TODO: Our serialisation/deserialisation is safe with regards to
  itself; i.e. it roundtrips. However, we only supports a subset of the
  specified blueprint format. For example, we would fail to deserialize
  blueprints that have inline data-schemas (we only use references).
2023-04-08 08:53:51 +02:00
KtorZ
6422027c6c Fix README template for newly generated projects, and hello, world 2023-03-18 22:23:55 +01:00
KtorZ
451737237e Fix blueprint generation for recursive types.
This was a bit tricky and I ended up breaking things down a lot and
  trying different path. This commit is the result of the most
  satisfying one.

  It introduces a new 'concept' and types: Definitions and Reference.
  These elements are meant to reflect JSON pointers and JSON-schema
  definitions which we now use for pretty much all user-defined
  data-types.

  In fact, Schemas are no longer inlined, but are always referencing
  some schema under "definitions".

  This indirection is necessary in order to cope with recursive types.
  And while it's only truly necessary for recursive types, using it
  consistently makes it both easier to produce and easier to consume.

  ---

  The blueprint generation for recursive types here also works thanks to
  the 'Definitions' data-structure wrapper around a BTreeMap. This uses
  a strategy where:

  (1) schemas are only generated if they haven't been seen before
  (2) schemas are marked as seen BEFORE actually being generated (to
  effectively stop a recursive generation).

  This relies on one important aspect: the key must be uniquely
  identifying a given schema. Which means that we have to monomorphize
  data-types with generic parameters also here, and use keys that are
  specialized in one data-type.

  ---

  In this large overhaul we've also lost one thing which I didn't bother
  re-introducing yet to keep the work manageable: title for record
  fields. Before, we use to pull those from record constructor when
  available, yet now, every record constructor has been replaced by a
  `$ref`. We could theoritically attach a title to the reference. I'll
  try to quickly add that in a later commit.
2023-03-12 12:44:49 -04:00
rvcas
f8545854fc feat: json output for uplc eval 2023-03-08 10:19:36 +01:00
KtorZ
cb11b21c9f Update dependencies
In particular, tempfile >= 3.4.0 to remove the vulnerability on remove_dir_all
2023-03-08 10:17:22 +01:00
rvcas
c3175e2fc9 fix: some breaking changes from clap v4 2023-03-06 13:16:33 -05:00
rvcas
1902a2d56c chore: update all deps 2023-03-06 13:13:59 -05:00
rvcas
1f8535e76e chore: update some deps 2023-03-06 11:09:44 -05:00
rvcas
9f587e802c chore: update comment 2023-03-03 20:57:20 -05:00
rvcas
e2dc4ec6c8 feat: implement convert command 2023-03-03 20:57:20 -05:00
rvcas
812ffb30f0 feat(cli): wire together a new command for convert 2023-03-03 20:57:20 -05:00