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
When a gnonative user wants to create a new app using gnonative, he can
use the make rule `new-app` like that: `APP_NAME=test make new-app`.
This rule now uses the gnonative expo module hosted in the NPM's
registry. This approach hides a lot of complexity to let the user
concentrate to his app development, and makes gnonative updates easier.
This PR does other things:
- updates gnoboard to Expo v51 to be compatible with Xcode 15.3 or
above.
- fixes the ios build caused by the uppercase of the first letter of the
app name `gnoboard`.
- uses a copy of the Expo's gnonative-provider file instead of use-gno
file. So make updates of gnonative in gnoboard would be easier.
---------
Signed-off-by: D4ryl00 <[email protected]>
@perl -pi -e "s/land\.gno/$(PACKAGE_PREFIX)/"$(MAIN_APP_DIR)/../gobridge/*# in gobridge, replace land.gno by PACKAGE_PREFIX (e.g. com.anonymous)
257
-
@perl -pi -e "s/land\.gno/$(PACKAGE_PREFIX)/"$(MAIN_APP_DIR)/../rootdir/*# in rootdir, replace land.gno by PACKAGE_PREFIX (e.g. com.anonymous)
258
-
@perl -pi -e '/^package ./ and $$_.="\nimport '"$(PACKAGE_PREFIX)"'.gobridge.GoBridgePackage"'$(MAIN_APP_DIR)/$(MAIN_APP_FILE)# add the right import path for gobridge (e.g. import com.anonymous.gobridge.GoBridgePackage)
259
-
@perl -pi -e '/^package ./ and $$_.="\nimport '"$(PACKAGE_PREFIX)"'.rootdir.RootDirPackage"'$(MAIN_APP_DIR)/$(MAIN_APP_FILE)# add the right import path for rootdir (e.g. import com.anonymous.rootdir.RootDirPackage)
260
-
@perl -pi -e 's/return PackageList\(this\)\.packages/return PackageList\(this\)\.packages.apply \{\n\t\t\t\tadd(RootDirPackage())\n\t\t\t\tadd(GoBridgePackage())\n\t\t\t\}/'$(MAIN_APP_DIR)/$(MAIN_APP_FILE)# replace the default package list by one adding gobridge and rootdir
261
-
@perl -pi -e '/^def projectRoot/ and $$_.="def frameworkDir = \"\$$\{rootDir\.getAbsoluteFile\(\)\.getParentFile\(\)\.getParentFile\(\)\.getParentFile\(\)\.getParentFile\(\)\.getParentFile\(\)\.getAbsolutePath\(\)\}/framework\"\n"'$(OUTPUT_DIR)/$(APP_NAME)/android/app/build.gradle # add the projectRoot variable in build.gradle
262
-
@perl -pi -e '/^dependencies/ and $$_.="\timplementation fileTree(dir: \"\$$\{frameworkDir\}/android\", include: \[\"\*\.jar\", \"\*\.aar\"\]\)\n"'$(OUTPUT_DIR)/$(APP_NAME)/android/app/build.gradle # add the framework dependency in build.gradle
Copy file name to clipboardExpand all lines: README.md
+11-10Lines changed: 11 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
Gno Native Kit is a framework that allows developers to build and port gno.land (d)apps written in the (d)app's native language.
4
4
5
-
Current Gno (d)apps run on desktop/laptop computers which have Go installed. To run on mobile, the (d)app would need to bundle the Go runtime, which is complicated for most developers.
5
+
Current Gno (d)apps run on desktop/laptop computers which have Go installed. To run on mobile, the (d)app would need to bundle the Go runtime, which is complicated for most developers.
6
6
7
7
However, Gno Native Kit helps bypass this complexity by using gRPC to make [calls to the Gno core API](https://buf.build/gnolang/gnonative/docs/main:land.gno.gnonative.v1) and access the blockchain's realm functions on a remote Gno.land node.
8
8
These API calls are a programming language-independent wrapper on top of the core supported APIs like [gnoclient](https://github.com/gnolang/gno/tree/master/gno.land/pkg/gnoclient) and [crypto/keys](https://github.com/gnolang/gno/tree/master/tm2/pkg/crypto/keys).
@@ -76,12 +76,12 @@ cd gnonative
76
76
77
77
#### Set up the Android NDK
78
78
79
-
* Launch Android Studio and accept the default startup options. Create a new
80
-
default project (so that we get the main screen).
81
-
* On the Tools menu, open the SDK Manager.
82
-
* In the "SDK Tools" tab, click "Show Package Details". Expand
83
-
"NDK (Side by side)" and check "23.1.7779620".
84
-
* Click OK to install and close the SDK Manager.
79
+
- Launch Android Studio and accept the default startup options. Create a new
80
+
default project (so that we get the main screen).
81
+
- On the Tools menu, open the SDK Manager.
82
+
- In the "SDK Tools" tab, click "Show Package Details". Expand
83
+
"NDK (Side by side)" and check "23.1.7779620".
84
+
- Click OK to install and close the SDK Manager.
85
85
86
86
#### Install the tools with asdf (only need to do once)
87
87
@@ -101,7 +101,7 @@ make build.android
101
101
102
102
```console
103
103
cd examples/js/react-native/gnoboard
104
-
yarn start
104
+
npm start
105
105
```
106
106
107
107
#### Connect your Android phone/emulator and bind its port to metro
@@ -125,6 +125,7 @@ If you prefer the CLI option:
125
125
```console
126
126
android-studio ./android
127
127
```
128
+
128
129
Once done, bind the port to metro:
129
130
130
131
```console
@@ -145,7 +146,7 @@ See more: https://developer.android.com/studio/run#basic-build-run
145
146
make asdf.install_tools
146
147
```
147
148
148
-
If you get an error like "https://github.com/CocoaPods/CLAide.git (at master@97b765e) is not yet checked out" then reinstall cocoapods like this:
149
+
If you get an error like "https://github.com/CocoaPods/CLAide.git (at master@97b765e) is not yet checked out" then reinstall cocoapods like this:
0 commit comments