Go to file
Fabian Grünbichler e6d1e6440d add bump.sh
for bumping crates in this workspace (it requires cargo-edit being installed).

Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
2022-12-07 10:36:27 +01:00
.cargo cargo: switch to use packaged crates by default 2020-01-03 09:39:52 +01:00
proxmox-api-macro inherit shared, external dependencies 2022-12-07 09:48:38 +01:00
proxmox-async define workspace dependencies in workspace 2022-12-07 09:48:38 +01:00
proxmox-borrow move common metadata to workspace 2022-12-07 09:48:25 +01:00
proxmox-compression update d/control files 2022-12-07 09:48:47 +01:00
proxmox-http update d/control files 2022-12-07 09:48:47 +01:00
proxmox-io update d/control files 2022-12-07 09:48:38 +01:00
proxmox-lang move common metadata to workspace 2022-12-07 09:48:25 +01:00
proxmox-metrics update d/control files 2022-12-07 09:48:47 +01:00
proxmox-rest-server update d/control files 2022-12-07 09:48:47 +01:00
proxmox-router update d/control files 2022-12-07 09:48:47 +01:00
proxmox-schema define workspace dependencies in workspace 2022-12-07 09:48:38 +01:00
proxmox-section-config update d/control files 2022-12-07 09:48:47 +01:00
proxmox-serde update d/control files 2022-12-07 09:48:47 +01:00
proxmox-shared-memory update d/control files 2022-12-07 09:48:47 +01:00
proxmox-sortable-macro inherit shared, external dependencies 2022-12-07 09:48:38 +01:00
proxmox-subscription update d/control files 2022-12-07 09:48:47 +01:00
proxmox-sys update d/control files 2022-12-07 09:48:47 +01:00
proxmox-tfa update d/control files 2022-12-07 09:48:47 +01:00
proxmox-time proxmox-time: drop TryFrom use statement 2022-12-07 09:48:47 +01:00
proxmox-uuid update d/control files 2022-12-07 09:48:38 +01:00
.gitignore git: ignore top level *-deb make target files 2022-08-26 12:18:44 +02:00
build.sh build: track d/control in git 2020-11-30 15:13:01 +01:00
bump.sh add bump.sh 2022-12-07 10:36:27 +01:00
Cargo.toml update outdated workspace dependencies 2022-12-07 09:48:47 +01:00
Makefile rest-server: add packaging and bump to 0.2.0 2022-10-11 15:09:50 +02:00
README.rst start checklist for adding crates in README.rst 2021-10-06 10:37:17 +02:00
rustfmt.toml bump edition in rustfmt.toml 2022-10-13 15:00:28 +02:00

Local cargo config
==================

This repository ships with a ``.cargo/config`` that replaces the crates.io
registry with packaged crates located in ``/usr/share/cargo/registry``.

A similar config is also applied building with dh_cargo. Cargo.lock needs to be
deleted when switching between packaged crates and crates.io, since the
checksums are not compatible.

To reference new dependencies (or updated versions) that are not yet packaged,
the dependency needs to point directly to a path or git source.

Steps for Releases
==================

- Cargo.toml updates:
  - Bump all modified crate versions.
  - Update all the other crates' Cargo.toml to depend on the new versions if
    required, then bump their version as well if not already done.
- Update debian/changelog files in all the crates updated above.
- Build packages with `make deb`.

Adding Crates
=============

1) At the top level:
  - Generate the crate: ``cargo new --lib the-name``
  - Sort the crate into ``Cargo.toml``'s ``workspace.members``
  - Sort the crate into the ``Makefile``'s ``CRATES`` list.

2) In the new crate's ``Cargo.toml``:
  - Replace the ``author`` line with
    ``authors = ["Proxmox Support Team <support@proxmox.com>"]``
  - Add ``license = "AGPL-3"``
  - Add ``exclude = [ "debian" ]``
  - Add a meaningful ``description``
  - Copy ``debian/copyright`` and ``debian/debcargo.toml`` from another subcrate.