Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Publish on crates.io #174

Open
thobson88 opened this issue Apr 19, 2024 · 7 comments · Fixed by #178
Open

Publish on crates.io #174

thobson88 opened this issue Apr 19, 2024 · 7 comments · Fixed by #178
Assignees

Comments

@thobson88
Copy link
Collaborator

thobson88 commented Apr 19, 2024

Use GitHub account: trustchain-devs with email [email protected].

(Note: this is a new gmail account, not to be confused with [email protected] used for the demo.)

TODO: decide how to publish the whole workspace, given that it's not supported by default (see here).

There's a crate for workspace publishing which looks promising, but to get the right name for the whole workspace I think we'll need to add name = trustchain to the top-level Cargo.toml.

That means making changes after the v0.1.0 tagged commit, which is annoying.

Alternatively we could just do some merging, update the metadata in Cargo.toml, tag the new release as v0.2.0 and publish that instead.

@thobson88 thobson88 self-assigned this Apr 19, 2024
@thobson88
Copy link
Collaborator Author

Remaining tasks for crates.io:

  • Check cargo-release whether to use over cargo-publish
  • Fix build on 174 (cargo build is broken by the new [package] section in top-level Cargo.toml)
  • Make PR from 174 and merge 174 with workspace toml changes
  • Tag release as v0.2.0 and publish draft
  • Check process for docs.rs publication (is this automatic?)

@sgreenbury
Copy link
Collaborator

See documentation guide.

@thobson88
Copy link
Collaborator Author

TODO:

  • Doc comments for all modules
  • Doc comments for all functions in the public API (but not enum variants)

@thobson88
Copy link
Collaborator Author

thobson88 commented May 3, 2024

UPDATE: We have a major obstacle because all dependencies must themselves be published on crates.io, which is a problem for us because Trustchain depends on our forks of third party repositories (specifically SSI and RSS).

See here and discussion here.

This would mean publishing our forks of those repos before publishing Trustchain, which seems daft.

To get the API docs online (which was part of the motivation for publishing), I'm going to try to build them into the new mkdocs site on GitHub pages #173.

@sgreenbury
Copy link
Collaborator

Additional discussion on crates.io and forks.

sgreenbury added a commit that referenced this issue May 13, 2024
Workspace package for publish and doc comments (#174)
@sgreenbury sgreenbury reopened this May 13, 2024
@thobson88
Copy link
Collaborator Author

Obstacle overcome! See #179 and PR #180.

Next step is to check doc comments and then publish from the publish branch.

@sgreenbury
Copy link
Collaborator

sgreenbury commented Aug 27, 2024

Adding some additional modifications that might be worthwhile to include in this release:

  • Remove unused deps (e.g. with cargo-machete)
  • Add workspace deps to simplify deps/versions across the workspace members (e.g. with cargo-autoinherit)
  • Restructure workspace members into a crates/ path (e.g. ssi and polars). I think it probably makes sense to keep the overall trustchain package (currently re-exports of the workspace member crates) as a package at the workspace level rather than a member.
  • Add remaining doc comments: these can be identified adding to the .cargo/config.toml to return warnings:
    [build]
    rustflags = ["-Wmissing-docs"]
    

sgreenbury added a commit that referenced this issue Jan 20, 2025
…structure

Remove unused deps, autoinherit and restructure (#174)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants