This file contains 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 | |
PROCESS=`ps -eaf | grep xmrig | grep -v grep` | |
if [ "$PROCESS" == '' ] | |
then | |
/home/monero/xmrig -B | |
else | |
echo "xmrig running" | |
fi |
This file contains 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 | |
LOCATION="Hampshire" | |
CONDITION=`curl -s wttr.in/$LOCATION?format=%C` | |
SUNSET=`curl -s wttr.in/$LOCATION?format=%s` | |
SUNRISE=`curl -s wttr.in/$LOCATION?format=%S` | |
TIME=`date "+%H:%M:%S"` | |
sunset_time=$(date -d $SUNSET +%s) |
This file contains 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
#!/usr/bin/python3 | |
import discord | |
token = ("") | |
class ExportFriends(discord.Client): | |
async def on_connect(self): | |
friendslist = client.user.friends | |
for user in friendslist: | |
try: | |
print(user.name+"#"+user.discriminator + " ("+str(user.id)+")") |
This file contains 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 fish_greeting | |
echo "" | |
neofetch | |
end | |
set LC_ALL en_GB.UTF-8 | |
set LANG en_GB.UTF-8 | |
set LANGUAGE en_GB.UTF-8 | |
alias psg="ps aux | grep" |
This file contains 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
[Unit] | |
Description=pydirlist | |
After=network.target | |
[Service] | |
User=myuser | |
WorkingDirectory=/path/to/pydirlist | |
ExecStart=bash /path/to/pydirlist/run.sh | |
Restart=always |
This file contains 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
#!/sbin/openrc-run | |
depend() { | |
need net | |
} | |
srv="/path/to/pydirlist/" | |
command="/bin/sh /path/to/pydirlist/run.sh" | |
command_args="" | |
command_user="myuser:mygroup" |
This file contains 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 | |
# Commands to renew certificates for angristan's openvpn-install | |
# https://github.com/angristan/openvpn-install | |
# CREDIT: https://github.com/angristan/openvpn-install/issues/1002#issuecomment-1229525488 | |
# https://github.com/kg6uyz | |
NAME=$(cat /etc/openvpn/easy-rsa/SERVER_NAME_GENERATED) |
This file contains 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
vm.swappiness = 1 | |
vm.dirty_background_ratio = 3 | |
vm.dirty_ratio = 40 | |
vm.dirty_background_bytes = 4194304 | |
vm.dirty_bytes = 4194304 | |
vm.vfs_cache_pressure = 50 | |
net.core.netdev_max_backlog = 16384 | |
net.core.somaxconn = 8192 | |
net.core.rmem_default = 1048576 | |
net.core.rmem_max = 16777216 |
This file contains 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
vm.vfs_cache_pressure = 500 | |
vm.swappiness = 90 | |
vm.dirty_background_ratio = 1 | |
vm.dirty_ratio = 50 | |
vm.dirty_background_bytes = 4194304 | |
vm.dirty_bytes = 4194304 | |
net.core.netdev_max_backlog = 16384 | |
net.core.somaxconn = 8192 | |
net.core.rmem_default = 1048576 | |
net.core.rmem_max = 16777216 |
This file contains 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 json, humanize, os, html | |
from datetime import datetime, timedelta | |
file = '/home/keira/Repositories/Public/github.html' | |
github_json_file = '/home/keira/Resources/github.json' | |
# cron every 30 minutes: | |
# */30 * * * * /usr/bin/gh repo list researcx -L 400 --visibility public --json name,owner,pushedAt,isFork,diskUsage,description > /home/keira/Resources/github.json | |
# */31 * * * * /usr/bin/python3 /home/keira/Scripts/githubrepos.py |