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

Add script to template in order to bump app versions #957

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

christianlupus
Copy link
Contributor

This set of scripts should allow the developer to bump the version of the app to a new version. It will update the appinfo/info.xml and the package.json file with the first CLI parameter.
By adding custom scripts to the appropriate folder, it is possible to update other files automatically as well.

There is a topic in the forum that poses some general questions that might be correlated with this PR.

@coveralls
Copy link

coveralls commented Jan 11, 2023

Coverage Status

Coverage: 92.625%. Remained the same when pulling c6f96f7 on dev/update-version-string into 817db86 on master.

@bigcat88
Copy link
Member

bigcat88 commented May 7, 2023

I suggest to implement this in GitHub Actions, when owner of app push tag - replace with commit automatically those versions.

@christianlupus
Copy link
Contributor Author

Adding a github action could be done as an add-on. This structure was designed to allow custom scripts to be added easily without much effort. Running these scripts from a GH action is no big deal. This would allow the authors to disable the GH action though (makes not much sense, I have to admit).

I can provide an implementation (after making it mergable) for that if that would be accepted and merged. Though, I do not want to work for nothing (aka the PR be rejected in the end). Therefore I am asking before investing too much and on too many details.

@bigcat88
Copy link
Member

If you could add entry for this to the Makefile(for example: make set-version 2.2.3), I will gladly merge such a pull request.

Name of makefile command can be any that you choose.

This needs manual documentation in the dev documentation.
It makes however no sense to add this to the docs unless the scrips are
rolled out in the app template.

Signed-off-by: Christian Wolf <github@christianwolf.email>
@christianlupus
Copy link
Contributor Author

Make dows not allow for arbitrary parameters. (All parameters are interpreted as Make targets.)

I could pass it via env variable (that would be like make update-version VERSION=1.2.3) or try to create a template target like make update-version-1.2.3. The latter might need a clear structure (only 3 parts) or a gernic match (so make update-version-new would work as well to create a version new).

I personally prefer the env var variant as it seems cleaner. Do you consent, @bigcat88?

@bigcat88
Copy link
Member

Make dows not allow for arbitrary parameters. (All parameters are interpreted as Make targets.)

I could pass it via env variable (that would be like make update-version VERSION=1.2.3) or try to create a template target like make update-version-1.2.3. The latter might need a clear structure (only 3 parts) or a gernic match (so make update-version-new would work as well to create a version new).

I personally prefer the env var variant as it seems cleaner. Do you consent, @bigcat88?

Yep, I am totally fine with this, if it will work through env like you suggested.

@bigcat88
Copy link
Member

Let know when this is ready to merge

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

Successfully merging this pull request may close these issues.

None yet

3 participants