Skip to content
This repository was archived by the owner on Jan 26, 2018. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
uuid: 1c5bd5f0-fcbc-4721-ad01-1aed89e32022
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Existen más referencias de esto? El artículo es de 2013 y no lo deja muy claro, a parte de que parece que habla de compartir configuración entre sitios distintos. Cuando dice:

-field_uuid: 84e904df-2f14-46e8-9700-e00c5ca3f7d3
+field_name: field_blog_image
Note that this relies on the specific handling of the FieldInstance class and may not be a general solution.

parece indicar que cuando se borra el uuid se tiene que sustituir con otro identificador (en el ejemplo, el machine name del campo).

Un poco más preocupante es la afirmación:

Edit: also note (see comments) that it is important to include a hardcoded UUID if you want to avoid that your configuration items are seen by Drupal as different items between your development and production sites, causing configuration import/export between the two to fail.

Estaría bien ver una opinión más reciente de alguien más involucrado en CMI, o encontrar referencias fiables que afirmen que es una buena práctica borrar los uuids una vez exportada la configuración.

Si esa fuera la práctica estándar, debería ser fácil encontrar otras referencias. En un ejemplo de un site Drupal 8 que he econtrado los uuids están en el código: https://github.com/geerlingguy/demo-drupal-8/tree/master/sites/default/config/staging

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jo no tinc respostes a cap pregunta de les que planteges, @pereorga i tot i que els dubtes que planteges són molt raonables, he estat mirant el perfil d'instal·lació standard de drupal8 i veig que allà no hi ha uuid (http://cgit.drupalcode.org/drupal/tree/core/profiles/standard/config/install/core.base_field_override.node.page.promote.yml)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Acabo de parlar amb Alex Pott (CMI) i m'ha confirmat que els UUIDs no s'han d'esborrar.

Al comentar-li el problema que tenim amb drush make, em contesta "don't use drush make, use the Configuration Installer. That will solve your problem"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Entonces esto se puede mergear con master desde mi punto de vista.

Abrimos issue para deshacernos del make

langcode: ca
status: true
dependencies:
config:
- node.type.drupal_cat_project
id: node.drupal_cat_project.promote
field_name: promote
entity_type: node
bundle: drupal_cat_project
label: 'Promogut a la portada'
description: ''
required: false
translatable: true
default_value:
-
value: 0
default_value_callback: ''
settings:
on_label: Actiu
off_label: Inactiu
field_type: boolean
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
uuid: b05e3e58-ebb6-4395-8839-57cacdf5a904
langcode: ca
status: true
dependencies:
config:
- node.type.drupal_cat_project
id: node.drupal_cat_project.title
field_name: title
entity_type: node
bundle: drupal_cat_project
label: Nom
description: ''
required: true
translatable: true
default_value:
-
value: ''
default_value_callback: ''
settings: { }
field_type: string
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
uuid: 30633dc4-d409-4d07-a400-c9429b94d6ec
langcode: ca
status: true
dependencies:
config:
- field.field.node.drupal_cat_project.body
- field.field.node.drupal_cat_project.field_project_image
- field.field.node.drupal_cat_project.field_project_organization
- field.field.node.drupal_cat_project.field_project_url
- node.type.drupal_cat_project
module:
- image
- link
- text
id: node.drupal_cat_project.default
targetEntityType: node
bundle: drupal_cat_project
mode: default
content:
body:
type: text_textarea_with_summary
weight: 4
settings:
rows: 9
summary_rows: 3
placeholder: ''
third_party_settings: { }
created:
type: datetime_timestamp
weight: 5
settings: { }
third_party_settings: { }
field_project_image:
type: image_image
weight: 2
settings:
progress_indicator: throbber
preview_image_style: thumbnail
third_party_settings: { }
field_project_organization:
type: entity_reference_autocomplete
weight: 3
settings:
match_operator: CONTAINS
size: 60
placeholder: ''
third_party_settings: { }
field_project_url:
type: link_default
weight: 1
settings:
placeholder_url: ''
placeholder_title: ''
third_party_settings: { }
langcode:
type: language_select
weight: 9
settings: { }
third_party_settings: { }
promote:
type: options_buttons
weight: 6
settings: { }
third_party_settings: { }
sticky:
type: boolean_checkbox
weight: 7
settings:
display_label: true
third_party_settings: { }
title:
type: string_textfield
weight: 0
settings:
size: 60
placeholder: ''
third_party_settings: { }
uid:
type: entity_reference_autocomplete
weight: 8
settings:
match_operator: CONTAINS
size: 60
placeholder: ''
third_party_settings: { }
hidden: { }
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
uuid: 0b47957b-6964-4dc5-8f39-5729b7be8c1c
langcode: ca
status: true
dependencies:
config:
- field.field.node.drupal_cat_project.body
- field.field.node.drupal_cat_project.field_project_image
- field.field.node.drupal_cat_project.field_project_organization
- field.field.node.drupal_cat_project.field_project_url
- node.type.drupal_cat_project
module:
- image
- link
- text
- user
id: node.drupal_cat_project.default
targetEntityType: node
bundle: drupal_cat_project
mode: default
content:
body:
type: text_default
weight: 0
settings: { }
third_party_settings: { }
label: hidden
field_project_image:
type: image
weight: 1
settings:
image_style: ''
image_link: ''
third_party_settings: { }
label: hidden
field_project_organization:
type: entity_reference_label
weight: 3
settings:
link: true
third_party_settings: { }
label: inline
field_project_url:
type: link
weight: 2
settings:
trim_length: 80
url_only: false
url_plain: false
rel: ''
target: ''
third_party_settings: { }
label: hidden
links:
weight: 4
settings: { }
third_party_settings: { }
hidden:
langcode: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
uuid: e1fc64b7-7813-4da4-9f00-dca00cbbb830
langcode: ca
status: true
dependencies:
config:
- core.entity_view_mode.node.teaser
- field.field.node.drupal_cat_project.body
- field.field.node.drupal_cat_project.field_project_image
- field.field.node.drupal_cat_project.field_project_organization
- field.field.node.drupal_cat_project.field_project_url
- node.type.drupal_cat_project
module:
- text
- user
id: node.drupal_cat_project.teaser
targetEntityType: node
bundle: drupal_cat_project
mode: teaser
content:
body:
label: hidden
type: text_summary_or_trimmed
weight: 101
settings:
trim_length: 600
third_party_settings: { }
links:
weight: 100
hidden:
field_project_image: true
field_project_organization: true
field_project_url: true
langcode: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
uuid: df1d5226-8571-4108-9e02-2bc4f77aff79
langcode: ca
status: true
dependencies:
config:
- field.storage.node.body
- node.type.drupal_cat_project
module:
- text
id: node.drupal_cat_project.body
field_name: body
entity_type: node
bundle: drupal_cat_project
label: Descripció
description: ''
required: true
translatable: true
default_value: { }
default_value_callback: ''
settings:
display_summary: true
field_type: text_with_summary
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
uuid: df9c8a7d-9982-4794-9230-4846492eb062
langcode: ca
status: true
dependencies:
config:
- field.storage.node.field_project_image
- node.type.drupal_cat_project
module:
- image
id: node.drupal_cat_project.field_project_image
field_name: field_project_image
entity_type: node
bundle: drupal_cat_project
label: 'Imatge del projecte'
description: ''
required: false
translatable: false
default_value: { }
default_value_callback: ''
settings:
file_directory: ''
file_extensions: 'png gif jpg jpeg'
max_filesize: ''
max_resolution: ''
min_resolution: ''
alt_field: true
alt_field_required: false
title_field: false
title_field_required: false
default_image:
uuid: ''
alt: ''
title: ''
width: null
height: null
handler: 'default:node'
handler_settings: { }
field_type: image
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
uuid: bb4448c9-1e52-4b69-8c03-3fdee536b7bb
langcode: ca
status: true
dependencies:
config:
- field.storage.node.field_project_organization
- node.type.drupal_cat_project
module:
- entity_reference
id: node.drupal_cat_project.field_project_organization
field_name: field_project_organization
entity_type: node
bundle: drupal_cat_project
label: 'Organització involucrada'
description: ''
required: false
translatable: false
default_value: { }
default_value_callback: ''
settings:
handler: 'default:node'
handler_settings:
target_bundles:
drupal_cat_project: drupal_cat_project
sort:
field: _none
field_type: entity_reference
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
uuid: 00a378de-4258-4aba-8c03-0338329a00cf
langcode: ca
status: true
dependencies:
config:
- field.storage.node.field_project_url
- node.type.drupal_cat_project
module:
- link
id: node.drupal_cat_project.field_project_url
field_name: field_project_url
entity_type: node
bundle: drupal_cat_project
label: Enllaç
description: ''
required: false
translatable: false
default_value: { }
default_value_callback: ''
settings:
link_type: 16
title: 0
field_type: link
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
uuid: 22d76fc2-8249-4927-9305-5d5a987dbad9
langcode: ca
status: true
dependencies:
module:
- image
- node
id: node.field_project_image
field_name: field_project_image
entity_type: node
type: image
settings:
uri_scheme: public
default_image:
uuid: ''
alt: ''
title: ''
width: null
height: null
target_type: file
display_field: false
display_default: false
target_bundle: null
module: image
locked: false
cardinality: -1
translatable: true
indexes: { }
persist_with_no_fields: false
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
uuid: 86a5fb5d-c6b5-47c5-b400-c2a3cd0bff4e
langcode: ca
status: true
dependencies:
module:
- entity_reference
- node
id: node.field_project_organization
field_name: field_project_organization
entity_type: node
type: entity_reference
settings:
target_type: node
module: entity_reference
locked: false
cardinality: -1
translatable: true
indexes: { }
persist_with_no_fields: false
Loading