Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Reduce scope of regex in PowerShellExeFinder#5228

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
tsmarvin wants to merge1 commit intoPowerShell:main
base:main
Choose a base branch
Loading
fromtsmarvin:tsmarvin/make_regex_accurate_to_comments

Conversation

tsmarvin
Copy link

PR Summary

  • Update integer checking regex to match implied expectations from related comments.
    • While reading through the comments associated with the IntRegex value it is implied that we're only looking for single digit integer folders. This update formally matches that implied expectation.

PR Checklist

Note: Tick the boxes below that apply to this pull request by putting anx between the square brackets.
Please mark anything not applicable to this PRNA.

  • PR has a meaningful title
  • Summarized changes
  • PR has tests
  • This PR is ready to merge and is not work in progress
    • If the PR is work in progress, please add the prefixWIP: to the beginning of the title and remove the prefix when the PR is ready

@CopilotCopilotAI review requested due to automatic review settingsJune 29, 2025 12:16
Copy link

@CopilotCopilotAI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR updates the integer checking regex in the PowerShellExeFinder to enforce a stricter validation by matching exactly a single digit rather than one or more digits.

  • Change the IntRegex from matching one or more digits (/^\d+$/) to exactly one digit (/^\d$/).
  • This adjustment aligns the implementation with the implied expectation from related comments regarding folder naming.
Comments suppressed due to low confidence (1)

src/platform.ts:81

  • Consider updating the associated comment to clearly state that the regex now only supports single digit folder names, ensuring that the documentation is consistent with the updated regex behavior.
    private static IntRegex = /^\d$/;

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

Copilot code reviewCopilotCopilot left review comments

At least 1 approving review is required to merge this pull request.

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

1 participant
@tsmarvin

[8]ページ先頭

©2009-2025 Movatter.jp