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 | |
RADARR_API_URL="http://radarr.com/api" | |
RADARR_API_KEY="PUT_YOUR_API_KEY_HERE" | |
history=$(curl -s ${RADARR_API_URL}/history?page=1\&pageSize=20\&sortKey=date\&sortDir=desc -H "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7" -X GET -H 'X-Api-Key: '$RADARR_API_KEY'' -k) | |
history=$(echo $history | tr -d '\n' | tr -d '\r' | tr -d '\b') | |
grabbed=$(echo $history | jq '.records | .[] | select(.movie.monitored) | select(.movie.downloaded | not) | select(.eventType=="grabbed") | .movieId') | |
grabbed=$(echo $grabbed | sed 's/ /, /g') | |
grabbed="[${grabbed}]" |
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 | |
SLACK_URL=$1 | |
RADARR_API_URL="$2/api" | |
RADARR_API_KEY=$3 | |
post_to_slack() { | |
curl --silent -X POST --data "payload={\"text\": \"${1}\", \"unfurl_links\": true, \"mrkdwn\": true}" ${SLACK_URL} | |
} | |
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 | |
HOOK_IFTTT_MAKER_KEY="" | |
HOOK_PLEX_USERNAME="" | |
HOOK_PLEX_PLAYER="" | |
HOOK_PLEX_NIGHT_HOUR_MIN=19 | |
HOOK_PLEX_NIGHT_HOUR_MAX=6 | |
HOOK_PLEX_PLAY="Play" | |
HOOK_PLEX_STOP="Stop" |
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
;End GCode | |
;Ultimaker 2+ octoprint | |
M104 S0 ;extruder heater off | |
M140 S0 ;heated bed heater off (if you have it) | |
G91 ;relative positioning | |
G1 E-1 F300 ;retract the filament a bit before lifting the nozzle, to release some of the pressure | |
G1 Z+0.5 E-5 X-20 Y-20 F4200 ;move Z up a bit and retract filament even more | |
G28 X0 Y0 ;move X/Y to min endstops, so the head is out of the way | |
M84 ;steppers off | |
G90 ;absolute positioning |
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
;Generated with Cura_SteamEngine 15.04 | |
;Ultimaker 2+ octoprint | |
M140 S60.0 | |
M109 T0 S210.0 | |
T0 | |
M190 S60.0 | |
;Sliced at: Thu 15-12-2016 09:28:45 | |
;Basic settings: Layer height: 0.1 Walls: 1.2 Fill: 80 | |
;Print time: ?print_time? | |
;Filament used: ?filament_amount?m ?filament_weight?g |