Skip to content

Instantly share code, notes, and snippets.

View mamemomonga's full-sized avatar

Shotaro Takahashi mamemomonga

View GitHub Profile
@mamemomonga
mamemomonga / gulp.md
Created March 12, 2020 04:11
gulpクイックスタート

nodeとyarnのクイックインストール

$ apt update && apt install -y curl sudo xz-utils
$ bash << 'EOS'
NODE_VERSION=12.16.1
curl -Lo /tmp/node.tar.xz https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-x64.tar.xz
curl -Lo /tmp/yarn.tar.gz https://yarnpkg.com/latest.tar.gz

mkdir /tmp/node
@mamemomonga
mamemomonga / arduino-cli.md
Last active November 26, 2020 05:20
Arduino-CLI メモ
@mamemomonga
mamemomonga / 00_README.md
Last active March 31, 2020 02:51
basedir

スクリプトの設置された位置から一つ下の階層を参照する

スクリプト内部で相対パスで参照し、かつ開始地のカレントディレクトリが不定な場合に便利である。

  • 01_basedir.sh Bashの例
  • 02_basedir.sh Perlの例
@mamemomonga
mamemomonga / escape.md
Created March 6, 2020 05:49
Bashのエスケープシーケンス
@mamemomonga
mamemomonga / 1_sample.txt
Last active February 13, 2020 13:35
何かのサンプルデータ
---1列目-1段目----
赤青黄緑赤青黄緑赤青黄緑
白白白白白白白白白白白白
水水水水水水水水水水水水
赤青黄緑赤青黄緑赤青黄緑
白白白白白白白白白白白白
水水水水水水水水水水水水
赤青黄緑赤青黄緑赤青黄緑
白白白白白白白白白白白白
水水水水水水水水水水水水
@mamemomonga
mamemomonga / jq.md
Last active March 20, 2020 06:28
jqコマンドサンプル集

jqサンプル集

cat animals.json

{
        "animals":[
                {
                        "name": "cat",
                        "say":"meow",

"types": [

@mamemomonga
mamemomonga / nginx.md
Last active February 6, 2020 09:52
取り急ぎローカルホストでnginxを動かす

取り急ぎローカルホストでnginxを動かす

  • 要Docker
  • コピペするときは $ のあとからつぎの$ の前の改行までコピペする

コマンド

$ cat > nginx.conf << 'EOS'
user  nginx;

worker_processes 1;

@mamemomonga
mamemomonga / gist:ad97ff3d89a09b765e1d2d8515c2fc54
Created February 6, 2020 08:24
ssh-agentを起動してtmuxを起動してssh-addする
exec ssh-agent tmux new-session 'ssh-add; exec $SHELL'
/etc/sysctl.conf
net.ipv6.conf.all.disable_ipv6 = 1
@mamemomonga
mamemomonga / shellscript.bat
Last active January 31, 2020 08:10
busybox.exeとバッチファイルだけでWindowsでシェルスクリプトを実行する
: <<EOF_BAT
@ECHO OFF
REM ***********************************************************
REM busybox.exeとバッチファイルだけでWindowsでシェルスクリプトを実行する
REM ***********************************************************
REM 同じフォルダにbusybox.exeを入れておく
REM busybox.exe 入手先
REM https://frippery.org/busybox
REM https://github.com/rmyorston/busybox-w32
REM 参考