![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
杂项
少言才不会咸
这个作者很懒,什么都没留下…
展开
-
termux 安装ubuntu
【代码】termux 安装ubuntu。原创 2022-09-16 16:25:53 · 1087 阅读 · 0 评论 -
perf性能火焰图生成
#!/bin/bash#sudo sh -c 'echo kernel.perf_event_paranoid=1 >> /etc/sysctl.d/99-perf.conf'#sudo sh -c 'echo kernel.kptr_restrict=0 >> /etc/sysctl.d/99-perf.conf'#sudo sh -c 'sysctl --system'DU=${1:-900}echo $DUTIME=`date +%s`DIR=perf_$T原创 2022-04-01 14:42:01 · 346 阅读 · 0 评论 -
迭代bash脚本参数
#!/bin/bash# method 0: for i in $## method 1args=$#for (( i=1; i<=$args; i++ ))do echo "$i - ${!i}"done# method 2for argdo case "$arg" in -*=*) value=`echo "$arg" | sed -e 's/[-_a-zA-Z0-9]*=//'` ;; *) value="" ;;原创 2021-11-14 18:45:50 · 901 阅读 · 0 评论 -
dart中转换list为map
void main() { var a = ['红色', '蓝色', '紫色'] .asMap() .map((index, element) => MapEntry(index, "$element $index")) .values .toList(); var b = ['红色', '蓝色', '紫色'].map((element) => "$element").toList(); print(a); print(b);原创 2021-06-29 17:27:55 · 1151 阅读 · 0 评论 -
达夫设备,循环展开
#include "stdio.h"#include "string.h"void Strncpy(char *to, const char *from, size_t count) { size_t n = (count + 7) / 8; switch (count % 8) { case 0: do { *to++ = *from++; case 7: .转载 2020-10-29 20:49:38 · 143 阅读 · 0 评论 -
zsh theme
# vim:ft=zsh ts=2 sw=2 sts=2## agnoster's Theme - https://gist.github.com/3712874# A Powerline-inspired theme for ZSH## # README## In order for this theme to render correctly, you will need a# [Powerline-patched font](https://github.com/Lokaltog/po原创 2020-06-13 19:15:55 · 927 阅读 · 0 评论 -
git repo
Git global setupgit config --global user.name "xinjiawei"git config --global user.email "xinjiawei@onething.net"Create a new repositorygit clone http://gitlab.willku.org/xinjiawei/bytesdk.gitcd...原创 2020-04-02 21:01:02 · 193 阅读 · 0 评论 -
raspiberry上报心跳
local redis=require "resty.redis";--local cjson = require "cjson";local red=redis:new();red:set_timeout(1000);--redis连接local ok,err=red:connect("127.0.0.1", 6379);if not ok then ngx.log("fa...原创 2020-03-21 20:43:56 · 217 阅读 · 0 评论 -
vscode配置调试c++
tasks.json{ "tasks": [ { "type": "shell", "label": "clang build active file", "command": "/usr/bin/clang", "args": [ "-g", "-std=c++11", "${file}...原创 2019-10-22 14:02:31 · 411 阅读 · 0 评论 -
cmakelist.demo
cmake_minimum_required(VERSION 2.8)project(unix)file(GLOB HDRS "/Users/kuwill/*_inc")include_directories(BEFORE ${HDRS})include_directories("/Users/kuwill/gun_inc" "/Users/kuwill/usr_inc" "/User...原创 2019-04-07 14:05:34 · 393 阅读 · 0 评论 -
nginx-rtmp-module
http{}# RMTP的服务器配置信息rtmp { server { listen 1935; #推流的监听端口 chunk_size 4000; publish_time_fix on; # 推流其一 applic...转载 2018-09-22 17:01:07 · 347 阅读 · 0 评论 -
sql
create database userinfo charset="utf-8";use userinfo;create table it user info(ui_user_id bigint auto_increment comment ‘用户ID',ui_name varchar(64) not null comment ‘用户名’,ui_passwd varchar(128) ...转载 2018-03-21 20:10:48 · 197 阅读 · 0 评论 -
virtualenvwrapper的安装及问题解决
安装virtualenvwrapperyum install python-setuptools python-develpip install virtualenvwrapper # linux下********************************************pip install virtualenvwrapper-win # windows下2...原创 2018-03-23 14:45:37 · 7916 阅读 · 0 评论 -
gitbook中book.json配置
{"title":"xxx","description": "xxx中文版", "pluginsConfig": { "fontSettings": { "theme": "white", "family": "msyh", "size": 2 }, "plugins": [ "yahei", "katex转载 2018-01-25 23:19:06 · 1889 阅读 · 0 评论 -
Oracle笔记(六)
--数据对象:触发器trigger--触发器:当数据库发生操作时,会发生一些事件--从而自动地执行相应的程序--分类--语句触发器:在执行DML(INSERT,DELETE,UPDATE)操作时,将激活该触发器--创建触发器,用于显示基于DEPT表的DML操作情况create or replace trigger trg_deptbefore insert or update or d原创 2016-11-04 18:24:21 · 215 阅读 · 0 评论 -
Oracle笔记(一)
10月27日设置只读事物 set transaction read only常用函数 lower(ename) upper(ename) length(ename) substr(ename,1,3) replace(ename,’A’,’我是A’) round(comm,1)//考虑四舍五入 trunc(comm,1)//不考虑四舍五入 floor(comm)//向下取整原创 2016-10-27 19:18:27 · 221 阅读 · 0 评论 -
Oracle笔记(七)
--完成一个简单的应用系统开发设计--背景:本次实践中实现学生信息管理系统的数据库结构的创建--需求:实现学生信息管理系统中教学模块的数据库设计--功能描述:教学模块包含学生基本信息管理,课程信息管理--班级信息管理,选课信息管理,教师基本信息管理--教师授课信息管理,--详细信息描述如下--学生基本信息包括:学号,姓名,年龄,性别,入学日期,家庭住址--教师基本信息包括:教工号,姓原创 2016-11-11 08:48:23 · 317 阅读 · 0 评论 -
cmd下获取系统时间
编写Windows批处理时经常会需要使用到日期和时间作为文件名,所以是非常重要的。 如何获取日期呢? 格式: %date% 结果: 2012-07-31 如何获取时间呢? 格式: %time% 结果: 10:21:21.68 这是获取的系统标准格式的日期和时间,但是有时候我们需要使用规定的格式,怎么办呢? 格式: %date:~x,y%以及%time:~x,y% 说明:转载 2016-11-29 08:18:44 · 29047 阅读 · 1 评论 -
Oracle笔记(三)
分支语句if 条件 then 语句end if;if 条件 then 语句1 else 语句2end if;if 条件1 then 语句1 elsif 条件2 then ......--创建简单过程create or replace procedure zxx_pro1 as--声明部分v_sal emp.sal%type;beginselect sal into v_sa原创 2016-11-01 09:32:56 · 210 阅读 · 0 评论 -
Oracle笔记(四)
--游标--游标是Oracle为用户开设的一个数据缓冲区,存放SQL语句的执行结果--Oracle数据库中执行的每个SQL语句都有对应的单独的游标--游标的分类:--a)隐式游标:处理单行SELECT INTO 和DML语句--b)显式游标:处理SELECT语句返回的多行数据--显式游标的应用一、定义游标:cursor cursor-name....(*_cursor)二、打开游标:原创 2016-11-01 09:35:23 · 170 阅读 · 0 评论 -
Oracle笔记(二)
–PL/SQL编程(procedure language )过程化的SQL编程 –SQL块,过程procedure,函数function,包package,触发器trigger –简单块 顺序 赋值语句 :=赋值号 =C语言 :=PASCAL 有关绑定变量 &绑定变量名 –简单块 declare v_sal emp.sal%type; begin select原创 2016-10-28 14:54:11 · 257 阅读 · 0 评论 -
Oracle笔记(五)
–1、goto –顺序控制语句 declare i int:=1; begin loop dbms_output.put_line(‘输出i=’||i); if i=5 then goto end_loop; end if; i:=i+1; end loop;原创 2016-11-01 09:48:00 · 188 阅读 · 0 评论 -
LNMP--搭建个人“Wordpress”轻博客
WordPress是一种使用PHP语言开发的博客平台,用户可以在支持PHP和MySQL数据库的服务器上架设属于自己的网站。也可以把 WordPress当作一个内容管理系统(CMS)来使用。WordPress是一个免费的开源项目,在GNU通用公共许可证下授权发布。这里我用最新的Centos 7 结合LNMP(Linux、Nginx、Mariadb、PHP)来搭建一个WEB Blog站点。原创 2016-05-19 22:47:04 · 958 阅读 · 0 评论 -
RHCE-EXERCISE
两台虚拟机,请认准机器再做。本域是domainX.example.com,172.25.X.0/24;敌对域my133t.org,172.26.X.0/24考试准备工作:一次性放开本域的所有访问firewall-cmd --permanent --list-allfirewall-cmd --permanent --add-rich-rule='rule family=ipv4 sourc转载 2017-04-30 18:09:58 · 1330 阅读 · 0 评论 -
RHCSA-EXERCISE
把 root密码设置为要求的:grub启动菜单选 e编辑,找见默认 kernel(linux16,在行末添加 rd.break,b引导。mount -o rw,remount /sysrootchroot /sysrootpasswd roottouch /.autorelabelreboot***********************************************转载 2017-04-30 18:06:20 · 736 阅读 · 0 评论 -
图种
::命令 copy /b a.png + b.zip a_new.png @title 拖拽图片文件和压缩包文件到此文件上松开瞬间制作伪装图片 @echo off color 3f if x%1==x (goto NoDragFile) if x%2==x ( :NoDragFile echo 请将图片文件和压缩包文件拖到此文件上松开即可瞬间制作伪装图片! echo转载 2017-04-08 13:22:03 · 557 阅读 · 0 评论 -
myconfig of st3 & vs code
# sublime{ "color_scheme": "Packages/Color Scheme - Default/Breakers.tmTheme", "font_size": 13, "ignored_packages": [ ], "auto_complete_commit_on_tab": true, "show_encodi原创 2017-11-16 09:54:54 · 275 阅读 · 0 评论 -
git学习
===================client端初始化===================:# git config --global user.name "willku"# git config --global user.mail "willku@coderr.cn"# git config --global core.editor vim# git config --list (原创 2017-06-22 23:06:58 · 281 阅读 · 0 评论 -
微信小程序开发知识点
主页面跳转子页面的方式方式一:子页面会被unload,资源被回收,每次重新加载 itemClick:function(){ wx.navigateTo({url:"../logs/logs"}) }方式二:主页面会被unload,此页面无”返回”按钮itemClick:function(){wx.redirectTo({url:"../logs/logs"})}原创 2018-01-08 10:58:49 · 866 阅读 · 0 评论 -
gitbook的book.json配置
{ “title”:”xxx”, “description”: “xxx中文版”, “language”: “zh”, “pluginsConfig”: { “fontSettings”: { “theme”: “white”, “family”: “msyh”, “size”: 2 }, “plugins”:转载 2018-01-25 23:07:10 · 3563 阅读 · 0 评论 -
【转】select into from 和 insert into select 的用法和区别
select into from 和 insert into select都是用来复制表,两者的主要区别为: select into from 要求目标表不存在,因为在插入时会自动创建。insert into select from 要求目标表存在。下面分别介绍两者语法一、INSERT INTO SELECT语句1、语句形式为:Insert into Table2(field1,field2,…)转载 2016-10-24 09:04:37 · 30123 阅读 · 2 评论