Skip to content

Commit

Permalink
Merge branch 'main' of github.com:xmtp/libxmtp into cv/duplicate-welc…
Browse files Browse the repository at this point in the history
…ome-warning
  • Loading branch information
insipx committed Oct 7, 2024
2 parents 151330d + 9f366f2 commit 2bc3c93
Show file tree
Hide file tree
Showing 137 changed files with 12,678 additions and 9,949 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Global rule:
* @xmtp/Engineering
*.md @fabriguespe
*.md @xmtp/documentation
9 changes: 2 additions & 7 deletions .github/workflows/lint-ffi-bindings.yaml
Original file line number Diff line number Diff line change
@@ -1,36 +1,31 @@
name: Lint FFI Bindings

on:
push:
branches:
- main

pull_request:
paths:
- "bindings_ffi/**"
- ".github/workflows/lint-ffi-bindings.yaml"
- "rustfmt.toml"

env:
CARGO_TERM_COLOR: always
jobs:
lint:
name: Lint
runs-on: warp-ubuntu-latest-x64-16x
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Update rust toolchains
run: rustup update

- name: Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: |
.
bindings_ffi
- name: Run clippy and fail on warnings
run: cargo clippy --manifest-path bindings_ffi/Cargo.toml --all-features --all-targets --no-deps -- -Dwarnings

- name: Run format check
run: cargo fmt --manifest-path bindings_ffi/Cargo.toml --check
3 changes: 2 additions & 1 deletion .github/workflows/lint-node-bindings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ on:
- "bindings_node/**"
- ".github/workflows/lint-node-bindings.yaml"
- "rustfmt.toml"

env:
CARGO_TERM_COLOR: always
jobs:
lint:
name: Lint
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/lint-workspace.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ on:
- "Cargo.lock"
- "rust-toolchain"
- "rustfmt.toml"
env:
CARGO_TERM_COLOR: always
jobs:
lint:
name: Lint
Expand Down
35 changes: 35 additions & 0 deletions .github/workflows/nightly-protos.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Nightly Automation
on:
schedule:
- cron: '0 10 * * 1'
workflow_dispatch:
jobs:
nightly-protos:
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: bufbuild/[email protected]
- name: Update rust toolchains
run: rustup update
- name: Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: |
.
- name: Generate Protos
run: dev/gen_protos.sh
- name: Create Pull Request
uses: peter-evans/create-pull-request@v7
with:
commit-message: Nightly Protos
title: Update Protos
body: |
- Nightly Proto Update
Auto-generated by [create-pull-request][1]
[1]: https://github.com/peter-evans/create-pull-request
branch: nightly-proto
3 changes: 2 additions & 1 deletion .github/workflows/release-cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ on:
branches:
- main
workflow_dispatch:

env:
CARGO_TERM_COLOR: always
jobs:
build:
strategy:
Expand Down
16 changes: 6 additions & 10 deletions .github/workflows/test-ffi-bindings.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
name: Test FFI Bindings

on:
push:
branches:
- main

pull_request:
# only run tests when related changes are made
paths:
Expand All @@ -21,27 +19,24 @@ on:
- "Cargo.toml"
- "Cargo.lock"
- "rust-toolchain"

env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Test
runs-on: warp-ubuntu-latest-x64-16x
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Update rust toolchains
run: rustup update

- uses: Swatinem/rust-cache@v2
with:
workspaces: |
.
bindings_ffi
- name: Start Docker containers
run: dev/up

- name: Setup Kotlin
run: |
sudo apt update -q
Expand All @@ -50,8 +45,9 @@ jobs:
cd bindings_ffi
make install-jar
echo "$(make echo-jar | tail -n 1 | sed -e 's/\.*export //')" >> "$GITHUB_ENV"
- name: Run cargo test on FFI bindings
- name: Install nextest
uses: taiki-e/install-action@nextest
- name: Run cargo nextest on FFI bindings
run: |
export CLASSPATH="${{ env.CLASSPATH }}"
cargo test --manifest-path bindings_ffi/Cargo.toml -- --test-threads=2
cargo nextest run --manifest-path bindings_ffi/Cargo.toml --test-threads 2
8 changes: 6 additions & 2 deletions .github/workflows/test-http-api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ on:
- "Cargo.toml"
- "Cargo.lock"
- "rust-toolchain"
env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Test
Expand All @@ -36,5 +38,7 @@ jobs:
.
- name: Start Docker containers
run: dev/up
- name: Run cargo test on main workspace
run: cargo test --workspace --exclude xmtp_api_grpc --features http-api -- --test-threads=2
- name: Install nextest
uses: taiki-e/install-action@nextest
- name: Run cargo nextest on main workspace
run: cargo nextest run --workspace --exclude xmtp_api_grpc --features http-api --test-threads 2
8 changes: 6 additions & 2 deletions .github/workflows/test-workspace.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ on:
- "Cargo.toml"
- "Cargo.lock"
- "rust-toolchain"
env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Test
Expand All @@ -36,5 +38,7 @@ jobs:
.
- name: Start Docker containers
run: dev/up
- name: Run cargo test on main workspace
run: cargo test -- --test-threads=2
- name: Install nextest
uses: taiki-e/install-action@nextest
- name: Run cargo nextest on main workspace
run: cargo nextest run --test-threads 2
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -164,3 +164,5 @@ ecies_bindings_wasm/
**/test_output.jsonl
**/tracing.folded
**/tracing-flamegraph.svg

chain_urls.json
Loading

0 comments on commit 2bc3c93

Please sign in to comment.