Skip to content

Commit 7c2ba69

Browse files
author
yuceltoluyag
committed
pelican-theme-tailwind3.x
0 parents  commit 7c2ba69

101 files changed

Lines changed: 12346 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
name: Install uv, Python, and project dependencies
3+
description: Install uv, Python, and project dependencies using cached uv and Python installations
4+
5+
inputs:
6+
python-version:
7+
description: >
8+
Version range or exact version of a Python version to use, using SemVer's version range syntax.
9+
required: false
10+
default: "3.13"
11+
12+
outputs:
13+
python-version:
14+
description: The installed python version. Useful when given a version range as input.
15+
value: ${{ steps.setup-python.outputs.python-version }}
16+
17+
runs:
18+
using: composite
19+
steps:
20+
- name: Setup uv with cache
21+
uses: astral-sh/setup-uv@v3
22+
with:
23+
version: "latest"
24+
enable-cache: true
25+
cache-dependency-glob: "uv.lock"
26+
27+
- name: Set up Python ${{ matrix.python-version }}
28+
shell: bash
29+
run: uv python install ${{ matrix.python-version }}
30+
31+
- name: Install the project
32+
shell: bash
33+
run: uv sync --all-extras --dev
34+
35+
- name: Minimize uv cache
36+
shell: bash
37+
run: uv cache prune --ci

.github/labels.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Add 'repo' label to any root file changes
2+
repo:
3+
- ./*
4+
5+
articles:
6+
- content/**/*
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
name: Check External Links
3+
4+
on:
5+
workflow_dispatch:
6+
pull_request:
7+
types:
8+
- opened
9+
- reopened
10+
- synchronize
11+
paths:
12+
- "content/**.md"
13+
14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
16+
cancel-in-progress: true
17+
18+
jobs:
19+
markdown-link-check:
20+
runs-on: ubuntu-22.04
21+
steps:
22+
- name: Checkout Repo
23+
uses: actions/checkout@v4
24+
25+
- name: Run linkspector
26+
uses: umbrelladocs/action-linkspector@v1
27+
with:
28+
github_token: ${{ secrets.github_token }}
29+
reporter: github-pr-check
30+
fail_on_error: true
31+
config_file: .linkspector.yml
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Compress Images
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
types:
7+
- opened
8+
- reopened
9+
- synchronize
10+
paths:
11+
- "**.jpg"
12+
- "**.jpeg"
13+
- "**.png"
14+
- "**.webp"
15+
16+
concurrency:
17+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
18+
cancel-in-progress: true
19+
20+
jobs:
21+
build:
22+
# Only run on Pull Requests within the same repository, and not from forks.
23+
if: github.event.pull_request.head.repo.full_name == github.repository
24+
name: calibreapp/image-actions
25+
permissions: write-all
26+
runs-on: ubuntu-latest
27+
steps:
28+
- name: Checkout Repo
29+
uses: actions/checkout@v4
30+
31+
- name: Compress Images
32+
uses: calibreapp/image-actions@main
33+
with:
34+
jpegQuality: "80"
35+
jpegProgressive: false
36+
pngQuality: "80"
37+
webpQuality: "80"
38+
githubToken: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/pr-linter.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
---
2+
name: Pull Request Linter
3+
4+
on:
5+
pull_request_target:
6+
types:
7+
- opened
8+
- edited
9+
- synchronize
10+
branches:
11+
- main
12+
13+
concurrency:
14+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
15+
cancel-in-progress: true
16+
17+
permissions: # added using https://github.com/step-security/secure-workflows
18+
contents: read
19+
20+
jobs:
21+
lint:
22+
permissions:
23+
pull-requests: read # for amannn/action-semantic-pull-request to analyze PRs
24+
statuses: write # for amannn/action-semantic-pull-request to mark status of analyzed PR
25+
runs-on: ubuntu-latest
26+
27+
steps:
28+
- name: Lint Pull Request
29+
uses: amannn/action-semantic-pull-request@v5
30+
with:
31+
types: |
32+
fix
33+
feat
34+
docs
35+
style
36+
refactor
37+
perf
38+
test
39+
build
40+
ci
41+
post
42+
chore
43+
requireScope: false
44+
subjectPattern: ^(?![A-Z]).+$
45+
subjectPatternError: |
46+
The subject "{subject}" found in the pull request title "{title}"
47+
didn't match the configured pattern. Please ensure that the subject
48+
doesn't start with an uppercase character.
49+
env:
50+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/tests.yml

Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
---
2+
name: "Tests"
3+
4+
on:
5+
workflow_dispatch:
6+
push:
7+
branches:
8+
- main
9+
pull_request:
10+
types:
11+
- opened
12+
- reopened
13+
- synchronize
14+
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
17+
cancel-in-progress: true
18+
19+
jobs:
20+
check-if-comment-pr:
21+
runs-on: ubuntu-latest
22+
outputs:
23+
is_comment_pr: ${{ steps.check_pr_title.outputs.is_comment_pr }}
24+
steps:
25+
- name: Check if PR is a comment submission
26+
id: check_pr_title
27+
# PR başlığı "chore: new comment on" ile başlıyorsa, yorum PR'ı olarak kabul et
28+
run: |
29+
if [[ "${{ github.event.pull_request.title }}" == chore:\ new\ comment\ on* ]]; then
30+
echo "is_comment_pr=true" >> $GITHUB_OUTPUT
31+
else
32+
echo "is_comment_pr=false" >> $GITHUB_OUTPUT
33+
fi
34+
35+
test-build:
36+
needs: check-if-comment-pr
37+
# Eğer bu bir yorum PR'ı ise ve PR açılmışsa test işini çalıştırma
38+
if: ${{ needs.check-if-comment-pr.outputs.is_comment_pr != 'true' || github.event_name != 'pull_request' }}
39+
runs-on: ubuntu-latest
40+
steps:
41+
- name: Checkout repository
42+
uses: actions/checkout@v4
43+
44+
- name: Setup Node.js
45+
uses: actions/setup-node@v4
46+
with:
47+
node-version: "20"
48+
cache: "npm"
49+
50+
- name: Install Node.js dependencies
51+
run: npm ci
52+
53+
- name: Setup Türkçe Locale
54+
run: |
55+
# Gerekli paketleri yükle
56+
sudo apt-get update && sudo apt-get install -y locales tzdata
57+
58+
# Tüm desteklenen locale'leri listele ve Türkçe'yi etkinleştir
59+
sudo sed -i 's/# tr_TR.UTF-8 UTF-8/tr_TR.UTF-8 UTF-8/' /etc/locale.gen
60+
sudo dpkg-reconfigure --frontend=noninteractive locales
61+
62+
# Zaman dilimini ayarla
63+
sudo timedatectl set-timezone Europe/Istanbul
64+
65+
# Sistem genelinde locale ayarla
66+
sudo update-locale LANG=tr_TR.UTF-8 LC_ALL=tr_TR.UTF-8
67+
68+
# Mevcut kabuk için locale ayarla
69+
export LANG=tr_TR.UTF-8
70+
export LC_ALL=tr_TR.UTF-8
71+
export TZ=Europe/Istanbul
72+
73+
# Oluşturulan locale'leri göster
74+
echo "Oluşturulan locale'ler:"
75+
locale -a | grep tr_TR
76+
77+
echo "Tarih ayarları:"
78+
date
79+
80+
echo "Locale ayarları:"
81+
locale
82+
83+
- name: Setup Python, uv, and the package
84+
uses: ./.github/actions/setup_python_env
85+
env:
86+
LANG: tr_TR.UTF-8
87+
LC_ALL: tr_TR.UTF-8
88+
TZ: Europe/Istanbul
89+
90+
- name: Create .nojekyll file
91+
run: touch .nojekyll
92+
93+
- name: Build the site
94+
env:
95+
NODE_ENV: production
96+
LANG: tr_TR.UTF-8
97+
LC_ALL: tr_TR.UTF-8
98+
TZ: Europe/Istanbul
99+
run: |
100+
# Site inşa sürecini başlat
101+
uv run duty publish
102+
103+
- name: Confirm files were created
104+
run: |
105+
ls -al output
106+
if [ ! -e "output/index.html" ]; then
107+
echo "output/index.html not found"
108+
exit 1
109+
fi
110+
111+
- name: Deploy to GitHub Pages
112+
if: github.ref == 'refs/heads/main'
113+
uses: peaceiris/actions-gh-pages@v4
114+
with:
115+
github_token: ${{ secrets.GITHUB_TOKEN }}
116+
publish_dir: ./output
117+
publish_branch: gh-pages
118+
cname: yuceltoluyag.github.io

0 commit comments

Comments
 (0)