Skip to content

Localization seed files for OFN ES installation.

Notifications You must be signed in to change notification settings

danypr92/l10n_es

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

l10n_es

Localization seed files for OFN ES installation.


Data Structure

states.yml --> Provincias

    ---
    - name: A Coruña (La Coruña)
      country_id: '188'
      id: '101'
      abbr: C
    - name: Araba (Álaba)
      country_id: '188'
      id: '102'
      abbr: VI

countries.yml --> Only need ES

    ---
    countries_188:
      id: '188'
      name: Spain
      iso3: ESP
      iso: ES
      iso_name: SPAIN
      numcode: '724'

How it works?

provision.yml

When you run playbooks/provisioning.yml playbook the app role run two tasks related with this repository:

copy seeds.rb

Copy seeds.rb file in {{ app_path }}/shared/config. This file loads states.yml and creates a record in the db with name, abbr and country fields.

get l10n repo

You need to specify where is l10n repo located in your inventory/group_vars file. In our case is inventory/group_vars/es.yml. With the key l10n_repo like here. The task clone l10n repo in {{ l10n_path }}.

deploy.yml

When you run playbook/deploy.yml playbook the deploy role run two tasks:

symlink into the repo

Create a symbolic link in {{ build_path }}/db/default/spree/states.yml from {{ l10n_path }}/states.yml .

seed database

Run the rake db:seed

About

Localization seed files for OFN ES installation.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published