Skip to content

Instantly share code, notes, and snippets.

View BobSynfig's full-sized avatar
🇬🇷

BobSynfig BobSynfig

🇬🇷
View GitHub Profile
@BobSynfig
BobSynfig / synfig-broadway.sh
Last active April 26, 2022 22:14
Run Synfig in a Web Browser!
#!/bin/bash
# Access SynfigStudio from your web browser at the address http://IP:PORT
# You can use for example a Tablet with a BlueTooth mouse
# Note: You may have to open the port in your firewall to access it from another device
IP=192.168.0.21 # The Ip of your interface
PORT=3131 # The Port
B_DISPLAY=:5 # A display number, 5 should be fine
# You can select a theme or let it empty for the default theme
@BobSynfig
BobSynfig / set_loops.py
Last active March 18, 2022 17:22
Set GIF animation loops number
#!/usr/bin/python3
# https://en.wikipedia.org/wiki/GIF#Animated_GIF
# The number of loops (0..65535) is located 3 bytes after the string "NETSCAPE2.0"
import sys
sys.argc = property(lambda self: len(self.argv)).__get__(sys, sys.__class__)
if ( (sys.argc == 1) or
((sys.argc == 2) and (sys.argv[1] == '--help'))):
print("Set GIF animation loops number")
@BobSynfig
BobSynfig / PatchEnveManjaroFedora.sh
Last active December 7, 2022 09:44
Patch for enve in Manjaro and Fedora - Solves libgio-2.0.so.0 error
#!/bin/bash
#
# Patch for enve in Manjaro and Fedora
#
# Solves libgio-2.0.so.0 error by removing embedded libstdc++.so.6 and libgmodule-2.0.so.0
# See https://github.com/MaurycyLiebner/enve/issues/289
# https://github.com/MaurycyLiebner/enve/issues/301
#
# Based on:
# https://github.com/AppImage/AppImageKit/issues/1162
@BobSynfig
BobSynfig / ext-keyb
Created June 8, 2019 17:24
External keyboard with a different layout under Linux
#!/bin/bash
# String identifying the keyboard (under "Virtual core keyboard" with xinput list)
EXT_KEYB_STR="NOVATEK USB Keyboard"
# Taken from Command line
EXT_KEYB_LANG=$1
EXT_KEYB_ID=`xinput list|grep "$EXT_KEYB_STR"|awk -F" " '{print $5}'|awk -F= '{if($2!="") print $2}'|head -n 1`
# This is field #5 because (Word count of EXT_KEYB_STR + 2) --^