Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

Pubblish the latest version to NPM #12

Open
iltumio opened this issue Sep 16, 2019 · 5 comments
Open

Pubblish the latest version to NPM #12

iltumio opened this issue Sep 16, 2019 · 5 comments

Comments

@iltumio
Copy link

iltumio commented Sep 16, 2019

The version on the master branch is updated and it is working with the latest version of React Native (PR #7 solved the podspec issue). The version that is published on NPM registry is not updated and it fails when you run "pod install".

Please pubblish the latest version on NPM

Thanks

@RobinTack
Copy link

Is there any update on this?

@russelRajitha
Copy link

russelRajitha commented Oct 1, 2019

is there any way to config android ? where to put keys like in react native 0.59? my version is react native 0.60.???
builder.add("*.site.com", "sha256/KEY_GOES_HERE");

@RobinTack
Copy link

You add the keys in your pinset.json file. Then you run the command npx pinset gen and the cert-pinner will configure this for you.

@iltumio
Copy link
Author

iltumio commented Oct 14, 2019

no updates. Seems that is not maintained anymore. Currently I'm using this repo link in my package JSON instead of the NPM package and I'm specifying the commit in order to avoid unwanted updates

{
     "react-native-cert-pinner": "git+ssh://git@github.com/approov/react-native-cert-pinner.git#f8a6314840e11e7c0857253b9628fcab00dbefa8",
}

@hdsenevi
Copy link

There is another approach (until maintainer publishes latest version to npm).

I like to avoid putting github pull request links or branch links on my package.json, so I'm using the following approach in one of my projects.

  1. install and setup patch-package in your project
  2. install react-native-cert-pinner from npm (like you would normally) npm install react-native-cert-pinner --save
  3. change your projects node_modules/react-native-cert-pinner to reflect changes from this PR
    for me just the s.homepage = "https://github.com/approov/react-native-cert-pinner" change was enough
  4. then do npx patch-package react-native-cert-pinner which will generate a file under PROJ_ROOT/patches

generated file looks like the following for me

diff --git a/node_modules/react-native-cert-pinner/ios/CertPinner.podspec b/node_modules/react-native-cert-pinner/ios/CertPinner.podspec
index 0095f31..64cab97 100644
--- a/node_modules/react-native-cert-pinner/ios/CertPinner.podspec
+++ b/node_modules/react-native-cert-pinner/ios/CertPinner.podspec
@@ -6,7 +6,7 @@ Pod::Spec.new do |s|
   s.description  = <<-DESC
                   CertPinner
                    DESC
-  s.homepage     = ""
+  s.homepage     = "https://github.com/approov/react-native-cert-pinner"
   s.license      = "MIT"
   # s.license      = { :type => "MIT", :file => "FILE_LICENSE" }
   s.author             = { "author" => "author@domain.cn" }

now every time you do a npm i is will apply this patch on top of npm downloaded package which would fix the pod install issue

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants