Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow fetching lints from registries #87

Closed
Tracked by #60
xFrednet opened this issue Jan 11, 2023 · 1 comment · Fixed by #168
Closed
Tracked by #60

Allow fetching lints from registries #87

xFrednet opened this issue Jan 11, 2023 · 1 comment · Fixed by #168
Assignees
Labels
A-marker-cargo Area: All things connected to `cargo_marker` C-enhancement Category: New feature or request

Comments

@xFrednet
Copy link
Member

#81 adds support to specify lint crates in Cargo.toml files. For now only local paths and git repositories are allowed. In the future, registries like crates.io should also be allowed.

This issue is currently blocked until the first version of marker_api has been released to crates.io, as we're otherwise not able to upload a lint crate to crates.io. It might be possible to work around this restriction by defining a git dependency. 🤔 I'll still mark it as blocked for now.

@xFrednet xFrednet added C-enhancement Category: New feature or request S-blocked Status: Blocked A-driver Area: Driver or something related to the internal working of a driver. labels Jan 11, 2023
@xFrednet
Copy link
Member Author

It might be worth to check out the crates_io crate. It apparently implements a part of talking to a registry or at least crates.io. I haven't looked into it further though.

bors bot added a commit that referenced this issue May 7, 2023
126: cargo-marker: add git support r=xFrednet a=Niki4tap

Its been a while since I've worked on this, but I've finally took the time to finish it.

This PR adds git support to marker so this now works:
```toml
[workspace.metadata.marker.lints]
marker_lints = { git = "https://github.com/rust-marker/marker" }
```

It makes use of [`cargo_fetch`](https://github.com/Niki4tap/cargo_fetch) library which I made for this specific use-case, which is essentially just a thin wrapper around `cargo` library (so the builds are now way slower :p).

I'll try to maintain the library to my best capacity, and prioritize marker's goals whenever needed.

Addition of the library also technically allows for any kind of package to be downloaded, so this also *technically* supports registries, though this PR does not implement it, because this is blocked on marker APIs being released.

---

In total this checks out... *\*looks up the issue\**... one task from #81!
But also *technically* closes <!-- do not close this issue github please --> #87 whenever APIs are published.

review side note: most changes are from `Cargo.lock`

Co-authored-by: Niki4tap <rombiklol2@gmail.com>
bors bot added a commit that referenced this issue May 7, 2023
126: cargo-marker: add git support r=xFrednet a=Niki4tap

Its been a while since I've worked on this, but I've finally took the time to finish it.

This PR adds git support to marker so this now works:
```toml
[workspace.metadata.marker.lints]
marker_lints = { git = "https://github.com/rust-marker/marker" }
```

It makes use of [`cargo_fetch`](https://github.com/Niki4tap/cargo_fetch) library which I made for this specific use-case, which is essentially just a thin wrapper around `cargo` library (so the builds are now way slower :p).

I'll try to maintain the library to my best capacity, and prioritize marker's goals whenever needed.

Addition of the library also technically allows for any kind of package to be downloaded, so this also *technically* supports registries, though this PR does not implement it, because this is blocked on marker APIs being released.

---

In total this checks out... *\*looks up the issue\**... one task from #81!
But also *technically* closes <!-- do not close this issue github please --> #87 whenever APIs are published.

review side note: most changes are from `Cargo.lock`

Co-authored-by: Niki4tap <rombiklol2@gmail.com>
@xFrednet xFrednet added A-marker-cargo Area: All things connected to `cargo_marker` and removed A-driver Area: Driver or something related to the internal working of a driver. labels Jul 11, 2023
@xFrednet xFrednet self-assigned this Jul 11, 2023
@xFrednet xFrednet removed the S-blocked Status: Blocked label Jul 11, 2023
@bors bors bot closed this as completed in bc5848e Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-marker-cargo Area: All things connected to `cargo_marker` C-enhancement Category: New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant