Skip to content

Instantly share code, notes, and snippets.

View fu-sen's full-sized avatar
🎈
🎈😍

BALLOON | FU-SEN fu-sen

🎈
🎈😍
View GitHub Profile
@fu-sen
fu-sen / Caddyfile
Last active September 17, 2022 01:11
Caddy v2 (Officical Docker Image) with Google Cloud Run (Freely editable Caddyfile) https://caddy.community/t/caddy-works-with-google-cloud-run/6898
:{$PORT}
root * /srv
# Do not rewrite up to this point!
file_server
templates
@fu-sen
fu-sen / sin.c
Last active September 4, 2022 11:38
Sine curve | z88dk mono graphics
/*
Sine curve | z88dk mono graphics
Copyright (c) 2019 Keiichi Shiga (BALLOON | FU-SEN)
The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
MSX (MSX turbo R has the tape feature removed!):
zcc +msx -lm -lmsxbios -create-app -bn sin sin.c (Cassette tape image, generate sin.cas)
--> BLOAD"CAS:",R
zcc +msx -lm -lmsxbios -create-app -subtype=disk -bn sin sin.c (BASIC BLOAD file, generate sin.msx)
--> BLOAD"SIN.MSX",R
@fu-sen
fu-sen / balloons.c
Last active September 4, 2022 11:23
風船 Balloons version 2 | MSX-BASIC 2.0+ (MSX2/MSX2+/turbo R) / z88dk https://msxjpn.jimdofree.com/%E3%83%97%E3%83%AD%E3%82%B0%E3%83%A9%E3%83%A0/%E9%A2%A8%E8%88%B9/
/*
Balloons version 2 | MSX-BASIC 2.0+ / z88dk
Copyright (c) 2019 Keiichi Shiga (BALLOON | FU-SEN)
The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
zcc +msx -lndos -create-app -subtype=disk -bn balloons balloons.c
--> BLOAD"BALLOONS.MSX",R
*/
void wrtvdp(char reg, char data)
@fu-sen
fu-sen / .htaccess
Last active August 12, 2021 01:31
Ideal transfer of 503
ErrorDocument 503 https://www.youtube.com/watch?v=8Mix9V42qJ8
<?php
/*
IchigoJam web での動作は次の 1 行が必要です。
mj.15j.run は .htaccess でこれを入れています。
header("Access-Control-Allow-Origin: *");
*/
header('Content-Type: text/plain');
@fu-sen
fu-sen / phpinfo.php
Last active June 2, 2021 04:14
phpinfo() with IBM Cloud Functions - This output will be the Plain Text version.
<?php
function main(array $args) : array
{
ob_start();
phpinfo();
$phpinfo = ob_get_contents();
ob_end_clean();
return [
"headers" => ['Content-Type' => 'text/plain'],
@fu-sen
fu-sen / README.md
Last active June 2, 2021 01:06
Use PHP 8.0 with IBM Cloud Functions
ibmcloud fn action create <ACTION-NAME> --docker openwhisk/action-php-v8.0 FILE.php --web true

If you were already using the PHP 7.3 runtime, you can run ibmcloud fn action update instead.
You can zip multiple files with .zip instead of FILE.php and specify it.
The source will work almost in common with the PHP 7.3 runtime.
This operation requires CLI to edit the source. (Cannot be edited from the console)

FROM abiosoft/caddy:php
COPY ./ /srv/
RUN sed -i 's/0\.0\.0\.0/0.0.0.0:{$PORT}/' /etc/Caddyfile
RUN sed -e '$a tls off' /etc/Caddyfile
' RANDOM screen | MSX JAPAN top page program 23 May, 2019 | MSX-BASIC
' Copyright (c) 2019 Keiichi Shiga (BALLOON | FU-SEN)
' The MIT License (MIT) - https://mit.balloon.net.eu.org/#2019
10 DEFINT A-Z
20 COLOR 15,1,1
30 SCREEN 3
40 X=RND(1)*256
50 Y=RND(1)*192
60 C=RND(1)*15+1
70 PSET(X,Y),C
@fu-sen
fu-sen / CAL.BAS
Last active February 12, 2021 12:32
カレンダー ( Calendar ) - SHARP POCKET COMPUTER PC-G850 series BASIC https://poke-com.jimdofree.com/basic-%E3%83%97%E3%83%AD%E3%82%B0%E3%83%A9%E3%83%A0/
1 ' Calendar | SHARP POCKET COMPUTER PC-E200 / G series BASIC
2 ' Copyright (c) 2006-2009 Keiichi Shiga (BALLOON | FU-SEN)
3 ' The MIT License (MIT) - https://mit.balloon.net.eu.org/#2006-2009
100 DIM D(12)
110 INPUT "ネン = ";Y
120 INPUT "ツキ = ";M
130 FOR I=1 TO 12:READ D(I):NEXT I
140 IF Y MOD 4=0 AND (Y MOD 100<>0 OR Y MOD 400=0 ) LET D(2)=D(2)+1
150 IF M<3 LET Y=Y-1:M=M+12
160 O = INT (Y+ INT (Y/4)- INT (Y/100)+ INT (Y/400)+ INT ((13*M+8)/5)+1) MOD 7