Inedo Community Forums Forums
    • Recent
    • Tags
    • Popular
    • Login

    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!

    Get-Asset Operation does not ensure WorkingDirectory exists

    Scheduled Pinned Locked Moved Support
    otter
    3 Posts 2 Posters 10 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • W Offline
      williamb_5729
      last edited by

      The Get-Asset operation does not ensure the $WorkingDirectory exists. This leads to an exception if the directory has not been created by a previous operation.

      The Ensure-Directory operation will create the $WorkingDirectory, but it then becomes a configuration item that is reported on the Server's configuration page.

      I cannot locate a function that simply creates a directory if it does not exist. The Get-Asset operation should ensure that the working directory exists when copying the asset, similar to some other operations.

      Is there a workaround other than Ensure-Directory?

      Product: Otter
      Version: 2.0.12

      1 Reply Last reply Reply Quote 0
      • W Offline
        williamb_5729
        last edited by

        The Create-File operation will create the directory. Using $WorkingDirectory as the location of the file ensures that that path is created and will be removed after execution completes.

        Still, Get-Asset should ensure the destination directory exists.

        1 Reply Last reply Reply Quote 0
        • atrippA Offline
          atripp inedo-engineer
          last edited by

          I totally agree! Thanks for pointing this out.

          I've filed this is a bug report (OT-254), so it will get fixed in a future maintenance release

          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • 1 / 1
          • First post
            Last post
          Inedo Website Home • Support Home • Code of Conduct • Forums Guide • Documentation