Skip to content

Instantly share code, notes, and snippets.

View kimikimi714's full-sized avatar

kimikimi714 kimikimi714

View GitHub Profile
@kimikimi714
kimikimi714 / daily_init.sh
Created April 5, 2019 06:43
日々のコマンド
brew upgrade
brew cleanup
gcloud components update

summary

  • hoge

other links

  • hoge
@kimikimi714
kimikimi714 / ArrayTest.php
Last active February 2, 2016 09:32
knowledge of phpunit
<?php
class ArrayTest extends PHPUnit_Framework_TestCase {
/**
* @test
*/
public function array_test() {
$actual = ['b', 'a'];
$expect = ['a', 'b'];
$this->assertSame($expect, $actual);
/*
@kimikimi714
kimikimi714 / chrome.js
Last active January 17, 2016 11:57
chrome extension test
var remind = function (detail) {
console.log(detail.url);
// chrome.notifications.create('reminder', {
// type: 'basic',
// iconUrl: 'icon-128.png',
// title: 'sent request! ' + detail.tabId,
// message: detail.url
// }, function(notificationId) {});
}
@kimikimi714
kimikimi714 / how_to_execute.sh
Last active August 29, 2015 14:03
うまくいったpharファイル作成テスト。Hello.phpはhttps://gist.github.com/kimikimi714/cc9b503f09ecbdf0cb02 と同じで、make_phar.phpとopen_phar.phpを修正した。またスタブとしてhello直下にmain.phpをおいてる
#!/bin/bash
php -d phar.readonly=0 make_phar.php
php open_test.php
@kimikimi714
kimikimi714 / Hello.php
Last active February 7, 2016 21:52
How to make valid phar file? (Hello.php puts in hello directory.)
<?php
class Hello {
public function sayHello() {
echo "hello\n";
}
}
@kimikimi714
kimikimi714 / grep.sh
Created June 7, 2014 14:48
自分で作ったスクリプトまとめ ref: http://qiita.com/kimikimi714/items/ed3dfb698a6ae6269c00
#!/bin/sh
filename=$1
word=$2
cat ${filename} | while read line
do
grep -l ${word} ${line};
done