I tried the repair option first that didn't work, I'll post what happened at the very bottom in case you are curious or it's helpful to know if others have similar problems.
Then I tried the sequence of commands you provided to get the repos again, and it looks like it may have fixed it (for the moment at least, I guess I'll find out with the next update).
Many super thanks for your help, I really appreciated your helping.
Maybe I'll try to clone the SD card to have a backup in case the card is getting flakey, odd with the git command.
root@pihole:/etc/.pihole# sudo rm -rf /var/www/html/admin/
root@pihole:/etc/.pihole# sudo git clone https://github.com/pi-hole/web.git /var/www/html/admin
Cloning into '/var/www/html/admin'...
remote: Enumerating objects: 37117, done.
remote: Counting objects: 100% (1883/1883), done.
remote: Compressing objects: 100% (1146/1146), done.
remote: Total 37117 (delta 1035), reused 1516 (delta 737), pack-reused 35234
Receiving objects: 100% (37117/37117), 37.34 MiB | 7.77 MiB/s, done.
Resolving deltas: 100% (20240/20240), done.
root@pihole:/etc/.pihole# cd /
root@pihole:/# sudo rm -rf /etc/.pihole
root@pihole:/# sudo git clone https://github.com/pi-hole/pi-hole /etc/.pihole
Cloning into '/etc/.pihole'...
remote: Enumerating objects: 23730, done.
remote: Counting objects: 100% (620/620), done.
remote: Compressing objects: 100% (359/359), done.
remote: Total 23730 (delta 366), reused 479 (delta 256), pack-reused 23110
Receiving objects: 100% (23730/23730), 7.86 MiB | 5.66 MiB/s, done.
Resolving deltas: 100% (15175/15175), done.
root@pihole:/# pihole -up
[✓] Update local cache of available packages
[i] Existing PHP installation detected : PHP version 7.4.33
[✓] Checking for git
[✓] Checking for iproute2
[✓] Checking for dialog
[✓] Checking for ca-certificates
[i] Checking for updates...
[i] Pi-hole Core: up to date
[i] Web Interface: up to date
[i] FTL: up to date
[✓] Everything is up to date!
The unsuccessful repair attempt:
[i] Latest FTL Binary already installed (v5.25.2). Confirming Checksum...
[i] **Corruption detected...**
[✓] Downloading and Installing FTL
[✓] Installing scripts from /etc/.pihole
and then toward the end
[✓] Pi-hole blocking is enabled
**fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.**
**Use '--' to separate paths from revisions, like this:**
**'git <command> [<revision>...] -- [<file>...]'**
**fatal: Needed a single revision**
[i] The install log is located at: /etc/pihole/install.log
[✓] Update complete!
Current Pi-hole version is v5.18.2
Current web version is HEAD N/A
Current FTL version is v5.25.2
root@pihole:/etc/.pihole#
and pihole -up resulted in this
[i] Pi-hole Core: update available
fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
fatal: ambiguous argument '@{0}': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
fatal: no such branch: 'master'
Error: Remote revision could not be obtained, please contact Pi-hole Support
Additional debugging output:
On branch master
No commits yet
nothing to commit (create/copy files and use "git add" to track)
Thanks again!