From 13eda1e40564a188ed557a9a65e18244a2e02ded Mon Sep 17 00:00:00 2001 From: Philipp Walter Date: Thu, 14 Dec 2023 23:35:28 +0100 Subject: [PATCH] chore: rename to sodium-react-native-direct --- example/package.json | 4 ++-- example/src/App.tsx | 2 +- package.json | 6 +++--- ...t-native.podspec => sodium-react-native-direct.podspec | 2 +- src/libsodium.ts | 2 +- tsconfig.json | 4 ++-- yarn.lock | 8 ++++---- 7 files changed, 14 insertions(+), 14 deletions(-) rename sodium-react-native.podspec => sodium-react-native-direct.podspec (97%) diff --git a/example/package.json b/example/package.json index addec06..4c9ffb2 100644 --- a/example/package.json +++ b/example/package.json @@ -1,6 +1,6 @@ { - "name": "sodium-react-native-example", - "description": "Example app for sodium-react-native", + "name": "sodium-react-native-direct-example", + "description": "Example app for sodium-react-native-direct", "version": "0.0.1", "private": true, "scripts": { diff --git a/example/src/App.tsx b/example/src/App.tsx index ea7bb07..cc13ee5 100644 --- a/example/src/App.tsx +++ b/example/src/App.tsx @@ -1,6 +1,6 @@ import * as React from 'react'; import { StyleSheet, View, SafeAreaView } from 'react-native'; -import sodium from 'sodium-react-native'; +import sodium from 'sodium-react-native-direct'; import b4a from 'b4a'; import Text from './components/Text'; diff --git a/package.json b/package.json index 5c9f5cf..6eec0d7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "sodium-react-native", - "version": "0.1.0", + "name": "sodium-react-native-direct", + "version": "0.3.0", "description": "React native wrapper for libsodium crypto library", "main": "lib/commonjs/index", "module": "lib/module/index", @@ -39,7 +39,7 @@ "!**/.*" ], "scripts": { - "example": "yarn workspace sodium-react-native-example", + "example": "yarn workspace sodium-react-native-direct-example", "build:libsodium": "./libsodium/build.sh", "test": "jest", "typecheck": "tsc --noEmit", diff --git a/sodium-react-native.podspec b/sodium-react-native-direct.podspec similarity index 97% rename from sodium-react-native.podspec rename to sodium-react-native-direct.podspec index be96067..3072865 100644 --- a/sodium-react-native.podspec +++ b/sodium-react-native-direct.podspec @@ -4,7 +4,7 @@ package = JSON.parse(File.read(File.join(__dir__, "package.json"))) folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32' Pod::Spec.new do |s| - s.name = "sodium-react-native" + s.name = package["name"] s.version = package["version"] s.summary = package["description"] s.homepage = package["homepage"] diff --git a/src/libsodium.ts b/src/libsodium.ts index a20a632..5920109 100644 --- a/src/libsodium.ts +++ b/src/libsodium.ts @@ -1,7 +1,7 @@ import { NativeModules, Platform } from 'react-native'; const LINKING_ERROR = - `The package 'sodium-react-native' doesn't seem to be linked. Make sure: \n\n` + + `The package 'sodium-react-native-direct' doesn't seem to be linked. Make sure: \n\n` + Platform.select({ ios: "- You have run 'pod install'\n", default: '' }) + '- You rebuilt the app after installing the package\n' + '- You are not using Expo Go\n'; diff --git a/tsconfig.json b/tsconfig.json index 67a29ed..36306ac 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,8 +2,8 @@ "compilerOptions": { "rootDir": ".", "paths": { - "sodium-react-native": ["./src/index"], - "sodium-react-native/*": ["./src/*"] + "sodium-react-native-direct": ["./src/index"], + "sodium-react-native-direct/*": ["./src/*"] }, "allowUnreachableCode": false, "allowUnusedLabels": false, diff --git a/yarn.lock b/yarn.lock index 528db8e..0dea3df 100644 --- a/yarn.lock +++ b/yarn.lock @@ -11932,9 +11932,9 @@ __metadata: languageName: node linkType: hard -"sodium-react-native-example@workspace:example": +"sodium-react-native-direct-example@workspace:example": version: 0.0.0-use.local - resolution: "sodium-react-native-example@workspace:example" + resolution: "sodium-react-native-direct-example@workspace:example" dependencies: "@babel/core": ^7.20.0 "@babel/preset-env": ^7.20.0 @@ -11950,9 +11950,9 @@ __metadata: languageName: unknown linkType: soft -"sodium-react-native@workspace:.": +"sodium-react-native-direct@workspace:.": version: 0.0.0-use.local - resolution: "sodium-react-native@workspace:." + resolution: "sodium-react-native-direct@workspace:." dependencies: "@commitlint/config-conventional": ^17.0.2 "@evilmartians/lefthook": ^1.5.0