-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from DSACMS/outbound-docs
Add Source Code and Docs to gource-log GitHub Action
- Loading branch information
Showing
17 changed files
with
321 additions
and
127 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* | ||
!Dockerfile | ||
!entrypoint.py |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
## Issue Report | ||
|
||
module-name: One line summary of the issue (less than 72 characters) | ||
|
||
### Expected behavior | ||
|
||
As concisely as possible, describe the expected behavior. | ||
|
||
### Actual behavior | ||
|
||
As concisely as possible, describe the observed behavior. | ||
|
||
### Steps to reproduce the behavior | ||
|
||
List all relevant steps to reproduce the observed behavior. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<!-- | ||
Thank you for sending the PR! We appreciate you spending the time to work on | ||
these changes. | ||
Help us understand your motivation by explaining why you decided to make this change. | ||
Happy contributing! | ||
- Comments should be formatted to a width no greater than 80 columns. | ||
- Files should be exempt of trailing spaces. | ||
- We adhere to a specific format for commit messages. Please write your commit | ||
messages along these guidelines. Please keep the line width no greater than 80 | ||
columns (You can use `fmt -n -p -w 80` to accomplish this). | ||
--> | ||
|
||
## module-name: One line description of your change (less than 72 characters) | ||
|
||
## Problem | ||
|
||
Explain the context and why you're making that change. What is the problem | ||
you're trying to solve? In some cases there is not a problem and this can be | ||
thought of being the motivation for your change. | ||
|
||
## Solution | ||
|
||
Describe the modifications you've done. | ||
|
||
## Result | ||
|
||
What will change as a result of your pull request? Note that sometimes this | ||
section is unnecessary because it is self-explanatory based on the solution. | ||
|
||
Some important notes regarding the summary line: | ||
|
||
* Describe what was done; not the result | ||
* Use the active voice | ||
* Use the present tense | ||
* Capitalize properly | ||
* Do not end in a period — this is a title/subject | ||
* Prefix the subject with its scope | ||
|
||
## Test Plan | ||
|
||
(Write your test plan here. If you changed any code, please provide us with | ||
clear instructions on how you verified your changes work.) |
File renamed without changes.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "docker" | ||
directory: "/" | ||
target-branch: "main" | ||
schedule: | ||
interval: "daily" | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
target-branch: "main" | ||
schedule: | ||
interval: "daily" |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Merge main into dev | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
update-dev: | ||
permissions: write-all | ||
name: update-dev | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- run: | | ||
git config user.name 'GitHub Actions' | ||
git config user.email '[email protected]' | ||
git checkout dev | ||
git merge main | ||
echo "Done with merge" | ||
- name: Push to dev | ||
uses: CasperWA/push-protected@v2 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
branch: dev |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: build | ||
|
||
on: | ||
push: | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ main ] | ||
|
||
jobs: | ||
|
||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Verify that the Docker image for the action builds | ||
run: sudo docker build . --file Dockerfile | ||
|
||
- name: Integration test | ||
id: integration | ||
uses: ./ | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,4 @@ | ||
on: | ||
push: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
@@ -16,53 +13,9 @@ jobs: | |
- name: Contribute List | ||
uses: akhilmhdh/[email protected] | ||
env: | ||
|
||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
with: | ||
# https://github.com/marketplace/actions/contribute-list#optional-parameters | ||
readme_path: MAINTAINERS.md | ||
use_username: false | ||
commit_message: "BOT: Update contributors info in MAINTAINERS.md" | ||
|
||
# Update contributor count | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Pull changes from contributors-readme-action | ||
run: | | ||
git pull | ||
- name: Get repository contributors count | ||
id: get_contributors | ||
# https://docs.github.com/en/rest/repos/repos?apiVersion=2022-11-28#list-repository-contributors | ||
# https://docs.github.com/en/graphql/reference/objects#repositorycollaboratorconnection | ||
# https://docs.github.com/en/graphql/guides/forming-calls-with-graphql#communicating-with-graphql | ||
# CANNOT have newlines! | ||
run: | | ||
OWNER=$(echo $GITHUB_REPOSITORY | cut -d'/' -f1) | ||
REPO=$(echo $GITHUB_REPOSITORY | cut -d'/' -f2) | ||
QUERY='query { repository(owner: \"'"$OWNER"'\", name: \"'"$REPO"'\") { collaborators { totalCount } } }' | ||
CONTRIBUTORS=$(curl -s -X POST -H "Authorization: bearer ${{ secrets.GITHUB_TOKEN }}" -H "Content-Type: application/json" -d "{\"query\": \"$QUERY\"}" https://api.github.com/graphql | jq -r '.data.repository.collaborators.totalCount') | ||
echo "Total contributors: $CONTRIBUTORS" | ||
echo "contributors=$CONTRIBUTORS" >> $GITHUB_OUTPUT | ||
- name: Replace slug in MAINTAINERS.md with number of contributors | ||
# https://stackoverflow.com/questions/10613643/replace-a-unknown-string-between-two-known-strings-with-sed | ||
run: | | ||
CONTRIBUTORS=${{ steps.get_contributors.outputs.contributors }} | ||
sed -i 's/<!--CONTRIBUTOR COUNT START-->.*<!--CONTRIBUTOR COUNT END-->/<!--CONTRIBUTOR COUNT START--> '"$CONTRIBUTORS"' <!--CONTRIBUTOR COUNT END-->/g' MAINTAINERS.md | ||
- name: Commit and push changes | ||
# https://github.com/orgs/community/discussions/26560#discussioncomment-3531273 | ||
# commit changes, but if no changes exist, then exit cleanly | ||
run: | | ||
git config user.name 'github-actions[bot]' | ||
git config user.email 'github-actions[bot]@users.noreply.github.com' | ||
git add MAINTAINERS.md | ||
git commit -m "BOT: Update contributors info in MAINTAINERS.md" || exit 0 | ||
git push | ||
commit_message: "BOT: Update contributors info in MAINTAINERS.md" |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
__pycache__/ | ||
tests/__pycache__/ | ||
*.pyc |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# If you need Python 3 and the GitHub CLI, then use: | ||
FROM cicirello/pyaction:4 | ||
|
||
# If all you need is Python 3, use: | ||
# FROM cicirello/pyaction-lite:3 | ||
|
||
# If Python 3 + git is sufficient, then use: | ||
# FROM cicirello/pyaction:3 | ||
|
||
# To pull from the GitHub Container Registry instead, use one of these: | ||
# FROM ghcr.io/cicirello/pyaction-lite:3 | ||
# FROM ghcr.io/cicirello/pyaction:4 | ||
# FROM ghcr.io/cicirello/pyaction:3 | ||
|
||
|
||
RUN apt-get update && apt-get install -y \ | ||
gource | ||
|
||
|
||
COPY entrypoint.py /entrypoint.py | ||
ENTRYPOINT ["/entrypoint.py"] |
Oops, something went wrong.