Welcome to mirror list, hosted at ThFree Co, Russian Federation.

publish-packages.sh - github.com/mono/corefx.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 408c9e4fe1783c74e52fda52d7f267144344e67d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/usr/bin/env bash

usage()
{
    echo "Publishes the NuGet packages to the specified location."
    echo "For publishing to Azure the following properties are required."
    echo "  /p:CloudDropAccountName='account name'"
    echo "  /p:CloudDropAccessToken='access token'"
    exit 1
}

working_tree_root="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
publish_packages_log=$working_tree_root/publish-packages.log
options="/nologo /flp:v=detailed;Append;LogFile=$publish_packages_log"
allargs="$@"

echo -e "Running publish-packages.sh $allargs" > $publish_packages_log

# Parse arguments
if [ "$allargs" == "-h" ] || [ "$allargs" == "--help" ]; then
    usage
fi

# Ensure that MSBuild is available
echo "Running init-tools.sh"
$working_tree_root/init-tools.sh

echo -e "\n$working_tree_root/Tools/corerun $working_tree_root/Tools/MSBuild.exe $working_tree_root/src/publish.builds $options $allargs" >> $publish_packages_log
$working_tree_root/Tools/corerun $working_tree_root/Tools/MSBuild.exe $working_tree_root/src/publish.builds $options $allargs

if [ $? -ne 0 ]; then
    echo -e "\nAn error occurred. Aborting publish-packages.sh ." >> $publish_packages_log
    echo "ERROR: An error occurred while building packages, see $publish_packages_log for more details."
    exit 1
fi

echo "Done building packages."
echo -e "\nDone building packages." >> $publish_packages_log
exit 0