diff --git a/.github/workflows/BuildTest.yaml b/.github/workflows/BuildTest.yaml new file mode 100644 index 0000000..cbe258e --- /dev/null +++ b/.github/workflows/BuildTest.yaml @@ -0,0 +1,55 @@ +name: BuildTest + +on: + schedule: + - cron: 0 0 * * * + pull_request: + workflow_dispatch: + +jobs: + build_and_test: + name: Build + runs-on: ubuntu-20.04 + strategy: + fail-fast: false + matrix: + rosdistro : [foxy,galactic] + steps: + - uses: actions/checkout@v2-beta + - name: Check dependency-${{ matrix.rosdistro }}.repos existence + id: check_rosdistro_repos_files + uses: andstor/file-existence-action@v1 + with: + files: dependency-${{ matrix.rosdistro }}.repos + allow_failure: false + - name: Check dependency.repos existence + id: check_repos_files + uses: andstor/file-existence-action@v1 + with: + files: dependency.repos + allow_failure: false + - name: Run OUXT-Polaris/ros2-ci@master with dependency-${{ matrix.rosdistro }}.repos + uses: OUXT-Polaris/ros2-ci@master + if: steps.check_rosdistro_repos_files.outputs.files_exists == 'true' + with: + ros2-distro: ${{ matrix.rosdistro }} + repos-filepath: dependency-${{ matrix.rosdistro }}.repos + - name: Run OUXT-Polaris/ros2-ci@master with dependency.repos + uses: OUXT-Polaris/ros2-ci@master + if: steps.check_rosdistro_repos_files.outputs.files_exists == 'false' && steps.check_repos_files.outputs.files_exists == 'true' + with: + ros2-distro: ${{ matrix.rosdistro }} + repos-filepath: dependency.repos + - name: Run OUXT-Polaris/ros2-ci@master without repos + uses: OUXT-Polaris/ros2-ci@master + if: steps.check_rosdistro_repos_files.outputs.files_exists == 'false' && steps.check_repos_files.outputs.files_exists == 'false' + with: + ros2-distro: ${{ matrix.rosdistro }} + - name: Notify Slack + uses: 8398a7/action-slack@v2 + if: failure() + with: + status: ${{ job.status }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} \ No newline at end of file diff --git a/.github/workflows/Release.yaml b/.github/workflows/Release.yaml new file mode 100644 index 0000000..39b4218 --- /dev/null +++ b/.github/workflows/Release.yaml @@ -0,0 +1,68 @@ +# This file is automatically deployed from https://github.com/at-wat/.rospkg-assets. +# Please don't directly edit; update at-wat/.rospkg-assets instead. + +name: Release +on: + issues: + types: [opened, edited] + +jobs: + release: + runs-on: ubuntu-latest + if: startsWith(github.event.issue.title, 'Release ') + steps: + - name: checkout + uses: actions/checkout@v2 + - name: create release + id: create_release + uses: at-wat/catkin-release-action@v1 + with: + issue_title: ${{ github.event.issue.title }} + git_user: wam-v-tan + git_email: ouxt.share@gmail.com + github_token: ${{ secrets.GITHUB_TOKEN }} + - name: open pull-request + uses: repo-sync/pull-request@v2 + id: create_pull_request + with: + source_branch: ${{ steps.create_release.outputs.created_branch }} + destination_branch: ${{ github.event.repository.default_branch }} + pr_title: Release ${{ steps.create_release.outputs.version}} + pr_body: close \#${{ github.event.issue.number }} + pr_assignee: wam-v-tan + github_token: ${{ secrets.WAMV_TAN_BOT_SECRET }} + - name: Enable Pull Request Automerge + uses: peter-evans/enable-pull-request-automerge@v1 + with: + token: ${{ secrets.WAMV_TAN_BOT_SECRET }} + pull-request-number: ${{ steps.create_pull_request.outputs.pr_number }} + merge-method: squash + - name: create GitHub release + uses: actions/create-release@v1 + continue-on-error: true + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ steps.create_release.outputs.version}} + release_name: Release ${{ steps.create_release.outputs.version}} + - name: bloom release + if: github.event.label.name == 'bloom' + id: bloom + uses: at-wat/bloom-release-action@v0 + with: + ros_distro: foxy galactic rolling + github_token_bloom: ${{ secrets.WAMV_TAN_BOT_SECRET }} + github_user: wam-v-tan + git_user: wam-v-tan + git_email: ouxt.share@gmail.com + release_repository_push_url: https://github.com/${{ github.repository }}-release.git + tag_and_release: true + open_pr: true + - name: Notify Slack + uses: 8398a7/action-slack@v2 + if: failure() + with: + status: ${{ job.status }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} \ No newline at end of file diff --git a/.github/workflows/UpdateWorkflowStatus.yaml b/.github/workflows/UpdateWorkflowStatus.yaml new file mode 100644 index 0000000..68115b2 --- /dev/null +++ b/.github/workflows/UpdateWorkflowStatus.yaml @@ -0,0 +1,19 @@ +name: UpdateDashboard +on: + pull_request: + paths-ignore: + - ".github/workflows/UpdateWorkflowStatus.yaml" + workflow_dispatch: + +jobs: + build: + name: UpdateDashboard + runs-on: ubuntu-latest + steps: + - uses: benc-uk/workflow-dispatch@v1 + with: + # You should create a personal access token and store it in your repository + token: ${{ secrets.WAMV_TAN_BOT_SECRET }} + repo: OUXT-Polaris/ouxt_automation + workflow: document + ref: master \ No newline at end of file