Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-110908

[Qt Contribution] incorrect error message by git commit -a

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Invalid
    • Not Evaluated
    • None
    • 6.5.0 Beta2
    • Build System
    • None
    • All

    Description

      I try to contribute into Qt. My steps

      git clone git://code.qt.io/qt/qt5.git qt5
      cd qt5
      perl init-repository
      git checkout -b my-fix origin/dev
      #make changes in qt5/qtdoc/doc/src/platforms/configure-linux-device.qdoc 
      

      But after

       

      qt5$ git commit -a
      On branch next-big-thing
      Changes not staged for commit:
        (use "git add <file>..." to update what will be committed)
        (use "git restore <file>..." to discard changes in working directory)
        (commit or discard the untracked or modified content in submodules)
          modified:   qtdoc (modified content)
      no changes added to commit (use "git add" and/or "git commit -a")
      

      In fact my problem was another. I spend a lot of time for reading not correct error message. In fact before git commit -a I forgot

       

      qt5$ cd qtdoc

       

      I suggest to add some extra check and good error message in my case.

      This is right steps for committing:

      git clone git://code.qt.io/qt/qt5.git qt5
      cd qt5
      perl init-repository
      git checkout -b my-fix origin/dev
      #make changes in qt5/qtdoc/doc/src/platforms/configure-linux-device.qdoc  
      cd qtdoc
      git commit -a

       

      P.S. Also there is another bad error message in case

      qt5/qtdoc$ git gpush --branch dev
      Notice: HEAD has no upstream remote; defaulting to origin.
      Attempted to push 1 loose Change(s):
        Id13302d69 (Change cmake set() to cmake_path())
      Please specify exact ranges.

      In fact I should use

      qt5/qtdoc$ git gpush --branch dev ..

      But how user can understand it reading error message?

      Attachments

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

        Activity

          People

            qtbuildsystem Qt Build System Team
            dungeonlords Andrei Cherniaev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes