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
| # cd <magent install directory> | |
| ./bin/magento setup:install --admin-firstname="Joeyne" --admin-lastname="Stone" --admin-email="lijunencode@gmail.com" --use-secure=1 --base-url-secure="https://mgt-224.joeyne.dev/" --use-secure-admin=1 --base-url="https://mgt-224.joeyne.dev/" --db-host="localhost" --db-name="mgt-224" --db-prefix="mgt_" --db-user="magento" --db-password="16c5088ed3a0a51e69a4ecfe5860270a" --backend-frontname="adm1n" --admin-user="adm1n" --admin-password="adm1n_123" |
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
| ssh-keygen -t rsa -C "lijunencode@gmail.com" |
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
| /** get Locale by timestamp ** | |
| * @Param timestamp int | |
| * @return string | |
| * | |
| * var mydate=new Date(); | |
| * var myyear=mydate.getFullYear(); | |
| * var mymonth=mydate.getMonth()+1;// 注:月数从 0~11 为一月到十二月 | |
| * var mydat=mydate.getDate(); | |
| * var myhours=mydate.getHours(); | |
| * var myminutes=mydate.getMinutes(); |
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
| # m h dom mon dow command | |
| 01 04 * * 4 certbot renew --force-renewal --post-hook 'service nginx reload |
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
| #------------------------- base -------------------------# | |
| # clone repos 克隆仓库 | |
| git clone git@47.93.24.225:xunta/xunta-php.git | |
| # 查看本地分支 | |
| git branch | |
| # 查看远程分支 | |
| git branch -r |
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
| nginx_process_num=$(ps -ef | grep nginx | grep -v grep | wc -l) | |
| fpm_process_num=$(ps -ef | grep fpm | grep -v grep | wc -l) | |
| # 判断Nginx是否启动 | |
| if [ $nginx_process_num -eq 0 ] | |
| then | |
| service nginx start | |
| echo -e "\033[32m nginx have been started, successed!\033[0m" | |
| else | |
| echo -e "\033[34m nginx already be started with process_num $nginx_process_num !!! \033[0m" | |
| fi |
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 Modules] | |
| calendar | |
| Core | |
| ctype | |
| date | |
| dom | |
| exif | |
| fileinfo | |
| filter | |
| ftp |
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
| const gulp = require('gulp'); | |
| const uglify = require('gulp-uglify-es').default; | |
| const cleanCSS = require('gulp-clean-css'); | |
| const rename = require('gulp-rename'); | |
| const sourcemaps = require('gulp-sourcemaps'); | |
| // 压缩JS文件,并建立map映射 | |
| gulp.task('minify-js', async function () { | |
| await gulp.src(['public/assets/js/**/*.js', '!public/assets/js/**/*.min.js']) | |
| .pipe(rename({extname: '.min.js'})) |
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
| <style type="text/css"> | |
| body, html { | |
| margin: 0; | |
| padding: 0; | |
| font-family: 'Quicksand' !important; | |
| font-weight: bold !important; | |
| color: white !important; | |
| } | |
| .center { | |
| background-color: rgba(30, 30, 30, 1) !important; |
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
| /** | |
| * [生成随机字符串] | |
| * @param integer $type 字符类型 0: 数字; 1: 小写字母; 2: 大写字母; 3: 混合字符(默认) | |
| * @param integer $len 字符长度 默认长度为4个字符 | |
| * @return string | |
| */ | |
| if (!function_exists('create_code')) { | |
| function create_code($type = 3, $len = 4) { | |
| $type = (int)$type; |
OlderNewer