This file contains hidden or 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
aws s3 ls s3://${BUCKET} --recursive | awk '{print "http://${DOMAIN_NAME}/"$4 }' |
This file contains hidden or 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
// Not valid JSON due to comments. | |
// The majority of the fields are missing. | |
{ | |
"messageHeader": { | |
"id": "9e8f3cfc-29c2-11e7-93ae-92361f002671", | |
// Values here are different from the documentation. | |
"messageType": "MetadataRecordCreate" | |
This file contains hidden or 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
""" | |
Credits: Carl Wilson (Open Preservation Foundation) | |
Using the search root for datacite: https://search.datacite.org/data-centers?member-id=bl&page= | |
I iterate through the data centres (in this case those that are BL assigned), then for each data centre I visit the | |
works page, e.g. https://search.datacite.org/data-centers/bl.ads and cycle through the works. I stop | |
(usually on the first) when I can scrape the doi from something like | |
https://doi.org/10.15124/19B43AA8-744A-404B-A8FF-7B0F931BF6D3 where the 3rd part of the URL is the DOI, in this case | |
for York University. |
This file contains hidden or 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
python -t -t -m py_compile file.py |
This file contains hidden or 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
grep -A 25 -R --include='Kconfig' 'LOCALVERSION_AUTO' * |
This file contains hidden or 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
SELECT | |
uid, | |
name, | |
mail, | |
FROM_UNIXTIME(created) AS 'account created', | |
FROM_UNIXTIME(access) AS 'last access', | |
FROM_UNIXTIME(login) AS 'last login' | |
FROM users | |
WHERE mail = '[email protected]'\G |
This file contains hidden or 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
drush php-eval "print_r(theme_get_registry());" | grep "${TEMPLATE_SEARCH_MATCH}" |
This file contains hidden or 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
for i in $(find . -name *.info); do sed -i 's/target/replace/g' $i; done |
This file contains hidden or 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
<?php | |
$server = search_api_server_load('acquia_search_solr_server'); | |
$index = search_api_index_load('node_index'); | |
$query = new SearchApiQuery($index); | |
$query->condition('type', 'article'); | |
$results = $query->execute(); |
NewerOlder