Skip to content

Instantly share code, notes, and snippets.

View Arathi's full-sized avatar

Arathi Arathi

View GitHub Profile
@Arathi
Arathi / Laravel54Notes.md
Created March 1, 2017 17:02
Laravel 5.4 学习笔记

Laravel 5.4 学习笔记

创建项目

composer create-project laravel/laravel project-name --prefer-dist "5.4.*"
@Arathi
Arathi / Preferences.sublime-settings
Created April 15, 2017 12:28
Sublime配置文件
{
"draw_white_space": "all",
"font_size": 12,
"highlight_line": true,
"ignored_packages":
[
""
],
"rulers":
[
@Arathi
Arathi / url_encoding.cpp
Created August 20, 2017 06:51
C++的URL转换
#include <iostream>
#include <string>
#include <cstring>
using namespace std;
const int CHARSET_NULL = 0;
const int CHARSET_ANSI = 1252; //ISO-8859-1
const int CHARSET_ASCII = CHARSET_ANSI;
const int CHARSET_GBK = 936;
@Arathi
Arathi / cmppv2.lua
Last active January 2, 2024 11:39
Wireshark CMPP 2.0 协议插件
----------------
-- 报文结构定义
----------------
CMPPv2_Field_Protos = {
Command_Name = {
[0x00000001] = "CMPP_CONNECT",
[0x80000001] = "CMPP_CONNECT_RESP",
[0x00000002] = "CMPP_TERMINATE",
[0x80000002] = "CMPP_TERMINATE_RESP",
[0x00000004] = "CMPP_SUBMIT",
@Arathi
Arathi / aws2azure.py
Created September 17, 2018 02:43
将Amazon的提供的IP段(json格式)转换为Azure的IP段(XML格式)
# -*- coding: utf-8 -*-
import urllib.request
import urllib.parse
import json
import xml.dom.minidom
url = 'https://ip-ranges.amazonaws.com/ip-ranges.json'
response = urllib.request.urlopen(url)
resp_json_str = response.read().decode('utf-8')
resp_json = json.loads(resp_json_str)
@Arathi
Arathi / mobile_prefix_rules.md
Last active July 8, 2020 08:13
中国内地移动终端通信号段规则

中国内地移动终端通信号段规则

正则表达式

移动

^((13[5-9]|14[78]|15[012789]|165|17[28]|18[23478]|19[578])\d{8})|((134[0-8]|144[01]|170[356])\d{7})$

联通

@Arathi
Arathi / tenichi.svg
Last active November 25, 2018 15:54
天一信局家徽
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Arathi
Arathi / wicurio.user.js
Last active January 7, 2019 09:09
Wicurio的FGO Wiki翻译
// ==UserScript==
// @name Wicurio的FGO Wiki翻译
// @namespace http://fgoutils.undsf.com/
// @version 0.0.4
// @description 替换Wicurio的Wiki上的各种从者、怪物名称为中文
// @author Arathi of Nebnizlla
// @match https://grand_order.wicurio.com/index.php?*
// @grant none
// ==/UserScript==
@Arathi
Arathi / OracleManagedParameters.cs
Created March 20, 2019 02:46
用于Oracle.ManagedDataAccess+Dapper方案的DynamicParameters,解决调用Oracle的存储过程时无法设置游标类型的参数的问题
using Dapper;
using Oracle.ManagedDataAccess.Client;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
namespace Undsf.Common.Database
{
public class OracleManagedParameters : SqlMapper.IDynamicParameters
@Arathi
Arathi / ShiftJis.cs
Last active October 25, 2019 11:01
生成Shift-JIS码表
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace ShiftJisCodeTable
{
class Program
{
static void Main(string[] args)