Skip to content

Instantly share code, notes, and snippets.

View aamaanaa's full-sized avatar
πŸ’»
πš†πšŠπšπšŒπš‘πš’πš—πš πšŠπš—πš’πš–πšŽ

NotAqua aamaanaa

πŸ’»
πš†πšŠπšπšŒπš‘πš’πš—πš πšŠπš—πš’πš–πšŽ
  • In Aqua
View GitHub Profile
@igv
igv / adaptive-sharpen.glsl
Last active July 7, 2025 20:25
Optimal sharpening strength (according to objective metrics) - 0.5. Can be applied only to luma channel (change OUTPUT to LUMA). To use it on-demand add the following line to input.conf: n change-list glsl-shaders toggle "~~/adaptive-sharpen.glsl"
// Copyright (c) 2015-2021, bacondither
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
// are met:
// 1. Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer
// in this position and unchanged.
// 2. Redistributions in binary form must reproduce the above copyright
@vwbusguy
vwbusguy / auto_profile
Last active May 14, 2025 08:03
Auto Update for power-profiles-daemon
#!/bin/bash
dbus-monitor --system "type='signal',path='/org/freedesktop/UPower/devices/battery_BAT0',member='PropertiesChanged'" | while read LINE; do
echo ${LINE} | grep battery_BAT0 | grep -q PropertiesChanged
if [ $? -eq 0 ]; then
BATT_STAT=$(dbus-send --print-reply=literal --system --dest=org.freedesktop.UPower /org/freedesktop/UPower/devices/battery_BAT0 org.freedesktop.DBus.Properties.Get string:org.freedesktop.UPower.Device string:State | awk '{ print $3; }')
if [ $BATT_STAT -eq 1 ] || [ $BATT_STAT -eq 4 ]; then
LEVEL=$(tuned-adm list | grep -q throughput-performance && echo "throughput-performance" || echo "balanced")
elif [ $BATT_STAT -eq 5 ]; then
LEVEL="balanced"
@aamaanaa
aamaanaa / gist:20a55dcf98b094583196c662b03f7bbe
Created October 27, 2022 12:03
Linux write access to /var/www/html/project
You will need to add you user to the 'apache' group first. Log out afhter you have done that.
$ sudo mkdir /var/www/html/project
$ sudo chown -R $USER:apache /var/www/html/project
$ sudo chmod -R 775 /var/www/html/project
@alexedwards
alexedwards / cache.go
Last active May 1, 2025 00:58
Generic in-memory cache implementation in Go
package cache
import (
"sync"
"time"
)
// Cache is a basic in-memory key-value cache implementation.
type Cache[K comparable, V any] struct {
items map[K]V // The map storing key-value pairs.
@mnabila
mnabila / JetBrains trial reset.md
Created February 28, 2024 08:17 — forked from h3ssan/JetBrains trial reset.md
Reset all JetBrains products trial in Linux

In some cases, only these lines will work

for product in IntelliJIdea WebStorm DataGrip PhpStorm CLion PyCharm GoLand RubyMine; do
    rm -rf ~/.config/$product*/eval 2> /dev/null
    rm -rf ~/.config/JetBrains/$product*/eval 2> /dev/null
done

But if not, try these

@aamaanaa
aamaanaa / NOTES.md
Last active July 4, 2025 15:29
Fedora notes

Fedora notes

These are my personal notes. It does not mean it is for you. I will update this from time to time.

Installing spotify

Add our user to pkg build group:

sudo usermod -a -G pkg-build $USER

Load changes witout a reboot: