Added size function #44
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Day1-Project0 | |
| on: | |
| push: | |
| branches: | |
| - main | |
| - DSDoublyLL | |
| jobs: | |
| build: | |
| name: ${{matrix.config.name}} | |
| runs-on: ${{matrix.config.os}} | |
| env: | |
| BUILD_TYPE: Release | |
| EXE_NAME: Data_Structures_Test | |
| ### ***** Put the name of the input files and output files here. | |
| ### List them in the order that they need to appear in Argv param of main. | |
| ### Output Files will follow input files | |
| ### Note: These should be the actual names of the files. No double quotes | |
| INPUT_FILES: ###INSERT INPUT FILE NAMES | |
| OUTPUT_FILES: ###INSERT OUTPUT FILE NAMES | |
| COMPILER: ${{matrix.config.compiler}} | |
| COMP: ${{matrix.config.comp}} | |
| CXXFLAGS: "-Werror" | |
| timeout-minutes: 3 | |
| strategy: | |
| matrix: | |
| config: | |
| - { | |
| name: "Ubuntu 20.04 GCC", | |
| os: ubuntu-20.04, | |
| compiler: g++, | |
| comp: gcc, | |
| shell: 'bash {0}' | |
| } | |
| defaults: | |
| run: | |
| shell: ${{matrix.config.shell}} | |
| steps: | |
| - name: Checkout project repo from GitHub | |
| uses: actions/checkout@v1 | |
| - name: Executable name Environment Variable Check | |
| run: | | |
| echo $EXE_NAME | |
| echo " " | |
| echo ${{runner.workspace}} | |
| echo " " | |
| echo $GITHUB_WORKSPACE | |
| echo " " | |
| g++ --version | |
| cmake --version | |
| - name: Create build environment | |
| run: mkdir ${{runner.workspace}}/build | |
| - name: Configure the build | |
| # Use a bash shell so we can use the same syntax for environment variable | |
| # access regardless of the host operating system | |
| shell: bash | |
| working-directory: ${{runner.workspace}}/build | |
| run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE | |
| - name: Build the project | |
| working-directory: ${{runner.workspace}}/build | |
| shell: bash | |
| # Execute the build. You can specify a specific target with "--target <NAME>" | |
| run: cmake --build . --config $BUILD_TYPE | |
| - name: Test build | |
| working-directory: ${{runner.workspace}}/build | |
| run: make -j2 optimize=no debug=yes > /dev/null | |
| - name: List contents of build directory | |
| run: ls -al ${{runner.workspace}}/build | |
| - name: Run the project | |
| working-directory: ${{runner.workspace}}/build | |
| shell: bash | |
| run: ./$EXE_NAME $INPUT_FILES $OUTPUT_FILES | |
| - name: Copy output files to artifact directory | |
| working-directory: ${{runner.workspace}}/build | |
| run: | | |
| mkdir artifacts | |
| for f in $OUTPUT_FILES | |
| do | |
| echo " Copying $f" | |
| cp $f artifacts/ | |
| done | |
| - name: Upload output files to GitHub so they can be reviewed | |
| uses: actions/upload-artifact@v1 | |
| with: | |
| name: project_output | |
| path: ${{runner.workspace}}/build/artifacts |