Skip to content

Instantly share code, notes, and snippets.

View k16shikano's full-sized avatar
💭
I may be slow to respond.

keiichiro shikano k16shikano

💭
I may be slow to respond.
View GitHub Profile
@k16shikano
k16shikano / LICENSE
Created June 22, 2026 01:07
License for my snippet on gist(このGistのライセンスについて)
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
@k16shikano
k16shikano / SKILL.md
Last active June 28, 2026 08:35
japanese-tech-writing/SKILL
name japanese-tech-writing
description 日本語の技術文書・書籍原稿の文章規範。整形(一文一行、引用ブロック、脚注、コラム記法)、段落と論証の構成(パラグラフライティング)、論証の厳密さ(ツッコミどころの除去)、読み手の負荷の管理、視点と語り、演出の抑制、LLM っぽい空句の禁止、冗長の排除を定める。日本語で技術書の章、草稿、記事、解説文を書くとき、または推敲・リライトするときに使用する。

日本語技術文書の文章規範

日本語で技術的な原稿(書籍の章、記事、解説文)を書く・推敲するときは、以下の規範に従う。

整形

@k16shikano
k16shikano / space-before-cmd.tex
Last active February 1, 2025 12:26
コマンドの「前」の文字をみて挙動を変える(LuaTeX)
\documentclass{article}
\usepackage{luacode}
\usepackage{luatexbase}
\newattribute\inlineattr
\newcommand{\inlinestart}{\kern0pt\setattribute{\inlineattr}{100}\kern0pt}
\newcommand{\inlineend}{\kern0pt\setattribute{\inlineattr}{101}\kern0pt}
\newcommand{\myinlinecmd}[1]{\inlinestart#1\inlineend}
\begin{luacode*}
local inlineattr = luatexbase.attributes['inlineattr']
@k16shikano
k16shikano / google-logo-ligature.tex
Last active January 22, 2025 13:59
LuaTeX+Google SansでGoogleロゴ
% Product Sansにはリガチャでロゴ全体のグリフ「も」ある
\documentclass{standalone}
\usepackage{fontspec}
\setmonofont{ProductSans-Regular.ttf}[
RawFeature=+calt % Contextual ligatures
]
\begin{document}
\verb|google_logo|
\end{document}
@k16shikano
k16shikano / luline.tex
Created October 2, 2023 03:37
LuaTeXで行分割可能な下線を引く
\documentclass[a4paper,11pt,twocolumn]{ltjsarticle}
\usepackage{luacode,luatexbase}
\usepackage[no-math,deluxe,expert,haranoaji]{luatexja-preset}
\usepackage{nodetree}
\NodetreeRegisterCallback{:post_linebreak_filter:}
\newcommand{\luline}[1]{\bgroup\attribute100=100 #1\egroup}

Keybase proof

I hereby claim:

  • I am k16shikano on github.
  • I am golden_lucky (https://keybase.io/golden_lucky) on keybase.
  • I have a public key whose fingerprint is 0B62 758B 42D9 9036 1D2A F704 6886 CAB0 1633 950A

To claim this, I am signing this object:

@k16shikano
k16shikano / writing.md
Created February 22, 2022 05:49 — forked from LambdaNote/writing.md
記事の書き方

記事の書き方

記事の執筆には、Markdown形式を利用してください。 Markdownにはさまざまな流派がありますが、GitHub Flavored Markdown(https://github.github.com/gfm/ )をベースとした書式を採用します。

書籍を執筆するための形式として考えると、Markdownには不足している機能が多々あります。 しかし、次のような利点があるので、Markdownを採用することにします。

  • 最低限の構造しかないので、見た目でごまかせる余地が少ない
  • 原稿を著者自身が再利用してもらいやすくしたい
@k16shikano
k16shikano / debian-install.md
Last active February 26, 2023 10:02
Debian作業用サーバをインストールするときのまとめ 2022.1(bullseye)

OSインストールとか

mini.isoをUSBメモリに入れて、USBブートする。 amd64向けのISOイメージは、USBメモリに直接cpするだけでブート可能なものができる。

$ curl http://ftp.jp.debian.org/dists/stable/main/installer-arch/current/images/netboot/mini.iso > mini.iso
$ cp mini.iso /dev/sda
$ sync
@k16shikano
k16shikano / ripple.tex
Created February 4, 2021 09:34
扇形に文字を配置するやつ
\documentclass[uplatex,dvipdfmx]{jlreq}
\usepackage{tikz}
\usetikzlibrary {decorations.text}
\def\mycommand#1{\rotatebox{-90}{#1}\relax}
\newlength{\ripplelength}
\newlength{\ripplewidth}
\newcommand{\ripple}[2]{
\settowidth{\ripplelength}{#1}
\setlength\ripplewidth{\dimexpr\ripplelength/3}
\begin{tikzpicture}[remember picture, overlay]
@k16shikano
k16shikano / intersection.scm
Created January 23, 2021 08:58
昇順の整数のリストが複数あったとき、それらの共通部分を抜き出すやつ
; https://twitter.com/golden_lucky/status/1352094822148915201
(use srfi-1)
(define (intersection lss)
(let R ((as (car lss))
(bss (drop-less-all (caar lss) (cdr lss)))
(result '()))
(if (or (null? bss) (null? as))
(reverse result)