NativeScript / NativeScript/nativescript-cli

Change versionCode/versionName when running with --release

Aberta
#1,118 24 comentários 2 reações 0 responsáveis Ver no GitHub

Ninguém assumiu esta issue ainda.

feature
Linguagem predominante
JavaScript
Estrelas
1.1k
Forks
204
Merge médio
1d 9h
PRs com merge (30d)
8

Descrição

Hi,

I've been building-beta releasing-building-beta releasing an Android app for a couple of days now. Pretty much every time I build it I forget to update the versionCode and versionName in the AndroidManifest.xml. I get reminded of this then Google's Developer Console rejects my APK because of the versionCode not being larger than the previous version.

An easy way to make a little bit easier for the developers would be to add a prompt for versionCode/versionName in the CLI if the build is run with the --release flag. And let the predefined value be read from the current AndroidManifest.xml. This way the developer will be reminded to update the versionCode/versionName and if s/he doesn't want to it's just an enter stroke away.

If versionCode/versionName is changed then write it back to the AndroidManifest.xml

As tns build could be a part of a larger build script where user input is not possible, a new flag, such as --auto or --quiet, should probably be added as well - skipping the prompt.

Guia de contribuição

Abrir o guia de contribuição

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Direção de pesquisa

Comece rastreando o fluxo de tns build quando --release é usado e inspecione como o AndroidManifest.xml é lido e atualizado. Está concluído quando os builds de release puderem solicitar os valores do manifest, persistir os valores alterados de versionCode/versionName e oferecer suporte a uma flag não interativa como --auto ou --quiet.

Escrita pelo modelo de indexação a partir do texto da issue.

Avaliação

Stack de tecnologia
android, javascript
Domínio
build-system, cli, mobile-dev
Tipo de issue
Funcionalidade
Dificuldade
4/5
Tempo estimado
3-5 dias
Status de atividade
Estagnada
Clareza
Razoavelmente clara
Facilidade para iniciantes
35/100

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.