summaryrefslogtreecommitdiff
path: root/xcopy
blob: 1511d51eb95c0f95d3f94b232aad2903aa7b5447 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh -e
#
# Copyright (C) 2023 dwlr <dweller@cabin.digital>
#
# BSD 3-Clause License (BSD-3-Clause)
# See LICENSE for details


{
    echo "" # TODO: why does it need a \n before the list?
    for i in "$@"; do
        echo "file://$(realpath "$i")"
    done

} | xclip -sel clipboard -i -r -t text/uri-list