Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature/sc-77462/project-commands #2543

Merged
merged 1 commit into from
Sep 28, 2022

Conversation

busticated
Copy link
Contributor

@busticated busticated commented Sep 26, 2022

Problem

The prtcl CLI now includes support for project-related build commands. The current compile, flash, and clean commands will be deprecated and removed

Solution

Move the test-build-system CI workflow over to the new project:compile and project:clean commands

Steps to Test

  1. Using macOS...
  2. Install the prtcl CLI (instructions)
  3. Run the CI test script:
    • cd /path/to/device-os
    • ./ci/test-build-tasks.sh ./
  4. Using linux (Ubuntu)...
  5. Install the prtcl CLI (instructions)
  6. Run the CI test script:
    • cd /path/to/device-os
    • ./ci/test-build-tasks.sh ./
  7. Using Windows + Powershell...
  8. Install the prtcl CLI (instructions)
  9. Run the CI test script:
    • cd C:\\path\to\device-os
    • .\ci\test-build-tasks.ps1 .\
  10. Observe the latest CI run in CircleCI

outcome

Scripts should run properly - exiting on error and otherwise reporting success. CI configuration changes should make sense and do what you expect.

References

https://app.shortcut.com/particle/story/77462


Completeness

  • User is totes amazing for contributing!
  • Contributor has signed CLA (Info here)
  • Problem and Solution clearly stated
  • Run unit/integration/application tests on device
  • Added documentation
  • Added to CHANGELOG.md after merging (add links to docs and issues)

… commands

from:

    ```
    prtcl compile:all source:/path/to/device-os argon /path/to/tinker --quiet
    ```

to:

    ```
    prtcl project:compile /path/to/tinker --toolchain source:/path/to/device-os argon --platform argon --task all --quiet
    ```
@busticated busticated force-pushed the feature/sc-77462/project-commands branch 2 times, most recently from f741ff9 to 9d6e22b Compare September 28, 2022 17:26
@busticated busticated marked this pull request as ready for review September 28, 2022 17:34
@scott-brust
Copy link
Member

scott-brust commented Sep 28, 2022

I ran this locally with the latest prtcl and it seemed to work as expected

➜  ci git:(feature/sc-77462/project-commands) ✗ ./test-build-tasks.sh ../ p2
:::: Using prtcl v1.8.0
:::: Using Device OS at: ../
:::: Targeting platforms: p2
:::: Running task pairs: compile:user clean:user compile:all clean:all compile:debug clean:debug
Toolchain was previously installed
:::: Testing build tasks for p2

✔ Compiling project: undefined
✔ Using toolchain for deviceOS@source and p2...
- - - -
Running build task: "compile-user" for deviceOS@source [p2] against /Users/scottbrust/develop/device-os/user/applications/tinker/
- -

:::: COMPILING APPLICATION
...snip...

*** COMPILED SUCCESSFULLY ***

✔ Cleaning project: undefined
✔ Using toolchain for deviceOS@source and p2...
- - - -
Running build task: "clean-debug" for deviceOS@source [p2] against /Users/scottbrust/develop/device-os/user/applications/tinker/
- -

:::: CLEANING APPLICATION FOR DEBUG


*** CLEANED SUCCESSFULLY ***

:::: done!

Does test-build-tasks.sh run in CI somewhere with each build?

@scott-brust scott-brust self-requested a review September 28, 2022 18:37
@busticated
Copy link
Contributor Author

@scott-brust

Does test-build-tasks.sh run in CI somewhere with each build?

yes, see here and here. the test-build-system workflow runs when these branches are updated 👍

@busticated busticated merged commit 17cbdef into develop Sep 28, 2022
@busticated busticated deleted the feature/sc-77462/project-commands branch September 28, 2022 18:42
@scott-brust scott-brust added this to the 5.1.0 milestone Sep 28, 2022
scott-brust pushed a commit that referenced this pull request Oct 12, 2022
@scott-brust scott-brust mentioned this pull request Oct 17, 2022
@scott-brust scott-brust mentioned this pull request Nov 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants