Skip to content

Commit

Permalink
Initial open source commit
Browse files Browse the repository at this point in the history
  • Loading branch information
dinkelk committed Nov 13, 2023
0 parents commit ef17194
Show file tree
Hide file tree
Showing 308 changed files with 10,415 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/alire/
.git
.unison*
**/build
**/.tar
52 changes: 52 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Make sure detected text files are stored with LF, since all these
# files need to work in a Linux VM. Windows users should install a
# text editor that can work with Unix line endings.
# Make everything auto that doesn't have a file extension. This ignores
# LF in binary files and the like that don't have extensions.
* text=auto
# Any text file with an extension we want to force UNIX LF.
*.* text eol=lf

# Make sure that git recognizes the following as
# text files that should have LFs.
*.txt text eol=lf
*.sh text eol=lf
*.do text eol=lf
*.txt text eol=lf
*.c text eol=lf
*.h text eol=lf
*.cpp text eol=lf
*.hpp text eol=lf
*.adb text eol=lf
*.ads text eol=lf
*.md text eol=lf
*.py text eol=lf
*.html text eol=lf
*.htm text eol=lf
*.tex text eol=lf
*.yaml text eol=lf
*.dot text eol=lf
*.xml text eol=lf
*.csv text eol=lf
*.json text eol=lf
.gitignore text eol=lf
.gitattributes text eol=lf
Vagrantfile text eol=lf

# These files are binary and should be left untouched
# (binary is a macro for -text -diff)
*.pptx binary
*.ppt binary
*.doc binary
*.docx binary
*.xls binary
*.xlsx binary
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.ico binary
*.gz binary
*.zip binary
*.pyc binary
*.pdf binary
47 changes: 47 additions & 0 deletions .github/workflows/build_linux.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Build the Linux Assembly
on:
push:
branches:
- master
workflow_dispatch:
jobs:
compile_job:
name: build_linux_assembly
runs-on: ubuntu-latest
container:
image: dinkelk/adamant:example-latest
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
env:
INSTALL_DIR: /home/user/env
EXAMPLE_DIR: ${{ github.workspace }}/example
ADAMANT_DIR: ${{ github.workspace }}/adamant
steps:
- run: echo "Starting job triggered by a ${{ github.event_name }} event on a ${{ runner.os }} server hosted by GitHub."
- run: echo "Checking out ${{ github.repository }} on branch ${{ github.ref }}."
- name: Check out repository code
uses: actions/checkout@v3
with:
set-safe-directory: true
path: example
- name: Clone adamant repository
uses: actions/checkout@v3
with:
set-safe-directory: true
repository: lasp/adamant
token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
path: adamant
ref: ${{ github.ref }}
- name: Get Adamant alire dependencies
run: alr -n build --release && alr -n toolchain --select gnat_native && alr -n toolchain --select gprbuild
working-directory: ${{ env.ADAMANT_DIR }}
- name: Build the Linux binary
run: bash example/docker/env/github_run.sh "redo example/src/assembly/linux/main/build/bin/Linux/main.elf"
- name: Archive Linux binary
uses: actions/upload-artifact@v3
with:
name: linux_elf
path: example/src/assembly/linux/main/build/bin/Linux/main.elf
if-no-files-found: error
- run: echo "Finished with status - ${{ job.status }}."
52 changes: 52 additions & 0 deletions .github/workflows/build_pico.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build the Pico Assembly
on:
push:
branches:
- master
workflow_dispatch:
jobs:
compile_job:
name: build_pico_assembly
runs-on: ubuntu-latest
container:
image: dinkelk/adamant:example-latest
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
env:
INSTALL_DIR: /home/user/env
EXAMPLE_DIR: ${{ github.workspace }}/example
ADAMANT_DIR: ${{ github.workspace }}/adamant
steps:
- run: echo "Starting job triggered by a ${{ github.event_name }} event on a ${{ runner.os }} server hosted by GitHub."
- run: echo "Checking out ${{ github.repository }} on branch ${{ github.ref }}."
- name: Check out repository code
uses: actions/checkout@v3
with:
set-safe-directory: true
path: example
- name: Clone adamant repository
uses: actions/checkout@v3
with:
set-safe-directory: true
repository: lasp/adamant
token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
path: adamant
ref: ${{ github.ref }}
- name: Get Adamant alire dependencies
run: alr -n build --release && alr -n toolchain --select gnat_native && alr -n toolchain --select gprbuild
working-directory: ${{ env.ADAMANT_DIR }}
- name: Get example alire dependencies
run: alr -n build --release
working-directory: ${{ env.EXAMPLE_DIR }}
- name: Build the Pico binary
run: bash example/docker/env/github_run.sh "redo example/src/assembly/pico/main/build/bin/Pico/main.uf2"
- name: Archive Pico binary
uses: actions/upload-artifact@v3
with:
name: pico_elf
path: |
example/src/assembly/pico/main/build/bin/Pico/main.elf
example/src/assembly/pico/main/build/bin/Pico/main.uf2
if-no-files-found: error
- run: echo "Finished with status - ${{ job.status }}."
45 changes: 45 additions & 0 deletions .github/workflows/publish_all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Build All Documentation
on:
push:
branches:
- master
workflow_dispatch:
jobs:
compile_job:
name: test_all
runs-on: ubuntu-latest
container:
image: dinkelk/adamant:example-latest
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
env:
INSTALL_DIR: /home/user/env
EXAMPLE_DIR: ${{ github.workspace }}/example
ADAMANT_DIR: ${{ github.workspace }}/adamant
steps:
- run: echo "Starting job triggered by a ${{ github.event_name }} event on a ${{ runner.os }} server hosted by GitHub."
- run: echo "Checking out ${{ github.repository }} on branch ${{ github.ref }}."
- name: Check out repository code
uses: actions/checkout@v3
with:
set-safe-directory: true
path: example
- name: Clone adamant repository
uses: actions/checkout@v3
with:
set-safe-directory: true
repository: lasp/adamant
token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
path: adamant
ref: ${{ github.ref }}
- name: Get Adamant alire dependencies
run: alr -n build --release && alr -n toolchain --select gnat_native && alr -n toolchain --select gprbuild
working-directory: ${{ env.ADAMANT_DIR }}
- name: Get example alire dependencies
run: alr -n build --release
working-directory: ${{ env.EXAMPLE_DIR }}
- name: Build all documentation
run: bash example/docker/env/github_run.sh "redo example/publish"
- run: echo "Finished with status - ${{ job.status }}."
if: always()
51 changes: 51 additions & 0 deletions .github/workflows/style_all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Check Style
on:
push:
branches:
- master
workflow_dispatch:
jobs:
compile_job:
name: style_all
runs-on: ubuntu-latest
container:
image: dinkelk/adamant:example-latest
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
env:
INSTALL_DIR: /home/user/env
EXAMPLE_DIR: ${{ github.workspace }}/example
ADAMANT_DIR: ${{ github.workspace }}/adamant
steps:
- run: echo "Starting job triggered by a ${{ github.event_name }} event on a ${{ runner.os }} server hosted by GitHub."
- run: echo "Checking out ${{ github.repository }} on branch ${{ github.ref }}."
- name: Check out repository code
uses: actions/checkout@v3
with:
set-safe-directory: true
path: example
- name: Clone adamant repository
uses: actions/checkout@v3
with:
set-safe-directory: true
repository: lasp/adamant
token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
path: adamant
ref: ${{ github.ref }}
- name: Get Adamant alire dependencies
run: alr -n build --release && alr -n toolchain --select gnat_native && alr -n toolchain --select gprbuild
working-directory: ${{ env.ADAMANT_DIR }}
- name: Get example alire dependencies
run: alr -n build --release
working-directory: ${{ env.EXAMPLE_DIR }}
- name: Check all style
run: bash example/docker/env/github_run.sh "redo example/style_all"
continue-on-error: true
- name: Archive logs for failed style checks
uses: actions/upload-artifact@v3
with:
name: failed_style_logs
path: example/build/failed_style_logs
if-no-files-found: ignore
- run: echo "Finished with status - ${{ job.status }}."
51 changes: 51 additions & 0 deletions .github/workflows/test_all.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Run All Unit Tests
on:
push:
branches:
- master
workflow_dispatch:
jobs:
compile_job:
name: test_all
runs-on: ubuntu-latest
container:
image: dinkelk/adamant:example-latest
credentials:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
env:
INSTALL_DIR: /home/user/env
EXAMPLE_DIR: ${{ github.workspace }}/example
ADAMANT_DIR: ${{ github.workspace }}/adamant
steps:
- run: echo "Starting job triggered by a ${{ github.event_name }} event on a ${{ runner.os }} server hosted by GitHub."
- run: echo "Checking out ${{ github.repository }} on branch ${{ github.ref }}."
- name: Check out repository code
uses: actions/checkout@v3
with:
set-safe-directory: true
path: example
- name: Clone adamant repository
uses: actions/checkout@v3
with:
set-safe-directory: true
repository: lasp/adamant
token: ${{ secrets.GH_PAT }} # `GH_PAT` is a secret that contains your PAT
path: adamant
ref: ${{ github.ref }}
- name: Get Adamant alire dependencies
run: alr -n build --release && alr -n toolchain --select gnat_native && alr -n toolchain --select gprbuild
working-directory: ${{ env.ADAMANT_DIR }}
- name: Get example alire dependencies
run: alr -n build --release
working-directory: ${{ env.EXAMPLE_DIR }}
- name: Run all unit tests
run: bash example/docker/env/github_run.sh "redo example/test_all"
continue-on-error: true
- name: Archive logs for failed unit tests
uses: actions/upload-artifact@v3
with:
name: failed_test_logs
path: example/build/failed_test_logs
if-no-files-found: ignore
- run: echo "Finished with status - ${{ job.status }}."
19 changes: 19 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
build/
.vagrant
.Trash*
.pyenv/
*.pyc
__pycache__/
.tmp
.DS_Store
*.swp
GNAT-*
*.tmp
~$*
.unison*

# Standard alire ignores:
/alire/
/config/
!/config/README.md
!/config/example.configuration.yaml
Loading

0 comments on commit ef17194

Please sign in to comment.