$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');
pip install gdown gdown 1l_5RK28JRL19wpT22B-DY9We3TVXnnQQ
When the shared files on Google Drive is downloaded, it is necessary to change the download method by the file size. The boundary of file size when the method is changed is about 40MB.
find . -type f | xargs -I {} bash -c "iconv -f utf-8 -t utf-16 {} &>/dev/null || echo {}" > utf8_fail |
// No Security | |
{ | |
"rules": { | |
".read": true, | |
".write": true | |
} | |
} |
Better Drupal Building
Configuration Management and Dependencies
Theming
[ | |
{ | |
"id": "1", | |
"nombre": "Pinar del Río", | |
"municipios": [ | |
"Consolación del Sur", | |
"Guane", | |
"La Palma", | |
"Los Palacios", | |
"Mantua", |
#!/bin/bash | |
function countContainers() { | |
docker ps -q $1 | wc -l | |
} | |
function countCrashedContainers() { | |
docker ps -a | grep -v -F 'Exited (0)' | grep -c -F 'Exited (' | |
} |
How to disable auto-save: | |
Go to File > Settings (Ctrl+Alt+S). | |
Go to Appearance & Behavior > System Settings. | |
Make sure the two are unchecked: | |
Save files on frame deactivation | |
Save files automatically if application is idle for x sec. | |
Go to Editor > General > Editor Tabs | |
Put a checkmark on "Mark modified files with asterisk" | |
(Optional but recommended) Under "Tab Closing Policy", select "Close non-modified files first". You may also want to increase the number of allowed tabs. | |
Click Apply > OK. |