Comment

Comment by geoka9

I use the following script (activated by a system-level shortcut key) to take a screenshot, upload to S3 bucket (using the minio client[0]) and place the URL in the X selection buffer, ready to be pasted:

  #!/bin/bash
  set -e
  dbus-update-activation-environment DISPLAY XAUTHORITY
  FNAME=`cat /dev/urandom | tr -cd 'a-f0-9' | head -c 32`.png
  flameshot gui --raw > /tmp/$FNAME
  ~/go/bin/mc -q cp --attr x-amz-acl=public-read /tmp/$FNAME s3/your.s3.bucket/dir/$FNAME
  echo -n https://s3-us-west-2.amazonaws.com/your.s3.bucket/dir/$FNAME | xsel
[0] https://min.io/docs/minio/linux/reference/minio-mc.html
parent geoka9 2 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton