-
Notifications
You must be signed in to change notification settings - Fork 9
Refactor testCloneRepository function and update .gitignore #85
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
Changes from 13 commits
18c57de
209fe0a
6aa90ce
90fee20
7eb2f24
b1c5d9e
8a0a2a1
ce98ee6
448311b
366d42e
6754885
5318018
f8ae2ff
eccd922
88b1597
07a50d6
87a489c
5f9d8fc
6d68173
1a8c8b7
06a9732
46be12b
9d43810
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,3 +17,4 @@ jobs: | |
| with: | ||
| python-version: '3.12' | ||
| - run: make test | ||
| - run: make test_with_git | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,3 +2,5 @@ dist | |
| __pycache__ | ||
| vendor | ||
| .history/ | ||
| .idea/ | ||
| .devcontainer/ | ||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -1,5 +1,9 @@ | ||||||||||||||||||||
| #!/bin/sh | ||||||||||||||||||||
|
|
||||||||||||||||||||
| git config --global user.email "you@example.com" | ||||||||||||||||||||
| git config --global user.name "Your Name" | ||||||||||||||||||||
|
||||||||||||||||||||
| git config --global user.email "you@example.com" | |
| git config --global user.name "Your Name" | |
| #!/usr/bin/env bash | |
| # Apply email/name only for this invocation, without touching ~/.gitconfig | |
| exec git \ | |
| -c user.email="you@example.com" \ | |
| -c user.name="Your Name" \ | |
| "$@" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Fix error handling in deferred function and use Go's file operations
The deferred function has several issues:
Note: The
os.RemoveAll(tmpGitDir)is already called in the earlier defer statement on line 109, so it's removed here to avoid duplication.🧰 Tools
🪛 golangci-lint (1.64.8)
197-197: Error return value is not checked
(errcheck)
🤖 Prompt for AI Agents