Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion create_protobuf.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def main() -> int:
# Fetch protocol file.
resp = urlopen(PROTOCOL_FILE_URL)
if resp.status != 200:
sys.stderr.write("Failed to fetch protcol file.\n")
sys.stderr.write("Failed to fetch protocol file.\n")
return 1
proto_dir = Path(tempfile.mkdtemp())
proto_path = proto_dir / "embedded_sass.proto"
Expand Down
2 changes: 1 addition & 1 deletion docs/usage/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Usage guide
When you install by sdist, none-any bdist or source,
you need to install it manually.

There are some usage for ``sass-embbedded``.
There are some usage for ``sass-embedded``.

.. toctree::
:maxdepth: 2
Expand Down
2 changes: 1 addition & 1 deletion docs/usage/protocol.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Currently, this project supports low-level protocol access.
**Under construction**

This API will be implemented to work correctly,
but it is only to send and recieve protobuf message.
but it is only to send and receive protobuf message.

If you want to know usage now, See `example code`_.

Expand Down
2 changes: 1 addition & 1 deletion src/sass_embedded/protocol/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def send_message(self, message: InboundMessage) -> OutboundMessage:
# Sending packet.
packet = self.make_packet(message)
self._proc.stdin.write(packet.to_bytes()) # type: ignore[union-attr]
# Recieve packet.
# Receive packet.
out = b""
idx = 0
length = 0
Expand Down
8 changes: 4 additions & 4 deletions src/sass_embedded/simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,9 +140,9 @@ def compile_string(
) -> Result[str]:
"""Convert from Sass/SCSS source to CSS.

:param srouce: Source text. It must be format for Sass or SCSS.
:param source: Source text. It must be format for Sass or SCSS.
:param syntax: Source format.
:param load_paths: List of addtional load path for Sass compile.
:param load_paths: List of additional load path for Sass compile.
:param style: Output style.
:param embed_sourcemap: Flag to embed source-map into output.
:param embed_sources: Flag to embed sources into output. It works only when ``embed_sourcemap`` is ``True``.
Expand Down Expand Up @@ -181,7 +181,7 @@ def compile_file(

:param source: Source path. It must have extension ``.sass``, ``.scss`` or ``.css``.
:param dest: Output destination.
:param load_paths: List of addtional load path for Sass compile.
:param load_paths: List of additional load path for Sass compile.
:param style: Output style.
:param no_sourcemap: Flag to skip generating source-map.
:param embed_sourcemap: Flag to embed source-map into output.
Expand Down Expand Up @@ -227,7 +227,7 @@ def compile_directory(

:param source: Source path. It must have extension ``.sass``, ``.scss`` or ``.css``.
:param dest: Output destination.
:param load_paths: List of addtional load path for Sass compile.
:param load_paths: List of additional load path for Sass compile.
:param style: Output style.
:param no_sourcemap: Flag to skip generating source-maps.
:param embed_sourcemap: Flag to embed source-map into output.
Expand Down
12 changes: 6 additions & 6 deletions tests/test_simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,8 +174,8 @@ def test_default_calling(self, syntax: str, style: str, tmpdir: Path):
cmp = filecmp.dircmp(output, expected)
output_files = list(Path(output).glob("*.css"))
output_maps = list(Path(output).glob("*.css.map"))
expexted_files = list(Path(expected).glob("*"))
assert len(expexted_files) == len(output_files)
expected_files = list(Path(expected).glob("*"))
assert len(expected_files) == len(output_files)
assert len(output_files) == len(output_maps)
assert cmp.left_only == sorted([f.name for f in output_maps])

Expand All @@ -184,17 +184,17 @@ def test_with_no_sourcemaps(self, tmpdir: Path):
M.compile_directory(source, output, no_sourcemap=True)
output_files = list(Path(output).glob("*.css"))
output_maps = list(Path(output).glob("*.css.map"))
expexted_files = list(Path(expected).glob("*"))
assert len(expexted_files) == len(output_files)
expected_files = list(Path(expected).glob("*"))
assert len(expected_files) == len(output_files)
assert not output_maps

def test_with_embed_sourcemap(self, tmpdir: Path):
source, expected, output = self._setup_items(tmpdir, "scss", "expanded")
M.compile_directory(source, output, embed_sourcemap=True)
output_files = list(Path(output).glob("*.css"))
output_maps = list(Path(output).glob("*.css.map"))
expexted_files = list(Path(expected).glob("*"))
assert len(expexted_files) == len(output_files)
expected_files = list(Path(expected).glob("*"))
assert len(expected_files) == len(output_files)
assert not output_maps

def test_with_embed_sources(self, tmpdir: Path):
Expand Down
Loading