- Generate the file:
$ awk 'BEGIN { for(c=0;c<10000000;c++) printf "<p>LOL</p>" }' > 100M.html
$ (for I in `seq 1 100`; do cat 100M.html; done) | pv | gzip -9 > 10G.boomgz
- Check it is indeed good:
$ awk 'BEGIN { for(c=0;c<10000000;c++) printf "<p>LOL</p>" }' > 100M.html
$ (for I in `seq 1 100`; do cat 100M.html; done) | pv | gzip -9 > 10G.boomgz
#!/bin/bash | |
set -euo pipefail | |
IFS=$'\n\t' | |
# Ubuntu 18.04 dev Server | |
# Run like - bash install_lamp.sh | |
# Script should auto terminate on errors | |
echo -e "\e[96m Adding PPA \e[39m" | |
sudo add-apt-repository -y ppa:ondrej/apache2 |
<!-- Facebook Custom Audience Pixel Code - Placed on Every Page of Site --> | |
<script> | |
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod? | |
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n; | |
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0; | |
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window, | |
document,'script','//connect.facebook.net/en_US/fbevents.js'); | |
fbq('init', '{{facebook pixel}}'); | |
fbq('track', 'PageView'); | |
</script> |
SELECT sub_query.month_ordered, | |
sub_query.year_ordered, | |
AVG(sub_query.base_subtotal) AS average_base_subtotal, | |
AVG(sub_query.discount_amount) AS average_discount_amt, | |
AVG(sub_query.order_qty) AS average_total_item_count, | |
COUNT(sub_query.entity_id) AS total_orders | |
FROM | |
(SELECT so.entity_id, | |
MONTH(so.created_at) AS month_ordered, | |
YEAR(so.created_at) AS year_ordered, |
#### by MageHost.pro #### | |
# execute in Magento 2 root: | |
find vendor app -regextype 'egrep' -type f -regex '.*/layout/.*\.xml' -not -regex '.*(vendor/magento/|/checkout_|/catalogsearch_result_|/dotmailer).*' | xargs grep --color -n -e 'cacheable="false"' |
<?php | |
/******************************************************************** | |
File name: rest_test.php | |
Description: | |
A PHP test script that calls the Coupon AutoGen extension | |
to Magento's REST API. | |
The Coupon AutoGen API takes: | |
-- the rule ID of the "Generate Coupons" rule to execute | |
-- the number of coupon codes to generate | |
-- the length of each coupon code |
sudo apt-get update | |
sudo apt-get install apt-transport-https openjdk-8-jre-headless | |
sudo wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add - | |
sudo echo "deb https://artifacts.elastic.co/packages/6.x/apt stable main" | sudo tee /etc/apt/sources.list.d/elastic-6.x.list | |
sudo apt-get update && sudo apt-get install elasticsearch | |
sudo /bin/systemctl daemon-reload | |
sudo /bin/systemctl enable elasticsearch.service | |
sudo systemctl start elasticsearch.service | |
sudo ls -la /var/log/elasticsearch/ |
<?php | |
$header = <<<'EOF' | |
Esse arquivo faz parte de <Empresa/Projeto> | |
(c) Nome Autor <e-mail> | |
Lorem ipsum ... | |
EOF; |
<action method="removeItem"><type>js_css</type><name>smartwave/bootstrap/css/bootstrap.optimized.min.css</name></action> | |
<action method="removeItem"><type>skin_css</type><name>css/local.css</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/jquery-1.11.3.min.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/jquery-migrate-1.2.1.min.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/jquery-noconflict.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/plugins/fancybox/js/jquery.fancybox.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/ajaxcart/ajaxaddto.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/plugins/etalage/jquery.etalage.min.js</name></action> | |
<action method="removeItem"><type>js</type><name>smartwave/jquery/plugins/etalage/jquery.zoom.min.js</name></action> | |
<action method="removeItem"><type>js</type><nam |
/* ============================================================================= */ | |
/* VERSAO 1.9.x DO MAGENTO - ATUALIZACAO DE DADOS */ | |
/* ============================================================================= */ | |
SET NAMES 'utf8'; | |
/* admin_role */ | |
UPDATE `admin_role` SET `role_name`='Administradores' WHERE `role_name`='Administrators'; | |
/* api2_acl_role */ |