Commit graph

97 commits

Author SHA1 Message Date
Chris Down 60611584ec Remove unused last_filename 2017-05-30 09:06:04 +01:00
Chris Down f0d09c7692 Use $TMPDIR as base for cache directory
Closes #38.
2017-05-30 09:03:35 +01:00
Chris Down e5508e84c5 systemd service: Don't restrict to only /tmp
People might set $TMPDIR and this doesn't buy us much.
2017-05-30 09:02:58 +01:00
Chris Down caa009b222 Remove partial clip dedupe support
The application that was particularly bad at this (Chrome) now no longer
does this, and this is basically a hack that has lasted too long.

Also closes #41 and closes #42 since the questionable "feature" is going
away.
2017-05-30 08:58:19 +01:00
Chris Down f184c37994 Add a note about using CM_ONESHOT, per #47 2017-05-30 08:55:27 +01:00
Chris Down e7a15a5d50 Do not sleep initially in oneshot mode 2017-05-10 10:05:16 +01:00
Chris Down 3ab7a6e2e7 Merge branch 'release/3.2.0' 2017-03-19 10:06:35 +00:00
Chris Down 33b0e13404 Test CM_LAUNCHER 2017-03-19 09:54:56 +00:00
Chris Down 7d9c46a370 Pass args in dmenu/rofi shims 2017-03-19 09:54:47 +00:00
Chris Down 92d584e4b3 Use a function insted of an alias for dmenu shim 2017-03-19 09:48:55 +00:00
Chris Down 1b4fcd5b8d Add demo GIF 2017-03-19 09:43:39 +00:00
Chris Down e315d8262c Forcibly add -dmenu if using rofi as $CM_LAUNCHER 2017-03-19 08:00:27 +00:00
Chris Down 497ba9c95c Mention rofi in readme 2017-03-19 07:55:57 +00:00
Chris Down abe461461b Add clipmenu --help 2017-03-19 07:53:51 +00:00
Chris Down e65b51b33c Use CM_* env vars 2017-03-19 07:53:26 +00:00
Chris Down 117385015b Add $CM_LAUNCHER env variable 2017-03-19 07:40:19 +00:00
Chris Down eecc031718 Use stderr for xsel logging when detached 2017-03-19 07:38:34 +00:00
Chris Down 19569a81bc Log new clipboard entries without $DEBUG 2017-03-19 07:34:29 +00:00
Chris Down 99a49211d9 Merge branch 'release/3.1.0' 2017-03-17 01:20:23 +00:00
Chris Down 28d8db8860 clipmenud: Time out all calls to xsel after 1 second
I'm not entirely sure how this happens, but sometimes xsel gets rather
stuck:

    % systemctl --user status clipmenud
    ● clipmenud.service - Clipmenu daemon
       Loaded: loaded (/usr/lib/systemd/user/clipmenud.service; disabled; vendor preset: enabled)
       Active: active (running) since Wed 2017-03-15 11:14:14 GMT; 1 day 13h ago
     Main PID: 31630 (clipmenud)
       CGroup: /user.slice/user-1000.slice/user@1000.service/clipmenud.service
               ├─ 9052 /bin/bash /usr/bin/clipmenud
               ├─ 9053 xsel --logfile /dev/null -o --primary
               └─31630 /bin/bash /usr/bin/clipmenud

    Mar 15 11:14:14 gongzuo systemd[474]: Started Clipmenu daemon.
    % strace -p 9053
    strace: Process 9053 attached
    restart_syscall(<... resuming interrupted restart_syscall ...>^Cstrace: Process 9053 detached
     <detached ...>
    % ps aux | grep 9053
    cdown     9053  0.0  0.0  15956   896 ?        S    Mar15   0:00 xsel --logfile /dev/null -o --primary
2017-03-17 01:18:43 +00:00
Chris Down d8dbb1d5af Use wrapper for xsel to avoid having to pass --logfile again and again 2017-03-17 01:18:43 +00:00
drake-on-mandrake 6facea933b Add --logfile /dev/null to the xsel command 2017-03-09 14:48:16 +00:00
Chris Down db05c51942 Add oneshot mode support
Fixes #27.
2017-02-17 20:45:06 -05:00
Chris Down b839f80779 Add locking support
This is a prerequisite for adding oneshot mode, see #27.
2017-02-17 20:42:29 -05:00
Chris Down 0b58a886a6 Merge branch 'release/3.0.1' 2017-02-17 14:06:44 -05:00
Chris Down 7367a8fc4b Do not filter syscalls in systemd init
Since we don't write the applications we use, this is liable to break
pretty easily for new/older versions than tested on. The other
protections should be sufficient.
2017-02-17 14:05:24 -05:00
Chris Down d938354148 Merge branch 'release/3.0.0' 2017-02-17 12:07:05 -05:00
Chris Down 9a5174123e Remove old version file, we now use versioned dirs 2017-02-17 12:06:10 -05:00
Chris Down 00e221559e Set -x in test-clipmenu 2017-02-17 12:03:02 -05:00
Chris Down 2acece7dce Put $major_version in cache_dir to avoid upgrade incompatibility 2017-02-17 12:01:42 -05:00
Chris Down 683f57484f Remove xclip support
Pretty much everyone runs with xsel, so xclip support is becoming more
and more questionable. Just have people use xsel.
2017-02-17 11:50:52 -05:00
Chris Down 662e31d618 Add systemd unit
Closes #39, #40.
2017-02-17 11:46:04 -05:00
Chris Down e85c7691e2 tests: Add clipmenu test 2017-01-15 10:18:20 +00:00
Chris Down e8b4d83e2e readme: Escape colour codes 2017-01-12 08:34:41 +00:00
Chris Down f7b0ea1c18 Add version to $cache_dir 2017-01-11 11:35:09 +00:00
Chris Down 8c1054ca73 Put vars above functions 2017-01-11 11:33:14 +00:00
Chris Down 533cdc871e Fix parens in README 2017-01-11 11:28:51 +00:00
Chris Down 8b4a047768 Use awk instead of uniq to only keep latest, even if not adjacent 2017-01-07 14:30:55 +00:00
Chris Down 9d5a241f1d Document behaviour in README 2017-01-06 17:50:09 +00:00
Chris Down 09c32b025e Merge branch 'release/2.0.0' 2017-01-06 17:36:01 +00:00
Chris Down 7c713d5673 Merge branch 'perf' into develop 2017-01-06 17:34:13 +00:00
Chris Down fe8ca2e3ca Don't mention non-existing clipmenu-fsck 2017-01-06 17:28:31 +00:00
Chris Down 1daaeda6f3 Remove print_debug_info, this was never very useful 2017-01-06 16:47:29 +00:00
Chris Down 8885306970 perf: Don't use date, use CRC instead
We don't need to sort by date now that we record in $cache_file, which
does it naturally for us.
2017-01-06 14:53:59 +00:00
Chris Down 6edf3c437b perf: Add naive but performant path 2017-01-06 14:04:37 +00:00
Chris Down f0fe96955a perf: Don't use printf with ordered_selections
printf is really, really slow with large arrays of strings. Switching to
this results in about a 50% performance improvement.
2017-01-06 12:52:34 +00:00
Chris Down e8ba60e432 Have clipmenud cache first lines 2017-01-06 12:05:36 +00:00
Chris Down 7987dd1757 Add test-perf script 2017-01-06 12:05:36 +00:00
kesha-on-disc 892fe73110 Add --logfile /dev/null to xsel commands 2016-11-30 09:11:10 +01:00
Chris Down 2ab5b5b502 Only take ownership of clipboard if we would not skip this clip
Fixes #34, an issue with pcmanfm GUI file copy/paste.
2016-11-09 11:38:41 +00:00