|
1 | 1 | project_name: smart-patcher |
2 | | -version: 5 |
3 | | -langs: |
4 | | - - rust |
5 | | -targets: |
6 | | - - arch: x86_64 |
7 | | - os: linux |
8 | | - os_derivative: any |
9 | | - os_version: |
10 | | - type: no |
11 | | -cache_files: |
| 2 | +version: 7 |
| 3 | +ignore_files: |
12 | 4 | - .git |
| 5 | +cache_files: |
13 | 6 | - Cargo.lock |
| 7 | + - examples |
14 | 8 | - target |
15 | | -variables: [] |
| 9 | +variables: |
| 10 | + app: |
| 11 | + is_secret: false |
| 12 | + value: |
| 13 | + type: plain |
| 14 | + value: target/release/smart-patcher |
| 15 | +actions: |
| 16 | + - info: cargo-fmt@0.1.0 |
| 17 | + action: |
| 18 | + type: staged |
| 19 | + stage: build |
| 20 | + cmd: cargo fmt -- --config tab_spaces=2,max_width=120 */**/*.rs |
| 21 | + - info: cargo-install-by-copy@0.1.0 |
| 22 | + action: |
| 23 | + type: staged |
| 24 | + stage: build |
| 25 | + cmd: cp -f %bin% ~/.cargo/bin |
| 26 | + placeholders: |
| 27 | + - "%bin%" |
| 28 | + - info: cargo-lint@0.1.0 |
| 29 | + action: |
| 30 | + type: staged |
| 31 | + stage: build |
| 32 | + cmd: cargo clippy |
| 33 | + show_success_output: true |
| 34 | + - info: cargo-release@0.1.0 |
| 35 | + tags: |
| 36 | + - rust |
| 37 | + - cargo |
| 38 | + requirements: |
| 39 | + - type: exists_any |
| 40 | + paths: |
| 41 | + - /bin/cargo |
| 42 | + - ~/.cargo/bin/cargo |
| 43 | + action: |
| 44 | + type: staged |
| 45 | + stage: build |
| 46 | + cmd: cargo build --release |
| 47 | + - info: cargo-test@0.1.0 |
| 48 | + action: |
| 49 | + type: staged |
| 50 | + stage: build |
| 51 | + cmd: cargo test --lib |
| 52 | + - info: sp-copy-tests@0.1.0 |
| 53 | + action: |
| 54 | + type: custom |
| 55 | + cmd: cp tests/*.py . |
| 56 | + - info: sp-generate-examples@0.1.0 |
| 57 | + action: |
| 58 | + type: staged |
| 59 | + stage: deploy |
| 60 | + cmd: cargo run --no-default-features --features=generate-patches -- generate-examples |
| 61 | + - info: upx@0.1.0 |
| 62 | + requirements: |
| 63 | + - type: exists_any |
| 64 | + paths: |
| 65 | + - /bin/upx |
| 66 | + - /usr/bin/upx |
| 67 | + - ~/.local/bin/upx |
| 68 | + action: |
| 69 | + type: staged |
| 70 | + stage: build |
| 71 | + cmd: upx %af% |
| 72 | + placeholders: |
| 73 | + - "%af%" |
16 | 74 | pipelines: |
17 | | - - title: build |
18 | | - desc: Got from `Default Rust Pipeline`. |
19 | | - info: rust-default@0.1.0 |
| 75 | + - title: generate-examples |
| 76 | + desc: Generate example patches and move them to the project folder |
| 77 | + info: generate-examples@0.1.0 |
| 78 | + tags: |
| 79 | + - rust |
| 80 | + - cargo |
| 81 | + default: false |
| 82 | + artifacts: |
| 83 | + - from: examples |
| 84 | + to: ../examples |
| 85 | + actions: |
| 86 | + - title: Generate examples |
| 87 | + used: sp-generate-examples@0.1.0 |
| 88 | + - title: install |
| 89 | + desc: Default Rust pipeline to install binary |
| 90 | + info: rust-default-install@0.1.0 |
20 | 91 | tags: |
21 | 92 | - rust |
22 | 93 | - cargo |
| 94 | + - clippy |
| 95 | + - fmt |
23 | 96 | - upx |
24 | 97 | default: true |
| 98 | + exclusive_exec_tag: "" |
25 | 99 | artifacts: |
26 | 100 | - from: target/release/smart-patcher |
27 | 101 | to: smart-patcher |
28 | 102 | actions: |
29 | 103 | - title: Lint |
30 | | - info: cargo-clippy@0.1.0 |
31 | | - tags: |
32 | | - - cargo |
33 | | - - clippy |
34 | | - action: |
35 | | - type: pre_build |
36 | | - supported_langs: |
37 | | - - rust |
38 | | - commands: |
39 | | - - bash_c: cargo clippy --no-default-features |
40 | | - show_success_output: true |
41 | | - - title: Lint v2 |
42 | | - info: cargo-clippy@0.1.0 |
43 | | - tags: |
44 | | - - cargo |
45 | | - - clippy |
46 | | - action: |
47 | | - type: pre_build |
48 | | - supported_langs: |
49 | | - - rust |
50 | | - commands: |
51 | | - - bash_c: cargo clippy --no-default-features --features=lua,rhai |
52 | | - show_success_output: true |
| 104 | + used: cargo-lint@0.1.0 |
53 | 105 | - title: Format |
54 | | - info: cargo-format@0.1.0 |
55 | | - tags: [] |
56 | | - exec_in_project_dir: true |
57 | | - action: |
58 | | - type: pre_build |
59 | | - supported_langs: |
60 | | - - rust |
61 | | - commands: |
62 | | - - bash_c: cargo fmt -- --config tab_spaces=2,max_width=120 */**/*.rs |
| 106 | + used: cargo-fmt@0.1.0 |
63 | 107 | - title: Build |
64 | | - info: cargo-rel@0.1.0 |
65 | | - tags: |
66 | | - - rust |
67 | | - - cargo |
68 | | - action: |
69 | | - type: build |
70 | | - supported_langs: |
71 | | - - rust |
72 | | - commands: |
73 | | - - bash_c: cargo build --release --no-default-features --features=lua,rhai |
| 108 | + used: cargo-release@0.1.0 |
| 109 | + - title: Copy tests |
| 110 | + used: sp-copy-tests@0.1.0 |
74 | 111 | - title: Test |
75 | | - info: cargo-test@0.1.0 |
76 | | - tags: |
77 | | - - cargo |
78 | | - - rust |
79 | | - - test |
80 | | - action: |
81 | | - type: post_build |
82 | | - supported_langs: |
83 | | - - rust |
84 | | - commands: |
85 | | - - bash_c: cp tests/*.py . |
86 | | - - bash_c: cargo test --lib --no-default-features --features=lua,rhai |
| 112 | + used: cargo-test@0.1.0 |
87 | 113 | - title: Compress |
88 | | - info: upx-compress@0.1.0 |
89 | | - tags: |
90 | | - - upx |
91 | | - action: |
92 | | - type: post_build |
93 | | - supported_langs: |
94 | | - - rust |
95 | | - - go |
96 | | - - c |
97 | | - - cpp |
98 | | - - python |
99 | | - - any |
100 | | - commands: |
101 | | - - bash_c: upx <artifact> |
102 | | - ignore_fails: true |
103 | | - show_bash_c: false |
104 | | - placeholders: |
105 | | - - <artifact> |
106 | | - replacements: |
107 | | - - group: |
108 | | - - from: <artifact> |
109 | | - to: |
110 | | - title: target/release/smart-patcher |
111 | | - is_secret: false |
112 | | - value: |
113 | | - type: plain |
114 | | - value: target/release/smart-patcher |
| 114 | + used: upx@0.1.0 |
| 115 | + with: |
| 116 | + "%af%": app |
115 | 117 | - title: Install |
116 | | - info: install-to-cargo-bin@0.1.0 |
117 | | - tags: |
118 | | - - rust |
119 | | - - cargo |
120 | | - action: |
121 | | - type: post_build |
122 | | - supported_langs: |
123 | | - - rust |
124 | | - commands: |
125 | | - - bash_c: cp -f <af> ~/.cargo/bin |
126 | | - only_when_fresh: false |
127 | | - placeholders: |
128 | | - - <af> |
129 | | - replacements: |
130 | | - - group: |
131 | | - - from: <af> |
132 | | - to: |
133 | | - title: target/release/smart-patcher |
134 | | - is_secret: false |
135 | | - value: |
136 | | - type: plain |
137 | | - value: target/release/smart-patcher |
138 | | - - title: generate-patches |
139 | | - desc: Got from `Default Rust Pipeline`. |
140 | | - info: rust-default@0.1.0 |
141 | | - tags: |
142 | | - - rust |
143 | | - - cargo |
144 | | - - upx |
145 | | - artifacts: |
146 | | - - from: target/release/smart-patcher |
147 | | - to: smart-patcher |
148 | | - actions: |
149 | | - - title: Generate patches |
150 | | - info: cargo-run@0.1.0 |
151 | | - tags: |
152 | | - - rust |
153 | | - - cargo |
154 | | - action: |
155 | | - type: build |
156 | | - supported_langs: |
157 | | - - rust |
158 | | - commands: |
159 | | - - bash_c: cargo run --no-default-features --features=generate-patches -- generate-examples |
160 | | - show_success_output: true |
| 118 | + used: cargo-install-by-copy@0.1.0 |
| 119 | + with: |
| 120 | + "%bin%": app |
0 commit comments