mirror of
https://github.com/morgan9e/macos-stats
synced 2026-04-14 00:04:15 +09:00
initialized makefile
This commit is contained in:
85
Makefile
Normal file
85
Makefile
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
APP = Stats
|
||||||
|
ITC_USERNAME = AC_USERNAME
|
||||||
|
ITC_PASSWORD = @keychain:AC_PASSWORD
|
||||||
|
ITC_PROVIDER= AC_PROVIDER
|
||||||
|
|
||||||
|
BUNDLE_ID = eu.exelban.Stats
|
||||||
|
|
||||||
|
BUILD_PATH = ${PWD}/build
|
||||||
|
ARCHIVE_PATH = $(BUILD_PATH)/$(APP).xcarchive
|
||||||
|
APP_PATH = "${BUILD_PATH}/${APP}.app"
|
||||||
|
ZIP_PATH = "${BUILD_PATH}/${APP}.zip"
|
||||||
|
DMG_PATH = $(PWD)/$(APP).dmg
|
||||||
|
|
||||||
|
all: clean archive notarize sign build clean
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf ${BUILD_PATH}
|
||||||
|
|
||||||
|
.PHONY: archive
|
||||||
|
archive: clean
|
||||||
|
xcodebuild \
|
||||||
|
-scheme ${APP} \
|
||||||
|
-destination 'platform=OS X,arch=x86_64' \
|
||||||
|
-configuration AppStoreDistribution archive \
|
||||||
|
-archivePath ${ARCHIVE_PATH}
|
||||||
|
|
||||||
|
xcodebuild \
|
||||||
|
-exportArchive \
|
||||||
|
-exportOptionsPlist "${PWD}/exportOptions.plist" \
|
||||||
|
-archivePath ${ARCHIVE_PATH} \
|
||||||
|
-exportPath ${BUILD_PATH}
|
||||||
|
|
||||||
|
ditto -c -k --keepParent ${APP_PATH} ${ZIP_PATH}
|
||||||
|
|
||||||
|
.PHONY: notarize
|
||||||
|
notarize: archive
|
||||||
|
xcrun altool \
|
||||||
|
--notarize-app \
|
||||||
|
--primary-bundle-id ${BUNDLE_ID} \
|
||||||
|
-itc_provider ${ITC_PROVIDER} \
|
||||||
|
-u ${ITC_USERNAME} \
|
||||||
|
-p ${ITC_PASSWORD} \
|
||||||
|
--file ${ZIP_PATH}
|
||||||
|
|
||||||
|
sleep 380
|
||||||
|
|
||||||
|
.PHONY: sign
|
||||||
|
sign:
|
||||||
|
xcrun stapler staple $(APP_PATH)
|
||||||
|
spctl -a -t exec -vvv $(APP_PATH)
|
||||||
|
|
||||||
|
.PHONY: build
|
||||||
|
build: sign
|
||||||
|
if [ ! -d $(PWD)/create-dmg ]; then \
|
||||||
|
git clone https://github.com/andreyvit/create-dmg; \
|
||||||
|
fi
|
||||||
|
|
||||||
|
./create-dmg/create-dmg \
|
||||||
|
--volname $(APP) \
|
||||||
|
--background "./resources/background.png" \
|
||||||
|
--window-pos 200 120 \
|
||||||
|
--window-size 500 320 \
|
||||||
|
--icon-size 80 \
|
||||||
|
--icon "Stats.app" 125 175 \
|
||||||
|
--hide-extension "Stats.app" \
|
||||||
|
--app-drop-link 375 175 \
|
||||||
|
$(DMG_PATH) \
|
||||||
|
$(APP_PATH)
|
||||||
|
|
||||||
|
rm -rf ./create-dmg
|
||||||
|
rm -rf $(BUILD_PATH)
|
||||||
|
|
||||||
|
check:
|
||||||
|
xcrun altool \
|
||||||
|
--notarization-info 55fe58d9-d149-4f91-b448-ad8427b90055 \
|
||||||
|
-itc_provider ${ITC_PROVIDER} \
|
||||||
|
-u ${ITC_USERNAME} \
|
||||||
|
-p ${ITC_PASSWORD}
|
||||||
|
|
||||||
|
history:
|
||||||
|
xcrun altool \
|
||||||
|
--notarization-history 0 \
|
||||||
|
-itc_provider ${ITC_PROVIDER} \
|
||||||
|
-u ${ITC_USERNAME} \
|
||||||
|
-p ${ITC_PASSWORD}
|
||||||
@@ -50,6 +50,7 @@ You can download latest version [here](https://github.com/exelban/stats/releases
|
|||||||
## What's new
|
## What's new
|
||||||
|
|
||||||
### v1.2.2
|
### v1.2.2
|
||||||
|
- fully automated build and sign app process
|
||||||
- added name of the indicators in the Chart/Chart with value
|
- added name of the indicators in the Chart/Chart with value
|
||||||
- added check for new version on start
|
- added check for new version on start
|
||||||
- removed charts and charts with value to Disk module
|
- removed charts and charts with value to Disk module
|
||||||
|
|||||||
25
build.sh
25
build.sh
@@ -1,25 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
if [ ! -d "./create-dmg" ]; then
|
|
||||||
git clone https://github.com/andreyvit/create-dmg
|
|
||||||
fi
|
|
||||||
|
|
||||||
# xcodebuild -configuration Distribution clean build
|
|
||||||
|
|
||||||
# cp -rf $PWD/build/Release/Stats.app ./
|
|
||||||
# rm -rf echo $PWD/build
|
|
||||||
|
|
||||||
./create-dmg/create-dmg \
|
|
||||||
--volname "Stats" \
|
|
||||||
--background "./resources/background.png" \
|
|
||||||
--window-pos 200 120 \
|
|
||||||
--window-size 500 320 \
|
|
||||||
--icon-size 80 \
|
|
||||||
--icon "Stats.app" 125 175 \
|
|
||||||
--hide-extension "Stats.app" \
|
|
||||||
--app-drop-link 375 175 \
|
|
||||||
"Stats.dmg" \
|
|
||||||
"Stats.app"
|
|
||||||
|
|
||||||
rm -rf ./create-dmg
|
|
||||||
rm -rf Stats.app
|
|
||||||
10
exportOptions.plist
Normal file
10
exportOptions.plist
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>method</key>
|
||||||
|
<string>developer-id</string>
|
||||||
|
<key>signingStyle</key>
|
||||||
|
<string>automatic</string>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
||||||
Reference in New Issue
Block a user