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

fix: checks if files end with newline. closes #13 #15

Merged
merged 3 commits into from
Nov 30, 2023

Conversation

samdoghor
Copy link
Contributor

Fix: checks if files end with newline.

Changes:

alxcheck\main.py:

  • Added ".md" in line 26 to ensure files with .md extensions are checked for newline.

alxcheck\checks\general.py:

  • Modified the check_file_ends_with_new_line function. Files should open in binary mode instead of read text mode. Instead using read() to return a single string containing the entire content, readlines() was used to return list of lines.

Copy link
Owner

@Emmo00 Emmo00 left a comment

Choose a reason for hiding this comment

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

This nice, but can the check for newline in the README.md file be placed somewhere between line 12 and 14

@Emmo00
Copy link
Owner

Emmo00 commented Nov 30, 2023

Thanks for taking your time to contribute to this project @samdoghor

@samdoghor
Copy link
Contributor Author

This nice, but can the check for newline in the README.md file be placed somewhere between line 12 and 14

Alright. Will do so.

Copy link
Contributor Author

@samdoghor samdoghor left a comment

Choose a reason for hiding this comment

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

Change has been effected

Changes

  • Modified the main.py by moving the check for newline in README.md file to line 14.

@Emmo00 Emmo00 merged commit 93a4834 into Emmo00:main Nov 30, 2023
4 checks passed
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