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
#!/usr/bin/with-contenv bashio | |
# shellcheck shell=bash | |
# ref: https://github.com/alexbelgium/hassio-addons/discussions/1467#discussioncomment-11699236 | |
# this script will look for your immich database backup file placed in path | |
# /share/postgresql_immich_restore.sql | |
# | |
# it must not be gzipped. | |
# requires: Terminal add-on to place files, a way you knwo how to place your .sql on HAOS server. I used an external USB I mounted. | |
# |
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
# | |
# udev rule | |
# Mount USB drive to the media directory using the partition name as mount point | |
# | |
# Description: | |
# Created for Home Assistant OS, this rule mounts any USB drives | |
# into the Hassio media directory (/mnt/data/supervisor/media). | |
# When a USB drive is connected to the board, the rule creates one directory | |
# per partition under the media directory. The newly created partition is named | |
# as the partition name. If the partition does not have a name, then the following |
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
<?php | |
namespace Uptactics\PpsTheme\Test\Unit; | |
use PHPUnit\Framework\TestCase; | |
class CronListTest extends TestCase | |
{ | |
private $filePath; |
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/env bash | |
# Requires HTTPie and JQ | |
ORG_NAME='xxxxxx' | |
API_KEY='xxxxxx' | |
SLEEP_S=0.5 | |
# End of variables that need to change | |
package_url="https://app.repman.io/api/organization/${ORG_NAME}/package" |
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
commands: | |
N98\Magento\Command\System\CheckCommand: | |
php: | |
required-extensions: | |
- bcmath | |
- ctype | |
- dom | |
- fileinfo | |
- json | |
- 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
Add the following to plugins/index.js | |
module.exports = (on, config) => { | |
on('task', { | |
log (message) { | |
console.log(message) | |
return null | |
} | |
}) | |
} |
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
Magento 2 Paypal has a weird limit that you cannot enable Paypal Expresss checkout and other payment methods | |
(like paypal payflowpro) at the same time. | |
Sure, Paypal Payflow has the option to enable express, but that is not teh same thing. | |
The 'express' in paypal payflow pro are direct checkout buttons on product and cart pages, which directly | |
make a purchase to Paypal, it does NOT add a payment method to select in checkout. | |
A bit of a hack to enable them both on checkout, so as selectable payment options is to lock the express | |
values to enbal in env.php |
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
rm composer.json | |
rm composer.lock | |
composer require magento-ecg/coding-standard mandrill/mandrill | |
[ -d "code_sniff" ] || mkdir code_sniff | |
phpcs --config-set ignore_warnings_on_exit 1 | |
phpcs --config-set ignore_errors_on_exit 1 | |
phpcs --report-file=./code_sniff/sniff.txt --standard=./vendor/magento-ecg/coding-standard/Ecg ${PATH_TO_SNIFF} | |
php_cwd=`php << 'EOF' | |
<?php | |
require __DIR__ . '/vendor/autoload.php'; |
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
#buddy starts in the working dir | |
SCANDIR=$(pwd) | |
wget http://www.rfxn.com/downloads/maldetect-current.tar.gz | |
tar -xzf maldetect-current.tar.gz | |
cd maldetect-1.6.4 | |
/bin/bash ./install.sh | |
#make a fake vi to just echo out the report | |
echo '#!/bin/bash' >/usr/bin/vi | |
echo 'echo $1' >>/usr/bin/vi | |
chmod +x /usr/bin/vi |
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
#!/usr/bin/env php | |
## steps | |
# | |
# fix where app:config:dump was run, adn value sin magento db is outof sync (so they ONLy exist in the dumped configs) | |
# | |
# Copy your app/etc/config.php (or app/etc/env.php) to bin folder | |
# delete from the app/etc/config.php (or env.php) file the values you want to re-import TO DB | |
# run bin/magento app:config:import (to process the changes you just made) | |
# run this script: ./bin/set-config.php --config config.php (or env.php) |
NewerOlder