michael127001

Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • in reply to: template {{ENTER}} question #32782
    michael127001
    Participant

    I assume you are editing a cpp file in a VisualGDB project. I see what you mean that the next newline after typing template {{ is indented to the same length as the end of the word template. I thought you were typing ENTER literally at first 😅

    You can edit the clang-formatting settings at the document icon in the upper-right corner of the open source file:

    Clang-formatting in upper-right of source file

    I couldn’t find the exact setting to fix your issue, but you might find it in there. You can also try different formatting styles based on chromium, mozilla, google, etc. or disable the formatting entirely. I usually prefer to format on save or manually anyway.

    in reply to: SSH Connection Failure Locks Project #32763
    michael127001
    Participant

    Wow, thanks for the tip! I’ve been trying to figure out how to reference my VM by name for a while now 😁

    in reply to: SSH Connection Failure Locks Project #32760
    michael127001
    Participant

    I believe I have nailed the source of error. You are correct in that “many VisualGDB issues are caused by selecting an incompatible combination of settings at some point.” Though, I think this warrants a fix of sorts. The source of the issue comes from Synchronized Directories where, if set to sync on opening the project, VisualGDB gets stuck in a loop attempting to connect and synchronize, even if many attempts have failed. Steps:

    1. Create a new Visual Studio 2022 project with VisualGDB Linux Project Wizard template:

      <hr />

    2. Create a new SSH connection when setting remote computer:

      <hr />

    3. Save host key
    4. Fix mismatching environment:

      <hr />

    5. Set source files directory (I think source code access can be set to default):

      <hr />

    6. Finish project setup. At this point Visual Studio can run and debug “Hello, World!” on the Virtual Machine (at this point I think it is remote source agnostic)
    7. Add shared folder:

      <hr />

    8. Exit Visual Studio and re-assign IP (or disconnect) remote source
    9. Open Visual Studio and load solution
    10. Visual Studio attempts to connect:

      <hr />

    11. Clicking OK then Cancel opens a dialog box saying the operation was cancelled
    12. Clicking OK in that dialog box in under 15 seconds goes to this dialog:

      <hr />

    13. Clicking (14.) after 15 seconds goes back to (12.)
    14. Clicking (15.) after 15 seconds goes back to (12.)
    15. Clicking (15.) under 15 seconds goes back to (15.)
    16. Repeat (12.) and (15.) ad. infinitum (kill with Task Manager to exit)

     

    Fortunately I have found a workaround! In a different VisualGDB project I loaded the project settings and deleted the remote source for the repo I am trying to fix:

    Then when I load my original project I get the prompt to set the remote host again:

    <hr />

     

    Hopefully this is enough information to reproduce the error. It would be nice if after a couple attempts of failing to SSH in and sync directories the Resolve Project Load Issues dialog was available.

     

    Thanks!

    in reply to: SSH Connection Failure Locks Project #32757
    michael127001
    Participant

    Hi- thanks for the reply.

    I was never able to ping a hostname (which is also the Hyper-V name) of the VM i.e. “ping centos7”.  However, I can ping and SSH in at its IP 192.168.x.x, which is how I set the project up. The IP starts with 172.x.x.x in my screenshots, so the IP definitely changed. At some point I had to swap the network switch from an internal to external network which may have forced this change, along with DHCP. Using the previous internal switch generates a new 172 address, but not the same as what VisualGDB is trying to connect to.

    I had issues trying to order a static IP to the VM that VisualGDB is trying to connect, so I really believed I could just edit the VisualGDB project properties any time the IP changed. As far as I can tell, I have the following options:

    • Continue trying to order the IP of the VM to match what VisualGDB is trying to connect to.
    • Edit the VisualGDB project properties somehow.
    • Setup a new project.

    Any advice?

Viewing 4 posts - 1 through 4 (of 4 total)