You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Add a package dependency `"https://github.com/objectbox/objectbox-swift-spm.git"` for your project.
30
+
- Confirm to link your project against `ObjectBox.xcframework`
31
+
23
32
## Running the objectbox code generator
24
33
25
34
The plugin name name is `objectbox-generator`
@@ -34,19 +43,14 @@ To run the plugin from the command line:
34
43
swift package plugin --allow-writing-to-package-directory objectbox-generator
35
44
```
36
45
37
-
### XCode, opening a Swift package
46
+
### XCode
38
47
39
48
Find the plugin menu entry for `ObjectBox` and run the `GeneratorCommand`.
40
49
41
-
If you have multiple targets, select the one for which you want to generate the code.
42
-
43
-
### XCode, classic .xcodeproj
44
-
45
-
As for now, we still recommend to use the existing Cocoapod.
46
-
47
-
However, if you want, you can still add `objectbox-swift-spm` as a package dependency
48
-
and run the generator command. But please be aware that this is not supported yet.
50
+
You will be asked to select a target, select that one which contains your ObjectBox model.
49
51
50
-
TODO: add note about the XCFramework
52
+
## Known limitations
51
53
52
-
(TODO: Note to myself: Align cocoapod way and generator way to produce the same files)
54
+
- The MacCatalyst build has not yet been integrated into Objectbox tests.
55
+
- For XCode project, the generated file `TargetProject/ObjectBox-generated/EntityInfo.generated.swift` needs to be added to XCode by hand.
56
+
- After changes on the ObjectBox models, the generator needs to be executed manually. This is due to the fact that only Generator commands are allowed to write to the package directory, and ObjectBox generated `ObjectBox-models.json` file needs to be added to git.
0 commit comments