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

dirname: support -- terminator #716

Merged
merged 3 commits into from
Aug 15, 2024
Merged

Conversation

mknos
Copy link
Contributor

@mknos mknos commented Aug 13, 2024

  • Standards document has an example where "--" option terminator is used.. $(dirname -- file) [1]
  • dirname is not a bash builtin on my Linux system
  • GNU and OpenBSD dirname support "--" so add it here too
  • GNU version supports multiple path arguments, but that does not follow the standard (this version already raised an error for multiple arguments)
  • test1: "perl dirname -- $(pwd)/A" --> single file argument after -- is valid
  • test2: "perl dirname a b" --> too many args
  • test3: "perl dirname --" --> not enough args
  • test4: "perl dirname -x -- -A" --> bad option error
  1. https://pubs.opengroup.org/onlinepubs/9699919799/utilities/dirname.html

* Standards document has an example where "--" option terminator is used.. $(dirname -- file) [1]
* dirname is not a bash builtin on my Linux system
* GNU and OpenBSD dirname support "--" so add it here too
* GNU version supports multiple path arguments, but that does not follow the standard (this version already raised an error for multiple arguments)

1. https://pubs.opengroup.org/onlinepubs/9699919799/utilities/dirname.html
@github-actions github-actions bot added Type: enhancement improve a feature that already exists Priority: low get to this whenever Program: dirname The dirname program labels Aug 13, 2024
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:57 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing August 13, 2024 08:58 — with GitHub Actions Inactive
@coveralls
Copy link

coveralls commented Aug 13, 2024

Pull Request Test Coverage Report for Build 10407089446

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 3 unchanged lines in 1 file lost coverage.
  • Overall coverage decreased (-0.7%) to 73.069%

Files with Coverage Reduction New Missed Lines %
bin/units 3 70.77%
Totals Coverage Status
Change from base Build 10350849541: -0.7%
Covered Lines: 350
Relevant Lines: 479

💛 - Coveralls

Copy link
Owner

@briandfoy briandfoy left a comment

Choose a reason for hiding this comment

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

Since you've completely replaced the program, you should get credit in the metadata

@briandfoy briandfoy self-assigned this Aug 13, 2024
@briandfoy briandfoy added the Status: changes requested adjust the pull request as noted in comments label Aug 13, 2024
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:27 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:27 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:30 — with GitHub Actions Inactive
@briandfoy briandfoy added Status: accepted The fix is accepted and removed Priority: low get to this whenever Status: changes requested adjust the pull request as noted in comments labels Aug 15, 2024
@briandfoy briandfoy merged commit 0f155b0 into briandfoy:master Aug 15, 2024
20 of 21 checks passed
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:31 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:31 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:31 — with GitHub Actions Inactive
@briandfoy briandfoy temporarily deployed to automated_testing August 15, 2024 16:32 — with GitHub Actions Inactive
@briandfoy briandfoy added Status: released there is a new release with this fix and removed Status: accepted The fix is accepted labels Sep 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Program: dirname The dirname program Status: released there is a new release with this fix Type: enhancement improve a feature that already exists
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants