This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is what we added to Node Docker image to install Terminus | |
# Install everything we need from php | |
RUN apk add curl | |
RUN apk add php | |
RUN apk add php-cli | |
RUN apk add php-json | |
RUN apk add php-phar | |
RUN apk add php-iconv | |
RUN apk add php-mbstring |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Move files from files dir & add image node. | |
*/ | |
function hook_update_N(&$sandbox) { | |
if (!isset($sandbox['progress'])) { | |
$sandbox['progress'] = 0; | |
$sandbox['current_nid'] = 0; | |
$sandbox['max'] = db_query("SELECT COUNT(entity_id) FROM {field_data_field_body} WHERE field_body_value LIKE '%src=\"https://www.example.com/sites/default/files/%'")->fetchField(); | |
$sandbox['messages'] = array(); | |
$sandbox['csv'] = array(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
parent_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P ) | |
FILES=${parent_path}/files/* | |
counter=0 | |
for f in $FILES | |
do | |
if [ -f "$f" ]; then | |
file=${f##*/} | |
if [[ ${file} != *"."* ]]; then | |
if [[ "$counter" -lt 2499 ]]; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
parent_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P ) | |
FILES=${parent_path}/files/* | |
counter=0 | |
for f in $FILES | |
do | |
if [ -f "$f" ]; then | |
file=${f##*/} | |
if [[ ${file} != *"."* ]]; then | |
if [[ "$counter" -lt 2499 ]]; then |