NativeScript / NativeScript/nx

Trouble with application id and custom nativescript.config.ts

Offen
#73 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
TypeScript
Sterne
68
Forks
15
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

I have this project.json setup where the nativescript.config-aaa.ts contains a different appResourcesPath than the default (nativescript.config.ts). This seems to work fine.

However, I'm also building for different environments, and have to set the application id based on that, so I add "id" to the config.

        "app-test": {
          "flags": "--config=nativescript.config-aaa.ts",
          "id": "com.app.aaa.test"
...
        "app-dev": {
          "flags": "--config=nativescript.config-aaa.ts",
          "id": "com.app.aaa.dev"

The problem is that the id replacements happens in the default nativescript.config.ts, while the rest of the build process is using the specified nativescript.config-aaa.ts.

Any tips on how I can handle this situation properly?

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginne mit project.json und vergleiche, wie --config=nativescript.config-aaa.ts verwendet wird und wie die Anwendungs-ID in nativescript.config.ts ersetzt wird. Führe die Builds app-test und app-dev erneut aus und überprüfe anschließend, dass die ausgewählte benutzerdefinierte Konfiguration die entsprechende ID erhält und dabei ihren appResourcesPath beibehält.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
typescript
Bereich
build-system, mobile-dev
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.