[SPARK-4501][Core] - Create build/mvn to automatically download maven/zinc/scalac

Creates a top level directory script (as `build/mvn`) to automatically download zinc and the specific version of scala used to easily build spark. This will also download and install maven if the user doesn't already have it and all packages are hosted under the `build/` directory. Tested on both Linux and OSX OS's and both work. All commands pass through to the maven binary so it acts exactly as a traditional maven call would.
Yes it does, great catch! I'll be back to a computer in a few hours and can commit the changes, but, if you want to merge before that, feel free to update. Thanks!



-----Original Message-----
From: Patrick Wendell [notifications@github.com<mailto:notifications@github.com>]
Sent: Friday, December 26, 2014 04:13 PM Eastern Standard Time
To: apache/spark
Cc: York, Brennon
Subject: Re: [spark] [SPARK-4501][Core] - Create build/mvn to automatically download maven/zinc/scalac (#3707)


In sbt/sbt<https://github.com/apache/spark/pull/3707#discussion-diff-22288516>:


> -  done
> -
> -  # Now, ensure sbt version is used.
> -  [[ "${sbt_version}XXX" != "XXX" ]] && addJava "-Dsbt.version=$sbt_version"
> -}
> -
> -loadConfigFile() {
> -  cat "$1" | sed '/^\#/d'
> -}
> -
> -# if sbtopts files exist, prepend their contents to $@ so it can be processed by this runner
> -[[ -f "$etc_sbt_opts_file" ]] && set -- $(loadConfigFile "$etc_sbt_opts_file") "$@"
> -[[ -f "$sbt_opts_file" ]] && set -- $(loadConfigFile "$sbt_opts_file") "$@"
> -
> -run "$@"
> +${_DIR}/../build/sbt $@


Does this need to quote the "$@" to preserve argument arrays?

—
Reply to this email directly or view it on GitHub<https://github.com/apache/spark/pull/3707/files#r22288516>.
________________________________________________________

The information contained in this e-mail is confidential and/or proprietary to Capital One and/or its affiliates. The information transmitted herewith is intended only for use by the individual or entity to which it is addressed.  If the reader of this message is not the intended recipient, you are hereby notified that any review, retransmission, dissemination, distribution, copying or other use of, or taking of any action in reliance upon this information is strictly prohibited. If you have received this communication in error, please contact the sender and delete the material from your computer.