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
/* タイトルと URL コピーするやつ */ | |
!function (document) { | |
var text = prompt("コメント:"); | |
if (text == null) { | |
return; | |
} | |
text = text === "" ? "" : text + "\n\n"; | |
var body = document.body; | |
var element = document.createElement("textarea"); |
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
<?php | |
$str = str_repeat(PHP_VERSION, 200000); | |
$len = strlen($str); | |
$r = null; | |
$e = null; | |
$w = []; | |
$bytes = []; | |
foreach (range(1, 100) as $i) { | |
$w[] = $fp = fopen("test{$i}.txt", 'wb'); |
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
os: linux | |
node_js: '12' | |
sudo: required | |
env: DISPLAY=':99.0' | |
dist: trusty | |
addons: | |
apt: | |
update: true | |
sources: | |
- google-chrome |
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
<!DOCTYPE html> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8"> | |
<title></title> | |
</head> | |
<body> | |
<div id="app" style="display: none" :style="{ display: 'block' }"> | |
<input type="button" value="ホモを出す" v-on:click="activate"> | |
<ul> |
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
python3<<<"import neovim; neovim.attach('socket', path='$NVIM_LISTEN_ADDRESS').input('<C-\\><C-n>')" |
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
import { path } from 'path'; | |
import { glob } from 'glob'; | |
import { webpack } from 'webpack'; | |
const entries = Object.assign( | |
...glob.sync('./app/webroot/scripts/js/test/**/entry.js') | |
.map(file => ({ [ path.basename(path.dirname(file)) ]: file })) | |
); | |
console.log(Object.keys(entries)) |
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
doruȝ- | |
dorw | |
dorwe | |
dorwgh | |
dourȝh | |
drowgȝ | |
durghe | |
durwe | |
-thogh | |
thorch |
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
<template> | |
<article>{{ message }}</article> | |
</template> | |
<script lang="babel"> | |
module.exports = { | |
computed: { | |
...Vuex.mapState([ | |
'message', | |
]), |
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
<?php | |
// https://qiita.com/mpyw/items/0fdffd3c70b3abd802f5 | |
function array_group_by_range(array $array, $separator = '-') | |
{ | |
sort($array, SORT_NUMERIC); | |
$pairs = $ranges = []; | |
foreach (array_values(array_unique($array, SORT_NUMERIC)) as $i => $v) { | |
$pairs[$v - $i][isset($pairs[$v - $i])] = $v; | |
} |
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
#!/bin/bash | |
RUN=/opt/vyatta/bin/vyatta-op-cmd-wrapper | |
# Slack Webhook | |
HOOK_URL='' | |
# Arguments | |
GROUP=$1 | |
INTF=$2 | |
STATUS=$3 |