Skip to content

Instantly share code, notes, and snippets.

View abearxiong's full-sized avatar
💭
coding

熊潇 abearxiong

💭
coding
  • china
View GitHub Profile
@abearxiong
abearxiong / jekyll-guide.md
Last active June 15, 2019 06:09 — forked from hellokaton/jekyll-guide.md
Jekyll 中的配置和模板语法

Jekyll 中的配置和模板语法

配置

文件介绍

_config.yml

Jekyll 的全局配置文件。
比如网站的名字,网站的域名,网站的链接格式等等。

@abearxiong
abearxiong / QQCrypter.cs
Last active February 15, 2023 03:30
socket learning python
/// <summary>
/// 加密解密QQ消息包的工具类.
/// </summary>
public static class QQCrypter
{
private static Random Rnd = new Random();
private static void code(byte[] In, int inOffset, int inPos, byte[] Out, int outOffset, int outPos, byte[] key)
{
if (outPos > 0)
{

腾讯的api网关,使用记录

  1. 新建服务,创建API
  2. 使用无服务函数scf

无服务函数创建函数

  1. 函数代码
'use strict'
/**************************************************
Usage: grep [OPTION]... PATTERN [FILE]...
Search for PATTERN in each FILE.
Example: grep -i 'hello world' menu.h main.c

Pattern selection and interpretation:
  -E, --extended-regexp     PATTERN is an extended regular expression
  -F, --fixed-strings       PATTERN is a set of newline-separated strings
  -G, --basic-regexp        PATTERN is a basic regular expression (default)
  -P, --perl-regexp         PATTERN is a Perl regular expression
function sleep(ms){
return new Promise((resolve)=>setTimeout(resolve,ms));
}
async function test(){
var temple=await sleep(1000);
console.log(1111)
return temple
}
test();

执行字符串类型的函数代码

Known

  1. 使用eval("要执行的字符串")
  2. 使用new Function("要执行的字符串")
  3. setTimeOut("要执行的字符串",500)
  4. setInterval("要执行的字符串",500)
@abearxiong
abearxiong / way_to.use.local.js.md
Last active May 3, 2019 03:33
tampermonkey 学习笔记

tampermonkey 本地引用js文件

Prepare in advance

chrome://extensions 把tampermonkey的[运行访问网址]勾上

coding

tampermonkey

// ==UserScript==
var link = $(link) //把元素绑定到JQuery对象
//console.log(link.next()) //下一个兄弟节点 parent() ,children()
var downChild = link.next()
downChild.slideToggle() // 当点击按钮,显示或隐藏元素
@abearxiong
abearxiong / new-web.gists.decoration.user.js
Last active May 2, 2019 10:37
tampermonkey插件 web gists装饰器
// ==UserScript==
// @name 关于web gists 的装饰
// @name:en web gists decoration
// @namespace https://github.com/abearxiong/
// namespace https://gists.github.com/
// @version 1.0.0
// @icon https://github.githubassets.com/favicon.ico
// @description 悬浮显示目录
// @homepageURL https://github.com/abearxiong/web-gists-decoration
// homepage https://gist.github.com/abearxiong/dab578c4c075993c16757f774ab09927/
@abearxiong
abearxiong / important.markdown
Last active April 29, 2019 13:32
程序员资料网站
  1. github [52.74.223.119]
  2. csdn.net [47.95.47.253]
  3. jianshu.com [106.75.17.181]