Skip to content

Instantly share code, notes, and snippets.

View cnDelbert's full-sized avatar

Delbert cnDelbert

View GitHub Profile
@cnDelbert
cnDelbert / starship.toml
Created September 23, 2023 06:38
A starship config file with full time and directory path.
add_newline = true
format = """
$username$status$hostname$time\
$git_branch$git_commit$git_state$git_metrics$git_status\
$package\
$c\
$cmake\
$dotnet\
$golang\
@cnDelbert
cnDelbert / 解决Windows系统蓝牙设置连接后音量100%的问题.reg
Created January 8, 2023 06:43
解决Windows系统蓝牙设置连接后音量100%的问题
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Bluetooth\Audio\AVRCP\CT]
"DisableAbsoluteVolume"=dword:00000001
@cnDelbert
cnDelbert / CameraRenderer.cs
Last active August 25, 2021 07:29
Unity Tutorials from Catlink.
using UnityEngine;
using UnityEngine.Rendering;
public class CameraRenderer
{
private ScriptableRenderContext context;
private Camera camera;
private const string bufferName = "RenderCamera";
private static ShaderTagId unlitShaderId = new ShaderTagId("SRPDefaultUnlit");
private CullingResults cullingResults;
# coding: utf-8
__author__ = 'Delbert'
# 20160303
# Original: https://www.wechall.net/challenge/training/encodings/ascii/
# Output: The solution is: dilsmeboeili
def main():
ascii_list = [84, 104, 101, 32, 115, 111, 108, 117, 116, 105, 111, 110, 32, 105, 115, 58, 32, 115, 105, 114, 101, 105, 98, 97, 101, 104, 101, 110, 97]
result = ascii_to_char(ascii_list)
@cnDelbert
cnDelbert / ExpireCNDomainSearch.py
Created December 26, 2015 15:54
Get domains which would expire in 2 days and match the keyword you interested in.
# -*- coding: utf-8 -*-
__author__ = 'Delbert'
import requests
def init():
domainList = list()
future0ListURL = 'http://www.cnnic.cn/download/registar_list/1todayDel.txt'
future1ListURL = 'http://www.cnnic.cn/download/registar_list/future1todayDel.txt'
future2ListURL = 'http://www.cnnic.cn/download/registar_list/future2todayDel.txt'
#!/usr/bin/env python
# coding=utf8
# author=evi1m0
# website=linux.im
'''
12306 Captcha Picture:
author: Evi1m0@20150316
1. Download Captcha
2. Pic Conver Text
@cnDelbert
cnDelbert / SimpleDesktops.py
Last active August 29, 2015 14:14
Download images from SimpleDesktops.com .
# -*- coding: utf-8 -*-
__author__ = 'Delbert'
# You can pass 2 parameters to init_config()
# `path` is the directory you would like to save the images
# `image_id` is the image ID you want to download from.
from bs4 import BeautifulSoup
import requests
import os
@cnDelbert
cnDelbert / refFormatter.py
Created January 31, 2015 13:50
Format references to the given format.
# -*- coding: utf-8 -*-
__author__ = 'Delbert'
import re
import xlwt
def parse(refer, formated):
r_file = open(refer, 'rt', encoding='utf-8')
save_file = open('saved.txt', 'wt', encoding='utf-8')
@cnDelbert
cnDelbert / java_install_sp.txt
Created January 25, 2015 11:53
Java Install Log
Sun Jan 25 19:41:15 2015
::
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Sun Jan 25 19:41:15 2015
:: ----------------------------------------------
Sun Jan 25 19:41:15 2015
:: GetSponsorOffer(), started 1/25/2015 at 11:41
@cnDelbert
cnDelbert / DownTraverse.py
Last active August 29, 2015 14:13
Download files from an http server which allows traversing.
# -*- coding: utf-8 -*-
__author__ = 'Delbert'
# Download files from an http server which allows traversing.
# Python 3 Only.
# requests and BeautifulSoup4 are required.
from bs4 import BeautifulSoup
import urllib
import requests
import os