Skip to content

Instantly share code, notes, and snippets.

Avatar
👨‍💻
Working from Home

Markus Ritzmann mritzmann

👨‍💻
Working from Home
View GitHub Profile
@mritzmann
mritzmann / attempt01.shell
Created Jul 10, 2019
download.nextcloud.com
View attempt01.shell
$ php ~/www/occ app:update --all \
&& php ~/www/updater/updater.phar --no-interaction \
&& ~/www/occ upgrade \
&& php ~/www/occ app:update --all
Nextcloud Updater - version: v16.0.0beta3-4-gc7a4074
Current version is 16.0.2.
Update to Nextcloud 16.0.3 available. (channel: "stable")
Following file will be downloaded automatically: https://download.nextcloud.com/server/releases/nextcloud-16.0.3.zip
@mritzmann
mritzmann / ys.zsh-theme
Created Oct 24, 2018
ys.zsh-theme edited for oh-my-zsh diskusage plugin
View ys.zsh-theme
# Clean, simple, compatible and meaningful.
# Tested on Linux, Unix and Windows under ANSI colors.
# It is recommended to use with a dark background.
# Colors: black, red, green, yellow, *blue, magenta, cyan, and white.
#
# Mar 2013 Yad Smood
#
# // Edited for oh-my-zsh diskusage plugin
# VCS
@mritzmann
mritzmann / php-crud-api-393.patch
Created Aug 5, 2018
mevdschee/php-crud-api: Issue #393: dot in id
View php-crud-api-393.patch
diff --git a/api.php b/api.php
index ee0769c..080f432 100644
--- a/api.php
+++ b/api.php
@@ -1887,7 +1887,7 @@ class PHP_CRUD_API {
extract($settings);
$table = $this->parseRequestParameter($request, 'a-zA-Z0-9\-_');
- $key = $this->parseRequestParameter($request, 'a-zA-Z0-9\-_,'); // auto-increment or uuid
+ $key = $this->parseRequestParameter($request, 'a-zA-Z0-9\-,\.'); // auto-increment or uuid
@mritzmann
mritzmann / after_update.sh
Created Jul 13, 2018
LG G6 with LineageOS: Boot Fix
View after_update.sh
#!/bin/sh
/sbin/dd if=/dev/zero of=/dev/block/bootdevice/by-name/misc bs=256 count=1 conv=notrunc
# After every OS Update, my LG G6 with LineageOS didn't boot.
# So i run this script with the Terminal inside "TWRP Recovery" to fix this Problem.
# sh /sdcard/scripts/after_update.sh
View sample.ics

Would it be possible to include an iCal file attachment to the Access-A-Ride advance notification emails with a 30 minute window from the specified pickup time (that is the window in which Access-A-Ride drivers need to arrive)?

For example: if my Access-A-Ride is supposed to pick me up at 10:34 am from 1000 Broadway Ave and then again at 8:00 pm from 900 Jay St., include a calendar event (a .ics file) that would look similar to the following, attached to the advance trip notification:

BEGIN:VCALENDAR
VERSION:2.0
CALSCALE:GREGORIAN
BEGIN:VEVENT
SUMMARY:Access-A-Ride Pickup
@mritzmann
mritzmann / remove_db_entry.php
Created Nov 4, 2017
remove netcup db entries
View remove_db_entry.php
# more information:
# https://github.com/dnszensur/dnszensur-web/issues/47
<?php
include '.env';
$db = mysqli_connect("$db_host", "$db_user", "$db_password", "$db_name");
$result = mysqli_query($db, "SELECT domain, autonomous_system FROM domains WHERE autonomous_system LIKE 'AS197540 netcup GmbH'");
while($row = mysqli_fetch_object($result))
View export_env.sh
export $(cat .env | xargs)
View gist:bfb7298fd14427c282b8a702547c74d5
DEBUG - os.symlink(/home/ocr/scan0_161129-144058.pdf, /tmp/com.github.ocrmypdf.1eo3vclv/origin)
DEBUG - os.symlink(/tmp/com.github.ocrmypdf.1eo3vclv/origin, /tmp/com.github.ocrmypdf.1eo3vclv/origin.pdf)
DEBUG - [{'width_inches': Decimal('8.05'), 'images': [{'enc': 'jpeg', 'type': 'image', 'comp': 3, 'name': '/Im0', 'width': 2416, 'height': 3461, 'dpi_h': Decimal('300.1734605377276920989970676600933074951171875'), 'dpi_w': Decimal('300.1242236024844487474183551967144012451171875'), 'color': 'rgb', 'dpi': Decimal('300.149'), 'bpc': 8}], 'height_pixels': 3461, 'xres': Decimal('300.1242236024844487474183551967144012451171875'), 'height_inches': Decimal('11.53'), 'has_text': False, 'yres': Decimal('300.1734605377276920989970676600933074951171875'), 'width_pixels': 2416, 'pageno': 0}, {'width_inches': Decimal('8.13'), 'images': [{'enc': 'jpeg', 'type': 'image', 'comp': 3, 'name': '/Im1', 'width': 2440, 'height': 3465, 'dpi_h': Decimal('300'), 'dpi_w': Decimal('300.123001230012278028880245983600616455078125'),
@mritzmann
mritzmann / count.php
Created Sep 15, 2016
time count with php
View count.php
<?php
// ermittelt datum und uhrzeit
$datumundzeit = date("d.m.Y H:i\n");
// gibt datum und uhrzeit aus
echo $datumundzeit;
// schreibt datum und uhrzeit in eine datei
file_put_contents(statistik, $datumundzeit, FILE_APPEND);
?>
View gist:b315f349a3d28fda7cc3482540ae3038
18.07.16 20:16:44 IPv6-Präfix wurde erfolgreich bezogen. Neues Präfix: 2001:1620:c7d::/48
18.07.16 20:16:43 Internetverbindung IPv6 wurde erfolgreich hergestellt. IP-Adresse: 2001:1620:4:9d7d:2665:11ff:feef:c67
18.07.16 20:16:43 Internetverbindung wurde erfolgreich hergestellt. IP-Adresse: 213.144.157.125, DNS-Server: 77.109.128.3 und 213.144.129.21, Gateway: 213.144.128.206, Breitband-PoP: ipd-zhb790-r-bn-25
18.07.16 20:16:32 PPPoE-Fehler: Zeitüberschreitung.
18.07.16 20:16:25 DSL ist verfügbar (DSL-Synchronisierung besteht mit 55040/16488 kbit/s).
18.07.16 20:15:03 Zeitüberschreitung bei der PPP-Aushandlung.
18.07.16 20:15:02 Internetverbindung IPv6 wurde getrennt, Präfix nicht mehr gültig.
18.07.16 20:15:02 Internetverbindung wurde getrennt.
18.07.16 20:14:58 DSL antwortet nicht (Keine DSL-Synchronisierung).
18.07.16 20:12:26 IPv6-Präfix wurde erfolgreich bezogen. Neues Präfix: 2001:1620:c7d::/48
You can’t perform that action at this time.