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

Add explanations for Multi-Line Mode and regular expressions #83

Merged
merged 1 commit into from
Nov 30, 2024

Conversation

catatsuy
Copy link
Owner

This pull request includes updates to the README.md file to provide more detailed explanations and examples of using regular expressions with Multi-Line Mode in Purl. The most important changes include adding sections on Multi-Line Mode, special cases for empty lines, and practical use cases.

Enhancements to documentation:

  • Added a section on Regular Expressions and Multi-Line Mode in Purl, explaining how ^ and ` behave in this mode and why it is useful for line-based text processing.
  • Included a special case explanation for matching empty lines, highlighting the difference between lines with zero characters and lines containing only a newline character (\n).
  • Added examples of how to use Purl with Multi-Line Mode for common tasks such as filtering lines starting with a specific word, excluding empty lines, and replacing text on specific lines.
  • Clarified why the -exclude '^ command does not work for lines that only contain a newline character and provided the correct pattern to use instead.

@catatsuy catatsuy merged commit f45f6ea into main Nov 30, 2024
5 checks passed
@catatsuy catatsuy deleted the feature-multi-line-mode-and-regex-explained branch November 30, 2024 07:56
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.

1 participant