This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function enable { | |
pactl load-module module-loopback latency_msec=1 > ~/.micloopback.id | |
} | |
function disable { | |
pactl unload-module `cat ~/.micloopback.id` | |
} | |
if [ -f ~/.micloopback.id ]; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo 'qdbus org.kde.kactivitymanagerd /ActivityManager/Activities CurrentActivity'>/usr/bin/echo_current_activity | |
chmod +x /usr/bin/echo_current_activity | |
echo "Activity for default profile: " | |
read default_activity | |
echo ' | |
#!/bin/bash | |
'>/usr/bin/firefox-kde |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cl.test.simpletest; | |
import java.nio.FloatBuffer; | |
import java.nio.IntBuffer; | |
import java.util.LinkedList; | |
import java.util.List; | |
import org.lwjgl.BufferUtils; | |
import org.lwjgl.LWJGLException; | |
import org.lwjgl.PointerBuffer; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ip2cidr = http://www.linuxweblog.com/blogs/sandip/20080515/ip-range-cidr-conversion | |
echo "">$1.cidr | |
while read -r line | |
do | |
parts=($(echo $line)) | |
start=${parts[0]} | |
end=${parts[1]} | |
echo $start,$end | |
ip2cidr $start-$end >> $1.cidr | |
done < <(cat $1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
80.253.32.0/20 | |
217.172.192.0/19 | |
81.72.0.0/14 | |
82.104.0.0/14 | |
82.88.0.0/14 | |
80.104.0.0/15 | |
37.205.128.0/17 | |
195.120.0.0/16 | |
195.31.0.0/16 | |
195.103.0.0/16 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SECURITY_GROUP='xxxxxx' #EDIT ME | |
REGION='xxxxxx' #EDIT ME | |
RC_FILE='xxxxxx' #EDIT ME | |
CIDR_LISTS=("https://gist.githubusercontent.com/riccardobl/28a616180d8d7ad44473/raw/telecom-italia-ips.txt") | |
DELETE_OLD_RULES=true | |
DELAY_BETWEEN_REQUESTS=2 | |
source "$RC_FILE" | |
export OS_REGION_NAME="$REGION" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Moved to https://github.com/riccardobl/simple-bash-bandwidth-monitor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
ip=$(curl https://wtfismyip.com/text) | |
# For api documentation see https://www.cloudflare.com/docs/client-api.html | |
curl https://www.cloudflare.com/api_json.html \ | |
-d 'a=rec_edit' \ | |
-d 'tkn=XXXXXXXXXXXXXXXXXXXX' \ | |
-d 'email=XXXXXXXXXXXXXXXXXXXX' \ | |
-d 'z=XXXXXXXXXXXXXXXXXXXX' \ | |
-d 'id=XXXXXXXXXXXXXXXXXXXX' \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.jme3.app.SimpleApplication; | |
import com.jme3.input.KeyInput; | |
import com.jme3.input.controls.ActionListener; | |
import com.jme3.input.controls.KeyTrigger; | |
import com.jme3.material.Material; | |
import com.jme3.math.ColorRGBA; | |
import com.jme3.math.Vector2f; | |
import com.jme3.math.Vector3f; | |
import com.jme3.scene.Geometry; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
A script that can be used with ScriptedWallpaper to pick a random image from Wallhaven and set it as background for kde. | |
All the code is released under public domain. |