Skip to content

Commit

Permalink
test rb
Browse files Browse the repository at this point in the history
  • Loading branch information
datpmt committed Dec 5, 2024
1 parent 02e944e commit 0dc7972
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions test/example.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@ def factorial(n):
if age >= 18:
print("You are elligible for an adult privilege.") # typo
print("You are elligible for an adult privilege.") # typo
print("You are elligible for an adult privilege.") # typo
else:
print("You are underage, so no adult privileges for you.")
2 changes: 1 addition & 1 deletion typocop.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def initialize(path, line, incorrect_word, correct_word)

puts "body: #{body}"
repo_remote_url = repo.remotes.first.url
match = %r{(?:https?://)?(?:www\.)?github\.com[/:](?<repo_name>[^/]+/[^/]+)(?:\.git)?\z}.match(repo_remote_url)
match = %r{(?:https?://)?(?:www\.)?github\.com[/:](?<repo_name>.*?)(?:\.git)?\z}.match(repo_remote_url)
repo_name = match[:repo_name]
create_comment(client, repo_name, body, repo.head.target_id, typo.path, typo.line)
end
Expand Down

0 comments on commit 0dc7972

Please sign in to comment.