{"action":"created","issue":{"url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/320","repository_url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins","labels_url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/320/labels{/name}","comments_url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/320/comments","events_url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/320/events","html_url":"https://github.com/gnu-mcu-eclipse/eclipse-plugins/issues/320","id":361271899,"node_id":"MDU6SXNzdWUzNjEyNzE4OTk=","number":320,"title":"Is it possible to have multi-line block statements in the launcher?","user":{"login":"AntonKrug","id":30338596,"node_id":"MDQ6VXNlcjMwMzM4NTk2","avatar_url":"https://avatars0.githubusercontent.com/u/30338596?v=4","gravatar_id":"","url":"https://api.github.com/users/AntonKrug","html_url":"https://github.com/AntonKrug","followers_url":"https://api.github.com/users/AntonKrug/followers","following_url":"https://api.github.com/users/AntonKrug/following{/other_user}","gists_url":"https://api.github.com/users/AntonKrug/gists{/gist_id}","starred_url":"https://api.github.com/users/AntonKrug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AntonKrug/subscriptions","organizations_url":"https://api.github.com/users/AntonKrug/orgs","repos_url":"https://api.github.com/users/AntonKrug/repos","events_url":"https://api.github.com/users/AntonKrug/events{/privacy}","received_events_url":"https://api.github.com/users/AntonKrug/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-18T12:07:04Z","updated_at":"2018-09-18T12:09:02Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"### Description\r\n\r\nThe GME launchers allow adding few commands to the initialization and run/restart. But it seems that they do not allow the multi-line block statements. Single line statements get executed without issue, but a **if** condition or **while** loop which are in multiple lines and need the whole block to function correctly do not work from the launcher.\r\n\r\nIn the end more complex behaviour can be added to the gdbinit as a defined function and only called from the launcher when needed. And that works well, but I wonder if this is by design or it's a symptom that the commands are sent one by one to the gdb?\r\n\r\n### Steps to Reproduce\r\n\r\n1. Enable GDB traces: Windows -> Preferences -> C/C++ -> Debug -> GDB -> Show the GDB traces consoles with character limit (default value of characters should be enough)\r\n1. Use regular launcher of a working project (in my case RISCV, but I think this is not target specific).\r\n2. Go to launcher settings -> Startup tab\r\n3. In the \"Initilization Commands\" type the following:\r\n\r\n```\r\nif (1)\r\n  print \"if condition true\"\r\nend\r\n```\r\n\r\n3.  Click debug and open the GDB traces console\r\n\r\n**Expected behaviour:** \r\nGet the condition to be executed correctly:\r\n\r\n```\r\n654,867 ~\"$1 = \\\"if condition true\\\"\"\r\n```\r\n\r\n**Actual behaviour:** \r\nThe launcher gets stuck the moment it reaches the block statement:\r\n\r\n```\r\n750,171 &\"if (1)\\n\"\r\n750,171 ~\" >\"\r\n750,172 ~\" >\"\r\n750,172 ~\" >\"\r\n750,177 ~\" >\"\r\n750,181 ~\" >\"\r\n750,182 ~\" >\"\r\n```\r\n\r\n### Versions\r\n\r\n* GME 4.4.1-201807211108\r\n* Eclipse Photon 4.8\r\n* Java 10\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/comments/422366925","html_url":"https://github.com/gnu-mcu-eclipse/eclipse-plugins/issues/320#issuecomment-422366925","issue_url":"https://api.github.com/repos/gnu-mcu-eclipse/eclipse-plugins/issues/320","id":422366925,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMjM2NjkyNQ==","user":{"login":"ilg-ul","id":362732,"node_id":"MDQ6VXNlcjM2MjczMg==","avatar_url":"https://avatars3.githubusercontent.com/u/362732?v=4","gravatar_id":"","url":"https://api.github.com/users/ilg-ul","html_url":"https://github.com/ilg-ul","followers_url":"https://api.github.com/users/ilg-ul/followers","following_url":"https://api.github.com/users/ilg-ul/following{/other_user}","gists_url":"https://api.github.com/users/ilg-ul/gists{/gist_id}","starred_url":"https://api.github.com/users/ilg-ul/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ilg-ul/subscriptions","organizations_url":"https://api.github.com/users/ilg-ul/orgs","repos_url":"https://api.github.com/users/ilg-ul/repos","events_url":"https://api.github.com/users/ilg-ul/events{/privacy}","received_events_url":"https://api.github.com/users/ilg-ul/received_events","type":"User","site_admin":false},"created_at":"2018-09-18T12:09:02Z","updated_at":"2018-09-18T12:09:02Z","author_association":"CONTRIBUTOR","body":"How do you suggest to implememt such a feature?"}}
{"actor":{"display_login":"ilg-ul"}}