15 lines
430 B
Bash
Executable file
15 lines
430 B
Bash
Executable file
#!/bin/bash
|
|
|
|
# Define the output file name
|
|
OUTPUT_FILE="commit_history.txt"
|
|
|
|
# Check if the file already exists
|
|
if [ -f "$OUTPUT_FILE" ]; then
|
|
echo "File $OUTPUT_FILE already exists. Deleting it."
|
|
rm "$OUTPUT_FILE"
|
|
fi
|
|
|
|
# Create a new commit history file with detailed information
|
|
git log --pretty=format:"%H - %an <%ae>, %ar, %ad : %s" --date=iso > "$OUTPUT_FILE"
|
|
|
|
echo "Commit history has been exported to $OUTPUT_FILE."
|