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 EOLs and Repo Settings #3

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

tajmone
Copy link

@tajmone tajmone commented Nov 3, 2019

Fix EOLs

This commit fixes some text files being indexed with CRLF or mixed EOLs, which might create problems on non-Windows OSs.

  • Add .gitattributes with optimal EOL normalization settings for Nim projects (from: tajmone/nim-repository-template) and cover all file extensions used in this repository.
  • Enforce the new EOL normalization rules via git add --renormalize, thus fixing those files that were indexed with CRLF or mixed EOLs.

EditorConfig

Add .editorconfig settings to enforce consistent code styles across various editors and IDEs. Most modern editors should pickup those settings from the repository, either natively or via a plugin.

Fix files that didn't pass EditoConfig validation via the EClint tool:

  • Fix indentations (in a few places).
  • Remove trailing whitespace (many occurrences).
  • Insert newline at file end.

NOTE — The .editorconfig file could also be used to validate commits and pull requests via Travis CI using EClint by adding a .travis.yml file:

dist: trusty
git:
  depth: false
install:
  - npm install -g eclint
script:
  - eclint check

Improve Git Exclusion Patterns

Reorganize .gitignore and add new exclusions patterns for better cross-platform coverage, including some OS-specific autogenerated system files.

This commit fixes some text files being indexed with CRLF or mixed EOLs,
which might create problems on non-Windows OSs.

* Add `.gitattributes` with optimal EOL normalization settings for Nim
  projects (from_ tajmone/nim-repository-template) and cover all file
  extensions used in this repository.
* Enforce the new EOL normalization rules via `git add --renormalize`,
  thus fixing those files that were indexed with CRLF or mixed EOLs.
Add `.editorconfig` settings to enforce consistent code styles across
various editors and IDEs.

Fix files that didn't pass EditoConfig validation via EClint:

* Fix indentations (in few places).
* Remove trailing whitespace (many occurrences).
* Insert newline at file end.
Reorganize and add new exclusions patterns for better cross-platform
coverage, including some OS-specific autogenerated system files.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant