Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelzw committed Jun 5, 2024
1 parent feabcc5 commit b492f5b
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 11 deletions.
9 changes: 8 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,20 @@ repos:
language: system
types: [text]
require_serial: true
# cargo fmt
# cargo fmt and clippy
- id: cargo-fmt
name: cargo-fmt
entry: pixi run -e default cargo fmt --
language: system
require_serial: false
types: [rust]
- id: cargo-clippy
name: cargo-clippy
entry: pixi run -e default cargo clippy --all-targets --all-features --workspace -- -D warnings
pass_filenames: false
language: system
require_serial: false
types: [rust]
# taplo
- id: taplo
name: taplo
Expand Down
2 changes: 1 addition & 1 deletion pixi.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ clippy = "cargo clippy"
rust = "1.77.2"
openssl = "3.*"

[activation]
[target.linux.activation]
scripts = ["activate-openssl.sh"]
# TODO: once TODO is fixed, replace with
# [activation.env]
Expand Down
19 changes: 10 additions & 9 deletions tests/integration_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,14 @@ fn options(
#[fixture]
fn required_fs_objects() -> Vec<&'static str> {
let mut required_fs_objects = vec!["conda-meta/history", "include", "share"];
let openssl_required_file = match Platform::current() {
Platform::Linux64 => "conda-meta/openssl-3.3.0-h4ab18f5_3.json",
Platform::LinuxAarch64 => "conda-meta/openssl-3.3.1-h68df207_0.json",
Platform::OsxArm64 => "conda-meta/openssl-3.3.0-hfb2fe0b_3.json",
Platform::Osx64 => "conda-meta/openssl-3.3.1-h87427d6_0.json",
Platform::Win64 => "conda-meta/openssl-3.3.0-h2466b09_3.json",
_ => panic!("Unsupported platform"),
};
if cfg!(windows) {
required_fs_objects.extend(vec![
"DLLs",
Expand All @@ -62,17 +70,10 @@ fn required_fs_objects() -> Vec<&'static str> {
"Scripts",
"Tools",
"python.exe",
"conda-meta/openssl-3.3.0-h2466b09_3.json",
openssl_required_file,
])
} else {
required_fs_objects.extend(vec!["bin/python", "lib", "man", "ssl"]);
if cfg!(target_os = "macos") {
// osx-arm64
required_fs_objects.push("conda-meta/openssl-3.3.0-hfb2fe0b_3.json");
} else {
// linux-64
required_fs_objects.push("conda-meta/openssl-3.3.0-h4ab18f5_3.json");
}
required_fs_objects.extend(vec!["bin/python", "lib", "man", "ssl", openssl_required_file]);
}
required_fs_objects
}
Expand Down

0 comments on commit b492f5b

Please sign in to comment.