Skip to content

Instantly share code, notes, and snippets.

View thehackercat's full-sized avatar
🚀
what's up

Lexus Lee thehackercat

🚀
what's up
View GitHub Profile
anonymous
anonymous / GAME_MASTER_v0_1.protobuf
Created July 16, 2016 16:31
Pokemon Go decoded GAME_MASTER protobuf file v0.1
Result: 1
Items {
TemplateId: "BADGE_BATTLE_ATTACK_WON"
Badge {
BadgeType: BADGE_BATTLE_ATTACK_WON
BadgeRanks: 4
Targets: "\nd\350\007"
}
}
Items {
@xcatliu
xcatliu / (已失效)中国区用户在开启 GitHub 两步验证中遇到的问题
Last active March 7, 2024 02:53
(已失效)中国区用户在开启 GitHub 两步验证中遇到的问题
2023.8.28
据多名网友回复,此方法已失效。
最新解决办法请参考此贴:[v2ex: 请问 github 的两步验证(two-factor authentication)大家是怎么做的?](https://www.v2ex.com/t/967533)
https://www.v2ex.com/t/967533
---
import requests
from db import db
"""
The Douban Group API which not display on http://developers.douban.com/wiki/?title=api_v2
Base url: https://api.douban.com/v2
Group info: /group/:id
"UserData": {
"Fn::Base64": { "Fn::Join":["", [
"#!/bin/bash -ex\n",
"apt-get update\n",
"apt-get -y install python-setuptools\n",
"mkdir aws-cfn-bootstrap-latest\n",
"curl https://s3.amazonaws.com/cloudformation-examples/aws-cfn-bootstrap-latest.tar.gz | tar xz -C aws-cfn-bootstrap-latest --strip-components 1\n",
"easy_install aws-cfn-bootstrap-latest\n",
"/usr/local/bin/cfn-init --stack ", { "Ref":"AWS::StackName" }, " --resource WebServer", " --region ", { "Ref": "AWS::Region" }, "\n",
"\n",
@genedna
genedna / gentoo-install-manual.md
Last active March 26, 2024 10:19
Gentoo 安装手册

Gentoo 安装手册

第一步:下载安装介质

GentooMinimal Install CD 每周都会自动构建一个版本,服务器一般使用最新的 x86_64 版本。 国内的镜像下载地址是:

第二步:启动机器,设置网络环境和开启 SSH 服务

@zhenyi2697
zhenyi2697 / Python 代码优化常见技巧.md
Created March 29, 2013 10:35
Python: 代码优化技巧

##Python 代码优化常见技巧

###改进算法,选择合适的数据结构

  • 使用dict的查找要比list快很多

  • 当要求list的交集时,转化成set来计算比较快。set的常见操作:

    union: set(list1) | set(list2)
    intersection: set(list1) & set(list2)
    difference: set(list1) - set(list2)