Giter VIP home page Giter VIP logo

slackadays / clipboard Goto Github PK

View Code? Open in Web Editor NEW
4.3K 25.0 122.0 69.71 MB

😎🏖️🐬 Your new, 𝙧𝙞𝙙𝙤𝙣𝙠𝙪𝙡𝙞𝙘𝙞𝙤𝙪𝙨𝙡𝙮 smart clipboard manager

Home Page: https://getclipboard.app/

License: GNU General Public License v3.0

CMake 0.19% C++ 99.34% Shell 0.41% PowerShell 0.02% Objective-C 0.04%
linux clipboard macos cross-platform cmd cli terminal windows cpp shell

clipboard's People

Contributors

andrejp88 avatar antiz96 avatar blquinn avatar davipb avatar derspyy avatar filiprojek avatar miguelguthridge avatar myd7349 avatar nekopsykose avatar nothingbutlucas avatar pixelomer avatar quincyf467 avatar raspbeguy avatar sagesphinx63920 avatar skeeto avatar slackadays avatar tranzystorekk avatar zaryob avatar zeczen avatar zoenglinghou avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

clipboard's Issues

Build fails on MacBook Air M1

System Information:

MacBook Air M1, 2020
Chip: Apple M1
Memory: 16 GB
macOS: 13.1 (22C65)

Getting errors during 'build'. Please see the logs below:

/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:50:6: error: no type named 'jthread' in namespace 'std'; did you mean 'thread'?
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:189:19: error: no member named 'request_stop' in 'std::thread'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:437:26: error: no type named 'stop_token' in namespace 'std'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:513:23: error: no member named 'request_stop' in 'std::thread'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:647:35: error: no member named 'request_stop' in 'std::thread'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:649:42: error: no member named 'jthread' in namespace 'std'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:794:26: error: no member named 'jthread' in namespace 'std'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:806:19: error: no member named 'request_stop' in 'std::thread'
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:819:19: error: no member named 'request_stop' in 'std::thread'
In file included from /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:3:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:447:62)>' requested here
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:447:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:447:62)>' requested here
In file included from /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:3:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:453:62)>' requested here
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:453:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:453:62)>' requested here
In file included from /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:3:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:469:62)>' requested here
/Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:469:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/UZER01/tools/cb/Clipboard/src/clipboard.cpp:469:62)>' requested here

Option to mute the help text when running `cb` with no params

Is your feature request related to a problem? Please describe.
It'd be nice if there was an environment variable that allows muting the help text after running cb with no options.

cb
• There are items in these clipboards:
▏ 0: foo
▏ 1: foo2
Add cut, copy, or paste to the end, like clipboard copy to get started, or if you need help, try clipboard -h to show the help screen.

It just feels very noisy to look at the cb real quick.

Describe the solution you'd like
CLIPBOARD_SILENCE_HELP environment variable

core dump when executing `clipboard show`

Describe the bug
I build rpm package from latest git repo and install on Fedora.

[ruby@fedora my-build]$ gcc --version
gcc (GCC) 12.2.1 20221121 (Red Hat 12.2.1-4)
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[ruby@fedora my-build]$ clipboard --help
▏This is Clipboard 0.2.1r2, the cut, copy, and paste system for the command line.
▏How To Use
▏clipboard cut (item) [items] (This cuts an item or items.)
▏clipboard copy (item) [items] (This copies an item or items.)
▏clipboard paste (This pastes a clipboard.)
▏clipboard show (This shows what's in a clipboard.)
▏clipboard clear (This clears a clipboard's contents.)
▏You can substitute "cb" for "clipboard" and use various shorthands for the actions to save time.
▏You can also choose which clipboard you want to use by adding a number to the end, or _ to use a persistent clipboard.
▏Examples
▏cb ct Nuclear_Launch_Codes.txt contactsfolder (This cuts the following items into the default clipboard, 0.)
▏clipboard cp1 dogfood.conf (This copies the following items into clipboard 1.)
▏cb p1 (This pastes clipboard 1.)
▏cb sh4 (This shows the contents of clipboard 4.)
▏cb clr (This clears the contents of the default clipboard.)
▏Configuration
▏CI: Set to make Clipboard overwrite existing items without a user prompt when pasting.
▏FORCE_COLOR: Set to make Clipboard always show color regardless of what you set NO_COLOR to.
▏TMPDIR: Set to the directory that Clipboard (and other programs) will use to hold the items you cut or copy into temporary clipboards.
▏CLIPBOARD_TMPDIR: Set to the directory that only Clipboard will use to hold the items you cut or copy into temporary clipboards.
▏CLIPBOARD_PERSISTDIR: Set to the directory that only Clipboard will use to hold the items you cut or copy into persistent clipboards.
▏CLIPBOARD_ALWAYS_PERSIST: Set to make Clipboard always use persistent clipboards.
▏CLIPBOARD_NOGUI: Set to disable GUI clipboard integration.
▏NO_COLOR: Set to make Clipboard not show color.
▏You can show this help screen anytime with clipboard -h, clipboard --help, or clipboard help.
▏You can also get more help in our Discord server at https://discord.gg/J6asnc3pEG
▏Copyright (C) 2022 Jackson Huff. Licensed under the GPLv3.
▏This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.

[ruby@fedora my-build]$ echo "aa" > clipboard

[ruby@fedora my-build]$ clipboard show
/usr/include/c++/12/span:278: constexpr std::span<_Type, _Extent>::element_type& std::span<_Type, _Extent>::operator[](size_type) const [with _Type = unsigned char; long unsigned int _Extent = 18446744073709551615; reference = unsigned char&; size_type = long unsigned int]: Assertion '__idx < size()' failed.
Aborted (core dumped)

update, the process of building rpm package:

[ruby@fedora SPECS]$ rpmbuild -bb clipboard.spec 
warning: source_date_epoch_from_changelog set but %changelog is missing
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.8DWwbk
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ git clone --depth=1 https://github.com/Slackadays/Clipboard .
Cloning into '.'...
remote: Enumerating objects: 80, done.
remote: Counting objects: 100% (80/80), done.
remote: Compressing objects: 100% (74/74), done.
remote: Total 80 (delta 10), reused 42 (delta 1), pack-reused 0
Receiving objects: 100% (80/80), 2.07 MiB | 773.00 KiB/s, done.
Resolving deltas: 100% (10/10), done.
+ RPM_EC=0
++ jobs -p
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.QI7TSZ
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CFLAGS
+ CXXFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CXXFLAGS
+ FFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FFLAGS
+ FCFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FCFLAGS
+ VALAFLAGS=-g
+ export VALAFLAGS
+ LDFLAGS='-Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes'
+ export LDFLAGS
+ LT_SYS_LIBRARY_PATH=/usr/lib64:
+ export LT_SYS_LIBRARY_PATH
+ CC=gcc
+ export CC
+ CXX=g++
+ export CXX
+ CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CFLAGS
+ CXXFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CXXFLAGS
+ FFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FFLAGS
+ FCFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FCFLAGS
+ VALAFLAGS=-g
+ export VALAFLAGS
+ LDFLAGS='-Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes'
+ export LDFLAGS
+ LT_SYS_LIBRARY_PATH=/usr/lib64:
+ export LT_SYS_LIBRARY_PATH
+ CC=gcc
+ export CC
+ CXX=g++
+ export CXX
+ /usr/bin/cmake -S . -B redhat-linux-build -DCMAKE_C_FLAGS_RELEASE:STRING=-DNDEBUG -DCMAKE_CXX_FLAGS_RELEASE:STRING=-DNDEBUG -DCMAKE_Fortran_FLAGS_RELEASE:STRING=-DNDEBUG -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -DCMAKE_INSTALL_DO_STRIP:BOOL=OFF -DCMAKE_INSTALL_PREFIX:PATH=/usr -DINCLUDE_INSTALL_DIR:PATH=/usr/include -DLIB_INSTALL_DIR:PATH=/usr/lib64 -DSYSCONF_INSTALL_DIR:PATH=/etc -DSHARE_INSTALL_PREFIX:PATH=/usr/share -DLIB_SUFFIX=64 -DBUILD_SHARED_LIBS:BOOL=ON -DCMAKE_BUILD_TYPE=Release
-- The CXX compiler identification is GNU 12.2.1
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/lib64/ccache/g++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found X11: /usr/include   
-- Looking for XOpenDisplay in /usr/lib64/libX11.so;/usr/lib64/libXext.so
-- Looking for XOpenDisplay in /usr/lib64/libX11.so;/usr/lib64/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Building Clipboard with X11 support
-- Found PkgConfig: /usr/bin/pkg-config (found version "1.8.0") 
-- Checking for module 'wayland-client'
--   Found wayland-client, version 1.21.0
-- Building Clipboard with Wayland support
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE  
-- Performing Test COMPILER_SUPPORTS_MARCH_NATIVE
-- Performing Test COMPILER_SUPPORTS_MARCH_NATIVE - Success
-- Configuring done
-- Generating done
CMake Warning:
  Manually-specified variables were not used by the project:

    CMAKE_C_FLAGS_RELEASE
    CMAKE_Fortran_FLAGS_RELEASE
    CMAKE_INSTALL_DO_STRIP
    INCLUDE_INSTALL_DIR
    LIB_INSTALL_DIR
    LIB_SUFFIX
    SHARE_INSTALL_PREFIX
    SYSCONF_INSTALL_DIR


-- Build files have been written to: /home/ruby/rpmbuild/BUILD/redhat-linux-build
+ /usr/bin/cmake --build redhat-linux-build -j6 --verbose
/usr/bin/cmake -S/home/ruby/rpmbuild/BUILD -B/home/ruby/rpmbuild/BUILD/redhat-linux-build --check-build-system CMakeFiles/Makefile.cmake 0
/usr/bin/cmake -E cmake_progress_start /home/ruby/rpmbuild/BUILD/redhat-linux-build/CMakeFiles /home/ruby/rpmbuild/BUILD/redhat-linux-build//CMakeFiles/progress.marks
/usr/bin/gmake  -f CMakeFiles/Makefile2 all
gmake[1]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
/usr/bin/gmake  -f src/clipboardx11/CMakeFiles/clipboardx11.dir/build.make src/clipboardx11/CMakeFiles/clipboardx11.dir/depend
/usr/bin/gmake  -f src/clipboardwayland/CMakeFiles/clipboardwayland.dir/build.make src/clipboardwayland/CMakeFiles/clipboardwayland.dir/depend
/usr/bin/gmake  -f src/clipboard/CMakeFiles/clipboard.dir/build.make src/clipboard/CMakeFiles/clipboard.dir/depend
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /home/ruby/rpmbuild/BUILD /home/ruby/rpmbuild/BUILD/src/clipboardx11 /home/ruby/rpmbuild/BUILD/redhat-linux-build /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardx11 /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardx11/CMakeFiles/clipboardx11.dir/DependInfo.cmake --color=
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /home/ruby/rpmbuild/BUILD /home/ruby/rpmbuild/BUILD/src/clipboardwayland /home/ruby/rpmbuild/BUILD/redhat-linux-build /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardwayland /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardwayland/CMakeFiles/clipboardwayland.dir/DependInfo.cmake --color=
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /home/ruby/rpmbuild/BUILD /home/ruby/rpmbuild/BUILD/src/clipboard /home/ruby/rpmbuild/BUILD/redhat-linux-build /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard/CMakeFiles/clipboard.dir/DependInfo.cmake --color=
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
/usr/bin/gmake  -f src/clipboardx11/CMakeFiles/clipboardx11.dir/build.make src/clipboardx11/CMakeFiles/clipboardx11.dir/build
/usr/bin/gmake  -f src/clipboardwayland/CMakeFiles/clipboardwayland.dir/build.make src/clipboardwayland/CMakeFiles/clipboardwayland.dir/build
/usr/bin/gmake  -f src/clipboard/CMakeFiles/clipboard.dir/build.make src/clipboard/CMakeFiles/clipboard.dir/build
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
gmake[2]: Entering directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
[ 37%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/clipboard.cpp.o
[ 37%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o
[ 37%] Building CXX object src/clipboardx11/CMakeFiles/clipboardx11.dir/src/x11.cpp.o
[ 50%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/messages.cpp.o
[ 62%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/posix.cpp.o
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard && /usr/lib64/ccache/g++  -I/home/ruby/rpmbuild/BUILD/src/gui/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -std=gnu++20 -MD -MT src/clipboard/CMakeFiles/clipboard.dir/src/clipboard.cpp.o -MF CMakeFiles/clipboard.dir/src/clipboard.cpp.o.d -o CMakeFiles/clipboard.dir/src/clipboard.cpp.o -c /home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardwayland && /usr/lib64/ccache/g++ -Dclipboardwayland_EXPORTS -I/home/ruby/rpmbuild/BUILD/src/gui/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -fPIC -std=gnu++20 -MD -MT src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o -MF CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o.d -o CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o -c /home/ruby/rpmbuild/BUILD/src/clipboardwayland/src/wayland.cpp
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardx11 && /usr/lib64/ccache/g++ -Dclipboardx11_EXPORTS -I/home/ruby/rpmbuild/BUILD/src/gui/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -fPIC -std=gnu++20 -MD -MT src/clipboardx11/CMakeFiles/clipboardx11.dir/src/x11.cpp.o -MF CMakeFiles/clipboardx11.dir/src/x11.cpp.o.d -o CMakeFiles/clipboardx11.dir/src/x11.cpp.o -c /home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard && /usr/lib64/ccache/g++  -I/home/ruby/rpmbuild/BUILD/src/gui/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -std=gnu++20 -MD -MT src/clipboard/CMakeFiles/clipboard.dir/src/messages.cpp.o -MF CMakeFiles/clipboard.dir/src/messages.cpp.o.d -o CMakeFiles/clipboard.dir/src/messages.cpp.o -c /home/ruby/rpmbuild/BUILD/src/clipboard/src/messages.cpp
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard && /usr/lib64/ccache/g++  -I/home/ruby/rpmbuild/BUILD/src/gui/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -std=gnu++20 -MD -MT src/clipboard/CMakeFiles/clipboard.dir/src/posix.cpp.o -MF CMakeFiles/clipboard.dir/src/posix.cpp.o.d -o CMakeFiles/clipboard.dir/src/posix.cpp.o -c /home/ruby/rpmbuild/BUILD/src/clipboard/src/posix.cpp
/home/ruby/rpmbuild/BUILD/src/clipboardwayland/src/wayland.cpp: warning: -D_FORTIFY_SOURCE defined but value is too low
[ 75%] Linking CXX shared module ../../libclipboardwayland.so
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardwayland && /usr/bin/cmake -E cmake_link_script CMakeFiles/clipboardwayland.dir/link.txt --verbose=1
/usr/lib64/ccache/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes -shared  -o ../../libclipboardwayland.so CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o  -lwayland-client 
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
[ 75%] Built target clipboardwayland
/home/ruby/rpmbuild/BUILD/src/clipboard/src/messages.cpp: warning: -D_FORTIFY_SOURCE defined but value is too low
/home/ruby/rpmbuild/BUILD/src/clipboard/src/posix.cpp: warning: -D_FORTIFY_SOURCE defined but value is too low
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: warning: -D_FORTIFY_SOURCE defined but value is too low
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: In function 'void PerformAction::show()':
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:267:30: warning: unused variable 'entry' [-Wunused-variable]
  267 |             for (const auto& entry : fs::directory_iterator(filepath.main)) {
      |                              ^~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:273:31: warning: comparison of integer expressions of different signedness: 'int' and 'const unsigned int' [-Wsign-compare]
  273 |             for (int i = 0; i < std::min(rowsAvailable, total_items); i++) {
      |                             ~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:277:23: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
  277 |                 if (i == rowsAvailable - 1 && total_items > rowsAvailable) {
      |                     ~~^~~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: In function 'std::string replaceColors(const std::string_view&)':
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:297:55: warning: comparison of integer expressions of different signedness: 'int' and 'const std::__cxx11::basic_string<char>::size_type' {aka 'const long unsigned int'} [-Wsign-compare]
  297 |         for (int i = 0; (i = temp.find(key.first, i)) != std::string::npos; i += key.second.length()) {
      |                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: In function 'void showClipboardStatus()':
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:541:45: warning: comparison of integer expressions of different signedness: 'std::vector<std::pair<std::filesystem::__cxx11::path, bool> >::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
  541 |         if (clipboards_with_contents.size() > termSizeAvailable.second) {
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:574:45: warning: comparison of integer expressions of different signedness: 'std::vector<std::pair<std::filesystem::__cxx11::path, bool> >::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
  574 |         if (clipboards_with_contents.size() > termSizeAvailable.second) {
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: In function 'void setupIndicator()':
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:698:30: warning: unused variable 'f' [-Wunused-variable]
  698 |             for (const auto& f : fs::directory_iterator(filepath.main)) {
      |                              ^
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp: In function 'void showSuccesses()':
/home/ruby/rpmbuild/BUILD/src/clipboard/src/clipboard.cpp:870:63: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
  870 |     if (action == Action::PipeIn || action == Action::PipeOut && is_tty.std_err) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
[ 87%] Linking CXX executable ../../clipboard
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboard && /usr/bin/cmake -E cmake_link_script CMakeFiles/clipboard.dir/link.txt --verbose=1
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp: warning: -D_FORTIFY_SOURCE defined but value is too low
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp: In member function 'std::vector<char> X11Window::getClipboardData(const X11Atom&)':
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:1135:25: warning: moving a local object in a return statement prevents copy elision [-Wpessimizing-move]
 1135 |         return std::move(result);
      |                ~~~~~~~~~^~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:1135:25: note: remove 'std::move' call
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp: In constructor 'X11SelectionRequest::X11SelectionRequest(X11Connection&, XSelectionRequestEvent)':
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:398:20: warning: 'X11SelectionRequest::m_property' will be initialized after [-Wreorder]
  398 |     X11Atom const& m_property;
      |                    ^~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:397:20: warning:   'const X11Atom& X11SelectionRequest::m_target' [-Wreorder]
  397 |     X11Atom const& m_target;
      |                    ^~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:1247:1: warning:   when initialized here [-Wreorder]
 1247 | X11SelectionRequest::X11SelectionRequest(
      | ^~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:397:20: warning: 'X11SelectionRequest::m_target' will be initialized after [-Wreorder]
  397 |     X11Atom const& m_target;
      |                    ^~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:395:28: warning:   'XSelectionRequestEvent X11SelectionRequest::m_event' [-Wreorder]
  395 |     XSelectionRequestEvent m_event;
      |                            ^~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:1247:1: warning:   when initialized here [-Wreorder]
 1247 | X11SelectionRequest::X11SelectionRequest(
      | ^~~~~~~~~~~~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp: In constructor 'X11SelectionDaemon::X11SelectionDaemon(X11Connection&, const X11Atom&, const ClipboardContent&)':
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:452:15: warning: 'X11SelectionDaemon::m_window' will be initialized after [-Wreorder]
  452 |     X11Window m_window;
      |               ^~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:450:29: warning:   'const ClipboardContent& X11SelectionDaemon::m_content' [-Wreorder]
  450 |     ClipboardContent const& m_content;
      |                             ^~~~~~~~~
/home/ruby/rpmbuild/BUILD/src/clipboardx11/src/x11.cpp:1309:1: warning:   when initialized here [-Wreorder]
 1309 | X11SelectionDaemon::X11SelectionDaemon(
      | ^~~~~~~~~~~~~~~~~~
/usr/lib64/ccache/g++ -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes -z origin CMakeFiles/clipboard.dir/src/clipboard.cpp.o CMakeFiles/clipboard.dir/src/messages.cpp.o CMakeFiles/clipboard.dir/src/posix.cpp.o -o ../../clipboard  -Wl,-rpath,"\$ORIGIN:" -ldl 
[100%] Linking CXX shared module ../../libclipboardx11.so
cd /home/ruby/rpmbuild/BUILD/redhat-linux-build/src/clipboardx11 && /usr/bin/cmake -E cmake_link_script CMakeFiles/clipboardx11.dir/link.txt --verbose=1
/usr/lib64/ccache/g++ -fPIC -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -DNDEBUG -s -flto=auto -fno-fat-lto-objects -flto=auto -Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes -shared  -o ../../libclipboardx11.so CMakeFiles/clipboardx11.dir/src/x11.cpp.o  /usr/lib64/libX11.so /usr/lib64/libXext.so 
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
[100%] Built target clipboardx11
gmake[2]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
[100%] Built target clipboard
gmake[1]: Leaving directory '/home/ruby/rpmbuild/BUILD/redhat-linux-build'
/usr/bin/cmake -E cmake_progress_start /home/ruby/rpmbuild/BUILD/redhat-linux-build/CMakeFiles 0
+ RPM_EC=0
++ jobs -p
+ exit 0
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.jYnGjO
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ '[' /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64 '!=' / ']'
+ rm -rf /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
++ dirname /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
+ mkdir -p /home/ruby/rpmbuild/BUILDROOT
+ mkdir /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
+ CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CFLAGS
+ CXXFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CXXFLAGS
+ FFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FFLAGS
+ FCFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FCFLAGS
+ VALAFLAGS=-g
+ export VALAFLAGS
+ LDFLAGS='-Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes'
+ export LDFLAGS
+ LT_SYS_LIBRARY_PATH=/usr/lib64:
+ export LT_SYS_LIBRARY_PATH
+ CC=gcc
+ export CC
+ CXX=g++
+ export CXX
+ export QA_RPATHS=17
+ QA_RPATHS=17
+ DESTDIR=/home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
+ /usr/bin/cmake --install redhat-linux-build
-- Install configuration: "Release"
-- Installing: /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64/usr/lib/libclipboardx11.so
-- Installing: /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64/usr/lib/libclipboardwayland.so
-- Installing: /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64/usr/bin/clipboard
-- Set runtime path of "/home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64/usr/bin/clipboard" to "/usr/lib"
ln: failed to create symbolic link '/usr/bin/cb': Permission denied
+ '[' '%{buildarch}' = noarch ']'
+ QA_CHECK_RPATHS=1
+ case "${QA_CHECK_RPATHS:-}" in
+ /usr/lib/rpm/check-rpaths
WARNING 0001: file '/usr/bin/clipboard' contains a standard runpath '/usr/lib' in [/usr/lib]
+ /usr/lib/rpm/check-buildroot
+ /usr/lib/rpm/redhat/brp-ldconfig
+ /usr/lib/rpm/brp-compress
+ /usr/lib/rpm/brp-strip /usr/bin/strip
+ /usr/lib/rpm/brp-strip-comment-note /usr/bin/strip /usr/bin/objdump
+ /usr/lib/rpm/redhat/brp-strip-lto /usr/bin/strip
+ /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip
+ /usr/lib/rpm/check-rpaths
WARNING 0001: file '/usr/bin/clipboard' contains a standard runpath '/usr/lib' in [/usr/lib]
+ /usr/lib/rpm/redhat/brp-mangle-shebangs
+ /usr/lib/rpm/brp-remove-la-files
+ env /usr/lib/rpm/redhat/brp-python-bytecompile '' 1 0 -j6
+ /usr/lib/rpm/redhat/brp-python-hardlink
Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.OQc2TJ
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CFLAGS
+ CXXFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer'
+ export CXXFLAGS
+ FFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FFLAGS
+ FCFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -U_FORTIFY_SOURCE -Wp,-U_FORTIFY_SOURCE -Wp,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -I/usr/lib64/gfortran/modules'
+ export FCFLAGS
+ VALAFLAGS=-g
+ export VALAFLAGS
+ LDFLAGS='-Wl,-z,relro -Wl,--as-needed  -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes'
+ export LDFLAGS
+ LT_SYS_LIBRARY_PATH=/usr/lib64:
+ export LT_SYS_LIBRARY_PATH
+ CC=gcc
+ export CC
+ CXX=g++
+ export CXX
+ RPM_EC=0
++ jobs -p
+ exit 0
Processing files: clipboard-git-2023.01.14-1.fc38.x86_64
Provides: clipboard-git = 2023.01.14-1.fc38 clipboard-git(x86-64) = 2023.01.14-1.fc38 libclipboardwayland.so()(64bit) libclipboardx11.so()(64bit)
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Requires: libX11.so.6()(64bit) libc.so.6()(64bit) libc.so.6(GLIBC_2.14)(64bit) libc.so.6(GLIBC_2.2.5)(64bit) libc.so.6(GLIBC_2.24)(64bit) libc.so.6(GLIBC_2.32)(64bit) libc.so.6(GLIBC_2.34)(64bit) libc.so.6(GLIBC_2.4)(64bit) libgcc_s.so.1()(64bit) libgcc_s.so.1(GCC_3.0)(64bit) libgcc_s.so.1(GCC_3.3.1)(64bit) libstdc++.so.6()(64bit) libstdc++.so.6(CXXABI_1.3)(64bit) libstdc++.so.6(CXXABI_1.3.9)(64bit) libstdc++.so.6(GLIBCXX_3.4)(64bit) libstdc++.so.6(GLIBCXX_3.4.11)(64bit) libstdc++.so.6(GLIBCXX_3.4.19)(64bit) libstdc++.so.6(GLIBCXX_3.4.20)(64bit) libstdc++.so.6(GLIBCXX_3.4.21)(64bit) libstdc++.so.6(GLIBCXX_3.4.22)(64bit) libstdc++.so.6(GLIBCXX_3.4.26)(64bit) libstdc++.so.6(GLIBCXX_3.4.29)(64bit) libstdc++.so.6(GLIBCXX_3.4.30)(64bit) libstdc++.so.6(GLIBCXX_3.4.9)(64bit) rtld(GNU_HASH)
Checking for unpackaged file(s): /usr/lib/rpm/check-files /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
Wrote: /home/ruby/rpmbuild/RPMS/x86_64/clipboard-git-2023.01.14-1.fc38.x86_64.rpm
Executing(%clean): /bin/sh -e /var/tmp/rpm-tmp.nKwlRs
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ /usr/bin/rm -rf /home/ruby/rpmbuild/BUILDROOT/clipboard-git-2023.01.14-1.fc38.x86_64
+ RPM_EC=0
++ jobs -p
+ exit 0
Executing(rmbuild): /bin/sh -e /var/tmp/rpm-tmp.QYgCwC
+ umask 022
+ cd /home/ruby/rpmbuild/BUILD
+ RPM_EC=0
++ jobs -p
+ exit 0

RPM build warnings:
    source_date_epoch_from_changelog set but %changelog is missing

GLIBC_2.32 not found - Windows 10, WSL 2

Describe the bug
Hello.

I've tried to install Clipboard to Windows 10 WSL2 with curl -sSL https://github.com/Slackadays/Clipboard/raw/main/src/install.sh | bash.

My env is:

$ uname -r
5.10.16.3-microsoft-standard-WSL2

$ cat /etc/os-release
NAME="Ubuntu"
VERSION="18.04.6 LTS (Bionic Beaver)"

$ cat /proc/version
Linux version 5.10.16.3-microsoft-standard-WSL2 (oe-user@oe-host) (x86_64-msft-linux-gcc (GCC) 9.3.0, GNU ld (GNU Binutils) 2.34.0.20200220) #1 SMP Fri Apr 2 22:23:49 UTC 2021

$ ldd --version
ldd (Ubuntu GLIBC 2.27-3ubuntu1.6) 2.27

When I run cb copy j.txt, I got the following error:

$ cb copy j.txt
cb: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by cb)
cb: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by cb)

Maybe it makes sense to add some additional steps to an install script, or README, how to install it.

Sugestion: clear

$cb clear ..... wipes the content of the /tmp/clipboard folder.

I tested by cb-ing the entire contents of my /downloads folder, which included an ISO of AlmaLinux (~8GB).

Thought it would be nice to clean the tmp out after using cb to do its thing :) or to ensure the clipboard was/is clear between shell sessions or doing a copy/paste of something important.

BTW, really LOVE this project. Its so unbelievable it isn't already in Linux.

Further idea, but unimportant... multiclips, so one can have a few items? e.g.
cb copy1 foo.txt
cb copy2 bar.txt
cb paste1
cb paste2

Feature Request: Customize installation prefix

Is your feature request related to a problem? Please describe.
Currently the user cannot choose the installation location of the Clipboard binary. For packaging purposes it would be difficult as well.

Describe the solution you'd like
Changing the CMakeLists.txt like this:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8051532..616c471 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -94,9 +94,13 @@ endif()
 if(WIN32)
   install(TARGETS clipboard DESTINATION bin)
 elseif(APPLE)
-  install(TARGETS clipboard DESTINATION /usr/local/bin)
-  install(CODE "execute_process(COMMAND ln -sf /usr/local/bin/clipboard /usr/local/bin/cb)")
+  set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "Installation Prefix")
+  install(TARGETS clipboard
+    RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/bin/")
+  install(CODE "execute_process(COMMAND ln -sf ${CMAKE_INSTALL_PREFIX}/bin/clipboard ${CMAKE_INSTALL_PREFIX}/bin/cb)")
 else()
-  install(TARGETS clipboard DESTINATION /usr/bin/)
-  install(CODE "execute_process(COMMAND ln -sf /usr/bin/clipboard /usr/bin/cb)")
-endif()
\ No newline at end of file
+  set(CMAKE_INSTALL_PREFIX "/usr" CACHE PATH "Installation Prefix")
+  install(TARGETS clipboard
+    RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/bin/")
+  install(CODE "execute_process(COMMAND ln -sf ${CMAKE_INSTALL_PREFIX}/bin/clipboard ${CMAKE_INSTALL_PREFIX}/bin/cb)")
+endif()

Describe alternatives you've considered
Providing DESTDIRvariable during make install

Additional context
Add any other context or screenshots about the feature request here.

Command line parameter to display Clipboards version

Is your feature request related to a problem? Please describe.
I dont recall what version of clipboard I have installed. Most command line tools have a way to report their version.

Describe the solution you'd like
Support the command line parameter -v or --version

Describe alternatives you've considered
None

Additional context
None

Encoding issue in CJK locales

Describe the bug

Hi! I am trying to build Clipboard from source under Win11 with VS2022 Preview Community Edition. Since my local language is Chinese Simplified, the default code page of my machine is CP936.

#1 Try:

pushd build
cmake .. -A Win32 > build.log
cmake --build . >> build.log
type build.log

Output:

-- Building for: Visual Studio 17 2022
-- The CXX compiler identification is MSVC 19.35.32019.0
-- The C compiler identification is MSVC 19.35.32019.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Looking for fork
-- Looking for fork - not found
-- Building Clipboard without X11 support
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Building Clipboard without Wayland support
-- Looking for pthread_cancel
-- Looking for pthread_cancel - not found
-- Looking for pthread.h
-- Looking for pthread.h - not found
-- Found Threads: TRUE  
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/hp/Desktop/Clipboard/build
MSBuild version 17.5.0-preview-22525-01+3b7246b65 for .NET Framework
  Checking Build System
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/gui/CMakeLists.txt
  fork.cpp
  gui.cpp
  utils.cpp
  Generating Code...
  gui.vcxproj -> C:\Users\hp\Desktop\Clipboard\build\gui.lib
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/clipboard/CMakeLists.txt
  clipboard.cpp
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(1,1): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(683,228): error C2001: newline in constant [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(684,5): error C2062: type 'unsigned int' unexpected [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(688,13): error C2065: 'percent_done': undeclared identifier [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(689,100): error C2065: 'percent_done': undeclared identifier [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(710,13): error C2065: 'percent_done': undeclared identifier [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(711,1): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(711,100): error C2065: 'percent_done': undeclared identifier [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
  messages.cpp
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(1,1): warning C4819: The file contains a character that cannot be represented in the current code page (936). Save the file in Unicode format to prevent data loss [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
  windows.cpp

01

In clipboard.cpp and messages.cpp, there are many non-ASCII characters stored in message string literals(std::string_view). When it comes to CJK locales, MSVC will try to parse these string literals with the system's current code page(instead of UTF-8), resulting in these compilation errors.

At first, I wanted to change the type of these strings to std::u8string_view, but I gave up due to the amount of work(COLs) involved.

#2 Try:

Patch src/clipboard/CMakeLists.txt:

diff --git a/src/clipboard/CMakeLists.txt b/src/clipboard/CMakeLists.txt
index db6ec89..64d9ab9 100644
--- a/src/clipboard/CMakeLists.txt
+++ b/src/clipboard/CMakeLists.txt
@@ -22,6 +22,7 @@ target_link_libraries(clipboard gui)
 
 if(WIN32)
   target_sources(clipboard PRIVATE src/windows.cpp)
+  target_compile_options(clipboard PRIVATE /source-charset:utf-8)
 elseif(APPLE)
   enable_language(OBJC)
   target_sources(clipboard PRIVATE

In this way, I want the compiler to treat the two source files containing the UNICODE message strings as UTF-8 encoded.

This strategy worked, although it elicited a bunch of warning messages.

Build log:

-- Building for: Visual Studio 17 2022
-- The CXX compiler identification is MSVC 19.35.32019.0
-- The C compiler identification is MSVC 19.35.32019.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Looking for fork
-- Looking for fork - not found
-- Building Clipboard without X11 support
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Building Clipboard without Wayland support
-- Looking for pthread_cancel
-- Looking for pthread_cancel - not found
-- Looking for pthread.h
-- Looking for pthread.h - not found
-- Found Threads: TRUE  
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/hp/Desktop/Clipboard/build
MSBuild version 17.5.0-preview-22525-01+3b7246b65 for .NET Framework
  Checking Build System
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/gui/CMakeLists.txt
  fork.cpp
  gui.cpp
  utils.cpp
  Generating Code...
  gui.vcxproj -> C:\Users\hp\Desktop\Clipboard\build\gui.lib
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/clipboard/CMakeLists.txt
  clipboard.cpp
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\clipboard.cpp(163,34): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
  messages.cpp
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(96,42): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(97,47): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(98,48): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(99,52): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(100,43): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(101,41): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(107,33): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(108,33): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(117,39): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(119,27): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(120,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(121,32): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(122,36): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(123,38): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(124,44): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(125,50): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(126,53): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(127,52): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(128,55): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(173,31): warning C4566: character represented by universal-character-name '\u00F1' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(174,44): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(175,37): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(176,31): warning C4566: character represented by universal-character-name '\u00F1' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(177,35): warning C4566: character represented by universal-character-name '\u00F1' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(180,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(181,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(189,28): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(190,34): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(191,40): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(192,51): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(222,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(222,20): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(223,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(225,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(225,20): warning C4566: character represented by universal-character-name '\u00F5' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(227,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(227,20): warning C4566: character represented by universal-character-name '\u00F5' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(228,31): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(228,31): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(229,37): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(229,37): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(229,37): warning C4566: character represented by universal-character-name '\u00F5' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(231,38): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(232,36): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(233,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(234,37): warning C4566: character represented by universal-character-name '\u00E3' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(234,37): warning C4566: character represented by universal-character-name '\u00F4' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(237,27): warning C4566: character represented by universal-character-name '\u00F5' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(239,28): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(240,34): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(241,40): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(242,51): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(264,34): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(265,35): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(265,35): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(266,36): warning C4566: character represented by universal-character-name '\u0130' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(266,36): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(266,36): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(267,37): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(267,37): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(267,37): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(270,32): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(271,33): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(271,33): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(272,34): warning C4566: character represented by universal-character-name '\u0130' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(272,34): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(272,34): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(273,35): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(273,35): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(273,35): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(275,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(275,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(275,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(276,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(277,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(277,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(278,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(278,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(279,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(279,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(280,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(280,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(281,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(281,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(282,20): warning C4566: character represented by universal-character-name '\u0130' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(282,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(282,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(282,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(283,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(283,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(284,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(284,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(285,20): warning C4566: character represented by universal-character-name '\u00D6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(286,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(286,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(286,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(286,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(287,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(287,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(288,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(288,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(289,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(289,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(289,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(290,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(290,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(290,20): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(290,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(291,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(291,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(291,20): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(293,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(295,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(295,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(296,20): warning C4566: character represented by universal-character-name '\u0130' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(296,20): warning C4566: character represented by universal-character-name '\u00C7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(296,20): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(296,20): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(296,20): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(297,38): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(297,38): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(297,38): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(297,38): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(297,38): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(298,44): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(298,44): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(298,44): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(299,37): warning C4566: character represented by universal-character-name '\u2022' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(299,37): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(299,37): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(300,31): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(300,31): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(300,31): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(300,31): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(301,31): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(301,31): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(301,31): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(301,31): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(302,35): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(302,35): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(302,35): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(302,35): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(303,38): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(303,38): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(303,38): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(303,38): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(304,36): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(304,36): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(304,36): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(305,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(305,29): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(305,29): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(306,29): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(308,37): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(308,37): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(308,37): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(308,37): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(308,37): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(311,27): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(311,27): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(312,27): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(313,34): warning C4566: character represented by universal-character-name '\u00F6' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(313,34): warning C4566: character represented by universal-character-name '\u011F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(313,34): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(313,34): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(313,34): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(314,28): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(315,34): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(316,40): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(317,51): warning C4566: character represented by universal-character-name '\u2713' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(318,30): warning C4566: character represented by universal-character-name '\u0130' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(318,30): warning C4566: character represented by universal-character-name '\u00E7' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(318,30): warning C4566: character represented by universal-character-name '\u015F' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
C:\Users\hp\Desktop\Clipboard\src\clipboard\src\messages.cpp(318,30): warning C4566: character represented by universal-character-name '\u0131' cannot be represented in the current code page (936) [C:\Users\hp\Desktop\Clipboard\build\src\clipboard\clipboard.vcxproj]
  windows.cpp
  Generating code
  Not all modules are compiled with -Gy (function comdat), build without incremental LTCG.
  Finished generating code
  clipboard.vcxproj -> C:\Users\hp\Desktop\Clipboard\build\clipboard.exe
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/CMakeLists.txt

However, the problem is that the path containing the CJK character and the localized error message returned by FormatMessageA are not displayed correctly when the program is run.

02

#3 Try:

Patch CMakeLists.txt:

diff --git a/src/clipboard/CMakeLists.txt b/src/clipboard/CMakeLists.txt
index db6ec89..1d4cd02 100644
--- a/src/clipboard/CMakeLists.txt
+++ b/src/clipboard/CMakeLists.txt
@@ -22,6 +22,7 @@ target_link_libraries(clipboard gui)
 
 if(WIN32)
   target_sources(clipboard PRIVATE src/windows.cpp)
+  target_compile_options(clipboard PRIVATE /utf-8)
 elseif(APPLE)
   enable_language(OBJC)
   target_sources(clipboard PRIVATE

This time, in addition to specifying the /source-charset:utf-8, I also specified the /execution-charset:utf-8.

https://learn.microsoft.com/en-us/cpp/build/reference/utf-8-set-source-and-executable-character-sets-to-utf-8?view=msvc-170

Build log:

-- Building for: Visual Studio 17 2022
-- The CXX compiler identification is MSVC 19.35.32019.0
-- The C compiler identification is MSVC 19.35.32019.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: D:/Program Files/Microsoft Visual Studio/2022/Preview/VC/Tools/MSVC/14.35.32019/bin/Hostx64/x86/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Looking for fork
-- Looking for fork - not found
-- Building Clipboard without X11 support
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Building Clipboard without Wayland support
-- Looking for pthread_cancel
-- Looking for pthread_cancel - not found
-- Looking for pthread.h
-- Looking for pthread.h - not found
-- Found Threads: TRUE  
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/hp/Desktop/Clipboard/build
MSBuild version 17.5.0-preview-22525-01+3b7246b65 for .NET Framework
  Checking Build System
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/gui/CMakeLists.txt
  fork.cpp
  gui.cpp
  utils.cpp
  Generating Code...
  gui.vcxproj -> C:\Users\hp\Desktop\Clipboard\build\gui.lib
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/src/clipboard/CMakeLists.txt
  clipboard.cpp
  messages.cpp
  windows.cpp
  Generating code
  Not all modules are compiled with -Gy (function comdat), build without incremental LTCG.
  Finished generating code
  clipboard.vcxproj -> C:\Users\hp\Desktop\Clipboard\build\clipboard.exe
  Building Custom Rule C:/Users/hp/Desktop/Clipboard/CMakeLists.txt

No errors, no warnings.

This time, characters like and can show correctly.

03

To Reproduce

Expected behavior

Screenshots

Additional context

Before you post
Please make sure you check previous bug reports before filing a new one.
This will help keep the Issues section less cluttered. :)

Feature Request: standards compliant usage syntax in help text

Is your feature request related to a problem? Please describe.
The usage definition and examples in the help text and README are unhelpfully freeform. There is ambiguousness and un-covered cases in each of them.

Describe the solution you'd like
Add http://docopt.org/ compliant* usage help, in the program and in the README. This could replace a bit of the existing documentation, but most of the longer descriptive examples and explanations could still work alongside this.

It might look something like this:

Usage:
  clipboard copy(n) [FILE ...]
  clipboard cut(n) [FILE ...]
  clipboard paste(n)
  clipboard show(n)
  clipboard clear(n)
  clipboard

This doesn't require actually using docopt.cpp to parse the help text or options.

* the copy1 syntax might not be possible to make fully compliant, but I'll be opening another issue for that.

Feature Request: standards compliant command line parameter syntax

Is your feature request related to a problem? Please describe.
The copy1 / paste4 etc syntax makes clipboard incompatible with tools that automatically handle command line parameters for other tools, such as https://github.com/nevesnunes/sh-manpage-completions

Describe the solution you'd like
Add an optional syntax to specify the clipboard number as a named parameter.

clipboard cut1 somefile could instead be clipboard cut -n 1 somefile or clipboard cut --clipboard-number=1 somefile

PS: It would be even better if this was the only syntax, and the user could implement shortcut aliases themself if they want them, but I suspect from the motivations described in the README that such a suggestion would get much less traction, so I've written this as a request for an option.

Support other types of contents

Is your feature request related to a problem? Please describe.
This program can currently only copy plain text.

Describe the solution you'd like
Support copying content types other than plain text. Images, files, HTML/RTF, etc.

Additional context
Another cross-platform clipboard tool that might be helpful for reference: https://github.com/hluk/CopyQ

copy files large than free space

If copy a big file larger than free space, there will be an error:
There won't be enough storage available to paste everything.
When I have another storage mounted which has enough free space and I'm going to paste there, that error will occur.
Maybe it detects free space of / only?
Or could you postpone this error till the paste operation?

WSL2 `cb` copy + host Windows regular paste = destination hang

Describe the bug
When pasting the content copied by cb outside of WSL2 the receiving app crashes hangs

To Reproduce

  1. Use WSL2
  2. Install cb with brew (not sure if has anything to do with it)
  3. copy echo test | cb
  4. paste on host OS (e.g. VSCode, Chrome)
  5. Observe the destination hang

Expected behavior
Shouldn't hang app outside of WSL

Screenshots
N/A

Additional context
N/A

clipboard paste giving ^M characters

when tried to paste into vim using :r !clipboard paste it is giving ^M characters in the output.

screenshot_20221212122600

is there any option to escape these ^M characters?

Feature Request: symlink option when copying files

When copying a file, the file is literally copied to the clipboard tmp (or non-tmp) directory. This could be slow for big files, or have other drawbacks in certain situations. I'd like an option that would result in a symlink being made instead of a copy. Just for the tmp dir; paste would still copy the file.

A down side of this would be that paste would reflect any changes made to the file on disk after it was copied. This should be documented. It could also result in a notification to the user when they try to paste, if the modification time on the file is newer than the creation time on the symlink.

Error during installation: ranges: No such file or directory

Describe the bug
When running the installation, I get following error on the cmake --build . step:

/home/dyte/temp/Clipboard/src/clipboardx11/src/x11.cpp:23:10: fatal error: ranges: No such file or directory
   23 | #include <ranges>
      |          ^~~~~~~~
compilation terminated.
make[2]: *** [src/clipboardx11/CMakeFiles/clipboardx11.dir/build.make:63: src/clipboardx11/CMakeFiles/clipboardx11.dir/src/x11.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:136: src/clipboardx11/CMakeFiles/clipboardx11.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

To Reproduce
Steps to reproduce the behavior:

  1. Run the manual installation up until cmake --build .

Expected behavior
The installation finishes succesfully

Additional context
I'm on Ubuntu 20.04.1 LTS

Install script side effects

The install script (install.sh) calls rm -r bin lib at the end of the installation.
This will delete any existing bin and lib folders in the working directory.

This happened to me - I called your script as described in README.md in my home directory,
where I also store a bin folder with all my useful scripts.

It's my fault for calling scripts from the internet without looking at them first, but maybe we can
save someone else from feeling the pain I'm feeling now...

To Reproduce

  1. mkdir test
  2. cd test
  3. mkdir bin
  4. curl -sSL https://github.com/Slackadays/Clipboard/raw/main/src/install.sh | bash
  5. bin folder has been removed.

Expected behavior
Clipboard should install, but without any side effects.

I think the install script could create a unique, temporary directory instead of doing its work in
the working directory.

Add instructions on how to uninstall

While installation is covered in the README, uninstalling is not. To install the AUR package of this software, i had to manually remove /usr/bin/cb and /usr/bin/clipboard. I am not sure if that was all i had to remove?

Something like cmake --uninstall . would be helpful.

Static variables in header file may cause problems

Describe the bug

When exploring #58 with VS2022,I noticed that filepath is empty in windows.cpp.

Since filepath is declared in clipboard.hpp as a static variable, then each compilation unit that includes this header will have its own copy of this variable. Some of them may be initialized correctly, some may not.

In windows.cpp, these two places will reference filepath:

std::ifstream file(filepath.main / constants.pipe_file);

for (const auto& entry : fs::directory_iterator(filepath.main)) {

Though filepath is initialized in clipboard.cpp:

because clipboard.cpp and windows.cpp are two compilation units, filepath referenced by these two places in windows.cpp is still uninitialized. As a result:

fs::directory_iterator(filepath.main) // fs::directory_iterator("")

will raise an exception(File not Found).

To Reproduce

First, add copy $(TargetPath) to Command Arguments:

01

Then step into setWindowsClipboardDataFiles or setWindowsClipboardDataPipe, and dump the value of filepath.main and address of filepath.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
Hi! @Slackadays Instead of screenshots, I made a short video to demonstrate the issue. And the reason I did not take screenshots is once I started to debugging Clipboard with VS2022, the Print Scrn key won't work any more.

https://drive.google.com/file/d/1cChilbVmh1uqt4OUv-_a3JDdbsij2cxu/view?usp=sharing

Additional context
Add any other context about the problem here.

Before you post
Please make sure you check previous bug reports before filing a new one.
This will help keep the Issues section less cluttered. :)

A situation that I see and cannot perceive while translating.

Hi,
I added Turkish translations and while making this, I see some problems. I want to list them and discuss.

The ActionArray we entered as actions is taken directly as the action of the clipboard. In this case, when I localize these operations in language.hpp, I call them with their localized version. Is this an expected behavior? If not, let's create something called actionNames instead of actions and pull the names from there, and use the actions variable to operate the operations. In this way, it can work with the same commands in every language, even if it is localized. Of course, this is just a suggestion.

Bug: Installation on M1 Mac doesn't work

Describe the bug
Error when building on M1 mac.

To Reproduce
I errors on make --build .

Expected behavior

p:464:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/yonatanalexander/development/misc_projects/tmp/Clipboard/src/clipboard.cpp:464:62)>' requested here
            cv.wait_for(lock, std::chrono::milliseconds(50), [&]{ return st.stop_requested(); });
               ^
12 errors generated.
make[2]: *** [CMakeFiles/clipboard.dir/src/clipboard.cpp.o] Error 1
make[1]: *** [CMakeFiles/clipboard.dir/all] Error 2
make: *** [all] Error 2

Windows installation command

Describe the bug
The windows installation command present in the README did not work for me.

To Reproduce

  1. Run Invoke-WebRequest -UseBasicParsing https://github.com/Slackadays/Clipboard/raw/main/src/install.ps1 | powershell

Error

$ Invoke-WebRequest -UseBasicParsing https://github.com/Slackadays/Clipboard/raw/main/src/install.ps1 | powershell
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.

Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows

PS C:\Users\anton>
PS C:\Users\anton> StatusCode        : 200
StatusCode : The term 'StatusCode' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of
the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ StatusCode        : 200
+ ~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (StatusCode:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton> StatusDescription : OK
StatusDescription : The term 'StatusDescription' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ StatusDescription : OK
+ ~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (StatusDescription:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton> Content           : Invoke-WebRequest https://nightly.link/Slackadays/Clipboard/workflows/main/main/clipboard-windows-amd64.zip -OutFile clipboard-windows-amd64.zip
Get-Content : A positional parameter cannot be found that accepts argument 'Invoke-WebRequest'.
At line:1 char:1
+ Content           : Invoke-WebRequest https://nightly.link/Slackadays ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [Get-Content], ParameterBindingException
    + FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.PowerShell.Commands.GetContentCommand

PS C:\Users\anton>                     Expand-Archive clipboard-windows-amd64.zip -Destination…
Expand-Archive : A parameter cannot be found that matches parameter name 'Destination…'.
At line:1 char:64
+ ...            Expand-Archive clipboard-windows-amd64.zip -Destination…
+                                                           ~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [Expand-Archive], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,Expand-Archive

PS C:\Users\anton> RawContent        : HTTP/1.1 200 OK
RawContent : The term 'RawContent' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of
the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ RawContent        : HTTP/1.1 200 OK
+ ~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (RawContent:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton>                     Connection: keep-alive
Connection: : The term 'Connection:' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling
of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:21
+                     Connection: keep-alive
+                     ~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Connection::String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton>                     Cache-Control: max-age=300
Cache-Control: : The term 'Cache-Control:' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:21
+                     Cache-Control: max-age=300
+                     ~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Cache-Control::String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton>                     Content-Security-Policy: default-src 'none'; style-src 'unsafe-inline'; sandbox
Content-Security-Policy: : The term 'Content-Security-Policy:' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:21
+                     Content-Security-Policy: default-src 'none'; styl ...
+                     ~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Content-Security-Policy::String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

style-src : The term 'style-src' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of
the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:66
+ ...        Content-Security-Policy: default-src 'none'; style-src 'unsafe ...
+                                                         ~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (style-src:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

sandbox : The term 'sandbox' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the
name, or if a path was included, verify that the path is correct and try again.
At line:1 char:93
+ ... curity-Policy: default-src 'none'; style-src 'unsafe-inline'; sandbox
+                                                                   ~~~~~~~
    + CategoryInfo          : ObjectNotFound: (sandbox:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\anton>                     ETag: "b1407ad3d5d4dc2cbd78fb19d0636afa40b811026b7…
>> Headers           : {[Connection, System.String[]], [Cache-Control, System.String[]], [Content-Security-Policy, System.String[]], [ETag, System.String[]]…}
>> Images            : {}
>> InputFields       : {}
>> Links             : {}
>> RawContentLength  : 1022
>> RelationLink      : {}
>>
>>
>>

Additional Context

$ $PSVersionTable

Name                           Value
----                           -----
PSVersion                      7.3.1
PSEdition                      Core
GitCommitId                    7.3.1
OS                             Microsoft Windows 10.0.22621
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Fix

I'm not sure if something is weird with my powershell set up but what I ran that works in admin mode is

Invoke-WebRequest -UseBasicParsing https://github.com/Slackadays/Clipboard/raw/main/src/install.ps1 | iex

piping zero bytes

clipboard is piping out zero bytes, when i try to paste the clipboard content to
some file or stdout as shown below.

screenshot_20221212104633

Problem cutting file

Hi, I get the following error when cutting a file:

~/Downloads 
 ⟩ cd ~/Downloads/
~/Downloads 
 ⟩ touch test.txt
~/Downloads 
 ⟩ clipboard cut test.txt
╳ Clipboard couldn't cut these items:
▏ test.txt: Invalid cross-device link
▏ See if you have the needed permissions, or
▏ try double-checking the spelling of the files or what directory you're in.

I have the permissions for the file:

 ⟩ ls -l test.txt
.rw-r--r--. nivaca 0B 10 Dec 22 16:57:44 test.txt
~/Downloads 
 ⟩ rm test.txt
~/Downloads 

I'm on Fedora 37:

 ⟩ uname -a
Linux nivaca-pc 6.0.10-300.fc37.x86_64 #1 SMP PREEMPT_DYNAMIC Sat Nov 26 16:55:13 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

Copy/paste does work, however.

Any ideas?

External changes to the normal clipboard aren't immeditely apparent in cb sh0, cb p0 commands

Describe the bug
Changes to the normal clipboard from outside this application aren't immediately apparent in cb sh0, cb p0 commands. The changes are immediate apparent in the output if cb is called without anything else, and after calling cb like that cb sh0, cb p0 works.

To Reproduce
Steps to reproduce the behavior:

Microsoft Windows [Version 10.0.19044.2604]
(c) Microsoft Corporation. All rights reserved.

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb cp0 text1
✓ Copied text "text1"

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb sh0
• Here are the first 5 bytes in clipboard 0:
text1

C:\Users\▋▋▋▋▋▋▋▋▋▋>echo text2 | clip

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb sh0
• Here are the first 5 bytes in clipboard 0:
text1

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb
• There are items in these clipboards:
▏ 0: text2
Add cut, copy, or paste to the end, like clipboard copy to get started, or if you need help, try clipboard -h to show the help screen.

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb sh0
• Here are the first 8 bytes in clipboard 0:
text2

Expected behavior

Microsoft Windows [Version 10.0.19044.2604]
(c) Microsoft Corporation. All rights reserved.

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb cp0 text1
✓ Copied text "text1"

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb sh0
• Here are the first 5 bytes in clipboard 0:
text1

C:\Users\▋▋▋▋▋▋▋▋▋▋>echo text2 | clip

C:\Users\▋▋▋▋▋▋▋▋▋▋>cb sh0
• Here are the first 5 bytes in clipboard 0:
text2

Bug: `CI` environment variable undocumented, silently forces overwrite

Describe the bug
Having an env variable named CI triggers the no-tty behaviors in clipboard, which forces overwrite of files

To Reproduce
Steps to reproduce the behavior:

  1. touch foo
  2. clipboard copy foo
  3. CI=something clipboard paste

Expected behavior
overwrite prompt, or default to not overwrite without an option like -f or --force, or the CI env behavior documented in the readme, help text, and/or man page.

After installing using the suggested tool GLIBCXX_3.4.29 is not found

Describe the bug
After installing using the suggeted methond:
curl -sSL https://github.com/Slackadays/Clipboard/raw/main/src/install.sh | sh

To Reproduce
❯ curl -sSL https://github.com/Slackadays/Clipboard/raw/main/src/install.sh | sh
Archive: clipboard-linux.zip
creating: bin/
creating: lib/
inflating: bin/clipboard
inflating: lib/libclipboardwayland.so
inflating: lib/libclipboardx11.so
inflating: lib/libgui.a
Clipboard installed successfully!

❯ cb
cb: /lib/x86_64-linux-gnu/libstdc++.so.6: version GLIBCXX_3.4.29' not found (required by cb) cb: /lib/x86_64-linux-gnu/libc.so.6: version GLIBC_2.32' not found (required by cb)
cb: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by cb)

I was usin Linux Mint Debian Edition 5 (Debian 11)

Install script fails

Running the install script on Ubuntu 20 fails with this output:

+ set +e
++ uname
+ '[' Linux = Linux ']'
++ mktemp -d -t cb-XXXXXXXXXX
+ tmp_dir=/tmp/cb-iZ3TjdGm6l
+ cd /tmp/cb-iZ3TjdGm6l
++ uname -m
+ '[' x86_64 = x86_64 ']'
+ download_link=https://nightly.link/Slackadays/Clipboard/workflows/main/main/clipboard-linux-gcc10-amd64.zip
+ '[' https://nightly.link/Slackadays/Clipboard/workflows/main/main/clipboard-linux-gcc10-amd64.zip '!=' skip ']'
+ curl -SsLl https://nightly.link/Slackadays/Clipboard/workflows/main/main/clipboard-linux-gcc10-amd64.zip -o clipboard-linux.zip
+ unzip clipboard-linux.zip
Archive:  clipboard-linux.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of clipboard-linux.zip or
        clipboard-linux.zip.zip, and cannot find clipboard-linux.zip.ZIP, period.
+ rm clipboard-linux.zip
+ sudo mv bin/clipboard /usr/bin/clipboard
mv: cannot stat 'bin/clipboard': No such file or directory
+ chmod +x /usr/bin/clipboard
chmod: cannot access '/usr/bin/clipboard': No such file or directory
+ sudo ln -sf /usr/bin/clipboard /usr/bin/cb
+ '[' -f lib/libclipboardx11.so ']'
+ '[' -f lib/libclipboardwayland.so ']'
+ rm -rf /tmp/cb-iZ3TjdGm6l
+ echo 'Installed Clipboard'
Installed Clipboard
+ exit 0

When I try to download the ZIP that's used in that script manually, I get this output:

<!DOCTYPE html>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="/style.css?963e4c4186">
<link rel="icon" href="/logo.svg" type="image/svg+xml">

<h1>Error 404 &ndash; Not Found</h1>

<p>Artifact &#39;clipboard-linux-gcc10-amd64&#39; not found for run #4079117061.
<p>Check on GitHub: <a rel="nofollow" href="https://github.com/Slackadays/Clipboard/actions/runs/4079117061#artifacts">https://github.com/Slackadays/Clipboard/actions/runs/4079117061#artifacts</a></p>

<p><a href="/">Return to the home page</a>

Processes hanging

Describe the bug
Every time I launch clipboard clear I got a bunch of processes lying around.

To Reproduce

  • Install clipboard from the AUR repo clipboard-bin.
  • Launch clipboard clear multiple time
  • Furthermore, if I copy a file, for example with cb cp .xinitrc I correctly expect the process to stay. But once I cb clear I expect it to exit, but that does not seem to be the case.

Expected behavior
Processes should exit with some status code, unless they are needed for some reason.
I did not try to compile it myself to see if this is an issue with the package. Besides, I don't think you maintain any of the AUR packages clipboard-bin or clipboard-git, do you?

Screenshots
2023-02-27T123146

On another notice, I read #95. I believe Clipboard is the best tool for clipboard interaction. As a matter of fact, as of today you have 2713 stars on github, kudos! Keep up the good work.

Inlining failing

Describe the bug
Unable to build with cmake --build .

To Reproduce

git clone https://github.com/Slackadays/Clipboard 
cd Clipboard/build
cmake -DCMAKE_BUILD_TYPE=MinSizeRel ..
cmake --build .

Building runs fine until linking:

[100%] Linking CXX executable ../../clipboard
/usr/include/fortify/stdio.h: In function '__to_xstring.constprop':
/usr/include/fortify/stdio.h:73:28: error: inlining failed in call to 'always_inline' 'vsnprintf': function body can be overwritten at link time
   73 | _FORTIFY_FN(vsnprintf) int vsnprintf(char * _FORTIFY_POS0 __s, size_t __n,
      |                            ^
/usr/include/c++/12.2.1/ext/string_conversions.h:111:32: note: called from here
  111 |       const int __len = __convf(__s, __n, __fmt, __args);
      |                                ^
make[3]: *** [/tmp/ccMOAGFB.mk:2: /tmp/ccbngCFG.ltrans0.ltrans.o] Error 1
lto-wrapper: fatal error: make returned 2 exit status
compilation terminated.
/usr/lib/gcc/x86_64-alpine-linux-musl/12.2.1/../../../../x86_64-alpine-linux-musl/bin/ld: error: lto-wrapper failed
collect2: error: ld returned 1 exit status
make[2]: *** [src/clipboard/CMakeFiles/clipboard.dir/build.make:146: clipboard] Error 1
make[1]: *** [CMakeFiles/Makefile2:142: src/clipboard/CMakeFiles/clipboard.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

Expected behavior
Successful build

Additional context
Alpine Linux edge

Bug: several build errors in the C++ source file clipboard.cpp

Describe the bug
After clean install, it fails on build

To Reproduce
Steps to reproduce the behavior:

  1. cmake --build .

Expected behavior
Use Clipboard

Screenshots
image

Additional context
chatGPT:
Pencil Originals
Explain on a text, that error while I was trying to install Clipboard from github on my Ubuntu 20.04.5 LTS

here is the error

ANSWER:
It looks like there are several errors in the C++ source file clipboard.cpp while trying to build the Clipboard project on your Ubuntu 20.04.5 LTS system.

Here is a summary of the errors:

‘jthread’ in namespace ‘std’ does not name a type; did you mean ‘thread’? - This error is occurring at line 51 and it suggests that the identifier jthread is not a recognized type in the std namespace. Instead, it is suggesting that you might have meant to use the thread type.

‘indicator’ was not declared in this scope - This error is occurring at lines 182, 503, 637, and 778. It means that the indicator variable has not been declared or is not in scope at the location where it is being used.

variable or field ‘setupIndicato’ declared void - This error is occurring at line 432 and it means that the setupIndicato variable or field has been declared as having the void type, which is not valid.

‘stop_token’ is not a member of ‘std’ - This error is occurring at line 432 and it means that the stop_token type is not a member of the std namespace.

‘jthread’ is not a member of ‘std’; did you mean ‘thread’? - This error is occurring at lines 639 and 778 and it means that the jthread type is not a member of the std namespace. It is suggesting that you might have meant to use the thread type instead.

‘setupIndicator’ was not declared in this scope - This error is occurring at lines 639, 778, and 778 and it means that the setupIndicator identifier has not been declared or is not in scope at the location where it is being used.

To fix these errors, you will need to review the clipboard.cpp file and make sure that all variables and types are properly declared and in scope, and that you are using the correct types and identifiers. You may also need to check that you have the necessary dependencies and libraries installed on your system in order to build the project successfully.

user@computer:~/hello$ cmake --build .
[ 50%] Building CXX object CMakeFiles/clipboard.dir/src/clipboard.cpp.o
/home/and/hello/Clipboard/src/clipboard.cpp:51:6: error: ‘jthread’ in namespace ‘std’ does not name a type; did you mean ‘thread’?
   51 | std::jthread indicator;
      |      ^~~~~~~
      |      thread
/home/and/hello/Clipboard/src/clipboard.cpp: In lambda function:
/home/and/hello/Clipboard/src/clipboard.cpp:182:9: error: ‘indicator’ was not declared in this scope
  182 |         indicator.request_stop();
      |         ^~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp: At global scope:
/home/and/hello/Clipboard/src/clipboard.cpp:432:26: error: variable or field ‘setupIndicato
’ declared void
  432 | void setupIndicator(std::stop_token st) {
      |                          ^~~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp:432:26: error: ‘stop_token’ is not a member of
std’
/home/and/hello/Clipboard/src/clipboard.cpp: In function ‘void checkItemSize()’:
/home/and/hello/Clipboard/src/clipboard.cpp:503:13: error: ‘indicator’ was not declared in this scope
  503 |             indicator.request_stop();
      |             ^~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp: In function ‘void pasteFiles()’:
/home/and/hello/Clipboard/src/clipboard.cpp:637:25: error: ‘indicator’ was not declared in this scope
  637 |                         indicator.request_stop();
      |                         ^~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp:639:42: error: ‘jthread’ is not a member of ‘st
’; did you mean ‘thread’?
  639 |                         indicator = std::jthread(setupIndicator);
      |                                          ^~~~~~~
      |                                          thread
/home/and/hello/Clipboard/src/clipboard.cpp:639:50: error: ‘setupIndicator’ was not declared in this scope
  639 |                         indicator = std::jthread(setupIndicator);
      |                                                  ^~~~~~~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp: In function ‘int main(int, char**)’:
/home/and/hello/Clipboard/src/clipboard.cpp:778:9: error: ‘indicator’ was not declared in this scope
  778 |         indicator = std::jthread(setupIndicator);
      |         ^~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp:778:26: error: ‘jthread’ is not a member of ‘st
’; did you mean ‘thread’?
  778 |         indicator = std::jthread(setupIndicator);
      |                          ^~~~~~~
      |                          thread
/home/and/hello/Clipboard/src/clipboard.cpp:778:34: error: ‘setupIndicator’ was not declared in this scope
  778 |         indicator = std::jthread(setupIndicator);
      |                                  ^~~~~~~~~~~~~~
/home/and/hello/Clipboard/src/clipboard.cpp:799:9: error: ‘indicator’ was not declared in this scope
  799 |         indicator.request_stop();
      |         ^~~~~~~~~
make[2]: *** [CMakeFiles/clipboard.dir/build.make:76: CMakeFiles/clipboard.dir/src/clipboard.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/clipboard.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

Option to install with `brew`

Is your feature request related to a problem? Please describe.
I'd like to use familiar way of installing this app

Describe the solution you'd like
brew install clipboard

Describe alternatives you've considered
existing installation methods

Additional context
brew works for both Mac and Linux btw.

aur pkbuild CMAKE_BUILD_TYPE

Not a bug but rather a question, is there any reason why you use CMAKE_BUILD_TYPE set to none instead of MinSizeRel for the AUR package?

Feature Request: PuTTY & similar interoperability

Is your feature request related to a problem? Please describe.
I have absolutely no idea if this is in any way technically possible, but I for one use terminals exclusively through tools such as PuTTY/KiTTY, Tabby and others like it. Clipboard does me little good unless the contents can be shared through the terminal tool I use.

Describe the solution you'd like
Support for the mentioned tools, or a mention in the README that such tools can't be supported due to technical limitations.

Suggestion: shortcuts, like cp and mv

I would like to use some shortcuts:

  • cb mv for moving a file to the clipboard
  • cb cp for copying a file to the clipboard
  • I noticed that cb p works for pasting from the clipboard

These should also appear in the help.

installing via curl method fails on nixos

when i curled the script to install clipboard, there were some errors. first it couldn't find unzip and also, it tries to install clipboard to /usr/bin/ which has nothing but env on nixos. everything is on /run/current-system/sw/ that has bin, etc, lib, share and etc. because of this i also got No such file or directory errors. i could make a PR to fix this problem, or you could just make a nix flake for clipboard.

also the nixos pkg version of clipboard has been removed for some reason

Bug: Errors while running cmake build on macOS

Describe the bug
Running cmake build (with or without sudo) produces a list of errors on macOS 12.6.1 Monterey

Additional context
`/Users//personal/Clipboard/src/clipboard.cpp:51:6: error: no type named 'jthread' in namespace 'std'; did you mean 'thread'?
std::jthread indicator;

     thread
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/thread:220:24: note: 'thread' declared here
class _LIBCPP_TYPE_VIS thread
                       ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:182:19: error: no member named 'request_stop' in 'std::thread'
        indicator.request_stop();
        ~~~~~~~~~ ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:432:26: error: no type named 'stop_token' in namespace 'std'
void setupIndicator(std::stop_token st) {
                    ~~~~~^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:503:23: error: no member named 'request_stop' in 'std::thread'
            indicator.request_stop();
            ~~~~~~~~~ ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:637:35: error: no member named 'request_stop' in 'std::thread'
                        indicator.request_stop();
                        ~~~~~~~~~ ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:639:42: error: no member named 'jthread' in namespace 'std'
                        indicator = std::jthread(setupIndicator);
                                    ~~~~~^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:778:26: error: no member named 'jthread' in namespace 'std'
        indicator = std::jthread(setupIndicator);
                    ~~~~~^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:786:19: error: no member named 'request_stop' in 'std::thread'
        indicator.request_stop();
        ~~~~~~~~~ ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:799:19: error: no member named 'request_stop' in 'std::thread'
        indicator.request_stop();
        ~~~~~~~~~ ^
In file included from /Users/<user>/personal/Clipboard/src/clipboard.cpp:3:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/filesystem:251:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/locale:192:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__locale:18:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/mutex:190:
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:431:12: error: invalid argument type 'void' to unary expression
    while (!__pred())
           ^~~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:442:62)>' requested here
    return wait_until(__lk, chrono::steady_clock::now() + __d,
           ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:442:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:442:62)>' requested here
            cv.wait_for(lock, std::chrono::milliseconds(50), [&]{ return st.stop_requested(); });
               ^
In file included from /Users/<user>/personal/Clipboard/src/clipboard.cpp:3:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/filesystem:251:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/locale:192:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__locale:18:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/mutex:190:
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:431:12: error: invalid argument type 'void' to unary expression
    while (!__pred())
           ^~~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:448:62)>' requested here
    return wait_until(__lk, chrono::steady_clock::now() + __d,
           ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:448:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:448:62)>' requested here
            cv.wait_for(lock, std::chrono::milliseconds(50), [&]{ return st.stop_requested(); });
               ^
In file included from /Users/<user>/personal/Clipboard/src/clipboard.cpp:3:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/filesystem:251:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/locale:192:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__locale:18:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/mutex:190:
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:431:12: error: invalid argument type 'void' to unary expression
    while (!__pred())
           ^~~~~~~~~
/Library/Developer/CommandLineTools/SDKs/MacOSX13.0.sdk/usr/include/c++/v1/__mutex_base:477:12: note: in instantiation of function template specialization 'std::condition_variable::wait_until<std::chrono::steady_clock, std::chrono::duration<long long, std::ratio<1, 1000000000>>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:464:62)>' requested here
    return wait_until(__lk, chrono::steady_clock::now() + __d,
           ^
/Users/<user>/personal/Clipboard/src/clipboard.cpp:464:16: note: in instantiation of function template specialization 'std::condition_variable::wait_for<long long, std::ratio<1, 1000>, (lambda at /Users/<user>/personal/Clipboard/src/clipboard.cpp:464:62)>' requested here
            cv.wait_for(lock, std::chrono::milliseconds(50), [&]{ return st.stop_requested(); });
               ^
12 errors generated.
make[2]: *** [CMakeFiles/clipboard.dir/src/clipboard.cpp.o] Error 1
make[1]: *** [CMakeFiles/clipboard.dir/all] Error 2`

Feature Request: man page

Is your feature request related to a problem? Please describe.
clipboard's documentation isn't accessible in standard ways

Describe the solution you'd like
Add a man page (or, if necessary, an info page)

Additional context
If there was a man page (in a standard format), it would be machine readable for tools like https://github.com/nevesnunes/sh-manpage-completions, improving usability for power users and folks with advanced shells and other tools.

Syntax and documentation of the persistent clipboard

The issues below are all related. I'd be happy to put a PR together if you like, but there are some decisions to be made below so I didn't want to do that unless you were interested and had weighed in on the perma_clip syntax, and on the CLIPBOARD_TMPDIR/CLIPBOARD_PERSISTENT subject.

1) Help Text

The help instructions for using the permanent clipboard are incorrect. The built-in help says You can also choose which clipboard you want to use by adding a number to the end, or - to use a permanent clipboard. but the actual syntax is to use one of _:;| (rather than -) per this line in clipboard.cpp:

            clipboard_name = clipboard_name.substr(clipboard_name.find_first_of("_:;|") + 1);

2) Naming (persistent vs permanent)

I think it would also be helpful to harmonize the language in the code with the language in the help/docs, and use persistent (rather than permanent) everywhere, so...

  • Help becomes:
    • You can also choose which clipboard you want to use by adding a number to the end, or one of "_:;|" to use a persestent clipboard.
  • copying.use_perma_clip -> copying.use_persistent_clip
  • filepath.persistent and constants.persistent_directory_name remain as they are

3) Invocation syntax

The invocation syntax in the README.md (and the man.md) does not mention the _:;| syntax for permanent/persistent clipboards. If you really want to support all of _:;| then writing the syntax gets hard because | is usually an OR in command line syntax. If you dropped the | then you could write something like:

Copyclipboard ([--]copy|[-]cp[_|:|;][(id)]) (file) [files]

But that's pretty verbose. I don't know the historical reason for allowing all of _:;|; it seems like selecting and committing to a single character would be more clear and easier to document.

4) [(id)] missing from README.md

The [(id)] parameter appears in the invocation syntax in man.md (and the subsequently generated man.1), but not in the invocation syntax in README.md.

5) TMPDIR

The way the README.md is worded suggests that one might change TMPDIR to change where the temporary clipboards are stored, but my understanding is that TMPDIR is a "system" env var also used by other programs to determine where to store their temp data. I think the wording should reflect that, and that if you really want a way to override Clipboard's (and only Clipboard's) temp location then there should be a new environment var (like CLIPBOARD_TMPDIR) which (if set) would do that.

6) Forcing Persistent

The reason I uncovered all of the above was because I just wanted all my clipboard data to always go to ~/.clipboard/ (i.e. the persistent clipboard) and I couldn't find a way to do that. Changing TMPDIR is inappropriate, and remembering to type one of _:;| is cumbersome. In the end I just hacked my local version to always use perma_clip.

It would be nice to have either a CLIPBOARD_TMPDIR env var that could override (just Clipboard's) temp dir, or alternatively a CLIPBOARD_PERSISTENT env var that, if set, would force perma_clip.

My local hack looks like this:
always_perma

Thanks for putting this tool together; I'm glad to have it in my back pocket!
Cheers!

Error message when copying data to system clipboard

Describe the bug
I'm getting an error message when copying data to the system clipboard

To Reproduce

cb --copy < files.txt

Error:
xdg_surface@7: error 3: xdg_surface has never been configured (Wayland)
error: XDG_RUNTIME_DIR is invalid or not set in the environment (X)

Expected behavior
No error messages

Additional context
Running on Arch, i3 and xterm (for X), and sway and foot (for Wayland)

Further discussion: leo-arch/clifm#188

Clipboard isn't perfect

This isn't an issue with Clipboard, but rather one of humans in general.

Consider this. If you look at some repo, your eyes might look at the number of Issues and Pull Requests first. If you then notice that this repo has zero issues and zero PRs, what do you assume? There are two potential cases here. The first is where most/all issues get quickly resolved and PRs get quickly resolved too. The second is where nobody has bothered to make any issues or PRs because nobody is using the project. Us humans tend to default to the second option.

Unfortunately, Clipboard falls into the first case. Most issues are quick fixes, some aren't actually issues with Clipboard but rather some underlying standard (so we can't fix them), and the rest do take more effort to fix. The end result of this is few to no issues or PRs, which gives false credence to the second case.

So, the purpose of this issue is to inform you of this psychological phenomenon and to keep at least one open issue in the queue.

Calculations seem wrong when the clipboard is not empty

Describe the bug
When the clipboard is not empty, the output says it copied an amount of bytes equals to the length of the existing content + the new content.

To Reproduce
Steps to reproduce the behavior:

[bendem@kwak lib]$ clipboard clear
• There is currently nothing in the clipboard.
[bendem@kwak lib]$ clipboard cp0 <<< hi
✓ Copied 3 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 12 bytes                            
[bendem@kwak lib]$ clipboard clear
✓ Cleared 9 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 9 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 18 bytes

Expected behavior

[bendem@kwak lib]$ clipboard clear
• There is currently nothing in the clipboard.
[bendem@kwak lib]$ clipboard cp0 <<< hi
✓ Copied 3 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 9 bytes                            
[bendem@kwak lib]$ clipboard clear
✓ Cleared 9 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 9 bytes                            
[bendem@kwak lib]$ clipboard cp0 <<< 'hi there'
✓ Copied 9 bytes

Additional context
This is the latest release, which I just unzipped on fedora 36.

Build fails on Debian GNU/Linux 11 (bullseye) with GCC 10

Describe the bug
Build fails on Debian GNU/Linux 11 (bullseye) with GCC 10.

To Reproduce
Steps to reproduce the behavior:

  1. Use a machine with Debian GNU/Linux 11 (bullseye)
  2. clone the repo
  3. follow the build instructions (cd build; cmake ..; cmake --build .)

Expected behavior
Build successful.

Screenshots
None

Additional context

  • gcc (Debian 10.2.1-6) 10.2.1 20210110
  • cmake version 3.18.4
  • i686
  • branch: main (but latest release 0.3.2 fails too)

Console log part 1:

alex@falbala ~/build/Clipboard % cmake ../../src/Clipboard
-- The CXX compiler identification is GNU 10.2.1
-- The C compiler identification is GNU 10.2.1
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Looking for fork
-- Looking for fork - found
-- Could NOT find X11 (missing: X11_X11_INCLUDE_PATH X11_X11_LIB)
-- Building Clipboard without X11 support
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.2")
-- Checking for modules 'wayland-client;wayland-protocols'
--   No package 'wayland-client' found
--   No package 'wayland-protocols' found
-- Building Clipboard without Wayland support
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - yes
-- Found Threads: TRUE
-- Configuring done
-- Generating done
-- Build files have been written to: /home/alex/build/Clipboard

Console log part 2:

[ 66%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/clipboard.cpp.o
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘bool isAWriteAction()’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:142:11: error: expected nested-name-specifier before ‘enum’
  142 |     using enum Action;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:143:22: error: ‘Paste’ was not declared in this scope; did you mean ‘Action::Paste’?
  143 |     return action != Paste && action != Show;
      |                      ^~~~~
      |                      Action::Paste
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:47: note: ‘Action::Paste’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                               ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:143:41: error: ‘Show’ was not declared in this scope; did you mean ‘Action::Show’?
  143 |     return action != Paste && action != Show;
      |                                         ^~~~
      |                                         Action::Show
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:61: note: ‘Action::Show’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                             ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘CopyPolicy userDecision(const string&)’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:147:11: error: expected nested-name-specifier before ‘enum’
  147 |     using enum CopyPolicy;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:149:32: error: ‘ReplaceAll’ was not declared in this scope; did you mean ‘CopyPolicy::ReplaceAll’?
  149 |     if (userIsARobot()) return ReplaceAll;
      |                                ^~~~~~~~~~
      |                                CopyPolicy::ReplaceAll
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:42:25: note: ‘CopyPolicy::ReplaceAll’ declared here
   42 | enum class CopyPolicy { ReplaceAll, ReplaceOnce, SkipOnce, SkipAll, Unknown };
      |                         ^~~~~~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:158:20: error: ‘ReplaceOnce’ was not declared in this scope; did you mean ‘CopyPolicy::ReplaceOnce’?
  158 |             return ReplaceOnce;
      |                    ^~~~~~~~~~~
      |                    CopyPolicy::ReplaceOnce
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:42:37: note: ‘CopyPolicy::ReplaceOnce’ declared here
   42 | enum class CopyPolicy { ReplaceAll, ReplaceOnce, SkipOnce, SkipAll, Unknown };
      |                                     ^~~~~~~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:160:20: error: ‘ReplaceAll’ was not declared in this scope; did you mean ‘CopyPolicy::ReplaceAll’?
  160 |             return ReplaceAll;
      |                    ^~~~~~~~~~
      |                    CopyPolicy::ReplaceAll
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:42:25: note: ‘CopyPolicy::ReplaceAll’ declared here
   42 | enum class CopyPolicy { ReplaceAll, ReplaceOnce, SkipOnce, SkipAll, Unknown };
      |                         ^~~~~~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:162:20: error: ‘SkipOnce’ was not declared in this scope; did you mean ‘CopyPolicy::SkipOnce’?
  162 |             return SkipOnce;
      |                    ^~~~~~~~
      |                    CopyPolicy::SkipOnce
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:42:50: note: ‘CopyPolicy::SkipOnce’ declared here
   42 | enum class CopyPolicy { ReplaceAll, ReplaceOnce, SkipOnce, SkipAll, Unknown };
      |                                                  ^~~~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:164:20: error: ‘SkipAll’ was not declared in this scope; did you mean ‘CopyPolicy::SkipAll’?
  164 |             return SkipAll;
      |                    ^~~~~~~
      |                    CopyPolicy::SkipAll
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:42:60: note: ‘CopyPolicy::SkipAll’ declared here
   42 | enum class CopyPolicy { ReplaceAll, ReplaceOnce, SkipOnce, SkipAll, Unknown };
      |                                                            ^~~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘void clearTempDirectory(bool)’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:373:11: error: expected nested-name-specifier before ‘enum’
  373 |     using enum Action;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:374:34: error: ‘Cut’ was not declared in this scope
  374 |     if (force_clear || action == Cut || action == Copy) {
      |                                  ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:374:34: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:36: note:   ‘Action::Cut’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                    ^~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:41: note:   ‘ClipboardPathsAction::Cut’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:374:51: error: ‘Copy’ was not declared in this scope
  374 |     if (force_clear || action == Cut || action == Copy) {
      |                                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:374:51: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:41: note:   ‘Action::Copy’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                         ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:35: note:   ‘ClipboardPathsAction::Copy’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:376:23: error: ‘Clear’ was not declared in this scope; did you mean ‘Action::Clear’?
  376 |         if (action == Clear && fs::is_regular_file(path.data)) {
      |                       ^~~~~
      |                       Action::Clear
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:54: note: ‘Action::Clear’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                      ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:382:27: error: ‘Clear’ was not declared in this scope; did you mean ‘Action::Clear’?
  382 |             if (action == Clear) {
      |                           ^~~~~
      |                           Action::Clear
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:54: note: ‘Action::Clear’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                      ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘void syncWithGUIClipboard(bool)’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:545:15: error: expected nested-name-specifier before ‘enum’
  545 |         using enum ClipboardContentType;
      |               ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:547:31: error: ‘Text’ was not declared in this scope
  547 |         if (content.type() == Text)
      |                               ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:547:31: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:48: note:   ‘IOType::Text’
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                                ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:42:42: note:   ‘ClipboardContentType::Text’
   42 | enum class ClipboardContentType { Empty, Text, Paths };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:549:36: error: ‘Paths’ was not declared in this scope; did you mean ‘ClipboardContentType::Paths’?
  549 |         else if (content.type() == Paths)
      |                                    ^~~~~
      |                                    ClipboardContentType::Paths
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:42:48: note: ‘ClipboardContentType::Paths’ declared here
   42 | enum class ClipboardContentType { Empty, Text, Paths };
      |                                                ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘Action getAction()’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:641:11: error: expected nested-name-specifier before ‘enum’
  641 |     using enum Action;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:642:11: error: expected nested-name-specifier before ‘enum’
  642 |     using enum IOType;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:35: error: ‘Cut’ was not declared in this scope
  644 |         for (const auto& entry : {Cut, Copy, Add, Remove}) {
      |                                   ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:35: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:36: note:   ‘Action::Cut’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                    ^~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:41: note:   ‘ClipboardPathsAction::Cut’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:40: error: ‘Copy’ was not declared in this scope
  644 |         for (const auto& entry : {Cut, Copy, Add, Remove}) {
      |                                        ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:40: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:41: note:   ‘Action::Copy’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                         ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:35: note:   ‘ClipboardPathsAction::Copy’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:46: error: ‘Add’ was not declared in this scope; did you mean ‘Action::Add’?
  644 |         for (const auto& entry : {Cut, Copy, Add, Remove}) {
      |                                              ^~~
      |                                              Action::Add
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:73: note: ‘Action::Add’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:51: error: ‘Remove’ was not declared in this scope; did you mean ‘Action::Remove’?
  644 |         for (const auto& entry : {Cut, Copy, Add, Remove}) {
      |                                                   ^~~~~~
      |                                                   Action::Remove
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:78: note: ‘Action::Remove’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                              ^~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:644:57: error: unable to deduce ‘std::initializer_list<auto>&&’ from ‘{<expression error>, <expression error>, <expression error>, <expression error>}’
  644 |         for (const auto& entry : {Cut, Copy, Add, Remove}) {
      |                                                         ^
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:646:43: error: ‘Pipe’ was not declared in this scope; did you mean ‘IOType::Pipe’?
  646 |                 if (!is_tty.in) io_type = Pipe;
      |                                           ^~~~
      |                                           IOType::Pipe
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:42: note: ‘IOType::Pipe’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:650:35: error: ‘Paste’ was not declared in this scope; did you mean ‘Action::Paste’?
  650 |         for (const auto& entry : {Paste, Show, Clear, Edit}) {
      |                                   ^~~~~
      |                                   Action::Paste
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:47: note: ‘Action::Paste’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                               ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:650:42: error: ‘Show’ was not declared in this scope; did you mean ‘Action::Show’?
  650 |         for (const auto& entry : {Paste, Show, Clear, Edit}) {
      |                                          ^~~~
      |                                          Action::Show
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:61: note: ‘Action::Show’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                             ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:650:48: error: ‘Clear’ was not declared in this scope; did you mean ‘Action::Clear’?
  650 |         for (const auto& entry : {Paste, Show, Clear, Edit}) {
      |                                                ^~~~~
      |                                                Action::Clear
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:54: note: ‘Action::Clear’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                      ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:650:55: error: ‘Edit’ was not declared in this scope; did you mean ‘Action::Edit’?
  650 |         for (const auto& entry : {Paste, Show, Clear, Edit}) {
      |                                                       ^~~~
      |                                                       Action::Edit
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:67: note: ‘Action::Edit’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:650:59: error: unable to deduce ‘std::initializer_list<auto>&&’ from ‘{<expression error>, <expression error>, <expression error>, <expression error>}’
  650 |         for (const auto& entry : {Paste, Show, Clear, Edit}) {
      |                                                           ^
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:652:44: error: ‘Pipe’ was not declared in this scope; did you mean ‘IOType::Pipe’?
  652 |                 if (!is_tty.out) io_type = Pipe;
      |                                            ^~~~
      |                                            IOType::Pipe
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:42: note: ‘IOType::Pipe’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:659:19: error: ‘Pipe’ was not declared in this scope; did you mean ‘IOType::Pipe’?
  659 |         io_type = Pipe;
      |                   ^~~~
      |                   IOType::Pipe
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:42: note: ‘IOType::Pipe’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:660:16: error: ‘Copy’ was not declared in this scope
  660 |         return Copy;
      |                ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:660:16: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:41: note:   ‘Action::Copy’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                         ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:35: note:   ‘ClipboardPathsAction::Copy’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:662:19: error: ‘Pipe’ was not declared in this scope; did you mean ‘IOType::Pipe’?
  662 |         io_type = Pipe;
      |                   ^~~~
      |                   IOType::Pipe
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:42: note: ‘IOType::Pipe’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:663:16: error: ‘Paste’ was not declared in this scope; did you mean ‘Action::Paste’?
  663 |         return Paste;
      |                ^~~~~
      |                Action::Paste
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:47: note: ‘Action::Paste’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                               ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp: In function ‘void performAction()’:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:811:11: error: expected nested-name-specifier before ‘enum’
  811 |     using enum IOType;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:812:11: error: expected nested-name-specifier before ‘enum’
  812 |     using enum Action;
      |           ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:814:20: error: ‘File’ was not declared in this scope; did you mean ‘IOType::File’?
  814 |     if (io_type == File) {
      |                    ^~~~
      |                    IOType::File
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:36: note: ‘IOType::File’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                    ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:816:14: error: ‘Copy’ was not declared in this scope
  816 |         case Copy:
      |              ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:816:14: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:41: note:   ‘Action::Copy’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                         ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:35: note:   ‘ClipboardPathsAction::Copy’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:817:14: error: ‘Cut’ was not declared in this scope
  817 |         case Cut:
      |              ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:817:14: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:36: note:   ‘Action::Cut’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                    ^~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:41: note:   ‘ClipboardPathsAction::Cut’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:820:14: error: ‘Paste’ was not declared in this scope; did you mean ‘Action::Paste’?
  820 |         case Paste:
      |              ^~~~~
      |              Action::Paste
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:47: note: ‘Action::Paste’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                               ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:823:14: error: ‘Clear’ was not declared in this scope; did you mean ‘Action::Clear’?
  823 |         case Clear:
      |              ^~~~~
      |              Action::Clear
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:54: note: ‘Action::Clear’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                      ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:826:14: error: ‘Show’ was not declared in this scope; did you mean ‘Action::Show’?
  826 |         case Show:
      |              ^~~~
      |              Action::Show
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:61: note: ‘Action::Show’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                             ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:829:14: error: ‘Edit’ was not declared in this scope; did you mean ‘Action::Edit’?
  829 |         case Edit:
      |              ^~~~
      |              Action::Edit
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:67: note: ‘Action::Edit’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:832:14: error: ‘Add’ was not declared in this scope; did you mean ‘Action::Add’?
  832 |         case Add:
      |              ^~~
      |              Action::Add
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:73: note: ‘Action::Add’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:835:14: error: ‘Remove’ was not declared in this scope; did you mean ‘Action::Remove’?
  835 |         case Remove:
      |              ^~~~~~
      |              Action::Remove
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:78: note: ‘Action::Remove’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                              ^~~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:839:27: error: ‘Pipe’ was not declared in this scope; did you mean ‘IOType::Pipe’?
  839 |     } else if (io_type == Pipe) {
      |                           ^~~~
      |                           IOType::Pipe
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:96:42: note: ‘IOType::Pipe’ declared here
   96 | enum class IOType : unsigned int { File, Pipe, Text };
      |                                          ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:841:14: error: ‘Copy’ was not declared in this scope
  841 |         case Copy:
      |              ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:841:14: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:41: note:   ‘Action::Copy’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                         ^~~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:35: note:   ‘ClipboardPathsAction::Copy’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:842:14: error: ‘Cut’ was not declared in this scope
  842 |         case Cut:
      |              ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:842:14: note: suggested alternatives:
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:36: note:   ‘Action::Cut’
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                    ^~~
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:26,
                 from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/gui/include/all/clipboard/gui.hpp:25:41: note:   ‘ClipboardPathsAction::Cut’
   25 | enum class ClipboardPathsAction { Copy, Cut };
      |                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:845:14: error: ‘Paste’ was not declared in this scope; did you mean ‘Action::Paste’?
  845 |         case Paste:
      |              ^~~~~
      |              Action::Paste
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:47: note: ‘Action::Paste’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                               ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:848:14: error: ‘Clear’ was not declared in this scope; did you mean ‘Action::Clear’?
  848 |         case Clear:
      |              ^~~~~
      |              Action::Clear
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:54: note: ‘Action::Clear’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                      ^~~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:849:14: error: ‘Show’ was not declared in this scope; did you mean ‘Action::Show’?
  849 |         case Show:
      |              ^~~~
      |              Action::Show
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:61: note: ‘Action::Show’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                             ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:850:14: error: ‘Edit’ was not declared in this scope; did you mean ‘Action::Edit’?
  850 |         case Edit:
      |              ^~~~
      |              Action::Edit
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:67: note: ‘Action::Edit’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                   ^~~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:851:14: error: ‘Add’ was not declared in this scope; did you mean ‘Action::Add’?
  851 |         case Add:
      |              ^~~
      |              Action::Add
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:73: note: ‘Action::Add’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                         ^~~
/home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:853:14: error: ‘Remove’ was not declared in this scope; did you mean ‘Action::Remove’?
  853 |         case Remove:
      |              ^~~~~~
      |              Action::Remove
In file included from /home/alex/src/Clipboard/src/clipboard/src/clipboard.cpp:15:
/home/alex/src/Clipboard/src/clipboard/src/clipboard.hpp:94:78: note: ‘Action::Remove’ declared here
   94 | enum class Action : unsigned int { Cut, Copy, Paste, Clear, Show, Edit, Add, Remove, Note };
      |                                                                              ^~~~~~
gmake[2]: *** [src/clipboard/CMakeFiles/clipboard.dir/build.make:82: src/clipboard/CMakeFiles/clipboard.dir/src/clipboard.cpp.o] Fehler 1
gmake[1]: *** [CMakeFiles/Makefile2:161: src/clipboard/CMakeFiles/clipboard.dir/all] Fehler 2
gmake: *** [Makefile:149: all] Fehler 2

If you need any more information, drop me a note.

Feature request: easier installation

TL;DR: I would like to install this in one command, not like 10.

Right now the way to install this project is:

command -v cmake || sudo apt install cmake

temp_dir="$(mktemp -d)"
pushd "$temp_dir"

# https://github.com/Slackadays/Clipboard#clone-configure--compile
git clone https://github.com/slackadays/Clipboard
cd Clipboard
cmake .
cmake --build .
# https://github.com/Slackadays/Clipboard#install
sudo cmake --install .

popd
rm -rf "$temp_dir"

And that was after a full 5 minutes of head scratching before I saw the "Install" section as separate from the "Clone, configure, & compile" section and realized "OHHH I need to do the --install one too!"

Instead, I'd like to see one of these:

sudo apt install clipboard # Or whatever name
curl -sS https://webi.sh/clipboard | sh # webinstall.dev for more info
curl -sSL https://github.com/Slackadays/Clipboard/raw/main/install.sh | bash # Or a branded shortlink

And of course the Windows counterpart might be using choco or Invoke-WebRequest | powershell or whatever.

Why this would be a good feature

Any good product makes it as easy as possible to onboard. You want to reduce the friction of your users getting started in order to make it "this is easy, so I might as well try it" or "its cheap to set up, so I'll try it!". The point is to make it really really easy. I think the current state is a bit challenging for someone who doesn't dive into the C++ ecosystem very much, but wants to use this as a CLI tool.

TL;DR: Make it more accessible!

Suggestion for a readme section on "Installation"

image

But I understand if the design text or whatever gets changed. The point is that its much easier for a user to copy-paste something like that than it is to think:

  1. Do I have cmake installed?
  2. How do I install cmake?
  3. Is this worth it for a tool I just wanted to copy a git log output?
  4. Ok now I need a temp folder to clone this into
  5. What were the commands again to build it?
  6. How do I get the binary onto my $PATH?

Alternative solutions

Besides putting it all in an install.sh or install.ps1 script, you could also host that script through the https://webinstall.dev/ project. Another option is to use the system package manager. I have absolutely no clue how to get involved with either of these; they're just ideas.

The simplest starting point, though, seems to be the self-hosted install.sh or install.ps1. You can even make it shorter with something like https://t.ly/

Clipboard don't see file copied from KDE/Dolphin

Describe the bug
When copying file from KDE's file manager Dolphin (Qt application), cb don't see clipboard content. On Linux with X11.
This doesn't reproduce with Gnome File Manager -- nautilus. In this case cb shows copied file.

But clipboard isn't broken, because when I press Ctrl+V in Telegram -- it shows dialog of attaching (copied) file to the message.

To Reproduce
Steps to reproduce the behavior:

  1. Open dolphin file manger
  2. Copy regular file
  3. run in terminal cb
[winnie@bm-linux-nitro517 ~]$ cb
• There is currently nothing in the clipboard.
Add cut, copy, or paste to the end, like clipboard copy to get started, or if you need help, try clipboard -h to show the help screen.

Expected behavior
Shows copied file, like: file:///home/winnie/.local/share/applications/Hardspace Shipbreaker.desktop

Screenshots
image

But clipboard content can be viewed in CopyQ app:
image

Additional context
Add any other context about the problem here.

Answer these questions so that we can help you faster:

  • If I compiled Clipboard myself, then the errors don't mention "LTO error" (this is a bug with the compiler, not Clipboard)
  • If I compiled Clipboard myself, then the errors don't mention "XYZ has not been defined in namespace std" (this usually means you need a compiler with C++20 support, so upgrade first)
  • I check these boxes without reading them (checking this one will make your bug report invalid!)
  • I am using the latest commit/release (we only support the latest)
  • If I downloaded Clipboard from GitHub Actions or with the install script, then the errors don't mention "GLIBC XYZ not found" (your system is too outdated for Clipboard, so upgrade it)

I don't know what about compilation errors? I've downloaded binary clipboard-0.4.0-amd64.zip from https://github.com/Slackadays/Clipboard/releases/download/0.4.0/clipboard-linux-arm64.zip (using AUR package). And I'm not using Git's main branch, but latest RELEASED version.

But just to be double-check I've built from sources from `main` branch:
-- Build files have been written to: /home/winnie/.cache/yay/clipboard-git/src/build
[  2%] Building CXX object src/gui/CMakeFiles/gui.dir/src/fork.cpp.o
[  5%] Generating generated/include/wayland-xdg-shell.hpp
[  5%] Built target clipboardwayland_generatedheaders
[  8%] Building CXX object src/gui/CMakeFiles/gui.dir/src/gui.cpp.o
[ 11%] Building CXX object src/gui/CMakeFiles/gui.dir/src/utils.cpp.o
[ 14%] Building CXX object src/gui/CMakeFiles/gui.dir/src/infermime.cpp.o
[ 17%] Building CXX object src/gui/CMakeFiles/gui.dir/src/posix/mime.cpp.o
[ 20%] Linking CXX static library ../../libgui.a
[ 20%] Built target gui
[ 22%] Generating generated/src/wayland-xdg-shell.c
[ 25%] Building CXX object src/clipboardx11/CMakeFiles/clipboardx11.dir/src/x11.cpp.o
[ 28%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/fd.cpp.o
[ 31%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/wayland.cpp.o
[ 34%] Linking CXX shared module ../../libclipboardx11.so
[ 37%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/buffer.cpp.o
[ 37%] Built target clipboardx11
[ 40%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/clipboard.cpp.o
[ 42%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/callback.cpp.o
[ 45%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/data_device.cpp.o
[ 48%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/actions.cpp.o
[ 51%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/data_offer.cpp.o
[ 54%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/data_source.cpp.o
[ 57%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/messages.cpp.o
[ 60%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/themes.cpp.o
[ 62%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/display.cpp.o
[ 65%] Building CXX object src/clipboard/CMakeFiles/clipboard.dir/src/posix.cpp.o
[ 68%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/keyboard.cpp.o
[ 71%] Linking CXX executable ../../clipboard
[ 74%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/registry.cpp.o
[ 77%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/seat.cpp.o
[ 80%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/shm.cpp.o
[ 80%] Built target clipboard
[ 82%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/shm_pool.cpp.o
[ 85%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/surface.cpp.o
[ 88%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/xdg_surface.cpp.o
[ 91%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/xdg_toplevel.cpp.o
[ 94%] Building CXX object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/src/objects/xdg_wm_base.cpp.o
[ 97%] Building C object src/clipboardwayland/CMakeFiles/clipboardwayland.dir/generated/src/wayland-xdg-shell.c.o
[100%] Linking CXX shared module ../../libclipboardwayland.so
[100%] Built target clipboardwayland

P.S. Recompilation from sources didn't resolved an issue.

System Specs

OS: Manjaro Linux
Installed version: 0.4.0 -- latest released
Display server: X11
DE: KDE Plasma 5.26.5

cb clr doesn't work on mac

Describe the bug
It appears that cb clr does not work on an M1 mac running 13.2.

To Reproduce
Steps to reproduce the behavior:

  1. echo "foo" | cb
✓ Copied 4 bytes
  1. cb
• There are items in these clipboards:
▏ 0: foo
  1. cb clr
✓ Cleared the clipboard... 0%
  1. cb
• There are items in these clipboards:
▏ 0: foo

Expected behavior
I expect there to be zero items in the clipboard.

Screenshots
Screenshot 2023-02-15 at 8 30 59 PM

clipboard can paste but not copy

Describe the bug
cb appears to not copy anything itself (whether via pipe or cmdline arg) on my system. Its clipboard seems to hold only what is pasted by other means.

I am tempted to wonder if I'm misusing cb in some way, but I've gone through the README a couple of times.

To Reproduce
Steps to reproduce the behavior:

❯ cb clear
✓ Cleared the clipboard
❯ echo 'not README!' | wl-copy [ensure something's already on the clipboard]
❯ cb copy README.md
✓ Copied README.md                        
❯ cb show
• Here are the first 1 items in clipboard 0: 
▏ clipboard.txt 
❯ cat clipboard.txt
not README!

I get the same result via pipe, eg. echo "something" | cb

Expected behavior
In the above interactive sequence, I would have expected cb show to show that I had copied the file README.txt. It instead shows a 'clipboard.txt' file which contains whatever was already on the clipboard from other sources.

Additional context
This is on Fedora 37, with Gnome 43.2 and Wayland. Installed clipboard with the install.sh script

Windows installation won't work without Cmake, users should not have to build from source

Is your feature request related to a problem? Please describe.
Windows installation instructions very unclear, overly complicated, error out when cmake is not installed (which is the case for most users)

Describe the solution you'd like
The installation instructions in the README.md file should be to download the already built artifact for windows, and install it to somewhere in the user's $PATH

Describe alternatives you've considered
Either install.ps1 needs to be replaced, or there needs to be a better alternative that doesn't build from source (just download the artifact) in the readme

Additional context
See further notes about this process that I wrote here in #44
I'll be happy to write up a pull request for this feature if you're interested (should be pretty straight forward), if so let me know

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.