Skip to content

Feature/add blog website #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/funding.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@

#github: tanthanhdev
ko_fi: devphan
custom: ["https://www.paypal.me/ThanhPhan481"]
60 changes: 60 additions & 0 deletions .github/workflows/update-frontmatter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Update Markdown Frontmatter

on:
push:
paths:
- 'docs/**/*.md'
- 'i18n/**/*.md'
pull_request:
paths:
- 'docs/**/*.md'
- 'i18n/**/*.md'
schedule:
# Run at 00:00 UTC every Monday
- cron: '0 0 * * 1'
# Allow manual runs from GitHub interface
workflow_dispatch:

jobs:
update-frontmatter:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
# Fetch full history to allow creating commits
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
cache: 'npm'

- name: Install dependencies
run: npm install gray-matter glob

- name: Run update script
run: |
chmod +x tools/update-frontmatter.js
node tools/update-frontmatter.js

- name: Check for changes
id: git-check
run: |
git diff --exit-code || echo "changes=true" >> $GITHUB_OUTPUT

- name: Commit changes if any
if: steps.git-check.outputs.changes == 'true'
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add -A
git commit -m "chore: update markdown frontmatter [skip ci]"

- name: Push changes
if: steps.git-check.outputs.changes == 'true'
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
Expand Down Expand Up @@ -67,7 +66,7 @@ coverage.xml
*.rej

# Ignore public site build if using static site generator (optional)
public/
# public/
.cache/

# Ignore Markdown preview temp files (e.g., Typora)
Expand All @@ -88,3 +87,6 @@ docker-compose.override.yml
.env
!.env.example
docker/environments/databases/.env

# Not follow website
!website/
52 changes: 52 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Tech Notes Hub Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender characteristics, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [CONTACT EMAIL]. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org), version 1.4, available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

## Summary

* Treat everyone with respect and courtesy
* Gracefully accept constructive feedback
* Focus on helping others and growing the community
* Don't use offensive language or imagery
* Don't harass, threaten, or discriminate against anyone
* If you witness inappropriate behavior, report it to project maintainers
52 changes: 52 additions & 0 deletions CODE_OF_CONDUCT_vi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Quy tắc Ứng xử của Tech Notes Hub

## Cam kết của chúng tôi

Nhằm thúc đẩy một môi trường mở và thân thiện, chúng tôi - những người đóng góp và duy trì dự án - cam kết đảm bảo việc tham gia vào dự án và cộng đồng của chúng tôi là một trải nghiệm không quấy rối cho tất cả mọi người, bất kể tuổi tác, kích thước cơ thể, khuyết tật, dân tộc, đặc điểm giới tính, bản dạng và biểu hiện giới tính, trình độ kinh nghiệm, quốc tịch, ngoại hình cá nhân, chủng tộc, tôn giáo, hoặc bản dạng và khuynh hướng tình dục.

## Tiêu chuẩn của chúng tôi

Các ví dụ về hành vi góp phần tạo ra môi trường tích cực bao gồm:

* Sử dụng ngôn ngữ chào đón và hòa nhập
* Tôn trọng các quan điểm và kinh nghiệm khác nhau
* Nhã nhặn chấp nhận phê bình mang tính xây dựng
* Tập trung vào điều tốt nhất cho cộng đồng
* Thể hiện sự đồng cảm với các thành viên khác trong cộng đồng

Các ví dụ về hành vi không thể chấp nhận từ người tham gia bao gồm:

* Việc sử dụng ngôn ngữ hoặc hình ảnh mang tính gợi dục và sự chú ý hoặc tiến triển tình dục không được chào đón
* Trolling, bình luận xúc phạm/miệt thị, và tấn công cá nhân hoặc mang tính chính trị
* Quấy rối công khai hoặc riêng tư
* Công bố thông tin cá nhân của người khác, chẳng hạn như địa chỉ vật lý hoặc điện tử, mà không được phép rõ ràng
* Các hành vi khác có thể hợp lý được coi là không phù hợp trong môi trường chuyên nghiệp

## Trách nhiệm của chúng tôi

Người duy trì dự án có trách nhiệm làm rõ các tiêu chuẩn về hành vi có thể chấp nhận được và được mong đợi sẽ thực hiện các hành động khắc phục phù hợp và công bằng để đáp lại bất kỳ trường hợp hành vi không thể chấp nhận nào.

Người duy trì dự án có quyền và trách nhiệm xóa, chỉnh sửa hoặc từ chối nhận xét, commit, mã, chỉnh sửa wiki, issues và các đóng góp khác không phù hợp với Quy tắc Ứng xử này, hoặc tạm thời hoặc vĩnh viễn cấm bất kỳ người đóng góp nào vì các hành vi khác mà họ cho là không phù hợp, đe dọa, xúc phạm hoặc có hại.

## Phạm vi

Quy tắc Ứng xử này áp dụng trong cả không gian dự án và không gian công cộng khi một cá nhân đại diện cho dự án hoặc cộng đồng của dự án. Ví dụ về việc đại diện cho một dự án hoặc cộng đồng bao gồm việc sử dụng địa chỉ email chính thức của dự án, đăng thông qua tài khoản mạng xã hội chính thức, hoặc làm đại diện được chỉ định tại một sự kiện trực tuyến hoặc ngoại tuyến. Đại diện của một dự án có thể được người duy trì dự án xác định và làm rõ thêm.

## Thực thi

Các trường hợp hành vi lạm dụng, quấy rối hoặc không thể chấp nhận khác có thể được báo cáo bằng cách liên hệ với nhóm dự án tại [EMAIL LIÊN HỆ]. Tất cả khiếu nại sẽ được xem xét và điều tra, và sẽ dẫn đến phản hồi được coi là cần thiết và phù hợp với hoàn cảnh. Nhóm dự án có nghĩa vụ duy trì tính bảo mật đối với người báo cáo về một sự cố. Các chi tiết cụ thể hơn về chính sách thực thi có thể được đăng riêng.

Người duy trì dự án không tuân theo hoặc thực thi Quy tắc Ứng xử một cách thiện chí có thể phải đối mặt với hậu quả tạm thời hoặc vĩnh viễn do các thành viên lãnh đạo khác của dự án quyết định.

## Ghi nhận

Quy tắc Ứng xử này được điều chỉnh từ [Contributor Covenant](https://www.contributor-covenant.org), phiên bản 1.4, có tại https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

## Tóm tắt

* Đối xử với mọi người bằng sự tôn trọng và lịch sự
* Chấp nhận các góp ý mang tính xây dựng một cách nhã nhặn
* Tập trung vào việc giúp đỡ người khác và phát triển cộng đồng
* Không sử dụng ngôn ngữ hoặc hình ảnh xúc phạm
* Không quấy rối, đe dọa hoặc phân biệt đối xử với bất kỳ ai
* Nếu bạn chứng kiến hành vi không phù hợp, hãy báo cáo cho người quản lý dự án
17 changes: 16 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,24 @@ Before submitting, ensure:
## 📁 File & Folder Naming Conventions

* Use lowercase and hyphens for file and folder names: `graph_traversal.md` (except for code files like C# using PascalCase such as `GraphTraversal.cs`, or Java using CamelCase like `GraphTraversal.java`)
* For translations, add language suffix: `graph_traversal_vi.md`
* For translations, add language suffix: `graph_traversal_vi.md`, but no suffix is needed if in the /i18n/[language_code]/ folder
* Notes should be grouped by docs folders (e.g., `docs/algorithms/`, `docs/aws/`, `docs/design-patterns/`)

### 📂 Code Snippets Structure

Code snippets must follow this directory structure for proper display on the website:

```
snippets/[category]/[topic-name]/[filename].[extension]
```

Examples:
- `snippets/algorithms/graph-traversal/graph_traversal.py`
- `snippets/devops/ci-cd/ci-cd.sh`
- `snippets/databases/mongodb/mongodb_query.js`

The `[topic-name]` folder must match the slug of your blog post for snippets to appear automatically. All files inside this folder will be displayed as code snippets on the corresponding blog post page.

## 🤝 Code of Conduct

Be respectful, open, and constructive in all interactions. We're building a friendly and inclusive learning space for all developers.
Expand Down
Loading
Loading