-
Notifications
You must be signed in to change notification settings - Fork 58
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 #58 from fabianegli/fabianegli-restore-attribution
Restore attribution
- Loading branch information
Showing
2 changed files
with
44 additions
and
10 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
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,38 @@ | ||
on: | ||
workflow_call: | ||
inputs: | ||
message: | ||
type: string | ||
required: true | ||
description: The message to commit | ||
push: | ||
paths: | ||
- 'robots.json' | ||
branches: | ||
- "main" | ||
|
||
jobs: | ||
ai-robots-txt: | ||
runs-on: ubuntu-latest | ||
name: ai-robots-txt | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 2 | ||
- run: | | ||
git config --global user.name "ai.robots.txt" | ||
git config --global user.email "[email protected]" | ||
git log -1 | ||
git status | ||
echo "Updating robots.txt and table-of-bot-metrics.md if necessary ..." | ||
python code/dark_visitors.py --convert | ||
echo "... done." | ||
git --no-pager diff | ||
git add -A | ||
if [ -n "${{ inputs.message }}" ]; then | ||
git commit -m "${{ inputs.message }}" | ||
else | ||
git commit -m "${{ github.event.head_commit.message }}" | ||
fi | ||
git push | ||
shell: bash |