Merge pull request #475 from hannobraun/crates

Add `crates/` and `tools/` directories
This commit is contained in:
Hanno Braun 2022-04-13 16:26:42 +02:00 committed by GitHub
commit b8e7c8bb10
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
110 changed files with 40 additions and 39 deletions

View File

@ -93,11 +93,11 @@ jobs:
uses: Swatinem/rust-cache@v1
with:
key: release-operator-01
working-directory: ./release-operator
working-directory: ./tools/release-operator
- name: Operator | Deduce
id: release
working-directory: ./release-operator
working-directory: ./tools/release-operator
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELEASE_LABEL: release
@ -130,19 +130,19 @@ jobs:
- name: Release | Crates.io
if: ${{ steps.release.outputs.release-detected == 'true' }}
working-directory: ./release-operator
working-directory: ./tools/release-operator
env:
RUST_LOG: info
run: |
# Publish to crates.io
cargo run -- publish \
--token ${{ secrets.CARGO_REGISTRY_TOKEN }} \
--crate ../fj-app \
--crate ../fj-export \
--crate ../fj-host \
--crate ../fj-interop \
--crate ../fj-kernel \
--crate ../fj-math \
--crate ../fj-operations \
--crate ../fj-viewer \
--crate ../fj
--crate ../crates/fj-app \
--crate ../crates/fj-export \
--crate ../crates/fj-host \
--crate ../crates/fj-interop \
--crate ../crates/fj-kernel \
--crate ../crates/fj-math \
--crate ../crates/fj-operations \
--crate ../crates/fj-viewer \
--crate ../crates/fj

View File

@ -1,30 +1,30 @@
[workspace]
resolver = "2"
members = [
"fj",
"fj-app",
"fj-export",
"fj-host",
"fj-interop",
"fj-kernel",
"fj-math",
"fj-operations",
"fj-viewer",
"crates/fj",
"crates/fj-app",
"crates/fj-export",
"crates/fj-host",
"crates/fj-interop",
"crates/fj-kernel",
"crates/fj-math",
"crates/fj-operations",
"crates/fj-viewer",
"models/cuboid",
"models/group",
"models/spacer",
"models/star",
"release-operator",
"tools/release-operator",
]
default-members = [
"fj-app",
"fj-export",
"fj-host",
"fj-interop",
"fj-kernel",
"fj-math",
"fj-operations",
"fj-viewer",
"crates/fj-app",
"crates/fj-export",
"crates/fj-host",
"crates/fj-interop",
"crates/fj-kernel",
"crates/fj-math",
"crates/fj-operations",
"crates/fj-viewer",
]

View File

@ -47,7 +47,7 @@ In the release branch, update the version numbers in the `Cargo.toml` files of a
Push the release branch and create a pull request and label it as `release`. Once the CI build completed successfully, merge the pull-request and mention the new version in the commit, e.g. `Release v0.1.2`.
The [release-operator](./release-operator) will run in the scope of GitHub Actions' [CD](./.github/workflows/cd.yml) workflow. It will yield a set of compiled binaries, their checksums and a new GitHub Release with all artifacts attached.
The [release-operator](./tools/release-operator) will run in the scope of GitHub Actions' [CD](./.github/workflows/cd.yml) workflow. It will yield a set of compiled binaries, their checksums and a new GitHub Release with all artifacts attached.
Next, publish the release by running `cargo publish` for each crate.

View File

@ -3,7 +3,7 @@ mod config;
use std::path::PathBuf;
use anyhow::anyhow;
use anyhow::{anyhow, Context as _};
use fj_export::export;
use fj_host::{Model, Parameters};
use fj_operations::shape_processor::ShapeProcessor;
@ -39,7 +39,8 @@ fn main() -> anyhow::Result<()> {
})?;
path.push(model);
let model = Model::from_path(path, config.target_dir)?;
let model = Model::from_path(path.clone(), config.target_dir)
.with_context(|| format!("Failed to load model: {}", path.display()))?;
let parameters = args.parameters.unwrap_or_else(Parameters::empty);
let shape_processor = ShapeProcessor {

Some files were not shown because too many files have changed in this diff Show More