Fixed: Update build.sh to fix macOS startup script issues (#565)

pull/6/head
Qstick 6 years ago committed by GitHub
parent 5c0643d76d
commit 24bdb5a891
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

1
.gitignore vendored

@ -113,6 +113,7 @@ src/UI/.idea/*
*log.txt *log.txt
node_modules/ node_modules/
_output* _output*
_artifacts
_rawPackage/ _rawPackage/
_dotTrace* _dotTrace*
_tests/ _tests/

@ -11,18 +11,10 @@ PublishArtifacts()
7z a $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.windows.zip $artifactsFolderWindows/* 7z a $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.windows.zip $artifactsFolderWindows/*
7z a $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx-app.zip $artifactsFolderMacOSApp/* 7z a $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx-app.zip $artifactsFolderMacOSApp/*
mkdir -p $artifactsFolderMacOSApp/StartScript/Lidarr.app/Contents/MacOS
cp ./osx/Lidarr $artifactsFolderMacOSApp/StartScript/Lidarr.app/Contents/MacOS
7z a $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx-app.zip $artifactsFolderMacOSApp/StartScript/*
rm -rf $artifactsFolderMacOSApp/StartScript/
7z a -ttar $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar $artifactsFolderMacOS/* 7z a -ttar $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar $artifactsFolderMacOS/*
mkdir -p $artifactsFolderMacOS/StartScript/Lidarr
cp ./osx/Lidarr $artifactsFolderMacOS/StartScript/Lidarr/Lidarr
7z a -ttar $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar $artifactsFolderMacOS/StartScript/*
7z a -tgzip $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar.gz $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar 7z a -tgzip $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar.gz $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar
rm -f $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar rm -f $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.osx.tar
rm -rf $artifactsFolderMacOS/StartScript/
7z a -ttar $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar $artifactsFolderLinux/* 7z a -ttar $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar $artifactsFolderLinux/*
7z a -tgzip $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar.gz $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar 7z a -tgzip $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar.gz $artifactsFolder/Lidarr.${APPVEYOR_REPO_BRANCH}.${APPVEYOR_BUILD_VERSION}.linux.tar

@ -1,6 +1,6 @@
version: '0.5.0.{build}' version: '0.5.0.{build}'
image: Previous Visual Studio 2017 image: Visual Studio 2017
assembly_info: assembly_info:
patch: true patch: true

@ -156,6 +156,8 @@ PackageMono()
ProgressStart 'Creating Mono Package' ProgressStart 'Creating Mono Package'
rm -rf $outputFolderLinux rm -rf $outputFolderLinux
echo "Copying Binaries"
cp -r $outputFolder $outputFolderLinux cp -r $outputFolder $outputFolderLinux
echo "Creating MDBs" echo "Creating MDBs"
@ -193,12 +195,19 @@ PackageMono()
ProgressEnd 'Creating Mono Package' ProgressEnd 'Creating Mono Package'
} }
PackageOsx() PackageMacOS()
{ {
ProgressStart 'Creating MacOS Package' ProgressStart 'Creating MacOS Package'
rm -rf $outputFolderMacOS rm -rf $outputFolderMacOS
cp -r $outputFolderLinux $outputFolderMacOS mkdir $outputFolderMacOS
echo "Adding Startup script"
cp ./macOS/Lidarr $outputFolderMacOS
dos2unix $outputFolderMacOS/Lidarr
echo "Copying Binaries"
cp -r $outputFolderLinux/* $outputFolderMacOS
echo "Adding sqlite dylibs" echo "Adding sqlite dylibs"
cp $sourceFolder/Libraries/Sqlite/*.dylib $outputFolderMacOS cp $sourceFolder/Libraries/Sqlite/*.dylib $outputFolderMacOS
@ -206,23 +215,35 @@ PackageOsx()
echo "Adding MediaInfo dylib" echo "Adding MediaInfo dylib"
cp $sourceFolder/Libraries/MediaInfo/*.dylib $outputFolderMacOS cp $sourceFolder/Libraries/MediaInfo/*.dylib $outputFolderMacOS
echo "Adding Startup script"
cp ./osx/Lidarr $outputFolderMacOS
ProgressEnd 'Creating MacOS Package' ProgressEnd 'Creating MacOS Package'
} }
PackageOsxApp() PackageMacOSApp()
{ {
ProgressStart 'Creating MacOS App Package' ProgressStart 'Creating macOS App Package'
rm -rf $outputFolderMacOSApp rm -rf $outputFolderMacOSApp
mkdir $outputFolderMacOSApp mkdir $outputFolderMacOSApp
cp -r ./macOS/Lidarr.app $outputFolderMacOSApp
mkdir -p $outputFolderMacOSApp/Lidarr.app/Contents/MacOS
echo "Adding Startup script"
cp ./macOS/Lidarr $outputFolderMacOSApp/Lidarr.app/Contents/MacOS
dos2unix $outputFolderMacOSApp/Lidarr.app/Contents/MacOS/Lidarr
echo "Copying Binaries"
cp -r $outputFolderLinux/* $outputFolderMacOSApp/Lidarr.app/Contents/MacOS
echo "Adding sqlite dylibs"
cp $sourceFolder/Libraries/Sqlite/*.dylib $outputFolderMacOSApp/Lidarr.app/Contents/MacOS
echo "Adding MediaInfo dylib"
cp $sourceFolder/Libraries/MediaInfo/*.dylib $outputFolderMacOSApp/Lidarr.app/Contents/MacOS
cp -r ./osx/Lidarr.app $outputFolderMacOSApp echo "Removing Update Folder"
cp -r $outputFolderMacOS $outputFolderMacOSApp/Lidarr.app/Contents/MacOS rm -r $outputFolderMacOSApp/Lidarr.app/Contents/MacOS/Lidarr.Update
ProgressEnd 'Creating MacOS App Package' ProgressEnd 'Creating macOS App Package'
} }
PackageTests() PackageTests()
@ -311,8 +332,8 @@ esac
Build Build
RunGulp RunGulp
PackageMono PackageMono
PackageOsx PackageMacOS
PackageOsxApp PackageMacOSApp
PackageTests PackageTests
CleanupWindowsPackage CleanupWindowsPackage
PackageArtifacts PackageArtifacts

Loading…
Cancel
Save