Skip to content

When we init a new project, some template strings are not replaced #561

@pvinis

Description

@pvinis

Environment

npx react-native info
info Fetching system and libraries information...
System:
    OS: macOS 10.14.5
    CPU: (8) x64 Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz
    Memory: 613.23 MB / 16.00 GB
    Shell: 5.3 - /bin/zsh
  Binaries:
    Node: 12.3.1 - ~/.nodenv/versions/12.3.1/bin/node
    Yarn: 1.16.0 - /usr/local/bin/yarn
    npm: 6.9.0 - ~/.nodenv/versions/12.3.1/bin/npm
    Watchman: 4.9.0 - /usr/local/bin/watchman
  SDKs:
    iOS SDK:
      Platforms: iOS 12.2, macOS 10.14, tvOS 12.2, watchOS 5.2
    Android SDK:
      API Levels: 28, 29
      Build Tools: 28.0.3, 29.0.1
      System Images: android-29 | Google APIs Intel x86 Atom
  IDEs:
    Android Studio: 3.4 AI-183.6156.11.34.5692245
    Xcode: 10.2.1/10E1001 - /usr/bin/xcodebuild

Description

Two files, one for ios and one for android have a template string as the name of the app. In both files it's Hello App Display Name.

I tried running react-native init Bla using the latest react-native-cli and it worked well, replacing these strings with Bla.
Using the latest @react-native-community/cli, the strings were not replaced.

Reproducible Demo

  • Run npx react-native init Bla
  • Open file Bla/ios/Bla/Info.plist and Bla/android/app/src/main/res/values/string.xml and notice that in both files there is the string Hello App Display Name as the project's name.

This should normally be Bla in our case.

Screenshot 2019-07-11 at 18 11 19

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions