chef / chef/os_release

No newline at end of files

Open Beginner friendly
#81 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
140
Forks
39
PR merge metrics
No merged PRs in 30d

Description

In the Unix/Linux/POSIX worlds, text files are by definition sequences LF-terminated lines. It follows that, in order to be valid, a non-empty text file must end with a newline (ASCII LF = \n).

This repository contains 30 files that fail to meet this criterion:

  • CODE_OF_CONDUCT.md
  • CONTRIBUTING.md
  • 28 os-release files (e.g. alma_*, fedora_{41..43}, gentoo_*)

The list is given by this command:

grep -Pzlvr --exclude-dir=.git '\x0a$' .

The markdown files not being proper text files may not be a big deal. However, the idea that some distros provide os-release files that are not valid text files is something I find hard to believe. I just spun up a Fedora 23 VM and sure, its /etc/os-release does end in \n, as expected, unlike the fedora_43 file in this repo.

Is there any known instance of a distro's /etc/os-release actually ending with an incomplete line? Or, as I suspect, are all these just failures to correctly copy the file into this repo? If so, would the maintainers accept a pull request fixing the situation?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running the issue's grep command to verify the listed files, then inspect CODE_OF_CONDUCT.md, CONTRIBUTING.md, and the named os-release files. Done means every non-empty text file ends with an ASCII LF newline; rerun the command to confirm it reports no files.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, shell
Domain
operating-systems
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
88/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.