Skip to content

Commit

Permalink
fix: disable 1password on non-windows
Browse files Browse the repository at this point in the history
Fixes #3050
  • Loading branch information
jdx committed Nov 16, 2024
1 parent 235000c commit 6c584e0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,11 +170,11 @@ jobs:
- run: |
cargo build
Add-Content $env:GITHUB_PATH "$env:GITHUB_WORKSPACE\target\debug"
- run: cargo test
continue-on-error: true
- run: mise install
- run: mise test-tool --all
continue-on-error: true
- run: cargo test
continue-on-error: true
windows-e2e:
runs-on: windows-latest
timeout-minutes: 30
Expand Down
2 changes: 1 addition & 1 deletion docs/registry.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ editLink: false

| Short | Full |
| ----------- | --------------- |
| 1password-cli | [aqua:1password/cli](https://github.com/1password/cli) [asdf:NeoHsu/asdf-1password-cli](https://github.com/NeoHsu/asdf-1password-cli) |
| 1password-cli | [asdf:NeoHsu/asdf-1password-cli](https://github.com/NeoHsu/asdf-1password-cli) [aqua:1password/cli](https://github.com/1password/cli) |
| aapt2 | [asdf:ronnnnn/asdf-aapt2](https://github.com/ronnnnn/asdf-aapt2) |
| act | [aqua:nektos/act](https://github.com/nektos/act) [ubi:nektos/act](https://github.com/nektos/act) [asdf:gr1m0h/asdf-act](https://github.com/gr1m0h/asdf-act) |
| action-validator | [aqua:mpalmer/action-validator](https://github.com/mpalmer/action-validator) [ubi:mpalmer/action-validator](https://github.com/mpalmer/action-validator) [asdf:mpalmer/action-validator](https://github.com/mpalmer/action-validator) |
Expand Down
3 changes: 2 additions & 1 deletion registry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
# or a backend may be disabled via MISE_DISABLE_BACKENDS=ubi

[tools]
1password-cli.backends = ["aqua:1password/cli", "asdf:NeoHsu/asdf-1password-cli"]
# ls-remote not available for aqua
1password-cli.backends = ["asdf:NeoHsu/asdf-1password-cli", "aqua:1password/cli"]
1password-cli.test = ["op --version", "{{version}}"]
aapt2.backends = ["asdf:ronnnnn/asdf-aapt2"]
aapt2.test = ["aapt2 version", "Android Asset Packaging Tool (aapt)"]
Expand Down
2 changes: 2 additions & 0 deletions src/registry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use crate::config::SETTINGS;
use itertools::Itertools;
use once_cell::sync::Lazy;
use std::collections::{BTreeMap, HashMap, HashSet};
use std::env::consts::OS;
use std::iter::Iterator;
use strum::IntoEnumIterator;
use url::Url;
Expand Down Expand Up @@ -36,6 +37,7 @@ pub static REGISTRY: Lazy<BTreeMap<&str, RegistryTool>> = Lazy::new(|| {

let mut registry: BTreeMap<&str, RegistryTool> = FULL_REGISTRY
.iter()
.filter(|(_, tr)| tr.os.is_empty() || tr.os.contains(&OS))
.map(|(short, tr)| {
let mut tr = tr.clone();
tr.backends = tr
Expand Down

0 comments on commit 6c584e0

Please sign in to comment.