Revision 174:6bb2461a2ff5
b/Assets/Installer.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: f86b05d33458d45ff94a12beb30e44f2 |
|
3 |
folderAsset: yes |
|
4 |
timeCreated: 1449523276 |
|
5 |
licenseType: Pro |
|
6 |
DefaultImporter: |
|
7 |
userData: |
|
8 |
assetBundleName: |
|
9 |
assetBundleVariant: |
b/Assets/Installer/Tidmarsh.nsi | ||
---|---|---|
1 |
Name "Tidmarsh Living Observatory" |
|
2 |
OutFile "tidmarsh-%VER%-win.exe" |
|
3 |
RequestExecutionLevel Admin |
|
4 |
InstallDir $PROGRAMFILES\Tidmarsh |
|
5 |
DirText "This will install Tidmarsh Living Observatory %VER% on your computer." |
|
6 |
|
|
7 |
Section "" |
|
8 |
|
|
9 |
SetOutPath $INSTDIR |
|
10 |
|
|
11 |
File Tidmarsh.exe |
|
12 |
File /r Tidmarsh_Data |
|
13 |
|
|
14 |
WriteUninstaller $INSTDIR\Uninstall.exe |
|
15 |
|
|
16 |
CreateDirectory "$SMPROGRAMS\Tidmarsh" |
|
17 |
CreateShortCut "$SMPROGRAMS\Tidmarsh\Tidmarsh Living Observatory.lnk" "$INSTDIR\Tidmarsh.exe" |
|
18 |
CreateShortCut "$SMPROGRAMS\Tidmarsh\Uninstall Tidmarsh.lnk" "$INSTDIR\Uninstall.exe" |
|
19 |
|
|
20 |
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tidmarsh" "DisplayName" "Tidmarsh Living Observatory" |
|
21 |
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tidmarsh" "UninstallString" "$INSTDIR\Uninstall.exe" |
|
22 |
|
|
23 |
SectionEnd |
|
24 |
|
|
25 |
Section "Uninstall" |
|
26 |
|
|
27 |
Delete $INSTDIR\Uninstall.exe |
|
28 |
Delete $INSTDIR\Tidmarsh.exe |
|
29 |
RMDir /r $INSTDIR\Tidmarsh_Data |
|
30 |
RMDir $INSTDIR |
|
31 |
|
|
32 |
Delete "$SMPROGRAMS\Tidmarsh\Tidmarsh Living Observatory.lnk" |
|
33 |
Delete "$SMPROGRAMS\Tidmarsh\Uninstall Tidmarsh.lnk" |
|
34 |
RMDir "$SMPROGRAMS\Tidmarsh" |
|
35 |
|
|
36 |
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tidmarsh" |
|
37 |
|
|
38 |
SectionEnd |
b/Assets/Installer/Tidmarsh.nsi.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: 90f0f16b06df54b10ac0e3b575bc4940 |
|
3 |
timeCreated: 1449523276 |
|
4 |
licenseType: Pro |
|
5 |
DefaultImporter: |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
b/Assets/Installer/downloads.json | ||
---|---|---|
1 |
{ |
|
2 |
"downloads": [ |
|
3 |
{ |
|
4 |
"title": "Tidmarsh Living Observatory for Mac OS X", |
|
5 |
"platform": "mac", |
|
6 |
"version": "%VER%", |
|
7 |
"date": "%DATE%", |
|
8 |
"url": "dl/tidmarsh-%VER%-mac.zip" |
|
9 |
}, |
|
10 |
{ |
|
11 |
"title": "Tidmarsh Living Observatory for Windows", |
|
12 |
"platform": "win32", |
|
13 |
"version": "%VER%", |
|
14 |
"date": "%DATE%", |
|
15 |
"url": "dl/tidmarsh-%VER%-win.exe" |
|
16 |
}, |
|
17 |
{ |
|
18 |
"title": "Tidmarsh Living Observatory for Linux x64", |
|
19 |
"platform": "linux", |
|
20 |
"version": "%VER%", |
|
21 |
"date": "%DATE%", |
|
22 |
"url": "dl/tidmarsh-%VER%-linux.tar.bz2" |
|
23 |
} |
|
24 |
] |
|
25 |
} |
|
26 |
|
b/Assets/Installer/downloads.json.meta | ||
---|---|---|
1 |
fileFormatVersion: 2 |
|
2 |
guid: b627a0e0d26ad4a52b2f4793c669cdb5 |
|
3 |
timeCreated: 1449527806 |
|
4 |
licenseType: Pro |
|
5 |
TextScriptImporter: |
|
6 |
userData: |
|
7 |
assetBundleName: |
|
8 |
assetBundleVariant: |
b/Makefile | ||
---|---|---|
1 |
UNITY=/opt/Unity/Editor/Unity |
|
2 |
SCENE="Assets/_Scenes/Cells\ 3,4.unity" |
|
3 |
|
|
4 |
|
|
5 |
VERSION=$(shell printf '%s.%s' \ |
|
6 |
`grep -m 1 MajorVersion "$(SCENE)" | sed -e 's/^.*\([0-9]\+\).*$$/\1/'` \ |
|
7 |
`grep -m 1 MinorVersion "$(SCENE)" | sed -e 's/^.*\([0-9]\+\).*$$/\1/'` ) |
|
8 |
|
|
9 |
BUILD=build |
|
10 |
LINUX=tidmarsh-$(VERSION)-linux |
|
11 |
MAC=tidmarsh-$(VERSION)-mac |
|
12 |
WIN=tidmarsh-$(VERSION)-win |
|
13 |
|
|
14 |
LINUX_APP=Tidmarsh_v$(VERSION).x86_64 |
|
15 |
MAC_APP=Tidmarsh_v$(VERSION).app |
|
16 |
WIN_APP=Tidmarsh.exe |
|
17 |
|
|
18 |
UNITY_ARGS=-batchmode -quit -logfile /dev/stdout \ |
|
19 |
-projectPath '$(shell pwd)' |
|
20 |
|
|
21 |
.PHONY: linux |
|
22 |
linux: $(BUILD)/$(LINUX).tar.bz2 |
|
23 |
|
|
24 |
.PHONY: mac |
|
25 |
mac: $(BUILD)/$(MAC).zip |
|
26 |
|
|
27 |
.PHONY: win |
|
28 |
win: $(BUILD)/$(WIN).exe |
|
29 |
|
|
30 |
DEPLOY_FILES=$(BUILD)/$(MAC).zip $(BUILD)/$(WIN).exe $(BUILD)/$(LINUX).tar.bz2 $(BUILD)/index.json |
|
31 |
|
|
32 |
.PHONY: deploy-beta deploy-prod deploy-local |
|
33 |
deploy-beta: $(DEPLOY_FILES) |
|
34 |
scp $^ tidmarsh.media.mit.edu:/srv/beta/dl |
|
35 |
|
|
36 |
deploy-prod: $(DEPLOY_FILES) |
|
37 |
scp $^ tidmarsh.media.mit.edu:/srv/http/dl |
|
38 |
|
|
39 |
deploy-local: $(DEPLOY_FILES) |
|
40 |
scp $^ ~/tid-site/dl |
|
41 |
|
|
42 |
$(BUILD)/$(LINUX)/$(LINUX_APP): |
|
43 |
mkdir -p $(BUILD)/$(LINUX) |
|
44 |
$(UNITY) -batchmode -quit -projectPath '$(shell pwd)' -buildLinux64Player $@ -logFile /dev/stdout -nographics |
|
45 |
|
|
46 |
$(BUILD)/$(LINUX).tar.bz2: $(BUILD)/$(LINUX)/$(LINUX_APP) |
|
47 |
cd $(BUILD) && tar cjvf $(LINUX).tar.bz2 $(LINUX) |
|
48 |
|
|
49 |
$(BUILD)/$(MAC)/$(MAC_APP): |
|
50 |
mkdir -p $(BUILD)/$(MAC) |
|
51 |
$(UNITY) -batchmode -quit -projectPath '$(shell pwd)' -buildOSX64Player $@ -logFile /dev/stdout -nographics |
|
52 |
|
|
53 |
$(BUILD)/$(MAC).dmg: $(BUILD)/$(MAC)/$(MAC_APP) |
|
54 |
genisoimage -V $(MAC) -D -R -apple -no-pad -o $@ $(BUILD)/$(MAC) |
|
55 |
|
|
56 |
$(BUILD)/$(MAC).zip: $(BUILD)/$(MAC)/$(MAC_APP) |
|
57 |
cd $(BUILD)/$(MAC) && zip -r ../$(MAC).zip $(MAC_APP) |
|
58 |
|
|
59 |
$(BUILD)/$(WIN)/$(WIN_APP): |
|
60 |
mkdir -p $(BUILD)/$(WIN) |
|
61 |
$(UNITY) -batchmode -quit -projectPath '$(shell pwd)' -buildWindowsPlayer $@ -logFile /dev/stdout -nographics |
|
62 |
|
|
63 |
$(BUILD)/$(WIN)/tidmarsh_$(VERSION).nsi: Assets/Installer/Tidmarsh.nsi |
|
64 |
sed -e 's/%VER%/$(VERSION)/g' $< > $@ |
|
65 |
|
|
66 |
$(BUILD)/$(WIN).exe: $(BUILD)/$(WIN)/tidmarsh_$(VERSION).nsi $(BUILD)/$(WIN)/$(WIN_APP) |
|
67 |
cd $(BUILD)/$(WIN) && makensis tidmarsh_$(VERSION).nsi && cp $(WIN).exe .. |
|
68 |
|
|
69 |
$(BUILD)/index.json: Assets/Installer/downloads.json |
|
70 |
sed -e 's/%VER%/$(VERSION)/g' -e 's/%DATE%/$(shell date --rfc-3339=seconds)/g' $< > $@ |
|
71 |
|
|
72 |
.PHONY: showversion |
|
73 |
showversion: |
|
74 |
@echo "Version: " $(VERSION) |
|
75 |
|
|
76 |
.PHONY: showfiles |
|
77 |
showfiles: |
|
78 |
@echo '$(FILES)' |
|
79 |
|
|
80 |
|
Also available in: Unified diff