sass-embedded 1.77.4 → 1.77.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/sass/Rakefile +1 -1
- data/ext/sass/package.json +1 -1
- data/lib/sass/compiler/connection.rb +15 -12
- data/lib/sass/compiler/host/logger_registry.rb +37 -14
- data/lib/sass/embedded/version.rb +1 -1
- data/lib/sass/embedded.rb +1 -1
- data/lib/sass/exception.rb +1 -0
- data/lib/sass/logger/silent.rb +2 -2
- metadata +9 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4867f6d4f0c72a82099760e3e30f978a3d8a3f7481e6b278de15932ba78abe9
|
4
|
+
data.tar.gz: 3a8715387e91dc208b7252dedc3d695f1b9042d473aefe1ff9e9a7c86adce923
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6122e3ca0bcdd1f6c0a020b17579f8762726ea7eb6b4d2ca80db93bff490820d37960d162d229ec612e39199e1de5353d46ad2d0dbd4f0552249f6c09a75ec78
|
7
|
+
data.tar.gz: e5f4c8007b71629eeb55292ff384c3e86003a5b214381ce361286ce83d379388b4c800a9c9452f503bac0a2c78d0e9c183591da65cec52bced86b60843657cf3
|
data/ext/sass/Rakefile
CHANGED
@@ -138,7 +138,7 @@ module FileUtils
|
|
138
138
|
def fetch(source_uri, dest_path = nil)
|
139
139
|
require 'rubygems/remote_fetcher'
|
140
140
|
|
141
|
-
source_uri = "/#{source_uri}" if
|
141
|
+
source_uri = "/#{source_uri}" if !source_uri.start_with?('/') && File.absolute_path?(source_uri)
|
142
142
|
|
143
143
|
source_uri = begin
|
144
144
|
Gem::Uri.parse!(source_uri)
|
data/ext/sass/package.json
CHANGED
@@ -24,21 +24,24 @@ module Sass
|
|
24
24
|
|
25
25
|
@stdin.binmode
|
26
26
|
|
27
|
-
|
28
|
-
|
27
|
+
# # https://dart.dev/tools/dart-devtools
|
28
|
+
# if 'dart' == File.basename(CLI::COMMAND.first, '.exe') && CLI::COMMAND.include?('--observe')
|
29
|
+
# Kernel.warn(@stdout.readline, uplevel: 0)
|
30
|
+
# Kernel.warn(@stdout.readline, uplevel: 0)
|
31
|
+
# end
|
29
32
|
|
30
|
-
|
31
|
-
Thread.new do
|
32
|
-
Thread.current.name = "sass-embedded-process-stdout-poller-#{@wait_thread.pid}"
|
33
|
+
@stdout.binmode
|
33
34
|
|
34
|
-
|
35
|
-
|
36
|
-
# Kernel.warn(@stdout.readline, uplevel: 0)
|
37
|
-
# Kernel.warn(@stdout.readline, uplevel: 0)
|
38
|
-
# end
|
35
|
+
@wait_thread.name = "sass-embedded-process-waiter-#{id}"
|
36
|
+
end
|
39
37
|
|
40
|
-
|
38
|
+
def id
|
39
|
+
@wait_thread.pid
|
40
|
+
end
|
41
41
|
|
42
|
+
def listen(dispatcher)
|
43
|
+
Thread.new do
|
44
|
+
Thread.current.name = "sass-embedded-process-stdout-poller-#{id}"
|
42
45
|
loop do
|
43
46
|
length = Varint.read(@stdout)
|
44
47
|
id = Varint.read(@stdout)
|
@@ -53,7 +56,7 @@ module Sass
|
|
53
56
|
end
|
54
57
|
|
55
58
|
Thread.new do
|
56
|
-
Thread.current.name = "sass-embedded-process-stderr-poller-#{
|
59
|
+
Thread.current.name = "sass-embedded-process-stderr-poller-#{id}"
|
57
60
|
loop do
|
58
61
|
Kernel.warn(@stderr.readline, uplevel: 0)
|
59
62
|
end
|
@@ -10,21 +10,11 @@ module Sass
|
|
10
10
|
def initialize(logger)
|
11
11
|
logger = Structifier.to_struct(logger, :debug, :warn)
|
12
12
|
|
13
|
-
|
14
|
-
|
15
|
-
logger.debug(event.message,
|
16
|
-
span: event.span.nil? ? nil : Logger::SourceSpan.new(event.span))
|
17
|
-
end
|
18
|
-
end
|
13
|
+
{ debug: DebugContext, warn: WarnContext }.each do |symbol, context_class|
|
14
|
+
next unless logger.respond_to?(symbol)
|
19
15
|
|
20
|
-
|
21
|
-
|
22
|
-
deprecation = event.type == :DEPRECATION_WARNING
|
23
|
-
logger.warn(event.message,
|
24
|
-
deprecation:,
|
25
|
-
deprecation_type: (event.deprecation_type if deprecation),
|
26
|
-
span: event.span.nil? ? nil : Logger::SourceSpan.new(event.span),
|
27
|
-
stack: event.stack_trace)
|
16
|
+
define_singleton_method(symbol) do |event|
|
17
|
+
logger.public_send(symbol, event.message, context_class.new(event))
|
28
18
|
end
|
29
19
|
end
|
30
20
|
end
|
@@ -49,6 +39,39 @@ module Sass
|
|
49
39
|
def warn(event)
|
50
40
|
Kernel.warn(event.formatted)
|
51
41
|
end
|
42
|
+
|
43
|
+
# Contextual information passed to `debug`.
|
44
|
+
class DebugContext
|
45
|
+
# @return [Logger::SourceSpan, nil]
|
46
|
+
attr_reader :span
|
47
|
+
|
48
|
+
def initialize(event)
|
49
|
+
@span = event.span.nil? ? nil : Logger::SourceSpan.new(event.span)
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
private_constant :DebugContext
|
54
|
+
|
55
|
+
# Contextual information passed to `warn`.
|
56
|
+
class WarnContext < DebugContext
|
57
|
+
# @return [Boolean]
|
58
|
+
attr_reader :deprecation
|
59
|
+
|
60
|
+
# @return [String, nil]
|
61
|
+
attr_reader :deprecation_type
|
62
|
+
|
63
|
+
# @return [String]
|
64
|
+
attr_reader :stack
|
65
|
+
|
66
|
+
def initialize(event)
|
67
|
+
super
|
68
|
+
@deprecation = event.type == :DEPRECATION_WARNING
|
69
|
+
@deprecation_type = (event.deprecation_type if @deprecation)
|
70
|
+
@stack = event.stack_trace
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
private_constant :WarnContext
|
52
75
|
end
|
53
76
|
|
54
77
|
private_constant :LoggerRegistry
|
data/lib/sass/embedded.rb
CHANGED
@@ -63,7 +63,7 @@ module Sass
|
|
63
63
|
@last_accessed_time = current_time
|
64
64
|
|
65
65
|
Thread.new do
|
66
|
-
Thread.current.name =
|
66
|
+
Thread.current.name = "sass-embedded-connection-reaper-#{@connection.id}"
|
67
67
|
duration = idle_timeout
|
68
68
|
loop do
|
69
69
|
sleep(duration.negative? ? idle_timeout : duration)
|
data/lib/sass/exception.rb
CHANGED
data/lib/sass/logger/silent.rb
CHANGED
@@ -18,9 +18,9 @@ module Sass
|
|
18
18
|
module Silent
|
19
19
|
module_function
|
20
20
|
|
21
|
-
def warn(message,
|
21
|
+
def warn(message, options); end
|
22
22
|
|
23
|
-
def debug(message,
|
23
|
+
def debug(message, options); end
|
24
24
|
end
|
25
25
|
|
26
26
|
private_constant :Silent
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sass-embedded
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.77.
|
4
|
+
version: 1.77.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- なつき
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-07-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -28,22 +28,16 @@ dependencies:
|
|
28
28
|
name: google-protobuf
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: '3.25'
|
34
|
-
- - "<"
|
31
|
+
- - "~>"
|
35
32
|
- !ruby/object:Gem::Version
|
36
|
-
version: '
|
33
|
+
version: '4.26'
|
37
34
|
type: :runtime
|
38
35
|
prerelease: false
|
39
36
|
version_requirements: !ruby/object:Gem::Requirement
|
40
37
|
requirements:
|
41
|
-
- - "
|
42
|
-
- !ruby/object:Gem::Version
|
43
|
-
version: '3.25'
|
44
|
-
- - "<"
|
38
|
+
- - "~>"
|
45
39
|
- !ruby/object:Gem::Version
|
46
|
-
version: '
|
40
|
+
version: '4.26'
|
47
41
|
description: A Ruby library that will communicate with Embedded Dart Sass using the
|
48
42
|
Embedded Sass protocol.
|
49
43
|
email:
|
@@ -107,8 +101,8 @@ licenses:
|
|
107
101
|
- MIT
|
108
102
|
metadata:
|
109
103
|
bug_tracker_uri: https://github.com/sass-contrib/sass-embedded-host-ruby/issues
|
110
|
-
documentation_uri: https://rubydoc.info/gems/sass-embedded/1.77.
|
111
|
-
source_code_uri: https://github.com/sass-contrib/sass-embedded-host-ruby/tree/v1.77.
|
104
|
+
documentation_uri: https://rubydoc.info/gems/sass-embedded/1.77.8
|
105
|
+
source_code_uri: https://github.com/sass-contrib/sass-embedded-host-ruby/tree/v1.77.8
|
112
106
|
funding_uri: https://github.com/sponsors/ntkme
|
113
107
|
rubygems_mfa_required: 'true'
|
114
108
|
post_install_message:
|
@@ -126,7 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
126
120
|
- !ruby/object:Gem::Version
|
127
121
|
version: '0'
|
128
122
|
requirements: []
|
129
|
-
rubygems_version: 3.5.
|
123
|
+
rubygems_version: 3.5.15
|
130
124
|
signing_key:
|
131
125
|
specification_version: 4
|
132
126
|
summary: Use dart-sass with Ruby!
|