Commit 2915981e authored by TanakaKotoha's avatar TanakaKotoha

dededededededededededede

parent 5d134e2e
{ {
"id": "downloadlogs", "id": "downloadlogs",
"version": "1.0.2", "version": "1.1.0",
"name": "按S下载牌谱", "name": "按S下载牌谱",
"author": "凉宫杏树", "author": "凉宫杏树",
"description": "太好了,准备把牌谱拿给主人看。", "description": "太好了,准备把牌谱拿给主人看。",
......
This diff is collapsed.
@echo off
SETLOCAL EnableDelayedExpansion
::gets around the windows parameter character limit by writing an .html that opens the tenhou/5 url
:: rem get unique file name
:: :uniqloop
:: set "tmpfile=%tmp%\bat~%RANDOM%.html"
:: if exist "%tmpfile%" goto :uniqloop
set "tmpfile=%tmp%~viewlog.html"
<NUL echo|set /p="<head><meta http-equiv='refresh' content='0; URL=https://tenhou.net/5/?tw=2#json="> %tmpfile%
<NUL type %1>> %tmpfile%
<NUL echo|set /p="'></head>">> %tmpfile%
start %tmpfile%
::you could wait and delete the file..
::pause
::del %tmpfile%
#!/bin/bash
if [[ "" == $1 ]]; then
echo "${0} log.json"
echo "opens your log with tenhou.net/5"
exit 1
fi
url="https://tenhou.net/5/?tw=2#json=""$(cat $1)"
case "$OSTYPE" in
linux*)
xdg-open "${url}"
;;
darwin*)
open "${url}"
;;
cygwin*)
cygstart "${url}"
;;
*)
open "${url}" || start "${url}"
;;
esac
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment