Skip to content

Commit

Permalink
Added Ensligh translation
Browse files Browse the repository at this point in the history
  • Loading branch information
alterat committed Mar 1, 2018
1 parent 569dad6 commit 5eaf889
Show file tree
Hide file tree
Showing 99 changed files with 2,670 additions and 49 deletions.
26 changes: 0 additions & 26 deletions .circleci/config.yml

This file was deleted.

File renamed without changes
8 changes: 4 additions & 4 deletions conf.py → en/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
from recommonmark.parser import CommonMarkParser

# -- PROJECT Variables ----------------------------------------------------
settings_project_name = 'Documento di test con Docs Italia'
settings_project_name = 'Test document with Docs Italia theme'
settings_copyright_copyleft = 'Creative Commons Attribution 4.0'
settings_editor_name = 'AT'
settings_doc_version = 'versione 0.1'
settings_doc_release = 'versione 0.1'
settings_doc_version = 'version 0.1'
settings_doc_release = 'version 0.1'
settings_basename = 'test-docs-italia'
settings_file_name = 'test-docs-italia'
# disqus_shortname = 'cloud-pa'
Expand Down Expand Up @@ -86,7 +86,7 @@
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#language = None
language = 'it'
language = 'en'

# There are two options for replacing |today|: either, you set today to some
# non-false value, then it is used:
Expand Down
155 changes: 155 additions & 0 deletions en/docs-italia-theme/Titillium-LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,155 @@
SIL Open Font License

Copyright (c) 2008-2010, Accademia di Belle Arti di Urbino (www.campivisivi.net|direzione@accademiadiurbino.it),
with Reserved Font Name Titillium.

N: Luca Antonucci
W: http://www.campivisivi.net
D: Contributor

N: Paola Bacchiocchi
W: http://www.campivisivi.net
D: Contributor

N: Simone Bastianelli
W: http://www.campivisivi.net
D: Contributor

N: Valerio Bosi
W: http://www.campivisivi.net
D: Contributor

N: Fabio Cecchi
W: http://www.campivisivi.net
D: Contributor

N: Giulia Di Grusa
W: http://www.campivisivi.net
D: Contributor

N: Donatella Esposito
W: http://www.campivisivi.net
D: Contributor

N: Giulia Giordani
W: http://www.campivisivi.net
D: Contributor

N: Raffaele Mariotti
W: http://www.campivisivi.net
D: Contributor

N: Leslie Ameto
W: http://www.campivisivi.net
D: Contributor

N: Elisa Mearelli
W: http://www.campivisivi.net
D: Contributor

N: Silvia Mengarelli
W: http://www.campivisivi.net
D: Contributor

N: Roberto Mezzano
W: http://www.campivisivi.net
D: Contributor

N: Valentina Mingucci
W: http://www.campivisivi.net
D: Contributor

N: Andrea Monachesi
W: http://www.campivisivi.net
D: Contributor

N: Manuel Pasini
W: http://www.campivisivi.net
D: Contributor

N: David Pulga
W: http://www.campivisivi.net
D: Contributor

N: Luca Silvestri
W: http://www.campivisivi.net
D: Contributor

N: Paolo Tripodi
W: http://www.campivisivi.net
D: Contributor

N: Fancesco Zamboni
W: http://www.campivisivi.net
D: Contributor

N: Giuliano Chimenti
W: http://www.isiaurbino.it
D: Contributor

N: Francesco Piarulli
W: http://www.isiaurbino.it
D: Contributor

N: Ivan Abbattista
W: http://www.isiaurbino.it
D: Contributor

N: Rita Colacicco
W: http://www.isiaurbino.it
D: Contributor

N: Paolo Mazzetti
W: http://www.scriptype.net
D: Contributor

N: Claudio Piccinini
W: http://www.tht.it/
D: Contributor

N: Luciano Perondi
E: luciano.perondi@campivisivi.net
W: http://www.campivisivi.net
D: Director of progect

This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL

—————————————————————————————-
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
—————————————————————————————-

PREAMBLE
The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.

The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.

DEFINITIONS
“Font Software” refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.

“Reserved Font Name” refers to any names specified as such after the copyright statement(s).

“Original Version” refers to the collection of Font Software components as distributed by the Copyright Holder(s).

“Modified Version” refers to any derivative made by adding to, deleting, or substituting—in part or in whole—any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.

“Author” refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.

PERMISSION & CONDITIONS
Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:

1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.

2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.

3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.

4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.

5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.

TERMINATION
This license becomes null and void if any of the above conditions are not met.

DISCLAIMER
THE FONT SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
97 changes: 97 additions & 0 deletions en/docs-italia-theme/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
"""Docs Italia theme - Team Digitale"""

import os
import re
import yaml

# This part would be better placed as an extension:
# It loads yaml data files to set them as variables
def get_html_theme_path():
"""Return list of HTML theme paths."""
cur_dir = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
return cur_dir


def deep_merge(source, destination):
"""Deep merge dictionaries"""
for key, value in source.items():
if isinstance(value, dict):
node = destination.setdefault(key, {})
deep_merge(value, node)
else:
destination[key] = value
return destination


def load_site_data():
"""Load data from Team Digitale Jekyll site config"""
source_path = os.path.abspath(
os.path.join(os.path.dirname(__file__), 'data')
)
config_path = os.path.join(source_path, '_config.yml')
overrides_path = os.path.join(source_path, '_overrides.yml')
data_path = os.path.join(source_path, '_data')
context = {}

# Load site config
config_h = open(config_path)
config_data = yaml.load(config_h)
context.update(config_data)

# Load Jekyll data files
filename_re = re.compile('\.yml$')
context['data'] = {}
for filename in os.listdir(data_path):
if filename_re.search(filename):
datafile_source = filename_re.sub('', filename)
datafile_path = os.path.join(data_path, filename)
datafile_h = open(datafile_path)
datafile_data = yaml.load(datafile_h)
context['data'].update({datafile_source: datafile_data})

# Load overrides
overrides_h = open(overrides_path)
overrides_data = yaml.load(overrides_h)
context = deep_merge(overrides_data, context)

# Transform network links to ordered mapping. Doing this dynamically
# instead of with overrides to alter mapping into an ordered list and keep
# the existing data
network_links = []
for link in ['trasformazione_digitale', 'developers', 'design', 'forum',
'docs', 'github']:
link_data = context['data']['network_links'].get(link, {}).copy()
link_data['name'] = link

# Alter classes
class_str = link_data.get('class', '')
classes = class_str.split(' ')
try:
del classes[classes.index('current')]
except (IndexError, ValueError):
pass
if link == 'docs':
classes.append('current')
link_data['class'] = ' '.join(classes)

network_links.append(link_data)
context['data']['network_links'] = network_links

footer_links = []
for link in ['privacy', 'legal']:
link_data = context['data']['footer_links'].get(link, {}).copy()
footer_links.append(link_data)
context['data']['footer_links'] = footer_links

return context

def html_page_context_listener(app, pagename, templatename, context, doctree):
"""Add site data to Sphinx context, to make porting templates easier"""
context['site'] = app.site_data
# The translation context is pinned to the Italian sources, as Sphinx has
# it's own translation mechanism built in
context['t'] = app.site_data['data']['l10n']['it']['t']

def setup(app):
app.site_data = load_site_data()
app.connect('html-page-context', html_page_context_listener)
Binary file not shown.
85 changes: 85 additions & 0 deletions en/docs-italia-theme/data/_config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
# Welcome to Jekyll!
#
# This config file is meant for settings that affect your whole blog, values
# which you are expected to set up once and rarely edit after that. If you find
# yourself editing this file very often, consider using Jekyll's data files
# feature for the data you need to update frequently.
#
# For technical reasons, this file is *NOT* reloaded automatically when you use
# 'bundle exec jekyll serve'. If you change this file, please restart the server process.

# Site settings
# These are used to personalize your new site. If you look in the HTML files,
# you will see them accessed via {{ site.title }}, {{ site.email }}, and so on.
# You can create any custom variable you would like, and they will be accessible
# in the templates via {{ site.myvariable }}.

title: Developers Italia
description: La comunità italiana degli sviluppatori di servizi pubblici
author: Team Digitale e AgID
twitter:
username: developersITA

email: teamdigitale@governo.it
baseurl: "" # the subpath of your site, e.g. /blog
url: "https://developers.italia.it"
twitter_username: developersITA
github_username: italia
piwik: teamdigitale
google_analytics: UA-96140462-1

# Build settings
markdown: kramdown
gems:
- jekyll-feed
- jekyll-seo-tag
- jekyll-redirect-from
- jekyll-paginate
- jekyll-toc
exclude:
- Gemfile
- Gemfile.lock

paginate: 10
paginate_path: "/news/page:num/"

# Custom vars
theme_color: "#0066cc"
css_theme: t-Pac
owner_short: AgID
owner_full: AgID
owner_link: http://www.agid.gov.it
logo: /assets/icons/logo-it.png
owner_logo: https://www.spid.gov.it/assets/img/agid-logo-bb.svg
partner_short: Team Digitale
partner_full: Team per la Trasformazione Digitale
partner_link: https://teamdigitale.governo.it
privacy_link: https://developers.italia.it/it/privacy-policy
gov_logo: https://teamdigitale.governo.it/images/loghi/governo.svg
partner_logo: https://teamdigitale.governo.it/images/loghi/dt-logo.svg
pill: beta

collections:
pages:
output: true
permalink: /:path/
layout: page
projects:
output: true
permalink: /:path/
layout: project
faqs:
output: false

defaults:
-
scope:
path: "" # an empty string here means all files in the project
type: "pages"
values:
subnav: "subnav"
scope:
path: "" # an empty string here means all files in the project
type: "projects"
values:
toc: true

0 comments on commit 5eaf889

Please sign in to comment.