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

patch: add paths to error messages #941

Merged
merged 1 commit into from
Feb 6, 2025

Conversation

mknos
Copy link
Contributor

@mknos mknos commented Feb 6, 2025

  • Improve error messages if open() fails
  • INFILE was listed instead of the original file path
  • OUTFILE was listed instead of the path provided to -o, e.g. if I specify an invalid argument
  • Style: switch filehandles to my-variables
  • Style: add more quotes for hash keys
%perl diff env.c env2.c | perl tee env.diff
61d60
< 	setprogname(*argv);
79d77
< 		case '?':
%perl patch -o /G/G env.c env.diff 
Hmm...  Looks like a normal diff to me...
Patching file env.c using Plan B...
Couldn't open OUTFILE: No such file or directory
Skipping patch...

% chmod 0 env.c
%perl patch -o NEW_ENV env.c env.diff
Hmm...  Looks like a normal diff to me...
Patching file env.c using Plan B...
Couldn't open INFILE: Permission denied
Skipping patch...

* Improve error messages if open() fails
* INFILE was listed instead of the original file path
* OUTFILE was listed instead of the path provided to -o, e.g. if I specify an invalid argument
* Style: switch filehandles to my-variables
* Style: add more quotes for hash keys
@github-actions github-actions bot added Type: enhancement improve a feature that already exists Priority: low get to this whenever Program: patch The patch program labels Feb 6, 2025
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 6, 2025 02:48 — with GitHub Actions Inactive
@coveralls
Copy link

coveralls commented Feb 6, 2025

Pull Request Test Coverage Report for Build 13170810561

Details

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

Totals Coverage Status
Change from base Build 13163530104: -0.7%
Covered Lines: 353
Relevant Lines: 481

💛 - Coveralls

@coveralls
Copy link

coveralls commented Feb 6, 2025

Pull Request Test Coverage Report for Build 13170810558

Details

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

Totals Coverage Status
Change from base Build 13163530104: -0.7%
Covered Lines: 353
Relevant Lines: 481

💛 - Coveralls

@briandfoy briandfoy self-assigned this Feb 6, 2025
@briandfoy briandfoy merged commit 5d45719 into briandfoy:master Feb 6, 2025
21 of 23 checks passed
@briandfoy
Copy link
Owner

nice change, thanks

@briandfoy briandfoy added Status: accepted The fix is accepted and removed Priority: low get to this whenever labels Feb 6, 2025
@briandfoy
Copy link
Owner

changes: add offending filenames to error messages about files

@briandfoy briandfoy added Status: released there is a new release with this fix and removed Status: accepted The fix is accepted labels Feb 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Program: patch The patch 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