Skip to content

Instantly share code, notes, and snippets.

View mimura1133's full-sized avatar

Satoshi Mimura mimura1133

View GitHub Profile
@mimura1133
mimura1133 / gist:1342542
Created November 6, 2011 06:06
三平方の定理 for Mac
#include <mach/mach.h>
#include <stdio.h>
/************************************************
とりあえず、中のデータは16進で記録してあって、
リトルエンディアンですから、
0x01020304 は、メモリ上に 0x04,0x03,0x02,0x01 の順で格納されます。
要は逆順です。
@mimura1133
mimura1133 / gist:1395485
Created November 26, 2011 11:25
Twitter OAuth 1.0 Sample
using System;
using System.Diagnostics;
using System.IO;
using System.Net;
using System.Security.Cryptography;
using System.Text;
using System.Web;
/*
* この辺を参考に:
@mimura1133
mimura1133 / zshrc
Created September 24, 2014 10:05
zshrc
# License : MIT
# http://mollifier.mit-license.org/
########################################
# If not running interactively, don't do anything.
[ -z "$PS1" ] && return
# 環境変数
export LANG=ja_JP.UTF-8
set nocompatible
if &term == 'win32'
set termencoding=cp932
set encoding=cp932
endif
set fileencodings=utf-8,cp932
set smartindent
@mimura1133
mimura1133 / QRPuzzle_Solve.hsp
Created December 6, 2015 06:29
QRPuzzle のソルバーです (HSP 3.x)
origdic="seccon|accept|achieve|acquire|add|advance|affect|agree|allow|appear|apply|approach|argue|assume|avoid|bear|beat|belong|bite|care|catch|claim|communicate|compare|consider|consume|contact|contain|continue|cost|count|cover|create|cross|decline|define|depend|describe|destroy|determine|develop|die|disappear|discover|draw|earn|encourage|enter|establish|excite|exist|expect|explain|express|face|fail|fear|feed|fire|fit|flow|follow|gain|gather|get|guess|hit|hold|hunt|hurt|imagine|improve|include|increase|indicate|influence|insist|introduce|invent|involve|lay|lead|lie|lose|maintain|manage|manufacture|marry|mean|mention|miss|observe|offer|perform|please|prefer|prepare|press|prevent|produce|program|protect|prove|provide|publish|raise|reach|realize|receive|recognize|reduce|refer|reflect|refuse|regard|remain|remember|reply|represent|require|reveal|rise|risk|rule|satisfy|save|search|seat|seek|seem|serve|share|solve|sound|spend|spread|stay|steal|stick|strike|struggle|suffer|suggest|support|suppose|surprise|survive|te
using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Numerics;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Text;
using System.Threading.Tasks;
@mimura1133
mimura1133 / install.sh
Last active January 29, 2023 21:24
Enhanced Session for Kali Linux.
#!/bin/bash
# Original : https://raw.githubusercontent.com/Microsoft/linux-vm-tools/master/arch/install-config.sh
###############################################################################
# Update our machine to the latest code if we need to.
#
if [ "$(id -u)" -ne 0 ]; then
echo 'This script must be run with root privileges' >&2
exit 1
; 一部コンポーネントにおいて、新暦処理を適用するとアプリケーションがクラッシュする事例の報告を受けております。
; つきましては、当該の副作用がご理解いただける方のみご利用頂き、そうでないかたは利用されないようお願い致します。
;
;Windows Registry Editor Version 5.00
;[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Nls\Calendars\Japanese\Eras]
;"2019 05 01"="令和_令_Reiwa_R"
comment_char %
escape_char /
% This file is part of the GNU C Library and contains locale data.
% The Free Software Foundation does not claim any copyright interest
% in the locale data contained in this file. The foregoing does not
% affect the license of the GNU C Library as a whole. It does not
% exempt you from the conditions of the license if your use would
% otherwise be governed by that license.
{
"defaultProfile": "{5b351a96-8fb8-49d7-b960-4bb0d1aee3c5}",
"initialRows": 30,
"initialCols": 120,
"alwaysShowTabs": true,
"showTerminalTitleInTitlebar": true,
"experimental_showTabsInTitlebar": true,
"profiles": [
{
"guid": "{5b351a96-8fb8-49d7-b960-4bb0d1aee3c5}",