fusuma 3.11.1 → 3.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/bin/console +4 -4
- data/exe/fusuma +15 -15
- data/lib/fusuma/config/searcher.rb +6 -8
- data/lib/fusuma/plugin/detectors/detector.rb +1 -0
- data/lib/fusuma/plugin/inputs/timer_input.rb +1 -0
- data/lib/fusuma/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 515a37e5be710edfd3beda67d734a49ad516dd9c01654afb0bf0d3145ab20c6d
|
|
4
|
+
data.tar.gz: ab7ab39b5097de21b58e403d3b4cdcebc3fab41327ddf0a5fb0c7a3ae6d531a3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8f84ab4bddf97600928b348dec236008205b7261a90bdf87ee8f6409f8524864ffe587ace33569b64b8ecac773a02a58c3776908186b3a08298dac55f9b0a0ed
|
|
7
|
+
data.tar.gz: 1c2b88e154697a95e96ce8e4b4df1b712f80ac2e27d63ac06c7d6f5824e566d1479df51975241277b881a537a1fd883364e19ed4d9338a9465d39438ed644370
|
data/bin/console
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env ruby
|
|
2
2
|
# frozen_string_literal: true
|
|
3
3
|
|
|
4
|
-
require
|
|
5
|
-
require
|
|
4
|
+
require "bundler/setup"
|
|
5
|
+
require "fusuma"
|
|
6
6
|
|
|
7
7
|
# You can add fixtures and/or initialization code here to make experimenting
|
|
8
8
|
# with your gem easier. You can also use a different console, if you like.
|
|
@@ -10,9 +10,9 @@ require 'fusuma'
|
|
|
10
10
|
# (If you use this, don't forget to add pry to your Gemfile!)
|
|
11
11
|
|
|
12
12
|
def reload!(print = true)
|
|
13
|
-
puts
|
|
13
|
+
puts "Reloading ..." if print
|
|
14
14
|
# Main project directory.
|
|
15
|
-
root_dir = File.expand_path(
|
|
15
|
+
root_dir = File.expand_path("..", __dir__)
|
|
16
16
|
# Directories within the project that should be reloaded.
|
|
17
17
|
reload_dirs = %w[lib]
|
|
18
18
|
# Loop through and reload every file in all relevant project directories.
|
data/exe/fusuma
CHANGED
|
@@ -1,47 +1,47 @@
|
|
|
1
1
|
#!/usr/bin/env ruby
|
|
2
2
|
# frozen_string_literal: true
|
|
3
3
|
|
|
4
|
-
require
|
|
5
|
-
require_relative
|
|
4
|
+
require "optparse"
|
|
5
|
+
require_relative "../lib/fusuma"
|
|
6
6
|
|
|
7
7
|
option = {}
|
|
8
8
|
opt = OptionParser.new
|
|
9
9
|
|
|
10
|
-
opt.on(
|
|
11
|
-
|
|
10
|
+
opt.on("-c", "--config=path/to/file",
|
|
11
|
+
"Use an alternative config file") do |v|
|
|
12
12
|
option[:config_path] = v
|
|
13
13
|
end
|
|
14
14
|
|
|
15
|
-
opt.on(
|
|
16
|
-
|
|
15
|
+
opt.on("-d", "--daemon",
|
|
16
|
+
"Daemonize process") do |v|
|
|
17
17
|
option[:daemon] = v
|
|
18
18
|
end
|
|
19
19
|
|
|
20
|
-
opt.on(
|
|
21
|
-
|
|
20
|
+
opt.on("-l", "--list-devices",
|
|
21
|
+
"List available devices") do |v|
|
|
22
22
|
option[:list] = v
|
|
23
23
|
end
|
|
24
24
|
|
|
25
|
-
opt.on(
|
|
26
|
-
|
|
25
|
+
opt.on("--log=path/to/file",
|
|
26
|
+
"Print logs to file") do |v|
|
|
27
27
|
option[:log_filepath] = v
|
|
28
28
|
end
|
|
29
29
|
|
|
30
|
-
opt.on(
|
|
30
|
+
opt.on("--show-config", "Show config as YAML format which is loaded internally") do |v|
|
|
31
31
|
option[:show_config] = v
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
opt.on('--device="Device name"',
|
|
35
|
-
|
|
35
|
+
"Open the given device only (DEPRECATED)") do |v|
|
|
36
36
|
option[:device] = v
|
|
37
37
|
end
|
|
38
38
|
|
|
39
|
-
opt.on(
|
|
40
|
-
|
|
39
|
+
opt.on("-v", "--verbose",
|
|
40
|
+
"Show details about the results of running fusuma") do |v|
|
|
41
41
|
option[:verbose] = v
|
|
42
42
|
end
|
|
43
43
|
|
|
44
|
-
opt.on(
|
|
44
|
+
opt.on("--version", "Show fusuma version") do |v|
|
|
45
45
|
option[:version] = v
|
|
46
46
|
end
|
|
47
47
|
|
|
@@ -19,18 +19,16 @@ module Fusuma
|
|
|
19
19
|
def search(index, location:)
|
|
20
20
|
key = index.keys.first
|
|
21
21
|
return location if key.nil?
|
|
22
|
-
|
|
23
22
|
return nil if location.nil?
|
|
24
|
-
|
|
25
23
|
return nil unless location.is_a?(Hash)
|
|
26
24
|
|
|
27
|
-
next_index = Index.new(
|
|
25
|
+
next_index = Index.new(index.keys.drop(1))
|
|
28
26
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
27
|
+
next_location_cadidates(location, key).each do |next_location|
|
|
28
|
+
result = search(next_index, location: next_location)
|
|
29
|
+
return result if result
|
|
32
30
|
end
|
|
33
|
-
|
|
31
|
+
nil
|
|
34
32
|
end
|
|
35
33
|
|
|
36
34
|
#: (Fusuma::Config::Index, location: Array[untyped], context: Hash[untyped, untyped] | nil) -> untyped
|
|
@@ -77,7 +75,7 @@ module Fusuma
|
|
|
77
75
|
def next_location_cadidates(location, key)
|
|
78
76
|
[
|
|
79
77
|
location[key.symbol],
|
|
80
|
-
key.skippable
|
|
78
|
+
key.skippable ? location : nil
|
|
81
79
|
].compact
|
|
82
80
|
end
|
|
83
81
|
|
data/lib/fusuma/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fusuma
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.11.
|
|
4
|
+
version: 3.11.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- iberianpig
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-01-
|
|
11
|
+
date: 2026-01-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: Fusuma is multitouch gesture recognizer. This gem makes your touchpad
|
|
14
14
|
on Linux able to recognize swipes or pinchs and assign command to them. Read installation
|