How to backup a nRF Connect SDK based project?

I'm new to nRF Connect SDK (Main repository version), I followed instructions and managed to build and run samples. (Linux Mint / Ubuntu OS here)

Followed the instructions to install nRF Connect SDK with WEST, I see it writes a 1.9 GByte folder with all nRF Connect SDK + Zephry + tons of other libraries I am not using.

I'm already using GIT to version control my application source code.

If I would like to make an hard backup of the project, managing that in future (years) I will be able to build it again, how should I proceed with this nRRF Connect SDK ?

I looks I will need to backup that 1.9GByte of data + project files? This sounds crazy as in the end I will need to eventually create a Virtual Machine with all environment setup?

What are the intermediate options?

  • Hi

    When you are building the final output (for example a hex file that will be programmed into your device), it is a combination of Zephyr OS, libraries and your application source code.

    The first two elements of the above drawing are managed by WEST and the latest one by you. And you want to freeze all these three element to generate same output at the future.

    Short answer is:

    You can store the commit number of the current Zephyr you are using in order to access the same source code of Zephyr in the future. WEST can manage to fetch a specific commit rather than the last version, for example.

    But, Please note:

    But anyway, maybe it is better to use the latest stable version instead of being stuck into a specific version. it is the nature of software, software is not like a stone, it is more like a tree, grows during the time Slight smile, so every time you want to build the software, you can use the latest version of the Zephyr, but it needs to take care of your application during the time to ensure it works well after updating the Zephyr.

    UPDATE:

    WEST tool can help you to manage reproducing the same Zephyr version and libraries you have used in your project at the moment. Indeed whatever you want to backup from Zephyr and its dependencies, is currently stored on Github, you only need a pointer to them in order to fetch them whenever you want. More information are available here:

    docs.zephyrproject.org/.../manifest.html

    And here is an example of an out-of-tree application that holds west.yml, which can be used to point to the Zephyr and its dependencies in order to build the application with the same source code at anytime. Please note how the project structure is:

    github.com/.../example-application

    BR,

    Saleh

Related