diff --git a/.github/workflows/use-visitor-counter.yml b/.github/workflows/use-visitor-counter.yml
new file mode 100644
index 0000000..4aa2c96
--- /dev/null
+++ b/.github/workflows/use-visitor-counter.yml
@@ -0,0 +1,94 @@
+name: Use Visitor Counter Logic
+
+on:
+ pull_request:
+ branches:
+ - main
+ schedule:
+ - cron: '0 0 * * *' # Runs daily at midnight
+ workflow_dispatch: # Allows manual triggering
+
+permissions:
+ contents: write
+ pull-requests: write
+
+jobs:
+ update-visitor-count:
+ runs-on: ubuntu-latest
+
+ steps:
+ - name: Checkout current repository
+ uses: actions/checkout@v4
+ with:
+ fetch-depth: 0
+
+ - name: Shallow clone visitor counter logic
+ run: git clone --depth=1 https://github.com/brown9804/github-visitor-counter.git
+
+ - name: Set up Node.js
+ uses: actions/setup-node@v4
+ with:
+ node-version: '20'
+
+ - name: Install dependencies for github-visitor-counter
+ run: |
+ cd github-visitor-counter
+ npm ci
+
+ - name: Run visitor counter logic (updates markdown badges and metrics.json)
+ run: node github-visitor-counter/update_repo_views_counter.js
+ env:
+ TRAFFIC_TOKEN: ${{ secrets.TRAFFIC_TOKEN }}
+ REPO: ${{ github.repository }}
+
+ - name: Move generated metrics.json to root
+ run: mv github-visitor-counter/metrics.json .
+
+ - name: List files for debugging
+ run: |
+ ls -l
+ ls -l github-visitor-counter
+
+ - name: Clean up visitor counter logic
+ run: rm -rf github-visitor-counter
+
+ - name: Configure Git author
+ run: |
+ git config --global user.name "github-actions[bot]"
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
+
+ - name: Commit and push changes (PR)
+ if: github.event_name == 'pull_request'
+ env:
+ TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ run: |
+ git fetch origin
+ git checkout -b ${{ github.event.pull_request.head.ref }} origin/${{ github.event.pull_request.head.ref }}
+ git add "*.md" metrics.json
+ git commit -m "Update visitor count" || echo "No changes to commit"
+ git remote set-url origin https://x-access-token:${TOKEN}@github.com/${{ github.repository }}
+ git pull --rebase origin ${{ github.event.pull_request.head.ref }} || echo "No rebase needed"
+ git push origin HEAD:${{ github.event.pull_request.head.ref }}
+
+ - name: Commit and push changes (non-PR)
+ if: github.event_name != 'pull_request'
+ env:
+ TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ run: |
+ git fetch origin
+ git checkout ${{ github.event.pull_request.head.ref }} || git checkout -b ${{ github.event.pull_request.head.ref }} origin/${{ github.event.pull_request.head.ref }}
+ git add "*.md" metrics.json
+ git commit -m "Update visitor count" || echo "No changes to commit"
+ git remote set-url origin https://x-access-token:${TOKEN}@github.com/${{ github.repository }}
+ git pull --rebase origin ${{ github.event.pull_request.head.ref }} || echo "No rebase needed"
+ git push origin HEAD:${{ github.event.pull_request.head.ref }}
+
+ - name: Create Pull Request (non-PR)
+ if: github.event_name != 'pull_request'
+ uses: peter-evans/create-pull-request@v6
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ branch: update-visitor-count
+ title: "Update visitor count"
+ body: "Automated update of visitor count"
+ base: main
diff --git a/Cost-Management/BillingReport.md b/Cost-Management/BillingReport.md
index 9428a05..cda510f 100644
--- a/Cost-Management/BillingReport.md
+++ b/Cost-Management/BillingReport.md
@@ -105,7 +105,9 @@ Last updated: 2025-05-02
+
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
+Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17
Refresh Date: 2025-07-17