Skip to content

Instantly share code, notes, and snippets.

@findix
findix / calibre.bat
Last active May 25, 2022 22:15
Open calibre on the NAS
@echo off
set CALIBRE_LIBRARY_DIRECTORY=\\NAS\book\talebook\books\library
set CALIBRE_EXE=C:\"Program Files"\Calibre2\calibre.exe
IF EXIST %CALIBRE_LIBRARY_DIRECTORY% (
SETX>nul CALIBRE_LIBRARY_DIRECTORY %CALIBRE_LIBRARY_DIRECTORY%
ECHO LIBRARY FILES: %CALIBRE_LIBRARY_DIRECTORY%
)
@findix
findix / xshell2mobaxterm.py
Created April 6, 2023 06:42
Convert xshell session to mobaxterm session file
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# xshell session to mobaxterm session file
# Support: TELNET, serial, SSH
# Usage: xshell2mobaxterm.py Xshell_Session_Direcotry
# Example: python3 xshell2mobaxterm.py C:\Users\USERNAME\Documents\NetSarang Computer\7\Xshell\Sessions > mobaxterm.mxtsessions
# Linux platform enviroment: LANG=zh_CN.utf8/en_US.utf8
# Windows: python3.6 cmd run it.
import os, sys