Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-19374

Working directory of Qbs project is not set until after clicking Projects/Run in Run Settings

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • Qt Creator 4.5.0
    • Qt Creator 4.4.1
    • None
    • Stock Qt Creator 4.4.1, Windows 8.1 Pro x64, Desktop Qt 5.8.0 MSVC2015 32bit
    • 9488b7e604d081552a97f66fe08bbdd38be38e6b

    Description

      In my Qbs project file I install "hello.txt" in the same directory as the executable, but if I try to read it from my application before I click Projects/Run, it's not found because the working directory is not set; after I click Projects/Run, my application can find the file.
      I looked into it and Qt Creator doesn't write the Qbs.RunConfiguration.WorkingDirectory.default property to the project settings file until after I click Projects/Run in Run Settings. I have attached:

      • A minimal project tree;
      • The project settings file before I click Projects/Run;
      • The project settings file after I click Projects/Run.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kandeler Christian Kandeler
            georger.araujo Georger Araujo
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes