This repository contains the source code for the Angry Data Scanner website.
.
├── src/ # Source files for the static website
│ ├── assets/ # Images, icons, screenshots
│ ├── css/ # Stylesheets
│ ├── js/ # JavaScript files (i18n, config, components, script)
│ └── *.html # HTML pages
├── static/ # Static files (robots.txt, BingSiteAuth.xml, etc.)
├── docs/ # Minimal MkDocs documentation (required for build)
├── hooks.py # MkDocs build hook (replaces site with src content)
├── mkdocs.yml # MkDocs configuration
└── requirements.txt # Python dependencies
-
Clone this repository:
git clone https://github.com/angryscan/angryscan.org.git cd angryscan.org -
Install dependencies:
pip install -r requirements.txt
-
Generate HTML pages from templates (optional, done automatically during build):
# Generate pages for all languages from templates and config.json python3 generate_html.pyThis creates pages in
/src/for all languages (/ru/,/de/,/fr/,/es/) using translations fromconfig.json. -
Build the site:
mkdocs build
This will copy files from
src/andstatic/tosite/directory, including language-specific pages. -
Start local development server:
mkdocs serve
Or use a simple HTTP server with URL rewrite support:
python3 dev_server.py
This server supports clean URLs (without .html extension):
/discovery→discovery.html/features→features.html/ru/discovery→ru/discovery.html- etc.
Or use a basic HTTP server (without rewrite support):
cd src && python3 -m http.server 8000
- Multi-language support:
- English (root pages:
/,/index.html, etc.) - Russian with custom translations (
/ru/) - German with Google Translate (
/de/) - French with Google Translate (
/fr/) - Spanish with Google Translate (
/es/)
- English (root pages:
- Analytics: Yandex Metrika, Google Tag Manager, and Bing verification
- Modern design: Responsive, dark/light theme support
- Static site: Fast, SEO-friendly static HTML
Сайт автоматически деплоится на GitHub Pages при каждом push в ветку main:
-
Настройка GitHub Pages (один раз):
- Перейдите в Settings → Pages
- Source: выберите "GitHub Actions"
- Сохраните настройки
-
Процесс деплоя:
- При push в
mainзапускается GitHub Actions workflow - Устанавливаются зависимости (
pip install -r requirements.txt) - Запускается сборка (
mkdocs build) hooks.pyкопирует файлы изsrc/иstatic/вsite/- Содержимое
site/деплоится на GitHub Pages - Сайт доступен по адресу:
https://<username>.github.io/<repository>/илиhttps://angryscan.org/
- При push в
-
Ручной запуск деплоя:
- Перейдите в Actions → Deploy documentation
- Нажмите "Run workflow" → "Run workflow"
Если нужно задеплоить на другой сервер:
# 1. Собрать сайт
mkdocs build
# 2. Скопировать содержимое папки site/ на сервер
# Например, через rsync:
rsync -avz --delete site/ user@server:/var/www/html/
# Или через scp:
scp -r site/* user@server:/var/www/html/- Netlify: подключите репозиторий, укажите build command:
mkdocs build, publish directory:site - Vercel: аналогично Netlify
- Cloudflare Pages: подключите репозиторий, укажите build command и output directory
- Любой статический хостинг: просто загрузите содержимое папки
site/после сборки