Giter VIP home page Giter VIP logo

Comments (13)

davormaricdev avatar davormaricdev commented on August 16, 2024 4

Agree. Coming up in next release

from fastlane-plugin-flutter-version-manager.

krjw-eyev avatar krjw-eyev commented on August 16, 2024 3

This is what I am using. I hope it helps you.

  def versionString()
    file=YAML.load_file('../version.yml')
    version="#{file['major']}.#{file['minor']}.#{file['patch']}"
    UI.message version
    return version
  end

Usage:

lane :set_version_ios do
    version = versionString()
    increment_version_number_in_xcodeproj(
        version_number: version,   
        xcodeproj: './ios/Runner.xcodeproj'  
    )
end

from fastlane-plugin-flutter-version-manager.

talbiislam96 avatar talbiislam96 commented on August 16, 2024 1

@krjw-eyev thank you for your help , I was using the wrong path. works now :)

from fastlane-plugin-flutter-version-manager.

Morteza-Rastgoo avatar Morteza-Rastgoo commented on August 16, 2024

I also needed this to get this to use in a commit message like this:

git commit -m "Version $major.$minor.$patch+$code"

I can still wait for the new release but:
Do you think there is a better way of doing it?

from fastlane-plugin-flutter-version-manager.

Y0ngg4n avatar Y0ngg4n commented on August 16, 2024

Would great if this feature comes fast :)

from fastlane-plugin-flutter-version-manager.

DanOxlade avatar DanOxlade commented on August 16, 2024

This feature would be really useful, any news on when it will be available?

from fastlane-plugin-flutter-version-manager.

talbiislam96 avatar talbiislam96 commented on August 16, 2024

@krjw-eyev does the code you posted work ? have you succeeded to get the current version and put it in a variable?
I need to know , because am trying to put the version in a git tag but don't know how , since am new to Fastlane and ruby. If anyone can help I'd be grateful.

from fastlane-plugin-flutter-version-manager.

talbiislam96 avatar talbiislam96 commented on August 16, 2024

@davormaricdev any progress / news on the feature? Is there a way I can read the. version after incrementing it then print it in a git tag ? I'd be grateful for your help

from fastlane-plugin-flutter-version-manager.

talbiislam96 avatar talbiislam96 commented on August 16, 2024

@krjw-eyev thank you so much that was extremely helpful. Happy coding

from fastlane-plugin-flutter-version-manager.

talbiislam96 avatar talbiislam96 commented on August 16, 2024

@krjw-eyev am getting the following error

`
No such file or directory @ rb_sysopen - ../version.yml

`
apparently it is not able to read version.yml although am sure the path is correct because it can read it in bump version lanes , do you happen to know how I can fix this please?

from fastlane-plugin-flutter-version-manager.

krjw-eyev avatar krjw-eyev commented on August 16, 2024

It depends where your version.yml file is located. ./ is the current directory ../ is the parent directory. ../../ is the parents parent directory and so on.

My folder structure looks like this:

my-flutter-app/
├─ fastlane/
│  ├─ Fastfile
├─ version.yml

I execute fastlane in the my-flutter-app folder.

from fastlane-plugin-flutter-version-manager.

Hritik602 avatar Hritik602 commented on August 16, 2024

Is this plugin discontinued???

Fastlane-plugin-flutter_vers | 1.0.0 | No actions found |
| ion_manager

[!] No actions were found while loading one or more plugins
Please use bundle exec fastlane with plugins
More info - https://docs.fastlane.tools/plugins/using-plugins/#run-with-plugins .

from fastlane-plugin-flutter-version-manager.

Phando avatar Phando commented on August 16, 2024

Add these with the appropriate paths to your Fastfile and you should be good to go. They came from a little deeper in the plugin (not my code).

`
def versionCode()
@git = Git.open('../../')
head = @git.object('HEAD')
commit = @git.gcommit(head.sha)
commit.date.to_i - GIT_OFFSET
end

def versionString()
file=YAML.load_file('../../version.yml')
version="#{file['major']}.#{file['minor']}.#{file['patch']}"
return version
end
`

from fastlane-plugin-flutter-version-manager.

Related Issues (11)

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.