Page MenuHomeFreeBSD

Improve URL subsitution for custom crates whit CARGO_USE_GIT[HUB|LAB]
ClosedPublic

Authored by pizzamig on Apr 17 2021, 9:58 AM.

Details

Summary

While maintaing a rust application, I found a cargo.toml that specifies
the git URL with { git="https://..." }, cargo.mk expects a form like { git = "https://..." }.
This patch improve the regex making the spaces around the '=' optional

Test Plan

Build all the ports using the CARGO_USE_GIT[HUB|LAB]
List of origins found with

grep -Rl ^CARGO_USE_GIT...= | xargs dirname | sort

Diff Detail

Repository
R11 FreeBSD ports repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

pizzamig edited the summary of this revision. (Show Details)
pizzamig edited the test plan for this revision. (Show Details)
pizzamig edited reviewers, added: rust; removed: tobik.
pizzamig added a subscriber: tobik.

All ports that are affected by this are tagged with CARGO_USE_GITHUB and CARGO_USE_GITLAB. Assuming those ports all build (or alternatively if you have checked that the contents of Cargo.toml are the same before and after) then this is approved if you remove the superfluous [].

Mk/Uses/cargo.mk
240

Why do you wrap the space in []? [ starts a list of characters but there is only one char in there AFAICT.

Remove useless [ ], as suggested by tobik@

Please commit it. Thanks.

This revision was not accepted when it landed; it landed in state Needs Review.Apr 19 2021, 9:09 AM
This revision was automatically updated to reflect the committed changes.