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

Create github workflow for the subtopology autocoder #2794

Open
wants to merge 6 commits into
base: devel
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 87 additions & 0 deletions .github/workflows/ext-build-subtopology-ac.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
# Runs the subtopology autocoder tool to test the subtopology tool (https://github.com/mosa11aei/fprime-subtopology-tool)

Check failure on line 1 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`subtopology` is not a recognized word. (unrecognized-spelling)

Check failure on line 1 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`subtopology` is not a recognized word. (check-file-path)

Check failure on line 1 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`subtopology` is not a recognized word. (unrecognized-spelling)

name: "Subtopology Autocoder Tool Test"

Check failure on line 3 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`Subtopology` is not a recognized word. (unrecognized-spelling)

on:
push:
branches: [ devel, release/** ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ devel, release/** ]
paths-ignore:
- 'docs/**'
- '**.md'
- '.github/actions/spelling/**'
- '.github/ISSUE_TEMPLATE/**'

jobs:
get-branch:
name: "Get target branch"
uses: ./.github/workflows/reusable-get-pr-branch.yml
with:
target_repository: mosa11aei/fprime-rngLibrary

Check failure on line 22 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`aei` is not a recognized word. (unrecognized-spelling)

Check failure on line 22 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`mosa` is not a recognized word. (unrecognized-spelling)

subtopology-test:
name: "Subtopology Test"
runs-on: ubuntu-latest
needs: get-branch
steps:
- name: "Checkout target repository"
uses: actions/checkout@v4
with:
submodules: false
repository: mosa11aei/fprime-rngLibrary
ref: ${{ needs.get-branch.outputs.target-branch }}
- name: "Overlay current F´ revision"
uses: actions/checkout@v4
with:
submodules: true
path: ./fprime
fetch-depth: 0
- uses: ./fprime/.github/actions/setup
with:
location: ./fprime
- name: "Verify CMake is installed"
run: |
sudo apt-get update
sudo apt-get install -y cmake
- name: "Get FPP"
uses: actions/checkout@v4
with:
submodules: false
repository: nasa/fpp
path: ./fpp
ref: main
- name: "[fpp] Install sbt"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Get rid of non native fpp install

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mosa11aei if it were me I would get rid of all the installs, since all those tools come pre-installed on the GitHub runners. This may prevent breakages in the future. Your call.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This specifically relates to something @LeStarch and I talked about today. See #2816 😉

run: |
sudo apt-get update
sudo apt-get install -y apt-transport-https curl gnupg -yqq

Check failure on line 58 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`yqq` is not a recognized word. (unrecognized-spelling)
echo "deb https://repo.scala-sbt.org/scalasbt/debian all main" | sudo tee /etc/apt/sources.list.d/sbt.list
echo "deb https://repo.scala-sbt.org/scalasbt/debian /" | sudo tee /etc/apt/sources.list.d/sbt_old.list
curl -sL "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x2EE0EA64E40A89B84B2DF73499E82A75642AC823" | sudo -H gpg --no-default-keyring --keyring gnupg-ring:/etc/apt/trusted.gpg.d/scalasbt-release.gpg --import

Check failure on line 61 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`gpg` is not a recognized word. (unrecognized-spelling)

Check failure on line 61 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`keyring` is not a recognized word. (unrecognized-spelling)

Check failure on line 61 in .github/workflows/ext-build-subtopology-ac.yml

View workflow job for this annotation

GitHub Actions / Spell checking

`scalasbt` is not a recognized word. (unrecognized-spelling)
sudo chmod 644 /etc/apt/trusted.gpg.d/scalasbt-release.gpg
mosa11aei marked this conversation as resolved.
Show resolved Hide resolved
sudo apt-get update
sudo apt-get install -y sbt default-jre
- name: "Install unreleased fpp"
run: |
chmod +x ./fpp/compiler/install
./fpp/compiler/install /usr/local/bin/
- name: "Checkout subtopology tool"
uses: actions/checkout@v4
with:
submodules: false
path: ./fprime-subtopology-tool
repository: mosa11aei/fprime-subtopology-tool
ref: main
- name: "Go to Deployment Directory"
run: |
cd ./MainDeployment
- name: "Generate Subtopology Example Build Cache"
run: |
fprime-util generate -DFPRIME_SKIP_TOOLS_VERSION_CHECK=ON -DCMAKE_DEBUG_OUTPUT=ON
mosa11aei marked this conversation as resolved.
Show resolved Hide resolved
- name: "Build Example"
run: |
fprime-util build -v
mosa11aei marked this conversation as resolved.
Show resolved Hide resolved
- name: "Exit Deployment Directory"
run: |
cd ..
Loading