Skip to content

Instantly share code, notes, and snippets.

View Matthew238's full-sized avatar

Ken ichi AKIMOTO Matthew238

  • Esashi, Hokkaido, Japan
View GitHub Profile
@Matthew238
Matthew238 / get_movie_2016.rb
Created August 10, 2018 08:03
某ストリーミングを保存するスクリプト2016年大会版
#!/usr/bin/env ruby
require 'fileutils'
require 'net/http'
require 'json'
block = {
1 => ['北海道', 'ik'], 2 => ['東北', 'hk'], 3 => ['関東甲信越', 'ak'],
4 => ['東海北陸', 'ck'], 5 => ['近畿', 'bk'], 6 => ['中国', 'fk'],
7 => ['四国', 'zk'], 8 => ['九州沖縄', 'lk'], 99 => ['全国', 'jk']
@Matthew238
Matthew238 / mp4_probe.py
Created July 5, 2018 23:40
指定されたディレクトリツリー中の全ディレクトリの全mp4ファイルの属性をCSV形式で標準出力するスクリプト
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import shutil
import sys
import os
import subprocess
import json
import math
import re
@Matthew238
Matthew238 / manyconvert_ffmpeg
Last active April 10, 2018 03:41
A convert shell script from ts to mp4 with ffmpeg
#!/bin/bash
CMDNAME=`basename $0`
dir_d="/mnt/d/ほげ"
dir_f="/mnt/f/ふが"
directory="$dir_f"
while getopts dfn: OPT
do
case $OPT in
@Matthew238
Matthew238 / A static page for Heroku maintenace mode
Last active September 28, 2017 02:00
an experimental static html code for Heroku maintenance mode
<!DOCTYPE html>
<html>
<head>
<meta charaset="utf-8" />
<title>高専ロボコンデータベース</title>
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css">
<!--
.wrap{
background: url(http://3.bp.blogspot.com/-xIvZovJ1qLk/WRaTaKHOP5I/AAAAAAABEQo/WktWXesekkoQ-BuFNkoXPgAD7YnhFTE5wCLcB/s800/machine_robot_contest.png);
@Matthew238
Matthew238 / manyconvert
Last active November 9, 2020 02:32
A convert shell script from ts to mp4 with VLC
#!/bin/bash
vlc="/mnt/c/Program\ Files/VideoLAN/VLC/vlc.exe"
directory="tvrec"
lin_directory="/mnt/f/"$directory
win_directory="f:\\"$directory
src_ext="ts"
dst_ext="mp4"
files=$lin_directory"/*."$src_ext
#filearr=()
@Matthew238
Matthew238 / get.html
Last active June 6, 2016 12:15
高専ロボコン情報取得ツール(IE専用)
<!-- -*- encoding: utf-8 -*- -->
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
html { height: 100% }
body { height: 100%; margin: 0px; padding: 0px }
</style>
<script type="text/javascript" charset="UTF-8">
//<![CDATA[
@Matthew238
Matthew238 / campus_code.html
Last active June 6, 2016 09:06
Chrome上での実行とそのデバッガーの利用を前提とした高専ロボコンDBのキャンパスコード生成のためのhtmlファイルに内包されたJavaScriptソースコード。
<!-- -*- encoding: utf-8 -*- -->
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
html { height: 100% }
body { height: 100%; margin: 0px; padding: 0px }
</style>
<script src="http://maps.google.com/maps/api/js?v=3&sensor=false"
type="text/javascript" charset="UTF-8"></script>