Skip to content

Instantly share code, notes, and snippets.

import requests
from urllib import parse
import os,re
def download(mid,artist,albumname,songname):
def nametest(name):
reg = re.compile(r'[\\/:*?"<>|\r\n]+')
valid_name = reg.findall(name)
if valid_name:
for nv in valid_name:
@j-iNFINITE
j-iNFINITE / a
Last active December 4, 2022 13:56
这个李雅胖胖叫小胖
@j-iNFINITE
j-iNFINITE / folder_organize.ps1
Last active July 27, 2021 21:09
powershell script for organize files in a folder,according to the year, month, day and extension
$path = "your folder path"
Set-Location $path
foreach ($file in (get-childitem $path | where { ! $_.PSIsContainer } ))
{
$year=$file.CreationTime.Year
$month=$file.CreationTime.Month
$day=$file.CreationTime.Day
$ext=($file.Extension).Trim(".")
$newpath=$path,$year,$month,$day,$ext -Join "\"
if (Test-Path $newpath){
<?xml version='1.0' encoding='utf-8'?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" version="2.0">
<channel>
<title>2019软考信息安全工程师基础知识教程上</title>
<link>https://www.google.com</link>
<description>2019软考信息安全工程师基础知识教程上</description>
<itunes:explicit>yes</itunes:explicit>
<docs>http://www.rssboard.org/rss-specification</docs>
<generator>python-podgen v1.0.0 https://podgen.readthedocs.org</generator>
<lastBuildDate>Sun, 24 Mar 2019 09:57:43 +0000</lastBuildDate>
@j-iNFINITE
j-iNFINITE / 联系人问题
Created May 22, 2017 01:46
android刷机
不双清给一加氢 OS 刷上 Google Apps
最近入爪一台一加 3,解锁刷 root 后几乎配置完了所有东西,然后才发现忘记了 gapps。网上看到许多人在这种情况下刷 gapps 遇到了各种各样的问题,一般都被建议双清解决。我查找了一些资料后,决定试试不双清自己修复权限问题。
安装 OpenGApps
这里的假设是已经刷过第三方 Recovery,我这里是 TWRP。从 OpenGApps 网站下载对应的包(我这里对应的是 ARM64、6.0),我选择了 nano 包。
重启进入 Recovery 刷入此包。然后不要急着重启,因为大量网友反应此时重启后会不断 fc。我在一加论坛找到了这样的方法,经实测有效(针对 TWRP,其他 Recovery 请自行调整):此时应回到 Recovery 首页,进入 Mount 页面勾上 System,然后回到首页依次选择 Advanced -> File Manager -> system -> priv-app -> SetupWizard,然后点击右下的选择气泡,最后点击 Delete 删除这个文件夹。
'621098' => '邮储银行-绿卡通-借记卡',
'622150' => '邮储银行-绿卡银联标准卡-借记卡',
'622151' => '邮储银行-绿卡银联标准卡-借记卡',
'622181' => '邮储银行-绿卡专用卡-借记卡',
'622188' => '邮储银行-绿卡银联标准卡-借记卡',
'955100' => '邮储银行-绿卡(银联卡)-借记卡',
'621095' => '邮储银行-绿卡VIP卡-借记卡',
'620062' => '邮储银行-银联标准卡-借记卡',
'621285' => '邮储银行-中职学生资助卡-借记卡',
'621798' => '邮政储蓄银行-IC绿卡通VIP卡-借记卡',
from win32com.client import Dispatch
import time
def start_office_application(app_name):
# 在这里获取到app后,其它的操作和通过VBA操作办公软件类似
app = Dispatch(app_name)
app.Visible = True
time.sleep(0.5)
app.Quit()
if __name__ == '__main__':
'''''''
@j-iNFINITE
j-iNFINITE / 返回字典形式
Created September 25, 2016 12:08
python sqlte3相关
def dict_factory(cursor, row):
return dict((col[0], row[idx]) for idx, col in enumerate(cursor.description))
cursor.row_factory=dict_factory
@j-iNFINITE
j-iNFINITE / centos 更新git
Last active September 11, 2016 14:54
git相关
1、安装依赖
[root@test ~]# yum install -y perl-ExtUtils-MakeMaker package
2、卸载系统原有git
[root@test ~]# rpm -e git
3、下载git源码包
[root@test ~]# wget https://www.kernel.org/pub/software/scm/git/git-2.0.0.tar.gz
4、安装git
[root@test ~]# tar xf git-2.0.0.tar.gz
[root@test tools]# cd git-2.0.0
[root@test git-2.0.0]# ./configure
@j-iNFINITE
j-iNFINITE / pan.baidu headers
Created September 9, 2016 04:34
收集一些百度云的headers
netdisk;4.1.0.13;PC;PC-Windows;6.2.9200;WindowsBaiduYunGuanJia
netdisk;6.12.1;iPhone 6;ios-iphone;9.0.2;zh_CN