Skip to content

Instantly share code, notes, and snippets.

View sekika's full-sized avatar

Katsutoshi Seki (関 勝寿) sekika

View GitHub Profile
@sekika
sekika / concatepdf.py
Last active August 10, 2023 14:28
Concatenate PDF images with multiple images on a single page
#!/usr/bin/env python3
"""Concatenate PDF images with multiple images on a single page
This is a Python script designed to concatenate PDF images into
a single file. The script arranges multiple PDF images both
horizontally and vertically on a single page, allowing for
customizable image counts along each axis. This results in
multiple pages being generated.
In stalled required library by the following command:
import discord
class Client(discord.Client):
async def on_ready(self):
if hasattr(self, 'action'):
for action in self.action:
if action[0] == 1:
user = await self.fetch_user(action[1])
syntax on
set autoindent
set expandtab
let _curfile=expand("%:r")
if _curfile == 'Makefile'
set noexpandtab
endif
set tabstop=4
set shiftwidth=4
set cursorline
@sekika
sekika / password.html
Last active May 15, 2017 20:24
パスワード生成プログラム (JavaScript 版)
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>パスワード</title>
<style type="text/css">
fieldset {
@sekika
sekika / password.py
Last active May 17, 2017 13:59
パスワード生成プログラム
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# パスワード生成プログラム
#
# このプログラムに関する記事「パスワードの管理について」
# https://sekika.github.io/2017/05/09/Password/
#
# 使い方:プログラムのソースコードに直接サイト情報を書く。
# サイト情報は、サイト名、ハッシュ関数、文字種、文字数、パスワードの種の5つ。
@sekika
sekika / primequiz.py
Last active May 9, 2017 18:36
Primality quiz
#!/usr/bin/env python3
# Primality quiz
# Use the commandline argument "p" to show the list
#
# http://sekika.github.io/2016/12/13/Primality/
### Parameters
rep=10 # Numbers of questions
@sekika
sekika / gitadd
Last active June 10, 2020 06:09
Safe run of (git add .; git commit; git push)
#!/bin/sh
#
# gitadd - safe run of (git add .; git commit; git push)
#
# Usage: gitadd [commit message]
#
# When adding too many files to github, error may arise such as
# remote: fatal: pack exceeds maximum allowed size
# or
# fatal: The remote end hung up unexpectedly
@sekika
sekika / seiseki.py
Last active January 29, 2016 15:43
東洋大学教員用成績登録ファイル作成スクリプト
#!/usr/bin/env python3
# coding: utf-8
# (東洋大学教員専用スクリプト)
# csv ファイルから、東洋大学の成績登録用テキストファイルを作成
# http://sekika.github.io/2016/01/23/Seiseki/
#
# python3 をインストールして実行
#
# 使い方:seiseki.py 入力ファイル名 出力ファイル名
#
@sekika
sekika / pdffonts.out
Last active June 8, 2017 02:57
pdffonts の出力
name type encoding emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
IQBEPV+IPAexMincho CID TrueType Identity-H yes yes no 5 0
OZJPWR+CMR17 Type 1C Builtin yes yes no 6 0
VIODJV+CMR12 Type 1C Builtin yes yes no 7 0
PJQDRI+CMSS12 Type 1C Builtin yes yes no 12 0
YWUWUS+IPAexGothic CID TrueType Identity-H yes yes no 14 0
NYPDSK+CMMI10 Type 1C Builtin yes yes no 16 0
JNQBVD+CMR10 Type 1C Builtin yes yes no 17 0
NHZZSQ+CMEX10 Type 1C Builtin yes yes yes 18 0
@sekika
sekika / sample.tex
Created November 22, 2015 16:25
サンプル TeX ファイル
\documentclass[11pt, a4j, titlepage]{jsarticle}
\usepackage[dvipdfmx]{graphicx}
\usepackage[dvipdfmx]{hyperref}
\usepackage{amssymb, amsmath}
\usepackage{enumitem}
\usepackage{numprint}
\usepackage{siunitx}
\usepackage{ascmac}