From 5f3c6f91e64db7f6304729f109ecee84f4bec831 Mon Sep 17 00:00:00 2001 From: "Larry Smith Jr." Date: Sat, 13 Jan 2024 08:25:31 -0500 Subject: [PATCH] Ansible galaxy version is out of date Fixes #41 --- .github/config.yml | 14 ++++++++++ .github/release-drafter.yml | 32 ++++++++++++++++++++++ .github/settings.yml | 13 +++++++++ .github/stale.yml | 17 ++++++++++++ .github/workflows/release-drafter.yml | 17 ++++++++++++ .github/workflows/release-galaxy.yml | 38 +++++++++++++++++++++++++++ 6 files changed, 131 insertions(+) create mode 100644 .github/config.yml create mode 100644 .github/release-drafter.yml create mode 100644 .github/settings.yml create mode 100644 .github/stale.yml create mode 100644 .github/workflows/release-drafter.yml create mode 100644 .github/workflows/release-galaxy.yml diff --git a/.github/config.yml b/.github/config.yml new file mode 100644 index 0000000..47ca920 --- /dev/null +++ b/.github/config.yml @@ -0,0 +1,14 @@ +# Configuration for request-info - https://github.com/behaviorbot/request-info + +# *Required* Comment to reply with +requestInfoReplyComment: > + We would appreciate it if you could provide us with more info about this issue/pr! + +# *OPTIONAL* default titles to check against for lack of descriptiveness +# MUST BE ALL LOWERCASE +requestInfoDefaultTitles: + - update readme.md + - updates + +# *OPTIONAL* Label to be added to Issues and Pull Requests with insufficient information given +requestInfoLabelToAdd: needs-more-info diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml new file mode 100644 index 0000000..5d89759 --- /dev/null +++ b/.github/release-drafter.yml @@ -0,0 +1,32 @@ +name-template: "v$RESOLVED_VERSION ๐ŸŒˆ" +tag-template: "v$RESOLVED_VERSION" +categories: + - title: "๐Ÿš€ Features" + labels: + - "feature" + - "enhancement" + - title: "๐Ÿ› Bug Fixes" + labels: + - "fix" + - "bugfix" + - "bug" + - title: "๐Ÿงฐ Maintenance" + label: "chore" + - title: "๐Ÿงบ Miscellaneous" #Everything except ABAP + label: "misc" +change-template: "- $TITLE @$AUTHOR (#$NUMBER)" +change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks. +version-resolver: + major: + labels: + - "major" + minor: + labels: + - "minor" + patch: + labels: + - "patch" + default: patch +template: | + ## Changes + $CHANGES diff --git a/.github/settings.yml b/.github/settings.yml new file mode 100644 index 0000000..8c2f7b6 --- /dev/null +++ b/.github/settings.yml @@ -0,0 +1,13 @@ +# These settings are synced to GitHub by https://probot.github.io/apps/settings/ + +repository: + # See https://developer.github.com/v3/repos/#edit for all available settings. + + # The name of the repository. Changing this will rename the repository + name: ansible-netplan + + # A short description of the repository that will show up on GitHub + description: Ansible role to manage Netplan + + # A comma-separated list of topics to set on the repository + topics: ansible, ansible-role diff --git a/.github/stale.yml b/.github/stale.yml new file mode 100644 index 0000000..dc90e5a --- /dev/null +++ b/.github/stale.yml @@ -0,0 +1,17 @@ +# Number of days of inactivity before an issue becomes stale +daysUntilStale: 60 +# Number of days of inactivity before a stale issue is closed +daysUntilClose: 7 +# Issues with these labels will never be considered stale +exemptLabels: + - pinned + - security +# Label to use when marking an issue as stale +staleLabel: wontfix +# Comment to post when marking an issue as stale. Set to `false` to disable +markComment: > + This issue has been automatically marked as stale because it has not had + recent activity. It will be closed if no further activity occurs. Thank you + for your contributions. +# Comment to post when closing a stale issue. Set to `false` to disable +closeComment: false diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml new file mode 100644 index 0000000..689fc73 --- /dev/null +++ b/.github/workflows/release-drafter.yml @@ -0,0 +1,17 @@ +name: Release Drafter + +on: + push: + # branches to consider in the event; optional, defaults to all + branches: + - main + - master + +jobs: + update_release_draft: + runs-on: ubuntu-latest + steps: + # Drafts your next Release notes as Pull Requests are merged into "master" + - uses: release-drafter/release-drafter@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release-galaxy.yml b/.github/workflows/release-galaxy.yml new file mode 100644 index 0000000..6f41447 --- /dev/null +++ b/.github/workflows/release-galaxy.yml @@ -0,0 +1,38 @@ +--- +name: Ansible Galaxy +on: + push: + branches: + - main + - master + release: + types: + - published + +jobs: + galaxy: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: [3.9] + steps: + - uses: actions/checkout@v3 + with: + submodules: recursive + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + - uses: actions/cache@v2 + with: + path: ~/.cache/pip + key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements*.txt') }} + restore-keys: | + ${{ runner.os }}-pip- + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt -r requirements-dev.txt + pip install pre-commit + - name: Trigger a new import on Galaxy. + run: ansible-galaxy role import --api-key ${{ secrets.GALAXY_API_KEY }} $(echo ${{ github.repository }} | cut -d/ -f1) $(echo ${{ github.repository }} | cut -d/ -f2)