Try to add release files
stable / fmt Details
stable / cross-${{ matrix.target }} (armv7-unknown-linux-gnueabihf) Details
stable / cross-${{ matrix.target }} (aarch64-unknown-linux-gnu) Details

This commit is contained in:
chmanie 2023-06-12 16:05:22 +02:00
parent 717c5c54a5
commit 17a0e8606e
6 changed files with 13 additions and 8 deletions

View File

@ -2,7 +2,8 @@ name: CI release
run-name: CI release run-name: CI release
on: on:
push: push:
tags: '*' tags:
- '*'
jobs: jobs:
release: release:
@ -16,11 +17,13 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- run: cargo fmt --check - run: cargo fmt --check
- uses: https://github.com/Swatinem/rust-cache@v2 - uses: https://github.com/Swatinem/rust-cache@v2
with:
key: ${{ matrix.target }}
- name: cross compile for ${{ matrix.target }} - name: cross compile for ${{ matrix.target }}
run: cross build --target ${{ matrix.target }} --release run: cross build --target ${{ matrix.target }} --release
- uses: actions/release-action@main - uses: actions/release-action@main
with: with:
files: |- files: |-
target/${{ matrix.target }}/release/crabidy-server target/${{ matrix.target }}/release/cbd-tui
api_key: '${{secrets.RELEASE_TOKEN}}' api_key: '${{secrets.RELEASE_TOKEN}}'
pre_release: true pre_release: true

View File

@ -1,8 +1,8 @@
[target.armv7-unknown-linux-gnueabihf] [target.armv7-unknown-linux-gnueabihf]
xargo = false xargo = false
dockerfile = "./crabidy-server/armv7-unknown-linux-gnueabihf-Dockerfile" dockerfile = "./armv7-unknown-linux-gnueabihf-Dockerfile"
[target.aarch64-unknown-linux-gnu] [target.aarch64-unknown-linux-gnu]
xargo = false xargo = false
dockerfile = "./crabidy-server/aarch64-unknown-linux-gnu-Dockerfile" dockerfile = "./aarch64-unknown-linux-gnu-Dockerfile"

View File

@ -43,7 +43,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
tokio::task::spawn_blocking(|| { tokio::task::spawn_blocking(|| {
run_ui(ui_tx, ui_rx); run_ui(ui_tx, ui_rx);
}) })
.await; .await?;
Ok(()) Ok(())
} }
@ -55,14 +55,16 @@ async fn orchestrate<'a>(
let mut rpc_client = rpc::RpcClient::connect(&config.server.address).await?; let mut rpc_client = rpc::RpcClient::connect(&config.server.address).await?;
if let Some(root_node) = rpc_client.get_library_node("node:/").await? { if let Some(root_node) = rpc_client.get_library_node("node:/").await? {
tx.send(MessageToUi::ReplaceLibraryNode(root_node.clone())); tx.send(MessageToUi::ReplaceLibraryNode(root_node.clone()))?;
} }
let init_data = rpc_client.init().await?; let init_data = rpc_client.init().await?;
tx.send_async(MessageToUi::Init(init_data)).await?; tx.send_async(MessageToUi::Init(init_data)).await?;
loop { loop {
poll(&mut rpc_client, &rx, &tx).await.ok(); if let Err(er) = poll(&mut rpc_client, &rx, &tx).await {
println!("ERROR");
}
} }
} }

View File

@ -4,7 +4,7 @@ version = "0.1.0"
edition = "2021" edition = "2021"
[[bin]] [[bin]]
name = "crabidy_server" name = "crabidy-server"
path = "src/main.rs" path = "src/main.rs"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html