location ~ /.*\.md {
root /www/;
default_type text/html;
charset UTF-8;
add_before_body /strapdown/prepend;
add_after_body /strapdown/postpend;
#!/bin/bash | |
# Check if the required arguments are provided | |
if [ $# -lt 2 ] || [ $# -gt 3 ]; then | |
echo "Usage: $0 <directory> <target_string> [<replacement_string>]" | |
exit 1 | |
fi | |
# Assign arguments to variables | |
directory="$1" |
# ximalaya vip check | |
127.0.0.1 mwsa.ximalaya.com |
select '%TABLE_NAME%' | |
into @table; | |
select '%DB_NAME%' | |
into @schema; | |
select concat(' public class ', @table) | |
union | |
select ' {' | |
union | |
select concat(' public ', tps.dest, ' ', column_name, ' { get; set; }') |
using System; | |
using System.Security.Cryptography; | |
using System.Text; | |
namespace xxx.ClassLibrary | |
{ | |
public static class TextEncryption | |
{ | |
private static TripleDESCryptoServiceProvider GetCryproProvider(string keyStr) | |
{ |
#!/bin/bash | |
#set -ex | |
# 搜索关键字要么不用引号包裹,要么使用双引号包裹。请不要使用单引号包裹 | |
pname=`basename $0` | |
if [ $pname = "g" -a $# -lt 1 ];then | |
echo "Usage: $pname 'keyword' [-i]" | |
exit | |
fi |
#!/bin/bash | |
# | |
# Automate mysql secure installation for Redhat/CentOS systems | |
# | |
# - You can set a password for root accounts. | |
# - You can remove root accounts that are accessible from outside the local host. | |
# - You can remove anonymous-user accounts. | |
# - You can remove the test database (which by default can be accessed by all users, even anonymous users), | |
# and privileges that permit anyone to access databases with names that start with test_. |
"curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim | |
set nocompatible | |
let g:XkbSwitchEnabled = 1 | |
let g:XkbSwitchLib = '/usr/local/lib/libg3kbswitch.so' | |
function! BuildComposer(info) | |
if a:info.status != 'unchanged' || a:info.force | |
if has('nvim') |
#!/bin/bash | |
#set -ex | |
pname=`basename $0` | |
if [ $pname = "g" -a $# -lt 1 ];then | |
echo "Usage: $pname 'keyword' [-i]" | |
exit | |
fi | |
if [ $pname = "s" -a $# -lt 3 ];then |
#!/usr/bin/php | |
<?php | |
if (sizeof($_SERVER['argv']) != 3) { | |
exit("Usage: {$_SERVER['argv'][0]} from_project_path to_project_path"); | |
} | |
$pwd = getcwd(); | |
if (!chdir($_SERVER['argv'][1])) { | |
exit("cd {$_SERVER['argv'][1]} failed"); | |
} |