FS#14640 - [vim] fetch_runtime.sh script fails to fetch updated files
Attached to Project:
Arch Linux
Opened by Sascha Blank (Catseye) - Saturday, 09 May 2009, 10:14 GMT
Last edited by Dan Griffiths (Ghost1227) - Sunday, 18 April 2010, 07:38 GMT
Opened by Sascha Blank (Catseye) - Saturday, 09 May 2009, 10:14 GMT
Last edited by Dan Griffiths (Ghost1227) - Sunday, 18 April 2010, 07:38 GMT
|
Details
I'm building vim 7.2.166-1 from "testing" and have noticed
that the "fetch_runtime.sh" script that is invoked during
the build process actually (and silently) fails to download
any updated files even though there are dozens of them
available on ftp.vim.org!
The problem can be found in the "fetch_runtime.sh" script itself. There are four places where it expects the following to behave differently: $ if [ $( /bin/true ) ]; then echo "True"; else echo "False"; fi $ if [ $( /bin/false ) ]; then echo "True"; else echo "False"; fi But that assumption is incorrect: both commands will emit "False" no matter what the actual exit code of the $( ... ) command substitution is. "pdksh", "dash", "Bash 3" and "Bash 4" behave consistently in this regard so it looks like the script itself is to blame. The attached diff corrects this wrong assumption and makes the script do correctly what it is supposed to do: replacing the provided runtime files with their more recent versions if they are available. You will see that it makes a difference because there will dozens of "... fetching file ... done!" lines during the "begin fetching updated runtime files..." step. |
This task depends upon
This task blocks these from closing
FS#13897 - [vim] Update python.vim to match version of Python
in Arch
if /bin/true; then echo "True"; else echo "False"; fi
using $() inside [] is to test for output, not for return status.
Could you attach the patch in unified diff? It's more readable that way.
The patched script could benefit from refactoring some of the the "if ! condition ... then ... else" blocks but I think that should done at a later stage (if it all) because at this point it would complicate the review process unnecessarily.
vim provides a much saner way to get the current runtime files using rsync.
See my vim package : http://aur.archlinux.org/packages.php?ID=30507
Are they equivalent in result?
Tobias, what do you think?
He said he would take some actions to fix a few things to reduce these differences. But there was nothing worrying anyway :)
It was mostly weird useless files, not important ones.
About the vim problem, there are some news : there is now an official hg repository containing the latest code and latest runtime files :
http://groups.google.com/group/vim_dev/browse_thread/thread/9f3ffd5d58859095/b513e33108b72003
This makes my vim-cvs and vim-git packages on AUR obsolete, and there is already a new vim-hg package :
http://aur.archlinux.org/packages.php?ID=33422