Skip to content

Instantly share code, notes, and snippets.

View jakkrokk's full-sized avatar

jakkrokk jakkrokk

View GitHub Profile
if ('serviceWorker' in navigator) {
navigator.serviceWorker
.register('service-worker.js')
.then(function(registration) {
return registration.pushManager.getSubscription().then(function(subscription) {
if (subscription) {
return subscription
}
return registration.pushManager.subscribe({
userVisibleOnly: true
{
"name": "Weather",
"short_name": "Weather",
"icons": [{
"src": "images/icons/icon-128x128.png",
"sizes": "128x128",
"type": "image/png"
}, {
"src": "images/icons/icon-144x144.png",
"sizes": "144x144",
var filesToCache = [
'index.html',
'images/aaa.png',
'js/main.js',
'css/styles.css',
];
0 9 * * * sleep $(($RANDOM % 1800)); echo flucted!!
$conveted = mb_convert_encoding($word, 'UTF-8', 'ASCII,JIS,UTF-8,EUC-JP,SJIS-win');
rsync -e "ssh -p 2222" -aur test@111.222.333.444:/var/www/html/* /var/www/html/
$w1 = '上';
$w2 = mb_convert_encoding($w1,'SJIS','ASCII,JIS,UTF-8,EUC-JP,SJIS-win,SJIS');
echo mb_convert_encoding($w2,'UTF-8','SJIS-win,SJIS,ASCII,JIS,UTF-8,EUC-JP');
$w1 = '上';
$w2 = mb_convert_encoding($w1,'SJIS','ASCII,JIS,UTF-8,EUC-JP,SJIS-win,SJIS');
echo mb_convert_encoding($w2,'UTF-8','ASCII,JIS,UTF-8,EUC-JP,SJIS-win,SJIS'); //真っ白
find . -name 'cache*' -type d | xargs chmod 777
public void setStrokeWidth(Float width) {
Log.d(LCAT, "Changing stroke width.");
tiPaintView.finalizePaths();
tiPaint.setStrokeWidth(TiConvert.toFloat(width));
tiPaint.setAlpha(alphaState);
}