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
""" | |
Reads in the export file from FBReader and imports your notes / bookmarkes / quotes to evernote. | |
It's done by sending a mail to your evernote-mail which then creates a note in your default notebook. | |
It creates one evernote note per quote. Each titled with the book title. | |
Additionally, it creates an optional summary note, which contains all quotes from the given book. | |
To use, fill out the settings variables below. | |
""" |
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
DATABASE_NAME=$(cat .env | grep DATABASE_NAME | sed -E 's/(.*)=(.*)/\2/' | xargs); |
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 | |
""" | |
This script returns the average number of pages of the books on a given Goodreads shelf. | |
Example Output: | |
> $ python3 goodreads_shelf_average_page_number.py | |
Average page number: 354 | |
Number of books in shelf to-read-next with known page numbers: 19/24 | |
Total number of pages in your shelf: 8496 | |
To read that within one year, you need to read 23 pages a day |
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/sh | |
# This script sets iptables rules vor IPv4 and IPv6. Currently IPv6 just has a drop anything policy. | |
# ToDo: Drop outgoing packages with spoofed source address - add local address as src in output rules. | |
################### | |
# RESET ALL RULES # | |
################### | |
iptables --flush | |
ip6tables --flush |
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
# models.py | |
class Job(models.Model): | |
slug = models.SlugField(max_length=60) | |
@models.permalink | |
def get_absolute_url(self): | |
return 'career:job-detail', (self.pk, self.slug) | |
# urls.py | |
path('<int:id>/<slug:slug>/', JobDetailView.as_view(), name='job') |
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
""" | |
Requires django (mark_safe and escape) | |
Add the following two properties to your model (and update the naming of the email field) | |
In your templates: <a href="{{ person.email_obfuscated_href }}">{{ person.email_obfuscated_name }}</a> | |
Result: <a href="javascript:window.location.href = 'mailto:' + ['max', 'mustermann.com'].join('@')">max<!---->@<!---->mustermann.com</a> | |
Inspired by https://github.com/Blueshoe/djangocms-link2 | |
""" |
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
.correct, | |
.incorrect { | |
background: none !important; | |
} | |
.questioncorrectnessicon { | |
display: none; | |
} | |
.multichoiceset input[type=checkbox] { | |
display: none; | |
} |
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
/* | |
* Overview | |
* https://kunde.comdirect.de/itx/persoenlicherbereich/anzeigen | |
*/ | |
/* Remove IBAN Column */ | |
form#j_idt67-j_idt68-0-j_idt70 table tr th:nth-of-type(3), | |
form#j_idt67-j_idt68-0-j_idt70 table tr td:nth-of-type(3) { | |
display: none !important; | |
} |
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
/* --------------- | |
name: Clean Google Calendar | |
author: @Gambloide | |
matches: https://google.com/calendar/* | |
version: 1.0 | |
------------------ */ | |
/* Calendar */ |
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/env python | |
from __future__ import print_function | |
import os | |
import sys | |
import json | |
import requests | |
GITHUB_API_URL = 'https://api.github.com' | |
TOKEN = 'YOUR_SECRET_TOKEN_HERE' |