$bid = 'myblock';
$block = \Drupal\block_content\Entity\BlockContent::load($bid);
$render = \Drupal::entityTypeManager()->getViewBuilder('block_content')->view($block);
$block_manager = \Drupal::service('plugin.manager.block');
| # Taxonomy terms: | |
| - https://gist.github.com/facine/35bb291811c146b6fc9e#file-create_taxonomy_term-php | |
| # Menu links: | |
| - https://gist.github.com/facine/35bb291811c146b6fc9e#file-create_menu_link-php | |
| # File items: | |
| - https://gist.github.com/facine/35bb291811c146b6fc9e#file-create_file-php | |
| # Nodes: |
| #!/bin/bash | |
| # A simple script to backup an organization's GitHub repositories. | |
| #------------------------------------------------------------------------------- | |
| # NOTES: | |
| #------------------------------------------------------------------------------- | |
| # * User @jimklimov (and probably some others called out in the long comment | |
| # thread below) have modified this script to make it more robust and keep | |
| # up with various changes in the GitHub API and response format at: | |
| # https://github.com/jimklimov/github-scripts |