markdown 常用语法

一至六级标题分别对应一到六个#,然后加一个空格,举例 # 一级标题## 二级标题### 三级标题#### 四级标题##### 五级标题###### 六级标题 效果如下: 一级标题 二级标题 三级标题 四级标题 五级标题 六级标题   文字加粗,要加粗的文字左右两边加两个*,不能带空改 : **加粗文字** 效果 加粗文字 文字斜体,文字左右两边加1个*,不能带空改: *斜体* 效果 斜体文字 文字加粗并斜体,文字左右两边加3个*,不能带空改: ***加粗斜体*** 效果 加粗斜体 文字加删除线,文字左右两边加2个~ ~~删除线~~ 效果 删除线 文字加粗删除线,套娃,两个~两个*中间加文字 ~~**加粗删除线**~~ 效果,加粗删除线 文字加粗斜体删除线,套娃,两个~三个*中间加文字 ~~***加粗斜体删除线***~~ 效果 加粗斜体删除线 斜体删除线,套娃,两个~1个*中间加文字 ~~*斜体删除线*~~ 效果 斜体删除线 引用,另起一行, 加>,后面加空改,跟文字 > 引用数据 效果   引用数据 分割线 ,三个以上-或* —***—-等 效果 图片 … Read more

终端和git设置代理解决gradle,pub,go,git等龟速问题

首先是终端设置代理: windows: 临时设置: set http_proxy=http://192.168.0.1:1024 set https_proxy=%http_proxy% 192.168.0.1:1024根据是要代理的ip和端口,根据自己的实际地址设置 以上是设置http代理,如果要设置socks5代理,比如ss,v2等把http:// 改成socks5://  ss设置: set http_proxy=socks5://127.0.0.1:1080 set https_proxy=%http_proxy% v2设置: set http_proxy=socks5://127.0.0.1:10808 set https_proxy=%http_proxy% 永久设置: 修改环境变量,新增系统变量: ss http_proxy socks5://127.0.0.1:1080 # 代理地址 https_proxy socks5://127.0.0.1:1080 v2 http_proxy socks5://127.0.0.1:10808 # 代理地址 https_proxy socks5://127.0.0.1:10808 http http_proxy http://192.168.0.1:1024 # 代理地址 https_proxy http://192.168.0.1:1024 Linux/MAC 首先bash编写脚本proxy.sh #!/bin/bash export http_proxy=socks5://127.0.0.1:1080 # ss代理地址,可以替换成v2或者http的 export https_proxy=$http_proxy export | grep http 设置权限:chmod+x proxy.sh source proxy.sh 取消: unset http_proxy 然后是git设置代理: 设置代理: 打开gitbash,输入下面指令 git config –global http.proxy socks5://127.0.0.1:1080    git config –global https.proxy socks5://127.0.0.1:1080 以上代理地址也可以设置成v2或者http地址 取消代理: git config –global –unset http.proxy  git config –global –unset https.proxy 查看代理: git config –get http.proxy git config –get https.proxy

懒人专用:git add ,commit,push合并同时调用

通常我们开发提交代码的时候要重复的使用下面git指令 git add -A  git commit -m "xxxx" git push 对于经常提交代码来说难免有些繁琐,下面提供两种简单的方式把三条指令合并提交 第一种:   打开gitbash,输入如下命令并回车 git config –global alias.acp '!f() { git add -A && git commit -m "$@" && git push; }; f'  以后提交代码就可以直接用一条指令: git acp "xxxx(提交message)" 第二种: 在.bash_profile输入如下: gitacp() {     git add .     git commit -m "$*"     git push } alias acp=gitacp source .bash_profile 以后提交代码就可以一条指令: acp "xxxx(提交message)"

CentOS8 安装Nginx,PHP8,Mysql8.0

CentOS8 安装nginx  dnf makecache  更新dnf 仓库缓存 dnf install nginx 安装nginx   (如果要安装最新版本的nginx可以到 Nginx RPMS 查看最新版,复制链接,然后输入命令 dnf install  http://nginx.org/packages/centos/8/x86_64/RPMS/nginx-1.18.0-2.el8.ngx.x86_64.rpm) 3.systemctl start nginx 启动nginx 4.systemctl enable nginx 开机启动  5.防火墙开启80和443端口  firewall-cmd –add-service={http,https} –permanent  或者 firewall-cmd –permanent –zone=public –add-port=80/tcp  , firewall-cmd –permanent –zone=public –add-port=443/tcp,如果要查询某个端口是否开启,可以用firewall-cmd –query-port=80/tcp 命令 6.重启防火墙  firewall-cmd –reload CentOS8 安装PHP8  安装epel和remi   dnf install epel-release -y dnf install https://rpms.remirepo.net/enterprise/remi-release-8.rpm -y 2.开启php8 module dnf module list php  dnf module enable php:8.0 3.安装php8 dnf install php php-cli php-common 4.验证 php -v CentOS8 安装mysql8  dnf install mysql-server 安装mysql8 … Read more

Mysql优化

Mysql优化常用的指令: show processlist;  show full processlist; 显示用户正在执行的线程,数据来自mysql系统数据库information_schema库中的processlist表,一般这条指令用来显示正在执行的sql语句,比如MySQL报错"too many connections"时候,可用用他来查询,查询的线程(ID)可以用kill指令杀死。没有full关键词的话,只显示前100条。 show open tables;  show open tables from xxdatabase; 显示缓存表中打开的非临时表,

Ida动态调试步骤

adb forward tcp:23946 tcp:23946 adb shell am  start -D -n com.hundun.yanxishe/.modules.welcome.WelcomeActivity jdb -connect com.sun.jdi.SocketAttach:port=8642,hostname=localhost

apktool invalid resource directory name: res navigation

反编译: apktool d yanxishenew.apk 回编译: apktool b yanxishenew 报错: W: invalid resource directory name: E:decodeapktoolyanxishenew1res navigation 解决方法: 使用aapt2  apktool b –use-aapt2 yanxishenew 执行结果: E:decodeapktool>apktool b –use-aapt2 yanxishenew1 I: Using Apktool 2.4.1 I: Checking whether sources has changed… I: Checking whether sources has changed… I: Checking whether sources has changed… I: Checking whether sources has changed… I: Checking whether resources has changed… I: Building resources… W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2756: error: resource 'drawable/$avd_hide_password__0' has invalid entry name '$avd_hide_password__0'. Invalid character '$avd_hide_password__0'. W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2757: error: resource 'drawable/$avd_hide_password__1' has invalid entry name '$avd_hide_password__1'. Invalid character '$avd_hide_password__1'. W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2758: error: resource 'drawable/$avd_hide_password__2' has invalid entry name '$avd_hide_password__2'. Invalid character '$avd_hide_password__2'. W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2759: error: resource 'drawable/$avd_show_password__0' has invalid entry name '$avd_show_password__0'. Invalid character '$avd_show_password__0'. W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2760: error: resource 'drawable/$avd_show_password__1' has invalid entry name '$avd_show_password__1'. Invalid character '$avd_show_password__1'. W: E:decodeapktoolyanxishenew1resvaluespublic.xml:2761: error: resource 'drawable/$avd_show_password__2' has invalid entry name '$avd_show_password__2'. Invalid character '$avd_show_password__2'. W: brut_util_Jar_185611557998604586.tmp W 09-27 23:02:05 18748 21244 ApkAssets.cpp:137] resources.arsc in APK 'C:UsersAdamAppDataLocalapktoolframework1.apk' is compressed. I: Copying libs… (/lib) I: Copying libs… (/kotlin) I: Copying libs… (/META-INF/services) I: Building apk file… I: Copying unknown files/dir… I: Built apk… E:decodeapktool> dist 目录下成功编译apk

简单程序理解C++的指针

程序: #include <iostream> using namespace std; int main() {     int var = 50;     int* p; //定义指针     p = &var; //把var变量的地址存储到指针p     cout << p << endl;  //输出var变量的地址     cout << *p << endl;  //输出50     *p = 100; //改变指针存储的值     cout << *p << endl; //输出100     cout << var << endl; //输出100            } 输出: 00AFFB48 50 100 100

ASCII编码对照表(查阅)

 ASCII(American Standard Code for Information Interchange,美国信息互换标准代码,ASCⅡ)是基于拉丁字母的一套电脑编码系统。它主要用于显示现代英语和其他西欧语言。它是现今最通用的单字节编码系统,并等同于国际标准ISO/IEC 646。   ASCII第一次以规范标准的型态发表是在1967年,最后一次更新则是在1986年,至今为止共定义了128个字符,其中33个字符无法显示(这是以现今操作系统为依归,但在DOS模式下可显示出一些诸如笑脸、扑克牌花式等8-bit符号),且这33个字符多数都已是陈废的控制字符,控制字符的用途主要是用来操控已经处理过的文字,在33个字符之外的是95个可显示的字符,包含用键盘敲下空白键所产生的空白字符也算1个可显示字符(显示为空白)。 ASCII控制字符 二进制 十进制 十六进制 缩写 可以显示的表示法 名称/意义 0000 0000 0 00 NUL ␀ 空字符(Null) 0000 0001 1 01 SOH ␁ 标题开始 0000 0010 2 02 STX ␂ 本文开始 0000 0011 3 03 ETX ␃ 本文结束 0000 0100 4 04 EOT ␄ 传输结束 0000 0101 5 05 ENQ ␅ 请求 0000 0110 6 06 ACK … Read more

ARM-SUB

substract without carry,不带进位的减法  语法: SUB{S}{cond} {Rd}, Rn, Operand2 SUB{cond} {Rd}, Rn, #imm12 ; Thumb, 32-bit encoding only SUB指令从Rn寄存器的值里面减掉Operand2或者imm12. 在某些特殊情况下,可以用一个寄存器减另一个寄存器