mylonics / zephyr-ide

Apache License 2.0
26 stars 5 forks source link

Provide an example project repository #63

Closed andre-stefanov closed 2 weeks ago

andre-stefanov commented 1 month ago

At the moment i am struggling to setup a zephyr-ide project repository because of following issues/questions:

An example application like https://github.com/zephyrproject-rtos/example-application would be very helpful to make usage of this extension much easier.

rijesha commented 1 month ago

I can look into this, I am thinking of automatically generating a .gitignore file. Currently you should only commit launch.json, vscode.json, .west/config, and project directories.

Can you provide the repository where this failed? "initialize from repository? This fails for me with FATAL ERROR: can't init: no west.yml found in /home/andre/repos/my-project/.west/manifest-tmp"

andre-stefanov commented 1 month ago

nice! i've included files you mentioned and it worked. I also added application/west.yml because it defines required zepyhr version (v3.7.0 in my case).

andre-stefanov commented 1 month ago

As of the issue i mentioned:

  1. open vscode in an empty folder
  2. in "extension setup" click on "workspace"
  3. initialize workspace
  4. from git repo
  5. use https://github.com/andre-stefanov/zephyr-ide-test.git
  6. (additional issue) the extension thinks that .venv already exists and asks to reinitialize
=== Initializing in /tmp/zephyr-ide-test
--- Cloning manifest repository from https://github.com/andre-stefanov/zephyr-ide-test.git
Cloning into '/tmp/zephyr-ide-test/.west/manifest-tmp'...
remote: Enumerating objects: 28, done.
remote: Counting objects: 100% (28/28), done.
remote: Compressing objects: 100% (17/17), done.
remote: Total 28 (delta 5), reused 28 (delta 5), pack-reused 0 (from 0)
Receiving objects: 100% (28/28), 4.34 KiB | 4.34 MiB/s, done.
Resolving deltas: 100% (5/5), done.
FATAL ERROR: can't init: no west.yml found in /tmp/zephyr-ide-test/.west/manifest-tmp
  Hint: check --manifest-url=https://github.com/andre-stefanov/zephyr-ide-test.git  You may need to remove /tmp/zephyr-ide-test/.west before retrying.

 *  The terminal process "/usr/bin/zsh '-c', 'west init -m https://github.com/andre-stefanov/zephyr-ide-test.git '" terminated with exit code: 1. 
 *  Terminal will be reused by tasks, press any key to close it. 

what on the other hand did work (with a small issue):

  1. git clone https://github.com/andre-stefanov/zephyr-ide-test.git && code zephyr-ide-test
  2. Now extension setup is displaying cached information of previously checked out project in this folder.
  3. reset workspace settings to get rid of cached project information, otherwise initialize option is not provided
  4. workspace
  5. initialize workspace
  6. select west.yml in workspace: application/west.yml in the workspace
  7. extensions asks if i want to reinitialize .venv (which definitely does not exist in the repository)
rijesha commented 2 weeks ago

Added automatic .gitignore generation. Added a sample project and referenced it in manual and readme.

Thanks for the issue