Commit Graph

90 Commits

Author SHA1 Message Date
633604cefa added missing check 2020-08-31 23:50:51 +02:00
0486872d78 better error messages for wrong config 2020-08-31 22:26:10 +02:00
9871f375ed bump to version 0.3
bug fixes, check commits for details
implemented new parser, altough it adds some lines it lowers the comlexity and
it should be faster especially for bigger config files
2020-08-31 17:53:20 +02:00
0507be14b6 testing new parser 2020-08-30 23:08:52 +02:00
5d6ee6dd83 more readable gitignore 2020-08-30 23:07:35 +02:00
6a3e033b68 fixed #2
skip zero or 1 allocations and uninitialized conditional jump
in hotkey_list_add()

now the whole output of die() is coloured
2020-08-29 20:52:44 +02:00
689e6005ac shitty hack to fix out of bounds with -v 2020-08-28 13:53:44 +02:00
1ba688f975 bump to version 0.2
- better recognition of invalid config files
- general polish of error messages
- hkd follows the rule of silence
- when using -v the correct key names are shown
- commands in config files can be multiline (using \\n)
2020-08-01 14:48:22 +02:00
344887c925 fixed: wrong key names after 'z' when using -v 2020-08-01 12:22:52 +02:00
1b7af99723 fix #1: parser no longer allows blank lines for keys or command 2020-07-29 22:07:53 +02:00
d110948129 closing #2: made the program silent
turned off the "error" messages by default and using the -v flag to turn
them back on as they are not useful for normal use, also now those messages
are printed to stdout
2020-07-29 20:37:59 +02:00
e14049d5b6 fixed invalid free() and missing break; 2020-07-29 16:57:53 +02:00
de6db78896 removed unnecessary memmove(s) in parse_config_file() 2020-07-29 12:27:08 +02:00
e1e239430c licensed under the MIT license 2020-07-29 12:04:02 +02:00
904a10cdf8 fix typo 2020-07-28 20:35:24 +02:00
36ea0ccc6d modified readme
fixed typos and updated some info
2020-07-28 20:32:19 +02:00
472daace31 added -c option
-c is used to override the default config files and instead use the speocified
one
2020-07-28 20:19:52 +02:00
5db72c0b43 fix comment bug
comments not at the beginning of the line are no longer ignored
2020-07-28 13:33:12 +02:00
514407015e install, uninstall and version
modified makefile to be abled to install and uninstall, also installing puts
the correct version in the man page.
All credits go to suckless :^)
2020-07-28 13:30:20 +02:00
c011888c5f added man page for hkd 2020-07-28 13:05:02 +02:00
a4fcd4de31 entering version 0.1
the program is finally in a usable status, many things were added in
this commit:
	- config file parsing from tests
	- config multiple config file locations
	- more I can't grasp
anyways have fun.
2020-07-28 01:14:37 +02:00
6613bd0707 modified parser to suit new config format 2020-07-25 17:51:00 +02:00
cc15646a15 changed makefile
Tests now compile with just -Wall in order to allow for placeholder variables.
Also tests are now compiled in c99
2020-07-25 17:43:21 +02:00
67a36f71e3 finally decided the config style
read the template.conf file for examples and the spec.
2020-07-19 16:35:21 +02:00
21e833143c changed key names
key names now don't include the "KEY_" part before the actual name
2020-07-19 16:34:20 +02:00
6a5367ac00 verbose option displays key names instead of values
very crude implementation, works for standard keys but breaks
for media/special keys, good enough for now
2020-07-19 11:54:29 +02:00
ea6f548399 added -v argument
verbose option: now hkd doesn't default to printing pressed keys basically
acting as a keylogger but now requires -v to do so.
2020-07-18 23:42:27 +02:00
3ffa960ae7 changed names
key_buffer_compare_ordered -> key_buffer_compare
key_buffer_compare_random  -> key_buffer_compare_fuzzy
2020-07-18 16:05:07 +02:00
05a18e8874 implemented exec_command with wordexp(3)
this allows for a less error-prone parsing method
(as wordexp(3) is in libc) and enables for shell-like
word expansion, refer to the man page for more info
about wordexp(3)
2020-07-05 17:00:50 +02:00
d39281f9a6 minor fix
hotkeys don't get triggerd twice when after the right
keys are pressed one or more other keys are pressed
afterwards
2020-07-05 12:02:32 +02:00
ed7202e5c8 added key_buffer_compare_random/ordered
In the future one can specify that the hotkey triggers
only when the keys are pressed in the right order, or
in any order, this will be configured per-hotkey in the
config file
2020-07-05 11:58:21 +02:00
dd319e08b7 deleted empty first line 2020-06-17 16:57:20 +02:00
8bbdaa3d21 key_buffer is now static for performance 2020-06-09 21:47:44 +02:00
435bbfbab8 modified configuration file and parser 2020-06-09 20:47:25 +02:00
300b82bc5e added str_to_argv() 2020-06-09 20:46:51 +02:00
33526a916f some linting 2020-06-09 18:15:45 +02:00
e15699e4ed removed unused files 2020-06-09 17:54:58 +02:00
9a5767263e key conversion table megastruct 2020-06-09 15:47:14 +02:00
9866fa0533 struct init test 2020-06-09 15:46:44 +02:00
9564915e08 key_buffer_compare() 2020-06-06 23:11:45 +02:00
edaa6806d4 made std c99 compliant 2020-05-27 14:50:57 +02:00
b18fb0cf8e formatting 2020-05-16 16:03:03 +02:00
129f0ce8e8 commented unnecessary free 2020-05-13 14:20:07 +02:00
bd3d82158b minor macro formatting 2020-05-13 14:19:55 +02:00
d7b0ac68ef green text 2020-05-13 14:03:41 +02:00
c4e671b203 close epoll fd on exit 2020-05-13 14:02:31 +02:00
5acaa2b7df line savings 2020-05-13 14:02:12 +02:00
9c89e52692 update on device change with inotify 2020-05-13 00:22:16 +02:00
4042c02ada inotify test 2020-05-13 00:17:29 +02:00
a8f8dc8126 removed bsd compatibility 2020-05-12 22:54:15 +02:00