You can set the time by using the following command.
date -s "06 DEC 2017 10:00:00"
You can set the time by using the following command.
date -s "06 DEC 2017 10:00:00"
Use –block-size=M /G
For example ls -lrt --block-size=GB
will list the files with size info in GB
Run the following command to see if php-fpm is running
netstat -pl | grep php-fpm.sock
Run the following command
gunzip < [backupfile.sql.gz] | mysql -u[username] -p[password] [database]
escapeshellcmd() escapes any characters in a string that might be used to trick a shell command into executing arbitrary commands. This function should be used to make sure that any data coming from user input is escaped before this data is passed to the exec() or system() functions, or to the backtick operator.
Following characters are preceded by a backslash: &#;`|*?~<>^()[]{}$\, \x0A and \xFF. ‘ and ” are escaped only if they are not paired. In Windows, all these characters plus % and ! are replaced by a space instead.
<?php $command = './configure '.$_POST['configure_options']; $escaped_command = escapeshellcmd($command); system($escaped_command); ?>
In this tutorial I will explain how to create product from CLI.
Declare the module
File: app/code/PHPCodez/Product/etc/module.xml Continue reading Create product programmatically Magento 2
Here I am creating a module PHPCodez_Customers that will help us to create customers from commandline.
Create folders for the modul app/code/PHPCodez/Customers Continue reading Magento 2 Create Customers Using CLI
Follow the below steps to create new command line in to Console CLI in Magento 2.
Define command in di.xml
In di.xml file, you can use a type with name Magento\Framework\Console\CommandList to define the command option. Continue reading Add New Command Magento 2
tar -czvf name-of-archive.tar.gz name-of-the-file-to-be-compressed
-c: Create an archive.
-z: Compress the archive with gzip.
-v: Display progress in the terminal while creating the archive(verbose mode).
-f: Allowsto specify the filename of the archive.
Install the CompizConfig Settings Manager (CCSM).
Hit Alt-F2 and input about:config and hit enter.