-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_notes.txt
More file actions
61 lines (36 loc) · 1.92 KB
/
_notes.txt
File metadata and controls
61 lines (36 loc) · 1.92 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
+ list schemes, targets
> xcodebuild -list -project multi.xcodeproj
+ set environment
* https://stackoverflow.com/questions/31179706/how-can-i-launch-the-ios-simulator-from-terminal
get device list
> xcrun simctl list devices available
get destination list
> xcodebuild -scheme $SCHEME -showdestinations
get bundleid (run after set $BUNDLEPATH)
> mdls -name kMDItemCFBundleIdentifier -r $BUNDLEPATH
phone
> SCHEME=multi
> DEVICEID=A736F7FD-1EC9-4EB3-9F88-33A12B76E96F
> DESTINATION='platform=iOS Simulator,name=iPhone 11,OS=15.0'
> BUNDLEPATH=/Users/reinfurt/Library/Developer/Xcode/DerivedData/multi-gewlnlwrghrquaaugzyvvcoompcu/Build/Products/Debug-iphonesimulator/multi.app
> BUNDLEID=com.o-r-g.multi
watch
> SCHEME=watch
> DEVICEID=EF4AF95D-CC52-42EF-9F2F-B74DAD317DDE
> DESTINATION='platform=watchsimulator,name=Apple Watch Series 7 - 45mm,OS=8.3'
or
> DESTINATION='platform=iOS,name=monsty'
> BUNDLEPATH=/Users/reinfurt/Library/Developer/Xcode/DerivedData/multi-gewlnlwrghrquaaugzyvvcoompcu/Build/Products/Debug-watchsimulator/Multi.app
> BUNDLEID=com.o-r-g.multi.watchkitapp
{ platform:iOS, id:00008020-0005153C0E62002E, name:monsty, error:monsty does not have a paired Apple Watch on which to run apps. }
+ start simulator
> /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app/Contents/MacOS/Simulator -CurrentDeviceUDID $DEVICEID;
+ build
> xcodebuild -scheme $SCHEME -destination $DESTINATION build
+ build, stop, install, run
> xcodebuild -scheme $SCHEME build
> xcrun simctl terminate $DEVICEID $BUNDLEID
> xcrun simctl install $DEVICEID $BUNDLEPATH
> xcrun simctl launch $DEVICEID $BUNDLEID
one-liner
> xcodebuild -scheme $SCHEME -destination $DESTINATION build; xcrun simctl terminate $DEVICEID $BUNDLEID; xcrun simctl install $DEVICEID $BUNDLEPATH; xcrun simctl launch $DEVICEID $BUNDLEID