Skip to content

Commit

Permalink
fix: error with removeAllNetrcEntries
Browse files Browse the repository at this point in the history
  • Loading branch information
alvarosabu committed Oct 29, 2024
1 parent ef9efb2 commit 7652466
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/creds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -227,13 +227,13 @@ export const removeNetrcEntry = async (
}
}
catch (error: unknown) {
throw new Error(`Error removing entry for machine ${machineName} from .netrc file: ${(error as Error).message}`)
handleFileSystemError('write', error as NodeJS.ErrnoException)
}
}

export function removeAllNetrcEntries(filePath = getNetrcFilePath()) {
try {
writeFile(filePath, '', {
return writeFile(filePath, '', {
mode: 0o600, // Set file permissions
})
}
Expand Down

0 comments on commit 7652466

Please sign in to comment.