Skip to content

Update dependencies and consolidate crate metadata into workspace Cargo.toml#129

Merged
azriel91 merged 8 commits intomainfrom
maintenance/128/update-and-use-workspace-dependencies
Jun 5, 2023
Merged

Update dependencies and consolidate crate metadata into workspace Cargo.toml#129
azriel91 merged 8 commits intomainfrom
maintenance/128/update-and-use-workspace-dependencies

Conversation

@azriel91
Copy link
Copy Markdown
Owner

@azriel91 azriel91 commented Jun 4, 2023

Closes #128.

See linked issue for scripts used to do this work.

azriel91 added 3 commits June 3, 2023 21:13
Used the following script:

```bash
\# Replace package fields
fd -Ftf Cargo.toml --exclude examples -x sd '^version = "0\.0\.10"$' 'version.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd -s 'authors = ["Azriel Hoh <azriel91@gmail.com>"]' 'authors.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd -s 'edition = "2021"' 'edition.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd -s 'repository = "https://github.com/azriel91/peace"' 'repository.workspace = true
homepage.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd '^readme = .+' 'readme.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd '^categories = .+' 'categories.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd '^keywords = .+' 'keywords.workspace = true'
fd -Ftf Cargo.toml --exclude examples -x sd '^license = .+' 'license.workspace = true'

\# Move description and documentation fields under `name`
fd -Ftf Cargo.toml --exclude examples -x bash -c "
cat << EOF | ed -sE {}
/^name/
ka
/^description/
m'a
ka
/^documentation/
m'a
w
EOF
"
```
@codecov
Copy link
Copy Markdown

codecov bot commented Jun 4, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (b72e18e) 90.83% compared to head (1a9e060) 90.83%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #129   +/-   ##
=======================================
  Coverage   90.83%   90.83%           
=======================================
  Files         335      334    -1     
  Lines       30403    30403           
=======================================
  Hits        27618    27618           
  Misses       2785     2785           

see 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

azriel91 added 5 commits June 5, 2023 09:05
Script used:

```bash
\# Replace `peace` dependencies in `Cargo.toml`s
fd -Ftf Cargo.toml --exclude examples -x \
  sd '\{ path = "([a-z_/.]+)", version = "0\.0\.10"([^}]+)\}' '{ workspace = true$2}'
fd -Ftf Cargo.toml --exclude examples -x \
  sd '\{ version = "0\.0\.10", path = "([a-z_/.]+)"([^}]+)\}' '{ workspace = true$2}'
\# Replace simple version dependencies in `Cargo.toml`s
fd -Ftf Cargo.toml --exclude examples -x \
  sd '^([a-z-_0-9]+) = ("[0-9.]+")'    '$1 = { workspace = true }'
\# Replace complex version dependencies in `Cargo.toml`s
fd -Ftf Cargo.toml --exclude examples -x \
  sd '^([a-z-_0-9]+) = \{ version = "[0-9.]+"([^}]+)\}' '$1 = { workspace = true$2}'
\# Put back version and edition values
fd -Ftf Cargo.toml --exclude examples -x sd -s 'edition = { workspace = true }' 'edition = "2021"'
sd -s 'version = { workspace = true }' 'version = "0.0.10"' Cargo.toml
```
@azriel91 azriel91 marked this pull request as ready for review June 4, 2023 23:45
@azriel91 azriel91 merged commit 85cb088 into main Jun 5, 2023
@azriel91 azriel91 deleted the maintenance/128/update-and-use-workspace-dependencies branch June 5, 2023 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update dependencies and use workspace dependencies

1 participant