Skip to content

Instantly share code, notes, and snippets.

View Buom01's full-sized avatar

Bastien Adam Buom01

View GitHub Profile
@Buom01
Buom01 / icon_to_emoticons.sh
Created August 26, 2021 02:47
Convert SVG icons to PNG emoticons with ImageMagick
#!/bin/sh
size="128"
for file in *.svg; do
convert -background transparent -geometry ${size}x${size} -gravity Center -extent ${size}x${size} ${file} ${file%%.*}_1x1.png
done
@Buom01
Buom01 / fullcalendar-preact.js
Created November 8, 2020 03:20
@fullcalendar for preact, based on `@fullcalendar/react`
import { h, Component } from 'preact';
import '@fullcalendar/core/vdom.js';
import {
CalendarApi, CalendarDataProvider,
CalendarContent, CalendarRoot
} from '@fullcalendar/common';
export default class FullCalendar extends Component
{
#!/bin/sh
# One-paste-install:
# sh -c "$(curl -fsSL https://gist.githubusercontent.com/Buom01/c8e332bc56e9076c29645af8aa532875/raw/minilibx-linux-installer.sh)"
function install_failed()
{
echo "Installation failed!"
exit 1
}
#!/bin/bash
MEDIA_PATH="/run/media/user/"
VIDEO_PATH=$(find $MEDIA_PATH -name "VIDEO*")
mplayer -nogui $VIDEO_PATH -fs -framedrop -dr -ontop -panscan 1 -stop-xscreensaver -vsync -loop 0
@Buom01
Buom01 / world.ini
Created May 31, 2019 02:42
Generate void (empty/full of air) world on cuberite
;...
[Generator]
Generator=Composable
BiomeGen=Constant
ConstantBiome=Forest
ShapeGen=HeightMap
HeightGen=Flat
FlatHeight=0
CompositionGen=SameBlock
@Buom01
Buom01 / world.ini
Created May 31, 2019 02:38
Generate flat world on cuberite
; ...
[Generator]
Generator=Composable
BiomeGen=Constant
ConstantBiome=Forest
ShapeGen=HeightMap
HeightGen=Flat
FlatHeight=64
CompositionGen=Classic
@Buom01
Buom01 / ic_logo.xml
Last active December 23, 2019 18:03
TWA splashscreen
<!---
IMPORTANT NOTE: This gist in now useless since splashscreen are now supported: https://github.com/GoogleChromeLabs/svgomg-twa/pull/23/files#diff-4ad2826e1292d083a4995de57bfaf133
-->
<!-- import here your svg logo (in drawables)
See https://stackoverflow.com/questions/30923205/easiest-way-to-use-svg-in-android/39266840#39266840
-->
@Buom01
Buom01 / collection.blog.js
Created February 23, 2017 12:09
A simple exemple of file upload using `dropbox` V2 API, `ostrio:files` and ImageMagick (gm package)
/*
Code based on: https://github.com/VeliovGroup/Meteor-Files/wiki/DropBox-Integration/5bc0adcba782f404994ff6a972fdf18ee5fec14a
This forked version probably need any verifications
*/
import {
blog_schema //Using simple-schema
} from "../schema/collection.blog.js";
import {