git remote -v
git remote rm <remote-name>
#!/bin/bash | |
# https://gist.github.com/hypnoJerk/781d9c33bd64d059bc467ed9e2e54fb2 | |
# | |
# Example usage: | |
# ./generate_iframe.sh https://asciinema.org/a/335480 -r 20 -c 90 -h 480px | |
# You may need to adjust the height, rows, or columns | |
# Extract the Asciicast ID from the URL | |
url=$1 |
@-moz-document domain("npmjs.com") { | |
html,body,main { | |
background-color: black !important; | |
color: white !important; | |
} | |
header, | |
header>div, | |
bg-white | |
{ | |
background-color: black !important; |
@-moz-document domain("nextjs.org") { | |
html, | |
header, | |
body { | |
background-color: black !important; | |
color: #ccc !important; | |
} | |
.react-autosuggest__suggestion mark { | |
background: #480043; |
// Hackmud Token API | |
// | |
// Authors: | |
// nlight (aka facebook.com) | |
// | |
// -- Motivation -- | |
// | |
// The token API allows for the existence of unhackable* user issued in-game currencies running on a network of FULLSEC scripts. | |
// Each implementation (instance) of the API represents a supply of tokens (currency) the ownership of which can be transferred | |
// securely between users. The user who hosts the token script (the issuer) is in full control of the supply and can issue new |
#First take note of which drive, and replace sdb with your volume name. | |
#Create Backup | |
sudo dd bs=4M if=/dev/sdb | gzip > /home/your_username/image'date +%d%m%y'.gz | |
#Restore backup | |
sudo gzip -dc /home/your_username/image.gz | dd bs=4M of=/dev/sdb |
#!/bin/bash | |
#Parse apache2 access.log | |
#And count how many times an IP appears and sorts them | |
cat /var/log/apache2/access.log | awk '{print $1}' | sort | uniq -c | sort -n | tail |
#!/usr/bin/env python | |
import sys, time | |
from twython import Twython | |
CONSUMER_KEY = 'xxxxx' | |
CONSUMER_SECRET = 'xxxxx' | |
ACCESS_KEY = 'xxxx-xxxx' | |
ACCESS_SECRET = 'xxxx' | |
print('Starting') |
import os | |
def erase_file(): | |
with open('/home/user/external_ip_output.txt', 'w'): | |
pass | |
def get_ip(): | |
stream = os.popen('curl ifconfig.me --max-time 7 -o /home/user/external_ip_output.txt') | |
return stream | |
def open_file(): | |
f = open('/home/user/external_ip_output.txt', 'r') | |
text = f.read() |
This script simply takes a twitter user name, and fetches the latest tweets from their timeline. Then reposts those tweets to a telegram bot(or channel via a bot)
####Requirements: You need Twython installed. Twython is a twitter-python API
####Notes: