Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

Importing a Variable?



  • One of our deployable tasks is to send files to a folder that is based on the version number. Although its not an exact copy of the version, and even worse, its the imported version.

    I originally used ${ReleaseName} which then let me call ${ReferancedReleaseName}, it was fine because I can type anything I want into the name, but I worry about using that field long term.

    So I created a custom variable called FolderNumber and I am trying to find a way to reliably access that value on releases that import from that project.

    I was hoping i could create an artifact named based on ${FolderNumber}, then on the applications that import I call ${ArtifactName}, however that is not option based on the Help dialog.

    Is there other ways I can link values across applications, even if it is not a variable? The 5 I see are App ID, App Name, Build Number, Release Name, and Release Number, and none of those will work any better than sticking with Release Name.

    Product: BuildMaster
    Version: 4.2.8



  • There is currently no built-in way to do that. However, this functionality could be added using a variable function. Something like $ApplicationVariable(appId, varName) which would return a variable value evaluated from the specified application's context. (or of course you could just implement $FolderNumber directly as a function using whatever logic you need)

    If you're up to it, you can feel free to try to implement this using the SDK - or we could try to get it (or something like it) in the BuildMasterBeta extension if you're willing to wait a little longer.



  • Waiting might be best for me. <-not so good with object oriented languages.

    I think it would be a great additions to be able to access the many types of Variables. (application, release, build are the 3 types I use, not sure about the rest of your client base)

    I expect my end result would look like:
    $ReleaseVariable(${ReferancedApplicaitonID, ,${ReferancedReleaseNumber, FolderNumber)
    Wow that just got crazy. Think it can handle passing in functions to find a variable?

    I am not in a rush, I just want to reduce the risk of problems. And because 4.3 did a major change to the database my built-in-house reports would have to be redone, so I am being lazy with updates.

    Also this solution would be able to consolidate some of my shared plans that each call different variables, if I instead ask for a variable by passing in the environment like this:
    $Appvar(${AppID}, ${EnvName}Server) I can have the same task work on all my environments.

    Thanks,
    Dan



Inedo Website HomeSupport HomeCode of ConductForums GuideDocumentation