<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/109658/in-nrf-connect-for-vscode-how-to-store-the-project-build-log-in-a-file</link><description>I would like to automatically save the contents of the log that `west` outputs to the terminal for a project build to a .log file; 
 When I click on `build` under the `action` column of `nrf connect for vscode`, I see that the code that is executed is</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 03 Apr 2024 07:22:46 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/109658/in-nrf-connect-for-vscode-how-to-store-the-project-build-log-in-a-file" /><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476754?ContentTypeID=1</link><pubDate>Wed, 03 Apr 2024 07:22:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:ee9ec40f-9156-45cd-8b11-4b53dffbd15f</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;Currently, you would need to write a new task for every build configuration.&amp;nbsp;&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476715?ContentTypeID=1</link><pubDate>Wed, 03 Apr 2024 01:11:22 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2532402e-2459-4a05-8bc8-f48c0af2d2ae</guid><dc:creator>emmovo</dc:creator><description>[quote userid="128557" url="~/f/nordic-q-a/109658/in-nrf-connect-for-vscode-how-to-store-the-project-build-log-in-a-file/476254"]&lt;p&gt;However, the cmd file that executes the west command in this way is written manually by me.&lt;/p&gt;
&lt;p&gt;In this way, I wrote the cmd file for executing west commands manually, and I would prefer to replace it with nrf connect for vscode, which uses the &amp;quot;Build: usb_hid_transparent/build (active)&amp;quot; task according to my configuration to save the output log to a file.&lt;/p&gt;[/quote]
&lt;p&gt;The difference between what I&amp;#39;ve realized so far, and what I want is here&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476535?ContentTypeID=1</link><pubDate>Tue, 02 Apr 2024 11:30:59 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8c4b2040-fdcb-474d-b666-3af4b6ab8583</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;Could you elaborate and show the difference of what you managed to achieve and what you prefer?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476254?ContentTypeID=1</link><pubDate>Thu, 28 Mar 2024 02:27:13 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9f9a1566-d80b-410f-96a2-88e46ea14f21</guid><dc:creator>emmovo</dc:creator><description>&lt;p&gt;I tried the following scenario&lt;/p&gt;
&lt;p&gt;Modify the Action Build pointers in nRF Connect for VScode.&lt;br /&gt;Add the task in &amp;quot;tasks.json&amp;quot; as follows&lt;/p&gt;
&lt;p&gt;&lt;!--mce:protected %3C%21--%20notionvc%3A%20162ca62c-7285-4dd1-8a90-5790887cef85%20--%3E--&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;{
    &amp;quot;version&amp;quot;: &amp;quot;2.0.0&amp;quot;,
    &amp;quot;tasks&amp;quot;: [
          {
              &amp;quot;label&amp;quot;: &amp;quot;build test&amp;quot;,
              &amp;quot;command&amp;quot;: &amp;quot;${workspaceFolder}/test.cmd&amp;quot;,
          }
      ]
  }&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Change the &amp;quot;taskName&amp;quot; of &amp;quot;build&amp;quot; to the name of our task, as follows:&lt;br /&gt;&lt;!--mce:protected %3C%21--%20notionvc%3A%20185399c5-3018-4fba-85b5-7253cc15cc7c%20--%3E--&gt;&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;{
    &amp;quot;nrf-connect.taskBindings&amp;quot;: {
        &amp;quot;build&amp;quot;: [
            {
                &amp;quot;taskName&amp;quot;: &amp;quot;build test&amp;quot;,
            },
        ]
    }
}&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Here is the contents of my test.cmd:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;SET PATH=C:/ncs/toolchains/cf2149caf2;C:/ncs/toolchains/cf2149caf2\mingw64\bin;C:/ncs/toolchains/cf2149caf2\bin;C:/ncs/toolchains/cf2149caf2\opt\bin;C:/ncs/toolchains/cf2149caf2\opt\bin\Scripts;C:/ncs/toolchains/cf2149caf2\opt\nanopb\generator-bin;C:/ncs/toolchains/cf2149caf2\opt\zephyr-sdk\aarch64-zephyr-elf\bin;C:/ncs/toolchains/cf2149caf2\opt\zephyr-sdk\x86_64-zephyr-elf\bin;C:/ncs/toolchains/cf2149caf2\opt\zephyr-sdk\arm-zephyr-eabi\bin;C:/ncs/toolchains/cf2149caf2\opt\zephyr-sdk\riscv64-zephyr-elf\bin;%PATH%
SET PYTHONPATH=C:/ncs/toolchains/cf2149caf2\opt\bin;C:/ncs/toolchains/cf2149caf2\opt\bin\Lib;C:/ncs/toolchains/cf2149caf2\opt\bin\Lib\site-packages
SET ZEPHYR_TOOLCHAIN_VARIANT=zephyr
SET ZEPHYR_SDK_INSTALL_DIR=C:/ncs/toolchains/cf2149caf2\opt\zephyr-sdk
SET ZEPHYR_BASE=C:/ncs/v2.6.0\zephyr
west build --build-dir D:/nordic/ncs_tutorial/code/Peripherals/15_usb/usb_hid_transparent/build D:/nordic/ncs_tutorial/code/Peripherals/15_usb/usb_hid_transparent --pristine --board nrf52840dk_nrf52840 --no-sysbuild -- -DNCS_TOOLCHAIN_VERSION=NONE -DCACHED_CONF_FILE=D:/nordic/ncs_tutorial/code/Peripherals/15_usb/usb_hid_transparent/prj.conf &amp;gt; build.log 2&amp;gt;&amp;amp;1
&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;In this way, I can realize that all the contents of west&amp;#39;s logs are output to the build.log file&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;However, the cmd file that executes the west command in this way is written manually by me.&lt;/p&gt;
&lt;p&gt;In this way, I wrote the cmd file for executing west commands manually, and I would prefer to replace it with nrf connect for vscode, which uses the &amp;quot;Build: usb_hid_transparent/build (active)&amp;quot; task according to my configuration to save the output log to a file.&lt;/p&gt;
&lt;p&gt;&lt;!--mce:protected %3C%21--%20notionvc%3A%209e766d75-846d-4e86-af4b-bf2316f42a3f%20--%3E--&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476108?ContentTypeID=1</link><pubDate>Wed, 27 Mar 2024 10:46:52 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:dfdf987c-0c5a-4376-bc7c-b385f4163c80</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;Could you show what you have tried so far? What are the results?&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/476022?ContentTypeID=1</link><pubDate>Wed, 27 Mar 2024 00:24:24 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4a4a8212-b803-4898-9a86-caecae346cef</guid><dc:creator>emmovo</dc:creator><description>&lt;p&gt;Thank you for your patience in replying, I&amp;#39;ve read it and learnt how to customise the build&amp;#39;s task and multiple tasks; however, I still haven&amp;#39;t found how to implement the output of the build process log to a file, I hope you can provide further support;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: In nrf connect for vscode, how to store the project build log in a file</title><link>https://devzone.nordicsemi.com/thread/475998?ContentTypeID=1</link><pubDate>Tue, 26 Mar 2024 16:11:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7f7de3dc-07d2-459a-8e01-60583f96ffe3</guid><dc:creator>dejans</dc:creator><description>&lt;p&gt;Hi,&lt;br /&gt;&lt;br /&gt;You could start by looking at &lt;a href="https://code.visualstudio.com/docs/editor/tasks"&gt;VS Code Tasks&lt;/a&gt; and &lt;a href="https://nrfconnect.github.io/vscode-nrf-connect/guides/build_bind_tasks.html#binding-custom-tasks-to-actions"&gt;Binding Custom Tasks to Actions&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Best regards,&lt;br /&gt;Dejan&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>