Skip to content

Instantly share code, notes, and snippets.

Avatar

Vijaya Chandran Mani vijaycs85

View GitHub Profile
View menu.php
<?php
function menu_get_Links_source($name, $default) {
$config = \Drupal::config('menu.settings');
// When menu module is not enabled, we need a hardcoded default value.
return module_exists('menu') ? $config->get('main_links') : 'main';
}
/**
* Returns an array of links to be rendered as the Main menu.
View currency.schema.yml
currency.exchange_rate_provider:
type: mapping
label: 'Currency excange rate provider' # feel free to update label
mapping:
plugins:
- type: boolean
label: 'Plugin status'
View How to co-maintainer.txt
How I got in (part of current process):
Step 1: Saw https://twitter.com/CatherineOmega/status/388037250896121856
Step 2: Created https://drupal.org/node/2108697
Step 3: Fixed by chx at https://drupal.org/comment/8140997#comment-8140997
Step 4: Found podarok shares my interests. So made as co-maintainer.
Step 5: We made a minor release (with 20+ fixes) in Dec 2013 - https://drupal.org/node/2161141
Step 6: Finally created http://www.drupaldate.org/ to make our scrum team run like other agile team :)
What can be improved:
View entity_area.yml
views.area.entity_entity_test:
type: views_area
label: 'Text custom'
mapping:
field:
type: string
label: ''
id:
type: string
label: ''
View block-header.yml
id: entity_block # covered by views_handler
table: views # covered by views_handler
field: entity_block # covered by views_handler
relationship: none # covered by views_handler
group_type: group # covered by views_handler
admin_label: '' # covered by views_handler
dependencies:
module:
- views
empty: false # covered by views_area
View language_config.diff
diff --git a/core/modules/language/lib/Drupal/language/Tests/LanguageConfigSchemaTest.php b/core/modules/language/lib/Drupal/language/Tests/LanguageConfigSche
index 2a5d8f5..dfeb8b2 100644
--- a/core/modules/language/lib/Drupal/language/Tests/LanguageConfigSchemaTest.php
+++ b/core/modules/language/lib/Drupal/language/Tests/LanguageConfigSchemaTest.php
@@ -51,6 +51,10 @@ function setUp() {
* Tests whether the language config schema is valid.
*/
function testValidLanguageConfigSchema() {
+ // Make sure no language configuration available by default.
+ $config_data = \Drupal::config('language.settings')->get();
View config.php
array ( 'menu_link' => array ( 'menu_link' => array ( 'language' => array ( 'default_configuration' => array ( 'langcode' => 'site_default', 'language_show' => true, ), ), ), ), 'user' => array ( 'user' => array ( 'language' => array ( 'default_configuration' => array ( 'langcode' => 'en', 'language_show' => true, ), ), ), ), )
View process.schema.yml
process:
type: sequence
sequnce:
#this type I'm talking about.
- type: string
label: ''
process:
type: sequence
View migration.schema.yml
migration.migration.*:
type: mapping
label: ''
mapping:
id:
type: string
label: ''
label:
type: label
label: ''
View app.php
<?php
require_once __DIR__ . '/../vendor/autoload.php';
$app = new Silex\Application();
$app->get('/hello/{name}', function($name) use($app) {
return 'Hello '.$app->escape($name);
});
$app->finish(function() {
sleep(20);