|
| 1 | +# ValienteTechnologies.github.io |
| 2 | + |
| 3 | +Marketing site for [Valiente Technologies](https://valientetechnologies.com) — Turkey's first cybersecurity firm based in Antalya. |
| 4 | + |
| 5 | +Built with **Jekyll** + [jekyll-agency](https://github.com/y7kim/agency-jekyll-theme) theme, deployed via **GitHub Pages**, served behind **Cloudflare**. |
| 6 | + |
| 7 | +--- |
| 8 | + |
| 9 | +## Prerequisites |
| 10 | + |
| 11 | +| Tool | Version | Purpose | |
| 12 | +|------|---------|---------| |
| 13 | +| Ruby | 3.2.2 (see `.ruby-version`) | Jekyll runtime | |
| 14 | +| Bundler | latest | Gem management | |
| 15 | +| Python 3 | any | WebP image conversion | |
| 16 | +| Node / npm | any | JS minification | |
| 17 | +| terser | `npm install -g terser` | Minify `assets/js/src/*.js` | |
| 18 | +| Pillow | `pip install pillow` | Convert PNG/JPG → WebP on commit | |
| 19 | + |
| 20 | +--- |
| 21 | + |
| 22 | +## Setup |
| 23 | + |
| 24 | +```bash |
| 25 | +# 1. Clone |
| 26 | +git clone https://github.com/ValienteTechnologies/ValienteTechnologies.github.io |
| 27 | +cd ValienteTechnologies.github.io |
| 28 | + |
| 29 | +# 2. Ruby deps |
| 30 | +bundle install |
| 31 | + |
| 32 | +# 3. Python deps (for pre-commit WebP hook) |
| 33 | +pip install pillow |
| 34 | + |
| 35 | +# 4. JS minifier |
| 36 | +npm install -g terser |
| 37 | + |
| 38 | +# 5. Install git hooks |
| 39 | +cp scripts/pre-commit .git/hooks/pre-commit |
| 40 | +chmod +x .git/hooks/pre-commit |
| 41 | +``` |
| 42 | + |
| 43 | +--- |
| 44 | + |
| 45 | +## Running locally |
| 46 | + |
| 47 | +```bash |
| 48 | +bundle exec jekyll serve --livereload |
| 49 | +# → http://localhost:4000 |
| 50 | +``` |
| 51 | + |
| 52 | +--- |
| 53 | + |
| 54 | +## Project structure |
| 55 | + |
| 56 | +``` |
| 57 | +_data/ # All site content (YAML). Edit here, not in templates. |
| 58 | + i18n.yml # UI strings (breadcrumbs, title suffixes) |
| 59 | + header.yml # Hero section text |
| 60 | + services.yml # Services section |
| 61 | + testimonials.yml |
| 62 | + footer.yml |
| 63 | + navigation.yml |
| 64 | + style.yml # Highlight color, fonts_urls |
| 65 | + ... |
| 66 | +
|
| 67 | +_includes/ |
| 68 | + layout/ # nav.html, nav-header.html, head.html, footer.html |
| 69 | + sections/ # services.html, testimonials.html, contact_form.html, ... |
| 70 | +
|
| 71 | +_layouts/ |
| 72 | + default.html # Base layout (scripts, footer) |
| 73 | + home.html # Home page (nav+header, sections, page-specific JS) |
| 74 | + subpage.html # Inner pages |
| 75 | + error.html # 404 |
| 76 | +
|
| 77 | +_pages/ # Page definitions (mostly include composition) |
| 78 | +_sass/ |
| 79 | + base/ # _variables.scss, _mixins.scss, _page.scss |
| 80 | + components/ # _navbar.scss, _buttons.scss, _utilities.scss, ... |
| 81 | + layout/ # Per-section SCSS (_masthead, _services, _footer, ...) |
| 82 | +
|
| 83 | +assets/ |
| 84 | + css/ # agency.css (Jekyll-compiled), bootstrap.min.css, all.min.css |
| 85 | + js/ # Minified JS (do not edit directly) |
| 86 | + js/src/ # JS source files (edit here, pre-commit auto-minifies) |
| 87 | + img/ # WebP images (PNG/JPG source → pre-commit auto-converts) |
| 88 | +
|
| 89 | +scripts/ |
| 90 | + pre-commit # Git hook: WebP conversion + JS minification |
| 91 | + minify-js.sh # Manual: ./scripts/minify-js.sh [filename] |
| 92 | + to_webp.py # Image converter used by pre-commit hook |
| 93 | +``` |
| 94 | + |
| 95 | +--- |
| 96 | + |
| 97 | +## i18n (bilingual TR/EN) |
| 98 | + |
| 99 | +The site uses [jekyll-polyglot](https://github.com/untra/polyglot). All content lives in `_data/*.yml` with this pattern: |
| 100 | + |
| 101 | +```yaml |
| 102 | +tr: &DEFAULT |
| 103 | + title: "Türkçe başlık" |
| 104 | + |
| 105 | +tr-TR: |
| 106 | + <<: *DEFAULT # inherits TR |
| 107 | + |
| 108 | +en: |
| 109 | + title: "English title" |
| 110 | +``` |
| 111 | +
|
| 112 | +UI strings (breadcrumbs, title suffixes, etc.) live in `_data/i18n.yml`. |
| 113 | + |
| 114 | +--- |
| 115 | + |
| 116 | +## JS workflow |
| 117 | + |
| 118 | +Source files live in `assets/js/src/`. **Never edit the minified files in `assets/js/` directly.** |
| 119 | + |
| 120 | +```bash |
| 121 | +# Edit source |
| 122 | +vim assets/js/src/mesh-network.js |
| 123 | +
|
| 124 | +# Minify one file |
| 125 | +./scripts/minify-js.sh mesh-network.js |
| 126 | +
|
| 127 | +# Or minify all |
| 128 | +./scripts/minify-js.sh |
| 129 | +``` |
| 130 | + |
| 131 | +The pre-commit hook does this automatically when you stage `assets/js/src/*.js`. |
| 132 | + |
| 133 | +--- |
| 134 | + |
| 135 | +## Images |
| 136 | + |
| 137 | +Stage a PNG/JPG and the pre-commit hook converts it to WebP automatically. Use `<picture>` elements in templates for WebP + PNG/JPG fallback. |
| 138 | + |
| 139 | +--- |
| 140 | + |
| 141 | +## Deployment |
| 142 | + |
| 143 | +Push to `main` → GitHub Pages builds automatically. Cloudflare proxies the result. |
| 144 | + |
| 145 | +**Cloudflare notes:** |
| 146 | +- Email obfuscation: disable in Scrape Shield → Cloudflare Email Obfuscation to remove `email-decode.min.js` |
| 147 | +- Cache TTLs for `/assets/*`: set via Cloudflare Cache Rules |
| 148 | +- `robots.txt` is managed by Cloudflare AI scraping protection (Content-Signal directive is harmless) |
| 149 | +- Analytics: GA4 tag `G-FF9YHPMVJL` |
0 commit comments