Skip to content

Instantly share code, notes, and snippets.

@Rene-Roscher
Last active October 19, 2024 07:33
Show Gist options
  • Select an option

  • Save Rene-Roscher/6474402102c04afc932504cb0d157261 to your computer and use it in GitHub Desktop.

Select an option

Save Rene-Roscher/6474402102c04afc932504cb0d157261 to your computer and use it in GitHub Desktop.
Flameshot custom uploader*

Download File and move it to /usr/local/bin/screen-capture

➜ ~ cat ~/.config/flameshot/flameshot.ini

[General]
autoCloseIdleDaemon=true
buttons=@Variant(\0\0\0\x7f\0\0\0\vQList<int>\0\0\0\0\b\0\0\0\0\0\0\0\x3\0\0\0\x4\0\0\0\x5\0\0\0\x12\0\0\0\b\0\0\0\v\0\0\0\r)
checkForUpdates=true
contrastOpacity=188
copyAndCloseAfterUpload=false
copyPathAfterSave=true
drawColor=#4f4f4f
savePathFixed=true
showDesktopNotification=false
showHelp=false
showStartupLaunchMessage=false
startupLaunch=false
uploadHistoryMax=25
uploadWithoutConfirmation=true
#!/bin/bash
flameshot gui
CLIPBOARD=$(xclip -o -selection clipboard)
if [ -f "$CLIPBOARD" ]; then
LOCAL_FILE="$CLIPBOARD"
REMOTE_DIR="/var/www/scrn.her.de/scrn"
SERVER="root@10.254.5.2"
URL_PREFIX="https://scrn.her.de/"
rsync -avz "$LOCAL_FILE" "$SERVER:$REMOTE_DIR"
FILE_NAME=$(basename "$LOCAL_FILE")
URL="$URL_PREFIX$FILE_NAME"
echo "$URL" | xclip -selection clipboard
notify-send "Success" "File Uploaded: $URL"
else
notify-send "Error!" "No File to upload..."
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment