-
Notifications
You must be signed in to change notification settings - Fork 127
/
stable.toml
executable file
·296 lines (258 loc) · 9.16 KB
/
stable.toml
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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
env_files = []
env_scripts = []
[config]
init_task = "init"
end_task = "end"
skip_core_tasks = false
default_to_workspace = true
additional_profiles = []
load_cargo_aliases = false
# legacy_migration_task = "legacy-migration"
[env]
RUST_BACKTRACE = "full"
RUST_RECURSION_COUNT = { unset = true }
CARGO_MAKE_RUN_DEPRECATED_MIGRATION = { value = "true", condition = { env_not_set = [
"CARGO_MAKE_RUN_DEPRECATED_MIGRATION",
] } }
CARGO_MAKE_KCOV_VERSION = 38
CARGO_MAKE_KCOV_EXCLUDE_LINE = "kcov-ignore"
CARGO_MAKE_KCOV_EXCLUDE_REGION = "kcov-ignore-start:kcov-ignore-end"
CARGO_MAKE_KCOV_DOWNLOAD_DIRECTORY = "./target/kcov"
CARGO_MAKE_TEST_COVERAGE_DEFAULT_BINARY_FILTER = "${CARGO_MAKE_CRATE_FS_NAME}-[a-z0-9]*$\\|test_[_a-z0-9]*-[a-z0-9]*$\\|[a-z0-9]*_test-[_a-z0-9]*$"
CARGO_MAKE_TEST_COVERAGE_BINARY_FILTER = "${CARGO_MAKE_TEST_COVERAGE_DEFAULT_BINARY_FILTER}"
CARGO_MAKE_RUST_DEFAULT_TOOLCHAIN = ""
CARGO_MAKE_CARGO_ALL_FEATURES = "--all-features"
CARGO_MAKE_CARGO_VERBOSE = "--verbose"
CARGO_MAKE_CARGO_PROFILE = { source = "${CARGO_MAKE_PROFILE}", mapping = { "development" = "dev", "ci" = "test" } }
CARGO_MAKE_CARGO_VERBOSE_FLAGS = { source = "${CARGO_MAKE_CI}", default_value = "", mapping = { "true" = "${CARGO_MAKE_CARGO_VERBOSE}" } }
CARGO_MAKE_CARGO_BUILD_TEST_FLAGS = "${CARGO_MAKE_CARGO_ALL_FEATURES}"
CARGO_MAKE_CARGO_PUBLISH_NO_ARGS = ""
CARGO_MAKE_CARGO_PUBLISH_ALLOW_DIRTY = "--allow-dirty"
CARGO_MAKE_CARGO_PUBLISH_FLAGS = "${CARGO_MAKE_CARGO_PUBLISH_NO_ARGS}"
CARGO_MAKE_CARGO_PUBLISH_DELETE_LOCK_FILE = false
CARGO_MAKE_CLIPPY_ALL_FEATURES_WARN = "${CARGO_MAKE_CARGO_ALL_FEATURES} -- -D warnings"
CARGO_MAKE_CLIPPY_NO_ARGS = ""
CARGO_MAKE_CLIPPY_ARGS = "${CARGO_MAKE_CLIPPY_NO_ARGS}"
CARGO_MAKE_RUST_SCRIPT_PROVIDER = "rust-script"
CARGO_MAKE_USE_WORKSPACE_PROFILE = true
CARGO_MAKE_BINARY_EXECUTABLE_NAME = "${CARGO_MAKE_PROJECT_NAME}"
CARGO_MAKE_ADDITIONAL_BINARY_EXECUTABLE_NAME = ""
CARGO_MAKE_FORMAT_TOML_FILES = "**/*.toml"
CARGO_MAKE_OPENSSL_VERSION_NO_PATCH = "1.0.2"
CARGO_MAKE_OPENSSL_VERSION_PATCH = "l"
CARGO_MAKE_OPENSSL_VERSION = "${CARGO_MAKE_OPENSSL_VERSION_NO_PATCH}${CARGO_MAKE_OPENSSL_VERSION_PATCH}"
CARGO_MAKE_OPENSSL_DOWNLOAD_URL_PREFIX = "https://www.openssl.org/source"
CARGO_MAKE_OPENSSL_DOWNLOAD_URL = "${CARGO_MAKE_OPENSSL_DOWNLOAD_URL_PREFIX}/old/${CARGO_MAKE_OPENSSL_VERSION_NO_PATCH}/openssl-${CARGO_MAKE_OPENSSL_VERSION}.tar.gz"
[env.none-thread-safe-tests]
RUST_TEST_THREADS = "1"
[env.multi-phase-tests]
CARGO_MAKE_TEST_USE_MULTI_TEST_PHASES = true
[env.docs-all-modification-tasks]
CARGO_MAKE_DOCS_README_SET_CRATE_VERSION = true
CARGO_MAKE_DOCS_README_INCLUDE_FILES = true
[env.publish-allow-dirty]
CARGO_MAKE_CARGO_PUBLISH_FLAGS = "${CARGO_MAKE_CARGO_PUBLISH_ALLOW_DIRTY}"
[env.publish-pre-cleanup]
CARGO_MAKE_CARGO_PUBLISH_DELETE_LOCK_FILE = true
[env.ci-coverage-tasks]
CARGO_MAKE_RUN_CODECOV = true
[env.ci-static-code-analysis-tasks]
CARGO_MAKE_RUN_CLIPPY = true
CARGO_MAKE_CLIPPY_ALLOW_FAIL = "${CARGO_MAKE_CI}"
[env.ci-all-build-tasks]
CARGO_MAKE_BUILD_BENCH = true
CARGO_MAKE_BUILD_EXAMPLES = true
CARGO_MAKE_CHECK_OUTDATED = true
[env.all-default-tasks]
CARGO_MAKE_RUN_TOML_FORMAT = true
[tasks.empty]
description = "Empty Task"
category = "Tools"
[tasks.wait]
description = "Waits based on the CARGO_MAKE_WAIT_MILLISECONDS environment variable value"
category = "Tools"
condition = { env_set = ["CARGO_MAKE_WAIT_MILLISECONDS"] }
script = '''
#!@duckscript
sleep ${CARGO_MAKE_WAIT_MILLISECONDS}
'''
[tasks.default]
description = "Default task points to the development testing flow"
category = "Development"
alias = "dev-test-flow"
[tasks.watch-flow]
description = "Watches for any file change and if any change is detected, it will invoke the default flow."
category = "Development"
watch = true
run_task = "default"
[tasks.init]
description = "By default this task is invoked at the start of every cargo-make run."
category = "Hooks"
[tasks.end]
description = "By default this task is invoked at the end of every cargo-make run."
category = "Hooks"
[tasks.print-cargo-make-env]
category = "Tools"
script = '''
#!@duckscript
echo "*************************************"
echo "Cargo Make:"
echo " Task: ${CARGO_MAKE_TASK}"
echo " Task Arguments: ${CARGO_MAKE_TASK_ARGS}"
echo " Command: ${CARGO_MAKE_COMMAND}"
echo " Working Directory: ${CARGO_MAKE_WORKING_DIRECTORY}"
echo " Profile: ${CARGO_MAKE_PROFILE}"
echo " Additional Profiles: ${CARGO_MAKE_ADDITIONAL_PROFILES}"
echo "*************************************"
'''
[tasks.print-project-env]
category = "Tools"
script = '''
#!@duckscript
echo "*************************************"
echo "Project:"
echo " Name: ${CARGO_MAKE_PROJECT_NAME}"
echo " Version: ${CARGO_MAKE_PROJECT_VERSION}"
echo " Version Member: ${CARGO_MAKE_PROJECT_VERSION_MEMBER}"
echo "*************************************"
'''
[tasks.print-ci-env]
category = "Tools"
script = '''
#!@duckscript
echo "*************************************"
echo "CI:"
echo " CI: ${CARGO_MAKE_CI}"
echo " PR: ${CARGO_MAKE_PR}"
echo " Branch Name: ${CARGO_MAKE_CI_BRANCH_NAME}"
echo " CI Vendor: ${CARGO_MAKE_CI_VENDOR}"
echo "*************************************"
'''
[tasks.print-git-env]
category = "Tools"
condition = { env_set = ["CARGO_MAKE_GIT_BRANCH"] }
script = '''
#!@duckscript
echo "*************************************"
echo "Git:"
echo " Branch: ${CARGO_MAKE_GIT_BRANCH}"
echo " User: ${CARGO_MAKE_GIT_USER_NAME}"
echo " Email: ${CARGO_MAKE_GIT_USER_EMAIL}"
echo " Commit Hash: ${CARGO_MAKE_GIT_HEAD_LAST_COMMIT_HASH}"
echo " Commit Hash Prefix: ${CARGO_MAKE_GIT_HEAD_LAST_COMMIT_HASH_PREFIX}"
echo "*************************************"
'''
[tasks.print-rust-env]
category = "Tools"
condition = { env_set = ["CARGO_MAKE_RUST_CHANNEL"] }
script = '''
#!@duckscript
echo "*************************************"
echo "Rust:"
echo " Version: ${CARGO_MAKE_RUST_VERSION}"
echo " Channel: ${CARGO_MAKE_RUST_CHANNEL}"
echo " Target Arch: ${CARGO_MAKE_RUST_TARGET_ARCH}"
echo " Target Env: ${CARGO_MAKE_RUST_TARGET_ENV}"
echo " Target OS: ${CARGO_MAKE_RUST_TARGET_OS}"
echo " Pointer Width: ${CARGO_MAKE_RUST_TARGET_POINTER_WIDTH}"
echo " Target Vendor: ${CARGO_MAKE_RUST_TARGET_VENDOR}"
echo " Target Triple: ${CARGO_MAKE_RUST_TARGET_TRIPLE}"
echo " Target Directory: ${CARGO_MAKE_CRATE_TARGET_DIRECTORY}"
echo " Custom Triple Target Directory: ${CARGO_MAKE_CRATE_CUSTOM_TRIPLE_TARGET_DIRECTORY}"
echo "*************************************"
'''
[tasks.print-cargo-env]
category = "Tools"
condition = { env_set = ["CARGO_MAKE_CARGO_HOME"] }
script = '''
#!@duckscript
echo "*************************************"
echo "Cargo:"
echo " Home: ${CARGO_MAKE_CARGO_HOME}"
echo " Profile: ${CARGO_MAKE_CARGO_PROFILE}"
echo "*************************************"
'''
[tasks.print-crate-env]
category = "Tools"
condition = { env_set = ["CARGO_MAKE_CRATE_NAME"] }
script = '''
#!@duckscript
echo "*************************************"
echo "Crate:"
echo " Name: ${CARGO_MAKE_CRATE_NAME}"
echo " Version: ${CARGO_MAKE_CRATE_VERSION}"
echo " Description: ${CARGO_MAKE_CRATE_DESCRIPTION}"
echo " License: ${CARGO_MAKE_CRATE_LICENSE}"
echo " Documentation: ${CARGO_MAKE_CRATE_DOCUMENTATION}"
echo " Homepage: ${CARGO_MAKE_CRATE_HOMEPAGE}"
echo " Repository: ${CARGO_MAKE_CRATE_REPOSITORY}"
echo " Workspace: ${CARGO_MAKE_CRATE_IS_WORKSPACE}"
echo " Workspace Working Directory: ${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}"
echo " Workspace Members: ${CARGO_MAKE_CRATE_WORKSPACE_MEMBERS}"
echo " Has Dependencies: ${CARGO_MAKE_CRATE_HAS_DEPENDENCIES}"
echo "*************************************"
'''
[tasks.print-duckscript-env]
category = "Tools"
script = '''
#!@duckscript
echo "*************************************"
echo "Duckscript:"
echo " Runtime: ${CARGO_MAKE_DUCKSCRIPT_VERSION}"
echo " SDK: ${CARGO_MAKE_DUCKSCRIPT_SDK_VERSION}"
echo "*************************************"
'''
[tasks.pre-print-env]
category = "Tools"
[tasks.post-print-env]
category = "Tools"
[tasks.print-env-flow]
category = "Tools"
dependencies = [
"pre-print-env",
"print-cargo-make-env",
"print-project-env",
"print-ci-env",
"print-git-env",
"print-rust-env",
"print-cargo-env",
"print-crate-env",
"print-duckscript-env",
"post-print-env",
]
[tasks.diff-files]
description = "Run diff on two provided files."
category = "Tools"
alias = "git-diff-files"
[tasks.setup-sudo-env]
description = "Sets the sudo enable/disable environment variables."
category = "Tools"
script = '''
#!@duckscript
# disable sudo if the env is defined
enable_sudo = not is_defined CARGO_MAKE_SUDO_DISABLE
# always allow sudo in CI
if equals "${CARGO_MAKE_CI}" true
enable_sudo = set true
end
fn <scope> is_ci_vendor
current_vendor = get_env CARGO_MAKE_CI_VENDOR
is_vendor = equals "${current_vendor}" "${1}"
return ${is_vendor}
end
fn <scope> is_ci_requires_sudo
if is_ci_vendor Drone
return false
end
# for all other vendors or in case we are not running inside a CI environment
return true
end
set_env CARGO_MAKE_SUDO_ENABLED ${enable_sudo}
set_env CARGO_MAKE_SUDO_COMMAND ""
if equals ${enable_sudo} true
if is_ci_requires_sudo
set_env CARGO_MAKE_SUDO_COMMAND sudo
end
end
echo sudo enabled: ${enable_sudo}
'''