This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import json | |
| import re | |
| import sys | |
| # Define validation rules as a list of (regex pattern, message) tuples | |
| VALIDATION_RULES = [ | |
| ( | |
| r"https://www.notion.so/", | |
| "Notion ページへのアクセスには WebFetch ツールではなく mcp__notion を利用してください", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import json | |
| import re | |
| import sys | |
| # Define validation rules as a list of (validation function, message) tuples | |
| VALIDATION_RULES = [ | |
| ( | |
| lambda cmd: True, | |
| "git grep --function-context [--and|--or|--not|(|)|-e <pattern>...] -- <pathspec>... を使ってください。--function-context フラグにより出力行が多すぎる場合、 --show-function と -C フラグを利用してください", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import json | |
| import re | |
| import sys | |
| # Define validation rules as a list of (validation function, message) tuples | |
| VALIDATION_RULES = [ | |
| ( | |
| lambda cmd: cmd.strip().startswith("grep "), | |
| "grep の変わりに git grep --function-context [--and|--or|--not|(|)|-e <pattern>...] -- <pathspec>... を使ってください。--function-context フラグにより出力行が多すぎる場合、 --show-function と -C フラグを利用してください", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| -- refs: https://developer.apple.com/library/archive/documentation/LanguagesUtilities/Conceptual/MacAutomationScriptingGuide/ReadandWriteFiles.html | |
| -- refs: https://medium.com/macoclock/how-in-the-bleep-do-i-mute-my-mic-anywhere-on-macos-d2fa1185b13 | |
| on writeTextToFile(theText, theFile, overwriteExistingContent) | |
| try | |
| set theFile to theFile as string | |
| set theOpenedFile to open for access file theFile with write permission | |
| if overwriteExistingContent is true then set eof of theOpenedFile to 0 | |
| write theText to theOpenedFile starting at eof | |
| close access theOpenedFile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Vagrant.configure("2") do |config| | |
| # refs: https://app.vagrantup.com/fedora | |
| config.vm.box = "fedora/33-cloud-base" | |
| config.vm.provider "virtualbox" do |v| | |
| v.memory = 2048 | |
| v.cpus = 2 | |
| end | |
| # https://www.vagrantup.com/docs/synced-folders/nfs |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # prefix | |
| set -g prefix C-q | |
| unbind C-b | |
| # keystroke delay | |
| set -sg escape-time 1 | |
| # to reload | |
| bind r source-file ~/.tmux.conf \; display "Reloaded!" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CFLAGS=-fPIC ./configure \ | |
| --with-tlib=ncurses \ | |
| --with-features=huge \ | |
| --with-x \ | |
| --enable-multibyte \ | |
| --enable-luainterp=dynamic \ | |
| --enable-gpm \ | |
| --enable-cscope \ | |
| --enable-fontset \ | |
| --enable-fail-if-missing \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ./configure \ | |
| --prefix=$HOME/local \ | |
| --enable-multibyte \ | |
| --enable-nls \ | |
| --enable-perlinterp \ | |
| --enable-pythoninterp=dynamic \ | |
| --enable-python3interp=dynamic \ | |
| --enable-rubyinterp \ | |
| --enable-luainterp --with-lua-prefix=/usr/local \ | |
| --enable-cscope \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export EDITOR='vim' | |
| export VISUAL='vim' | |
| export PAGER='less' | |
| # for `Ctrl + w` | |
| export WORDCHARS='*?_.[]~-=&;!#$%^(){}<>' | |
| export DIRSTACKSIZE=8 | |
| bindkey -e | |
| setopt clobber |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt install \ | |
| lua5.2 \ | |
| liblua5.2-dev \ | |
| luajit \ | |
| ruby-dev \ | |
| xorg-dev \ | |
| libncurses5-dev | |
| ./configure \ | |
| --with-features=huge \ |
NewerOlder