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
Running bash [-c /tmp/test_ddev.sh] | |
======= Existing project config ========= | |
These config files were loaded for project p-ci: [/home/bserem/Development/anrt/p-ci/.ddev/config.yaml /home/bserem/Development/anrt/p-ci/.ddev/config.hooks.yaml] | |
name: p-ci | |
type: drupal9 | |
docroot: web | |
php_version: 8.1 | |
webserver_type: nginx-fpm | |
webimage: drud/ddev-webserver:v1.21.5 | |
router_http_port: 80 |
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
translate([0,0,0]) { | |
difference() { | |
cylinder(h=14, d=30, $fn=360); | |
translate([-4,-4,2.52]) | |
cube([8, 8, 100]); | |
} | |
translate([-10, 10, 0]) { | |
cube([18, 70, 14]); | |
} | |
} |
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
#! /bin/bash | |
for f in *.pdf | |
do | |
fbname=$(basename "$f" .pdf) | |
fbname_safe="${fbname// /_}" | |
mv "$fbname".pdf $fbname_safe.temp.pdf | |
gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=$fbname_safe.pdf $fbname_safe.temp.pdf | |
# To also change PDF title (untested): | |
# gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=$fbname_safe.pdf $fbname_safe.temp.pdf -c "[ /Title (My New Title) /DOCINFO pdfmark" |
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 | |
/** | |
* Implements hook_views_pre_execute(). | |
*/ | |
function HOOK_views_pre_execute(ViewExecutable $view) { | |
if (empty($view->exposed_raw_input['title']) && ($view->query->getPluginId() === "search_api_query")) { | |
$view->query->abort(); | |
} | |
} |
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
OS Information: Linux dragoon 5.16.0-1-amd64 #1 SMP PREEMPT Debian 5.16.7-2 (2022-02-09) x86_64 GNU/Linux | |
User information: uid=1000(bserem) gid=1000(bserem) groups=1000(bserem),4(adm),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video),46(plugdev),109(netdev),112(bluetooth),116(scanner),119(lpadmin),131(i2c),997(docker),998(nordvpn) | |
ITEM VALUE | |
DDEV version v1.18.2 | |
architecture amd64 | |
db drud/ddev-dbserver-mariadb-10.3:v1.18.2 | |
dba phpmyadmin:5 | |
ddev-ssh-agent drud/ddev-ssh-agent:v1.18.0 | |
docker 20.10.12 | |
docker-compose v2.2.2 |
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
#!/usr/bin/php | |
<?php | |
$message = file_get_contents($argv[1]); | |
checkMessage($message); | |
exit(0); | |
function checkMessage($message) { | |
if (strlen($message) < 10) { |
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
#!/bin/bash | |
exec < /dev/tty | |
read -n 1 -p "Would you like to run CI? (y/N) " ans; | |
ans=${ans:-n} # Default is no, always add [skip ci] | |
echo # Just add a new line | |
case $ans in | |
y|Y) | |
exit;; | |
n|N|*) | |
sed -i '$s/$/ [skip ci]/' $1;; |
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
#!/usr/bin/php | |
<?php | |
/** | |
* @file | |
* A Git pre-commit hook script to check files for PHP syntax errors and Drupal | |
* coding standards violations. Requires phpcs and Coder Sniffer: | |
* | |
* @see https://drupal.org/node/1419988 | |
* |
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
/** | |
*Looks for directory *750GB* in the path and removes it for paths. | |
* Based on that you can do any replacements. | |
*/ | |
UPDATE track_locations | |
SET location = replace (location, '750GB/', '') | |
where | |
location LIKE '%750G%'; |
NewerOlder