Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails if app is iOS-only #211

Open
iotashan opened this issue Mar 8, 2023 · 1 comment
Open

Fails if app is iOS-only #211

iotashan opened this issue Mar 8, 2023 · 1 comment

Comments

@iotashan
Copy link

iotashan commented Mar 8, 2023

Describe the bug
Running npx react-native-rename@latest returns the error Directory should be created using "react-native init".

To Reproduce
Steps to reproduce the behavior:

  1. run react-native init
  2. delete the android directory
  3. run react-native-rename

Expected behavior
I would expect it to ignore android renames if the android directory is missing, same with iOS. At the very least it should ignore android if I use --iosBundleID instead of -b

@BrentWardOx
Copy link

BrentWardOx commented Aug 22, 2023

I can confirm that the inverse of this problem is also true:

I have an Android-only app in React Native. Running the npx react-native-rename command fails with Directory should be created using "react-native init".

As a temporary workaround, I initialized a new project with react-native init and copy/pasted the auto-generated ios folder into my existing project. After doing this, npx react-native-rename works!

...This isn't ideal, since I now have a useless ios folder (and @iotashan, you would have a useless android folder if you did this for your project), but this temp-fix did unblock me for local development with this package.

Hope this helps!

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

No branches or pull requests

2 participants