Skip to content

Instantly share code, notes, and snippets.

Avatar

funatsufumiya funatsufumiya

View GitHub Profile
View wifi-auto-reconnect.sh
#!/bin/sh
while true
do
/sbin/ping -W 3 -t 1 google.com>/dev/null
if [ $? -ne 0 ]; then
date=$(date "+%Y/%m/%d %H:%M:%S")
View settings.json
{
"workbench.colorTheme": "Default Dark+",
"security.workspace.trust.untrustedFiles": "open",
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"vim.insertModeKeyBindings": [
{
"before": ["j", "j"],
"after": ["<Esc>"]
}
@funatsufumiya
funatsufumiya / main.dart
Last active Nov 13, 2021
Easy ScrollView and ScrollListView
View main.dart
import 'package:flutter/material.dart';
void main() => runApp(App());
class SimpleScrollView extends StatelessWidget {
SimpleScrollView({required this.child, this.isAlwaysShown = true});
final Widget child;
final bool isAlwaysShown;
@funatsufumiya
funatsufumiya / main.dart
Created Nov 13, 2021
Scroll always shown template
View main.dart
import 'package:flutter/material.dart';
void main() => runApp(App());
class App extends StatelessWidget {
final _scrollController = ScrollController();
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Material(
View youtube-dl-x16
alias "youtube-dl-x16"="youtube-dl --external-downloader aria2c --external-downloader-args \"-j 16 -x 16 -s 16 -k 1M\""
View enable_shingeta_ruby_dual_topre.sh
#!/bin/bash
ID1=$(cat /proc/bus/input/devices | grep -m 1 -A 4 'Name="Topre' | tail -n 1 | sed -e 's/.*event\([0-9]\+\).*/\1/' | tr -d '\n')
ID2=$(cat /proc/bus/input/devices | grep -m 2 -A 4 'Name="Topre' | tail -n 1 | sed -e 's/.*event\([0-9]\+\).*/\1/' | tr -d '\n')
/usr/bin/gnome-terminal -e 'bash -c "echo \"input device ids: '$ID1', '$ID2'\"; echo \"shingeta is working (if close, stops)\"; cd /path/to/shingeta-linux-ruby; echo PASSWORD | sudo -S ruby shingeta.rb -e /dev/input/event'$ID1' -E /dev/input/event'$ID2' &> /dev/null"'
@funatsufumiya
funatsufumiya / 新下駄配列+DvorakP改2.yab
Created Jul 23, 2021
新下駄配列+DvorakP改 rev.2 ( Dvorakにおいてコロンをバックスペースにし、コロン+右親指シフトをハイフンに。かつ ] にハイフンを追加割り当て )
View 新下駄配列+DvorakP改2.yab
;新下駄配列+DvorakP改 rev.2
;( Dvorakにおいてコロンをバックスペースにし、コロン+右親指シフトをハイフンとした。 )
;( さらにrev.2では、]にハイフンを追加割り当て。 )
[ローマ字シフト無し]
1,2,3,4,5,6,7,8,9,0,-,^,¥
-,ni,ha,,入,ti,gu,ba,ko,ga,hi,ge,'['
no,to,ka,nn,ltu,ku,u,i,si,na,後,']'
su,ma,ki,ru,tu,te,ta,de,.入,bu,¥
@funatsufumiya
funatsufumiya / programmer_dvorak_cmdqwerty_forjis-kai2.json
Last active Aug 28, 2021
Programmer Dvorak-CmdQwerty Kai (rev. 2) for JIS (mapped ':' to backspace, ':' + right_shift to '-', and ']' to '-'.)
View programmer_dvorak_cmdqwerty_forjis-kai2.json
{
"title": "Programmer Dvorak-CmdQwerty Kai (rev. 2) for JIS",
"__note": "mapped ':' to backspace, ':' + right_shift to '-', and ']' to '-'.",
"rules": [
{
"description": "Programmer Dvorak-CmdQwerty Kai (rev. 2) for JIS",
"manipulators": [
{
"type": "basic",
"from": {
@funatsufumiya
funatsufumiya / programmer_dvorak_cmdqwerty_forjis-kai.json
Last active Aug 28, 2021
Programmer Dvorak-CmdQwerty Kai (rev. 1) for JIS (mapped colon to backspace, and colon + right_shift to hyphen)
View programmer_dvorak_cmdqwerty_forjis-kai.json
{
"title": "Programmer Dvorak-CmdQwerty Kai (rev. 1) for JIS",
"__note": "mapped colon to backspace, and colon + right_shift to hyphen",
"rules": [
{
"description": "Programmer Dvorak-CmdQwerty Kai (rev. 1) for JIS",
"manipulators": [
{
"type": "basic",
"from": {
@funatsufumiya
funatsufumiya / 新下駄配列+DvorakP改.yab
Last active Jul 22, 2021
新下駄配列+DvorakP改.yab ( Dvorakにおいてコロンをバックスペースにし、コロン+右親指シフトをハイフンとした )
View 新下駄配列+DvorakP改.yab
;新下駄配列+DvorakP改
;( Dvorakにおいてコロンをバックスペースにし、コロン+右親指シフトをハイフンとした )
[ローマ字シフト無し]
1,2,3,4,5,6,7,8,9,0,-,^,¥
-,ni,ha,,入,ti,gu,ba,ko,ga,hi,ge,'['
no,to,ka,nn,ltu,ku,u,i,si,na,後,']'
su,ma,ki,ru,tu,te,ta,de,.入,bu,¥
<k>