Skip to content

Instantly share code, notes, and snippets.

View magdesign's full-sized avatar
💭
slow to respond, since I am cycling...

magdesign magdesign

💭
slow to respond, since I am cycling...
View GitHub Profile
@magdesign
magdesign / sxmo_hook_battery.sh
Created February 26, 2024 18:21
low battery warning, goes into ~/.config/sxmo/hooks/sxmo_hook_battery.sh
GNU nano 7.2 .config/sxmo/hooks/sxmo_hook_battery.sh
#!/bin/sh
# configversion: d7a31b6b01150a2b1ad3e57f556a5de6
load_data() {
data="$(upower -i "$1" | grep . | sed -e 's|^ \+||' -e 's|: \+|:|')"
type="$(printf "%b" "$data" | grep -m1 -v : | sed -e 's|^ \+||')"
}
data_get() {
@magdesign
magdesign / bonsai_tree.json
Created February 12, 2024 17:54
powerbutton_four
[
{
"type": "event",
"event_name": "power_pressed",
"transitions": [
{
"type": "delay",
"delay_duration": 400000000,
"transitions": [
{
@magdesign
magdesign / kdeglobals
Created January 31, 2024 13:23
file to set darktheme for kde apps on linuxmobile
[ColorEffects:Disabled]
ChangeSelectionColor=
Color=56,56,56
ColorAmount=0
ColorEffect=0
ContrastAmount=0.65
ContrastEffect=1
Enable=
IntensityAmount=0.1
IntensityEffect=2
@magdesign
magdesign / squeekboard.md
Created January 25, 2024 19:07
Squeekboard Keyboard modify/tab key

Squeekboard Keyboard modify/tab key

you can modify the keyboard by yourself, following will just add tab key to first page

mkdir -p ~/.local/share/squeekboard/keyboards/terminal/
cd ~/.local/share/squeekboard/keyboards/terminal/
wget https://gist.githubusercontent.com/magdesign/33aa088987d0df044eb75e5a263ca76d/raw/e06dd7535f90037c4c93e91ecf0e6e39afd78611/us.yaml

if you need umlauts use:

@magdesign
magdesign / ovpn_howtoadd_cli.md
Created January 25, 2024 13:53
add a openvpn configuration file in cli

How to add a .ovpn config file via cli in linux:

sudo nmcli connection import type openvpn file vpnfile.ovpn

How to set the username:

sudo nmcli connection modify "${vpnname}" +vpn.data username="${myname}"

How to set password:

@magdesign
magdesign / us.yaml
Last active January 26, 2024 09:06
terminal squeekboard with tab key on basic
---
outlines:
default: { width: 35.33, height: 43 }
action: { width: 59, height: 43 }
altline: { width: 52.67, height: 43 }
wide: { width: 59, height: 43 }
spaceline: { width: 140, height: 43 }
special: { width: 44, height: 43 }
small: { width: 59, height: 32 }
#!/bin/sh
# __ _
# / _| ___ _ __ (_)_ __
# | |_ / _ \ '_ \| \ \/ /
# | _| __/ | | | |> <
# |_| \___|_| |_|_/_/\_\
#
#
# Make firefox real mobile, find all the info here:
# https://forums.puri.sm/t/mobile-friendly-firefox-customizations-for-librem-5/20313/61
@magdesign
magdesign / pinephonepro
Last active July 13, 2022 14:58
Pinephonepro to do on fresh install
new and updated version of this is here: https://codeberg.org/magdesign/Pinephone_Things2doAfterInstall/src/branch/main/README.md
things to do after fresh install of an os:
sudo nano /etc/fstab add noatime
# update system
sudo pacman -Syyu
# install pamac
@magdesign
magdesign / osmin
Created April 8, 2022 14:39
build osmin on pinephone
[magdesign@manjaro-arm osmin]$ cmake -B build -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang++ .
-- Found Qt5 version 5.15.3
-- Downloading marisa
-- Configuring done
-- Generating done
-- Build files have been written to: /home/magdesign/Downloads/osmin/build/backend/marisa-download
[100%] Built target marisa-download
-- Build MARISA: /home/magdesign/Downloads/osmin/build/backend/marisa-build
-- SSE test compilation fails
CMake Warning (dev) at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
@magdesign
magdesign / Processing_Countdown
Created November 30, 2020 10:45
Countdown which triggers scrit at 0
/*countdown, t- from data.txt file,
when finished trigger a trigger.sh (make sure to declare exact path when compiling)
and destroy itself
2020*/
///load time from a file, decalred as data ( you don't need an array, as there is just one value to pick )
int timer;
/// declare the String Array to store the data from the txt file
String[] txtFile;