Closed startergo closed 3 years ago
Unfortunately an expected outcome of recent change on existing setups. Please sync manually and things should work as expected for future runs.
I did sync manually by removing the offending code from the file. Upon reexecution I got the same error.
/Users/MBP113/Documents/RefindPlus/edk2/000-BuildScript/RepoUpdater.sh
Syncing RefindPlus
Already on 'GOPFix'
Your branch is up to date with 'origin/GOPFix'.
fatal: ambiguous argument '': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Everything up-to-date
From https://github.com/dakanji/RefindPlus
* branch GOPFix -> FETCH_HEAD
Already up to date.
Everything up-to-date
Everything up-to-date
Synced RefindPlus
## RepoUpdater ##
-----------------
Syncing RefindPlusUDK
M 000-BuildScript/RepoUpdater.sh
Already on 'rudk'
Your branch is up to date with 'origin/rudk'.
HEAD is now at 69bcbeec Improve Resilience of RepoUpdater
Total 0 (delta 0), reused 0 (delta 0)
To https://github.com/startergo/Refind-UDK.git
+ 986bb668...69bcbeec HEAD -> rudk (forced update)
From https://github.com/dakanji/Refind-UDK
* branch rudk -> FETCH_HEAD
Updating 69bcbeec..986bb668
Fast-forward
000-BuildScript/RepoUpdateSHA.txt | 2 +-
MdeModulePkg/Library/UefiHiiLib/HiiLib.c | 13 +++++++++++++
UefiCpuPkg/Library/MtrrLib/MtrrLib.c | 12 ++++++++++--
3 files changed, 24 insertions(+), 3 deletions(-)
Total 0 (delta 0), reused 0 (delta 0)
To https://github.com/startergo/Refind-UDK.git
69bcbeec..986bb668 rudk -> rudk
Everything up-to-date
Synced RefindPlusUDK
-----------------
## RepoUpdater ##
MBP113@G5s-Mac-Pro-2 ~ % /Users/MBP113/Documents/RefindPlus/edk2/000-BuildScript/RepoUpdater.sh
Syncing RefindPlus
Already on 'GOPFix'
Your branch is up to date with 'origin/GOPFix'.
fatal: ambiguous argument '': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Runtime Error ... Exiting
What offending code was removed? Lost on that.
BTW, "sync manually" means literally do the sync steps manually as outlined in the ReadMe and not through the script. The script is not meant to be edited.
What offending code was removed? Lost on that.
BTW, "sync manually" means literally do the sync steps manually as outlined in the ReadMe and not through the script. The script is not meant to be edited.
If you look at my fork you will see it is in sync with yours. I still get this error when executing the updater script. The error handling code halts the execution of the script.
Still no idea what was edited and possible this is affecting things. Either way, once you have synced manually and not edited anything, you don't need to to run the sync script again.
Everything works fine if:
## ERROR HANDLER ##
runErr() { # $1: message
# Declare Local Variables
local errMessage
errMessage="${1:-Runtime Error ... Exiting}"
echo ''
msg_error "${errMessage}"
echo ''
echo ''
exit 1
}
trap runErr ERR
this code is gone. There must be some error there. Whenever it is present I get:
RepoUpdater.sh
Syncing RefindPlus
Already on 'GOPFix'
Your branch is up to date with 'origin/GOPFix'.
fatal: ambiguous argument '': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Runtime Error ... Exiting
Every time I need to update the forks I have to remove this:
## ERROR HANDLER ##
runErr() { # $1: message
# Declare Local Variables
local errMessage
errMessage="${1:-Runtime Error ... Exiting}"
echo ''
msg_error "${errMessage}"
echo ''
echo ''
exit 1
}
trap runErr ERR
That is treating a symptom as all that does is halt the script because of an actual error. Removing it does not fix the error that triggers it.
The actual error is emitted by git here: fatal: ambiguous argument '': unknown revision or path not in the working tree.
There is something out of place in your git setup.
Let me update the Reset SHA then do the sync manually as per the ReadMe. Things should be fine then.
EDIT: Updated as was possible that what was currently there was wrong
Update your 000-BuildScript/RepoUpdateSHA.txt
file with the current version manually and rerun the script.
PS: Specially setup to avoid issues with manual update which is not the typical case so not something to repeat.
Sorry ... you might have issues with that.
Copy the script folder to your desktop, update RepoUpdateSHA.txt and run the script on the desktop. RepoUpdateSHA.txt in the git folder should not be changed.
So if I manually try to update and get this:
git pull upstream GOPFix
From https://github.com/dakanji/RefindPlus
* branch GOPFix -> FETCH_HEAD
error: Your local changes to the following files would be overwritten by merge:
EfiLib/AcquireGOP.c
.gitignore:
# Ignore RefindPlusPkg and Build items
/Build
!/Python/build/*
.Build-TMP/
cov-int/
000-BOOTx64-Files/
RefindPlusPkg/
000-Releases/
See: https://github.com/dakanji/RefindPlusUDK/issues/8#issuecomment-804401110
Hang on. Spotted something.
Run the attached from your desktop. Will fix the repo version later
/Users/MBP113/Desktop/RepoUpdater.sh
Syncing RefindPlus
M EfiLib/AcquireGOP.c
Already on 'GOPFix'
Your branch is up to date with 'origin/GOPFix'.
fatal: Could not parse object '986bb668c163a81be980cf79cf439faa68f8684b'.
Runtime Error ... Exiting
Try this: RepoUpdater.sh.zip
You need to commit or discard your pending changes to EfiLib/AcquireGOP.c btw.
This one works like a charm. No need to commit/discard anything.