Skip to content

Instantly share code, notes, and snippets.

View tyru's full-sized avatar
🏠
Working from home

Fujiwara Takuya tyru

🏠
Working from home
View GitHub Profile
@azu
azu / git-2.26.1-README.md
Last active January 22, 2022 21:54
Gitの認証情報を奪い取れるGit 2.26.0以下にある脆弱性について

Git 2.26.0以下にある脆弱性

Git 2.26.0以下*1には、細工したリポジトリをgit cloneしたときに、 そのユーザーのCredential(たとえばGitHub.comをcloneするときに使う認証情報)を奪い取れる脆弱性があります。

📝 取得できる認証情報は credential.helper の設定に依存する

既にPoC(検証するためのコード)もあり、結構簡単なので是非Gitを2.26.1以上にアップデートしましょう。 git submoduleを使うと見た目ではわかりにくい攻撃もできるので、「気をつける」では回避は難しいです。

@itchyny
itchyny / go114-regression.md
Last active April 8, 2020 23:23
Go 1.14の主なregression

Go 1.14 の主なregressionです。1.14.1で修正されると思われます。

@Shougo
Shougo / gist:d8898fae31d9c8dc791224cf34840f15
Created February 2, 2020 06:17
テキストエディタ界隈まとめ 1 月 4 週
テキストエディタ界隈まとめ 1 月 4 週
* Vim9 がマージされる
https://github.com/vim/vim/commit/8a7d6542b33e5d2b352262305c3bfdb2d14e1cf8
Vim 8.2.0149 で突如 Vim9 開発ブランチがマスターにマージされました。
Vim9 は Perl5 と Perl6 くらいの違いがあり個人的に別言語です。
ちなみに、neovim は Lua との連携に集中するようですね。
@andywer
andywer / _readme.md
Last active March 7, 2024 05:52
React - Functional error boundaries

React - Functional error boundaries

Thanks to React hooks you have now happily turned all your classes into functional components.

Wait, all your components? Not quite. There is one thing that can still only be implemented using classes: Error boundaries.

There is just no functional equivalent for componentDidCatch and deriveStateFromError yet.

Proposed solution

@lambdalisue
lambdalisue / List.vim
Created December 10, 2018 19:36
compare old/new vital.data.list
let s:Benchmark = vital#vital#import('Vital.Benchmark')
let s:Old = vital#vital#import('Data.List')
let s:New = vital#vital#import('Vital.List')
function! s:map() abort
let list = repeat(['hello'], 1000)
echo 'map()'
echo printf(
\ ' Old: %f sec',
\ s:Benchmark.timeit({ -> s:OldList.map(list, { v -> toupper(v) }) })
@thinca
thinca / .zshrc
Last active November 23, 2017 12:58
Support :command in zsh in Vim (experimental)
# put this code in your .zshrc
if [[ "${VIM_TERMINAL_SHELL}" != "" ]]; then
command_not_found_handler() {
if [[ "${1}" != :* ]]; then
echo "command not found: ${1}" > /dev/stderr
return 127
fi
echo -ne "\e_$*\e\\" > /dev/tty
while [[ ! -f "${VIM_TERMINAL_SHELL}" ]]; do
@sile
sile / rfc.md
Last active June 2, 2022 15:19
Rustの『RFC 2033: 実験的なコルーチン』の要約メモ
mingw32-make -f Make_ming.mak GUI=no IME=yes MBYTE=yes ICONV=yes ^
PERL=c:/mingw64/mingw64 DYNAMIC_PERL=yes PERL_VER=522 ^
PERLEXE=c:/msys64/mingw64/bin/perl.exe ^
PERLLIB=c:/msys64/mingw64/lib/perl5/core_perl ^
PYTHON=c:/msys64/mingw64 DYNAMIC_PYTHON=yes PYTHON_VER=27 ^
PYTHON_HOME=c:/msys64/mingw64 ^
PYTHONINC=-Ic:/msys64/mingw64/include/python2.7 ^
DYNAMIC_PYTHON_DLL=libpython2.7.dll ^
PYTHON3=c:/msys64/mingw64 DYNAMIC_PYTHON3=yes PYTHON3_VER=36 ^
PYTHON3_HOME=c:/msys64/mingw64/ ^
@k-takata
k-takata / 256colors2.bat
Last active November 25, 2023 16:23
Testing ANSI color sequence on Windows 10 and other terminal emulators
@echo off
rem Based on Todd Larason's 256color2.pl.
rem Ported to Windows 10's Command Prompt.
setlocal EnableDelayedExpansion
rem display the colors
rem first the system ones:
echo System colors: