Giter Site home page Giter Site logo

appversioncomposer's Introduction

AppVersionComposer

This package handles app versioning. App version composes from git tag, number of commits since the tag, commit hash (optionally) and branch name (optionally). Composed version is written to 2 places: PlayerSettings.bundleVersion field and to AppVersionHolder asset

Example:

Name Value
Git tag v1.3
Number of commits since the tag 5
Commit hash f540d3
Branch name MyFeatureBranch

Results matrix

Development build Production build
iOS 1.3.51 1.3.51
Android 1.3.5-f540d3-MyFeatureBranch 1.3.5-f540d3
MacOS 1.3.5-f540d3-MyFeatureBranch 1.3.5-f540d3
Windows 1.3.5-f540d3-MyFeatureBranch 1.3.5-f540d3

Requirements:

  • Repository has at least one tag
  • Git tag must be 'vX.X', where X - is a positive number (eg. v1.2)

AppVersionHolder asset

Some platforms might not support any kind of version string (for example iOS). Often, they use semantic versioning with strict restriction to have {major.minor.patch} view. In this case in your implementation you can use AppVersionHolder scriptable object located in Assets/Resources. It contains several properties:

  • AppVersion — data structure that contains all values required to build app version string
  • [editor only] BuildPreprocessorOder — specifies order in which app version will be composed during build preprocessing stage

So, in order to get full app version at Runtime in semver-only platforms, reference AppVersionHolder asset and use AppVersion property

Footnotes

  1. iOS (ipadOS etc) supports only semantic versioning (semver). To get full app version check usage of AppVersionHolder asset 2

appversioncomposer's People

Contributors

artein avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.