diff --git a/.github/workflows/update-md-date.yml b/.github/workflows/update-md-date.yml index afa6680..5b2a19b 100644 --- a/.github/workflows/update-md-date.yml +++ b/.github/workflows/update-md-date.yml @@ -5,15 +5,20 @@ on: branches: - main +permissions: + contents: write + pull-requests: write + jobs: update-date: runs-on: ubuntu-latest steps: - - name: Checkout repository + - name: Checkout PR branch uses: actions/checkout@v4 with: fetch-depth: 0 + ref: ${{ github.event.pull_request.head.ref }} - name: Set up Python uses: actions/setup-python@v4 @@ -27,17 +32,17 @@ jobs: run: | git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - + - name: Update last modified date in Markdown files run: python .github/workflows/update_date.py - - name: Commit changes + - name: Pull (merge) remote changes, commit, and push if needed env: TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - git fetch origin - git pull --rebase origin ${{ github.event.pull_request.head.ref }} || echo "No rebase needed" + BRANCH="${{ github.event.pull_request.head.ref }}" + git pull origin "$BRANCH" || echo "No merge needed" git add -A git commit -m "Update last modified date in Markdown files" || echo "No changes to commit" git remote set-url origin https://x-access-token:${TOKEN}@github.com/${{ github.repository }} - git push origin HEAD:${{ github.event.pull_request.head.ref }} + git push origin HEAD:"$BRANCH" diff --git a/BestPractices.md b/BestPractices.md index acc46d2..ad03904 100644 --- a/BestPractices.md +++ b/BestPractices.md @@ -96,8 +96,8 @@ Last updated: 2025-08-04
- Total views -

Refresh Date: 2025-08-27

+ Total views +

Refresh Date: 2025-08-29

diff --git a/README.md b/README.md index f5c8bcb..c5c2614 100644 --- a/README.md +++ b/README.md @@ -459,11 +459,10 @@ gh codespace stop | **GitHub Actions** | Automation platform for CI/CD workflows, enabling testing, building, and deployment. | Streamlines development workflows by automating repetitive tasks.| | **GitHub Code Quality** | A forthcoming feature focused on improving code quality through automated analysis. | Aims to provide insights and recommendations to improve code maintainability and readability. | -
- Total views -

Refresh Date: 2025-08-27

+ Total views +

Refresh Date: 2025-08-29

diff --git a/demos/0_GithubAImodels.md b/demos/0_GithubAImodels.md index 317fad2..acf2a93 100644 --- a/demos/0_GithubAImodels.md +++ b/demos/0_GithubAImodels.md @@ -194,8 +194,8 @@ Last updated: 2025-08-04
- Total views -

Refresh Date: 2025-08-27

+ Total views +

Refresh Date: 2025-08-29

diff --git a/demos/1_GitHubPagesOverview/README.md b/demos/1_GitHubPagesOverview/README.md index a2f5e4e..f79aea4 100644 --- a/demos/1_GitHubPagesOverview/README.md +++ b/demos/1_GitHubPagesOverview/README.md @@ -71,7 +71,7 @@ Last updated: 2025-08-04
- Total views -

Refresh Date: 2025-08-27

+ Total views +

Refresh Date: 2025-08-29

diff --git a/demos/2_Github-Licenses.md b/demos/2_Github-Licenses.md index 1c2a3b4..70109ad 100644 --- a/demos/2_Github-Licenses.md +++ b/demos/2_Github-Licenses.md @@ -154,8 +154,8 @@ https://github.com/user-attachments/assets/3c993648-8a8d-4b5d-be79-19850aeef593
- Total views -

Refresh Date: 2025-08-27

+ Total views +

Refresh Date: 2025-08-29

diff --git a/metrics.json b/metrics.json new file mode 100644 index 0000000..8665541 --- /dev/null +++ b/metrics.json @@ -0,0 +1,37 @@ +[ + { + "date": "2025-07-07", + "count": 330, + "uniques": 20 + }, + { + "date": "2025-07-08", + "count": 159, + "uniques": 6 + }, + { + "date": "2025-07-10", + "count": 482, + "uniques": 1 + }, + { + "date": "2025-07-11", + "count": 170, + "uniques": 4 + }, + { + "date": "2025-07-12", + "count": 7, + "uniques": 1 + }, + { + "date": "2025-07-14", + "count": 130, + "uniques": 2 + }, + { + "date": "2025-07-15", + "count": 2, + "uniques": 1 + } +] \ No newline at end of file