Skip to content

Instantly share code, notes, and snippets.

#/bin/bash
declare -a remote_dirs=("sdcard/inshot/"
"sdcard/DCIM/"
"sdcard/Pictures/"
"sdcard/Download"
"sdcard/Movies/")
bak=bak_$(date +"%Y%m%d-%H%M%S")
for dir in "${remote_dirs[@]}"
@xue-blood
xue-blood / insert-time.js
Created August 5, 2021 08:42
show current localtime by tampermonkey
// ==UserScript==
// @name insert time
// @namespace http://tampermonkey.net/
// @version 0.1
// @description show current localtime
// @author You
// @match https://github.com/*
// @icon https://www.google.com/s2/favicons?domain=github.com
// @grant none
// ==/UserScript==
@xue-blood
xue-blood / arch-iscsi.md
Created August 5, 2019 08:51
Install `arch` on *`ISCSI`* target

Install arch on ISCSI target

Note

  • /boot from pxe
  • /root from iscsi
  • ip assign by dhcp

Software

Server

  • OS: arch linux 5.2.1-arch1-1-ARCH
  • syslinux
  • dnsmasq
Shader "Post/Rain"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_Rain("Rain", 2D) = "black" {}
_Ripple("Ripple", 2D) = "black" {}
_NoiseTex("Noise Tex", 2D) = "black"{}
_RainForce("RainForce",Range(0,1)) = 0
_RainSpeed("Rain Speed", float) = 0.1
@xue-blood
xue-blood / rain.shader
Created May 18, 2019 10:04
unity rain post process shader
Shader "Post/Rain"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_Rain("Rain", 2D) = "black" {}
_Ripple("Ripple", 2D) = "black" {}
_NoiseTex("Noise Tex", 2D) = "black"{}
_RainForce("RainForce",Range(0,1)) = 0
_RainSpeed("Rain Speed", float) = 0.1
@xue-blood
xue-blood / grub4dos.md
Created May 13, 2019 03:24
Grub4dos tips
title Boot CentOS 7 from ISO\n Direct boot CentOS 7 from ISO file

#ISO is full path to ISO - no spaces
set ISO=/_ISO/CentOS-7.0-1406-x86_64-DVD.iso
#LBL=CD VOLUME LABEL OF THE ISO - spaces replaced by \\x20
set LBL=CentOS\\x207\\x20x86_64

map %ISO% (0xff) || echo -e $[0147]%ISO% IS NOT CONTIGUOUS! && map --mem %ISO% (0xff)
@xue-blood
xue-blood / unity-shader.md
Last active May 13, 2019 03:17
unity shader
  • Setup camera cam.depthTextureMode = DepthTextureMode.DepthNormals;
  • Depth sample
float depth = SAMPLE_DEPTH_TEXTURE(_CameraDepthTexture, i.uv);
float depth01 = Linear01Depth(depth);
depth = LinearEyeDepth(depth);
@xue-blood
xue-blood / git.cmd
Created May 5, 2019 09:08
git use tips
[Using a socks proxy with git for the http transport](https://stackoverflow.com/questions/15227130/using-a-socks-proxy-with-git-for-the-http-transport)
`ALL_PROXY=socks5://127.0.0.1:8888 git clone https://github.com/some/one.git`

2019

  • 【動漫國字幕組】★01月新番[勇者企劃 / Endro~!]
  • 【DHR動研字幕組】[約會大作戰 第三季_DATE A LIVE III]
  • 【動漫國字幕組】★10月新番[刀劍神域 Alicization篇]
  • 【DHR百合組】[BanG Dream!第二季_BanG Dream!S2]
  • 【DHR百合組】[天使降臨到我身邊!_Watashi ni Tenshi ga Maiorita!]
  • 【DHR動研字幕組】[飛翔吧!戰機少女_Girly Air Force]

2019.04.06

  • [動漫國字幕組x輕之國度字幕組][噬血狂襲III/Strike The Blood III][OVA]

openssl req -x509 -newkey rsa:4096 -keyout key.pem -out cert.pem -days 365

<Location /folder/>
  ProxyPass http://test.example.com/
  ProxyPassReverse http://test.example.com/ 
  AddOutputFilterByType SUBSTITUTE text/html
 Substitute "s|test.example.com/|www.example.com/folder/|i"