Support put UNITY_LICENSE in file

pull/66/head
litefeel 2020-03-02 01:48:09 +08:00 committed by GitHub
parent b47dcdab84
commit 01c67a3890
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 3 deletions

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
if [[ -n "$UNITY_LICENSE" ]]; then
if [[ -n "$UNITY_LICENSE" || -n "$UNITY_LICENSE_PATH" ]]; then
#
# PERSONAL LICENSE MODE
#
@ -15,8 +15,13 @@ if [[ -n "$UNITY_LICENSE" ]]; then
# Set the license file path
FILE_PATH=UnityLicenseFile.ulf
# Copy license file from Github variables
echo "$UNITY_LICENSE" | tr -d '\r' > $FILE_PATH
if [[ -n "$UNITY_LICENSE" || -n "$UNITY_LICENSE_PATH" ]]; then
# Copy license file from Github variables
echo "$UNITY_LICENSE" | tr -d '\r' > $FILE_PATH
else
# Copy license file from file system
cat "$UNITY_LICENSE_PATH" | tr -d '\r' > $FILE_PATH
fi
# Activate license
ACTIVATION_OUTPUT=$(xvfb-run --auto-servernum --server-args='-screen 0 640x480x24' \