Skip to content

Latest commit

 

History

History
52 lines (34 loc) · 2.88 KB

README.md

File metadata and controls

52 lines (34 loc) · 2.88 KB

TWC Site

Netlify Status

This repository is responsible for most content visible on the website techworkerscoalition.org. The site is made with a static site generator called Jekyll in a language called Ruby.

Getting Started

  1. Install dependencies: bundle install
  2. Start a local server: bundle exec jekyll serve

Open a browser to localhost:8080

DecapCMS

In addition to GitHub, you can update the website via DecapCMS for example adding new blog posts and events by going to /admin interface. For local development, visit this tutorial (run npx decap-server from a different shell)

Add your city

If your country/city's TWC chapter is not mentioned in the website, link to it on the homepage here and if you want a local markdown page (as opposed to external link) see the other examples here.

Add a press mention

Inside _data/press.yml file, add a media entry, with date format in YYYY-MM-DD

Translation

I18n (internationalization) is made available with the jekyll-multiple-languages-plugin. When a page has a translated version available, a link will show up on the top right if you use the default_translate layout. English is the default language, while other languages have their two letter ISO code prefixed, for example TechWorkersCoalition.org/ru for Russian.

Adding new language

  1. Add new language key to en.yml
  2. Add two letter iso code in config. The order here determines the order shown on the page. English must be first.
  3. Inside the i18n directory create a
  • LANGUAGE/ (where LANGUAGE is two letter ISO code for that language)
  • LANGUAGE.yml with the language key and value in its own language, for example es: Español

Note, only the default en.yml must contain the names of each language. The other language yml files contain just their own language key.

Screen Shot 2019-07-21 at 14 48 46

To include only certain languages, specify the exact language keys you want inside the page front matter. For example languages: ["en", 'ja']

Supported Pages

Supported Languages

  • English
  • Russian
  • Portuguese
  • Italian
  • Portuguese (BR)
  • Spanish (ES)