Commit graph

73 commits

Author SHA1 Message Date
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
Chris Down 9efd96b405 blank check: Use [:space:], not [:blank:]
This is semantically more correct. Previously, in the most common case,
pastes with only `\n` would result in `bad array subscript`.

Fixes #31.
2016-11-07 08:46:40 +00:00
Chris Down c5f101d996 Use -o when running xsel
xsel` without `-o` even though it has the same *end* result, has
different internal logic. Specifically, it seems to do things with the
PRIMARY selection that cause weird behaviour (like causing applications
like urxvt to deselect their selection, see #33).
2016-11-05 12:06:15 -06:00
Chris Down 3e50f9460a Uniquify adjacent identical selection items
This is a potential solution for #30.
2016-11-03 20:36:58 -06:00
Chris Down 6e6c4ed430 Fix blank check
lol where da unit tests at
2016-11-02 16:55:39 -06:00
Chris Down e8ebe8b27d Add tons of debug logging
I'm hoping this will help debug #33, #32, and #26.
2016-11-02 08:49:45 -06:00
GSI2016 05431fe645 replaced md5 logic by using current time with nanoseconds (refs #20)
This strongly improves performance for clipmenud.
2016-06-22 16:59:51 +01:00
Chris Down 1fcc55a48d Silence shellcheck warning about mkdir -pm 2016-06-22 16:50:10 +01:00
Chris Down f9a7291472 License as public domain 2015-10-26 11:10:54 +00:00
Chris Down 45ac24d625 Remove partial clips 2015-10-07 19:06:47 +01:00
Chris Down 4dfbfed9e2 Tidy up clipboard ownership code to be 80 characters wide 2015-09-14 13:41:31 +01:00
Streetwalrus Einstein a613aa6b2e Don't take ownership of PRIMARY, comment about this behavior 2015-09-14 15:01:22 +03:00
Streetwalrus Einstein 065e91a5fc Take over the clipboard to persist it after the owner quits 2015-09-11 23:29:14 +03:00
Chris Down 7c87f80234 Add comments to clipmenu where it could be helpful for future devs 2015-09-06 14:01:06 +01:00
Chris Down 20e9303def Do not deduplicate lines before sending to dmenu
I don't remember why I added this in 0418bf2 (sigh...), but it seems
unnecessary.
2015-09-06 13:58:21 +01:00
Chris Down 72e15005e9 Reduce default poll time down to 0.5 seconds
This is configurable via an environment variable rather than a command line
option, as I'm not expecting many people really need to change this thing.

I profiled the change from 1 -> 0.5 seconds on an old P4, and saw pretty much
no difference in CPU usage, whether there were new clipboard entries or not.

Closes #12.
2015-09-06 01:46:21 +01:00
Chris Down 54981486f2 Use chrisdown.name as URL in LICENSE 2015-08-22 23:13:10 +01:00
Chris Down 66301f4f5f Remove ability to override default dmenu lines with CLIPMENU_LINES
If people want to use this, they can just pass `-l <n>` to clipmenu and it will
be passed through to dmenu. I've checked that passing `-l` twice works fine and
accepts the second passed `-l` optarg as the definitive one.
2015-08-22 23:11:12 +01:00
Chris Down 58a8d7f288 Add ISC license 2015-08-22 23:03:30 +01:00
Chris Down b851c04d3e Set nullglob to avoid "bad array subscript" when no files exist 2015-08-22 19:41:19 +01:00
Chris Down 92807e1053 Merge branch 'feature/travis' into develop 2015-08-22 19:37:07 +01:00
Chris Down 1eb1e21857 Add Travis CI configuration
Fixes #15.
2015-08-22 19:30:26 +01:00
Chris Down 190722f909 Revert "Remove CLIPMENU_LINES support"
This is a sensible default and probably should remain.

This reverts commit 10f0ffe6cb.
2015-08-22 19:28:15 +01:00
Chris Down 95b8cd5698 Limit number of characters displayed in "first line" dmenu selector to 500
Fixes #14.
2015-08-22 13:17:12 +01:00
Chris Down 98b959e0d9 Merge branch 'master' into develop 2015-08-07 19:15:41 +01:00