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

doc: Use the conventional comment syntax #174

Merged
merged 6 commits into from
Oct 9, 2024

Conversation

Muhammad-Owais-Warsi
Copy link
Contributor

@Muhammad-Owais-Warsi Muhammad-Owais-Warsi commented Oct 6, 2024

Description

Changed the comments syntax from /* */ to /// in the codebase.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (no code change)
  • Refactor (refactoring production code)
  • Other

Checklist:

  • My code follows the code style of this project.
  • I have updated the documentation and changelog accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • Rustfmt and Rust-clippy passed.

Copy link
Owner

@orhun orhun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

src/util.rs Outdated Show resolved Hide resolved
src/app.rs Outdated
Comment on lines 51 to 54

/// Return iterator of the available scroll directions.


Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also remove these extra newlines?

src/app.rs Outdated
Comment on lines 106 to 109

/// Check if input mode is set.


Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary newlines

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just pushed , please check , hope I have not missed anything now 😅

@orhun
Copy link
Owner

orhun commented Oct 8, 2024

CI is failing due to invalid doc comments: https://github.com/orhun/kmon/actions/runs/11220108587/job/31215613896?pr=174

See https://doc.rust-lang.org/reference/comments.html

I guess we are still not ready :)

@Muhammad-Owais-Warsi
Copy link
Contributor Author

CI is failing due to invalid doc comments: https://github.com/orhun/kmon/actions/runs/11220108587/job/31215613896?pr=174

See https://doc.rust-lang.org/reference/comments.html

I guess we are still not ready :)

So sorry, actually it is my first time trying rust. I think I have used /// inside the functions , but I think it's not the right way. I'll look into that. Thanks :)

@orhun
Copy link
Owner

orhun commented Oct 8, 2024

No worries :)

@Muhammad-Owais-Warsi
Copy link
Contributor Author

Muhammad-Owais-Warsi commented Oct 8, 2024

CI is failing due to invalid doc comments: https://github.com/orhun/kmon/actions/runs/11220108587/job/31215613896?pr=174
See https://doc.rust-lang.org/reference/comments.html
I guess we are still not ready :)

So sorry, actually it is my first time trying rust. I think I have used /// inside the functions , but I think it's not the right way. I'll look into that. Thanks :)

As per the docs, we have to use // for the comments inside the functions.

@Muhammad-Owais-Warsi
Copy link
Contributor Author

Muhammad-Owais-Warsi commented Oct 8, 2024

  1. On cargo build i get this

cargo build Compiling kmon v1.6.5 (/home/owais/Documents/kmon) Finished dev profile [unoptimized + debuginfo] target(s) in 4.33s

  1. On cargo test

Screenshot from 2024-10-08 21-54-19

@Muhammad-Owais-Warsi
Copy link
Contributor Author

  1. On cargo build i get this

cargo build Compiling kmon v1.6.5 (/home/owais/Documents/kmon) Finished dev profile [unoptimized + debuginfo] target(s) in 4.33s

  1. On cargo test

Screenshot from 2024-10-08 21-54-19

So should I push these changes.

@orhun
Copy link
Owner

orhun commented Oct 8, 2024

Yup, please. Those look good

@Muhammad-Owais-Warsi
Copy link
Contributor Author

Yup, please. Those look good

Done 👍

@orhun
Copy link
Owner

orhun commented Oct 9, 2024

Can you run cargo fmt and push the changes?

@Muhammad-Owais-Warsi
Copy link
Contributor Author

Can you run cargo fmt and push the changes?

Can you run cargo fmt and push the changes?

Yeah, sure.

Copy link
Owner

@orhun orhun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution (and bearing with me :D)

@orhun orhun changed the title change the comment syntax from /* */ to /// doc: Use the conventional comment syntax Oct 9, 2024
@orhun orhun merged commit 90b30cb into orhun:master Oct 9, 2024
3 of 5 checks passed
@Muhammad-Owais-Warsi
Copy link
Contributor Author

Thanks for your contribution (and bearing with me :D)
Thank you so much , it was great to contribute first time on rust project. You helped me lot. Thanks again

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.

2 participants