-
Notifications
You must be signed in to change notification settings - Fork 0
75 lines (60 loc) · 2.52 KB
/
bench-test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: bench-test
on: [push]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
request_request:
runs-on: ubuntu-latest
name: request_request
steps:
- name: clone repo
run: git clone https://gitee.com/openharmony/request_request.git
- name: install dylint
run: cargo install cargo-dylint dylint-link
- name: add Cargo.toml dylint lib link
working-directory: ./request_request
run: echo -e "\n[workspace.metadata.dylint]\nlibraries = [\n { git = \"https://github.com/trusted-programming/cargo-mate\"},\n]" >> Cargo.toml
- name: add rayon
working-directory: ./request_request
run: |
cargo add rayon --package request
cargo add rayon --package download_server
- name: lint fix
working-directory: ./request_request
continue-on-error: true
run: cargo dylint --all --workspace --fix -- --allow-dirty --allow-no-vcs --broken-code --lib
- name: cargo check
working-directory: ./request_request
run: cargo check
- name: git diff
working-directory: ./request_request
run: git diff
commonlibrary_rust_ylong_runtime:
runs-on: ubuntu-latest
name: commonlibrary_rust_ylong_runtime
steps:
- name: clone repo
run: git clone https://gitee.com/openharmony/commonlibrary_rust_ylong_runtime.git
- name: install dylint
run: cargo install cargo-dylint dylint-link
- name: add Cargo.toml dylint lib link
working-directory: ./commonlibrary_rust_ylong_runtime
run: echo -e "\n[workspace.metadata.dylint]\nlibraries = [\n { git = \"https://github.com/trusted-programming/cargo-mate\"},\n]" >> Cargo.toml
- name: add rayon
working-directory: ./commonlibrary_rust_ylong_runtime
run: |
cargo add rayon --package ylong_runtime
cargo add rayon --package ylong_ffrt
cargo add rayon --package ylong_io
cargo add rayon --package ylong_runtime_macros
- name: lint fix
working-directory: ./commonlibrary_rust_ylong_runtime
continue-on-error: true
run: cargo dylint --all --workspace --fix -- --allow-dirty --allow-no-vcs --broken-code --lib
- name: cargo check
working-directory: ./commonlibrary_rust_ylong_runtime
run: cargo check
- name: git diff
working-directory: ./commonlibrary_rust_ylong_runtime
run: git diff