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
| import { DynamoDB } from 'aws-sdk'; | |
| import { config } from 'aws-sdk'; | |
| import * as dotenv from 'dotenv'; | |
| dotenv.config(); | |
| async function test() { | |
| config.update({ | |
| region: 'NOKEY', | |
| secretAccessKey: 'NOKEY', |
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
| /etc/php5/cli/php.ini is for the CLI PHP program, which you found by running php on the terminal. | |
| /etc/php5/cgi/php.ini is for the php-cgi system which isn't specifically used in this setup. | |
| /etc/php5/apache2/php.ini is for the PHP plugin used by Apache. This is the one you need to edit for changes to be applied for your Apache setup. |
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
| alias cd...="cd ../.." | |
| alias cd....="cd ../../.." | |
| alias cd.....="cd ../../../.." | |
| alias chrome="open -a 'Google Chrome'" | |
| alias emacs="emacs -nw" |
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
| var keepsHisWord; | |
| keepsHisWord = true; | |
| promise1 = new Promise(function(resolve, reject) { | |
| if (keepsHisWord) { | |
| resolve("The man likes to keep his word"); | |
| } else { | |
| reject("The man doesnt want to keep his word"); | |
| } | |
| }); | |
| console.log(promise1); |
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
| import { SQSEvent } from 'aws-lambda'; | |
| console.log('Loading function'); | |
| exports.handler = async (event: SQSEvent): Promise<void> => { | |
| console.log('Received event:', JSON.stringify(event, null, 2)); | |
| for (const { messageId, body } of event.Records) { | |
| console.log('SQS message %s: %j', messageId, body); | |
| } | |
| return `Successfully processed ${event.Records.length} messages.`; |
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 | |
| $productDescription = "ranjani, is a very good , girl in the town. She lives in england , india and china at the same time."; | |
| echo $productDescription; | |
| $productDescriptionStripped = str_replace(',','', $productDescription); | |
| echo $productDescriptionStripped; | |
| echo $productDescription; |
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
| explain SELECT `cataloginventory_stock_status`.`product_id`, `cataloginventory_stock_status`.`stock_status` FROM `cataloginventory_stock_status` WHERE (product_id IN('63376', '63377', '124450', '124451')) AND (stock_id=1) AND (website_id=1) | |
| explain SELECT `l`.`product_id`, `l`.`parent_id` FROM `catalog_product_super_link` AS `l` | |
| INNER JOIN `catalog_product_entity` AS `e` ON e.entity_id = l.product_id AND e.required_options = 0 WHERE (parent_id = '63378') | |
| explain select product_id from catalog_product_super_link where parent_id = '63378' | |
| explain select stock_status from cataloginventory_stock_status where stock_id = '1' and website_id = '1' and product_id IN (select product_id from catalog_product_super_link where parent_id = '63378') |
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
| stop & remove docker containers: | |
| docker stop $(docker ps -a -q); docker rm $(docker ps -a -q); docker volume rm $(docker volume ls -qf dangling=true) ; | |
| remove problematic networks: | |
| docker network rm(docker network ls -q) | |
| ./reset.sh |
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
| -- G1802717 - denim jacket - blue | |
| delete from enterprise_url_rewrite_redirect where target_path = 'catalog/product/view/id/631899’ | |
| delete from enterprise_url_rewrite where target_path = 'catalog/product/view/id/631899' | |
| -- DD912972 - ribbed midi dress - cream | |
| delete from enterprise_url_rewrite_redirect where target_path = 'catalog/product/view/id/638873’ | |